|
@@ -179,9 +179,11 @@
|
|
|
|
|
|
}
|
|
|
|
|
|
- geometry.addAttribute( 'position', new THREE.BufferAttribute( positions, 3 ) );
|
|
|
- geometry.addAttribute( 'normal', new THREE.BufferAttribute( normals, 3 ) );
|
|
|
- geometry.addAttribute( 'color', new THREE.BufferAttribute( colors, 3 ) );
|
|
|
+ function disposeArray() { this.array = null; }
|
|
|
+
|
|
|
+ geometry.addAttribute( 'position', new THREE.BufferAttribute( positions, 3 ).onUpload( disposeArray ) );
|
|
|
+ geometry.addAttribute( 'normal', new THREE.BufferAttribute( normals, 3 ).onUpload( disposeArray ) );
|
|
|
+ geometry.addAttribute( 'color', new THREE.BufferAttribute( colors, 3 ).onUpload( disposeArray ) );
|
|
|
|
|
|
geometry.computeBoundingSphere();
|
|
|
|