Documentation / device / PBBuiltinScope
Class: PBBuiltinScope
Defined in: libs/device/src/builder/programbuilder.ts:3324
The builtin scope of a shader
Extends
Indexable
[
props:string]:any
Constructors
Constructor
new PBBuiltinScope():
PBBuiltinScope
Defined in: libs/device/src/builder/programbuilder.ts:3350
Returns
PBBuiltinScope
Properties
position
position:
PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3325
pointSize
pointSize:
number|PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3326
fragDepth
fragDepth:
number|PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3327
fragCoord
readonlyfragCoord:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3328
frontFacing
readonlyfrontFacing:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3329
vertexIndex
readonlyvertexIndex:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3330
instanceIndex
readonlyinstanceIndex:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3331
localInvocationId
readonlylocalInvocationId:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3332
globalInvocationId
readonlyglobalInvocationId:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3333
workGroupId
readonlyworkGroupId:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3334
numWorkGroups
readonlynumWorkGroups:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3335
sampleMaskIn
readonlysampleMaskIn:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3336
sampleMaskOut
sampleMaskOut:
PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3337
sampleIndex
readonlysampleIndex:PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:3338
Accessors
$thisProxy
Get Signature
get $thisProxy():
T
Defined in: libs/device/src/builder/base.ts:133
Returns
T
Inherited from
$builder
Get Signature
get $builder():
ProgramBuilder
Defined in: libs/device/src/builder/programbuilder.ts:2884
Get the program builder
Returns
Inherited from
$builtins
Get Signature
get $builtins():
PBBuiltinScope
Defined in: libs/device/src/builder/programbuilder.ts:2888
Returns the scope of the builtin variables
Returns
PBBuiltinScope
Inherited from
$inputs
Get Signature
get $inputs():
PBInputScope
Defined in: libs/device/src/builder/programbuilder.ts:2892
Returns the scope of the input variables
Returns
Inherited from
$outputs
Get Signature
get $outputs():
PBOutputScope
Defined in: libs/device/src/builder/programbuilder.ts:2896
Returns the scope of the output variables
Returns
Inherited from
$l
Get Signature
get $l():
PBLocalScope
Defined in: libs/device/src/builder/programbuilder.ts:2924
Get the current local scope
Returns
Inherited from
$g
Get Signature
get $g():
PBGlobalScope
Defined in: libs/device/src/builder/programbuilder.ts:2928
Get the global scope
Returns
Inherited from
Methods
$getVertexAttrib()
$getVertexAttrib(
semantic):PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:2920
Get the input vertex attribute by specified semantic
Parameters
semantic
The vertex semantic
Returns
The input vertex attribute or null if not exists
Remarks
Can only be called only in vertex shader
Inherited from
$query()
$query(
name):PBShaderExp
Defined in: libs/device/src/builder/programbuilder.ts:2946
Query the global variable by the name
Parameters
name
string
Name of the variable
Returns
The variable or null if not exists