Skip to content

TgpuVar

  • TgpuNamable

TScope extends VariableScope = VariableScope

TDataType extends BaseData = BaseData

readonly [$gpuValueOf]: InferGPU<TDataType>

packages/typegpu/src/core/variable/tgpuVariable.ts:25


readonly [$internal]: object

optional dataType: TDataType

Makes it differentiable on the type level. Does not exist at runtime.

optional scope: TScope

Makes it differentiable on the type level. Does not exist at runtime.

packages/typegpu/src/core/variable/tgpuVariable.ts:32


$

$: InferGPU<TDataType>

packages/typegpu/src/core/variable/tgpuVariable.ts:30


readonly resourceType: "var"

packages/typegpu/src/core/variable/tgpuVariable.ts:24


value: InferGPU<TDataType>

packages/typegpu/src/core/variable/tgpuVariable.ts:29

$name(label): this

string

this

TgpuNamable.$name

packages/typegpu/src/shared/meta.ts:97