TgpuBindGroupLayout
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:160
Extends
Section titled “Extends”TgpuNamable
Type Parameters
Section titled “Type Parameters”• Entries extends Record
<string
, TgpuLayoutEntry
| null
> = Record
<string
, TgpuLayoutEntry
| null
>
Properties
Section titled “Properties”[$internal]
Section titled “[$internal]”
readonly
[$internal]:true
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:166
$
readonly
$: { [K in string | number | symbol]: InferLayoutEntry<Entries[K]> }
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:175
readonly
bound: { [K in string | number | symbol]: BindLayoutEntry<Entries[K]> }
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:169
entries
Section titled “entries”
readonly
entries:Entries
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:168
readonly
index:undefined
|number
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:184
An explicit numeric index assigned to this bind group layout. If undefined, a unique
index is assigned automatically during resolution. This can be changed with the
.$idx()
method.
resourceType
Section titled “resourceType”
readonly
resourceType:"bind-group-layout"
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:167
readonly
value: { [K in string | number | symbol]: InferLayoutEntry<Entries[K]> }
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:172
Methods
Section titled “Methods”$idx()
Section titled “$idx()”$idx(
index
?):this
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:192
Associates this bind group layout with an explicit numeric index. When a call to this method is omitted, a unique numeric index is assigned to it automatically.
Used when generating WGSL code: @group(${index}) @binding(...) ...;
Parameters
Section titled “Parameters”index?
Section titled “index?”number
Returns
Section titled “Returns”this
$name()
Section titled “$name()”$name(
label
):this
Defined in: packages/typegpu/src/shared/meta.ts:83
Parameters
Section titled “Parameters”string
Returns
Section titled “Returns”this
Inherited from
Section titled “Inherited from”TgpuNamable.$name
unwrap()
Section titled “unwrap()”unwrap(
unwrapper
):GPUBindGroupLayout
Defined in: packages/typegpu/src/tgpuBindGroupLayout.ts:199
Creates a raw WebGPU resource based on the typed descriptor.
NOTE: This creates a new resource every time, better to use root.unwrap(...)
instead.
Parameters
Section titled “Parameters”unwrapper
Section titled “unwrapper”Unwrapper
Used to unwrap any resources that this resource depends on.
Returns
Section titled “Returns”GPUBindGroupLayout