CesiumGS / CesiumGS/cesium-native
Address potential desyncs between tile selection and runtime rendering
- Dominant language
- C++
- Stars
- 623
- Forks
- 277
- PR merge metrics
- No merged PRs in 30d
Description
## Problem
Non-traditional data types (e.g., Gaussian splats and voxels) require rendering techniques that aggregate data into one place on the GPU. However, these systems are at odds with cesium-native's own systems for tile selection and resource preparation.
The assumption is that after `prepareInMainThread`, a model will have fully initialized on the runtime side and the tile will be ready to render. This is not true for splats or voxels, because there is an extra latency between when the game components/objects are created vs. when their data actually makes it into their respective rendering systems.
For voxels in Unreal (https://github.com/CesiumGS/cesium-unreal/pull/1685), this is mitigated because of the custom `VoxelOctree` class which maintains its own traversal history. For splats, many tiles are hidden too early before the intended level of detail appears, leading to large incorrect gaps.
## Possible Solutions
One idea is to have some overridable `isReady` function on the render resources. This way, native won't choose to hide a tile if the contents of its children aren't actually "ready" according to some runtime metric. I'm not sure how this would work API wise, though I think it's possible and perhaps the easiest solution.
There is also the possibility to bring parts of the splat/voxel systems in Unreal into cesium-native; they both use a "registering"/"unregistering" system for their respective rendering techniques. But maybe that would be too heavy handed?
Contributor guide
Research direction
Start by tracing prepareInMainThread and the tile-selection and render-resource readiness paths. Compare the voxel traversal approach described in cesium-unreal PR 1685 with the splat behavior, then define and validate a readiness contract that prevents tiles from being hidden before their runtime data is available.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- computer-graphics
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100