Bladeren bron

GLTFExporter: Fixed accessor reference.

Mr.doob 4 jaren geleden
bovenliggende
commit
9d8ed2778e
2 gewijzigde bestanden met toevoegingen van 2 en 2 verwijderingen
  1. 1 1
      examples/js/exporters/GLTFExporter.js
  2. 1 1
      examples/jsm/exporters/GLTFExporter.js

+ 1 - 1
examples/js/exporters/GLTFExporter.js

@@ -899,7 +899,7 @@ THREE.GLTFExporter = ( function () {
 
 			};
 
-			if ( attribute.normalized === true ) gltfAccessor.normalized = true;
+			if ( attribute.normalized === true ) accessorDef.normalized = true;
 			if ( ! json.accessors ) json.accessors = [];
 
 			return json.accessors.push( accessorDef ) - 1;

+ 1 - 1
examples/jsm/exporters/GLTFExporter.js

@@ -922,7 +922,7 @@ var GLTFExporter = ( function () {
 
 			};
 
-			if ( attribute.normalized === true ) gltfAccessor.normalized = true;
+			if ( attribute.normalized === true ) accessorDef.normalized = true;
 			if ( ! json.accessors ) json.accessors = [];
 
 			return json.accessors.push( accessorDef ) - 1;