Browse Source

Merge remote-tracking branch 'remotes/mrdoob/dev' into dev

alteredq 13 years ago
parent
commit
d073c4b68a
100 changed files with 100 additions and 355 deletions
  1. 2 2
      README.md
  2. 0 254
      build/custom/ThreeCanvas.js
  3. 1 1
      build/three.min.js
  4. 1 1
      examples/canvas_ascii_effect.html
  5. 1 2
      examples/canvas_camera_orthographic.html
  6. 1 1
      examples/canvas_camera_orthographic2.html
  7. 1 1
      examples/canvas_geometry_birds.html
  8. 1 1
      examples/canvas_geometry_cube.html
  9. 1 1
      examples/canvas_geometry_earth.html
  10. 1 1
      examples/canvas_geometry_hierarchy.html
  11. 1 1
      examples/canvas_geometry_panorama.html
  12. 1 1
      examples/canvas_geometry_panorama_fisheye.html
  13. 1 1
      examples/canvas_geometry_terrain.html
  14. 1 1
      examples/canvas_geometry_text.html
  15. 1 1
      examples/canvas_interactive_cubes.html
  16. 1 1
      examples/canvas_interactive_cubes_tween.html
  17. 1 1
      examples/canvas_interactive_particles.html
  18. 1 1
      examples/canvas_interactive_voxelpainter.html
  19. 1 1
      examples/canvas_lights_pointlights.html
  20. 1 1
      examples/canvas_lights_pointlights_smooth.html
  21. 1 1
      examples/canvas_lines.html
  22. 1 1
      examples/canvas_lines_sphere.html
  23. 1 1
      examples/canvas_materials.html
  24. 1 1
      examples/canvas_materials_depth.html
  25. 1 1
      examples/canvas_materials_normal.html
  26. 1 1
      examples/canvas_materials_reflection.html
  27. 1 1
      examples/canvas_materials_video.html
  28. 1 1
      examples/canvas_particles_floor.html
  29. 1 1
      examples/canvas_particles_random.html
  30. 1 1
      examples/canvas_particles_shapes.html
  31. 1 1
      examples/canvas_particles_sprites.html
  32. 1 1
      examples/canvas_particles_waves.html
  33. 1 1
      examples/canvas_performance.html
  34. 1 1
      examples/canvas_sandbox.html
  35. 1 1
      examples/misc_camera_fly.html
  36. 1 1
      examples/misc_camera_orbit.html
  37. 1 1
      examples/misc_camera_path.html
  38. 1 1
      examples/misc_camera_roll.html
  39. 1 1
      examples/misc_camera_trackball.html
  40. 1 1
      examples/misc_lights_test.html
  41. 1 1
      examples/misc_lookat.html
  42. 1 1
      examples/misc_software.html
  43. 1 1
      examples/misc_sound.html
  44. 1 1
      examples/misc_ubiquity_test.html
  45. 1 1
      examples/misc_uv_tests.html
  46. 1 1
      examples/webgl_animation_cloth.html
  47. 1 1
      examples/webgl_animation_skinning.html
  48. 1 1
      examples/webgl_camera.html
  49. 1 1
      examples/webgl_custom_attributes.html
  50. 1 1
      examples/webgl_custom_attributes_lines.html
  51. 1 1
      examples/webgl_custom_attributes_particles.html
  52. 1 1
      examples/webgl_custom_attributes_particles2.html
  53. 1 1
      examples/webgl_custom_attributes_particles3.html
  54. 1 1
      examples/webgl_geometries.html
  55. 1 1
      examples/webgl_geometries2.html
  56. 1 1
      examples/webgl_geometry_colors.html
  57. 1 1
      examples/webgl_geometry_colors_blender.html
  58. 1 1
      examples/webgl_geometry_convex.html
  59. 1 1
      examples/webgl_geometry_cube.html
  60. 1 1
      examples/webgl_geometry_dynamic.html
  61. 1 1
      examples/webgl_geometry_extrude_shapes.html
  62. 1 1
      examples/webgl_geometry_extrude_splines.html
  63. 1 1
      examples/webgl_geometry_extrude_uvs2.html
  64. 1 1
      examples/webgl_geometry_hierarchy.html
  65. 1 1
      examples/webgl_geometry_hierarchy2.html
  66. 1 1
      examples/webgl_geometry_large_mesh.html
  67. 1 1
      examples/webgl_geometry_minecraft.html
  68. 1 1
      examples/webgl_geometry_minecraft_ao.html
  69. 1 1
      examples/webgl_geometry_shapes.html
  70. 1 1
      examples/webgl_geometry_subdivison.html
  71. 1 1
      examples/webgl_geometry_terrain.html
  72. 1 1
      examples/webgl_geometry_terrain_fog.html
  73. 1 1
      examples/webgl_geometry_tessellation.html
  74. 1 1
      examples/webgl_geometry_text.html
  75. 1 1
      examples/webgl_hdr.html
  76. 1 1
      examples/webgl_interactive_cubes.html
  77. 1 1
      examples/webgl_interactive_cubes_gpu.html
  78. 1 1
      examples/webgl_interactive_draggablecubes.html
  79. 1 1
      examples/webgl_interactive_voxelpainter.html
  80. 1 1
      examples/webgl_kinect.html
  81. 1 1
      examples/webgl_lensflares.html
  82. 1 1
      examples/webgl_lights_pointlights.html
  83. 1 1
      examples/webgl_lights_pointlights2.html
  84. 1 1
      examples/webgl_lines_colors.html
  85. 1 1
      examples/webgl_lines_cubes.html
  86. 1 1
      examples/webgl_lines_sphere.html
  87. 1 1
      examples/webgl_lines_splines.html
  88. 1 1
      examples/webgl_loader_collada.html
  89. 1 1
      examples/webgl_loader_collada_keyframe.html
  90. 1 1
      examples/webgl_loader_ctm.html
  91. 1 1
      examples/webgl_loader_ctm_materials.html
  92. 1 1
      examples/webgl_loader_json_blender.html
  93. 1 1
      examples/webgl_loader_json_objconverter.html
  94. 1 1
      examples/webgl_loader_obj.html
  95. 1 1
      examples/webgl_loader_scene.html
  96. 1 1
      examples/webgl_loader_scene_blender.html
  97. 1 1
      examples/webgl_loader_utf8.html
  98. 1 1
      examples/webgl_loader_vtk.html
  99. 1 1
      examples/webgl_lod.html
  100. 1 1
      examples/webgl_marching_cubes.html

+ 2 - 2
README.md

@@ -10,11 +10,11 @@ The aim of the project is to create a lightweight 3D library with a very low lev
 
 
 ### Usage ###
 ### Usage ###
 
 
-Download the [minified library](http://mrdoob.github.com/three.js/build/Three.js) and include it in your html.
+Download the [minified library](http://mrdoob.github.com/three.js/build/three.min.js) and include it in your html.
 Alternatively see [how to build the library yourself](https://github.com/mrdoob/three.js/wiki/build.py,-or-how-to-generate-a-compressed-Three.js-file). 
 Alternatively see [how to build the library yourself](https://github.com/mrdoob/three.js/wiki/build.py,-or-how-to-generate-a-compressed-Three.js-file). 
 
 
 ```html
 ```html
-<script src="js/Three.js"></script>
+<script src="js/three.min.js"></script>
 ```
 ```
 
 
 This code creates a scene, then creates a camera, adds the camera and cube to the scene, creates a &lt;canvas&gt; renderer and adds its viewport in the document.body element.
 This code creates a scene, then creates a camera, adds the camera and cube to the scene, creates a &lt;canvas&gt; renderer and adds its viewport in the document.body element.

+ 0 - 254
build/custom/ThreeCanvas.js

@@ -1,254 +0,0 @@
-// ThreeCanvas.js - http://github.com/mrdoob/three.js
-'use strict';var THREE=THREE||{REVISION:"50dev"};self.console||(self.console={info:function(){},log:function(){},debug:function(){},warn:function(){},error:function(){}});self.Int32Array||(self.Int32Array=Array,self.Float32Array=Array);
-(function(){for(var a=0,b=["ms","moz","webkit","o"],c=0;c<b.length&&!window.requestAnimationFrame;++c){window.requestAnimationFrame=window[b[c]+"RequestAnimationFrame"];window.cancelAnimationFrame=window[b[c]+"CancelAnimationFrame"]||window[b[c]+"CancelRequestAnimationFrame"]}if(!window.requestAnimationFrame)window.requestAnimationFrame=function(b){var c=Date.now(),e=Math.max(0,16-(c-a)),g=window.setTimeout(function(){b(c+e)},e);a=c+e;return g};if(!window.cancelAnimationFrame)window.cancelAnimationFrame=
-function(a){clearTimeout(a)}})();THREE.FrontSide=0;THREE.BackSide=1;THREE.DoubleSide=2;THREE.NoShading=0;THREE.FlatShading=1;THREE.SmoothShading=2;THREE.NoColors=0;THREE.FaceColors=1;THREE.VertexColors=2;THREE.NoBlending=0;THREE.NormalBlending=1;THREE.AdditiveBlending=2;THREE.SubtractiveBlending=3;THREE.MultiplyBlending=4;THREE.CustomBlending=5;THREE.AddEquation=100;THREE.SubtractEquation=101;THREE.ReverseSubtractEquation=102;THREE.ZeroFactor=200;THREE.OneFactor=201;THREE.SrcColorFactor=202;
-THREE.OneMinusSrcColorFactor=203;THREE.SrcAlphaFactor=204;THREE.OneMinusSrcAlphaFactor=205;THREE.DstAlphaFactor=206;THREE.OneMinusDstAlphaFactor=207;THREE.DstColorFactor=208;THREE.OneMinusDstColorFactor=209;THREE.SrcAlphaSaturateFactor=210;THREE.MultiplyOperation=0;THREE.MixOperation=1;THREE.UVMapping=function(){};THREE.CubeReflectionMapping=function(){};THREE.CubeRefractionMapping=function(){};THREE.SphericalReflectionMapping=function(){};THREE.SphericalRefractionMapping=function(){};
-THREE.RepeatWrapping=1E3;THREE.ClampToEdgeWrapping=1001;THREE.MirroredRepeatWrapping=1002;THREE.NearestFilter=1003;THREE.NearestMipMapNearestFilter=1004;THREE.NearestMipMapLinearFilter=1005;THREE.LinearFilter=1006;THREE.LinearMipMapNearestFilter=1007;THREE.LinearMipMapLinearFilter=1008;THREE.UnsignedByteType=1009;THREE.ByteType=1010;THREE.ShortType=1011;THREE.UnsignedShortType=1012;THREE.IntType=1013;THREE.UnsignedIntType=1014;THREE.FloatType=1015;THREE.UnsignedShort4444Type=1016;
-THREE.UnsignedShort5551Type=1017;THREE.UnsignedShort565Type=1018;THREE.AlphaFormat=1019;THREE.RGBFormat=1020;THREE.RGBAFormat=1021;THREE.LuminanceFormat=1022;THREE.LuminanceAlphaFormat=1023;THREE.Color=function(a){a!==void 0&&this.setHex(a);return this};
-THREE.Color.prototype={constructor:THREE.Color,r:1,g:1,b:1,copy:function(a){this.r=a.r;this.g=a.g;this.b=a.b;return this},copyGammaToLinear:function(a){this.r=a.r*a.r;this.g=a.g*a.g;this.b=a.b*a.b;return this},copyLinearToGamma:function(a){this.r=Math.sqrt(a.r);this.g=Math.sqrt(a.g);this.b=Math.sqrt(a.b);return this},convertGammaToLinear:function(){var a=this.r,b=this.g,c=this.b;this.r=a*a;this.g=b*b;this.b=c*c;return this},convertLinearToGamma:function(){this.r=Math.sqrt(this.r);this.g=Math.sqrt(this.g);
-this.b=Math.sqrt(this.b);return this},setRGB:function(a,b,c){this.r=a;this.g=b;this.b=c;return this},setHSV:function(a,b,c){var d,f,e;if(c===0)this.r=this.g=this.b=0;else{d=Math.floor(a*6);f=a*6-d;a=c*(1-b);e=c*(1-b*f);b=c*(1-b*(1-f));if(d===0){this.r=c;this.g=b;this.b=a}else if(d===1){this.r=e;this.g=c;this.b=a}else if(d===2){this.r=a;this.g=c;this.b=b}else if(d===3){this.r=a;this.g=e;this.b=c}else if(d===4){this.r=b;this.g=a;this.b=c}else if(d===5){this.r=c;this.g=a;this.b=e}}return this},setHex:function(a){a=
-Math.floor(a);this.r=(a>>16&255)/255;this.g=(a>>8&255)/255;this.b=(a&255)/255;return this},lerpSelf:function(a,b){this.r=this.r+(a.r-this.r)*b;this.g=this.g+(a.g-this.g)*b;this.b=this.b+(a.b-this.b)*b;return this},getHex:function(){return Math.floor(this.r*255)<<16^Math.floor(this.g*255)<<8^Math.floor(this.b*255)},getContextStyle:function(){return"rgb("+Math.floor(this.r*255)+","+Math.floor(this.g*255)+","+Math.floor(this.b*255)+")"},clone:function(){return(new THREE.Color).setRGB(this.r,this.g,this.b)}};
-THREE.Vector2=function(a,b){this.x=a||0;this.y=b||0};
-THREE.Vector2.prototype={constructor:THREE.Vector2,set:function(a,b){this.x=a;this.y=b;return this},copy:function(a){this.x=a.x;this.y=a.y;return this},add:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;return this},addSelf:function(a){this.x=this.x+a.x;this.y=this.y+a.y;return this},sub:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;return this},subSelf:function(a){this.x=this.x-a.x;this.y=this.y-a.y;return this},multiplyScalar:function(a){this.x=this.x*a;this.y=this.y*a;return this},divideScalar:function(a){if(a){this.x=
-this.x/a;this.y=this.y/a}else this.set(0,0);return this},negate:function(){return this.multiplyScalar(-1)},dot:function(a){return this.x*a.x+this.y*a.y},lengthSq:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.lengthSq())},normalize:function(){return this.divideScalar(this.length())},distanceTo:function(a){return Math.sqrt(this.distanceToSquared(a))},distanceToSquared:function(a){var b=this.x-a.x,a=this.y-a.y;return b*b+a*a},setLength:function(a){return this.normalize().multiplyScalar(a)},
-lerpSelf:function(a,b){this.x=this.x+(a.x-this.x)*b;this.y=this.y+(a.y-this.y)*b;return this},equals:function(a){return a.x===this.x&&a.y===this.y},isZero:function(){return this.lengthSq()<1.0E-4},clone:function(){return new THREE.Vector2(this.x,this.y)}};THREE.Vector3=function(a,b,c){this.x=a||0;this.y=b||0;this.z=c||0};
-THREE.Vector3.prototype={constructor:THREE.Vector3,set:function(a,b,c){this.x=a;this.y=b;this.z=c;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setZ:function(a){this.z=a;return this},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;return this},add:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z;return this},addSelf:function(a){this.x=this.x+a.x;this.y=this.y+a.y;this.z=this.z+a.z;return this},addScalar:function(a){this.x=this.x+a;this.y=this.y+
-a;this.z=this.z+a;return this},sub:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z;return this},subSelf:function(a){this.x=this.x-a.x;this.y=this.y-a.y;this.z=this.z-a.z;return this},multiply:function(a,b){this.x=a.x*b.x;this.y=a.y*b.y;this.z=a.z*b.z;return this},multiplySelf:function(a){this.x=this.x*a.x;this.y=this.y*a.y;this.z=this.z*a.z;return this},multiplyScalar:function(a){this.x=this.x*a;this.y=this.y*a;this.z=this.z*a;return this},divideSelf:function(a){this.x=this.x/a.x;this.y=
-this.y/a.y;this.z=this.z/a.z;return this},divideScalar:function(a){if(a){this.x=this.x/a;this.y=this.y/a;this.z=this.z/a}else this.z=this.y=this.x=0;return this},negate:function(){return this.multiplyScalar(-1)},dot:function(a){return this.x*a.x+this.y*a.y+this.z*a.z},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z},length:function(){return Math.sqrt(this.lengthSq())},lengthManhattan:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)},normalize:function(){return this.divideScalar(this.length())},
-setLength:function(a){return this.normalize().multiplyScalar(a)},lerpSelf:function(a,b){this.x=this.x+(a.x-this.x)*b;this.y=this.y+(a.y-this.y)*b;this.z=this.z+(a.z-this.z)*b;return this},cross:function(a,b){this.x=a.y*b.z-a.z*b.y;this.y=a.z*b.x-a.x*b.z;this.z=a.x*b.y-a.y*b.x;return this},crossSelf:function(a){var b=this.x,c=this.y,d=this.z;this.x=c*a.z-d*a.y;this.y=d*a.x-b*a.z;this.z=b*a.y-c*a.x;return this},distanceTo:function(a){return Math.sqrt(this.distanceToSquared(a))},distanceToSquared:function(a){return(new THREE.Vector3).sub(this,
-a).lengthSq()},getPositionFromMatrix:function(a){this.x=a.elements[12];this.y=a.elements[13];this.z=a.elements[14];return this},setEulerFromRotationMatrix:function(a,b){function c(a){return Math.min(Math.max(a,-1),1)}var d=a.elements,f=d[0],e=d[4],g=d[8],j=d[1],m=d[5],k=d[9],h=d[2],n=d[6],d=d[10];if(b===void 0||b==="XYZ"){this.y=Math.asin(c(g));if(Math.abs(g)<0.99999){this.x=Math.atan2(-k,d);this.z=Math.atan2(-e,f)}else{this.x=Math.atan2(j,m);this.z=0}}else if(b==="YXZ"){this.x=Math.asin(-c(k));if(Math.abs(k)<
-0.99999){this.y=Math.atan2(g,d);this.z=Math.atan2(j,m)}else{this.y=Math.atan2(-h,f);this.z=0}}else if(b==="ZXY"){this.x=Math.asin(c(n));if(Math.abs(n)<0.99999){this.y=Math.atan2(-h,d);this.z=Math.atan2(-e,m)}else{this.y=0;this.z=Math.atan2(g,f)}}else if(b==="ZYX"){this.y=Math.asin(-c(h));if(Math.abs(h)<0.99999){this.x=Math.atan2(n,d);this.z=Math.atan2(j,f)}else{this.x=0;this.z=Math.atan2(-e,m)}}else if(b==="YZX"){this.z=Math.asin(c(j));if(Math.abs(j)<0.99999){this.x=Math.atan2(-k,m);this.y=Math.atan2(-h,
-f)}else{this.x=0;this.y=Math.atan2(h,d)}}else if(b==="XZY"){this.z=Math.asin(-c(e));if(Math.abs(e)<0.99999){this.x=Math.atan2(n,m);this.y=Math.atan2(g,f)}else{this.x=Math.atan2(-g,d);this.y=0}}return this},setEulerFromQuaternion:function(a,b){function c(a){return Math.min(Math.max(a,-1),1)}var d=a.x*a.x,f=a.y*a.y,e=a.z*a.z,g=a.w*a.w;if(b===void 0||b==="XYZ"){this.x=Math.atan2(2*(a.x*a.w-a.y*a.z),g-d-f+e);this.y=Math.asin(c(2*(a.x*a.z+a.y*a.w)));this.z=Math.atan2(2*(a.z*a.w-a.x*a.y),g+d-f-e)}else if(b===
-"YXZ"){this.x=Math.asin(c(2*(a.x*a.w-a.y*a.z)));this.y=Math.atan2(2*(a.x*a.z+a.y*a.w),g-d-f+e);this.z=Math.atan2(2*(a.x*a.y+a.z*a.w),g-d+f-e)}else if(b==="ZXY"){this.x=Math.asin(c(2*(a.x*a.w+a.y*a.z)));this.y=Math.atan2(2*(a.y*a.w-a.z*a.x),g-d-f+e);this.z=Math.atan2(2*(a.z*a.w-a.x*a.y),g-d+f-e)}else if(b==="ZYX"){this.x=Math.atan2(2*(a.x*a.w+a.z*a.y),g-d-f+e);this.y=Math.asin(c(2*(a.y*a.w-a.x*a.z)));this.z=Math.atan2(2*(a.x*a.y+a.z*a.w),g+d-f-e)}else if(b==="YZX"){this.x=Math.atan2(2*(a.x*a.w-a.z*
-a.y),g-d+f-e);this.y=Math.atan2(2*(a.y*a.w-a.x*a.z),g+d-f-e);this.z=Math.asin(c(2*(a.x*a.y+a.z*a.w)))}else if(b==="XZY"){this.x=Math.atan2(2*(a.x*a.w+a.y*a.z),g-d+f-e);this.y=Math.atan2(2*(a.x*a.z+a.y*a.w),g+d-f-e);this.z=Math.asin(c(2*(a.z*a.w-a.x*a.y)))}return this},getScaleFromMatrix:function(a){var b=this.set(a.elements[0],a.elements[1],a.elements[2]).length(),c=this.set(a.elements[4],a.elements[5],a.elements[6]).length(),a=this.set(a.elements[8],a.elements[9],a.elements[10]).length();this.x=
-b;this.y=c;this.z=a;return this},equals:function(a){return a.x===this.x&&a.y===this.y&&a.z===this.z},isZero:function(){return this.lengthSq()<1.0E-4},clone:function(){return new THREE.Vector3(this.x,this.y,this.z)}};THREE.Vector4=function(a,b,c,d){this.x=a||0;this.y=b||0;this.z=c||0;this.w=d!==void 0?d:1};
-THREE.Vector4.prototype={constructor:THREE.Vector4,set:function(a,b,c,d){this.x=a;this.y=b;this.z=c;this.w=d;return this},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;this.w=a.w!==void 0?a.w:1;return this},add:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z;this.w=a.w+b.w;return this},addSelf:function(a){this.x=this.x+a.x;this.y=this.y+a.y;this.z=this.z+a.z;this.w=this.w+a.w;return this},sub:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z;this.w=a.w-b.w;return this},subSelf:function(a){this.x=
-this.x-a.x;this.y=this.y-a.y;this.z=this.z-a.z;this.w=this.w-a.w;return this},multiplyScalar:function(a){this.x=this.x*a;this.y=this.y*a;this.z=this.z*a;this.w=this.w*a;return this},divideScalar:function(a){if(a){this.x=this.x/a;this.y=this.y/a;this.z=this.z/a;this.w=this.w/a}else{this.z=this.y=this.x=0;this.w=1}return this},negate:function(){return this.multiplyScalar(-1)},dot:function(a){return this.x*a.x+this.y*a.y+this.z*a.z+this.w*a.w},lengthSq:function(){return this.dot(this)},length:function(){return Math.sqrt(this.lengthSq())},
-normalize:function(){return this.divideScalar(this.length())},setLength:function(a){return this.normalize().multiplyScalar(a)},lerpSelf:function(a,b){this.x=this.x+(a.x-this.x)*b;this.y=this.y+(a.y-this.y)*b;this.z=this.z+(a.z-this.z)*b;this.w=this.w+(a.w-this.w)*b;return this},clone:function(){return new THREE.Vector4(this.x,this.y,this.z,this.w)},setAxisAngleFromQuaternion:function(a){this.w=2*Math.acos(a.w);var b=Math.sqrt(1-a.w*a.w);if(b<1.0E-4){this.x=1;this.z=this.y=0}else{this.x=a.x/b;this.y=
-a.y/b;this.z=a.z/b}return this},setAxisAngleFromRotationMatrix:function(a){var b,c,d,a=a.elements,f=a[0];d=a[4];var e=a[8],g=a[1],j=a[5],m=a[9];c=a[2];b=a[6];var k=a[10];if(Math.abs(d-g)<0.01&&Math.abs(e-c)<0.01&&Math.abs(m-b)<0.01){if(Math.abs(d+g)<0.1&&Math.abs(e+c)<0.1&&Math.abs(m+b)<0.1&&Math.abs(f+j+k-3)<0.1){this.set(1,0,0,0);return this}a=Math.PI;f=(f+1)/2;j=(j+1)/2;k=(k+1)/2;d=(d+g)/4;e=(e+c)/4;m=(m+b)/4;if(f>j&&f>k)if(f<0.01){b=0;d=c=0.707106781}else{b=Math.sqrt(f);c=d/b;d=e/b}else if(j>
-k)if(j<0.01){b=0.707106781;c=0;d=0.707106781}else{c=Math.sqrt(j);b=d/c;d=m/c}else if(k<0.01){c=b=0.707106781;d=0}else{d=Math.sqrt(k);b=e/d;c=m/d}this.set(b,c,d,a);return this}a=Math.sqrt((b-m)*(b-m)+(e-c)*(e-c)+(g-d)*(g-d));Math.abs(a)<0.001&&(a=1);this.x=(b-m)/a;this.y=(e-c)/a;this.z=(g-d)/a;this.w=Math.acos((f+j+k-1)/2);return this}};
-THREE.EventTarget=function(){var a={};this.addEventListener=function(b,c){a[b]===void 0&&(a[b]=[]);a[b].indexOf(c)===-1&&a[b].push(c)};this.dispatchEvent=function(b){for(var c in a[b.type])a[b.type][c](b)};this.removeEventListener=function(b,c){var d=a[b].indexOf(c);d!==-1&&a[b].splice(d,1)}};THREE.Frustum=function(){this.planes=[new THREE.Vector4,new THREE.Vector4,new THREE.Vector4,new THREE.Vector4,new THREE.Vector4,new THREE.Vector4]};
-THREE.Frustum.prototype.setFromMatrix=function(a){var b=this.planes,c=a.elements,a=c[0],d=c[1],f=c[2],e=c[3],g=c[4],j=c[5],m=c[6],k=c[7],h=c[8],n=c[9],l=c[10],o=c[11],q=c[12],i=c[13],p=c[14],c=c[15];b[0].set(e-a,k-g,o-h,c-q);b[1].set(e+a,k+g,o+h,c+q);b[2].set(e+d,k+j,o+n,c+i);b[3].set(e-d,k-j,o-n,c-i);b[4].set(e-f,k-m,o-l,c-p);b[5].set(e+f,k+m,o+l,c+p);for(d=0;d<6;d++){a=b[d];a.divideScalar(Math.sqrt(a.x*a.x+a.y*a.y+a.z*a.z))}};
-THREE.Frustum.prototype.contains=function(a){for(var b=0,c=this.planes,b=a.matrixWorld,d=b.elements,a=-a.geometry.boundingSphere.radius*b.getMaxScaleOnAxis(),f=0;f<6;f++){b=c[f].x*d[12]+c[f].y*d[13]+c[f].z*d[14]+c[f].w;if(b<=a)return false}return true};THREE.Frustum.__v1=new THREE.Vector3;
-THREE.Ray=function(a,b,c,d){this.origin=a||new THREE.Vector3;this.direction=b||new THREE.Vector3;this.near=c||0;this.far=d||Infinity;var f=new THREE.Vector3,e=new THREE.Vector3,g=new THREE.Vector3,j=new THREE.Vector3,m=new THREE.Vector3,k=new THREE.Vector3,h=new THREE.Vector3,n=new THREE.Vector3,l=new THREE.Vector3,o=function(a,b){return a.distance-b.distance},q=new THREE.Vector3,i=new THREE.Vector3,p=new THREE.Vector3,r,u,v,B=function(a,b,c){q.sub(c,a);r=q.dot(b);u=i.add(a,p.copy(b).multiplyScalar(r));
-return v=c.distanceTo(u)},x,A,y,E,s,w,C,K,M=function(a,b,c,d){q.sub(d,b);i.sub(c,b);p.sub(a,b);x=q.dot(q);A=q.dot(i);y=q.dot(p);E=i.dot(i);s=i.dot(p);w=1/(x*E-A*A);C=(E*y-A*s)*w;K=(x*s-A*y)*w;return C>=0&&K>=0&&C+K<1},N=1.0E-4;this.setPrecision=function(a){N=a};this.intersectObject=function(a,b){var c,d=[];if(b===true)for(var i=0,q=a.children.length;i<q;i++)Array.prototype.push.apply(d,this.intersectObject(a.children[i],b));if(a instanceof THREE.Particle){v=B(this.origin,this.direction,a.matrixWorld.getPosition());
-if(v>a.scale.x)return[];c={distance:v,point:a.position,face:null,object:a};d.push(c)}else if(a instanceof THREE.Mesh){i=THREE.Frustum.__v1.set(a.matrixWorld.getColumnX().length(),a.matrixWorld.getColumnY().length(),a.matrixWorld.getColumnZ().length());i=a.geometry.boundingSphere.radius*Math.max(i.x,Math.max(i.y,i.z));v=B(this.origin,this.direction,a.matrixWorld.getPosition());if(v>i)return d;var z,p,r=a.geometry,J=r.vertices,s;a.matrixRotationWorld.extractRotation(a.matrixWorld);i=0;for(q=r.faces.length;i<
-q;i++){c=r.faces[i];m.copy(this.origin);k.copy(this.direction);s=a.matrixWorld;h=s.multiplyVector3(h.copy(c.centroid)).subSelf(m);n=a.matrixRotationWorld.multiplyVector3(n.copy(c.normal));z=k.dot(n);if(!(Math.abs(z)<N)){p=n.dot(h)/z;if(!(p<0)&&(a.doubleSided||(a.flipSided?z>0:z<0))){l.add(m,k.multiplyScalar(p));v=m.distanceTo(l);if(!(v<this.near)&&!(v>this.far))if(c instanceof THREE.Face3){f=s.multiplyVector3(f.copy(J[c.a]));e=s.multiplyVector3(e.copy(J[c.b]));g=s.multiplyVector3(g.copy(J[c.c]));
-if(M(l,f,e,g)){c={distance:v,point:l.clone(),face:c,faceIndex:i,object:a};d.push(c)}}else if(c instanceof THREE.Face4){f=s.multiplyVector3(f.copy(J[c.a]));e=s.multiplyVector3(e.copy(J[c.b]));g=s.multiplyVector3(g.copy(J[c.c]));j=s.multiplyVector3(j.copy(J[c.d]));if(M(l,f,e,j)||M(l,e,g,j)){c={distance:v,point:l.clone(),face:c,faceIndex:i,object:a};d.push(c)}}}}}}d.sort(o);return d};this.intersectObjects=function(a,b){for(var c=[],d=0,e=a.length;d<e;d++)Array.prototype.push.apply(c,this.intersectObject(a[d],
-b));c.sort(o);return c}};
-THREE.Rectangle=function(){function a(){e=d-b;g=f-c}var b=0,c=0,d=0,f=0,e=0,g=0,j=true;this.getX=function(){return b};this.getY=function(){return c};this.getWidth=function(){return e};this.getHeight=function(){return g};this.getLeft=function(){return b};this.getTop=function(){return c};this.getRight=function(){return d};this.getBottom=function(){return f};this.set=function(e,g,h,n){j=false;b=e;c=g;d=h;f=n;a()};this.addPoint=function(e,g){if(j===true){j=false;b=e;c=g;d=e;f=g}else{b=b<e?b:e;c=c<g?c:
-g;d=d>e?d:e;f=f>g?f:g}a()};this.add3Points=function(e,g,h,n,l,o){if(j===true){j=false;b=e<h?e<l?e:l:h<l?h:l;c=g<n?g<o?g:o:n<o?n:o;d=e>h?e>l?e:l:h>l?h:l;f=g>n?g>o?g:o:n>o?n:o}else{b=e<h?e<l?e<b?e:b:l<b?l:b:h<l?h<b?h:b:l<b?l:b;c=g<n?g<o?g<c?g:c:o<c?o:c:n<o?n<c?n:c:o<c?o:c;d=e>h?e>l?e>d?e:d:l>d?l:d:h>l?h>d?h:d:l>d?l:d;f=g>n?g>o?g>f?g:f:o>f?o:f:n>o?n>f?n:f:o>f?o:f}a()};this.addRectangle=function(e){if(j===true){j=false;b=e.getLeft();c=e.getTop();d=e.getRight();f=e.getBottom()}else{b=b<e.getLeft()?b:e.getLeft();
-c=c<e.getTop()?c:e.getTop();d=d>e.getRight()?d:e.getRight();f=f>e.getBottom()?f:e.getBottom()}a()};this.inflate=function(e){b=b-e;c=c-e;d=d+e;f=f+e;a()};this.minSelf=function(e){b=b>e.getLeft()?b:e.getLeft();c=c>e.getTop()?c:e.getTop();d=d<e.getRight()?d:e.getRight();f=f<e.getBottom()?f:e.getBottom();a()};this.intersects=function(a){return d<a.getLeft()||b>a.getRight()||f<a.getTop()||c>a.getBottom()?false:true};this.empty=function(){j=true;f=d=c=b=0;a()};this.isEmpty=function(){return j}};
-THREE.Math={clamp:function(a,b,c){return a<b?b:a>c?c:a},clampBottom:function(a,b){return a<b?b:a},mapLinear:function(a,b,c,d,f){return d+(a-b)*(f-d)/(c-b)},random16:function(){return(65280*Math.random()+255*Math.random())/65535},randInt:function(a,b){return a+Math.floor(Math.random()*(b-a+1))},randFloat:function(a,b){return a+Math.random()*(b-a)},randFloatSpread:function(a){return a*(0.5-Math.random())},sign:function(a){return a<0?-1:a>0?1:0}};THREE.Matrix3=function(){this.elements=new Float32Array(9)};
-THREE.Matrix3.prototype={constructor:THREE.Matrix3,getInverse:function(a){var b=a.elements,a=b[10]*b[5]-b[6]*b[9],c=-b[10]*b[1]+b[2]*b[9],d=b[6]*b[1]-b[2]*b[5],f=-b[10]*b[4]+b[6]*b[8],e=b[10]*b[0]-b[2]*b[8],g=-b[6]*b[0]+b[2]*b[4],j=b[9]*b[4]-b[5]*b[8],m=-b[9]*b[0]+b[1]*b[8],k=b[5]*b[0]-b[1]*b[4],b=b[0]*a+b[1]*f+b[2]*j;b===0&&console.warn("Matrix3.getInverse(): determinant == 0");var b=1/b,h=this.elements;h[0]=b*a;h[1]=b*c;h[2]=b*d;h[3]=b*f;h[4]=b*e;h[5]=b*g;h[6]=b*j;h[7]=b*m;h[8]=b*k;return this},
-transpose:function(){var a,b=this.elements;a=b[1];b[1]=b[3];b[3]=a;a=b[2];b[2]=b[6];b[6]=a;a=b[5];b[5]=b[7];b[7]=a;return this},transposeIntoArray:function(a){var b=this.m;a[0]=b[0];a[1]=b[3];a[2]=b[6];a[3]=b[1];a[4]=b[4];a[5]=b[7];a[6]=b[2];a[7]=b[5];a[8]=b[8];return this}};THREE.Matrix4=function(a,b,c,d,f,e,g,j,m,k,h,n,l,o,q,i){this.elements=new Float32Array(16);this.set(a!==void 0?a:1,b||0,c||0,d||0,f||0,e!==void 0?e:1,g||0,j||0,m||0,k||0,h!==void 0?h:1,n||0,l||0,o||0,q||0,i!==void 0?i:1)};
-THREE.Matrix4.prototype={constructor:THREE.Matrix4,set:function(a,b,c,d,f,e,g,j,m,k,h,n,l,o,q,i){var p=this.elements;p[0]=a;p[4]=b;p[8]=c;p[12]=d;p[1]=f;p[5]=e;p[9]=g;p[13]=j;p[2]=m;p[6]=k;p[10]=h;p[14]=n;p[3]=l;p[7]=o;p[11]=q;p[15]=i;return this},identity:function(){this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1);return this},copy:function(a){a=a.elements;this.set(a[0],a[4],a[8],a[12],a[1],a[5],a[9],a[13],a[2],a[6],a[10],a[14],a[3],a[7],a[11],a[15]);return this},lookAt:function(a,b,c){var d=this.elements,
-f=THREE.Matrix4.__v1,e=THREE.Matrix4.__v2,g=THREE.Matrix4.__v3;g.sub(a,b).normalize();if(g.length()===0)g.z=1;f.cross(c,g).normalize();if(f.length()===0){g.x=g.x+1.0E-4;f.cross(c,g).normalize()}e.cross(g,f);d[0]=f.x;d[4]=e.x;d[8]=g.x;d[1]=f.y;d[5]=e.y;d[9]=g.y;d[2]=f.z;d[6]=e.z;d[10]=g.z;return this},multiply:function(a,b){var c=a.elements,d=b.elements,f=this.elements,e=c[0],g=c[4],j=c[8],m=c[12],k=c[1],h=c[5],n=c[9],l=c[13],o=c[2],q=c[6],i=c[10],p=c[14],r=c[3],u=c[7],v=c[11],c=c[15],B=d[0],x=d[4],
-A=d[8],y=d[12],E=d[1],s=d[5],w=d[9],C=d[13],K=d[2],M=d[6],N=d[10],t=d[14],G=d[3],I=d[7],O=d[11],d=d[15];f[0]=e*B+g*E+j*K+m*G;f[4]=e*x+g*s+j*M+m*I;f[8]=e*A+g*w+j*N+m*O;f[12]=e*y+g*C+j*t+m*d;f[1]=k*B+h*E+n*K+l*G;f[5]=k*x+h*s+n*M+l*I;f[9]=k*A+h*w+n*N+l*O;f[13]=k*y+h*C+n*t+l*d;f[2]=o*B+q*E+i*K+p*G;f[6]=o*x+q*s+i*M+p*I;f[10]=o*A+q*w+i*N+p*O;f[14]=o*y+q*C+i*t+p*d;f[3]=r*B+u*E+v*K+c*G;f[7]=r*x+u*s+v*M+c*I;f[11]=r*A+u*w+v*N+c*O;f[15]=r*y+u*C+v*t+c*d;return this},multiplySelf:function(a){return this.multiply(this,
-a)},multiplyToArray:function(a,b,c){var d=this.elements;this.multiply(a,b);c[0]=d[0];c[1]=d[1];c[2]=d[2];c[3]=d[3];c[4]=d[4];c[5]=d[5];c[6]=d[6];c[7]=d[7];c[8]=d[8];c[9]=d[9];c[10]=d[10];c[11]=d[11];c[12]=d[12];c[13]=d[13];c[14]=d[14];c[15]=d[15];return this},multiplyScalar:function(a){var b=this.elements;b[0]=b[0]*a;b[4]=b[4]*a;b[8]=b[8]*a;b[12]=b[12]*a;b[1]=b[1]*a;b[5]=b[5]*a;b[9]=b[9]*a;b[13]=b[13]*a;b[2]=b[2]*a;b[6]=b[6]*a;b[10]=b[10]*a;b[14]=b[14]*a;b[3]=b[3]*a;b[7]=b[7]*a;b[11]=b[11]*a;b[15]=
-b[15]*a;return this},multiplyVector3:function(a){var b=this.elements,c=a.x,d=a.y,f=a.z,e=1/(b[3]*c+b[7]*d+b[11]*f+b[15]);a.x=(b[0]*c+b[4]*d+b[8]*f+b[12])*e;a.y=(b[1]*c+b[5]*d+b[9]*f+b[13])*e;a.z=(b[2]*c+b[6]*d+b[10]*f+b[14])*e;return a},multiplyVector4:function(a){var b=this.elements,c=a.x,d=a.y,f=a.z,e=a.w;a.x=b[0]*c+b[4]*d+b[8]*f+b[12]*e;a.y=b[1]*c+b[5]*d+b[9]*f+b[13]*e;a.z=b[2]*c+b[6]*d+b[10]*f+b[14]*e;a.w=b[3]*c+b[7]*d+b[11]*f+b[15]*e;return a},multiplyVector3Array:function(a){for(var b=THREE.Matrix4.__v1,
-c=0,d=a.length;c<d;c=c+3){b.x=a[c];b.y=a[c+1];b.z=a[c+2];this.multiplyVector3(b);a[c]=b.x;a[c+1]=b.y;a[c+2]=b.z}return a},rotateAxis:function(a){var b=this.elements,c=a.x,d=a.y,f=a.z;a.x=c*b[0]+d*b[4]+f*b[8];a.y=c*b[1]+d*b[5]+f*b[9];a.z=c*b[2]+d*b[6]+f*b[10];a.normalize();return a},crossVector:function(a){var b=this.elements,c=new THREE.Vector4;c.x=b[0]*a.x+b[4]*a.y+b[8]*a.z+b[12]*a.w;c.y=b[1]*a.x+b[5]*a.y+b[9]*a.z+b[13]*a.w;c.z=b[2]*a.x+b[6]*a.y+b[10]*a.z+b[14]*a.w;c.w=a.w?b[3]*a.x+b[7]*a.y+b[11]*
-a.z+b[15]*a.w:1;return c},determinant:function(){var a=this.elements,b=a[0],c=a[4],d=a[8],f=a[12],e=a[1],g=a[5],j=a[9],m=a[13],k=a[2],h=a[6],n=a[10],l=a[14],o=a[3],q=a[7],i=a[11],a=a[15];return f*j*h*o-d*m*h*o-f*g*n*o+c*m*n*o+d*g*l*o-c*j*l*o-f*j*k*q+d*m*k*q+f*e*n*q-b*m*n*q-d*e*l*q+b*j*l*q+f*g*k*i-c*m*k*i-f*e*h*i+b*m*h*i+c*e*l*i-b*g*l*i-d*g*k*a+c*j*k*a+d*e*h*a-b*j*h*a-c*e*n*a+b*g*n*a},transpose:function(){var a=this.elements,b;b=a[1];a[1]=a[4];a[4]=b;b=a[2];a[2]=a[8];a[8]=b;b=a[6];a[6]=a[9];a[9]=b;
-b=a[3];a[3]=a[12];a[12]=b;b=a[7];a[7]=a[13];a[13]=b;b=a[11];a[11]=a[14];a[14]=b;return this},flattenToArray:function(a){var b=this.elements;a[0]=b[0];a[1]=b[1];a[2]=b[2];a[3]=b[3];a[4]=b[4];a[5]=b[5];a[6]=b[6];a[7]=b[7];a[8]=b[8];a[9]=b[9];a[10]=b[10];a[11]=b[11];a[12]=b[12];a[13]=b[13];a[14]=b[14];a[15]=b[15];return a},flattenToArrayOffset:function(a,b){var c=this.elements;a[b]=c[0];a[b+1]=c[1];a[b+2]=c[2];a[b+3]=c[3];a[b+4]=c[4];a[b+5]=c[5];a[b+6]=c[6];a[b+7]=c[7];a[b+8]=c[8];a[b+9]=c[9];a[b+10]=
-c[10];a[b+11]=c[11];a[b+12]=c[12];a[b+13]=c[13];a[b+14]=c[14];a[b+15]=c[15];return a},getPosition:function(){var a=this.elements;return THREE.Matrix4.__v1.set(a[12],a[13],a[14])},setPosition:function(a){var b=this.elements;b[12]=a.x;b[13]=a.y;b[14]=a.z;return this},getColumnX:function(){var a=this.elements;return THREE.Matrix4.__v1.set(a[0],a[1],a[2])},getColumnY:function(){var a=this.elements;return THREE.Matrix4.__v1.set(a[4],a[5],a[6])},getColumnZ:function(){var a=this.elements;return THREE.Matrix4.__v1.set(a[8],
-a[9],a[10])},getInverse:function(a){var b=this.elements,c=a.elements,d=c[0],f=c[4],e=c[8],g=c[12],j=c[1],m=c[5],k=c[9],h=c[13],n=c[2],l=c[6],o=c[10],q=c[14],i=c[3],p=c[7],r=c[11],c=c[15];b[0]=k*q*p-h*o*p+h*l*r-m*q*r-k*l*c+m*o*c;b[4]=g*o*p-e*q*p-g*l*r+f*q*r+e*l*c-f*o*c;b[8]=e*h*p-g*k*p+g*m*r-f*h*r-e*m*c+f*k*c;b[12]=g*k*l-e*h*l-g*m*o+f*h*o+e*m*q-f*k*q;b[1]=h*o*i-k*q*i-h*n*r+j*q*r+k*n*c-j*o*c;b[5]=e*q*i-g*o*i+g*n*r-d*q*r-e*n*c+d*o*c;b[9]=g*k*i-e*h*i-g*j*r+d*h*r+e*j*c-d*k*c;b[13]=e*h*n-g*k*n+g*j*o-d*
-h*o-e*j*q+d*k*q;b[2]=m*q*i-h*l*i+h*n*p-j*q*p-m*n*c+j*l*c;b[6]=g*l*i-f*q*i-g*n*p+d*q*p+f*n*c-d*l*c;b[10]=f*h*i-g*m*i+g*j*p-d*h*p-f*j*c+d*m*c;b[14]=g*m*n-f*h*n-g*j*l+d*h*l+f*j*q-d*m*q;b[3]=k*l*i-m*o*i-k*n*p+j*o*p+m*n*r-j*l*r;b[7]=f*o*i-e*l*i+e*n*p-d*o*p-f*n*r+d*l*r;b[11]=e*m*i-f*k*i-e*j*p+d*k*p+f*j*r-d*m*r;b[15]=f*k*n-e*m*n+e*j*l-d*k*l-f*j*o+d*m*o;this.multiplyScalar(1/a.determinant());return this},setRotationFromEuler:function(a,b){var c=this.elements,d=a.x,f=a.y,e=a.z,g=Math.cos(d),d=Math.sin(d),
-j=Math.cos(f),f=Math.sin(f),m=Math.cos(e),e=Math.sin(e);if(b===void 0||b==="XYZ"){var k=g*m,h=g*e,n=d*m,l=d*e;c[0]=j*m;c[4]=-j*e;c[8]=f;c[1]=h+n*f;c[5]=k-l*f;c[9]=-d*j;c[2]=l-k*f;c[6]=n+h*f;c[10]=g*j}else if(b==="YXZ"){k=j*m;h=j*e;n=f*m;l=f*e;c[0]=k+l*d;c[4]=n*d-h;c[8]=g*f;c[1]=g*e;c[5]=g*m;c[9]=-d;c[2]=h*d-n;c[6]=l+k*d;c[10]=g*j}else if(b==="ZXY"){k=j*m;h=j*e;n=f*m;l=f*e;c[0]=k-l*d;c[4]=-g*e;c[8]=n+h*d;c[1]=h+n*d;c[5]=g*m;c[9]=l-k*d;c[2]=-g*f;c[6]=d;c[10]=g*j}else if(b==="ZYX"){k=g*m;h=g*e;n=d*m;
-l=d*e;c[0]=j*m;c[4]=n*f-h;c[8]=k*f+l;c[1]=j*e;c[5]=l*f+k;c[9]=h*f-n;c[2]=-f;c[6]=d*j;c[10]=g*j}else if(b==="YZX"){k=g*j;h=g*f;n=d*j;l=d*f;c[0]=j*m;c[4]=l-k*e;c[8]=n*e+h;c[1]=e;c[5]=g*m;c[9]=-d*m;c[2]=-f*m;c[6]=h*e+n;c[10]=k-l*e}else if(b==="XZY"){k=g*j;h=g*f;n=d*j;l=d*f;c[0]=j*m;c[4]=-e;c[8]=f*m;c[1]=k*e+l;c[5]=g*m;c[9]=h*e-n;c[2]=n*e-h;c[6]=d*m;c[10]=l*e+k}return this},setRotationFromQuaternion:function(a){var b=this.elements,c=a.x,d=a.y,f=a.z,e=a.w,g=c+c,j=d+d,m=f+f,a=c*g,k=c*j,c=c*m,h=d*j,d=d*
-m,f=f*m,g=e*g,j=e*j,e=e*m;b[0]=1-(h+f);b[4]=k-e;b[8]=c+j;b[1]=k+e;b[5]=1-(a+f);b[9]=d-g;b[2]=c-j;b[6]=d+g;b[10]=1-(a+h);return this},compose:function(a,b,c){var d=this.elements,f=THREE.Matrix4.__m1,e=THREE.Matrix4.__m2;f.identity();f.setRotationFromQuaternion(b);e.makeScale(c.x,c.y,c.z);this.multiply(f,e);d[12]=a.x;d[13]=a.y;d[14]=a.z;return this},decompose:function(a,b,c){var d=this.elements,f=THREE.Matrix4.__v1,e=THREE.Matrix4.__v2,g=THREE.Matrix4.__v3;f.set(d[0],d[1],d[2]);e.set(d[4],d[5],d[6]);
-g.set(d[8],d[9],d[10]);a=a instanceof THREE.Vector3?a:new THREE.Vector3;b=b instanceof THREE.Quaternion?b:new THREE.Quaternion;c=c instanceof THREE.Vector3?c:new THREE.Vector3;c.x=f.length();c.y=e.length();c.z=g.length();a.x=d[12];a.y=d[13];a.z=d[14];d=THREE.Matrix4.__m1;d.copy(this);d.elements[0]=d.elements[0]/c.x;d.elements[1]=d.elements[1]/c.x;d.elements[2]=d.elements[2]/c.x;d.elements[4]=d.elements[4]/c.y;d.elements[5]=d.elements[5]/c.y;d.elements[6]=d.elements[6]/c.y;d.elements[8]=d.elements[8]/
-c.z;d.elements[9]=d.elements[9]/c.z;d.elements[10]=d.elements[10]/c.z;b.setFromRotationMatrix(d);return[a,b,c]},extractPosition:function(a){var b=this.elements,a=a.elements;b[12]=a[12];b[13]=a[13];b[14]=a[14];return this},extractRotation:function(a){var b=this.elements,a=a.elements,c=THREE.Matrix4.__v1,d=1/c.set(a[0],a[1],a[2]).length(),f=1/c.set(a[4],a[5],a[6]).length(),c=1/c.set(a[8],a[9],a[10]).length();b[0]=a[0]*d;b[1]=a[1]*d;b[2]=a[2]*d;b[4]=a[4]*f;b[5]=a[5]*f;b[6]=a[6]*f;b[8]=a[8]*c;b[9]=a[9]*
-c;b[10]=a[10]*c;return this},translate:function(a){var b=this.elements,c=a.x,d=a.y,a=a.z;b[12]=b[0]*c+b[4]*d+b[8]*a+b[12];b[13]=b[1]*c+b[5]*d+b[9]*a+b[13];b[14]=b[2]*c+b[6]*d+b[10]*a+b[14];b[15]=b[3]*c+b[7]*d+b[11]*a+b[15];return this},rotateX:function(a){var b=this.elements,c=b[4],d=b[5],f=b[6],e=b[7],g=b[8],j=b[9],m=b[10],k=b[11],h=Math.cos(a),a=Math.sin(a);b[4]=h*c+a*g;b[5]=h*d+a*j;b[6]=h*f+a*m;b[7]=h*e+a*k;b[8]=h*g-a*c;b[9]=h*j-a*d;b[10]=h*m-a*f;b[11]=h*k-a*e;return this},rotateY:function(a){var b=
-this.elements,c=b[0],d=b[1],f=b[2],e=b[3],g=b[8],j=b[9],m=b[10],k=b[11],h=Math.cos(a),a=Math.sin(a);b[0]=h*c-a*g;b[1]=h*d-a*j;b[2]=h*f-a*m;b[3]=h*e-a*k;b[8]=h*g+a*c;b[9]=h*j+a*d;b[10]=h*m+a*f;b[11]=h*k+a*e;return this},rotateZ:function(a){var b=this.elements,c=b[0],d=b[1],f=b[2],e=b[3],g=b[4],j=b[5],m=b[6],k=b[7],h=Math.cos(a),a=Math.sin(a);b[0]=h*c+a*g;b[1]=h*d+a*j;b[2]=h*f+a*m;b[3]=h*e+a*k;b[4]=h*g-a*c;b[5]=h*j-a*d;b[6]=h*m-a*f;b[7]=h*k-a*e;return this},rotateByAxis:function(a,b){var c=this.elements;
-if(a.x===1&&a.y===0&&a.z===0)return this.rotateX(b);if(a.x===0&&a.y===1&&a.z===0)return this.rotateY(b);if(a.x===0&&a.y===0&&a.z===1)return this.rotateZ(b);var d=a.x,f=a.y,e=a.z,g=Math.sqrt(d*d+f*f+e*e),d=d/g,f=f/g,e=e/g,g=d*d,j=f*f,m=e*e,k=Math.cos(b),h=Math.sin(b),n=1-k,l=d*f*n,o=d*e*n,n=f*e*n,d=d*h,q=f*h,h=e*h,e=g+(1-g)*k,g=l+h,f=o-q,l=l-h,j=j+(1-j)*k,h=n+d,o=o+q,n=n-d,m=m+(1-m)*k,k=c[0],d=c[1],q=c[2],i=c[3],p=c[4],r=c[5],u=c[6],v=c[7],B=c[8],x=c[9],A=c[10],y=c[11];c[0]=e*k+g*p+f*B;c[1]=e*d+g*
-r+f*x;c[2]=e*q+g*u+f*A;c[3]=e*i+g*v+f*y;c[4]=l*k+j*p+h*B;c[5]=l*d+j*r+h*x;c[6]=l*q+j*u+h*A;c[7]=l*i+j*v+h*y;c[8]=o*k+n*p+m*B;c[9]=o*d+n*r+m*x;c[10]=o*q+n*u+m*A;c[11]=o*i+n*v+m*y;return this},scale:function(a){var b=this.elements,c=a.x,d=a.y,a=a.z;b[0]=b[0]*c;b[4]=b[4]*d;b[8]=b[8]*a;b[1]=b[1]*c;b[5]=b[5]*d;b[9]=b[9]*a;b[2]=b[2]*c;b[6]=b[6]*d;b[10]=b[10]*a;b[3]=b[3]*c;b[7]=b[7]*d;b[11]=b[11]*a;return this},getMaxScaleOnAxis:function(){var a=this.elements;return Math.sqrt(Math.max(a[0]*a[0]+a[1]*a[1]+
-a[2]*a[2],Math.max(a[4]*a[4]+a[5]*a[5]+a[6]*a[6],a[8]*a[8]+a[9]*a[9]+a[10]*a[10])))},makeTranslation:function(a,b,c){this.set(1,0,0,a,0,1,0,b,0,0,1,c,0,0,0,1);return this},makeRotationX:function(a){var b=Math.cos(a),a=Math.sin(a);this.set(1,0,0,0,0,b,-a,0,0,a,b,0,0,0,0,1);return this},makeRotationY:function(a){var b=Math.cos(a),a=Math.sin(a);this.set(b,0,a,0,0,1,0,0,-a,0,b,0,0,0,0,1);return this},makeRotationZ:function(a){var b=Math.cos(a),a=Math.sin(a);this.set(b,-a,0,0,a,b,0,0,0,0,1,0,0,0,0,1);
-return this},makeRotationAxis:function(a,b){var c=Math.cos(b),d=Math.sin(b),f=1-c,e=a.x,g=a.y,j=a.z,m=f*e,k=f*g;this.set(m*e+c,m*g-d*j,m*j+d*g,0,m*g+d*j,k*g+c,k*j-d*e,0,m*j-d*g,k*j+d*e,f*j*j+c,0,0,0,0,1);return this},makeScale:function(a,b,c){this.set(a,0,0,0,0,b,0,0,0,0,c,0,0,0,0,1);return this},makeFrustum:function(a,b,c,d,f,e){var g=this.elements;g[0]=2*f/(b-a);g[4]=0;g[8]=(b+a)/(b-a);g[12]=0;g[1]=0;g[5]=2*f/(d-c);g[9]=(d+c)/(d-c);g[13]=0;g[2]=0;g[6]=0;g[10]=-(e+f)/(e-f);g[14]=-2*e*f/(e-f);g[3]=
-0;g[7]=0;g[11]=-1;g[15]=0;return this},makePerspective:function(a,b,c,d){var a=c*Math.tan(a*Math.PI/360),f=-a;return this.makeFrustum(f*b,a*b,f,a,c,d)},makeOrthographic:function(a,b,c,d,f,e){var g=this.elements,j=b-a,m=c-d,k=e-f;g[0]=2/j;g[4]=0;g[8]=0;g[12]=-((b+a)/j);g[1]=0;g[5]=2/m;g[9]=0;g[13]=-((c+d)/m);g[2]=0;g[6]=0;g[10]=-2/k;g[14]=-((e+f)/k);g[3]=0;g[7]=0;g[11]=0;g[15]=1;return this},clone:function(){var a=this.elements;return new THREE.Matrix4(a[0],a[4],a[8],a[12],a[1],a[5],a[9],a[13],a[2],
-a[6],a[10],a[14],a[3],a[7],a[11],a[15])}};THREE.Matrix4.__v1=new THREE.Vector3;THREE.Matrix4.__v2=new THREE.Vector3;THREE.Matrix4.__v3=new THREE.Vector3;THREE.Matrix4.__m1=new THREE.Matrix4;THREE.Matrix4.__m2=new THREE.Matrix4;
-THREE.Object3D=function(){this.id=THREE.Object3DCount++;this.name="";this.properties={};this.parent=void 0;this.children=[];this.up=new THREE.Vector3(0,1,0);this.position=new THREE.Vector3;this.rotation=new THREE.Vector3;this.eulerOrder="XYZ";this.scale=new THREE.Vector3(1,1,1);this.renderDepth=null;this.rotationAutoUpdate=true;this.matrix=new THREE.Matrix4;this.matrixWorld=new THREE.Matrix4;this.matrixRotationWorld=new THREE.Matrix4;this.matrixWorldNeedsUpdate=this.matrixAutoUpdate=true;this.quaternion=
-new THREE.Quaternion;this.useQuaternion=false;this.boundRadius=0;this.boundRadiusScale=1;this.visible=true;this.receiveShadow=this.castShadow=false;this.frustumCulled=true;this._vector=new THREE.Vector3};
-THREE.Object3D.prototype={constructor:THREE.Object3D,applyMatrix:function(a){this.matrix.multiply(a,this.matrix);this.scale.getScaleFromMatrix(this.matrix);this.rotation.setEulerFromRotationMatrix((new THREE.Matrix4).extractRotation(this.matrix),this.eulerOrder);this.position.getPositionFromMatrix(this.matrix)},translate:function(a,b){this.matrix.rotateAxis(b);this.position.addSelf(b.multiplyScalar(a))},translateX:function(a){this.translate(a,this._vector.set(1,0,0))},translateY:function(a){this.translate(a,
-this._vector.set(0,1,0))},translateZ:function(a){this.translate(a,this._vector.set(0,0,1))},lookAt:function(a){this.matrix.lookAt(a,this.position,this.up);this.rotationAutoUpdate&&this.rotation.setEulerFromRotationMatrix(this.matrix,this.eulerOrder)},add:function(a){if(a===this)console.warn("THREE.Object3D.add: An object can't be added as a child of itself.");else if(a instanceof THREE.Object3D){a.parent!==void 0&&a.parent.remove(a);a.parent=this;this.children.push(a);for(var b=this;b.parent!==void 0;)b=
-b.parent;b!==void 0&&b instanceof THREE.Scene&&b.__addObject(a)}},remove:function(a){var b=this.children.indexOf(a);if(b!==-1){a.parent=void 0;this.children.splice(b,1);for(b=this;b.parent!==void 0;)b=b.parent;b!==void 0&&b instanceof THREE.Scene&&b.__removeObject(a)}},getChildByName:function(a,b){var c,d,f;c=0;for(d=this.children.length;c<d;c++){f=this.children[c];if(f.name===a)return f;if(b){f=f.getChildByName(a,b);if(f!==void 0)return f}}},updateMatrix:function(){this.matrix.setPosition(this.position);
-this.useQuaternion===true?this.matrix.setRotationFromQuaternion(this.quaternion):this.matrix.setRotationFromEuler(this.rotation,this.eulerOrder);if(this.scale.x!==1||this.scale.y!==1||this.scale.z!==1){this.matrix.scale(this.scale);this.boundRadiusScale=Math.max(this.scale.x,Math.max(this.scale.y,this.scale.z))}this.matrixWorldNeedsUpdate=true},updateMatrixWorld:function(a){this.matrixAutoUpdate===true&&this.updateMatrix();if(this.matrixWorldNeedsUpdate===true||a===true){this.parent!==void 0?this.matrixWorld.multiply(this.parent.matrixWorld,
-this.matrix):this.matrixWorld.copy(this.matrix);this.matrixWorldNeedsUpdate=false;a=true}for(var b=0,c=this.children.length;b<c;b++)this.children[b].updateMatrixWorld(a)},worldToLocal:function(a){return THREE.Object3D.__m1.getInverse(this.matrixWorld).multiplyVector3(a)},localToWorld:function(a){return this.matrixWorld.multiplyVector3(a)},clone:function(){}};THREE.Object3D.__m1=new THREE.Matrix4;THREE.Object3DCount=0;
-THREE.Projector=function(){function a(a,c){g=0;A.objects.length=0;A.sprites.length=0;A.lights.length=0;var f=function(a){if(a.visible!==false){if((a instanceof THREE.Mesh||a instanceof THREE.Line)&&(a.frustumCulled===false||C.contains(a)===true)){y.copy(a.matrixWorld.getPosition());s.multiplyVector3(y);e=b();e.object=a;e.z=y.z;A.objects.push(e)}else if(a instanceof THREE.Sprite||a instanceof THREE.Particle){y.copy(a.matrixWorld.getPosition());s.multiplyVector3(y);e=b();e.object=a;e.z=y.z;A.sprites.push(e)}else a instanceof
-THREE.Light&&A.lights.push(a);for(var c=0,d=a.children.length;c<d;c++)f(a.children[c])}};f(a);c===true&&A.objects.sort(d);return A}function b(){var a;if(g===j.length){a=new THREE.RenderableObject;j.push(a)}else a=j[g];g++;return a}function c(){var a;if(k===h.length){a=new THREE.RenderableVertex;h.push(a)}else a=h[k];k++;return a}function d(a,b){return b.z-a.z}function f(a,b){var c=0,d=1,e=a.z+a.w,g=b.z+b.w,f=-a.z+a.w,h=-b.z+b.w;if(e>=0&&g>=0&&f>=0&&h>=0)return true;if(e<0&&g<0||f<0&&h<0)return false;
-e<0?c=Math.max(c,e/(e-g)):g<0&&(d=Math.min(d,e/(e-g)));f<0?c=Math.max(c,f/(f-h)):h<0&&(d=Math.min(d,f/(f-h)));if(d<c)return false;a.lerpSelf(b,c);b.lerpSelf(a,1-d);return true}var e,g,j=[],m,k,h=[],n,l,o=[],q,i=[],p,r,u=[],v,B,x=[],A={objects:[],sprites:[],lights:[],elements:[]},y=new THREE.Vector3,E=new THREE.Vector4,s=new THREE.Matrix4,w=new THREE.Matrix4,C=new THREE.Frustum,K=new THREE.Vector4,M=new THREE.Vector4;this.projectVector=function(a,b){b.matrixWorldInverse.getInverse(b.matrixWorld);s.multiply(b.projectionMatrix,
-b.matrixWorldInverse);s.multiplyVector3(a);return a};this.unprojectVector=function(a,b){b.projectionMatrixInverse.getInverse(b.projectionMatrix);s.multiply(b.matrixWorld,b.projectionMatrixInverse);s.multiplyVector3(a);return a};this.pickingRay=function(a,b){var c;a.z=-1;c=new THREE.Vector3(a.x,a.y,1);this.unprojectVector(a,b);this.unprojectVector(c,b);c.subSelf(a).normalize();return new THREE.Ray(a,c)};this.projectScene=function(b,e,g){var j=e.near,y=e.far,P=false,R,z,$,aa,J,S,W,D,F,H,L,Q,la,T,ca,
-U,da;B=r=q=l=0;A.elements.length=0;b.updateMatrixWorld();e.parent===void 0&&e.updateMatrixWorld();e.matrixWorldInverse.getInverse(e.matrixWorld);s.multiply(e.projectionMatrix,e.matrixWorldInverse);C.setFromMatrix(s);A=a(b,false);b=0;for(R=A.objects.length;b<R;b++){F=A.objects[b].object;H=F.matrixWorld;k=0;if(F instanceof THREE.Mesh){L=F.geometry;Q=F.geometry.materials;aa=L.vertices;la=L.faces;ca=L.faceVertexUvs;L=F.matrixRotationWorld.extractRotation(H);da=F.material instanceof THREE.MeshFaceMaterial;
-z=0;for($=aa.length;z<$;z++){m=c();m.positionWorld.copy(aa[z]);H.multiplyVector3(m.positionWorld);m.positionScreen.copy(m.positionWorld);s.multiplyVector4(m.positionScreen);m.positionScreen.x=m.positionScreen.x/m.positionScreen.w;m.positionScreen.y=m.positionScreen.y/m.positionScreen.w;m.visible=m.positionScreen.z>j&&m.positionScreen.z<y}aa=0;for(z=la.length;aa<z;aa++){D=la[aa];$=da===true?Q[D.materialIndex]:F.material;if($!==void 0){W=$.side;if(D instanceof THREE.Face3){J=h[D.a];S=h[D.b];T=h[D.c];
-if(J.visible===true&&S.visible===true&&T.visible===true){P=(T.positionScreen.x-J.positionScreen.x)*(S.positionScreen.y-J.positionScreen.y)-(T.positionScreen.y-J.positionScreen.y)*(S.positionScreen.x-J.positionScreen.x)<0;if(W===THREE.DoubleSide||P===(W===THREE.FrontSide)){U=void 0;if(l===o.length){U=new THREE.RenderableFace3;o.push(U)}else U=o[l];l++;n=U;n.v1.copy(J);n.v2.copy(S);n.v3.copy(T)}else continue}else continue}else if(D instanceof THREE.Face4){J=h[D.a];S=h[D.b];T=h[D.c];U=h[D.d];if(J.visible===
-true&&S.visible===true&&T.visible===true&&U.visible===true){P=(U.positionScreen.x-J.positionScreen.x)*(S.positionScreen.y-J.positionScreen.y)-(U.positionScreen.y-J.positionScreen.y)*(S.positionScreen.x-J.positionScreen.x)<0||(S.positionScreen.x-T.positionScreen.x)*(U.positionScreen.y-T.positionScreen.y)-(S.positionScreen.y-T.positionScreen.y)*(U.positionScreen.x-T.positionScreen.x)<0;if(W===THREE.DoubleSide||P===(W===THREE.FrontSide)){var fa=void 0;if(q===i.length){fa=new THREE.RenderableFace4;i.push(fa)}else fa=
-i[q];q++;n=fa;n.v1.copy(J);n.v2.copy(S);n.v3.copy(T);n.v4.copy(U)}else continue}else continue}n.normalWorld.copy(D.normal);P===false&&(W===THREE.BackSide||W===THREE.DoubleSide)&&n.normalWorld.negate();L.multiplyVector3(n.normalWorld);n.centroidWorld.copy(D.centroid);H.multiplyVector3(n.centroidWorld);n.centroidScreen.copy(n.centroidWorld);s.multiplyVector3(n.centroidScreen);D=D.vertexNormals;J=0;for(S=D.length;J<S;J++){T=n.vertexNormalsWorld[J];T.copy(D[J]);P===false&&(W===THREE.BackSide||W===THREE.DoubleSide)&&
-T.negate();L.multiplyVector3(T)}J=0;for(S=ca.length;J<S;J++){T=ca[J][aa];if(T!==void 0){W=0;for(D=T.length;W<D;W++)n.uvs[J][W]=T[W]}}n.material=$;n.z=n.centroidScreen.z;A.elements.push(n)}}}else if(F instanceof THREE.Line){w.multiply(s,H);aa=F.geometry.vertices;J=c();J.positionScreen.copy(aa[0]);w.multiplyVector4(J.positionScreen);H=F.type===THREE.LinePieces?2:1;z=1;for($=aa.length;z<$;z++){J=c();J.positionScreen.copy(aa[z]);w.multiplyVector4(J.positionScreen);if(!((z+1)%H>0)){S=h[k-2];K.copy(J.positionScreen);
-M.copy(S.positionScreen);if(f(K,M)===true){K.multiplyScalar(1/K.w);M.multiplyScalar(1/M.w);Q=void 0;if(r===u.length){Q=new THREE.RenderableLine;u.push(Q)}else Q=u[r];r++;p=Q;p.v1.positionScreen.copy(K);p.v2.positionScreen.copy(M);p.z=Math.max(K.z,M.z);p.material=F.material;A.elements.push(p)}}}}}b=0;for(R=A.sprites.length;b<R;b++){F=A.sprites[b].object;H=F.matrixWorld;if(F instanceof THREE.Particle){E.set(H.elements[12],H.elements[13],H.elements[14],1);s.multiplyVector4(E);E.z=E.z/E.w;if(E.z>0&&E.z<
-1){j=void 0;if(B===x.length){j=new THREE.RenderableParticle;x.push(j)}else j=x[B];B++;v=j;v.object=F;v.x=E.x/E.w;v.y=E.y/E.w;v.z=E.z;v.rotation=F.rotation.z;v.scale.x=F.scale.x*Math.abs(v.x-(E.x+e.projectionMatrix.elements[0])/(E.w+e.projectionMatrix.elements[12]));v.scale.y=F.scale.y*Math.abs(v.y-(E.y+e.projectionMatrix.elements[5])/(E.w+e.projectionMatrix.elements[13]));v.material=F.material;A.elements.push(v)}}}g&&A.elements.sort(d);return A}};
-THREE.Quaternion=function(a,b,c,d){this.x=a||0;this.y=b||0;this.z=c||0;this.w=d!==void 0?d:1};
-THREE.Quaternion.prototype={constructor:THREE.Quaternion,set:function(a,b,c,d){this.x=a;this.y=b;this.z=c;this.w=d;return this},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;this.w=a.w;return this},setFromEuler:function(a,b){var c=Math.cos(a.x/2),d=Math.cos(a.y/2),f=Math.cos(a.z/2),e=Math.sin(a.x/2),g=Math.sin(a.y/2),j=Math.sin(a.z/2);if(b===void 0||b==="XYZ"){this.x=e*d*f+c*g*j;this.y=c*g*f-e*d*j;this.z=c*d*j+e*g*f;this.w=c*d*f-e*g*j}else if(b==="YXZ"){this.x=e*d*f+c*g*j;this.y=c*g*f-e*d*j;this.z=
-c*d*j-e*g*f;this.w=c*d*f+e*g*j}else if(b==="ZXY"){this.x=e*d*f-c*g*j;this.y=c*g*f+e*d*j;this.z=c*d*j+e*g*f;this.w=c*d*f-e*g*j}else if(b==="ZYX"){this.x=e*d*f-c*g*j;this.y=c*g*f+e*d*j;this.z=c*d*j-e*g*f;this.w=c*d*f+e*g*j}else if(b==="YZX"){this.x=e*d*f+c*g*j;this.y=c*g*f+e*d*j;this.z=c*d*j-e*g*f;this.w=c*d*f-e*g*j}else if(b==="XZY"){this.x=e*d*f-c*g*j;this.y=c*g*f-e*d*j;this.z=c*d*j+e*g*f;this.w=c*d*f+e*g*j}return this},setFromAxisAngle:function(a,b){var c=b/2,d=Math.sin(c);this.x=a.x*d;this.y=a.y*
-d;this.z=a.z*d;this.w=Math.cos(c);return this},setFromRotationMatrix:function(a){var b=a.elements,c=b[0],a=b[4],d=b[8],f=b[1],e=b[5],g=b[9],j=b[2],m=b[6],b=b[10],k=c+e+b;if(k>0){c=0.5/Math.sqrt(k+1);this.w=0.25/c;this.x=(m-g)*c;this.y=(d-j)*c;this.z=(f-a)*c}else if(c>e&&c>b){c=2*Math.sqrt(1+c-e-b);this.w=(m-g)/c;this.x=0.25*c;this.y=(a+f)/c;this.z=(d+j)/c}else if(e>b){c=2*Math.sqrt(1+e-c-b);this.w=(d-j)/c;this.x=(a+f)/c;this.y=0.25*c;this.z=(g+m)/c}else{c=2*Math.sqrt(1+b-c-e);this.w=(f-a)/c;this.x=
-(d+j)/c;this.y=(g+m)/c;this.z=0.25*c}return this},calculateW:function(){this.w=-Math.sqrt(Math.abs(1-this.x*this.x-this.y*this.y-this.z*this.z));return this},inverse:function(){this.x=this.x*-1;this.y=this.y*-1;this.z=this.z*-1;return this},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)},normalize:function(){var a=Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w);if(a===0)this.w=this.z=this.y=this.x=0;else{a=1/a;this.x=this.x*a;this.y=
-this.y*a;this.z=this.z*a;this.w=this.w*a}return this},multiply:function(a,b){var c=a.x,d=a.y,f=a.z,e=a.w,g=b.x,j=b.y,m=b.z,k=b.w;this.x=c*k+d*m-f*j+e*g;this.y=-c*m+d*k+f*g+e*j;this.z=c*j-d*g+f*k+e*m;this.w=-c*g-d*j-f*m+e*k;return this},multiplySelf:function(a){var b=this.x,c=this.y,d=this.z,f=this.w,e=a.x,g=a.y,j=a.z,a=a.w;this.x=b*a+f*e+c*j-d*g;this.y=c*a+f*g+d*e-b*j;this.z=d*a+f*j+b*g-c*e;this.w=f*a-b*e-c*g-d*j;return this},multiplyVector3:function(a,b){b||(b=a);var c=a.x,d=a.y,f=a.z,e=this.x,g=
-this.y,j=this.z,m=this.w,k=m*c+g*f-j*d,h=m*d+j*c-e*f,n=m*f+e*d-g*c,c=-e*c-g*d-j*f;b.x=k*m+c*-e+h*-j-n*-g;b.y=h*m+c*-g+n*-e-k*-j;b.z=n*m+c*-j+k*-g-h*-e;return b},slerpSelf:function(a,b){var c=this.x,d=this.y,f=this.z,e=this.w,g=e*a.w+c*a.x+d*a.y+f*a.z;if(g<0){this.w=-a.w;this.x=-a.x;this.y=-a.y;this.z=-a.z;g=-g}else this.copy(a);if(g>=1){this.w=e;this.x=c;this.y=d;this.z=f;return this}var j=Math.acos(g),m=Math.sqrt(1-g*g);if(Math.abs(m)<0.001){this.w=0.5*(e+this.w);this.x=0.5*(c+this.x);this.y=0.5*
-(d+this.y);this.z=0.5*(f+this.z);return this}g=Math.sin((1-b)*j)/m;j=Math.sin(b*j)/m;this.w=e*g+this.w*j;this.x=c*g+this.x*j;this.y=d*g+this.y*j;this.z=f*g+this.z*j;return this},clone:function(){return new THREE.Quaternion(this.x,this.y,this.z,this.w)}};
-THREE.Quaternion.slerp=function(a,b,c,d){var f=a.w*b.w+a.x*b.x+a.y*b.y+a.z*b.z;if(f<0){c.w=-b.w;c.x=-b.x;c.y=-b.y;c.z=-b.z;f=-f}else c.copy(b);if(Math.abs(f)>=1){c.w=a.w;c.x=a.x;c.y=a.y;c.z=a.z;return c}var b=Math.acos(f),e=Math.sqrt(1-f*f);if(Math.abs(e)<0.001){c.w=0.5*(a.w+c.w);c.x=0.5*(a.x+c.x);c.y=0.5*(a.y+c.y);c.z=0.5*(a.z+c.z);return c}f=Math.sin((1-d)*b)/e;d=Math.sin(d*b)/e;c.w=a.w*f+c.w*d;c.x=a.x*f+c.x*d;c.y=a.y*f+c.y*d;c.z=a.z*f+c.z*d;return c};
-THREE.Vertex=function(a){console.warn("THREE.Vertex has been DEPRECATED. Use THREE.Vector3 instead.");return a};THREE.Face3=function(a,b,c,d,f,e){this.a=a;this.b=b;this.c=c;this.normal=d instanceof THREE.Vector3?d:new THREE.Vector3;this.vertexNormals=d instanceof Array?d:[];this.color=f instanceof THREE.Color?f:new THREE.Color;this.vertexColors=f instanceof Array?f:[];this.vertexTangents=[];this.materialIndex=e;this.centroid=new THREE.Vector3};
-THREE.Face3.prototype={constructor:THREE.Face3,clone:function(){var a=new THREE.Face3(this.a,this.b,this.c);a.normal.copy(this.normal);a.color.copy(this.color);a.centroid.copy(this.centroid);a.materialIndex=this.materialIndex;var b,c;b=0;for(c=this.vertexNormals.length;b<c;b++)a.vertexNormals[b]=this.vertexNormals[b].clone();b=0;for(c=this.vertexColors.length;b<c;b++)a.vertexColors[b]=this.vertexColors[b].clone();b=0;for(c=this.vertexTangents.length;b<c;b++)a.vertexTangents[b]=this.vertexTangents[b].clone();
-return a}};THREE.Face4=function(a,b,c,d,f,e,g){this.a=a;this.b=b;this.c=c;this.d=d;this.normal=f instanceof THREE.Vector3?f:new THREE.Vector3;this.vertexNormals=f instanceof Array?f:[];this.color=e instanceof THREE.Color?e:new THREE.Color;this.vertexColors=e instanceof Array?e:[];this.vertexTangents=[];this.materialIndex=g;this.centroid=new THREE.Vector3};
-THREE.Face4.prototype={constructor:THREE.Face4,clone:function(){var a=new THREE.Face4(this.a,this.b,this.c,this.d);a.normal.copy(this.normal);a.color.copy(this.color);a.centroid.copy(this.centroid);a.materialIndex=this.materialIndex;var b,c;b=0;for(c=this.vertexNormals.length;b<c;b++)a.vertexNormals[b]=this.vertexNormals[b].clone();b=0;for(c=this.vertexColors.length;b<c;b++)a.vertexColors[b]=this.vertexColors[b].clone();b=0;for(c=this.vertexTangents.length;b<c;b++)a.vertexTangents[b]=this.vertexTangents[b].clone();
-return a}};THREE.UV=function(a,b){this.u=a||0;this.v=b||0};THREE.UV.prototype={constructor:THREE.UV,set:function(a,b){this.u=a;this.v=b;return this},copy:function(a){this.u=a.u;this.v=a.v;return this},lerpSelf:function(a,b){this.u=this.u+(a.u-this.u)*b;this.v=this.v+(a.v-this.v)*b;return this},clone:function(){return new THREE.UV(this.u,this.v)}};
-THREE.Geometry=function(){this.id=THREE.GeometryCount++;this.name="";this.vertices=[];this.colors=[];this.materials=[];this.faces=[];this.faceUvs=[[]];this.faceVertexUvs=[[]];this.morphTargets=[];this.morphColors=[];this.morphNormals=[];this.skinWeights=[];this.skinIndices=[];this.boundingSphere=this.boundingBox=null;this.hasTangents=false;this.dynamic=true};
-THREE.Geometry.prototype={constructor:THREE.Geometry,applyMatrix:function(a){var b=new THREE.Matrix4;b.extractRotation(a);for(var c=0,d=this.vertices.length;c<d;c++)a.multiplyVector3(this.vertices[c]);c=0;for(d=this.faces.length;c<d;c++){var f=this.faces[c];b.multiplyVector3(f.normal);for(var e=0,g=f.vertexNormals.length;e<g;e++)b.multiplyVector3(f.vertexNormals[e]);a.multiplyVector3(f.centroid)}},computeCentroids:function(){var a,b,c;a=0;for(b=this.faces.length;a<b;a++){c=this.faces[a];c.centroid.set(0,
-0,0);if(c instanceof THREE.Face3){c.centroid.addSelf(this.vertices[c.a]);c.centroid.addSelf(this.vertices[c.b]);c.centroid.addSelf(this.vertices[c.c]);c.centroid.divideScalar(3)}else if(c instanceof THREE.Face4){c.centroid.addSelf(this.vertices[c.a]);c.centroid.addSelf(this.vertices[c.b]);c.centroid.addSelf(this.vertices[c.c]);c.centroid.addSelf(this.vertices[c.d]);c.centroid.divideScalar(4)}}},computeFaceNormals:function(){var a,b,c,d,f,e,g=new THREE.Vector3,j=new THREE.Vector3;a=0;for(b=this.faces.length;a<
-b;a++){c=this.faces[a];d=this.vertices[c.a];f=this.vertices[c.b];e=this.vertices[c.c];g.sub(e,f);j.sub(d,f);g.crossSelf(j);g.isZero()||g.normalize();c.normal.copy(g)}},computeVertexNormals:function(){var a,b,c,d;if(this.__tmpVertices===void 0){d=this.__tmpVertices=Array(this.vertices.length);a=0;for(b=this.vertices.length;a<b;a++)d[a]=new THREE.Vector3;a=0;for(b=this.faces.length;a<b;a++){c=this.faces[a];if(c instanceof THREE.Face3)c.vertexNormals=[new THREE.Vector3,new THREE.Vector3,new THREE.Vector3];
-else if(c instanceof THREE.Face4)c.vertexNormals=[new THREE.Vector3,new THREE.Vector3,new THREE.Vector3,new THREE.Vector3]}}else{d=this.__tmpVertices;a=0;for(b=this.vertices.length;a<b;a++)d[a].set(0,0,0)}a=0;for(b=this.faces.length;a<b;a++){c=this.faces[a];if(c instanceof THREE.Face3){d[c.a].addSelf(c.normal);d[c.b].addSelf(c.normal);d[c.c].addSelf(c.normal)}else if(c instanceof THREE.Face4){d[c.a].addSelf(c.normal);d[c.b].addSelf(c.normal);d[c.c].addSelf(c.normal);d[c.d].addSelf(c.normal)}}a=0;
-for(b=this.vertices.length;a<b;a++)d[a].normalize();a=0;for(b=this.faces.length;a<b;a++){c=this.faces[a];if(c instanceof THREE.Face3){c.vertexNormals[0].copy(d[c.a]);c.vertexNormals[1].copy(d[c.b]);c.vertexNormals[2].copy(d[c.c])}else if(c instanceof THREE.Face4){c.vertexNormals[0].copy(d[c.a]);c.vertexNormals[1].copy(d[c.b]);c.vertexNormals[2].copy(d[c.c]);c.vertexNormals[3].copy(d[c.d])}}},computeMorphNormals:function(){var a,b,c,d,f;c=0;for(d=this.faces.length;c<d;c++){f=this.faces[c];f.__originalFaceNormal?
-f.__originalFaceNormal.copy(f.normal):f.__originalFaceNormal=f.normal.clone();if(!f.__originalVertexNormals)f.__originalVertexNormals=[];a=0;for(b=f.vertexNormals.length;a<b;a++)f.__originalVertexNormals[a]?f.__originalVertexNormals[a].copy(f.vertexNormals[a]):f.__originalVertexNormals[a]=f.vertexNormals[a].clone()}var e=new THREE.Geometry;e.faces=this.faces;a=0;for(b=this.morphTargets.length;a<b;a++){if(!this.morphNormals[a]){this.morphNormals[a]={};this.morphNormals[a].faceNormals=[];this.morphNormals[a].vertexNormals=
-[];var g=this.morphNormals[a].faceNormals,j=this.morphNormals[a].vertexNormals,m,k;c=0;for(d=this.faces.length;c<d;c++){f=this.faces[c];m=new THREE.Vector3;k=f instanceof THREE.Face3?{a:new THREE.Vector3,b:new THREE.Vector3,c:new THREE.Vector3}:{a:new THREE.Vector3,b:new THREE.Vector3,c:new THREE.Vector3,d:new THREE.Vector3};g.push(m);j.push(k)}}g=this.morphNormals[a];e.vertices=this.morphTargets[a].vertices;e.computeFaceNormals();e.computeVertexNormals();c=0;for(d=this.faces.length;c<d;c++){f=this.faces[c];
-m=g.faceNormals[c];k=g.vertexNormals[c];m.copy(f.normal);if(f instanceof THREE.Face3){k.a.copy(f.vertexNormals[0]);k.b.copy(f.vertexNormals[1]);k.c.copy(f.vertexNormals[2])}else{k.a.copy(f.vertexNormals[0]);k.b.copy(f.vertexNormals[1]);k.c.copy(f.vertexNormals[2]);k.d.copy(f.vertexNormals[3])}}}c=0;for(d=this.faces.length;c<d;c++){f=this.faces[c];f.normal=f.__originalFaceNormal;f.vertexNormals=f.__originalVertexNormals}},computeTangents:function(){function a(a,b,c,d,e,f,t){j=a.vertices[b];m=a.vertices[c];
-k=a.vertices[d];h=g[e];n=g[f];l=g[t];o=m.x-j.x;q=k.x-j.x;i=m.y-j.y;p=k.y-j.y;r=m.z-j.z;u=k.z-j.z;v=n.u-h.u;B=l.u-h.u;x=n.v-h.v;A=l.v-h.v;y=1/(v*A-B*x);C.set((A*o-x*q)*y,(A*i-x*p)*y,(A*r-x*u)*y);K.set((v*q-B*o)*y,(v*p-B*i)*y,(v*u-B*r)*y);s[b].addSelf(C);s[c].addSelf(C);s[d].addSelf(C);w[b].addSelf(K);w[c].addSelf(K);w[d].addSelf(K)}var b,c,d,f,e,g,j,m,k,h,n,l,o,q,i,p,r,u,v,B,x,A,y,E,s=[],w=[],C=new THREE.Vector3,K=new THREE.Vector3,M=new THREE.Vector3,N=new THREE.Vector3,t=new THREE.Vector3;b=0;for(c=
-this.vertices.length;b<c;b++){s[b]=new THREE.Vector3;w[b]=new THREE.Vector3}b=0;for(c=this.faces.length;b<c;b++){e=this.faces[b];g=this.faceVertexUvs[0][b];if(e instanceof THREE.Face3)a(this,e.a,e.b,e.c,0,1,2);else if(e instanceof THREE.Face4){a(this,e.a,e.b,e.d,0,1,3);a(this,e.b,e.c,e.d,1,2,3)}}var G=["a","b","c","d"];b=0;for(c=this.faces.length;b<c;b++){e=this.faces[b];for(d=0;d<e.vertexNormals.length;d++){t.copy(e.vertexNormals[d]);f=e[G[d]];E=s[f];M.copy(E);M.subSelf(t.multiplyScalar(t.dot(E))).normalize();
-N.cross(e.vertexNormals[d],E);f=N.dot(w[f]);f=f<0?-1:1;e.vertexTangents[d]=new THREE.Vector4(M.x,M.y,M.z,f)}}this.hasTangents=true},computeBoundingBox:function(){if(!this.boundingBox)this.boundingBox={min:new THREE.Vector3,max:new THREE.Vector3};if(this.vertices.length>0){var a;a=this.vertices[0];this.boundingBox.min.copy(a);this.boundingBox.max.copy(a);for(var b=this.boundingBox.min,c=this.boundingBox.max,d=1,f=this.vertices.length;d<f;d++){a=this.vertices[d];if(a.x<b.x)b.x=a.x;else if(a.x>c.x)c.x=
-a.x;if(a.y<b.y)b.y=a.y;else if(a.y>c.y)c.y=a.y;if(a.z<b.z)b.z=a.z;else if(a.z>c.z)c.z=a.z}}else{this.boundingBox.min.set(0,0,0);this.boundingBox.max.set(0,0,0)}},computeBoundingSphere:function(){var a=0;if(this.boundingSphere===null)this.boundingSphere={radius:0};for(var b=0,c=this.vertices.length;b<c;b++){var d=this.vertices[b].lengthSq();d>a&&(a=d)}this.boundingSphere.radius=Math.sqrt(a)},mergeVertices:function(){var a={},b=[],c=[],d,f=Math.pow(10,4),e,g,j,m;e=0;for(g=this.vertices.length;e<g;e++){d=
-this.vertices[e];d=[Math.round(d.x*f),Math.round(d.y*f),Math.round(d.z*f)].join("_");if(a[d]===void 0){a[d]=e;b.push(this.vertices[e]);c[e]=b.length-1}else c[e]=c[a[d]]}e=0;for(g=this.faces.length;e<g;e++){a=this.faces[e];if(a instanceof THREE.Face3){a.a=c[a.a];a.b=c[a.b];a.c=c[a.c]}else if(a instanceof THREE.Face4){a.a=c[a.a];a.b=c[a.b];a.c=c[a.c];a.d=c[a.d];d=[a.a,a.b,a.c,a.d];for(f=3;f>0;f--)if(d.indexOf(a["abcd"[f]])!==f){d.splice(f,1);this.faces[e]=new THREE.Face3(d[0],d[1],d[2],a.normal,a.color,
-a.materialIndex);d=0;for(j=this.faceVertexUvs.length;d<j;d++)(m=this.faceVertexUvs[d][e])&&m.splice(f,1);this.faces[e].vertexColors=a.vertexColors;break}}}c=this.vertices.length-b.length;this.vertices=b;return c},clone:function(){}};THREE.GeometryCount=0;THREE.Camera=function(){THREE.Object3D.call(this);this.matrixWorldInverse=new THREE.Matrix4;this.projectionMatrix=new THREE.Matrix4;this.projectionMatrixInverse=new THREE.Matrix4};THREE.Camera.prototype=Object.create(THREE.Object3D.prototype);
-THREE.Camera.prototype.lookAt=function(a){this.matrix.lookAt(this.position,a,this.up);this.rotationAutoUpdate===true&&this.rotation.setEulerFromRotationMatrix(this.matrix,this.eulerOrder)};THREE.OrthographicCamera=function(a,b,c,d,f,e){THREE.Camera.call(this);this.left=a;this.right=b;this.top=c;this.bottom=d;this.near=f!==void 0?f:0.1;this.far=e!==void 0?e:2E3;this.updateProjectionMatrix()};THREE.OrthographicCamera.prototype=Object.create(THREE.Camera.prototype);
-THREE.OrthographicCamera.prototype.updateProjectionMatrix=function(){this.projectionMatrix.makeOrthographic(this.left,this.right,this.top,this.bottom,this.near,this.far)};THREE.PerspectiveCamera=function(a,b,c,d){THREE.Camera.call(this);this.fov=a!==void 0?a:50;this.aspect=b!==void 0?b:1;this.near=c!==void 0?c:0.1;this.far=d!==void 0?d:2E3;this.updateProjectionMatrix()};THREE.PerspectiveCamera.prototype=Object.create(THREE.Camera.prototype);
-THREE.PerspectiveCamera.prototype.setLens=function(a,b){this.fov=2*Math.atan((b!==void 0?b:24)/(a*2))*(180/Math.PI);this.updateProjectionMatrix()};THREE.PerspectiveCamera.prototype.setViewOffset=function(a,b,c,d,f,e){this.fullWidth=a;this.fullHeight=b;this.x=c;this.y=d;this.width=f;this.height=e;this.updateProjectionMatrix()};
-THREE.PerspectiveCamera.prototype.updateProjectionMatrix=function(){if(this.fullWidth){var a=this.fullWidth/this.fullHeight,b=Math.tan(this.fov*Math.PI/360)*this.near,c=-b,d=a*c,a=Math.abs(a*b-d),c=Math.abs(b-c);this.projectionMatrix.makeFrustum(d+this.x*a/this.fullWidth,d+(this.x+this.width)*a/this.fullWidth,b-(this.y+this.height)*c/this.fullHeight,b-this.y*c/this.fullHeight,this.near,this.far)}else this.projectionMatrix.makePerspective(this.fov,this.aspect,this.near,this.far)};
-THREE.Light=function(a){THREE.Object3D.call(this);this.color=new THREE.Color(a)};THREE.Light.prototype=Object.create(THREE.Object3D.prototype);THREE.AmbientLight=function(a){THREE.Light.call(this,a)};THREE.AmbientLight.prototype=Object.create(THREE.Light.prototype);
-THREE.DirectionalLight=function(a,b,c){THREE.Light.call(this,a);this.position=new THREE.Vector3(0,1,0);this.target=new THREE.Object3D;this.intensity=b!==void 0?b:1;this.distance=c!==void 0?c:0;this.onlyShadow=this.castShadow=false;this.shadowCameraNear=50;this.shadowCameraFar=5E3;this.shadowCameraLeft=-500;this.shadowCameraTop=this.shadowCameraRight=500;this.shadowCameraBottom=-500;this.shadowCameraVisible=false;this.shadowBias=0;this.shadowDarkness=0.5;this.shadowMapHeight=this.shadowMapWidth=512;
-this.shadowCascade=false;this.shadowCascadeOffset=new THREE.Vector3(0,0,-1E3);this.shadowCascadeCount=2;this.shadowCascadeBias=[0,0,0];this.shadowCascadeWidth=[512,512,512];this.shadowCascadeHeight=[512,512,512];this.shadowCascadeNearZ=[-1,0.99,0.998];this.shadowCascadeFarZ=[0.99,0.998,1];this.shadowCascadeArray=[];this.shadowMatrix=this.shadowCamera=this.shadowMapSize=this.shadowMap=null};THREE.DirectionalLight.prototype=Object.create(THREE.Light.prototype);
-THREE.PointLight=function(a,b,c){THREE.Light.call(this,a);this.position=new THREE.Vector3(0,0,0);this.intensity=b!==void 0?b:1;this.distance=c!==void 0?c:0};THREE.PointLight.prototype=Object.create(THREE.Light.prototype);THREE.Loader=function(a){this.statusDomElement=(this.showStatus=a)?THREE.Loader.prototype.addStatusElement():null;this.onLoadStart=function(){};this.onLoadProgress=function(){};this.onLoadComplete=function(){}};
-THREE.Loader.prototype={constructor:THREE.Loader,crossOrigin:"anonymous",addStatusElement:function(){var a=document.createElement("div");a.style.position="absolute";a.style.right="0px";a.style.top="0px";a.style.fontSize="0.8em";a.style.textAlign="left";a.style.background="rgba(0,0,0,0.25)";a.style.color="#fff";a.style.width="120px";a.style.padding="0.5em 0.5em 0.5em 0.5em";a.style.zIndex=1E3;a.innerHTML="Loading ...";return a},updateProgress:function(a){var b="Loaded ",b=a.total?b+((100*a.loaded/
-a.total).toFixed(0)+"%"):b+((a.loaded/1E3).toFixed(2)+" KB");this.statusDomElement.innerHTML=b},extractUrlBase:function(a){a=a.split("/");a.pop();return(a.length<1?".":a.join("/"))+"/"},initMaterials:function(a,b,c){a.materials=[];for(var d=0;d<b.length;++d)a.materials[d]=THREE.Loader.prototype.createMaterial(b[d],c)},hasNormals:function(a){var b,c,d=a.materials.length;for(c=0;c<d;c++){b=a.materials[c];if(b instanceof THREE.ShaderMaterial)return true}return false},createMaterial:function(a,b){function c(a){a=
-Math.log(a)/Math.LN2;return Math.floor(a)==a}function d(a){a=Math.log(a)/Math.LN2;return Math.pow(2,Math.round(a))}function f(a,b){var e=new Image;e.onload=function(){if(!c(this.width)||!c(this.height)){var b=d(this.width),e=d(this.height);a.image.width=b;a.image.height=e;a.image.getContext("2d").drawImage(this,0,0,b,e)}else a.image=this;a.needsUpdate=true};e.crossOrigin=j.crossOrigin;e.src=b}function e(a,c,d,e,g,h){var j=document.createElement("canvas");a[c]=new THREE.Texture(j);a[c].sourceFile=
-d;if(e){a[c].repeat.set(e[0],e[1]);if(e[0]!==1)a[c].wrapS=THREE.RepeatWrapping;if(e[1]!==1)a[c].wrapT=THREE.RepeatWrapping}g&&a[c].offset.set(g[0],g[1]);if(h){e={repeat:THREE.RepeatWrapping,mirror:THREE.MirroredRepeatWrapping};if(e[h[0]]!==void 0)a[c].wrapS=e[h[0]];if(e[h[1]]!==void 0)a[c].wrapT=e[h[1]]}f(a[c],b+"/"+d)}function g(a){return(a[0]*255<<16)+(a[1]*255<<8)+a[2]*255}var j=this,m="MeshLambertMaterial",k={color:15658734,opacity:1,map:null,lightMap:null,normalMap:null,bumpMap:null,wireframe:false};
-if(a.shading){var h=a.shading.toLowerCase();h==="phong"?m="MeshPhongMaterial":h==="basic"&&(m="MeshBasicMaterial")}if(a.blending!==void 0&&THREE[a.blending]!==void 0)k.blending=THREE[a.blending];if(a.transparent!==void 0||a.opacity<1)k.transparent=a.transparent;if(a.depthTest!==void 0)k.depthTest=a.depthTest;if(a.depthWrite!==void 0)k.depthWrite=a.depthWrite;if(a.visible!==void 0)k.visible=a.visible;if(a.flipSided!==void 0)k.side=THREE.BackSide;if(a.doubleSided!==void 0)k.side=THREE.DoubleSide;if(a.wireframe!==
-void 0)k.wireframe=a.wireframe;if(a.vertexColors!==void 0)if(a.vertexColors=="face")k.vertexColors=THREE.FaceColors;else if(a.vertexColors)k.vertexColors=THREE.VertexColors;if(a.colorDiffuse)k.color=g(a.colorDiffuse);else if(a.DbgColor)k.color=a.DbgColor;if(a.colorSpecular)k.specular=g(a.colorSpecular);if(a.colorAmbient)k.ambient=g(a.colorAmbient);if(a.transparency)k.opacity=a.transparency;if(a.specularCoef)k.shininess=a.specularCoef;a.mapDiffuse&&b&&e(k,"map",a.mapDiffuse,a.mapDiffuseRepeat,a.mapDiffuseOffset,
-a.mapDiffuseWrap);a.mapLight&&b&&e(k,"lightMap",a.mapLight,a.mapLightRepeat,a.mapLightOffset,a.mapLightWrap);a.mapBump&&b&&e(k,"bumpMap",a.mapBump,a.mapBumpRepeat,a.mapBumpOffset,a.mapBumpWrap);a.mapNormal&&b&&e(k,"normalMap",a.mapNormal,a.mapNormalRepeat,a.mapNormalOffset,a.mapNormalWrap);a.mapSpecular&&b&&e(k,"specularMap",a.mapSpecular,a.mapSpecularRepeat,a.mapSpecularOffset,a.mapSpecularWrap);if(a.mapNormal){m=THREE.ShaderUtils.lib.normal;h=THREE.UniformsUtils.clone(m.uniforms);h.tNormal.texture=
-k.normalMap;if(a.mapNormalFactor)h.uNormalScale.value=a.mapNormalFactor;if(k.map){h.tDiffuse.texture=k.map;h.enableDiffuse.value=true}if(k.specularMap){h.tSpecular.texture=k.specularMap;h.enableSpecular.value=true}if(k.lightMap){h.tAO.texture=k.lightMap;h.enableAO.value=true}h.uDiffuseColor.value.setHex(k.color);h.uSpecularColor.value.setHex(k.specular);h.uAmbientColor.value.setHex(k.ambient);h.uShininess.value=k.shininess;if(k.opacity!==void 0)h.uOpacity.value=k.opacity;k=new THREE.ShaderMaterial({fragmentShader:m.fragmentShader,
-vertexShader:m.vertexShader,uniforms:h,lights:true,fog:true})}else k=new THREE[m](k);if(a.DbgName!==void 0)k.name=a.DbgName;return k}};THREE.BinaryLoader=function(a){THREE.Loader.call(this,a)};THREE.BinaryLoader.prototype=Object.create(THREE.Loader.prototype);THREE.BinaryLoader.prototype.load=function(a,b,c,d){var c=c?c:this.extractUrlBase(a),d=d?d:this.extractUrlBase(a),f=this.showProgress?THREE.Loader.prototype.updateProgress:null;this.onLoadStart();this.loadAjaxJSON(this,a,b,c,d,f)};
-THREE.BinaryLoader.prototype.loadAjaxJSON=function(a,b,c,d,f,e){var g=new XMLHttpRequest;g.onreadystatechange=function(){if(g.readyState==4)if(g.status==200||g.status==0){var j=JSON.parse(g.responseText);a.loadAjaxBuffers(j,c,f,d,e)}else console.error("THREE.BinaryLoader: Couldn't load ["+b+"] ["+g.status+"]")};g.open("GET",b,true);g.overrideMimeType&&g.overrideMimeType("text/plain; charset=x-user-defined");g.setRequestHeader("Content-Type","text/plain");g.send(null)};
-THREE.BinaryLoader.prototype.loadAjaxBuffers=function(a,b,c,d,f){var e=new XMLHttpRequest,g=c+"/"+a.buffers,j=0;e.onreadystatechange=function(){if(e.readyState==4)if(e.status==200||e.status==0){var c=e.response;if(c===void 0)c=(new Uint8Array(e.responseBody)).buffer;THREE.BinaryLoader.prototype.createBinModel(c,b,d,a.materials)}else console.error("THREE.BinaryLoader: Couldn't load ["+g+"] ["+e.status+"]");else if(e.readyState==3){if(f){j==0&&(j=e.getResponseHeader("Content-Length"));f({total:j,loaded:e.responseText.length})}}else e.readyState==
-2&&(j=e.getResponseHeader("Content-Length"))};e.open("GET",g,true);e.responseType="arraybuffer";e.send(null)};
-THREE.BinaryLoader.prototype.createBinModel=function(a,b,c,d){var f=function(b){var c,f,m,k,h,n,l,o,q,i,p,r,u,v,B;function x(a){return a%4?4-a%4:0}function A(a,b){return(new Uint8Array(a,b,1))[0]}function y(a,b){return(new Uint32Array(a,b,1))[0]}function E(b,c){var d,e,g,f,h,j,k,m,i=new Uint32Array(a,c,3*b);for(d=0;d<b;d++){e=i[d*3];g=i[d*3+1];f=i[d*3+2];h=I[e*2];e=I[e*2+1];j=I[g*2];k=I[g*2+1];g=I[f*2];m=I[f*2+1];f=N.faceVertexUvs[0];var l=[];l.push(new THREE.UV(h,e));l.push(new THREE.UV(j,k));l.push(new THREE.UV(g,
-m));f.push(l)}}function s(b,c){var d,e,g,f,h,j,k,m,i,l,n=new Uint32Array(a,c,4*b);for(d=0;d<b;d++){e=n[d*4];g=n[d*4+1];f=n[d*4+2];h=n[d*4+3];j=I[e*2];e=I[e*2+1];k=I[g*2];i=I[g*2+1];m=I[f*2];l=I[f*2+1];f=I[h*2];g=I[h*2+1];h=N.faceVertexUvs[0];var o=[];o.push(new THREE.UV(j,e));o.push(new THREE.UV(k,i));o.push(new THREE.UV(m,l));o.push(new THREE.UV(f,g));h.push(o)}}function w(b,c,d){for(var e,g,f,h,c=new Uint32Array(a,c,3*b),j=new Uint16Array(a,d,b),d=0;d<b;d++){e=c[d*3];g=c[d*3+1];f=c[d*3+2];h=j[d];
-N.faces.push(new THREE.Face3(e,g,f,null,null,h))}}function C(b,c,d){for(var e,g,f,h,j,c=new Uint32Array(a,c,4*b),k=new Uint16Array(a,d,b),d=0;d<b;d++){e=c[d*4];g=c[d*4+1];f=c[d*4+2];h=c[d*4+3];j=k[d];N.faces.push(new THREE.Face4(e,g,f,h,null,null,j))}}function K(b,c,d,e){for(var g,f,h,j,k,m,i,c=new Uint32Array(a,c,3*b),d=new Uint32Array(a,d,3*b),l=new Uint16Array(a,e,b),e=0;e<b;e++){g=c[e*3];f=c[e*3+1];h=c[e*3+2];k=d[e*3];m=d[e*3+1];i=d[e*3+2];j=l[e];var n=G[m*3],o=G[m*3+1];m=G[m*3+2];var p=G[i*3],
-q=G[i*3+1];i=G[i*3+2];N.faces.push(new THREE.Face3(g,f,h,[new THREE.Vector3(G[k*3],G[k*3+1],G[k*3+2]),new THREE.Vector3(n,o,m),new THREE.Vector3(p,q,i)],null,j))}}function M(b,c,d,e){for(var g,f,h,j,k,m,i,l,n,c=new Uint32Array(a,c,4*b),d=new Uint32Array(a,d,4*b),o=new Uint16Array(a,e,b),e=0;e<b;e++){g=c[e*4];f=c[e*4+1];h=c[e*4+2];j=c[e*4+3];m=d[e*4];i=d[e*4+1];l=d[e*4+2];n=d[e*4+3];k=o[e];var p=G[i*3],q=G[i*3+1];i=G[i*3+2];var r=G[l*3],s=G[l*3+1];l=G[l*3+2];var t=G[n*3],w=G[n*3+1];n=G[n*3+2];N.faces.push(new THREE.Face4(g,
-f,h,j,[new THREE.Vector3(G[m*3],G[m*3+1],G[m*3+2]),new THREE.Vector3(p,q,i),new THREE.Vector3(r,s,l),new THREE.Vector3(t,w,n)],null,k))}}var N=this,t=0,G=[],I=[],O,P,R;THREE.Geometry.call(this);THREE.Loader.prototype.initMaterials(N,d,b);(function(a,b,c){for(var a=new Uint8Array(a,b,c),d="",e=0;e<c;e++)d=d+String.fromCharCode(a[b+e]);return d})(a,t,12);c=A(a,t+12);A(a,t+13);A(a,t+14);A(a,t+15);f=A(a,t+16);m=A(a,t+17);k=A(a,t+18);h=A(a,t+19);n=y(a,t+20);l=y(a,t+20+4);o=y(a,t+20+8);b=y(a,t+20+12);q=
-y(a,t+20+16);i=y(a,t+20+20);p=y(a,t+20+24);r=y(a,t+20+28);u=y(a,t+20+32);v=y(a,t+20+36);B=y(a,t+20+40);t=t+c;c=f*3+h;R=f*4+h;O=b*c;P=q*(c+m*3);f=i*(c+k*3);h=p*(c+m*3+k*3);c=r*R;m=u*(R+m*4);k=v*(R+k*4);t=t+function(b){var b=new Float32Array(a,b,n*3),c,d,e,g;for(c=0;c<n;c++){d=b[c*3];e=b[c*3+1];g=b[c*3+2];N.vertices.push(new THREE.Vector3(d,e,g))}return n*3*Float32Array.BYTES_PER_ELEMENT}(t);t=t+function(b){if(l){var b=new Int8Array(a,b,l*3),c,d,e,g;for(c=0;c<l;c++){d=b[c*3];e=b[c*3+1];g=b[c*3+2];G.push(d/
-127,e/127,g/127)}}return l*3*Int8Array.BYTES_PER_ELEMENT}(t);t=t+x(l*3);t=t+function(b){if(o){var b=new Float32Array(a,b,o*2),c,d,e;for(c=0;c<o;c++){d=b[c*2];e=b[c*2+1];I.push(d,e)}}return o*2*Float32Array.BYTES_PER_ELEMENT}(t);O=t+O+x(b*2);P=O+P+x(q*2);f=P+f+x(i*2);h=f+h+x(p*2);c=h+c+x(r*2);m=c+m+x(u*2);k=m+k+x(v*2);(function(a){if(i){var b=a+i*Uint32Array.BYTES_PER_ELEMENT*3;w(i,a,b+i*Uint32Array.BYTES_PER_ELEMENT*3);E(i,b)}})(P);(function(a){if(p){var b=a+p*Uint32Array.BYTES_PER_ELEMENT*3,c=b+
-p*Uint32Array.BYTES_PER_ELEMENT*3;K(p,a,b,c+p*Uint32Array.BYTES_PER_ELEMENT*3);E(p,c)}})(f);(function(a){if(v){var b=a+v*Uint32Array.BYTES_PER_ELEMENT*4;C(v,a,b+v*Uint32Array.BYTES_PER_ELEMENT*4);s(v,b)}})(m);(function(a){if(B){var b=a+B*Uint32Array.BYTES_PER_ELEMENT*4,c=b+B*Uint32Array.BYTES_PER_ELEMENT*4;M(B,a,b,c+B*Uint32Array.BYTES_PER_ELEMENT*4);s(B,c)}})(k);b&&w(b,t,t+b*Uint32Array.BYTES_PER_ELEMENT*3);(function(a){if(q){var b=a+q*Uint32Array.BYTES_PER_ELEMENT*3;K(q,a,b,b+q*Uint32Array.BYTES_PER_ELEMENT*
-3)}})(O);r&&C(r,h,h+r*Uint32Array.BYTES_PER_ELEMENT*4);(function(a){if(u){var b=a+u*Uint32Array.BYTES_PER_ELEMENT*4;M(u,a,b,b+u*Uint32Array.BYTES_PER_ELEMENT*4)}})(c);this.computeCentroids();this.computeFaceNormals();THREE.Loader.prototype.hasNormals(this)&&this.computeTangents()};f.prototype=Object.create(THREE.Geometry.prototype);b(new f(c))};THREE.ImageLoader=function(){THREE.EventTarget.call(this);this.crossOrigin=null};
-THREE.ImageLoader.prototype={constructor:THREE.ImageLoader,load:function(a,b){var c=this;b===void 0&&(b=new Image);b.addEventListener("load",function(){c.dispatchEvent({type:"load",content:b})},false);b.addEventListener("error",function(){c.dispatchEvent({type:"error",message:"Couldn't load URL ["+a+"]"})},false);if(c.crossOrigin)b.crossOrigin=c.crossOrigin;b.src=a}};THREE.JSONLoader=function(a){THREE.Loader.call(this,a)};THREE.JSONLoader.prototype=Object.create(THREE.Loader.prototype);
-THREE.JSONLoader.prototype.load=function(a,b,c){c=c?c:this.extractUrlBase(a);this.onLoadStart();this.loadAjaxJSON(this,a,b,c)};
-THREE.JSONLoader.prototype.loadAjaxJSON=function(a,b,c,d,f){var e=new XMLHttpRequest,g=0;e.onreadystatechange=function(){if(e.readyState===e.DONE)if(e.status===200||e.status===0){if(e.responseText){var j=JSON.parse(e.responseText);a.createModel(j,c,d)}else console.warn("THREE.JSONLoader: ["+b+"] seems to be unreachable or file there is empty");a.onLoadComplete()}else console.error("THREE.JSONLoader: Couldn't load ["+b+"] ["+e.status+"]");else if(e.readyState===e.LOADING){if(f){g===0&&(g=e.getResponseHeader("Content-Length"));
-f({total:g,loaded:e.responseText.length})}}else e.readyState===e.HEADERS_RECEIVED&&(g=e.getResponseHeader("Content-Length"))};e.open("GET",b,true);e.overrideMimeType&&e.overrideMimeType("text/plain; charset=x-user-defined");e.setRequestHeader("Content-Type","text/plain");e.send(null)};
-THREE.JSONLoader.prototype.createModel=function(a,b,c){var d=new THREE.Geometry,f=a.scale!==void 0?1/a.scale:1;this.initMaterials(d,a.materials,c);(function(b){var c,f,m,k,h,n,l,o,q,i,p,r,u,v,B=a.faces;n=a.vertices;var x=a.normals,A=a.colors,y=0;for(c=0;c<a.uvs.length;c++)a.uvs[c].length&&y++;for(c=0;c<y;c++){d.faceUvs[c]=[];d.faceVertexUvs[c]=[]}k=0;for(h=n.length;k<h;){l=new THREE.Vector3;l.x=n[k++]*b;l.y=n[k++]*b;l.z=n[k++]*b;d.vertices.push(l)}k=0;for(h=B.length;k<h;){b=B[k++];n=b&1;m=b&2;c=b&
-4;f=b&8;o=b&16;l=b&32;i=b&64;b=b&128;if(n){p=new THREE.Face4;p.a=B[k++];p.b=B[k++];p.c=B[k++];p.d=B[k++];n=4}else{p=new THREE.Face3;p.a=B[k++];p.b=B[k++];p.c=B[k++];n=3}if(m){m=B[k++];p.materialIndex=m}m=d.faces.length;if(c)for(c=0;c<y;c++){r=a.uvs[c];q=B[k++];v=r[q*2];q=r[q*2+1];d.faceUvs[c][m]=new THREE.UV(v,q)}if(f)for(c=0;c<y;c++){r=a.uvs[c];u=[];for(f=0;f<n;f++){q=B[k++];v=r[q*2];q=r[q*2+1];u[f]=new THREE.UV(v,q)}d.faceVertexUvs[c][m]=u}if(o){o=B[k++]*3;f=new THREE.Vector3;f.x=x[o++];f.y=x[o++];
-f.z=x[o];p.normal=f}if(l)for(c=0;c<n;c++){o=B[k++]*3;f=new THREE.Vector3;f.x=x[o++];f.y=x[o++];f.z=x[o];p.vertexNormals.push(f)}if(i){l=B[k++];l=new THREE.Color(A[l]);p.color=l}if(b)for(c=0;c<n;c++){l=B[k++];l=new THREE.Color(A[l]);p.vertexColors.push(l)}d.faces.push(p)}})(f);(function(){var b,c,f,m;if(a.skinWeights){b=0;for(c=a.skinWeights.length;b<c;b=b+2){f=a.skinWeights[b];m=a.skinWeights[b+1];d.skinWeights.push(new THREE.Vector4(f,m,0,0))}}if(a.skinIndices){b=0;for(c=a.skinIndices.length;b<c;b=
-b+2){f=a.skinIndices[b];m=a.skinIndices[b+1];d.skinIndices.push(new THREE.Vector4(f,m,0,0))}}d.bones=a.bones;d.animation=a.animation})();(function(b){if(a.morphTargets!==void 0){var c,f,m,k,h,n;c=0;for(f=a.morphTargets.length;c<f;c++){d.morphTargets[c]={};d.morphTargets[c].name=a.morphTargets[c].name;d.morphTargets[c].vertices=[];h=d.morphTargets[c].vertices;n=a.morphTargets[c].vertices;m=0;for(k=n.length;m<k;m=m+3){var l=new THREE.Vector3;l.x=n[m]*b;l.y=n[m+1]*b;l.z=n[m+2]*b;h.push(l)}}}if(a.morphColors!==
-void 0){c=0;for(f=a.morphColors.length;c<f;c++){d.morphColors[c]={};d.morphColors[c].name=a.morphColors[c].name;d.morphColors[c].colors=[];k=d.morphColors[c].colors;h=a.morphColors[c].colors;b=0;for(m=h.length;b<m;b=b+3){n=new THREE.Color(16755200);n.setRGB(h[b],h[b+1],h[b+2]);k.push(n)}}}})(f);d.computeCentroids();d.computeFaceNormals();this.hasNormals(d)&&d.computeTangents();b(d)};THREE.GeometryLoader=function(){THREE.EventTarget.call(this);this.path=this.crossOrigin=null};
-THREE.GeometryLoader.prototype={constructor:THREE.GeometryLoader,load:function(a){var b=this,c=null;if(b.path===null){var d=a.split("/");d.pop();b.path=d.length<1?".":d.join("/")}d=new XMLHttpRequest;d.addEventListener("load",function(d){d.target.responseText?c=b.parse(JSON.parse(d.target.responseText),f):b.dispatchEvent({type:"error",message:"Invalid file ["+a+"]"})},false);d.addEventListener("error",function(){b.dispatchEvent({type:"error",message:"Couldn't load URL ["+a+"]"})},false);d.open("GET",
-a,true);d.send(null);var f=new THREE.LoadingMonitor;f.addEventListener("load",function(){b.dispatchEvent({type:"load",content:c})});f.add(d)},parse:function(a,b){var c=this,d=new THREE.Geometry,f=a.scale!==void 0?1/a.scale:1;if(a.materials){d.materials=[];for(var e=0;e<a.materials.length;++e){var g=a.materials[e],j=function(a){a=Math.log(a)/Math.LN2;return Math.floor(a)==a},m=function(a){a=Math.log(a)/Math.LN2;return Math.pow(2,Math.round(a))},k=function(a,d,e,f,g,h){a[d]=new THREE.Texture;a[d].sourceFile=
-e;if(f){a[d].repeat.set(f[0],f[1]);if(f[0]!==1)a[d].wrapS=THREE.RepeatWrapping;if(f[1]!==1)a[d].wrapT=THREE.RepeatWrapping}g&&a[d].offset.set(g[0],g[1]);if(h){f={repeat:THREE.RepeatWrapping,mirror:THREE.MirroredRepeatWrapping};if(f[h[0]]!==void 0)a[d].wrapS=f[h[0]];if(f[h[1]]!==void 0)a[d].wrapT=f[h[1]]}var k=a[d],a=new THREE.ImageLoader;a.addEventListener("load",function(a){a=a.content;if(!j(a.width)||!j(a.height)){var b=m(a.width),c=m(a.height);k.image=document.createElement("canvas");k.image.width=
-b;k.image.height=c;k.image.getContext("2d").drawImage(a,0,0,b,c)}else k.image=a;k.needsUpdate=true});a.crossOrigin=c.crossOrigin;a.load(c.path+"/"+e);b&&b.add(a)},h=function(a){return(a[0]*255<<16)+(a[1]*255<<8)+a[2]*255},n="MeshLambertMaterial",l={color:15658734,opacity:1,map:null,lightMap:null,normalMap:null,bumpMap:null,wireframe:false};if(g.shading){var o=g.shading.toLowerCase();o==="phong"?n="MeshPhongMaterial":o==="basic"&&(n="MeshBasicMaterial")}if(g.blending!==void 0&&THREE[g.blending]!==
-void 0)l.blending=THREE[g.blending];if(g.transparent!==void 0||g.opacity<1)l.transparent=g.transparent;if(g.depthTest!==void 0)l.depthTest=g.depthTest;if(g.depthWrite!==void 0)l.depthWrite=g.depthWrite;if(g.vertexColors!==void 0)if(g.vertexColors=="face")l.vertexColors=THREE.FaceColors;else if(g.vertexColors)l.vertexColors=THREE.VertexColors;if(g.colorDiffuse)l.color=h(g.colorDiffuse);else if(g.DbgColor)l.color=g.DbgColor;if(g.colorSpecular)l.specular=h(g.colorSpecular);if(g.colorAmbient)l.ambient=
-h(g.colorAmbient);if(g.transparency)l.opacity=g.transparency;if(g.specularCoef)l.shininess=g.specularCoef;if(g.visible!==void 0)l.visible=g.visible;if(g.flipSided!==void 0)l.side=THREE.BackSide;if(g.doubleSided!==void 0)l.side=THREE.DoubleSide;if(g.wireframe!==void 0)l.wireframe=g.wireframe;g.mapDiffuse&&k(l,"map",g.mapDiffuse,g.mapDiffuseRepeat,g.mapDiffuseOffset,g.mapDiffuseWrap);g.mapLight&&k(l,"lightMap",g.mapLight,g.mapLightRepeat,g.mapLightOffset,g.mapLightWrap);g.mapBump&&k(l,"bumpMap",g.mapBump,
-g.mapBumpRepeat,g.mapBumpOffset,g.mapBumpWrap);g.mapNormal&&k(l,"normalMap",g.mapNormal,g.mapNormalRepeat,g.mapNormalOffset,g.mapNormalWrap);g.mapSpecular&&k(l,"specularMap",g.mapSpecular,g.mapSpecularRepeat,g.mapSpecularOffset,g.mapSpecularWrap);if(g.mapNormal){k=THREE.ShaderUtils.lib.normal;h=THREE.UniformsUtils.clone(k.uniforms);h.tNormal.texture=l.normalMap;if(g.mapNormalFactor)h.uNormalScale.value=g.mapNormalFactor;if(l.map){h.tDiffuse.texture=l.map;h.enableDiffuse.value=true}if(l.specularMap){h.tSpecular.texture=
-l.specularMap;h.enableSpecular.value=true}if(l.lightMap){h.tAO.texture=l.lightMap;h.enableAO.value=true}h.uDiffuseColor.value.setHex(l.color);h.uSpecularColor.value.setHex(l.specular);h.uAmbientColor.value.setHex(l.ambient);h.uShininess.value=l.shininess;if(l.opacity!==void 0)h.uOpacity.value=l.opacity;l=new THREE.ShaderMaterial({fragmentShader:k.fragmentShader,vertexShader:k.vertexShader,uniforms:h,lights:true,fog:true})}else l=new THREE[n](l);if(g.DbgName!==void 0)l.name=g.DbgName;d.materials[e]=
-l}}var g=a.faces,q=a.vertices,l=a.normals,k=a.colors,h=0;if(a.uvs)for(e=0;e<a.uvs.length;e++)a.uvs[e].length&&h++;for(e=0;e<h;e++){d.faceUvs[e]=[];d.faceVertexUvs[e]=[]}n=0;for(o=q.length;n<o;){var i=new THREE.Vector3;i.x=q[n++]*f;i.y=q[n++]*f;i.z=q[n++]*f;d.vertices.push(i)}n=0;for(o=g.length;n<o;){var p=g[n++],r=p&2,e=p&4,u=p&8,v=p&16,q=p&32,B=p&64,i=p&128;if(p&1){p=new THREE.Face4;p.a=g[n++];p.b=g[n++];p.c=g[n++];p.d=g[n++];var x=4}else{p=new THREE.Face3;p.a=g[n++];p.b=g[n++];p.c=g[n++];x=3}if(r){r=
-g[n++];p.materialIndex=r}var A=d.faces.length;if(e)for(e=0;e<h;e++){var y=a.uvs[e],r=g[n++],E=y[r*2],r=y[r*2+1];d.faceUvs[e][A]=new THREE.UV(E,r)}if(u)for(e=0;e<h;e++){for(var y=a.uvs[e],u=[],s=0;s<x;s++){r=g[n++];E=y[r*2];r=y[r*2+1];u[s]=new THREE.UV(E,r)}d.faceVertexUvs[e][A]=u}if(v){v=g[n++]*3;r=new THREE.Vector3;r.x=l[v++];r.y=l[v++];r.z=l[v];p.normal=r}if(q)for(e=0;e<x;e++){v=g[n++]*3;r=new THREE.Vector3;r.x=l[v++];r.y=l[v++];r.z=l[v];p.vertexNormals.push(r)}if(B){q=g[n++];p.color=new THREE.Color(k[q])}if(i)for(e=
-0;e<x;e++){q=g[n++];p.vertexColors.push(new THREE.Color(k[q]))}d.faces.push(p)}if(a.skinWeights){e=0;for(g=a.skinWeights.length;e<g;e=e+2)d.skinWeights.push(new THREE.Vector4(a.skinWeights[e],a.skinWeights[e+1],0,0))}if(a.skinIndices){e=0;for(g=a.skinIndices.length;e<g;e=e+2){l=0;d.skinIndices.push(new THREE.Vector4(a.skinIndices[e],a.skinIndices[e+1],l,0))}}d.bones=a.bones;d.animation=a.animation;if(a.morphTargets){e=0;for(g=a.morphTargets.length;e<g;e++){d.morphTargets[e]={};d.morphTargets[e].name=
-a.morphTargets[e].name;d.morphTargets[e].vertices=[];l=d.morphTargets[e].vertices;k=a.morphTargets[e].vertices;r=0;for(h=k.length;r<h;r=r+3){i=new THREE.Vector3;i.x=k[r]*f;i.y=k[r+1]*f;i.z=k[r+2]*f;l.push(i)}}}if(a.morphColors){e=0;for(g=a.morphColors.length;e<g;e++){d.morphColors[e]={};d.morphColors[e].name=a.morphColors[e].name;d.morphColors[e].colors=[];f=d.morphColors[e].colors;k=a.morphColors[e].colors;l=0;for(h=k.length;l<h;l=l+3){n=new THREE.Color(16755200);n.setRGB(k[l],k[l+1],k[l+2]);f.push(n)}}}d.computeCentroids();
-d.computeFaceNormals();return d}};THREE.SceneLoader=function(){this.onLoadStart=function(){};this.onLoadProgress=function(){};this.onLoadComplete=function(){};this.callbackSync=function(){};this.callbackProgress=function(){}};THREE.SceneLoader.prototype.constructor=THREE.SceneLoader;
-THREE.SceneLoader.prototype.load=function(a,b){var c=this,d=new XMLHttpRequest;d.onreadystatechange=function(){if(d.readyState===4)if(d.status===200||d.status===0){var f=JSON.parse(d.responseText);c.createScene(f,b,a)}else console.error("THREE.SceneLoader: Couldn't load ["+a+"] ["+d.status+"]")};d.open("GET",a,true);d.overrideMimeType&&d.overrideMimeType("text/plain; charset=x-user-defined");d.setRequestHeader("Content-Type","text/plain");d.send(null)};
-THREE.SceneLoader.prototype.createScene=function(a,b,c){function d(a,b){return b=="relativeToHTML"?a:k+"/"+a}function f(a,b){var c;for(l in b)if(z.objects[l]===void 0){r=b[l];if(r.geometry!==void 0){if(C=z.geometries[r.geometry]){c=false;K=z.materials[r.materials[0]];(c=K instanceof THREE.ShaderMaterial)&&C.computeTangents();x=r.position;A=r.rotation;y=r.quaternion;E=r.scale;u=r.matrix;y=0;r.materials.length==0&&(K=new THREE.MeshFaceMaterial);r.materials.length>1&&(K=new THREE.MeshFaceMaterial);c=
-new THREE.Mesh(C,K);c.name=l;if(u){c.matrixAutoUpdate=false;c.matrix.set(u[0],u[1],u[2],u[3],u[4],u[5],u[6],u[7],u[8],u[9],u[10],u[11],u[12],u[13],u[14],u[15])}else{c.position.set(x[0],x[1],x[2]);if(y){c.quaternion.set(y[0],y[1],y[2],y[3]);c.useQuaternion=true}else c.rotation.set(A[0],A[1],A[2]);c.scale.set(E[0],E[1],E[2])}c.visible=r.visible;c.castShadow=r.castShadow;c.receiveShadow=r.receiveShadow;a.add(c);z.objects[l]=c}}else{x=r.position;A=r.rotation;y=r.quaternion;E=r.scale;y=0;c=new THREE.Object3D;
-c.name=l;c.position.set(x[0],x[1],x[2]);if(y){c.quaternion.set(y[0],y[1],y[2],y[3]);c.useQuaternion=true}else c.rotation.set(A[0],A[1],A[2]);c.scale.set(E[0],E[1],E[2]);c.visible=r.visible!==void 0?r.visible:false;a.add(c);z.objects[l]=c;z.empties[l]=c}if(r.properties!==void 0)for(var d in r.properties)c.properties[d]=r.properties[d];r.children!==void 0&&f(c,r.children)}}function e(a){return function(b){z.geometries[a]=b;f(z.scene,t.objects);I=I-1;m.onLoadComplete();j()}}function g(a){return function(b){z.geometries[a]=
-b}}function j(){m.callbackProgress({totalModels:P,totalTextures:R,loadedModels:P-I,loadedTextures:R-O},z);m.onLoadProgress();I===0&&O===0&&b(z)}var m=this,k=THREE.Loader.prototype.extractUrlBase(c),h,n,l,o,q,i,p,r,u,v,B,x,A,y,E,s,w,C,K,M,N,t,G,I,O,P,R,z;t=a;c=new THREE.BinaryLoader;G=new THREE.JSONLoader;O=I=0;z={scene:new THREE.Scene,geometries:{},materials:{},textures:{},objects:{},cameras:{},lights:{},fogs:{},empties:{}};if(t.transform){a=t.transform.position;v=t.transform.rotation;s=t.transform.scale;
-a&&z.scene.position.set(a[0],a[1],a[2]);v&&z.scene.rotation.set(v[0],v[1],v[2]);s&&z.scene.scale.set(s[0],s[1],s[2]);if(a||v||s){z.scene.updateMatrix();z.scene.updateMatrixWorld()}}a=function(a){return function(){O=O-a;j();m.onLoadComplete()}};for(q in t.cameras){s=t.cameras[q];s.type==="perspective"?M=new THREE.PerspectiveCamera(s.fov,s.aspect,s.near,s.far):s.type==="ortho"&&(M=new THREE.OrthographicCamera(s.left,s.right,s.top,s.bottom,s.near,s.far));x=s.position;v=s.target;s=s.up;M.position.set(x[0],
-x[1],x[2]);M.target=new THREE.Vector3(v[0],v[1],v[2]);s&&M.up.set(s[0],s[1],s[2]);z.cameras[q]=M}for(o in t.lights){v=t.lights[o];q=v.color!==void 0?v.color:16777215;M=v.intensity!==void 0?v.intensity:1;if(v.type==="directional"){x=v.direction;B=new THREE.DirectionalLight(q,M);B.position.set(x[0],x[1],x[2]);B.position.normalize()}else if(v.type==="point"){x=v.position;B=v.distance;B=new THREE.PointLight(q,M,B);B.position.set(x[0],x[1],x[2])}else v.type==="ambient"&&(B=new THREE.AmbientLight(q));z.scene.add(B);
-z.lights[o]=B}for(i in t.fogs){o=t.fogs[i];o.type==="linear"?N=new THREE.Fog(0,o.near,o.far):o.type==="exp2"&&(N=new THREE.FogExp2(0,o.density));s=o.color;N.color.setRGB(s[0],s[1],s[2]);z.fogs[i]=N}if(z.cameras&&t.defaults.camera)z.currentCamera=z.cameras[t.defaults.camera];if(z.fogs&&t.defaults.fog)z.scene.fog=z.fogs[t.defaults.fog];s=t.defaults.bgcolor;z.bgColor=new THREE.Color;z.bgColor.setRGB(s[0],s[1],s[2]);z.bgColorAlpha=t.defaults.bgalpha;for(h in t.geometries){i=t.geometries[h];if(i.type==
-"bin_mesh"||i.type=="ascii_mesh"){I=I+1;m.onLoadStart()}}P=I;for(h in t.geometries){i=t.geometries[h];if(i.type==="cube"){C=new THREE.CubeGeometry(i.width,i.height,i.depth,i.segmentsWidth,i.segmentsHeight,i.segmentsDepth,null,i.flipped,i.sides);z.geometries[h]=C}else if(i.type==="plane"){C=new THREE.PlaneGeometry(i.width,i.height,i.segmentsWidth,i.segmentsHeight);z.geometries[h]=C}else if(i.type==="sphere"){C=new THREE.SphereGeometry(i.radius,i.segmentsWidth,i.segmentsHeight);z.geometries[h]=C}else if(i.type===
-"cylinder"){C=new THREE.CylinderGeometry(i.topRad,i.botRad,i.height,i.radSegs,i.heightSegs);z.geometries[h]=C}else if(i.type==="torus"){C=new THREE.TorusGeometry(i.radius,i.tube,i.segmentsR,i.segmentsT);z.geometries[h]=C}else if(i.type==="icosahedron"){C=new THREE.IcosahedronGeometry(i.radius,i.subdivisions);z.geometries[h]=C}else if(i.type==="bin_mesh")c.load(d(i.url,t.urlBaseType),e(h));else if(i.type==="ascii_mesh")G.load(d(i.url,t.urlBaseType),e(h));else if(i.type==="embedded_mesh"){i=t.embeds[i.id];
-i.metadata=t.metadata;i&&G.createModel(i,g(h),"")}}for(p in t.textures){h=t.textures[p];if(h.url instanceof Array){O=O+h.url.length;for(i=0;i<h.url.length;i++)m.onLoadStart()}else{O=O+1;m.onLoadStart()}}R=O;for(p in t.textures){h=t.textures[p];if(h.mapping!==void 0&&THREE[h.mapping]!==void 0)h.mapping=new THREE[h.mapping];if(h.url instanceof Array){i=h.url.length;N=[];for(c=0;c<i;c++)N[c]=d(h.url[c],t.urlBaseType);i=THREE.ImageUtils.loadTextureCube(N,h.mapping,a(i))}else{i=THREE.ImageUtils.loadTexture(d(h.url,
-t.urlBaseType),h.mapping,a(1));if(THREE[h.minFilter]!==void 0)i.minFilter=THREE[h.minFilter];if(THREE[h.magFilter]!==void 0)i.magFilter=THREE[h.magFilter];if(h.repeat){i.repeat.set(h.repeat[0],h.repeat[1]);if(h.repeat[0]!==1)i.wrapS=THREE.RepeatWrapping;if(h.repeat[1]!==1)i.wrapT=THREE.RepeatWrapping}h.offset&&i.offset.set(h.offset[0],h.offset[1]);if(h.wrap){N={repeat:THREE.RepeatWrapping,mirror:THREE.MirroredRepeatWrapping};if(N[h.wrap[0]]!==void 0)i.wrapS=N[h.wrap[0]];if(N[h.wrap[1]]!==void 0)i.wrapT=
-N[h.wrap[1]]}}z.textures[p]=i}for(n in t.materials){u=t.materials[n];for(w in u.parameters)if(w==="envMap"||w==="map"||w==="lightMap")u.parameters[w]=z.textures[u.parameters[w]];else if(w==="shading")u.parameters[w]=u.parameters[w]=="flat"?THREE.FlatShading:THREE.SmoothShading;else if(w==="blending")u.parameters[w]=u.parameters[w]in THREE?THREE[u.parameters[w]]:THREE.NormalBlending;else if(w==="combine")u.parameters[w]=u.parameters[w]=="MixOperation"?THREE.MixOperation:THREE.MultiplyOperation;else if(w===
-"vertexColors")if(u.parameters[w]=="face")u.parameters[w]=THREE.FaceColors;else if(u.parameters[w])u.parameters[w]=THREE.VertexColors;if(u.parameters.opacity!==void 0&&u.parameters.opacity<1)u.parameters.transparent=true;if(u.parameters.normalMap){p=THREE.ShaderUtils.lib.normal;a=THREE.UniformsUtils.clone(p.uniforms);h=u.parameters.color;i=u.parameters.specular;N=u.parameters.ambient;c=u.parameters.shininess;a.tNormal.texture=z.textures[u.parameters.normalMap];if(u.parameters.normalMapFactor)a.uNormalScale.value=
-u.parameters.normalMapFactor;if(u.parameters.map){a.tDiffuse.texture=u.parameters.map;a.enableDiffuse.value=true}if(u.parameters.lightMap){a.tAO.texture=u.parameters.lightMap;a.enableAO.value=true}if(u.parameters.specularMap){a.tSpecular.texture=z.textures[u.parameters.specularMap];a.enableSpecular.value=true}a.uDiffuseColor.value.setHex(h);a.uSpecularColor.value.setHex(i);a.uAmbientColor.value.setHex(N);a.uShininess.value=c;if(u.parameters.opacity)a.uOpacity.value=u.parameters.opacity;K=new THREE.ShaderMaterial({fragmentShader:p.fragmentShader,
-vertexShader:p.vertexShader,uniforms:a,lights:true,fog:true})}else K=new THREE[u.type](u.parameters);z.materials[n]=K}f(z.scene,t.objects);m.callbackSync(z);j()};THREE.TextureLoader=function(){THREE.EventTarget.call(this);this.crossOrigin=null};
-THREE.TextureLoader.prototype={constructor:THREE.TextureLoader,load:function(a){var b=this,c=new Image;c.addEventListener("load",function(){var a=new THREE.Texture(c);a.needsUpdate=true;b.dispatchEvent({type:"load",content:a})},false);c.addEventListener("error",function(){b.dispatchEvent({type:"error",message:"Couldn't load URL ["+a+"]"})},false);if(b.crossOrigin)c.crossOrigin=b.crossOrigin;c.src=a}};
-THREE.Material=function(){this.id=THREE.MaterialCount++;this.name="";this.side=THREE.FrontSide;this.opacity=1;this.transparent=false;this.blending=THREE.NormalBlending;this.blendSrc=THREE.SrcAlphaFactor;this.blendDst=THREE.OneMinusSrcAlphaFactor;this.blendEquation=THREE.AddEquation;this.depthWrite=this.depthTest=true;this.polygonOffset=false;this.alphaTest=this.polygonOffsetUnits=this.polygonOffsetFactor=0;this.overdraw=false;this.needsUpdate=this.visible=true};
-THREE.Material.prototype.setValues=function(a){if(a!==void 0)for(var b in a){var c=a[b];if(c===void 0)console.warn("THREE.Material: '"+b+"' parameter is undefined.");else if(b in this){var d=this[b];d instanceof THREE.Color&&c instanceof THREE.Color?d.copy(c):d instanceof THREE.Color&&typeof c==="number"?d.setHex(c):d instanceof THREE.Vector3&&c instanceof THREE.Vector3?d.copy(c):this[b]=c}}};
-THREE.Material.prototype.clone=function(a){a===void 0&&(a=new THREE.Material);a.name=this.name;a.side=this.side;a.opacity=this.opacity;a.transparent=this.transparent;a.blending=this.blending;a.blendSrc=this.blendSrc;a.blendDst=this.blendDst;a.blendEquation=this.blendEquation;a.depthTest=this.depthTest;a.depthWrite=this.depthWrite;a.polygonOffset=this.polygonOffset;a.polygonOffsetFactor=this.polygonOffsetFactor;a.polygonOffsetUnits=this.polygonOffsetUnits;a.alphaTest=this.alphaTest;a.overdraw=this.overdraw;
-a.visible=this.visible;return a};THREE.MaterialCount=0;THREE.LineBasicMaterial=function(a){THREE.Material.call(this);this.color=new THREE.Color(16777215);this.linewidth=1;this.linejoin=this.linecap="round";this.vertexColors=false;this.fog=true;this.setValues(a)};THREE.LineBasicMaterial.prototype=Object.create(THREE.Material.prototype);
-THREE.LineBasicMaterial.prototype.clone=function(){var a=new THREE.LineBasicMaterial;THREE.Material.prototype.clone.call(this,a);a.color.copy(this.color);a.linewidth=this.linewidth;a.linecap=this.linecap;a.linejoin=this.linejoin;a.vertexColors=this.vertexColors;a.fog=this.fog;return a};
-THREE.MeshBasicMaterial=function(a){THREE.Material.call(this);this.color=new THREE.Color(16777215);this.envMap=this.specularMap=this.lightMap=this.map=null;this.combine=THREE.MultiplyOperation;this.reflectivity=1;this.refractionRatio=0.98;this.fog=true;this.shading=THREE.SmoothShading;this.wireframe=false;this.wireframeLinewidth=1;this.wireframeLinejoin=this.wireframeLinecap="round";this.vertexColors=THREE.NoColors;this.morphTargets=this.skinning=false;this.setValues(a)};
-THREE.MeshBasicMaterial.prototype=Object.create(THREE.Material.prototype);
-THREE.MeshBasicMaterial.prototype.clone=function(){var a=new THREE.MeshBasicMaterial;THREE.Material.prototype.clone.call(this,a);a.color.copy(this.color);a.map=this.map;a.lightMap=this.lightMap;a.specularMap=this.specularMap;a.envMap=this.envMap;a.combine=this.combine;a.reflectivity=this.reflectivity;a.refractionRatio=this.refractionRatio;a.fog=this.fog;a.shading=this.shading;a.wireframe=this.wireframe;a.wireframeLinewidth=this.wireframeLinewidth;a.wireframeLinecap=this.wireframeLinecap;a.wireframeLinejoin=
-this.wireframeLinejoin;a.vertexColors=this.vertexColors;a.skinning=this.skinning;a.morphTargets=this.morphTargets;return a};
-THREE.MeshLambertMaterial=function(a){THREE.Material.call(this);this.color=new THREE.Color(16777215);this.ambient=new THREE.Color(16777215);this.emissive=new THREE.Color(0);this.wrapAround=false;this.wrapRGB=new THREE.Vector3(1,1,1);this.envMap=this.specularMap=this.lightMap=this.map=null;this.combine=THREE.MultiplyOperation;this.reflectivity=1;this.refractionRatio=0.98;this.fog=true;this.shading=THREE.SmoothShading;this.wireframe=false;this.wireframeLinewidth=1;this.wireframeLinejoin=this.wireframeLinecap=
-"round";this.vertexColors=THREE.NoColors;this.morphNormals=this.morphTargets=this.skinning=false;this.setValues(a)};THREE.MeshLambertMaterial.prototype=Object.create(THREE.Material.prototype);
-THREE.MeshLambertMaterial.prototype.clone=function(){var a=new THREE.MeshLambertMaterial;THREE.Material.prototype.clone.call(this,a);a.color.copy(this.color);a.ambient.copy(this.ambient);a.emissive.copy(this.emissive);a.wrapAround=this.wrapAround;a.wrapRGB.copy(this.wrapRGB);a.map=this.map;a.lightMap=this.lightMap;a.specularMap=this.specularMap;a.envMap=this.envMap;a.combine=this.combine;a.reflectivity=this.reflectivity;a.refractionRatio=this.refractionRatio;a.fog=this.fog;a.shading=this.shading;
-a.wireframe=this.wireframe;a.wireframeLinewidth=this.wireframeLinewidth;a.wireframeLinecap=this.wireframeLinecap;a.wireframeLinejoin=this.wireframeLinejoin;a.vertexColors=this.vertexColors;a.skinning=this.skinning;a.morphTargets=this.morphTargets;a.morphNormals=this.morphNormals;return a};
-THREE.MeshPhongMaterial=function(a){THREE.Material.call(this);this.color=new THREE.Color(16777215);this.ambient=new THREE.Color(16777215);this.emissive=new THREE.Color(0);this.specular=new THREE.Color(1118481);this.shininess=30;this.wrapAround=this.perPixel=this.metal=false;this.wrapRGB=new THREE.Vector3(1,1,1);this.bumpMap=this.lightMap=this.map=null;this.bumpScale=1;this.envMap=this.specularMap=null;this.combine=THREE.MultiplyOperation;this.reflectivity=1;this.refractionRatio=0.98;this.fog=true;
-this.shading=THREE.SmoothShading;this.wireframe=false;this.wireframeLinewidth=1;this.wireframeLinejoin=this.wireframeLinecap="round";this.vertexColors=THREE.NoColors;this.morphNormals=this.morphTargets=this.skinning=false;this.setValues(a)};THREE.MeshPhongMaterial.prototype=Object.create(THREE.Material.prototype);
-THREE.MeshPhongMaterial.prototype.clone=function(){var a=new THREE.MeshPhongMaterial;THREE.Material.prototype.clone.call(this,a);a.color.copy(this.color);a.ambient.copy(this.ambient);a.emissive.copy(this.emissive);a.specular.copy(this.specular);a.shininess=this.shininess;a.metal=this.metal;a.perPixel=this.perPixel;a.wrapAround=this.wrapAround;a.wrapRGB.copy(this.wrapRGB);a.map=this.map;a.lightMap=this.lightMap;a.bumpMap=this.bumpMap;a.bumpScale=this.bumpScale;a.specularMap=this.specularMap;a.envMap=
-this.envMap;a.combine=this.combine;a.reflectivity=this.reflectivity;a.refractionRatio=this.refractionRatio;a.fog=this.fog;a.shading=this.shading;a.wireframe=this.wireframe;a.wireframeLinewidth=this.wireframeLinewidth;a.wireframeLinecap=this.wireframeLinecap;a.wireframeLinejoin=this.wireframeLinejoin;a.vertexColors=this.vertexColors;a.skinning=this.skinning;a.morphTargets=this.morphTargets;a.morphNormals=this.morphNormals;return a};
-THREE.MeshDepthMaterial=function(a){THREE.Material.call(this);this.wireframe=false;this.wireframeLinewidth=1;this.setValues(a)};THREE.MeshDepthMaterial.prototype=Object.create(THREE.Material.prototype);THREE.MeshDepthMaterial.prototype.clone=function(){var a=new THREE.LineBasicMaterial;THREE.Material.prototype.clone.call(this,a);a.wireframe=this.wireframe;a.wireframeLinewidth=this.wireframeLinewidth;return a};
-THREE.MeshNormalMaterial=function(a){THREE.Material.call(this,a);this.shading=THREE.FlatShading;this.wireframe=false;this.wireframeLinewidth=1;this.setValues(a)};THREE.MeshNormalMaterial.prototype=Object.create(THREE.Material.prototype);THREE.MeshNormalMaterial.prototype.clone=function(){var a=new THREE.MeshNormalMaterial;THREE.Material.prototype.clone.call(this,a);a.shading=this.shading;a.wireframe=this.wireframe;a.wireframeLinewidth=this.wireframeLinewidth;return a};THREE.MeshFaceMaterial=function(){};
-THREE.MeshFaceMaterial.prototype.clone=function(){return new THREE.MeshFaceMaterial};THREE.ParticleBasicMaterial=function(a){THREE.Material.call(this);this.color=new THREE.Color(16777215);this.map=null;this.size=1;this.sizeAttenuation=true;this.vertexColors=false;this.fog=true;this.setValues(a)};THREE.ParticleBasicMaterial.prototype=Object.create(THREE.Material.prototype);
-THREE.ParticleBasicMaterial.prototype.clone=function(){var a=new THREE.ParticleBasicMaterial;THREE.Material.prototype.clone.call(this,a);a.color.copy(this.color);a.map=this.map;a.size=this.size;a.sizeAttenuation=this.sizeAttenuation;a.vertexColors=this.vertexColors;a.fog=this.fog;return a};THREE.ParticleCanvasMaterial=function(a){THREE.Material.call(this);this.color=new THREE.Color(16777215);this.program=function(){};this.setValues(a)};THREE.ParticleCanvasMaterial.prototype=Object.create(THREE.Material.prototype);
-THREE.ParticleCanvasMaterial.prototype.clone=function(){var a=new THREE.ParticleCanvasMaterial;THREE.Material.prototype.clone.call(this,a);a.color.copy(this.color);a.program=this.program;return a};
-THREE.Texture=function(a,b,c,d,f,e,g,j,m){this.id=THREE.TextureCount++;this.image=a;this.mapping=b!==void 0?b:new THREE.UVMapping;this.wrapS=c!==void 0?c:THREE.ClampToEdgeWrapping;this.wrapT=d!==void 0?d:THREE.ClampToEdgeWrapping;this.magFilter=f!==void 0?f:THREE.LinearFilter;this.minFilter=e!==void 0?e:THREE.LinearMipMapLinearFilter;this.anisotropy=m!==void 0?m:1;this.format=g!==void 0?g:THREE.RGBAFormat;this.type=j!==void 0?j:THREE.UnsignedByteType;this.offset=new THREE.Vector2(0,0);this.repeat=
-new THREE.Vector2(1,1);this.generateMipmaps=true;this.premultiplyAlpha=false;this.flipY=true;this.needsUpdate=false;this.onUpdate=null};THREE.Texture.prototype={constructor:THREE.Texture,clone:function(){var a=new THREE.Texture(this.image,this.mapping,this.wrapS,this.wrapT,this.magFilter,this.minFilter,this.format,this.type,this.anisotropy);a.offset.copy(this.offset);a.repeat.copy(this.repeat);a.generateMipmaps=this.generateMipmaps;a.premultiplyAlpha=this.premultiplyAlpha;a.flipY=this.flipY;return a}};
-THREE.TextureCount=0;THREE.DataTexture=function(a,b,c,d,f,e,g,j,m,k){THREE.Texture.call(this,null,e,g,j,m,k,d,f);this.image={data:a,width:b,height:c}};THREE.DataTexture.prototype=Object.create(THREE.Texture.prototype);THREE.DataTexture.prototype.clone=function(){var a=new THREE.DataTexture(this.image.data,this.image.width,this.image.height,this.format,this.type,this.mapping,this.wrapS,this.wrapT,this.magFilter,this.minFilter);a.offset.copy(this.offset);a.repeat.copy(this.repeat);return a};
-THREE.Particle=function(a){THREE.Object3D.call(this);this.material=a};THREE.Particle.prototype=Object.create(THREE.Object3D.prototype);THREE.Line=function(a,b,c){THREE.Object3D.call(this);this.geometry=a;this.material=b!==void 0?b:new THREE.LineBasicMaterial({color:Math.random()*16777215});this.type=c!==void 0?c:THREE.LineStrip;this.geometry&&(this.geometry.boundingSphere||this.geometry.computeBoundingSphere())};THREE.LineStrip=0;THREE.LinePieces=1;THREE.Line.prototype=Object.create(THREE.Object3D.prototype);
-THREE.Mesh=function(a,b){THREE.Object3D.call(this);this.geometry=a;this.material=b!==void 0?b:new THREE.MeshBasicMaterial({color:Math.random()*16777215,wireframe:true});if(this.geometry){this.geometry.boundingSphere||this.geometry.computeBoundingSphere();this.boundRadius=a.boundingSphere.radius;if(this.geometry.morphTargets.length){this.morphTargetBase=-1;this.morphTargetForcedOrder=[];this.morphTargetInfluences=[];this.morphTargetDictionary={};for(var c=0;c<this.geometry.morphTargets.length;c++){this.morphTargetInfluences.push(0);
-this.morphTargetDictionary[this.geometry.morphTargets[c].name]=c}}}};THREE.Mesh.prototype=Object.create(THREE.Object3D.prototype);THREE.Mesh.prototype.getMorphTargetIndexByName=function(a){if(this.morphTargetDictionary[a]!==void 0)return this.morphTargetDictionary[a];console.log("THREE.Mesh.getMorphTargetIndexByName: morph target "+a+" does not exist. Returning 0.");return 0};THREE.Bone=function(a){THREE.Object3D.call(this);this.skin=a;this.skinMatrix=new THREE.Matrix4};THREE.Bone.prototype=Object.create(THREE.Object3D.prototype);
-THREE.Bone.prototype.update=function(a,b){this.matrixAutoUpdate&&(b=b|this.updateMatrix());if(b||this.matrixWorldNeedsUpdate){a?this.skinMatrix.multiply(a,this.matrix):this.skinMatrix.copy(this.matrix);this.matrixWorldNeedsUpdate=false;b=true}var c,d=this.children.length;for(c=0;c<d;c++)this.children[c].update(this.skinMatrix,b)};
-THREE.Sprite=function(a){THREE.Object3D.call(this);this.color=a.color!==void 0?new THREE.Color(a.color):new THREE.Color(16777215);this.map=a.map!==void 0?a.map:new THREE.Texture;this.blending=a.blending!==void 0?a.blending:THREE.NormalBlending;this.blendSrc=a.blendSrc!==void 0?a.blendSrc:THREE.SrcAlphaFactor;this.blendDst=a.blendDst!==void 0?a.blendDst:THREE.OneMinusSrcAlphaFactor;this.blendEquation=a.blendEquation!==void 0?a.blendEquation:THREE.AddEquation;this.useScreenCoordinates=a.useScreenCoordinates!==
-void 0?a.useScreenCoordinates:true;this.mergeWith3D=a.mergeWith3D!==void 0?a.mergeWith3D:!this.useScreenCoordinates;this.affectedByDistance=a.affectedByDistance!==void 0?a.affectedByDistance:!this.useScreenCoordinates;this.scaleByViewport=a.scaleByViewport!==void 0?a.scaleByViewport:!this.affectedByDistance;this.alignment=a.alignment instanceof THREE.Vector2?a.alignment:THREE.SpriteAlignment.center;this.rotation3d=this.rotation;this.rotation=0;this.opacity=1;this.uvOffset=new THREE.Vector2(0,0);this.uvScale=
-new THREE.Vector2(1,1)};THREE.Sprite.prototype=Object.create(THREE.Object3D.prototype);THREE.Sprite.prototype.updateMatrix=function(){this.matrix.setPosition(this.position);this.rotation3d.set(0,0,this.rotation);this.matrix.setRotationFromEuler(this.rotation3d);if(this.scale.x!==1||this.scale.y!==1){this.matrix.scale(this.scale);this.boundRadiusScale=Math.max(this.scale.x,this.scale.y)}this.matrixWorldNeedsUpdate=true};THREE.SpriteAlignment={};THREE.SpriteAlignment.topLeft=new THREE.Vector2(1,-1);
-THREE.SpriteAlignment.topCenter=new THREE.Vector2(0,-1);THREE.SpriteAlignment.topRight=new THREE.Vector2(-1,-1);THREE.SpriteAlignment.centerLeft=new THREE.Vector2(1,0);THREE.SpriteAlignment.center=new THREE.Vector2(0,0);THREE.SpriteAlignment.centerRight=new THREE.Vector2(-1,0);THREE.SpriteAlignment.bottomLeft=new THREE.Vector2(1,1);THREE.SpriteAlignment.bottomCenter=new THREE.Vector2(0,1);THREE.SpriteAlignment.bottomRight=new THREE.Vector2(-1,1);
-THREE.Scene=function(){THREE.Object3D.call(this);this.overrideMaterial=this.fog=null;this.matrixAutoUpdate=false;this.__objects=[];this.__lights=[];this.__objectsAdded=[];this.__objectsRemoved=[]};THREE.Scene.prototype=Object.create(THREE.Object3D.prototype);
-THREE.Scene.prototype.__addObject=function(a){if(a instanceof THREE.Light){this.__lights.indexOf(a)===-1&&this.__lights.push(a);a.target&&a.target.parent===void 0&&this.add(a.target)}else if(!(a instanceof THREE.Camera||a instanceof THREE.Bone)&&this.__objects.indexOf(a)===-1){this.__objects.push(a);this.__objectsAdded.push(a);var b=this.__objectsRemoved.indexOf(a);b!==-1&&this.__objectsRemoved.splice(b,1)}for(b=0;b<a.children.length;b++)this.__addObject(a.children[b])};
-THREE.Scene.prototype.__removeObject=function(a){if(a instanceof THREE.Light){var b=this.__lights.indexOf(a);b!==-1&&this.__lights.splice(b,1)}else if(!(a instanceof THREE.Camera)){b=this.__objects.indexOf(a);if(b!==-1){this.__objects.splice(b,1);this.__objectsRemoved.push(a);b=this.__objectsAdded.indexOf(a);b!==-1&&this.__objectsAdded.splice(b,1)}}for(b=0;b<a.children.length;b++)this.__removeObject(a.children[b])};
-THREE.CanvasRenderer=function(a){function b(a){if(u!==a)u=i.globalAlpha=a}function c(a){if(v!==a){if(a===THREE.NormalBlending)i.globalCompositeOperation="source-over";else if(a===THREE.AdditiveBlending)i.globalCompositeOperation="lighter";else if(a===THREE.SubtractiveBlending)i.globalCompositeOperation="darker";v=a}}function d(a){if(B!==a)B=i.strokeStyle=a}function f(a){if(x!==a)x=i.fillStyle=a}console.log("THREE.CanvasRenderer",THREE.REVISION);var a=a||{},e=this,g,j,m,k=new THREE.Projector,h=a.canvas!==
-void 0?a.canvas:document.createElement("canvas"),n,l,o,q,i=h.getContext("2d"),p=new THREE.Color(0),r=0,u=1,v=0,B=null,x=null,A=null,y=null,E=null,s,w,C,K,M=new THREE.RenderableVertex,N=new THREE.RenderableVertex,t,G,I,O,P,R,z,$,aa,J,S,W,D=new THREE.Color,F=new THREE.Color,H=new THREE.Color,L=new THREE.Color,Q=new THREE.Color,la=[],T=[],ca,U,da,fa,za,Aa,Ba,Ca,Da,Ea,ia=new THREE.Rectangle,ba=new THREE.Rectangle,X=new THREE.Rectangle,ua=false,Z=new THREE.Color,ma=new THREE.Color,na=new THREE.Color,V=
-new THREE.Vector3,ra,sa,ya,ea,ta,va,a=16;ra=document.createElement("canvas");ra.width=ra.height=2;sa=ra.getContext("2d");sa.fillStyle="rgba(0,0,0,1)";sa.fillRect(0,0,2,2);ya=sa.getImageData(0,0,2,2);ea=ya.data;ta=document.createElement("canvas");ta.width=ta.height=a;va=ta.getContext("2d");va.translate(-a/2,-a/2);va.scale(a,a);a--;this.domElement=h;this.sortElements=this.sortObjects=this.autoClear=true;this.info={render:{vertices:0,faces:0}};this.setSize=function(a,b){n=a;l=b;o=Math.floor(n/2);q=Math.floor(l/
-2);h.width=n;h.height=l;ia.set(-o,-q,o,q);ba.set(-o,-q,o,q);u=1;v=0;E=y=A=x=B=null};this.setClearColor=function(a,b){p.copy(a);r=b!==void 0?b:1;ba.set(-o,-q,o,q)};this.setClearColorHex=function(a,b){p.setHex(a);r=b!==void 0?b:1;ba.set(-o,-q,o,q)};this.clear=function(){i.setTransform(1,0,0,-1,o,q);if(ba.isEmpty()===false){ba.minSelf(ia);ba.inflate(2);r<1&&i.clearRect(Math.floor(ba.getX()),Math.floor(ba.getY()),Math.floor(ba.getWidth()),Math.floor(ba.getHeight()));if(r>0){c(THREE.NormalBlending);b(1);
-f("rgba("+Math.floor(p.r*255)+","+Math.floor(p.g*255)+","+Math.floor(p.b*255)+","+r+")");i.fillRect(Math.floor(ba.getX()),Math.floor(ba.getY()),Math.floor(ba.getWidth()),Math.floor(ba.getHeight()))}ba.empty()}};this.render=function(a,h){function l(a){var b,c,d,e;Z.setRGB(0,0,0);ma.setRGB(0,0,0);na.setRGB(0,0,0);b=0;for(c=a.length;b<c;b++){d=a[b];e=d.color;if(d instanceof THREE.AmbientLight){Z.r=Z.r+e.r;Z.g=Z.g+e.g;Z.b=Z.b+e.b}else if(d instanceof THREE.DirectionalLight){ma.r=ma.r+e.r;ma.g=ma.g+e.g;
-ma.b=ma.b+e.b}else if(d instanceof THREE.PointLight){na.r=na.r+e.r;na.g=na.g+e.g;na.b=na.b+e.b}}}function n(a,b,c,d){var e,f,g,h,k,j;e=0;for(f=a.length;e<f;e++){g=a[e];h=g.color;if(g instanceof THREE.DirectionalLight){k=g.matrixWorld.getPosition().normalize();j=c.dot(k);if(!(j<=0)){j=j*g.intensity;d.r=d.r+h.r*j;d.g=d.g+h.g*j;d.b=d.b+h.b*j}}else if(g instanceof THREE.PointLight){k=g.matrixWorld.getPosition();j=c.dot(V.sub(k,b).normalize());if(!(j<=0)){j=j*(g.distance==0?1:1-Math.min(b.distanceTo(k)/
-g.distance,1));if(j!=0){j=j*g.intensity;d.r=d.r+h.r*j;d.g=d.g+h.g*j;d.b=d.b+h.b*j}}}}}function p(a,e,g){b(g.opacity);c(g.blending);var h,k,j,m,l,n;if(g instanceof THREE.ParticleBasicMaterial){if(g.map===null){j=e.object.scale.x;m=e.object.scale.y;j=j*e.scale.x*o;m=m*e.scale.y*q;X.set(a.x-j,a.y-m,a.x+j,a.y+m);if(ia.intersects(X)===false)return;f(g.color.getContextStyle());i.save();i.translate(a.x,a.y);i.rotate(-e.rotation);i.scale(j,m);i.fillRect(-1,-1,2,2)}else{g=g.map.image;l=g.width>>1;n=g.height>>
-1;j=e.scale.x*o;m=e.scale.y*q;h=j*l;k=m*n;X.set(a.x-h,a.y-k,a.x+h,a.y+k);if(ia.intersects(X)===false)return;i.save();i.translate(a.x,a.y);i.rotate(-e.rotation);i.scale(j,-m);i.translate(-l,-n);i.drawImage(g,0,0)}i.restore()}else if(g instanceof THREE.ParticleCanvasMaterial){h=e.scale.x*o;k=e.scale.y*q;X.set(a.x-h,a.y-k,a.x+h,a.y+k);if(ia.intersects(X)!==false){d(g.color.getContextStyle());f(g.color.getContextStyle());i.save();i.translate(a.x,a.y);i.rotate(-e.rotation);i.scale(h,k);g.program(i);i.restore()}}}
-function r(a,e,f,g){b(g.opacity);c(g.blending);i.beginPath();i.moveTo(a.positionScreen.x,a.positionScreen.y);i.lineTo(e.positionScreen.x,e.positionScreen.y);i.closePath();if(g instanceof THREE.LineBasicMaterial){a=g.linewidth;if(A!==a)A=i.lineWidth=a;a=g.linecap;if(y!==a)y=i.lineCap=a;a=g.linejoin;if(E!==a)E=i.lineJoin=a;d(g.color.getContextStyle());i.stroke();X.inflate(g.linewidth*2)}}function u(a,d,f,g,k,j,i,l){e.info.render.vertices=e.info.render.vertices+3;e.info.render.faces++;b(l.opacity);c(l.blending);
-t=a.positionScreen.x;G=a.positionScreen.y;I=d.positionScreen.x;O=d.positionScreen.y;P=f.positionScreen.x;R=f.positionScreen.y;x(t,G,I,O,P,R);if(l instanceof THREE.MeshBasicMaterial)if(l.map!==null){if(l.map.mapping instanceof THREE.UVMapping){fa=i.uvs[0];Fa(t,G,I,O,P,R,fa[g].u,fa[g].v,fa[k].u,fa[k].v,fa[j].u,fa[j].v,l.map)}}else if(l.envMap!==null){if(l.envMap.mapping instanceof THREE.SphericalReflectionMapping){a=h.matrixWorldInverse;V.copy(i.vertexNormalsWorld[g]);za=(V.x*a.elements[0]+V.y*a.elements[4]+
-V.z*a.elements[8])*0.5+0.5;Aa=(V.x*a.elements[1]+V.y*a.elements[5]+V.z*a.elements[9])*0.5+0.5;V.copy(i.vertexNormalsWorld[k]);Ba=(V.x*a.elements[0]+V.y*a.elements[4]+V.z*a.elements[8])*0.5+0.5;Ca=(V.x*a.elements[1]+V.y*a.elements[5]+V.z*a.elements[9])*0.5+0.5;V.copy(i.vertexNormalsWorld[j]);Da=(V.x*a.elements[0]+V.y*a.elements[4]+V.z*a.elements[8])*0.5+0.5;Ea=(V.x*a.elements[1]+V.y*a.elements[5]+V.z*a.elements[9])*0.5+0.5;Fa(t,G,I,O,P,R,za,Aa,Ba,Ca,Da,Ea,l.envMap)}}else l.wireframe===true?ja(l.color,
-l.wireframeLinewidth,l.wireframeLinecap,l.wireframeLinejoin):ga(l.color);else if(l instanceof THREE.MeshLambertMaterial)if(ua===true)if(l.wireframe===false&&l.shading==THREE.SmoothShading&&i.vertexNormalsWorld.length==3){F.r=H.r=L.r=Z.r;F.g=H.g=L.g=Z.g;F.b=H.b=L.b=Z.b;n(m,i.v1.positionWorld,i.vertexNormalsWorld[0],F);n(m,i.v2.positionWorld,i.vertexNormalsWorld[1],H);n(m,i.v3.positionWorld,i.vertexNormalsWorld[2],L);F.r=Math.max(0,Math.min(l.color.r*F.r,1));F.g=Math.max(0,Math.min(l.color.g*F.g,1));
-F.b=Math.max(0,Math.min(l.color.b*F.b,1));H.r=Math.max(0,Math.min(l.color.r*H.r,1));H.g=Math.max(0,Math.min(l.color.g*H.g,1));H.b=Math.max(0,Math.min(l.color.b*H.b,1));L.r=Math.max(0,Math.min(l.color.r*L.r,1));L.g=Math.max(0,Math.min(l.color.g*L.g,1));L.b=Math.max(0,Math.min(l.color.b*L.b,1));Q.r=(H.r+L.r)*0.5;Q.g=(H.g+L.g)*0.5;Q.b=(H.b+L.b)*0.5;da=wa(F,H,L,Q);pa(t,G,I,O,P,R,0,0,1,0,0,1,da)}else{D.r=Z.r;D.g=Z.g;D.b=Z.b;n(m,i.centroidWorld,i.normalWorld,D);D.r=Math.max(0,Math.min(l.color.r*D.r,1));
-D.g=Math.max(0,Math.min(l.color.g*D.g,1));D.b=Math.max(0,Math.min(l.color.b*D.b,1));l.wireframe===true?ja(D,l.wireframeLinewidth,l.wireframeLinecap,l.wireframeLinejoin):ga(D)}else l.wireframe===true?ja(l.color,l.wireframeLinewidth,l.wireframeLinecap,l.wireframeLinejoin):ga(l.color);else if(l instanceof THREE.MeshDepthMaterial){ca=h.near;U=h.far;F.r=F.g=F.b=1-oa(a.positionScreen.z,ca,U);H.r=H.g=H.b=1-oa(d.positionScreen.z,ca,U);L.r=L.g=L.b=1-oa(f.positionScreen.z,ca,U);Q.r=(H.r+L.r)*0.5;Q.g=(H.g+L.g)*
-0.5;Q.b=(H.b+L.b)*0.5;da=wa(F,H,L,Q);pa(t,G,I,O,P,R,0,0,1,0,0,1,da)}else if(l instanceof THREE.MeshNormalMaterial){D.r=qa(i.normalWorld.x);D.g=qa(i.normalWorld.y);D.b=qa(i.normalWorld.z);l.wireframe===true?ja(D,l.wireframeLinewidth,l.wireframeLinecap,l.wireframeLinejoin):ga(D)}}function v(a,d,f,g,k,j,l,i,o){e.info.render.vertices=e.info.render.vertices+4;e.info.render.faces++;b(i.opacity);c(i.blending);if(i.map!==void 0&&i.map!==null||i.envMap!==void 0&&i.envMap!==null){u(a,d,g,0,1,3,l,i,o);u(k,f,
-j,1,2,3,l,i,o)}else{t=a.positionScreen.x;G=a.positionScreen.y;I=d.positionScreen.x;O=d.positionScreen.y;P=f.positionScreen.x;R=f.positionScreen.y;z=g.positionScreen.x;$=g.positionScreen.y;aa=k.positionScreen.x;J=k.positionScreen.y;S=j.positionScreen.x;W=j.positionScreen.y;if(i instanceof THREE.MeshBasicMaterial){B(t,G,I,O,P,R,z,$);i.wireframe===true?ja(i.color,i.wireframeLinewidth,i.wireframeLinecap,i.wireframeLinejoin):ga(i.color)}else if(i instanceof THREE.MeshLambertMaterial)if(ua===true)if(!i.wireframe&&
-i.shading==THREE.SmoothShading&&l.vertexNormalsWorld.length==4){F.r=H.r=L.r=Q.r=Z.r;F.g=H.g=L.g=Q.g=Z.g;F.b=H.b=L.b=Q.b=Z.b;n(m,l.v1.positionWorld,l.vertexNormalsWorld[0],F);n(m,l.v2.positionWorld,l.vertexNormalsWorld[1],H);n(m,l.v4.positionWorld,l.vertexNormalsWorld[3],L);n(m,l.v3.positionWorld,l.vertexNormalsWorld[2],Q);F.r=Math.max(0,Math.min(i.color.r*F.r,1));F.g=Math.max(0,Math.min(i.color.g*F.g,1));F.b=Math.max(0,Math.min(i.color.b*F.b,1));H.r=Math.max(0,Math.min(i.color.r*H.r,1));H.g=Math.max(0,
-Math.min(i.color.g*H.g,1));H.b=Math.max(0,Math.min(i.color.b*H.b,1));L.r=Math.max(0,Math.min(i.color.r*L.r,1));L.g=Math.max(0,Math.min(i.color.g*L.g,1));L.b=Math.max(0,Math.min(i.color.b*L.b,1));Q.r=Math.max(0,Math.min(i.color.r*Q.r,1));Q.g=Math.max(0,Math.min(i.color.g*Q.g,1));Q.b=Math.max(0,Math.min(i.color.b*Q.b,1));da=wa(F,H,L,Q);x(t,G,I,O,z,$);pa(t,G,I,O,z,$,0,0,1,0,0,1,da);x(aa,J,P,R,S,W);pa(aa,J,P,R,S,W,1,0,1,1,0,1,da)}else{D.r=Z.r;D.g=Z.g;D.b=Z.b;n(m,l.centroidWorld,l.normalWorld,D);D.r=Math.max(0,
-Math.min(i.color.r*D.r,1));D.g=Math.max(0,Math.min(i.color.g*D.g,1));D.b=Math.max(0,Math.min(i.color.b*D.b,1));B(t,G,I,O,P,R,z,$);i.wireframe===true?ja(D,i.wireframeLinewidth,i.wireframeLinecap,i.wireframeLinejoin):ga(D)}else{B(t,G,I,O,P,R,z,$);i.wireframe===true?ja(i.color,i.wireframeLinewidth,i.wireframeLinecap,i.wireframeLinejoin):ga(i.color)}else if(i instanceof THREE.MeshNormalMaterial){D.r=qa(l.normalWorld.x);D.g=qa(l.normalWorld.y);D.b=qa(l.normalWorld.z);B(t,G,I,O,P,R,z,$);i.wireframe===true?
-ja(D,i.wireframeLinewidth,i.wireframeLinecap,i.wireframeLinejoin):ga(D)}else if(i instanceof THREE.MeshDepthMaterial){ca=h.near;U=h.far;F.r=F.g=F.b=1-oa(a.positionScreen.z,ca,U);H.r=H.g=H.b=1-oa(d.positionScreen.z,ca,U);L.r=L.g=L.b=1-oa(g.positionScreen.z,ca,U);Q.r=Q.g=Q.b=1-oa(f.positionScreen.z,ca,U);da=wa(F,H,L,Q);x(t,G,I,O,z,$);pa(t,G,I,O,z,$,0,0,1,0,0,1,da);x(aa,J,P,R,S,W);pa(aa,J,P,R,S,W,1,0,1,1,0,1,da)}}}function x(a,b,c,d,e,f){i.beginPath();i.moveTo(a,b);i.lineTo(c,d);i.lineTo(e,f);i.lineTo(a,
-b)}function B(a,b,c,d,e,f,g,h){i.beginPath();i.moveTo(a,b);i.lineTo(c,d);i.lineTo(e,f);i.lineTo(g,h);i.lineTo(a,b)}function ja(a,b,c,e){if(A!==b)A=i.lineWidth=b;if(y!==c)y=i.lineCap=c;if(E!==e)E=i.lineJoin=e;d(a.getContextStyle());i.stroke();X.inflate(b*2)}function ga(a){f(a.getContextStyle());i.fill()}function Fa(a,b,c,d,e,g,h,k,j,l,m,n,o){if(!(o.image===void 0||o.image.width===0)){if(o.needsUpdate===true||la[o.id]===void 0){var p=o.wrapS==THREE.RepeatWrapping,q=o.wrapT==THREE.RepeatWrapping;la[o.id]=
-i.createPattern(o.image,p===true&&q===true?"repeat":p===true&&q===false?"repeat-x":p===false&&q===true?"repeat-y":"no-repeat");o.needsUpdate=false}f(la[o.id]);var p=o.offset.x/o.repeat.x,q=o.offset.y/o.repeat.y,r=o.image.width*o.repeat.x,s=o.image.height*o.repeat.y,h=(h+p)*r,k=(1-k+q)*s,c=c-a,d=d-b,e=e-a,g=g-b,j=(j+p)*r-h,l=(1-l+q)*s-k,m=(m+p)*r-h,n=(1-n+q)*s-k,p=j*n-m*l;if(p===0){if(T[o.id]===void 0){b=document.createElement("canvas");b.width=o.image.width;b.height=o.image.height;b=b.getContext("2d");
-b.drawImage(o.image,0,0);T[o.id]=b.getImageData(0,0,o.image.width,o.image.height).data}b=T[o.id];h=(Math.floor(h)+Math.floor(k)*o.image.width)*4;D.setRGB(b[h]/255,b[h+1]/255,b[h+2]/255);ga(D)}else{p=1/p;o=(n*c-l*e)*p;l=(n*d-l*g)*p;c=(j*e-m*c)*p;d=(j*g-m*d)*p;a=a-o*h-c*k;h=b-l*h-d*k;i.save();i.transform(o,l,c,d,a,h);i.fill();i.restore()}}}function pa(a,b,c,d,e,f,g,h,k,j,l,m,n){var o,p;o=n.width-1;p=n.height-1;g=g*o;h=h*p;c=c-a;d=d-b;e=e-a;f=f-b;k=k*o-g;j=j*p-h;l=l*o-g;m=m*p-h;p=1/(k*m-l*j);o=(m*c-
-j*e)*p;j=(m*d-j*f)*p;c=(k*e-l*c)*p;d=(k*f-l*d)*p;a=a-o*g-c*h;b=b-j*g-d*h;i.save();i.transform(o,j,c,d,a,b);i.clip();i.drawImage(n,0,0);i.restore()}function wa(a,b,c,d){var e=~~(a.r*255),f=~~(a.g*255),a=~~(a.b*255),g=~~(b.r*255),h=~~(b.g*255),b=~~(b.b*255),i=~~(c.r*255),j=~~(c.g*255),c=~~(c.b*255),k=~~(d.r*255),l=~~(d.g*255),d=~~(d.b*255);ea[0]=e<0?0:e>255?255:e;ea[1]=f<0?0:f>255?255:f;ea[2]=a<0?0:a>255?255:a;ea[4]=g<0?0:g>255?255:g;ea[5]=h<0?0:h>255?255:h;ea[6]=b<0?0:b>255?255:b;ea[8]=i<0?0:i>255?
-255:i;ea[9]=j<0?0:j>255?255:j;ea[10]=c<0?0:c>255?255:c;ea[12]=k<0?0:k>255?255:k;ea[13]=l<0?0:l>255?255:l;ea[14]=d<0?0:d>255?255:d;sa.putImageData(ya,0,0);va.drawImage(ra,0,0);return ta}function oa(a,b,c){a=(a-b)/(c-b);return a*a*(3-2*a)}function qa(a){a=(a+1)*0.5;return a<0?0:a>1?1:a}function ka(a,b){var c=b.x-a.x,d=b.y-a.y,e=c*c+d*d;if(e!==0){e=1/Math.sqrt(e);c=c*e;d=d*e;b.x=b.x+c;b.y=b.y+d;a.x=a.x-c;a.y=a.y-d}}if(h instanceof THREE.Camera===false)console.error("THREE.CanvasRenderer.render: camera is not an instance of THREE.Camera.");
-else{var xa,Ga,Y,ha;this.autoClear===true?this.clear():i.setTransform(1,0,0,-1,o,q);e.info.render.vertices=0;e.info.render.faces=0;g=k.projectScene(a,h,this.sortElements);j=g.elements;m=g.lights;ua=m.length>0;ua===true&&l(m);xa=0;for(Ga=j.length;xa<Ga;xa++){Y=j[xa];ha=Y.material;if(!(ha===void 0||ha.visible===false)){X.empty();if(Y instanceof THREE.RenderableParticle){s=Y;s.x=s.x*o;s.y=s.y*q;p(s,Y,ha,a)}else if(Y instanceof THREE.RenderableLine){s=Y.v1;w=Y.v2;s.positionScreen.x=s.positionScreen.x*
-o;s.positionScreen.y=s.positionScreen.y*q;w.positionScreen.x=w.positionScreen.x*o;w.positionScreen.y=w.positionScreen.y*q;X.addPoint(s.positionScreen.x,s.positionScreen.y);X.addPoint(w.positionScreen.x,w.positionScreen.y);ia.intersects(X)===true&&r(s,w,Y,ha,a)}else if(Y instanceof THREE.RenderableFace3){s=Y.v1;w=Y.v2;C=Y.v3;s.positionScreen.x=s.positionScreen.x*o;s.positionScreen.y=s.positionScreen.y*q;w.positionScreen.x=w.positionScreen.x*o;w.positionScreen.y=w.positionScreen.y*q;C.positionScreen.x=
-C.positionScreen.x*o;C.positionScreen.y=C.positionScreen.y*q;if(ha.overdraw===true){ka(s.positionScreen,w.positionScreen);ka(w.positionScreen,C.positionScreen);ka(C.positionScreen,s.positionScreen)}X.add3Points(s.positionScreen.x,s.positionScreen.y,w.positionScreen.x,w.positionScreen.y,C.positionScreen.x,C.positionScreen.y);ia.intersects(X)===true&&u(s,w,C,0,1,2,Y,ha,a)}else if(Y instanceof THREE.RenderableFace4){s=Y.v1;w=Y.v2;C=Y.v3;K=Y.v4;s.positionScreen.x=s.positionScreen.x*o;s.positionScreen.y=
-s.positionScreen.y*q;w.positionScreen.x=w.positionScreen.x*o;w.positionScreen.y=w.positionScreen.y*q;C.positionScreen.x=C.positionScreen.x*o;C.positionScreen.y=C.positionScreen.y*q;K.positionScreen.x=K.positionScreen.x*o;K.positionScreen.y=K.positionScreen.y*q;M.positionScreen.copy(w.positionScreen);N.positionScreen.copy(K.positionScreen);if(ha.overdraw===true){ka(s.positionScreen,w.positionScreen);ka(w.positionScreen,K.positionScreen);ka(K.positionScreen,s.positionScreen);ka(C.positionScreen,M.positionScreen);
-ka(C.positionScreen,N.positionScreen)}X.addPoint(s.positionScreen.x,s.positionScreen.y);X.addPoint(w.positionScreen.x,w.positionScreen.y);X.addPoint(C.positionScreen.x,C.positionScreen.y);X.addPoint(K.positionScreen.x,K.positionScreen.y);ia.intersects(X)===true&&v(s,w,C,K,M,N,Y,ha,a)}ba.addRectangle(X)}}i.setTransform(1,0,0,1,0,0)}}};THREE.RenderableVertex=function(){this.positionWorld=new THREE.Vector3;this.positionScreen=new THREE.Vector4;this.visible=true};
-THREE.RenderableVertex.prototype.copy=function(a){this.positionWorld.copy(a.positionWorld);this.positionScreen.copy(a.positionScreen)};
-THREE.RenderableFace3=function(){this.v1=new THREE.RenderableVertex;this.v2=new THREE.RenderableVertex;this.v3=new THREE.RenderableVertex;this.centroidWorld=new THREE.Vector3;this.centroidScreen=new THREE.Vector3;this.normalWorld=new THREE.Vector3;this.vertexNormalsWorld=[new THREE.Vector3,new THREE.Vector3,new THREE.Vector3];this.material=null;this.uvs=[[]];this.z=null};
-THREE.RenderableFace4=function(){this.v1=new THREE.RenderableVertex;this.v2=new THREE.RenderableVertex;this.v3=new THREE.RenderableVertex;this.v4=new THREE.RenderableVertex;this.centroidWorld=new THREE.Vector3;this.centroidScreen=new THREE.Vector3;this.normalWorld=new THREE.Vector3;this.vertexNormalsWorld=[new THREE.Vector3,new THREE.Vector3,new THREE.Vector3,new THREE.Vector3];this.material=null;this.uvs=[[]];this.z=null};THREE.RenderableObject=function(){this.z=this.object=null};
-THREE.RenderableParticle=function(){this.rotation=this.z=this.y=this.x=this.object=null;this.scale=new THREE.Vector2;this.material=null};THREE.RenderableLine=function(){this.z=null;this.v1=new THREE.RenderableVertex;this.v2=new THREE.RenderableVertex;this.material=null};

