v++,GinstanceofTHREE.DirectionalLight&&!G.shadowCascade&&v++)}x=v;varF;if(tc&&e&&e.skeleton&&e.skeleton.useVertexTexture)F=1024;else{varT=l.getParameter(l.MAX_VERTEX_UNIFORM_VECTORS),J=Math.floor((T-20)/4);void0!==e&&einstanceofTHREE.SkinnedMesh&&(J=Math.min(e.skeleton.bones.length,J),J<e.skeleton.bones.length&&console.warn("WebGLRenderer: too many bones - "+e.skeleton.bones.length+", this GPU supports just "+J+" (try OpenGL instead of ANGLE)"));F=J}varO={precision:W,supportsVertexTextures:fc,
v++,GinstanceofTHREE.DirectionalLight&&!G.shadowCascade&&v++)}x=v;varF;if(ec&&e&&e.skeleton&&e.skeleton.useVertexTexture)F=1024;else{varT=l.getParameter(l.MAX_VERTEX_UNIFORM_VECTORS),J=Math.floor((T-20)/4);void0!==e&&einstanceofTHREE.SkinnedMesh&&(J=Math.min(e.skeleton.bones.length,J),J<e.skeleton.bones.length&&console.warn("WebGLRenderer: too many bones - "+e.skeleton.bones.length+", this GPU supports just "+J+" (try OpenGL instead of ANGLE)"));F=J}varO={precision:W,supportsVertexTextures:kc,
b;a.pointLightPosition.needsUpdate=b;a.pointLightDistance.needsUpdate=b;a.spotLightColor.needsUpdate=b;a.spotLightPosition.needsUpdate=b;a.spotLightDistance.needsUpdate=b;a.spotLightDirection.needsUpdate=b;a.spotLightAngleCos.needsUpdate=b;a.spotLightExponent.needsUpdate=b;a.hemisphereLightSkyColor.needsUpdate=b;a.hemisphereLightGroundColor.needsUpdate=b;a.hemisphereLightDirection.needsUpdate=b}functionE(){vara=Lb;a>=Lc&&console.warn("WebGLRenderer: trying to use "+a+" texture units while this GPU supports only "+
b;a.pointLightPosition.needsUpdate=b;a.pointLightDistance.needsUpdate=b;a.spotLightColor.needsUpdate=b;a.spotLightPosition.needsUpdate=b;a.spotLightDistance.needsUpdate=b;a.spotLightDirection.needsUpdate=b;a.spotLightAngleCos.needsUpdate=b;a.spotLightExponent.needsUpdate=b;a.hemisphereLightSkyColor.needsUpdate=b;a.hemisphereLightGroundColor.needsUpdate=b;a.hemisphereLightDirection.needsUpdate=b}functionE(){vara=dc;a>=Mc&&console.warn("WebGLRenderer: trying to use "+a+" texture units while this GPU supports only "+
b.__oldAnisotropy)&&(l.texParameterf(a,c.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(b.anisotropy,H.getMaxAnisotropy())),b.__oldAnisotropy=b.anisotropy)}functionR(a,b){if(a.width>b||a.height>b){varc=b/Math.max(a.width,a.height),d=document.createElement("canvas");d.width=Math.floor(a.width*c);d.height=Math.floor(a.height*c);d.getContext("2d").drawImage(a,0,0,a.width,a.height,0,0,d.width,d.height);console.log("THREE.WebGLRenderer:",a,"is too big ("+a.width+"x"+a.height+"). Resized to "+d.width+"x"+d.height+
function(){vara;returnfunction(){if(void0!==a)returna;a=[];if(sa.get("WEBGL_compressed_texture_pvrtc")||sa.get("WEBGL_compressed_texture_s3tc"))for(varb=l.getParameter(l.COMPRESSED_TEXTURE_FORMATS),c=0;c<b.length;c++)a.push(b[c]);returna}}(),bd=0<Yc.precision&&0<$c.precision,Rc=0<Zc.precision&&0<ad.precision;"highp"!==W||bd||(Rc?(W="mediump",console.warn("THREE.WebGLRenderer: highp not supported, using mediump.")):(W="lowp",console.warn("THREE.WebGLRenderer: highp and mediump not supported, using lowp.")));
"mediump"!==W||Rc||(W="lowp",console.warn("THREE.WebGLRenderer: mediump not supported, using lowp."));this.getContext=function(){returnl};this.supportsVertexTextures=function(){returnfc};this.supportsFloatTextures=function(){returnsa.get("OES_texture_float")};this.supportsStandardDerivatives=function(){returnsa.get("OES_standard_derivatives")};this.supportsCompressedTextureS3TC=function(){returnsa.get("WEBGL_compressed_texture_s3tc")};this.supportsCompressedTexturePVRTC=function(){returnsa.get("WEBGL_compressed_texture_pvrtc")};
function(){vara;returnfunction(){if(void0!==a)returna;a=[];if(sa.get("WEBGL_compressed_texture_pvrtc")||sa.get("WEBGL_compressed_texture_s3tc"))for(varb=l.getParameter(l.COMPRESSED_TEXTURE_FORMATS),c=0;c<b.length;c++)a.push(b[c]);returna}}(),dd=0<$c.precision&&0<bd.precision,Tc=0<ad.precision&&0<cd.precision;"highp"!==W||dd||(Tc?(W="mediump",console.warn("THREE.WebGLRenderer: highp not supported, using mediump.")):(W="lowp",console.warn("THREE.WebGLRenderer: highp and mediump not supported, using lowp.")));
"mediump"!==W||Tc||(W="lowp",console.warn("THREE.WebGLRenderer: mediump not supported, using lowp."));this.getContext=function(){returnl};this.supportsVertexTextures=function(){returnkc};this.supportsFloatTextures=function(){returnsa.get("OES_texture_float")};this.supportsStandardDerivatives=function(){returnsa.get("OES_standard_derivatives")};this.supportsCompressedTextureS3TC=function(){returnsa.get("WEBGL_compressed_texture_s3tc")};this.supportsCompressedTexturePVRTC=function(){returnsa.get("WEBGL_compressed_texture_pvrtc")};
b){console.warn("THREE.WebGLRenderer: .setClearColorHex() is being removed. Use .setClearColor() instead.");this.setClearColor(a,b)};this.getClearColor=function(){returnJa};this.getClearAlpha=function(){returndb};this.clear=function(a,b,c){vard=0;if(void0===a||a)d|=l.COLOR_BUFFER_BIT;if(void0===b||b)d|=l.DEPTH_BUFFER_BIT;if(void0===c||c)d|=l.STENCIL_BUFFER_BIT;l.clear(d)};this.clearColor=function(){l.clear(l.COLOR_BUFFER_BIT)};this.clearDepth=function(){l.clear(l.DEPTH_BUFFER_BIT)};this.clearStencil=
e.__webglParticleCount)}};this.render=function(a,b,c,d){if(!1===binstanceofTHREE.Camera)console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.");else{vare=a.fog;Bb=Fa=-1;Yb=null;gc=!0;!0===a.autoUpdate&&a.updateMatrixWorld();void0===b.parent&&b.updateMatrixWorld();a.traverse(function(a){ainstanceofTHREE.SkinnedMesh&&a.skeleton.update()});b.matrixWorldInverse.getInverse(b.matrixWorld);xc.multiplyMatrices(b.projectionMatrix,b.matrixWorldInverse);Bc.setFromMatrix(xc);
this.renderImmediateObject=function(a,b,c,d,e){varf=v(a,b,c,d,e);Fa=-1;H.setMaterialFaces(d);e.immediateRenderCallback?e.immediateRenderCallback(f,l,Bc):e.render(function(a){H.renderBufferImmediate(a,f,d)})};varsb={},rc=0;this.initMaterial=function(){console.warn("THREE.WebGLRenderer: .initMaterial() has been removed.")};this.setFaceCulling=function(a,b){a===THREE.CullFaceNone?l.disable(l.CULL_FACE):(b===THREE.FrontFaceDirectionCW?l.frontFace(l.CW):l.frontFace(l.CCW),a===THREE.CullFaceBack?l.cullFace(l.BACK):
e.__webglParticleCount)}};this.render=function(a,b,c,d){if(!1===binstanceofTHREE.Camera)console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.");else{vare=a.fog;Jb=Fa=-1;fc=null;gc=!0;!0===a.autoUpdate&&a.updateMatrixWorld();void0===b.parent&&b.updateMatrixWorld();a.traverse(function(a){ainstanceofTHREE.SkinnedMesh&&a.skeleton.update()});b.matrixWorldInverse.getInverse(b.matrixWorld);xc.multiplyMatrices(b.projectionMatrix,b.matrixWorldInverse);Bc.setFromMatrix(xc);
this.renderImmediateObject=function(a,b,c,d,e){varf=v(a,b,c,d,e);Fa=-1;H.setMaterialFaces(d);e.immediateRenderCallback?e.immediateRenderCallback(f,l,Bc):e.render(function(a){H.renderBufferImmediate(a,f,d)})};varBb={},sc=0;this.initMaterial=function(){console.warn("THREE.WebGLRenderer: .initMaterial() has been removed.")};this.setFaceCulling=function(a,b){a===THREE.CullFaceNone?l.disable(l.CULL_FACE):(b===THREE.FrontFaceDirectionCW?l.frontFace(l.CW):l.frontFace(l.CCW),a===THREE.CullFaceBack?l.cullFace(l.BACK):
THREE.PlaneGeometry=function(a,b,c,d){console.info("THREE.PlaneGeometry: Consider using THREE.PlaneBufferGeometry for lower memory footprint.");THREE.Geometry.call(this);this.type="PlaneGeometry";this.parameters={width:a,height:b,widthSegments:c,heightSegments:d};this.fromBufferGeometry(newTHREE.PlaneBufferGeometry(a,b,c,d))};THREE.PlaneGeometry.prototype=Object.create(THREE.Geometry.prototype);