Skip to content

feat: Cesium example#534

Draft
ilyabo wants to merge 18 commits intomainfrom
cesium-example
Draft

feat: Cesium example#534
ilyabo wants to merge 18 commits intomainfrom
cesium-example

Conversation

@ilyabo
Copy link
Copy Markdown
Collaborator

@ilyabo ilyabo commented Apr 13, 2026

image

collord and others added 9 commits April 11, 2026 17:52
Introduces @sqlrooms/cesium, a new package for 3D geospatial
visualization built on CesiumJS and Resium, along with an
example app demonstrating earthquake data visualization on a
3D globe.

Package features:
- CesiumSlice for state management (camera, clock, layers, scene)
- SQL-driven entity layers via useSqlToCesiumEntities hook
- Support for geojson, czml, sql-entities, and tileset layer types
- Time-animated entities with clock sync
- Depth testing against terrain, subsurface rendering, and
  camera height controls
- CesiumPanel, CesiumClock, CesiumToolbar UI components

Example app (examples/cesium-app):
- Earthquake explorer loading parquet data from HuggingFace
- Demonstrates SQL query to 3D entity rendering pipeline
- Uses vite-plugin-cesium for asset handling
- Room.tsx: remove manual initialize() call; RoomShell handles it
  automatically, and the manual useEffect fired twice under React
  StrictMode.
- cesium-config.ts: createDefaultCesiumConfig now returns a
  structuredClone of DEFAULT_CESIUM_CONFIG so callers cannot mutate
  the shared singleton. Also fix stale doc comment claiming camera
  longitude/latitude are in radians (they are degrees).
- useSqlToCesiumEntities: skip rows with non-finite lon/lat/alt or
  unparseable time values instead of passing NaN to
  Cartesian3.fromDegrees / JulianDate.fromIso8601.
- useClockSync: narrow the store->Cesium selector with useShallow to
  exclude currentTime. Previously the tick handler wrote currentTime
  to the store, retriggering the effect that reapplied the full clock
  config to Cesium, creating a feedback loop.
- CesiumEntityLayer: remove debug console.log from clock-range
  setter that was leaking into production logs.
- cesium-app README: correct the earthquake magnitude filter (5.0+,
  not 4.0+) and the speed slider description (logarithmic 1x to
  1 year/sec, not "0.1x to 100x").
- useClockSync: restore store->Cesium currentTime propagation that was
  lost when we excluded currentTime from the selector. A separate
  guarded effect now watches store currentTime and applies it to the
  viewer only when it differs from the last tick-originated write,
  preventing the feedback loop while allowing external setCurrentTime
  calls (e.g. timeline scrub) to reach the viewer.
- useSqlToCesiumEntities: compute stopJd by scanning all rows for the
  maximum valid timestamp instead of assuming the last row is latest.
  Rows may not be time-sorted depending on the SQL query.
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 13, 2026

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 5f23c06d-7c9e-4080-a908-2542a20018e0

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch cesium-example

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@ilyabo ilyabo changed the title Cesium example feat: Cesium example Apr 13, 2026
ilyabo added 9 commits April 14, 2026 00:41
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Signed-off-by: Ilya Boyandin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants