|
@@ -626,7 +626,7 @@ if(a===THREE.RGBA_PVRTC_4BPPV1_Format)return b.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;
|
|
|
ca=new THREE.WebGLClipping,qa=!1,va=!1,ha=new THREE.Sphere,pa=new THREE.Matrix4,W=new THREE.Vector3,S={hash:"",ambient:[0,0,0],directional:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadowMap:[],spotShadowMatrix:[],point:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[],shadows:[]},fa={calls:0,vertices:0,faces:0,points:0};this.info={render:fa,memory:{geometries:0,textures:0},programs:null};var x;try{w={alpha:w,depth:E,stencil:y,antialias:z,premultipliedAlpha:B,preserveDrawingBuffer:F};
|
|
|
x=C||u.getContext("webgl",w)||u.getContext("experimental-webgl",w);if(null===x){if(null!==u.getContext("webgl"))throw"Error creating WebGL context with your selected attributes.";throw"Error creating WebGL context.";}void 0===x.getShaderPrecisionFormat&&(x.getShaderPrecisionFormat=function(){return{rangeMin:1,rangeMax:1,precision:1}});u.addEventListener("webglcontextlost",e,!1)}catch(za){console.error("THREE.WebGLRenderer: "+za)}var U=new THREE.WebGLExtensions(x);U.get("WEBGL_depth_texture");U.get("OES_texture_float");
|
|
|
U.get("OES_texture_float_linear");U.get("OES_texture_half_float");U.get("OES_texture_half_float_linear");U.get("OES_standard_derivatives");U.get("ANGLE_instanced_arrays");U.get("OES_element_index_uint")&&(THREE.BufferGeometry.MaxIndex=4294967296);var da=new THREE.WebGLCapabilities(x,U,a),R=new THREE.WebGLState(x,U,t),Z=new THREE.WebGLProperties,ka=new THREE.WebGLTextures(x,U,R,Z,da,t,this.info),ea=new THREE.WebGLObjects(x,Z,this.info),na=new THREE.WebGLPrograms(this,da),ta=new THREE.WebGLLights;this.info.programs=
|
|
|
-na.programs;var Aa=new THREE.WebGLBufferRenderer(x,U,fa),Ba=new THREE.WebGLIndexedBufferRenderer(x,U,fa),Ca=new THREE.OrthographicCamera(-1,1,1,-1,0,1),la=new THREE.PerspectiveCamera,oa=new THREE.Mesh(new THREE.PlaneBufferGeometry(2,2),new THREE.MeshBasicMaterial({depthTest:!1,depthWrite:!1,fog:!1}));a=THREE.ShaderLib.cube;var ga=new THREE.Mesh(new THREE.BoxBufferGeometry(5,5,5,2,2,2),new THREE.ShaderMaterial({uniforms:a.uniforms,vertexShader:a.vertexShader,fragmentShader:a.fragmentShader,side:THREE.BackSide,
|
|
|
+na.programs;var Aa=new THREE.WebGLBufferRenderer(x,U,fa),Ba=new THREE.WebGLIndexedBufferRenderer(x,U,fa),Ca=new THREE.OrthographicCamera(-1,1,1,-1,0,1),la=new THREE.PerspectiveCamera,oa=new THREE.Mesh(new THREE.PlaneBufferGeometry(2,2),new THREE.MeshBasicMaterial({depthTest:!1,depthWrite:!1,fog:!1}));a=THREE.ShaderLib.cube;var ga=new THREE.Mesh(new THREE.BoxBufferGeometry(5,5,5),new THREE.ShaderMaterial({uniforms:a.uniforms,vertexShader:a.vertexShader,fragmentShader:a.fragmentShader,side:THREE.BackSide,
|
|
|
depthTest:!1,depthWrite:!1,fog:!1}));c();this.context=x;this.capabilities=da;this.extensions=U;this.properties=Z;this.state=R;var ya=new THREE.WebGLShadowMap(this,S,ea);this.shadowMap=ya;var Da=new THREE.SpritePlugin(this,M),Ea=new THREE.LensFlarePlugin(this,O);this.getContext=function(){return x};this.getContextAttributes=function(){return x.getContextAttributes()};this.forceContextLoss=function(){U.get("WEBGL_lose_context").loseContext()};this.getMaxAnisotropy=function(){return da.getMaxAnisotropy()};
|
|
|
this.getPrecision=function(){return da.precision};this.getPixelRatio=function(){return $};this.setPixelRatio=function(a){void 0!==a&&($=a,this.setSize(ma.z,ma.w,!1))};this.getSize=function(){return{width:ra,height:sa}};this.setSize=function(a,b,c){ra=a;sa=b;u.width=a*$;u.height=b*$;!1!==c&&(u.style.width=a+"px",u.style.height=b+"px");this.setViewport(0,0,a,b)};this.setViewport=function(a,b,c,d){R.viewport(ma.set(a,b,c,d))};this.setScissor=function(a,b,c,d){R.scissor(ua.set(a,b,c,d))};this.setScissorTest=
|
|
|
function(a){R.setScissorTest(xa=a)};this.getClearColor=function(){return V};this.setClearColor=function(a,c){V.set(a);Y=void 0!==c?c:1;b(V.r,V.g,V.b,Y)};this.getClearAlpha=function(){return Y};this.setClearAlpha=function(a){Y=a;b(V.r,V.g,V.b,Y)};this.clear=function(a,b,c){var d=0;if(void 0===a||a)d|=x.COLOR_BUFFER_BIT;if(void 0===b||b)d|=x.DEPTH_BUFFER_BIT;if(void 0===c||c)d|=x.STENCIL_BUFFER_BIT;x.clear(d)};this.clearColor=function(){this.clear(!0,!1,!1)};this.clearDepth=function(){this.clear(!1,
|