The default PickStrategy for general-purpose use — composes a BVHPickStrategy and (optionally) a RendererPickStrategy and routes each call to whichever backend can answer it.

Request Backend
snap-to-vertex / snap-to-edge requested AND GPU is ready GPU
filter callback supplied BVH
ray / matrix input BVH
otherwise BVH

GPU unavailable (no renderer attached, context lost, renderer not yet started) ⇒ snap requests fall through silently to BVH and the result's PickResult.snap stays null. The caller's PickResult.strategyUsed tells them what actually ran.

Constructor accepts a renderer that is not yet attached. The strategy subscribes to renderer lifecycle / context-loss events and flips an internal gpuReady flag as those transitions happen. Each transition bumps stateEpoch so memoising decorators can invalidate cached results that became stale across a state change (a result computed via BVH while the renderer was unavailable should not be served once GPU snap becomes available, for example).

dispose unwinds all subscriptions. Idempotent.

Implements

Constructors

Accessors

Methods

Constructors

Accessors

Methods