ariadne: port the volume bunny demos (volren + volslice) to DSL via a mesh-SDF volume source - #546
Merged
Merged
Conversation
…+ reusable controls
The cvcGL volume-raycast (volren_bunny) and volume-slice (volslice_bunny) demos had
no Ariadne .ari version because the realizer could only load a volume FILE, while the
demos synthesize the volume as the signed distance field of the bunny MESH at runtime.
Enabler — a MESH-SDF volume source in the scene schema: `source: { sdf: { mesh: <uri>,
dim: N } }` on a volren/volslice node. The realizer loads the mesh (optionally applying
the node's `fit:` to stand/scale it, for framing parity with a geometry node) and runs
cvc::sdf over an N³ grid — so any demo can turn a mesh into a volume with no asset file,
pure-DSL on the stock ariadne_hello host. Guarded on CVC_ENABLE_SDF (warns + skips
without it). The file-source path is unchanged (realize regression test still passes).
Ports — volren_bunny.ari (distance-field isosurface) and volslice_bunny.ari (a transfer
function around the zero level set), both verified rendering headless via EGL.
Reusable components — they import the existing stage_lighting + camera_controls
components (shared with bunny_shadow), plus two new catalog components, volren_controls
and volslice_controls, that bind the renderer's two-way cvc::volren/volslice::state_settings
keys (steps/ambient/supersample/shadows, quality/near-plane/max-planes) so the panels are
declarative — no host C++. Added both to the component INDEX.
Tests: AriadneScene.VolumeSdfMeshSource (loader parses source: { sdf }); the existing
cvcgl_ariadne_realize volren/volslice path is unchanged and green.
transfix
enabled auto-merge
October 2, 2026 21:43
transfix
added a commit
that referenced
this pull request
Oct 2, 2026
Conflicts:
- cvcpkg/recipes/{cvcgl,cvcgl-cuda,cvcgl-examples}/recipe.yaml: #537 took
cvcgl 18, cvcgl-cuda 3 and cvcgl-examples 17 for the wasm app contract, above
the revisions this branch had set aside (17, 2, 16). Master's bump comments
are kept; this branch's revisions move to the next number above master's and
above the highest published on any platform (cvcgl 16, cvcgl-examples 15,
cvcgl-cuda none): cvcgl 19, cvcgl-cuda 4, cvcgl-examples 18. libcvc stays at
17 (master 15, published 16).
- src/cvcGL/CMakeLists.txt: both installs kept -- master's wasm state shim and
this branch's THIRD_PARTY_NOTICES.md. The test region merged clean: master's
JS-test registration and its REMOVE_ITEM additions, one GL-test lock block.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Ariadne (
.ari) ports of the cvcGL volume-raycast (volren_bunny) and volume-slice (volslice_bunny) demos — the "finish the Ariadne demo versions, start with the bunnies" work — plus the enabling capability and reusable control components.The blocker & the fix. These demos had no
.aribecause the realizer could only load a volume file, while the demos synthesize the volume as the signed distance field of the bunny mesh at runtime. New mesh-SDF volume source in the scene schema:The realizer loads the mesh (applying the node's
fit:to stand/scale it, for framing parity with a geometry node) and runscvc::sdfover an N³ grid — so any demo can turn a mesh into a volume with no asset file, pure-DSL on the stockariadne_hellohost. Guarded onCVC_ENABLE_SDF(warns + skips without it). The file-source path is unchanged.Ports.
volren_bunny.ari(distance-field isosurface) andvolslice_bunny.ari(a transfer function around the zero level set), both verified rendering headless via EGL (the bunny raycast / sliced on the ground plane).Reusable components (the "shared functionality" ask). Both demos
importthe existingstage_lighting+camera_controlscomponents (shared withbunny_shadow), plus two new catalog components —volren_controlsandvolslice_controls— binding the renderer's two-waycvc::volren/cvc::volslice::state_settingskeys (steps/ambient/supersample/shadows; quality/near-plane/max-planes), so the panels are declarative with no host C++. Added both to the componentINDEX.Tests.
AriadneScene.VolumeSdfMeshSource(loader parsessource: { sdf }); the existingcvcgl_ariadne_realizevolren/volslice path is unchanged and green.Follow-ups: parametrize the volume-control components by node id (the catalog already models
args: { node: … }) instead of thebunny_volumeconvention; extendSceneVolRenwith the richer volumetric-shadow/AO/hemisphere knobs for full volren panel parity.