Skip to content

feat: picking indicator - #229

Open
seankmartin wants to merge 7 commits into
masterfrom
feat/rendering-overlay
Open

seankmartin wants to merge 7 commits into
masterfrom
feat/rendering-overlay

Conversation

@seankmartin

Copy link
Copy Markdown

Overlays are intended for a very quick rendering for simple updates outside of the
regular draw loop. They are rendered as DOM elements.

Also added a title to all settings since this new setting felt it needed some
explanation and didn't want to be inconsistent

Overlays are intended for a very quick rendering for simple updates outside of the
regular draw loop. They are rendered as DOM elements.

Also added a title to all settings since this new setting felt it needed some
explanation and didn't want to be inconsistent
@seankmartin
seankmartin marked this pull request as ready for review September 17, 2026 16:25
Also clarify existing tests and check overlay draw order and disposal
@seankmartin
seankmartin marked this pull request as draft September 23, 2026 12:09
The first round of overlays were a bit muddled between the display context and rendered
data panels. And the viewer settings were also threaded through in the wrong pattern.
This aims to simplify these patterns.

Additionally fixes an issue with any clipped panels.
Shows position based on cursor but pick info based on last async pick
@seankmartin
seankmartin marked this pull request as ready for review September 24, 2026 17:54
Comment thread src/panel_overlay.ts
(visibleTopFraction +
(0.5 - (clip[1] / w) * 0.5) * visibleHeightFraction) *
logicalHeight,
focalPlaneDepthFraction: orthographic

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

potential issue: This assumes the focal plane is halfway between the clipping planes. However, PerspectivePanel clamps the near plane with Math.max(0.1, 1 - relativeDepthRange) while leaving the far plane at 1 + relativeDepthRange. Once that clamp applies, the bounds are unequal distances from focus.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some consequences are:

  • Orthographic: the ring is almost invisible at focus and brightest at the clipping midpoint.
  • Perspective: the ring disappears before reaching the far boundary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants