Repository navigation
Ariadne: the fog-of-war ghost as a document (nav_fog_ghost.ari), on a nav_swarm arena with a stale map - #1589
Merged
Merged
Conversation
… nav_swarm arena with a stale map The C++ nav_fog_ghost (retired by #1568) as an Ariadne document that arigl runs, on a 2-D map by default. One vehicle crosses a 200 m open field with a stale map that shows a wall across its path; its A* route over its belief bends round the wall's end, its sensor wears the phantom away, the route is planned again and it drives straight through where the wall stood. The ground shows what it knows, with an LED per believed wall (red real, amber ghost); the phantom stands as a see-through amber wall that wears away; the blue plan to the carrot against the yellow track, the cyan route ahead, the sensor ring, the start and the GOAL; a four-beat caption at 0.5x. Scenario dynamic: an honest map and a second vehicle crossing the path. In the gallery as nav_fog_ghost_ari, and the old nav_fog_ghost address opens it. The library pieces, in the nav_swarm node (scene_swarm.h, swarm_nodes.h, ARIADNE.md §5.4): - arena: an open field in metres, walls:, and phantoms: in the vehicles' starting map only (swarm_city::prior, arena_swarm_city), with the phantoms key choosing it at each build; - vehicles: listed starts and goals, each its own target; - route: belief: an 8-connected A* route over each plane's belief, planned again on the worker whenever a belief flip changes some plane's map; - range and sense_ticks (the range key too); stats time, range, ghosts, ghosts0 and replans; SceneSwarm::belief(), ghosts(), routes(); the frame's carrots (sim_thread::snapshot::carrot); - the ghosts, plan, route and sensor layers; the city layer's belief: true (the LED grid) and an arena's walls; path up to 1024 segments; the city ground under the cells' full extent. Tests: ariadne_scene_swarm_test (the arena's raster, the props, listed vehicles and the phantoms key, and the whole ghost story on the worker and on the frame's thread) and cvcgl_ariadne_swarm (a ghost section: the new layers' meshes, and the ghost wall wearing away).
…ls sample on the navigator's frames, sense_ticks - city layer: the fog and the lights are painted through the pixels taken before setTexture shares the image. The image is copy-on-write, so fog.data() after it painted a private copy the texture never saw, and the ground stayed as it was built (the synthetic city's fog too). cvcgl_ariadne_swarm reads the texture's texels back: in view lit, the cleared lights out. - trails and path sample every `every` navigator frames, not view frames, and a jump is three vehicle lengths (at least 3 m): at the story's half speed the track was dots. - nav_swarm's sense_ticks: the navigator steps between senses (4); the ghost senses every 2, as the C++ demo did. - The caption's discovery beat fires once a quarter of the phantom is sensed away: the far end never comes within the sensor's range. stats.time to the hundredth; "1 vehicle". - The gallery thumbnail, and the old nav_fog_ghost address as a redirect to the document.
transfix
force-pushed
the
feat/ariadne-nav-fog-ghost
branch
from
November 27, 2026 08:37
7f8f7dc to
3c4f358
Compare
transfix
added a commit
that referenced
this pull request
Nov 27, 2026
…, nav_fog_ghost, nav_finale) (#1568) The rendered cvc::nav demos are Ariadne documents and hosts now: nav_city_swarm.ari and nav_city_drive.ari (the swarm and the drive as documents, faster than the programs were), nav_scrub, nav_convoy, world_lab.ari, and the fleet swarm (#1547) in the gallery. The four C++ programs that drew the swarm through cvcGL by hand go, with their nav_common and its test. Each loaded and fitted its vehicle model its own way (nav_common's load_vehicle_template), so none of them could draw the Humvee in parts (vehicle-humvee 1.0.0+cvc.5) with turning wheels; Ariadne's one vehicle look can. - examples/CMakeLists.txt: the four targets, nav_demo_common and nav_common_test gone. The wasm gallery builds nav_scrub as its only nav program; its bundle preload (the Austin scene and the shared Humvee) stays, and the trained-weights preload (CVC_WASM_NAV_WEIGHTS), which only the swarm and the drive read, goes. - The gallery (demos.json) and its thumbnails lose the three pages. deploy-pages, publish-cvcgl-wasm and publish-cvcpkg stop building, installing or expecting them; the gallery's WebGL-shim check reads nav_scrub.js in place of nav_city_drive.js; grl-snam-weights is no longer installed for the browser build (the documents fetch the policy themselves). - libcvc-examples ships the cvcGL scene demos, the three headless nav CLIs (nav_swarm_demo, nav_train_demo, nav_material_demo, which load no models and stay) and the documents; libcvc-examples-web drops grl-snam-weights. - NAV_DEMOS.md describes the documents and the CLIs; the docs and comments that pointed at the programs say they are retired. The documents' headers and vehicle_view.cpp's fitted_model comment no longer name the deleted programs or nav_common's load_vehicle_template. After #1547, the old nav_city_swarm and nav_city_drive gallery addresses redirect to the fleet swarm (nav_fleet_swarm_ari), and NAV_DEMOS.md lists it; the old nav_fog_ghost address is left to the Ariadne fog ghost (#1589).
…' retirement (#1568) demos.json: master's order and redirects (nav_city_swarm and nav_city_drive open the fleet swarm), with the fog ghost's card after nav_scrub and the old nav_fog_ghost address redirecting to its document. NAV_DEMOS.md: master's page, with a row for nav_fog_ghost.ari.
transfix
enabled auto-merge (squash)
November 28, 2026 00:42
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.
The fog-of-war "ghost" story is now an Ariadne document that arigl runs, on a 2-D map by default. It replaces the C++
nav_fog_ghost, which #1568 retires. It is in the browser gallery asnav_fog_ghost_ari, and the oldnav_fog_ghostaddress opens it.The document
examples/ariadne/documents/nav_fog_ghost.ari:What's drawn:
Controls:
--view 3d(or M) shows a perspective orbit.--scenario dynamic: an honest map and a second vehicle crossing the path.Vehicles are drawn by the swarm's agents layer (
look: humvee), which since #1569 resolves the Humvee through Ariadne's shared vehicle look; it draws arrows where no Humvee model is installed. The document loads no model itself. This branch is rebased on #1569 and doesn't touch the agents layer.Library pieces
All in the
nav_swarmnode:scene_swarm.h,swarm_nodes.h, docs/ARIADNE.md §5.4 "Swarms".New props:
arena:: an open field in metres withwalls:, andphantoms:that are only in the map the vehicles set out with (swarm_city::prior,arena_swarm_city).vehicles:: listed starts and goals, each vehicle its own target.route: belief: an 8-connected A* route over each belief plane, planned again on the worker whenever a belief flip changes some plane's map.range(sensor range) andsense_ticks(navigator steps between senses; default 4, so existing documents are unchanged).New keys:
phantomsandrange: what the next build makes.time,range,ghosts,ghosts0andreplans.New API:
SceneSwarm::belief(),ghosts(),routes()androute_cursor().sim_thread::snapshotnow carriescarrot.New and changed
swarm_layers:ghosts,plan,routeandsensor.citytakesbelief: true(the LED grid) and draws an arena's walls.pathtakes up to 1024 segments andevery:.Fixes found on the way
setTexturekeeps a copy-on-write share of the image, so the layer's laterfog.data()painted a private copy the texture never saw. The synthetic city's fog innav_city_swarm.ariwas frozen at its first paint too. The layer now paints through the pixels it took beforesetTexture, as the C++ demo did.Tests
ariadne_scene_swarm_test, 12 tests, passing five runs in a row:phantomskey;cvcgl_ariadne_swarm, 42 checks, including a new ghost section:ariadne_loader_testShippedExamplesDeclareWhatTheyNeedloads the new document.Screenshots of the map mid-story are in the session's notes (the ghost wearing away, the plan against the track). The new gallery thumbnail is
examples/web/gallery-assets/img/nav_fog_ghost_ari.jpg.arigl-web
This PR's paths don't trigger CI's arigl-web job, so I checked it locally. I built single-threaded arigl-web from this branch, against the recipe's wasm deps (as build-wasm.sh with no examples). I served it with the document and opened
index.html?src=nav_fog_ghost.ariin Chromium.data:look (cvcpkg://cy-pca/vehicle-humvee), as the world's vehicles do.Rebase
#1568 rewrites examples/nav/NAV_DEMOS.md and removes the old
nav_fog_ghostentry from demos.json. I'll rebase once it lands: the fog-ghost row becomes one row in its new "rendered demos" table, and the redirect stays.