Skip to content

Documentation / @sw-file-lib/three / applyBuilderOnBufferGeometry

Function: applyBuilderOnBufferGeometry() ​

ts
function applyBuilderOnBufferGeometry(builder: GeometryBuilder, buffer: BufferGeometry): void;

Defined in: geometry.ts:13

Transfers the contents of a GeometryBuilder into a THREE.BufferGeometry.

This function clears the existing attributes and groups of the buffer geometry, then copies the position, normal, color, index, and group data from the builder.

Parameters ​

ParameterTypeDescription
builderGeometryBuilderThe source geometry builder.
bufferBufferGeometryThe target buffer geometry.

Returns ​

void