Skip to content

explorer: show sample points over the heatmap in point mode#246

Open
rdhyee wants to merge 1 commit into
isamplesorg:mainfrom
rdhyee:feat/heatmap-show-samples-in-point-mode
Open

explorer: show sample points over the heatmap in point mode#246
rdhyee wants to merge 1 commit into
isamplesorg:mainfrom
rdhyee:feat/heatmap-show-samples-in-point-mode

Conversation

@rdhyee
Copy link
Copy Markdown
Contributor

@rdhyee rdhyee commented May 29, 2026

What

When the heatmap is on and you're zoomed to sample resolution (point mode),
show the individual sample points on top of the heatmap instead of hiding them.

Why

#242 made the heatmap mutually exclusive with both marker layers. That's
correct for cluster dots — they're an aggregate/density view, so painting
them over the heatmap gives the dots-vs-hotspots contradiction flagged
2026-05-27. But individual sample points are exact per-sample locations that
complement the density overlay (heatmap = where it's dense, dots = the actual
samples there), so hiding them at sample zoom loses useful detail.

New rule in applyLayerVisibility() (the single marker-visibility control point):

cluster zoom sample zoom (point mode)
heatmap off cluster dots sample dots
heatmap on (nothing — heatmap alone) sample dots over heatmap ← new

Scope

One-line logic change (viewer.samplePoints.show = mode === 'point') plus an
expanded rationale comment. No other paths needed:

  • loadViewportSamples() already runs under heatmap in point mode (moveEnd
    handler calls it unconditionally), so the dots are loaded and stay pan-fresh —
    this just unhides them.
  • The heatmap is a Cesium SingleTileImageryProvider on imageryLayers (globe
    surface), so sample primitives render on top of it.

quarto render explorer.qmd passes. Built on top of #242.

🤖 Generated with Claude Code

isamplesorg#242 made the heatmap mutually exclusive with both marker layers. That's
right for cluster dots (aggregated — they contradict the density view), but
individual sample points are exact per-sample locations that COMPLEMENT the
heatmap (density = where it's busy, dots = the actual samples there). So at
sample resolution (point mode) show the sample dots on top of the heatmap
instead of hiding them; cluster dots stay hidden under the heatmap as before.

One-line change in applyLayerVisibility() (the single marker-visibility
control point). loadViewportSamples() already runs under heatmap in point
mode, so the dots stay loaded and pan-fresh — this just unhides them. The
heatmap is a Cesium imagery layer (globe surface), so sample primitives
render on top of it.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.

1 participant