MCPcopy Index your code
hub / github.com/Kayhan-Space/sgp4gl-demo

github.com/Kayhan-Space/sgp4gl-demo @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
144 symbols 280 edges 18 files 1 documented · 1% updated 9mo ago★ 33
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

3D Satellite Visualization with SGP4GL, Cesium, and Next.js 14

This project demonstrates real-time 3D satellite visualization in the browser using SGP4GL, CesiumJS, and Next.js 14. It provides a framework for rendering satellite orbits with web-based ephemeris propagation.


🚀 Getting Started

Comparing GPU vs CPU rendering

Installation

Clone the repository and install dependencies:

npm install

Running in Development

npm run dev

Production Build

npm run build
npm run start

🌐 Live Demo & Resources


⚙️ Configuration

Environment Variables

Cesium is configured to use an external tile provider.
Set the following environment variable in .env.local:

NEXT_PUBLIC_CESIUM_TOKEN=<your_cesium_token>
NEXT_PUBLIC_TILES_URL=<your_tile_provider_url>

You can get your own tokens here https://cesium.com/learn/ion/cesium-ion-access-tokens/

Cesium File Requirements

Cesium requires specific static assets to be served publicly.
This is handled with CopyWebpackPlugin in next.config.js.

Note: Each copy statement must include:

js info: { minimized: true; }


🛠️ Compatibility Notes

Integrating Cesium with Next.js can introduce build/runtime challenges.
This repository is configured to maximize compatibility between:

  • CesiumJS
  • Next.js 14+
  • Vercel Deployment

If you are adapting this project, refer to this repository:

Barebones Cesium + Next.js Example: github.com/hyundotio/next-ts-pagerouter-cesium-example


📖 License

MIT – feel free to use and adapt this project.

Extension points exported contracts — how you extend this code

SatMetadata (Interface)
(no doc)
Components/CesiumComponent.tsx
PerformanceStats (Interface)
(no doc)
Components/PerformanceComparison.tsx
SatMetadata (Interface)
(no doc)
Components/CesiumComponent_CPU.tsx
ErrorTleWhatBadChecksum (Interface)
(no doc)
sgp4/bindings/sgp4/sgp4.d.ts
PositionBuffer (Interface)
(no doc)
Components/CesiumComponent.tsx
ErrorTleWhatBadLength (Interface)
(no doc)
sgp4/bindings/sgp4/sgp4.d.ts
ErrorTleWhatBadFirstCharacter (Interface)
(no doc)
sgp4/bindings/sgp4/sgp4.d.ts
ErrorTleWhatExpectedFloat (Interface)
(no doc)
sgp4/bindings/sgp4/sgp4.d.ts

Core symbols most depended-on inside this repo

data_view
called by 209
sgp4/bindings/sgp4/intrinsics.js
clone
called by 39
sgp4/bindings/sgp4/sgp4.js
insert
called by 33
sgp4/bindings/sgp4/intrinsics.js
remove
called by 11
sgp4/bindings/sgp4/intrinsics.js
get
called by 7
sgp4/bindings/sgp4/intrinsics.js
pathBuilder
called by 6
next.config.js
utf8_encode
called by 6
sgp4/bindings/sgp4/intrinsics.js
utf8_encoded_len
called by 6
sgp4/bindings/sgp4/intrinsics.js

Shape

Method 55
Interface 37
Function 30
Class 22

Languages

TypeScript100%

Modules by API surface

sgp4/bindings/sgp4/sgp4.js56 symbols
sgp4/bindings/sgp4/sgp4.d.ts41 symbols
sgp4/bindings/sgp4/intrinsics.js11 symbols
Components/PerformanceComparison.tsx8 symbols
Components/CesiumComponent.tsx8 symbols
sgp4/bindings/index.js5 symbols
pages/index.tsx3 symbols
next.config.js3 symbols
Components/CesiumComponent_CPU.tsx3 symbols
sgp4/bindings/index.d.ts2 symbols
utils/tles.ts1 symbols
pages/_document.tsx1 symbols

For agents

$ claude mcp add sgp4gl-demo \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact