|
@@ -182,9 +182,9 @@
|
|
|
|
|
|
}
|
|
|
|
|
|
- geometry.addAttribute( 'position', new THREE.Float32Attribute( positions, 3 ) );
|
|
|
- geometry.addAttribute( 'normal', new THREE.Float32Attribute( normals, 3 ) );
|
|
|
- geometry.addAttribute( 'color', new THREE.Float32Attribute( colors, 3 ) );
|
|
|
+ geometry.addAttribute( 'position', new THREE.BufferAttribute( positions, 3 ) );
|
|
|
+ geometry.addAttribute( 'normal', new THREE.BufferAttribute( normals, 3 ) );
|
|
|
+ geometry.addAttribute( 'color', new THREE.BufferAttribute( colors, 3 ) );
|
|
|
|
|
|
geometry.computeBoundingSphere();
|
|
|
|
|
@@ -204,7 +204,7 @@
|
|
|
mouse = new THREE.Vector2();
|
|
|
|
|
|
var geometry = new THREE.BufferGeometry();
|
|
|
- geometry.addAttribute( 'position', new THREE.Float32Attribute( 4 * 3, 3 ) );
|
|
|
+ geometry.addAttribute( 'position', new THREE.BufferAttribute( new Float32Array( 4 * 3 ), 3 ) );
|
|
|
|
|
|
var material = new THREE.LineBasicMaterial( { color: 0xffffff, linewidth: 2, transparent: true } );
|
|
|
|