+ 1 - 1
build/Three.js → build/three.min.js

@@ -1,4 +1,4 @@
-// Three.js - http://github.com/mrdoob/three.js
+// three.min.js - http://github.com/mrdoob/three.js
 'use strict';var THREE=THREE||{REVISION:"50dev"};self.console||(self.console={info:function(){},log:function(){},debug:function(){},warn:function(){},error:function(){}});self.Int32Array||(self.Int32Array=Array,self.Float32Array=Array);
 'use strict';var THREE=THREE||{REVISION:"50dev"};self.console||(self.console={info:function(){},log:function(){},debug:function(){},warn:function(){},error:function(){}});self.Int32Array||(self.Int32Array=Array,self.Float32Array=Array);
 (function(){for(var a=0,b=["ms","moz","webkit","o"],c=0;c<b.length&&!window.requestAnimationFrame;++c){window.requestAnimationFrame=window[b[c]+"RequestAnimationFrame"];window.cancelAnimationFrame=window[b[c]+"CancelAnimationFrame"]||window[b[c]+"CancelRequestAnimationFrame"]}if(!window.requestAnimationFrame)window.requestAnimationFrame=function(b){var c=Date.now(),f=Math.max(0,16-(c-a)),g=window.setTimeout(function(){b(c+f)},f);a=c+f;return g};if(!window.cancelAnimationFrame)window.cancelAnimationFrame=
 (function(){for(var a=0,b=["ms","moz","webkit","o"],c=0;c<b.length&&!window.requestAnimationFrame;++c){window.requestAnimationFrame=window[b[c]+"RequestAnimationFrame"];window.cancelAnimationFrame=window[b[c]+"CancelAnimationFrame"]||window[b[c]+"CancelRequestAnimationFrame"]}if(!window.requestAnimationFrame)window.requestAnimationFrame=function(b){var c=Date.now(),f=Math.max(0,16-(c-a)),g=window.setTimeout(function(){b(c+f)},f);a=c+f;return g};if(!window.cancelAnimationFrame)window.cancelAnimationFrame=
 function(a){clearTimeout(a)}})();THREE.FrontSide=0;THREE.BackSide=1;THREE.DoubleSide=2;THREE.NoShading=0;THREE.FlatShading=1;THREE.SmoothShading=2;THREE.NoColors=0;THREE.FaceColors=1;THREE.VertexColors=2;THREE.NoBlending=0;THREE.NormalBlending=1;THREE.AdditiveBlending=2;THREE.SubtractiveBlending=3;THREE.MultiplyBlending=4;THREE.CustomBlending=5;THREE.AddEquation=100;THREE.SubtractEquation=101;THREE.ReverseSubtractEquation=102;THREE.ZeroFactor=200;THREE.OneFactor=201;THREE.SrcColorFactor=202;
 function(a){clearTimeout(a)}})();THREE.FrontSide=0;THREE.BackSide=1;THREE.DoubleSide=2;THREE.NoShading=0;THREE.FlatShading=1;THREE.SmoothShading=2;THREE.NoColors=0;THREE.FaceColors=1;THREE.VertexColors=2;THREE.NoBlending=0;THREE.NormalBlending=1;THREE.AdditiveBlending=2;THREE.SubtractiveBlending=3;THREE.MultiplyBlending=4;THREE.CustomBlending=5;THREE.AddEquation=100;THREE.SubtractEquation=101;THREE.ReverseSubtractEquation=102;THREE.ZeroFactor=200;THREE.OneFactor=201;THREE.SrcColorFactor=202;

