Преглед на файлове

Merge pull request #10881 from Mugen87/dev

DecalGeometry: Fixed index read access
Mr.doob преди 8 години
родител
ревизия
d46d7b055a
променени са 1 файла, в които са добавени 2 реда и са изтрити 2 реда
  1. 2 2
      src/geometries/DecalGeometry.js

+ 2 - 2
src/geometries/DecalGeometry.js

@@ -82,8 +82,8 @@ function DecalGeometry( mesh, position, orientation, size ) {
 
 			for ( i = 0; i < index.count; i ++ ) {
 
-				vertex.fromBufferAttribute( positionAttribute, index[ i ] );
-				normal.fromBufferAttribute( normalAttribute, index[ i ] );
+				vertex.fromBufferAttribute( positionAttribute, index.getX( i ) );
+				normal.fromBufferAttribute( normalAttribute, index.getX( i ) );
 
 				pushDecalVertex( decalVertices, vertex, normal );