Skip to main content

Module context_keys

Module context_keys 

Source
Expand description

Domain-agnostic context key types for LaneContext.

These newtypes are inserted into a LaneContext by agents and extracted by lanes. Placing them in khora-core avoids a cyclic dependency between khora-lanes and khora-agents.

§Render domain

KeyMeaning
ColorTargetTexture view to render colour into
DepthTargetTexture view for depth testing
ClearColorFramebuffer clear colour
ShadowAtlasViewShadow atlas view written by shadow lanes
ShadowComparisonSamplerPCF comparison sampler for shadow sampling

§Physics domain

KeyMeaning
PhysicsDeltaTimeFixed timestep for the current step

§Audio domain

Audio lanes consume an Arc<dyn AudioMixBus> injected directly into the LaneContext by the AudioAgent. The bus carries its own StreamInfo, so no separate context key is needed.

Structs§

ClearColor
Clear color for the current frame.
ColorTarget
Color render target for the current frame.
DepthTarget
Depth render target for the current frame.
PhysicsDeltaTime
Fixed timestep for the current physics step.
ShadowAtlasCubeView
Cube shadow atlas texture view (point lights), bound by lit shaders as texture_depth_cube_array. Written by shadow lanes after execute().
ShadowAtlasView
2D shadow atlas texture view (directional / spot lights), written by shadow lanes after execute().
ShadowComparisonSampler
Shadow comparison sampler, written by shadow lanes after execute().