An Input is an object used to pass data from the CPU to the GPU either via uniforms or storages.

interface Input {
    type: string;
    onBeforeUpdate?: (() => void);
    value: InputValue;
}

Hierarchy (view full)

Properties

type: string

InputBase type - could be 'f32', 'vec2f', etc.

onBeforeUpdate?: (() => void)

callback to run before updating the binding using this InputBase

Type declaration

    • (): void
    • callback to run before updating the binding using this InputBase

      Returns void

value: InputValue

The Input value