WasmGeometryProcessor
Index
Constructors
constructor
Parameters
module: TwinfinityMeshStore
optionalblobUrl: string
Returns WasmGeometryProcessor
Accessors
publicsupportsQuantizedBatch
Returns boolean
Methods
addGeometryBuffer
Parameters
buffer: ArrayBuffer
descriptors: { hash: string; indexCount: number; vertexCount: number }[]
Returns boolean
addGeometryBufferLegacy
Parameters
buffer: ArrayBuffer
descriptors: MeshDescriptorV1[]
Returns void
clearCache
Returns void
deflate
Parameters
hash: Uint8Array<ArrayBufferLike>
maxVertexCount: number
maxIndexCount: number
isV2Format: boolean
Returns undefined | { indices: Uint32Array<ArrayBufferLike>; normals: Uint16Array<ArrayBufferLike>; positions: Float32Array<ArrayBufferLike> }
dispose
Returns void
getMemoryUsage
Returns { allocated: number; capacity: number; outputBuffers: number; used: number }
allocated: number
capacity: number
outputBuffers: number
used: number
getMeshDescriptorByHash
Parameters
hash: string
Returns undefined | MeshDescriptor
publicgetOrCreateUrlId
Parameters
indexUrl: string
Returns number
processBatchInto
Parameters
requests: MergeRequest[]
destination: ProcessBatchDestination
Returns undefined | ProcessBatchIntoResult
processBatchIntoQuantized
As processBatchInto, but the module writes normalized int16x4 positions directly, so float32 positions are never materialized. The AABB still describes the true extent.
Parameters
requests: MergeRequest[]
destination: ProcessBatchQuantizedDestination
Returns undefined | ProcessBatchIntoResult
readEdges
Parameters
binaryHash: Uint8Array<ArrayBufferLike>
Returns undefined | Uint32Array<ArrayBufferLike>
publicregisterTransforms
Parameters
url: string
transforms: readonly (undefined | TransformData)[]
Returns void
Whether the loaded module can emit int16 positions; older ones cannot, and fall back.