+ 1 - 1
examples/canvas_ascii_effect.html

@@ -16,7 +16,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/effects/AsciiEffect.js"></script>
 		<script src="js/effects/AsciiEffect.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 2
examples/canvas_camera_orthographic.html

@@ -15,8 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/custom/ThreeCanvas.js"></script>
-		<script src="../build/custom/ThreeExtras.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_camera_orthographic2.html

@@ -20,7 +20,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="../src/extras/cameras/CombinedCamera.js"></script>
 		<script src="../src/extras/cameras/CombinedCamera.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/canvas_geometry_birds.html

@@ -28,7 +28,7 @@
 		<div id="container"></div>
 		<div id="container"></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - birds demo</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - birds demo</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="obj/Bird.js"></script>
 		<script src="obj/Bird.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/canvas_geometry_cube.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_geometry_earth.html

@@ -34,7 +34,7 @@
 		<div id="container"></div>
 		<div id="container"></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - earth demo</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - earth demo</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 
 		<script>
 		<script>

+ 1 - 1
examples/canvas_geometry_hierarchy.html

@@ -16,7 +16,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_geometry_panorama.html

@@ -32,7 +32,7 @@
 		<div id="container"></div>
 		<div id="container"></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - panorama demo. cubemap by <a href="http://www.zfight.com/" target="_blank">Jochum Skoglund</a>.</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - panorama demo. cubemap by <a href="http://www.zfight.com/" target="_blank">Jochum Skoglund</a>.</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_geometry_panorama_fisheye.html

