feat(cursor): extrude the cursor along the screen normal - #686
Closed
EtienneLescot wants to merge 4 commits into
Closed
EtienneLescot wants to merge 4 commits into
EtienneLescot wants to merge 4 commits into
Conversation
Give the cursor a thickness, off by default (cursor.volume 0..1). - Shader mode 13 (HLSL, MSL, WGSL) extrudes the sprite by repetition: mb.xy carries the extrusion vector, mb.z the tap count. Taps <= 1 keep the flat branch, so volume 0 renders byte-identically to main. - The extrusion vector is the plane normal rotated by the zoom rotation, projected and scaled by the thickness; on a flat screen it fades to a 3 px bottom-right offset (for a 34 px sprite). - With volume on, a flat screen routes the cursor through mode 13 on an identity quad, which lands on mode 7's rectangle. - A contact shadow (mode 12) sits under the tip, radius capped at 0.8x the half-side so the inset quad never flips. - CursorPlan carries the extrusion and the shadow; the sprite and shadow constant buffers are now built once in frame_geometry for all three backends. - Setting plumbed through CursorVisualSettings, editor settings, style presets (old presets read as 0), SceneCursor, scene.rs (serde default 0), LiveParams and the cursorVolume native param; "3D Depth" slider in the cursor pane, disabled with a tooltip while the cursor is hidden.
At the default size, iso extrudes ~37 px in 4K but the tap count was capped at 16, so the side faces showed steps ~2.5 px apart. Raise the cap to 48 in the Rust constant and in the HLSL, MSL and WGSL loop bounds. The tap count still follows |e|, and taps <= 1 is unchanged.
Contributor
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This was referenced Sep 16, 2026
Collaborator
Author
EtienneLescot
added a commit
that referenced
this pull request
Sep 17, 2026
Superseded later in this series by the modelled 3D cursor. Formerly #686.
EtienneLescot
added a commit
that referenced
this pull request
Sep 17, 2026
Superseded later in this series by the modelled 3D cursor. Formerly #686.
EtienneLescot
added a commit
that referenced
this pull request
Sep 17, 2026
Superseded later in this series by the modelled 3D cursor. Formerly #686.
EtienneLescot
added a commit
that referenced
this pull request
Sep 17, 2026
Superseded later in this series by the modelled 3D cursor. Formerly #686.
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.
3D cursor: the cursor gains volume and presses into the tilted screen. Off by default.
Chantier 3D, PR 3. Spec complète et branche d intégration : #682.
🤖 Generated with Claude Code