Browse Source

Updated builds.

Mr.doob 5 years ago
parent
commit
bd7f618c0a
3 changed files with 4 additions and 8 deletions
  1. 0 2
      build/three.js
  2. 4 4
      build/three.min.js
  3. 0 2
      build/three.module.js

+ 0 - 2
build/three.js

@@ -23896,8 +23896,6 @@
 
 			animation.stop();
 
-			this.forceContextLoss();
-
 		};
 
 		// Events

+ 4 - 4
build/three.min.js

@@ -207,10 +207,10 @@ function(a){void 0!==a&&(Q=a,this.setSize(ca,J,!1))};this.getSize=function(a){vo
 a&&(console.warn("WebGLRenderer: .getdrawingBufferSize() now requires a Vector2 as an argument"),a=new t);return a.set(ca*Q,J*Q).floor()};this.setDrawingBufferSize=function(a,b,c){ca=a;J=b;Q=c;v.width=Math.floor(a*c);v.height=Math.floor(b*c);this.setViewport(0,0,a,b)};this.getCurrentViewport=function(a){void 0===a&&(console.warn("WebGLRenderer: .getCurrentViewport() now requires a Vector4 as an argument"),a=new R);return a.copy(Z)};this.getViewport=function(a){return a.copy(fa)};this.setViewport=
 function(a,b,c,d){a.isVector4?fa.set(a.x,a.y,a.z,a.w):fa.set(a,b,c,d);X.viewport(Z.copy(fa).multiplyScalar(Q).floor())};this.getScissor=function(a){return a.copy(ka)};this.setScissor=function(a,b,c,d){a.isVector4?ka.set(a.x,a.y,a.z,a.w):ka.set(a,b,c,d);X.scissor(S.copy(ka).multiplyScalar(Q).floor())};this.getScissorTest=function(){return fg};this.setScissorTest=function(a){X.setScissorTest(fg=a)};this.setOpaqueSort=function(a){la=a};this.setTransparentSort=function(a){na=a};this.getClearColor=function(){return oa.getClearColor()};
 this.setClearColor=function(){oa.setClearColor.apply(oa,arguments)};this.getClearAlpha=function(){return oa.getClearAlpha()};this.setClearAlpha=function(){oa.setClearAlpha.apply(oa,arguments)};this.clear=function(a,b,c){var d=0;if(void 0===a||a)d|=16384;if(void 0===b||b)d|=256;if(void 0===c||c)d|=1024;I.clear(d)};this.clearColor=function(){this.clear(!0,!1,!1)};this.clearDepth=function(){this.clear(!1,!0,!1)};this.clearStencil=function(){this.clear(!1,!1,!0)};this.dispose=function(){v.removeEventListener("webglcontextlost",
-d,!1);v.removeEventListener("webglcontextrestored",e,!1);wa.dispose();va.dispose();Y.dispose();sa.dispose();ta.dispose();ya.stop();this.forceContextLoss()};this.renderBufferImmediate=function(a,b){X.initAttributes();var c=Y.get(a);a.hasPositions&&!c.position&&(c.position=I.createBuffer());a.hasNormals&&!c.normal&&(c.normal=I.createBuffer());a.hasUvs&&!c.uv&&(c.uv=I.createBuffer());a.hasColors&&!c.color&&(c.color=I.createBuffer());b=b.getAttributes();a.hasPositions&&(I.bindBuffer(34962,c.position),
-I.bufferData(34962,a.positionArray,35048),X.enableAttribute(b.position),I.vertexAttribPointer(b.position,3,5126,!1,0,0));a.hasNormals&&(I.bindBuffer(34962,c.normal),I.bufferData(34962,a.normalArray,35048),X.enableAttribute(b.normal),I.vertexAttribPointer(b.normal,3,5126,!1,0,0));a.hasUvs&&(I.bindBuffer(34962,c.uv),I.bufferData(34962,a.uvArray,35048),X.enableAttribute(b.uv),I.vertexAttribPointer(b.uv,2,5126,!1,0,0));a.hasColors&&(I.bindBuffer(34962,c.color),I.bufferData(34962,a.colorArray,35048),X.enableAttribute(b.color),
-I.vertexAttribPointer(b.color,3,5126,!1,0,0));X.disableUnusedAttributes();I.drawArrays(4,0,a.count);a.count=0};var Ga=new nb;this.renderBufferDirect=function(a,c,d,e,f,g){null===c&&(c=Ga);var h=f.isMesh&&0>f.matrixWorld.determinant(),l=x(a,c,e,f);X.setMaterial(e,h);var m=!1;if(b!==d.id||da!==l.id||Le!==(!0===e.wireframe))b=d.id,da=l.id,Le=!0===e.wireframe,m=!0;if(e.morphTargets||e.morphNormals)za.update(f,d,e,l),m=!0;a=d.index;c=d.attributes.position;if(null===a){if(void 0===c||0===c.count)return}else if(0===
-a.count)return;var u=1;!0===e.wireframe&&(a=xa.getWireframeAttribute(d),u=2);h=Aa;if(null!==a){var p=ra.get(a);h=Ca;h.setIndex(p)}if(m){if(!1!==Fa.isWebGL2||!f.isInstancedMesh&&!d.isInstancedBufferGeometry||null!==qa.get("ANGLE_instanced_arrays")){X.initAttributes();m=d.attributes;l=l.getAttributes();var k=e.defaultAttributeValues;for(ha in l){var q=l[ha];if(0<=q){var r=m[ha];if(void 0!==r){var v=r.normalized,n=r.itemSize,w=ra.get(r);if(void 0!==w){var E=w.buffer,z=w.type;w=w.bytesPerElement;if(r.isInterleavedBufferAttribute){var B=
+d,!1);v.removeEventListener("webglcontextrestored",e,!1);wa.dispose();va.dispose();Y.dispose();sa.dispose();ta.dispose();ya.stop()};this.renderBufferImmediate=function(a,b){X.initAttributes();var c=Y.get(a);a.hasPositions&&!c.position&&(c.position=I.createBuffer());a.hasNormals&&!c.normal&&(c.normal=I.createBuffer());a.hasUvs&&!c.uv&&(c.uv=I.createBuffer());a.hasColors&&!c.color&&(c.color=I.createBuffer());b=b.getAttributes();a.hasPositions&&(I.bindBuffer(34962,c.position),I.bufferData(34962,a.positionArray,
+35048),X.enableAttribute(b.position),I.vertexAttribPointer(b.position,3,5126,!1,0,0));a.hasNormals&&(I.bindBuffer(34962,c.normal),I.bufferData(34962,a.normalArray,35048),X.enableAttribute(b.normal),I.vertexAttribPointer(b.normal,3,5126,!1,0,0));a.hasUvs&&(I.bindBuffer(34962,c.uv),I.bufferData(34962,a.uvArray,35048),X.enableAttribute(b.uv),I.vertexAttribPointer(b.uv,2,5126,!1,0,0));a.hasColors&&(I.bindBuffer(34962,c.color),I.bufferData(34962,a.colorArray,35048),X.enableAttribute(b.color),I.vertexAttribPointer(b.color,
+3,5126,!1,0,0));X.disableUnusedAttributes();I.drawArrays(4,0,a.count);a.count=0};var Ga=new nb;this.renderBufferDirect=function(a,c,d,e,f,g){null===c&&(c=Ga);var h=f.isMesh&&0>f.matrixWorld.determinant(),l=x(a,c,e,f);X.setMaterial(e,h);var m=!1;if(b!==d.id||da!==l.id||Le!==(!0===e.wireframe))b=d.id,da=l.id,Le=!0===e.wireframe,m=!0;if(e.morphTargets||e.morphNormals)za.update(f,d,e,l),m=!0;a=d.index;c=d.attributes.position;if(null===a){if(void 0===c||0===c.count)return}else if(0===a.count)return;var u=
+1;!0===e.wireframe&&(a=xa.getWireframeAttribute(d),u=2);h=Aa;if(null!==a){var p=ra.get(a);h=Ca;h.setIndex(p)}if(m){if(!1!==Fa.isWebGL2||!f.isInstancedMesh&&!d.isInstancedBufferGeometry||null!==qa.get("ANGLE_instanced_arrays")){X.initAttributes();m=d.attributes;l=l.getAttributes();var k=e.defaultAttributeValues;for(ha in l){var q=l[ha];if(0<=q){var r=m[ha];if(void 0!==r){var v=r.normalized,n=r.itemSize,w=ra.get(r);if(void 0!==w){var E=w.buffer,z=w.type;w=w.bytesPerElement;if(r.isInterleavedBufferAttribute){var B=
 r.data,t=B.stride;r=r.offset;B&&B.isInstancedInterleavedBuffer?(X.enableAttributeAndDivisor(q,B.meshPerAttribute),void 0===d.maxInstancedCount&&(d.maxInstancedCount=B.meshPerAttribute*B.count)):X.enableAttribute(q);I.bindBuffer(34962,E);X.vertexAttribPointer(q,n,z,v,t*w,r*w)}else r.isInstancedBufferAttribute?(X.enableAttributeAndDivisor(q,r.meshPerAttribute),void 0===d.maxInstancedCount&&(d.maxInstancedCount=r.meshPerAttribute*r.count)):X.enableAttribute(q),I.bindBuffer(34962,E),X.vertexAttribPointer(q,
 n,z,v,0,0)}}else if("instanceMatrix"===ha)w=ra.get(f.instanceMatrix),void 0!==w&&(E=w.buffer,z=w.type,X.enableAttributeAndDivisor(q+0,1),X.enableAttributeAndDivisor(q+1,1),X.enableAttributeAndDivisor(q+2,1),X.enableAttributeAndDivisor(q+3,1),I.bindBuffer(34962,E),I.vertexAttribPointer(q+0,4,z,!1,64,0),I.vertexAttribPointer(q+1,4,z,!1,64,16),I.vertexAttribPointer(q+2,4,z,!1,64,32),I.vertexAttribPointer(q+3,4,z,!1,64,48));else if(void 0!==k&&(v=k[ha],void 0!==v))switch(v.length){case 2:I.vertexAttrib2fv(q,
 v);break;case 3:I.vertexAttrib3fv(q,v);break;case 4:I.vertexAttrib4fv(q,v);break;default:I.vertexAttrib1fv(q,v)}}}X.disableUnusedAttributes()}null!==a&&I.bindBuffer(34963,p.buffer)}var ha=d.drawRange.start*u;m=null!==g?g.start*u:0;p=Math.max(ha,m);g=Math.max(0,Math.min(null!==a?a.count:c.count,ha+d.drawRange.count*u,m+(null!==g?g.count*u:Infinity))-1-p+1);0!==g&&(f.isMesh?!0===e.wireframe?(X.setLineWidth(e.wireframeLinewidth*(null===O?Q:1)),h.setMode(1)):h.setMode(4):f.isLine?(e=e.linewidth,void 0===

+ 0 - 2
build/three.module.js

@@ -23888,8 +23888,6 @@ function WebGLRenderer( parameters ) {
 
 		animation.stop();
 
-		this.forceContextLoss();
-
 	};
 
 	// Events