898 B
898 B
Shader Package Contract
Each shader package lives under shaders/<id>/ and includes:
shader.jsonshader.slang
Manifest fields
shader.json defines:
idnamedescriptioncategoryentryPointparameters
Supported parameter types:
floatvec2colorboolenum
Slang contract
The runtime owns the fragment entry point, video decode, and final mix/bypass behavior.
Your shader.slang file implements:
float4 shadeVideo(ShaderContext context)
{
return context.sourceColor;
}
Available built-ins through ShaderContext:
uvsourceColorinputResolutionoutputResolutiontimeframeCountmixAmountbypass
Manifest parameters are exposed to the shader as globals named by their id.
Helper function:
sampleVideo(float2 uv)returns decoded RGBA video from the live DeckLink input.