Skip to main content

Module globals

Module globals 

Source
Expand description

Uniforms the built-in pipelines bind.

Three records, each advanced by whoever owns the value it carries: Camera by the camera a pass draws through, Globals by the renderer once a frame, and View by the pass that states the viewport. They are mirrored by the camera.wesl, globals.wesl and view.wesl modules of the built-in WESL package, and all three are bound as var<uniform>.

Structsยง

Camera
Camera state: the transforms a pass draws through, and the eye they imply.
Globals
Values the renderer advances once per frame.
View
What one pass frames: the region of the target its clip space covers.