Module material

Source
Expand description

Reusable shader handles. GPU compilation is host-owned and replacements are transactional.

ShaderMaterial::new_with_layout opts into checked, material-bound parameters. The layout describes how authored hooks read the existing u_params[4] ABI; it is not GLSL reflection. Source reloads must preserve that contract.

Structs§

MaterialFileWatcher
MaterialOptions
MaterialParameters
A fixed-size, finite parameter block tied to one material’s declared layout.
MaterialStatus
ShaderMaterial
ShaderSource

Enums§

BlendMode
CompileStatus
ParameterError
A rejected update or binding. Failures leave the parameter block and active binding intact.
ParameterType
The components a shader hook reads from one u_params slot.
ParameterValue
A typed update to one slot; MaterialParameters::set checks its type and finiteness.

Constants§

DEFAULT_FRAGMENT_HOOK
DEFAULT_VERTEX_HOOK
FRAGMENT_BODY
MAX_ERROR_BYTES
MAX_SOURCE_BYTES