@@ -32,7 +32,7 @@
 		<div id="container"></div>
 		<div id="container"></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - panorama fisheye demo. cubemap by <a href="http://www.zfight.com/" target="_blank">Jochum Skoglund</a>. (mousewheel: change fov)</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - panorama fisheye demo. cubemap by <a href="http://www.zfight.com/" target="_blank">Jochum Skoglund</a>. (mousewheel: change fov)</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_geometry_terrain.html

@@ -34,7 +34,7 @@
 		<div id="container"><br /><br /><br /><br /><br />Generating...</div>
 		<div id="container"><br /><br /><br /><br /><br />Generating...</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - terrain demo. <a href="canvas_geometry_terrain.html">generate another</a></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - terrain demo. <a href="canvas_geometry_terrain.html">generate another</a></div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/canvas_geometry_text.html

@@ -16,7 +16,7 @@
 	<body>
 	<body>
 
 
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_interactive_cubes.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_interactive_cubes_tween.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Tween.js"></script>
 		<script src="js/Tween.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/canvas_interactive_particles.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_interactive_voxelpainter.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_lights_pointlights.html

@@ -39,7 +39,7 @@
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_lights_pointlights_smooth.html

@@ -39,7 +39,7 @@
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_lines.html

@@ -18,7 +18,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_lines_sphere.html

