浏览代码

Update EXRLoader.js

mrdoob 3 年之前
父节点
当前提交
71a8dca532
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      examples/jsm/loaders/EXRLoader.js

+ 3 - 1
examples/jsm/loaders/EXRLoader.js

@@ -1992,10 +1992,12 @@ class EXRLoader extends DataTextureLoader {
 
 			const EXRHeader = {};
 
-			if ( dataView.getUint32( 0, true ) != 20000630 ) // magic
+			if ( dataView.getUint32( 0, true ) != 20000630 ) { // magic
 
 				throw new Error( 'THREE.EXRLoader: provided file doesn\'t appear to be in OpenEXR format.' );
 
+			}
+
 			EXRHeader.version = dataView.getUint8( 4, true );
 
 			const spec = dataView.getUint8( 5, true ); // fullMask