Function createMeshFromData
-
createMeshFromData( engine: EngineContext, name: string, positions: Float32Array, normals: Float32Array, indices: Uint32Array, uvs?: Float32Array<ArrayBufferLike>, uvs2?: Float32Array<ArrayBufferLike>, tangents?: Float32Array<ArrayBufferLike>, colors?: Float32Array<ArrayBufferLike>,): Mesh
Parameters
- engine: EngineContext
- name: string
- positions: Float32Array
- normals: Float32Array
- indices: Uint32Array
Optionaluvs: Float32Array<ArrayBufferLike>
Optionaluvs2: Float32Array<ArrayBufferLike>
Optionaltangents: Float32Array<ArrayBufferLike>
Optionalcolors: Float32Array<ArrayBufferLike>
Create a Mesh from raw geometry data + GPU device. No material is assigned — the caller must set mesh.material before adding to scene.