@@ -18,7 +18,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_materials.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_materials_depth.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_materials_normal.html

@@ -39,7 +39,7 @@
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_materials_reflection.html

@@ -38,7 +38,7 @@
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>. Reflection texture by <a href="http://kewlers.scene.org/" target="_blank">Kewlers</a>.
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>. Reflection texture by <a href="http://kewlers.scene.org/" target="_blank">Kewlers</a>.
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/canvas_materials_video.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_particles_floor.html

@@ -18,7 +18,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_particles_random.html

@@ -18,7 +18,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_particles_shapes.html

@@ -16,7 +16,7 @@
 	<body>
 	<body>
 
 
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Tween.js"></script>
 		<script src="js/Tween.js"></script>

+ 1 - 1
examples/canvas_particles_sprites.html

@@ -18,7 +18,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Tween.js"></script>
 		<script src="js/Tween.js"></script>

+ 1 - 1
examples/canvas_particles_waves.html

@@ -17,7 +17,7 @@
 		</style>
 		</style>
 	</head>
 	</head>
 	<body>
 	<body>
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_performance.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/canvas_sandbox.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/misc_camera_fly.html

@@ -33,7 +33,7 @@
 			b { color:orange }
 			b { color:orange }
 		</style>
 		</style>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ShaderExtras.js"></script>
 		<script src="js/ShaderExtras.js"></script>
 
 

