Renderer · type
PassDevice
What a registered pass is handed once, at registration, to build its resources.
Explained in Hello world.
type PassDevice =import type { PassDevice } from '@driftengine/core';In depth
Backend-specific on purpose. A neutral device abstraction would be a second renderer API and an enormous one, and it would buy nothing: a package drawing Gaussian splats has a different shader, a different buffer layout and a different sort on each backend, so it branches whatever this looks like. A union makes the branch explicit and typed instead of hidden behind a lowest common denominator.
format and samples ride along on the WebGPU side because a render pipeline cannot be built
without them and a package has no other way to learn what the frame is.
depthFormat rides along for the same reason, and was missing for the same length of time
nobody depth-tested through this seam (2026-08-25). A pipeline that reads the depth buffer
cannot be built without it either, and the only contributed pass in the tree hard-coded
depth24plus with depthCompare: 'always' — invisible while a pass does not depth-test, and
wrong the first time one does. Splats are that first one: a Gaussian is composed into the
scene and has to be occluded by the geometry standing in front of it, which is a depth test
against the frame's own attachment.
What it costs: one more field every backend must answer honestly, which is the 2026-08-13 rule and not an accident. What would make it wrong: a frame with no depth attachment at all, which this renderer does not have and which would want the field to be nullable rather than absent.