Expand description
The transparent, z-sorted scene: overlapping translucent panes composite in draw order.
The other scenes draw opaque geometry, so the only blending they exercise is the UI’s own. This scene is the one that pins the unlit pipeline’s transparent path: three translucent panes overlap, and what the middle of that overlap looks like depends on two things at once — that the draws are ordered back to front, and that the blend state frames the shader’s straight-alpha output correctly. Either one wrong changes the pixels, which is what the snapshot freezes.
The panes carry ZSortedDrawing, so the renderer draws them after the
opaque cubes and sorts them by camera distance rather than by registration
order. They are spawned in an order that is deliberately not their draw
order, so a scene that lost the sort would composite them the other way
round and fail the snapshot rather than happening to look right.
Re-exports§
use super::SceneControl;🔒use super::SceneDef;🔒use super::SceneOptions;🔒use super::TEST_SIZE;🔒use super::camera_looking_at;🔒use unlit_ecs::Bundle;🔒use unlit_ecs::DynamicBundle;🔒use unlit_ecs::bundle;🔒use unlit3d::prelude::*;🔒
Structs§
- Backdrop 🔒
- The opaque cube the panes composite over.
- Pane 🔒
- One translucent pane: the shared mesh, tinted and placed where it blends.
Constants§
- BACKDROP_
TINT 🔒 - The opaque cube behind the panes, tinted so the composite has something to blend against that is not the clear colour alone.
- CAMERA_
EYE 🔒 - How far in front of the panes the camera sits.
- CAMERA_
TARGET 🔒 - The point the camera looks at.
- PANES 🔒
- The tint of one pane, where it sits, and how far along the view direction.
Statics§
- SCENE
- The scene: opaque cubes behind three overlapping translucent panes.
Functions§
- build 🔒
- Build the transparent scene’s world content.