+ 1 - 1
examples/misc_camera_orbit.html

@@ -37,7 +37,7 @@
 			<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - orbit camera example
 			<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - orbit camera example
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/misc_camera_path.html

@@ -37,7 +37,7 @@
 			mouse look around
 			mouse look around
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/misc_camera_roll.html

@@ -37,7 +37,7 @@
 			WASD move, RF up/down, QE roll,	mouse look around
 			WASD move, RF up/down, QE roll,	mouse look around
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/misc_camera_trackball.html

@@ -38,7 +38,7 @@
 			MOVE mouse &amp; press LEFT/A: rotate, MIDDLE/S: zoom, RIGHT/D: pan
 			MOVE mouse &amp; press LEFT/A: rotate, MIDDLE/S: zoom, RIGHT/D: pan
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/misc_lights_test.html

@@ -35,7 +35,7 @@
 			<p>Canvas renderer is very slow on anything other than Chrome.
 			<p>Canvas renderer is very slow on anything other than Chrome.
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/misc_lookat.html

@@ -31,7 +31,7 @@
 	<body>
 	<body>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - Object3D::lookAt() demo</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - Object3D::lookAt() demo</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/misc_software.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/renderers/SoftwareRenderer.js"></script>
 		<script src="js/renderers/SoftwareRenderer.js"></script>
 		<script src="js/renderers/SoftwareRenderer2.js"></script>
 		<script src="js/renderers/SoftwareRenderer2.js"></script>
 		<script src="js/renderers/SoftwareRenderer3.js"></script>
 		<script src="js/renderers/SoftwareRenderer3.js"></script>

