Skip to content

LAYER beta ​

Variable of @v12-engine/render

ts
LAYER = "\nstruct Layer {\n\t// the view and projection the frame is drawn with (jittered, as the view's pass has it)\n\tviewProjection: mat4x4f,\n\t// the same without the jitter, this frame's and the frame's before\n\tplain: mat4x4f,\n\tlast: mat4x4f,\n\t// the picture's width and height in pixels, and 1 / them\n\tsize: vec4f,\n}\n@group(0) @binding(0) var<uniform> layer: Layer;\n"

What every kind's shader of a layer begins with: the layers' group (0). A kind's own group (1) is its material's, as in the view's pass. A layer's vertex stage places a vertex as the view's does, by layer.viewProjection.