|
@@ -6,13 +6,13 @@ THREE.Geometry2 = function ( size ) {
|
|
|
|
|
|
THREE.BufferGeometry.call( this );
|
|
|
|
|
|
- this.addAttribute( 'position', new Float32Array( size * 3 ), 3 );
|
|
|
- this.addAttribute( 'normal', new Float32Array( size * 3 ), 3 );
|
|
|
- this.addAttribute( 'uv', new Float32Array( size * 2 ), 2 );
|
|
|
+ this.vertices = new Float32Array( size * 3 );
|
|
|
+ this.normals = new Float32Array( size * 3 );
|
|
|
+ this.uvs = new Float32Array( size * 2 );
|
|
|
|
|
|
- this.vertices = this.getAttribute( 'position' ).array;
|
|
|
- this.normals = this.getAttribute( 'normal' ).array;
|
|
|
- this.uvs = this.getAttribute( 'uv' ).array;
|
|
|
+ this.addAttribute( 'position', this.vertices, 3 );
|
|
|
+ this.addAttribute( 'normal', this.normals, 3 );
|
|
|
+ this.addAttribute( 'uv', this.uvs, 2 );
|
|
|
|
|
|
this.boundingBox = null;
|
|
|
this.boundingSphere = null;
|