VertexFormatInfo: {
    byteSize: 2 | 4 | 8 | 12 | 16;
    bytesPerComponent: 1 | 2 | 4 | "packed";
    componentCount: 1 | 2 | 3 | 4;
    type: "float" | "unorm" | "snorm" | "uint" | "sint";
    wgslType: "f32" | "vec2<f32>" | "vec3<f32>" | "vec4<f32>" | "u32" | "vec2<u32>" | "vec3<u32>" | "vec4<u32>" | "i32" | "vec2<i32>" | "vec3<i32>" | "vec4<i32>";
}

Per-GPUVertexFormat info.

Type declaration

  • Readonly byteSize: 2 | 4 | 8 | 12 | 16

    Size in bytes.

  • Readonly bytesPerComponent: 1 | 2 | 4 | "packed"

    Number of bytes in each component.

  • Readonly componentCount: 1 | 2 | 3 | 4

    Number of components.

  • Readonly type: "float" | "unorm" | "snorm" | "uint" | "sint"

    The data encoding (float, normalized, or integer) for each component.

  • Readonly wgslType: "f32" | "vec2<f32>" | "vec3<f32>" | "vec4<f32>" | "u32" | "vec2<u32>" | "vec3<u32>" | "vec4<u32>" | "i32" | "vec2<i32>" | "vec3<i32>" | "vec4<i32>"

    The completely matching WGSL type for vertex format

Generated using TypeDoc