+ 1 - 1
examples/misc_sound.html

@@ -42,7 +42,7 @@
 
 
 		<div id="container"></div>
 		<div id="container"></div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 
 

+ 1 - 1
examples/misc_ubiquity_test.html

@@ -14,7 +14,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/renderers/SVGRenderer.js"></script>
 		<script src="js/renderers/SVGRenderer.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/misc_uv_tests.html

@@ -7,7 +7,7 @@
   article, aside, figure, footer, header, hgroup, 
   article, aside, figure, footer, header, hgroup, 
   menu, nav, section { display: block; }
   menu, nav, section { display: block; }
 </style>
 </style>
-  <script src="../build/Three.js"></script>
+  <script src="../build/three.min.js"></script>
   <script src="js/UVsUtils.js"></script>
   <script src="js/UVsUtils.js"></script>
 
 
 </head>
 </head>

+ 1 - 1
examples/webgl_animation_cloth.html

@@ -37,7 +37,7 @@
 			<a onclick="togglePins();">Pins</a>
 			<a onclick="togglePins();">Pins</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_animation_skinning.html

@@ -39,7 +39,7 @@
 		click to start animation
 		click to start animation
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_camera.html

@@ -39,7 +39,7 @@
 		<b>O</b> orthographic <b>P</b> perspective
 		<b>O</b> orthographic <b>P</b> perspective
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 
 		<script>
 		<script>

+ 1 - 1
examples/webgl_custom_attributes.html

@@ -31,7 +31,7 @@
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example</div>
 		<div id="container"></div>
 		<div id="container"></div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_custom_attributes_lines.html

@@ -34,7 +34,7 @@
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="fonts/helvetiker_bold.typeface.js"></script>
 		<script src="fonts/helvetiker_bold.typeface.js"></script>
 
 

+ 1 - 1
examples/webgl_custom_attributes_particles.html

@@ -34,7 +34,7 @@
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example - particles</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example - particles</div>
 		<div id="container"></div>
 		<div id="container"></div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_custom_attributes_particles2.html

@@ -31,7 +31,7 @@
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example - particles - billboards</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example - particles - billboards</div>
 		<div id="container"></div>
 		<div id="container"></div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_custom_attributes_particles3.html

@@ -31,7 +31,7 @@
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example - particles - billboards - alphatest</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - custom attributes example - particles - billboards - alphatest</div>
 		<div id="container"></div>
 		<div id="container"></div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_geometries.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_geometries2.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_geometry_colors.html

@@ -34,7 +34,7 @@
 		<div id="container"></div>
 		<div id="container"></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - vertex colors - webgl</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - vertex colors - webgl</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_geometry_colors_blender.html

@@ -34,7 +34,7 @@
 		<div id="container"></div>
 		<div id="container"></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> webgl - io blender - vertex colors</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> webgl - io blender - vertex colors</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_geometry_convex.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/webgl_geometry_cube.html

@@ -13,7 +13,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script>
 		<script>
 
 

+ 1 - 1
examples/webgl_geometry_dynamic.html

@@ -40,7 +40,7 @@
 		<div id="container"></div>
 		<div id="container"></div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - dynamic geometry demo - webgl<br />(left click: forward, right click: backward)</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - dynamic geometry demo - webgl<br />(left click: forward, right click: backward)</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_geometry_extrude_shapes.html

@@ -18,7 +18,7 @@
 	<body>
 	<body>
 		<canvas id="debug" style="position:absolute; left:100px"></canvas>
 		<canvas id="debug" style="position:absolute; left:100px"></canvas>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="../src/extras/core/Curve.js"></script>
 		<script src="../src/extras/core/Curve.js"></script>
 		<script src="../src/extras/geometries/TubeGeometry.js"></script>
 		<script src="../src/extras/geometries/TubeGeometry.js"></script>
 		<script src="../src/extras/geometries/ExtrudeGeometry.js"></script>
 		<script src="../src/extras/geometries/ExtrudeGeometry.js"></script>

+ 1 - 1
examples/webgl_geometry_extrude_splines.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="../src/extras/core/Curve.js"></script>
 		<script src="../src/extras/core/Curve.js"></script>
 		<script src="../src/extras/geometries/TubeGeometry.js"></script>
 		<script src="../src/extras/geometries/TubeGeometry.js"></script>
 		<script src="../src/extras/helpers/CameraHelper.js"></script>
 		<script src="../src/extras/helpers/CameraHelper.js"></script>

+ 1 - 1
examples/webgl_geometry_extrude_uvs2.html

@@ -3,7 +3,7 @@
 	<head>
 	<head>
 		<title>three.js webgl - UV mapped ExtrudeGeometry</title>
 		<title>three.js webgl - UV mapped ExtrudeGeometry</title>
 		
 		
-		<script type="text/javascript" src="../build/Three.js"></script>
+		<script type="text/javascript" src="../build/three.min.js"></script>
 		<script type="text/javascript" src="js/UVsUtils.js"></script>
 		<script type="text/javascript" src="js/UVsUtils.js"></script>
 
 
 		<script type="text/javascript">
 		<script type="text/javascript">

+ 1 - 1
examples/webgl_geometry_hierarchy.html

@@ -16,7 +16,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 
 		<script>
 		<script>

+ 1 - 1
examples/webgl_geometry_hierarchy2.html

@@ -16,7 +16,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 
 		<script>
 		<script>

+ 1 - 1
examples/webgl_geometry_large_mesh.html

@@ -45,7 +45,7 @@
 
 
 		<pre id="log"></pre>
 		<pre id="log"></pre>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 
 		<script>
 		<script>

+ 1 - 1
examples/webgl_geometry_minecraft.html

@@ -41,7 +41,7 @@
 		<div id="container"><br /><br /><br /><br /><br />Generating world...</div>
 		<div id="container"><br /><br /><br /><br /><br />Generating world...</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - <a href="http://www.minecraft.net/" target="_blank">minecraft</a> demo. featuring <a href="http://painterlypack.net/" target="_blank">painterly pack</a><br />(left click: forward, right click: backward)</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - <a href="http://www.minecraft.net/" target="_blank">minecraft</a> demo. featuring <a href="http://painterlypack.net/" target="_blank">painterly pack</a><br />(left click: forward, right click: backward)</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>

+ 1 - 1
examples/webgl_geometry_minecraft_ao.html

@@ -48,7 +48,7 @@
 			<button id="baot">texture + ao</button>
 			<button id="baot">texture + ao</button>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/ImprovedNoise.js"></script>
 
 

+ 1 - 1
examples/webgl_geometry_shapes.html

@@ -16,7 +16,7 @@
 	<body>
 	<body>
 		<canvas id="debug" style="position:absolute; left:100px"></canvas>
 		<canvas id="debug" style="position:absolute; left:100px"></canvas>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/webgl_geometry_subdivison.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/webgl_geometry_terrain.html

@@ -34,7 +34,7 @@
 		<div id="container"><br /><br /><br /><br /><br />Generating world...</div>
 		<div id="container"><br /><br /><br /><br /><br />Generating world...</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - webgl terrain demo<br />(left click: forward, right click: backward)</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - webgl terrain demo<br />(left click: forward, right click: backward)</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>

+ 1 - 1
examples/webgl_geometry_terrain_fog.html

@@ -34,7 +34,7 @@
 		<div id="container"><br /><br /><br /><br /><br />Generating world...</div>
 		<div id="container"><br /><br /><br /><br /><br />Generating world...</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - webgl terrain + fog demo <br />(left click: forward, right click: backward)</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - webgl terrain + fog demo <br />(left click: forward, right click: backward)</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ImprovedNoise.js"></script>
 		<script src="js/ImprovedNoise.js"></script>
 
 

+ 1 - 1
examples/webgl_geometry_tessellation.html

@@ -33,7 +33,7 @@
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - geometry tessellation example</div>
 		<div id="info"><a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - geometry tessellation example</div>
 		<div id="container"></div>
 		<div id="container"></div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_geometry_text.html

@@ -39,7 +39,7 @@
 		</div>
 		</div>
 
 
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ShaderExtras.js"></script>
 		<script src="js/ShaderExtras.js"></script>
 
 

+ 1 - 1
examples/webgl_hdr.html

@@ -37,7 +37,7 @@
 			based on <a href="http://spidergl.org/example.php?id=13" target="_blank">SpiderGL</a>
 			based on <a href="http://spidergl.org/example.php?id=13" target="_blank">SpiderGL</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_interactive_cubes.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/webgl_interactive_cubes_gpu.html

@@ -35,7 +35,7 @@
 		
 		
 		<div id="container"></div>
 		<div id="container"></div>
 	
 	
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/webgl_interactive_draggablecubes.html

@@ -15,7 +15,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/webgl_interactive_voxelpainter.html

@@ -17,7 +17,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_kinect.html

@@ -36,7 +36,7 @@
 	</head>
 	</head>
 	<body>
 	<body>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src='js/DAT.GUI.min.js'></script>
 		<script src='js/DAT.GUI.min.js'></script>
 
 

+ 1 - 1
examples/webgl_lensflares.html

@@ -41,7 +41,7 @@
 			textures from <a href="http://ro.me">ro.me</a> - fly with WASD/RF/QE + mouse
 			textures from <a href="http://ro.me">ro.me</a> - fly with WASD/RF/QE + mouse
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>
 
 

+ 1 - 1
examples/webgl_lights_pointlights.html

@@ -39,7 +39,7 @@
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 			Walt Disney head by <a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 
 

+ 1 - 1
examples/webgl_lights_pointlights2.html

@@ -38,7 +38,7 @@
 			<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - point lights WebGL demo
 			<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - point lights WebGL demo
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_lines_colors.html

@@ -44,7 +44,7 @@
 			[<a href="http://en.wikipedia.org/wiki/Hilbert_curve">Hilbert curve</a> thanks to <a href="http://www.openprocessing.org/visuals/?visualID=15599">Thomas Diewald</a>]
 			[<a href="http://en.wikipedia.org/wiki/Hilbert_curve">Hilbert curve</a> thanks to <a href="http://www.openprocessing.org/visuals/?visualID=15599">Thomas Diewald</a>]
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/ShaderExtras.js"></script>
 		<script src="js/ShaderExtras.js"></script>
 
 

+ 1 - 1
examples/webgl_lines_cubes.html

@@ -44,7 +44,7 @@
 			[<a href="http://en.wikipedia.org/wiki/Hilbert_curve">Hilbert curve</a> thanks to <a href="http://www.openprocessing.org/visuals/?visualID=15599">Thomas Diewald</a>]
 			[<a href="http://en.wikipedia.org/wiki/Hilbert_curve">Hilbert curve</a> thanks to <a href="http://www.openprocessing.org/visuals/?visualID=15599">Thomas Diewald</a>]
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_lines_sphere.html

@@ -43,7 +43,7 @@
 			<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - lines WebGL demo
 			<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - lines WebGL demo
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_lines_splines.html

@@ -44,7 +44,7 @@
 			[<a href="http://en.wikipedia.org/wiki/Hilbert_curve">Hilbert curve</a> thanks to <a href="http://www.openprocessing.org/visuals/?visualID=15599">Thomas Diewald</a>]
 			[<a href="http://en.wikipedia.org/wiki/Hilbert_curve">Hilbert curve</a> thanks to <a href="http://www.openprocessing.org/visuals/?visualID=15599">Thomas Diewald</a>]
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_loader_collada.html

@@ -32,7 +32,7 @@
 			monster by <a href="http://www.3drt.com/downloads.htm" target="_blank">3drt</a>
 			monster by <a href="http://www.3drt.com/downloads.htm" target="_blank">3drt</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/loaders/ColladaLoader.js"></script>
 		<script src="js/loaders/ColladaLoader.js"></script>
 
 

+ 1 - 1
examples/webgl_loader_collada_keyframe.html

@@ -34,7 +34,7 @@
 			pump by <a href="http://code.google.com/p/kuda" target="_blank">Kuda</a>
 			pump by <a href="http://code.google.com/p/kuda" target="_blank">Kuda</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/loaders/ColladaLoader.js"></script>
 		<script src="js/loaders/ColladaLoader.js"></script>
 
 

+ 1 - 1
examples/webgl_loader_ctm.html

@@ -35,7 +35,7 @@
 		<a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 		<a href="http://davidoreilly.com/post/18087489343/disneyhead" target="_blank">David OReilly</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/loaders/ctm/lzma.js"></script>
 		<script src="js/loaders/ctm/lzma.js"></script>
 		<script src="js/loaders/ctm/ctm.js"></script>
 		<script src="js/loaders/ctm/ctm.js"></script>

+ 1 - 1
examples/webgl_loader_ctm_materials.html

@@ -37,7 +37,7 @@
 		skybox by <a href="http://ict.debevec.org/~debevec/" target="_blank">Paul Debevec</a>
 		skybox by <a href="http://ict.debevec.org/~debevec/" target="_blank">Paul Debevec</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/loaders/ctm/lzma.js"></script>
 		<script src="js/loaders/ctm/lzma.js"></script>
 		<script src="js/loaders/ctm/ctm.js"></script>
 		<script src="js/loaders/ctm/ctm.js"></script>

+ 1 - 1
examples/webgl_loader_json_blender.html

@@ -32,7 +32,7 @@
 			monster by <a href="http://www.3drt.com/downloads.htm" target="_blank">3drt</a>
 			monster by <a href="http://www.3drt.com/downloads.htm" target="_blank">3drt</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="../src/loaders/LoadingMonitor.js"></script>
 		<script src="../src/loaders/LoadingMonitor.js"></script>
 		<script src="../src/loaders/GeometryLoader.js"></script>
 		<script src="../src/loaders/GeometryLoader.js"></script>

+ 1 - 1
examples/webgl_loader_json_objconverter.html

@@ -35,7 +35,7 @@
 			<a href="http://sketchup.google.com/3dwarehouse/details?mid=f526cc4abf7cb68d76cab47c765b7255">iClone</a>.
 			<a href="http://sketchup.google.com/3dwarehouse/details?mid=f526cc4abf7cb68d76cab47c765b7255">iClone</a>.
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_loader_obj.html

@@ -30,7 +30,7 @@
 		<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - OBJLoader test
 		<a href="http://github.com/mrdoob/three.js" target="_blank">three.js</a> - OBJLoader test
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/loaders/OBJLoader.js"></script>
 		<script src="js/loaders/OBJLoader.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>

+ 1 - 1
examples/webgl_loader_scene.html

@@ -147,7 +147,7 @@
 			</center>
 			</center>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_loader_scene_blender.html

@@ -147,7 +147,7 @@
 			</center>
 			</center>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_loader_utf8.html

@@ -32,7 +32,7 @@
 		models from <a href="http://www.sci.utah.edu/~wald/animrep/" target="_blank">The Utah 3D Animation Repository</a>
 		models from <a href="http://www.sci.utah.edu/~wald/animrep/" target="_blank">The Utah 3D Animation Repository</a>
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/loaders/UTF8Loader.js"></script>
 		<script src="js/loaders/UTF8Loader.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>

+ 1 - 1
examples/webgl_loader_vtk.html

@@ -32,7 +32,7 @@
 		model from <a href="http://www.cc.gatech.edu/projects/large_models/" target="_blank">The GeorgiaTech Lagre Geometric Model Archive</a>,
 		model from <a href="http://www.cc.gatech.edu/projects/large_models/" target="_blank">The GeorgiaTech Lagre Geometric Model Archive</a>,
 		</div>
 		</div>
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 		<script src="js/loaders/VTKLoader.js"></script>
 		<script src="js/loaders/VTKLoader.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>

+ 1 - 1
examples/webgl_lod.html

@@ -36,7 +36,7 @@
 		</div>
 		</div>
 
 
 
 
-		<script src="../build/Three.js"></script>
+		<script src="../build/three.min.js"></script>
 
 
 		<script src="js/Detector.js"></script>
 		<script src="js/Detector.js"></script>
 		<script src="js/Stats.js"></script>
 		<script src="js/Stats.js"></script>

+ 1 - 1
examples/webgl_marching_cubes.html

@@ -54,7 +54,7 @@
 		[based on greggman's <a href="http://webglsamples.googlecode.com/hg/blob/blob.html">blob</a>, original code by Henrik Rydgård]
 		[based on greggman's <a href="http://webglsamples.googlecode.com/hg/blob/blob.html">blob</a>, original code by Henrik Rydgård]
 	</div>
 	</div>
 
 
-	<script src="../build/Three.js"></script>
+	<script src="../build/three.min.js"></script>
 
 
 	<script src="js/MarchingCubes.js"></script>
 	<script src="js/MarchingCubes.js"></script>
 
 

Some files were not shown because too many files changed in this diff