SceneContext Type
The scene state passed to a Draw3D.drawImmediate callback: the raw graphics device plus everything the pipeline gathered for the current frame (active camera, lights, the shadow pass output, elapsed time). Use it for fully-custom draws that need both device control and the scene data — water/refraction, screen-space effects, multi-pass.
Read-only snapshot of the frame's gather; mutate device state at your own risk (the pipeline
restores viewport + camera scope around the callback). SceneContext.Shadows
is ValueNone when no shadow-casting light exists.
Record fields
| Record Field |
Description
|
The active camera config.
|
|
|
The graphics device — bind render targets, blend/raster/depth states, issue raw draws.
|
|
The frame's accumulated lights (ambient + directional + point + spot).
|
|
The active camera's projection matrix.
|
|
The frame's shadow pass output — ValueNone when no shadow-casting light / missing DepthShadow.fx.
|
Full Usage:
Time
Field type: float32
|
Total elapsed game time, in seconds — the animation clock.
|
The active camera's view matrix.
|
Mibo