VertexAttr
Interface in Reflection
One @location-attributed parameter of the module's @vertex entry point.
import type { VertexAttr } from 'typeshade'
The signature, the description and the examples come from the compiler's own source at commit 26de7be8.
Syntax
interface VertexAttr { readonly name: string; readonly location: number; readonly type: string; readonly offset: number;}Description
Attributes
are listed in the order the entry function declares its parameters, and offset comes
from walking them in that order and rounding each one up to its own type’s std430
alignment. The layout follows the parameter order, so reordering the entry’s parameters
changes every later attribute’s offset. type is the DSL type key (the string
typeKey returns), the same spelling StructLayout.fields[].type uses.
Instance properties
nameread onlystringlocationread onlynumbertyperead onlystringoffsetread onlynumber
See also
Source
src/core/reflect.ts, line 477, at commit 26de7be8