Repository navigation
Editor: a page to select, move, turn and scale a scene's entities, with undo, driven by people or agents - #80
Merged
Merged
Conversation
…th undo, driven by people or agents editor.html opens a scene and its project. Its viewport flies, orbits and pans as Unreal's does; a click picks the exact object under it, read from the GPU's visibility buffer by a one-thread pass made only when the editor asks; a gizmo moves, turns and scales with grid and angle snapping, in world or local axes; the outliner and details panel follow the selection; every change is one undo step; drafts are kept in the browser and the scene saved to a file, written byte for byte as the bake writes it. Every action is a command in one registry, which the panels, keyboard and gizmo use and which agents call through window.solstice (and WebMCP where the browser has it): docs/editor-api.md. The scene file's map of entities now holds where the bake placed each, so the editor moves a seated model or an actor exactly. The viewer's page and the editor's share one loader, loader.js. The editor is its own wasm build, so the viewer pays nothing for it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tch late picks safely From the review: an edit tidies only the fields it changed, so the rest are saved as the file had them; a scale below 0.0001 or a position beyond 10 000 km is refused instead of drifting from what is drawn; a pick answered after its caller gave up is dropped rather than given to the next; undo waits for a drag to end; restoring a draft brings back names and notes too; the pick is read back without assuming alignment. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
What and why
The first working slice of the in-browser editor (
docs/editor.md, phase 1).editor.html?scene=NAMEopens a baked scene together with its project, and lets a person, or an agent throughwindow.solstice, select, move, turn and scale what is in it, with undo.solstice-render/src/pick.rs,shaders/editor/pick.wgsl) reads it from the visibility buffer after the frame resolves. The pass is created on the first pick and recorded only on frames that ask, so the viewer pays nothing for it. Ctrl or Shift adds to the selection..scenethrough the File System Access API, or as a download.window.solstice.call(name, args)returns{ ok, result | error }and never throws.help()gives every command's JSON Schema.navigator.modelContext), each command is also registered as a tool.docs/editor-api.md.index.htmlintoloader.js, which both pages use.editor) that onlyeditor.htmlloads.build-web.shbuilds the editor and copies anyassets/*.scene, and CI builds and lints the editor's wasm and runs its tests.docs/editor.mdare reordered, as the user asked, around building scenes and games from blank terrain: a blank scene with an in-browser bake comes next, then trees, water and weather, then placing things, then scripting and play, then sculpting. Every tool is also an agent command.No scene is converted or published here. The site's scenes carry no project yet, so on the site the editor lists each instance alone and can't save. Converting Cove and republishing it waits for the user.
Verified
Checked in Chrome on the RTX 5080, on Cove baked locally from its converted project (91 entities, 3,180 instances):
window.solstice, as an agent would:pickfails after 5 s withnot_drawinginstead of hanging.Tests:
node apps/viewer/web/editor/test.mjs(20 checks, also in CI):solstice-project/tests/fixture.rs: the crate re-writes the same fixture unchanged.a_pick_finds_the_instance_under_a_pointpicks the left, middle and right balls and the sky, and checks the depth, on the 5080.Authorship
Written by: Claude Opus 5.5 through Claude Code
Reviewed by: Claude Sonnet 5.5. Nothing blocks merging. It verified:
innerHTMLanywhere, with every name, note and log line going in as text;Fixed from its points:
Noted, not changed:
Moving a seated model sideways keeps its old height, as both editors do. Dropping it onto the ground (End) comes with the terrain tools.
Euler angles lose a fraction of a degree within 0.3° of straight up or down.
The JSON writer's exponent form differs from serde_json below 1e-5 and above 1e16, numbers the editor never makes.
A multi-selection turns and scales each entity about its own pivot.
All code, text and comments in this pull request were written by a frontier AI model, with no human-written code, and will be reviewed by a frontier AI model before merging, as the Code of Conduct requires.
🤖 Generated with Claude Code