Ver código fonte

Fix GLTFExporter cachedData check

Takahiro 7 anos atrás
pai
commit
3bb7d4b975
1 arquivos alterados com 2 adições e 2 exclusões
  1. 2 2
      examples/js/exporters/GLTFExporter.js

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

@@ -396,7 +396,7 @@ THREE.GLTFExporter.prototype = {
 		 */
 		 */
 		function processImage( map ) {
 		function processImage( map ) {
 
 
-			if ( cachedData.images[ map.uuid ] ) {
+			if ( cachedData.images[ map.uuid ] !== undefined ) {
 
 
 				return cachedData.images[ map.uuid ];
 				return cachedData.images[ map.uuid ];
 
 
@@ -507,7 +507,7 @@ THREE.GLTFExporter.prototype = {
 		 */
 		 */
 		function processMaterial( material ) {
 		function processMaterial( material ) {
 
 
-			if ( cachedData.materials[ material.uuid ] ) {
+			if ( cachedData.materials[ material.uuid ] !== undefined ) {
 
 
 				return cachedData.materials[ material.uuid ];
 				return cachedData.materials[ material.uuid ];