1 |
- var globalObject="undefined"!=typeof global?global:"undefined"!=typeof window?window:this,babylonDependency=globalObject&&globalObject.BABYLON||BABYLON||"undefined"!=typeof require&&require("babylonjs"),BABYLON=babylonDependency,__decorate=this&&this.__decorate||function(e,t,r,i){var s,a=arguments.length,n=a<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,r):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,r,i);else for(var o=e.length-1;o>=0;o--)(s=e[o])&&(n=(a<3?s(n):a>3?s(t,r,n):s(t,r))||n);return a>3&&n&&Object.defineProperty(t,r,n),n},__extends=this&&this.__extends||(function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])};return function(t,r){function i(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(i.prototype=r.prototype,new i)}})(),BABYLON;!(function(e){var t=(function(){function t(){}return t.OBJ=function(t,r,i,s){var a=[],n=1;r&&(i||(i="mat"),a.push("mtllib "+i+".mtl"));for(var o=0;o<t.length;o++){a.push("g object"+o),a.push("o object_"+o);var u=null;if(s){var l=e.Matrix.Translation(t[o].position.x,t[o].position.y,t[o].position.z);u=e.Matrix.Translation(-t[o].position.x,-t[o].position.y,-t[o].position.z),t[o].bakeTransformIntoVertices(l)}if(r){var c=t[o].material;c&&a.push("usemtl "+c.id)}var h=t[o].geometry;if(h){var f=h.getVerticesData("position"),p=h.getVerticesData("normal"),g=h.getVerticesData("uv"),d=h.getIndices(),m=0;if(f&&p&&g&&d){for(var v=0;v<f.length;v+=3)a.push("v "+f[v]+" "+f[v+1]+" "+f[v+2]),m++;for(v=0;v<p.length;v+=3)a.push("vn "+p[v]+" "+p[v+1]+" "+p[v+2]);for(v=0;v<g.length;v+=2)a.push("vt "+g[v]+" "+g[v+1]);for(v=0;v<d.length;v+=3)a.push("f "+(d[v+2]+n)+"/"+(d[v+2]+n)+"/"+(d[v+2]+n)+" "+(d[v+1]+n)+"/"+(d[v+1]+n)+"/"+(d[v+1]+n)+" "+(d[v]+n)+"/"+(d[v]+n)+"/"+(d[v]+n));s&&u&&t[o].bakeTransformIntoVertices(u),n+=m}}}return a.join("\n")},t.MTL=function(e){var t=[],r=e.material;t.push("newmtl mat1"),t.push(" Ns "+r.specularPower.toFixed(4)),t.push(" Ni 1.5000"),t.push(" d "+r.alpha.toFixed(4)),t.push(" Tr 0.0000"),t.push(" Tf 1.0000 1.0000 1.0000"),t.push(" illum 2"),t.push(" Ka "+r.ambientColor.r.toFixed(4)+" "+r.ambientColor.g.toFixed(4)+" "+r.ambientColor.b.toFixed(4)),t.push(" Kd "+r.diffuseColor.r.toFixed(4)+" "+r.diffuseColor.g.toFixed(4)+" "+r.diffuseColor.b.toFixed(4)),t.push(" Ks "+r.specularColor.r.toFixed(4)+" "+r.specularColor.g.toFixed(4)+" "+r.specularColor.b.toFixed(4)),t.push(" Ke "+r.emissiveColor.r.toFixed(4)+" "+r.emissiveColor.g.toFixed(4)+" "+r.emissiveColor.b.toFixed(4));return r.ambientTexture&&t.push(" map_Ka "+r.ambientTexture.name),r.diffuseTexture&&t.push(" map_Kd "+r.diffuseTexture.name),r.specularTexture&&t.push(" map_Ks "+r.specularTexture.name),r.bumpTexture&&t.push(" map_bump -imfchan z "+r.bumpTexture.name),r.opacityTexture&&t.push(" map_d "+r.opacityTexture.name),t.join("\n")},t})();e.OBJExport=t})(BABYLON||(BABYLON={}));var BABYLON;!(function(e){var t=(function(){function t(){}return t.GLTF=function(t,r,i){var s=r.replace(/\.[^\/.]+$/,""),a=new e.GLTF2._Exporter(t,i);if(t.isReady)return a._generateGLTF(s);throw new Error("glTF Serializer: Scene is not ready!")},t.GLB=function(t,r,i){var s=r.replace(/\.[^\/.]+$/,""),a=new e.GLTF2._Exporter(t,i);if(t.isReady)return a._generateGLB(s);throw new Error("glTF Serializer: Scene is not ready!")},t})();e.GLTF2Export=t})(BABYLON||(BABYLON={}));var BABYLON;!(function(e){!(function(t){var r=(function(){function r(e,t){this.asset={generator:"BabylonJS",version:"2.0"},this.babylonScene=e,this.bufferViews=new Array,this.accessors=new Array,this.meshes=new Array,this.scenes=new Array,this.nodes=new Array,this.images=new Array,this.materials=new Array,this.imageData={},void 0!==t&&(this.options=t);var r=0;r=this.createScene(this.babylonScene,r),this.totalByteLength=r}return r.prototype.createBufferView=function(e,t,r,i){var s={buffer:e,byteLength:r};return t>0&&(s.byteOffset=t),i&&(s.name=i),s},r.prototype.createAccessor=function(e,t,r,i,s,a,n){var o={name:t,bufferView:e,componentType:i,count:s,type:r};return a&&(o.min=a),n&&(o.max=n),o},r.prototype.calculateMinMax=function(e,t,r,i,s){var a=[1/0,1/0,1/0],n=[-(1/0),-(1/0),-(1/0)],o=t+r;if(r>0)for(var u=t;u<o;++u)for(var l=s*u,c=0;c<s;++c)e[l]<a[c]&&(a[c]=e[l]),e[l]>n[c]&&(n[c]=e[l]),++l;return{min:a,max:n}},r.prototype.writeAttributeData=function(t,r,i,s,a,n,o){var u=a,l=r.verticesStart+r.verticesCount,c=0;switch(t){case e.VertexBuffer.PositionKind:case e.VertexBuffer.NormalKind:for(var h=r.verticesStart;h<l;++h){var f=h*s;n.setFloat32(u,i[f],!0),u+=4,n.setFloat32(u,i[f+1],!0),u+=4,o?n.setFloat32(u,i[f+2],!0):n.setFloat32(u,-i[f+2],!0),u+=4}c=12*r.verticesCount;break;case e.VertexBuffer.TangentKind:for(var h=r.indexStart;h<l;++h){var f=h*s;n.setFloat32(u,i[f],!0),u+=4,n.setFloat32(u,i[f+1],!0),u+=4,o?n.setFloat32(u,i[f+2],!0):n.setFloat32(u,-i[f+2],!0),u+=4,n.setFloat32(u,i[f+3],!0),u+=4}c=16*r.verticesCount;break;case e.VertexBuffer.ColorKind:for(var h=r.verticesStart;h<l;++h){var f=h*s;n.setFloat32(u,i[f],!0),u+=4,n.setFloat32(u,i[f+1],!0),u+=4,n.setFloat32(u,i[f+2],!0),u+=4,n.setFloat32(u,i[f+3],!0),u+=4}c=16*r.verticesCount;break;case e.VertexBuffer.UVKind:case e.VertexBuffer.UV2Kind:for(var h=r.verticesStart;h<l;++h){var f=h*s;n.setFloat32(u,i[f],!0),u+=4,n.setFloat32(u,i[f+1],!0),u+=4}c=8*r.verticesCount;break;default:throw new Error("Unsupported vertex buffer type: "+t)}return c},r.prototype.generateJSON=function(e,t,r){var i={byteLength:this.totalByteLength},s={asset:this.asset};if(i.byteLength>0&&(s.buffers=[i]),this.nodes&&0!==this.nodes.length&&(s.nodes=this.nodes),this.meshes&&0!==this.meshes.length&&(s.meshes=this.meshes),this.scenes&&0!==this.scenes.length&&(s.scenes=this.scenes,s.scene=0),this.bufferViews&&0!==this.bufferViews.length&&(s.bufferViews=this.bufferViews),this.accessors&&0!==this.accessors.length&&(s.accessors=this.accessors),this.materials&&0!==this.materials.length&&(s.materials=this.materials),this.textures&&0!==this.textures.length&&(s.textures=this.textures),this.images&&0!==this.images.length)if(e){s.images=[];for(var a=this.images.length,n=this.totalByteLength,o=0;o<a;++o){var u=this.images[o];if(void 0!==u.uri){var l=this.imageData[u.uri],c=u.uri.split(".")[0]+" image",h=this.createBufferView(0,n,l.data.length,c);n+=l.data.buffer.byteLength,this.bufferViews.push(h),u.bufferView=this.bufferViews.length-1,u.name=c,u.mimeType=l.mimeType,u.uri=void 0,s.images.push(u)}}i.byteLength=n}else s.images=this.images;return e||(i.uri=t+".bin"),r?JSON.stringify(s,null,2):JSON.stringify(s)},r.prototype._generateGLTF=function(t){var r=this.generateJSON(!1,t,!0),i=this.generateBinary(),s=new Blob([i],{type:"application/octet-stream"}),a=t+".gltf",n=t+".bin",o=new e._GLTFData;if(o.glTFFiles[a]=r,o.glTFFiles[n]=s,null!==this.imageData)for(var u in this.imageData)o.glTFFiles[u]=new Blob([this.imageData[u].data],{type:this.imageData[u].mimeType});return o},r.prototype.generateBinary=function(){var e=0,t=new ArrayBuffer(this.totalByteLength),r=new DataView(t);return e=this.createScene(this.babylonScene,e,r),t},r.prototype._getPadding=function(e){var t=e%4;return 0===t?t:4-t},r.prototype._generateGLB=function(t){var r=this.generateJSON(!0),i=this.generateBinary(),s=t+".glb",a=r.length,n=0;for(var o in this.imageData)n+=this.imageData[o].data.byteLength;var u=this._getPadding(a),l=this._getPadding(i.byteLength),c=28+a+u+i.byteLength+l+n,h=new ArrayBuffer(12),f=new DataView(h);f.setUint32(0,1179937895,!0),f.setUint32(4,2,!0),f.setUint32(8,c,!0);var p=new ArrayBuffer(8+a+u),g=new DataView(p);g.setUint32(0,a+u,!0),g.setUint32(4,1313821514,!0);for(var d=new Uint8Array(p,8),m=0;m<a;++m)d[m]=r.charCodeAt(m);for(var v=new Uint8Array(p,8+a),m=0;m<u;++m)v[m]=32;var b=new ArrayBuffer(8),x=new DataView(b);x.setUint32(0,i.byteLength+n,!0),x.setUint32(4,5130562,!0);for(var y=new ArrayBuffer(l),B=new Uint8Array(y),m=0;m<l;++m)B[m]=0;var T=[h,p,b,i];for(var o in this.imageData)T.push(this.imageData[o].data.buffer);T.push(y);var w=new Blob(T,{type:"application/octet-stream"}),A=new e._GLTFData;return A.glTFFiles[s]=w,A},r.prototype.setNodeTransformation=function(t,r,i){0===r.position.x&&0===r.position.y&&0===r.position.z||(t.translation=i?r.position.asArray():[r.position.x,r.position.y,-r.position.z]),1===r.scaling.x&&1===r.scaling.y&&1===r.scaling.z||(t.scale=i?r.scaling.asArray():[r.scaling.x,r.scaling.y,-r.scaling.z]);var s=e.Quaternion.RotationYawPitchRoll(r.rotation.y,r.rotation.x,r.rotation.z);r.rotationQuaternion&&(s=s.multiply(r.rotationQuaternion)),0===s.x&&0===s.y&&0===s.z&&1===s.w||(t.rotation=i?s.asArray():[-s.x,-s.y,s.z,s.w])},r.prototype.exportTexture=function(e,t){void 0===t&&(t="image/jpeg");var r,i=null;r={source:this.images.length};var s=e.getInternalTexture().url;if(s.search("/")!==-1){var a=s.split("/");s=a[a.length-1];var n=s.split(".")[0],o=s.split(".")[1];if("image/jpeg"===t)o=".jpg";else{if("image/png"!==t)throw new Error("Unsupported mime type "+t);o=".png"}s=n+o}var u=e.readPixels(),l=document.createElement("canvas");l.id="ImageCanvas";var c=l.getContext("2d"),h=e.getSize();l.width=h.width,l.height=h.height;var f=c.createImageData(h.width,h.height);f.data.set(u),c.putImageData(f,0,0);for(var p=l.toDataURL(t),g=atob(p.split(",")[1]),d=new Uint8Array(g.length),m=0;m<g.length;++m)d[m]=g.charCodeAt(m);var v={data:d,mimeType:t};if(this.imageData[s]=v,"image/jpeg"===t){for(var b={uri:s},x=-1,m=0;m<this.images.length;++m)if(this.images[m].uri===s){x=m;break}x===-1?(this.images.push(b),r.source=this.images.length-1,this.textures.push({source:this.images.length-1}),i={index:this.images.length-1}):(r.source=x,i={index:x})}return i},r.prototype.setPrimitiveAttributes=function(r,i,s,a,n){for(var o=0;o<i.subMeshes.length;++o){var u=null,l=i.subMeshes[o],c={attributes:{}};if(i instanceof e.Mesh?u=i:i instanceof e.InstancedMesh&&(u=i.sourceMesh),u.isVerticesDataPresent(e.VertexBuffer.PositionKind)){var h=u.getVertexBuffer(e.VertexBuffer.PositionKind),f=h.getOffset(),p=h.getData(),g=h.getStrideSize();if(n)s+=this.writeAttributeData(e.VertexBuffer.PositionKind,l,p,g,s,n,a);else{var d=12*l.verticesCount,m=this.createBufferView(0,s,d,"Positions");s+=d,this.bufferViews.push(m);var v=this.calculateMinMax(p,l.verticesStart,l.verticesCount,f,g),b=this.createAccessor(this.bufferViews.length-1,"Position","VEC3",5126,l.verticesCount,v.min,v.max);this.accessors.push(b),c.attributes.POSITION=this.accessors.length-1}}if(u.isVerticesDataPresent(e.VertexBuffer.NormalKind)){var x=u.getVertexBuffer(e.VertexBuffer.NormalKind),y=x.getData(),B=x.getStrideSize();if(n)s+=this.writeAttributeData(e.VertexBuffer.NormalKind,l,y,B,s,n,a);else{var d=12*l.verticesCount,m=this.createBufferView(0,s,d,"Normals");s+=d,this.bufferViews.push(m);var b=this.createAccessor(this.bufferViews.length-1,"Normal","VEC3",5126,l.verticesCount);this.accessors.push(b),c.attributes.NORMAL=this.accessors.length-1}}if(u.isVerticesDataPresent(e.VertexBuffer.TangentKind)){var T=u.getVertexBuffer(e.VertexBuffer.TangentKind),w=T.getData(),A=T.getStrideSize();if(n)s+=this.writeAttributeData(e.VertexBuffer.TangentKind,l,w,A,s,n,a);else{var d=16*l.verticesCount,m=this.createBufferView(0,s,d,"Tangents");s+=d,this.bufferViews.push(m);var b=this.createAccessor(this.bufferViews.length-1,"Tangent","VEC4",5126,l.verticesCount);this.accessors.push(b),c.attributes.TANGENT=this.accessors.length-1}}if(u.isVerticesDataPresent(e.VertexBuffer.ColorKind)){var V=u.getVertexBuffer(e.VertexBuffer.ColorKind),C=V.getData(),L=V.getStrideSize();if(n)s+=this.writeAttributeData(e.VertexBuffer.ColorKind,l,C,L,s,n,a);else{var d=16*l.verticesCount,m=this.createBufferView(0,s,d,"Colors");s+=d,this.bufferViews.push(m);var b=this.createAccessor(this.bufferViews.length-1,"Color","VEC4",5126,l.verticesCount);this.accessors.push(b),c.attributes.COLOR_0=this.accessors.length-1}}if(u.isVerticesDataPresent(e.VertexBuffer.UVKind)){var F=u.getVertexBuffer(e.VertexBuffer.UVKind),S=F.getData(),O=F.getStrideSize();if(n)s+=this.writeAttributeData(e.VertexBuffer.UVKind,l,S,O,s,n,a);else{var d=8*l.verticesCount,m=this.createBufferView(0,s,d,"Texture Coords0");s+=d,this.bufferViews.push(m);var b=this.createAccessor(this.bufferViews.length-1,"Texture Coords","VEC2",5126,l.verticesCount);this.accessors.push(b),c.attributes.TEXCOORD_0=this.accessors.length-1}}if(u.isVerticesDataPresent(e.VertexBuffer.UV2Kind)){var D=u.getVertexBuffer(e.VertexBuffer.UV2Kind),M=D.getData(),P=D.getStrideSize();if(n)s+=this.writeAttributeData(e.VertexBuffer.UV2Kind,l,M,P,s,n,a);else{var d=8*l.verticesCount,m=this.createBufferView(0,s,d,"Texture Coords 1");s+=d,this.bufferViews.push(m);var b=this.createAccessor(this.bufferViews.length-1,"Texture Coords","VEC2",5126,l.verticesCount);this.accessors.push(b),c.attributes.TEXCOORD_1=this.accessors.length-1}}if(u.getTotalIndices()>0)if(n){for(var N=u.getIndices(),_=l.indexStart,E=l.indexCount+_,R=s,U=_;U<E;U+=3)n.setUint32(R,N[U],!0),R+=4,n.setUint32(R,N[U+1],!0),R+=4,n.setUint32(R,N[U+2],!0),R+=4;var d=4*l.indexCount;s+=d}else{var K=l.indexCount,d=4*K,m=this.createBufferView(0,s,d,"Indices");s+=d,this.bufferViews.push(m);var b=this.createAccessor(this.bufferViews.length-1,"Indices","SCALAR",5125,K);this.accessors.push(b),c.indices=this.accessors.length-1}if(u.material)if(u.material instanceof e.StandardMaterial){var G=u.material,j={name:G.name};if(G.backFaceCulling||(j.doubleSided=!0),G.bumpTexture){var Y=this.exportTexture(G.bumpTexture);Y&&(j.normalTexture=Y)}if(G.emissiveTexture){var z=this.exportTexture(G.emissiveTexture);z&&(j.emissiveTexture=z),j.emissiveFactor=[1,1,1]}if(G.ambientTexture){var I=this.exportTexture(G.ambientTexture);I&&(j.occlusionTexture=I)}var k=t._GLTFMaterial.ConvertToGLTFPBRMetallicRoughness(G);j.pbrMetallicRoughness=k,this.materials.push(j),c.material=this.materials.length-1}else if(u.material instanceof e.PBRMetallicRoughnessMaterial){this.textures||(this.textures=new Array);var J=u.material,k={};if(J.baseColor&&(k.baseColorFactor=[J.baseColor.r,J.baseColor.g,J.baseColor.b,J.alpha]),void 0!==J.baseTexture){var Y=this.exportTexture(J.baseTexture);null!==Y&&(k.baseColorTexture=Y),k.baseColorTexture}void 0!==J.metallic&&(k.metallicFactor=J.metallic),void 0!==J.roughness&&(k.roughnessFactor=J.roughness);var j={name:J.name};if(J.doubleSided&&(j.doubleSided=J.doubleSided),J.normalTexture){var Y=this.exportTexture(J.normalTexture);Y&&(j.normalTexture=Y)}if(J.occlusionTexture){var Y=this.exportTexture(J.occlusionTexture);Y&&(j.occlusionTexture=Y,void 0!==J.occlusionStrength&&(j.occlusionTexture.strength=J.occlusionStrength))}if(J.emissiveTexture){var Y=this.exportTexture(J.emissiveTexture);null!==Y&&(j.emissiveTexture=Y)}if(J.emissiveColor.equals(new e.Color3(0,0,0))||(j.emissiveFactor=J.emissiveColor.asArray()),J.transparencyMode){var Q=t._GLTFMaterial.GetAlphaMode(J);"OPAQUE"!==Q&&(j.alphaMode=Q,"BLEND"===Q&&(j.alphaCutoff=J.alphaCutOff))}j.pbrMetallicRoughness=k,this.materials.push(j),c.material=this.materials.length-1}r.primitives.push(c)}return s},r.prototype.createScene=function(e,t,r){if(e.meshes.length>0){for(var i=e.meshes,s={nodes:new Array},a=0;a<i.length;++a)if(!this.options||void 0===this.options.shouldExportMesh||this.options.shouldExportMesh(i[a])){var n={mesh:-1},o=i[a],u=o.getScene().useRightHandedSystem;this.setNodeTransformation(n,o,u);var l={primitives:new Array};l.primitives=[],t=this.setPrimitiveAttributes(l,o,t,u,r),this.meshes.push(l),n.mesh=this.meshes.length-1,o.name&&(n.name=o.name),this.nodes.push(n),s.nodes.push(this.nodes.length-1)}this.scenes.push(s)}return t},r})();t._Exporter=r})(e.GLTF2||(e.GLTF2={}))})(BABYLON||(BABYLON={}));var BABYLON;!(function(e){var t=(function(){function e(){this.glTFFiles={}}return e.prototype.downloadFiles=function(){function e(e,t){return e.indexOf(t,e.length-t.length)!==-1}for(var t in this.glTFFiles){var r=document.createElement("a");document.body.appendChild(r),r.setAttribute("type","hidden"),r.download=t;var i=this.glTFFiles[t],s=void 0;e(t,".glb")?s={type:"model/gltf-binary"}:e(t,".bin")?s={type:"application/octet-stream"}:e(t,".gltf")?s={type:"model/gltf+json"}:e(t,".jpeg")?s={type:"image/jpeg"}:e(t,".png")&&(s={type:"image/png"}),r.href=window.URL.createObjectURL(new Blob([i],s)),r.click()}},e})();e._GLTFData=t})(BABYLON||(BABYLON={}));var BABYLON;!(function(e){!(function(t){var r=(function(){function t(){}return t.ConvertToGLTFPBRMetallicRoughness=function(r){var i={diffuse:r.diffuseColor,opacity:r.alpha,specular:r.specularColor||e.Color3.Black(),glossiness:r.specularPower/256};r.specularTexture;var s=t._ConvertToMetallicRoughness(i);return{baseColorFactor:[s.baseColor.r,s.baseColor.g,s.baseColor.b,s.opacity],metallicFactor:s.metallic,roughnessFactor:s.roughness}},t._ConvertToMetallicRoughness=function(r){var i=r.diffuse,s=r.opacity,a=r.specular,n=r.glossiness,o=1-Math.max(a.r,Math.max(a.g,a.b)),u=t.PerceivedBrightness(i),l=t.PerceivedBrightness(a),c=t.SolveMetallic(u,l,o),h=o/(1-this.dielectricSpecular.r)/Math.max(1-c,this.epsilon),f=i.scale(h),p=a.subtract(this.dielectricSpecular.scale(1-c)).scale(1/Math.max(c,this.epsilon)),g=e.Color3.Lerp(f,p,c*c),d=new e.Color3;return g.clampToRef(0,1,d),{baseColor:d,opacity:s,metallic:c,roughness:1-n}},t.PerceivedBrightness=function(e){return Math.sqrt(.299*e.r*e.r+.587*e.g*e.g+.114*e.b*e.b)},t.SolveMetallic=function(t,r,i){if(r<this.dielectricSpecular.r)return 0;var s=this.dielectricSpecular.r,a=t*i/(1-this.dielectricSpecular.r)+r-2*this.dielectricSpecular.r,n=this.dielectricSpecular.r-r,o=a*a-4*s*n;return e.Scalar.Clamp((-a+Math.sqrt(o))/(2*s))},t.GetAlphaMode=function(t){if(t instanceof e.StandardMaterial){var r=t;return 1!=r.alpha||null!=r.diffuseTexture&&r.diffuseTexture.hasAlpha||null!=r.opacityTexture?"BLEND":"OPAQUE"}if(!(t instanceof e.PBRMetallicRoughnessMaterial))throw new Error("Unsupported Babylon material type");var i=t;switch(i.transparencyMode){case e.PBRMaterial.PBRMATERIAL_OPAQUE:return"OPAQUE";case e.PBRMaterial.PBRMATERIAL_ALPHABLEND:return"BLEND";case e.PBRMaterial.PBRMATERIAL_ALPHATEST:return"MASK";case e.PBRMaterial.PBRMATERIAL_ALPHATESTANDBLEND:return console.warn("GLTF Exporter | Alpha test and blend mode not supported in glTF. Alpha blend used instead."),"BLEND";default:throw new Error("Unsupported alpha mode "+i.transparencyMode)}},t.dielectricSpecular=new e.Color3(.04,.04,.04),t.epsilon=1e-6,t})();t._GLTFMaterial=r})(e.GLTF2||(e.GLTF2={}))})(BABYLON||(BABYLON={})),(function(e,t){var r=t();e&&e.BABYLON||("object"==typeof exports&&"object"==typeof module?module.exports=r:"function"==typeof define&&define.amd?define(["BJSSerializers"],t):"object"==typeof exports?exports.BJSSerializers=r:e.BABYLON=r)})(this,(function(){return BABYLON}));
|