Class VertexAttribute

Hierarchy

  • VertexAttribute

Constructors

Properties

arrayStride?: number

The stride, in bytes, between elements of this array.

GPUVertexBufferLayout.arrayStride

顶点数据。

format: VertexFormat

顶点数据格式。

由于提供的数据并不一定与着色器中格式一直,因此必须提供与着色器中兼容的数据格式。

offset?: number

所在顶点数据中的偏移字节数。

stepMode?: VertexStepMode

Whether each element of this array represents per-vertex data or per-instance data

GPUVertexBufferLayout.stepMode

默认 "vertex"

Methods

  • 获取顶点属性数据的字节尺寸。

    Parameters

    Returns 2 | 4 | 8 | 16 | 12

Generated using TypeDoc