{"version":3,"sources":["jsdelivr-header.js","/npm/videojs-vr@2.0.0/dist/videojs-vr.cjs.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;ACLA,aAEA,IAAI,SAAW,QAAQ,iBACnB,WAAa,QAAQ,mBACrB,cAAgB,QAAQ,qCACxB,QAAU,QAAQ,YAClB,kBAAoB,QAAQ,2CAC5B,SAAW,QAAQ,kCAEvB,SAAS,sBAAuB,GAAK,OAAO,GAAkB,iBAAN,GAAkB,YAAa,EAAI,EAAI,CAAE,QAAW,EAAK,CAEjH,IAAI,gBAA+B,sBAAsB,UACrD,kBAAiC,sBAAsB,YACvD,uBAAsC,sBAAsB,eAC5D,iBAAgC,sBAAsB,SACtD,2BAA0C,sBAAsB,mBAChE,kBAAiC,sBAAsB,UAEvD,QAAU,QAGd,MAAM,SAAW,MACX,MAAQ,CACZ,KAAM,EACN,OAAQ,EACR,MAAO,EACP,OAAQ,EACR,MAAO,EACP,IAAK,GAED,aAAe,EACf,aAAe,EACf,cAAgB,EAChB,aAAe,EACf,iBAAmB,EACnB,aAAe,EACf,UAAY,EACZ,SAAW,EACX,WAAa,EACb,YAAc,EACd,WAAa,EACb,eAAiB,EACjB,iBAAmB,EACnB,oBAAsB,EACtB,iBAAmB,EACnB,eAAiB,EACjB,YAAc,IACd,iBAAmB,IACnB,wBAA0B,IAC1B,YAAc,IACd,YAAc,IACd,WAAa,IACb,UAAY,IACZ,eAAiB,IACjB,uBAAyB,IACzB,eAAiB,IACjB,uBAAyB,IACzB,eAAiB,IACjB,uBAAyB,IACzB,eAAiB,IACjB,uBAAyB,IACzB,uBAAyB,IACzB,WAAa,EACb,YAAc,EACd,UAAY,EACZ,eAAiB,EACjB,WAAa,EACb,kBAAoB,EACpB,aAAe,EACf,cAAgB,EAChB,kBAAoB,EACpB,aAAe,EACf,aAAe,EACf,cAAgB,EAChB,kBAAoB,EACpB,oBAAsB,EACtB,kBAAoB,EACpB,sBAAwB,EACxB,kBAAoB,EACpB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,UAAU,UAAU,WAC9C,GAAG,UAAU,aAAe,UAAU,UAAU,aAChD,GAAG,QAAU,QACb,iBAA0B,QAAE,eAAe,KAAM,IAEjD,OAAO,QAAU","file":"/npm/videojs-vr@2.0.0/dist/videojs-vr.cjs.js","sourceRoot":"","sourcesContent":["/**\n * Minified by jsDelivr using Terser v5.37.0.\n * Original file: /npm/videojs-vr@2.0.0/dist/videojs-vr.cjs.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","/*! @name videojs-vr @version 2.0.0 @license MIT */\n'use strict';\n\nvar window$1 = require('global/window');\nvar document$1 = require('global/document');\nvar WebVRPolyfill = require('webvr-polyfill/src/webvr-polyfill');\nvar videojs = require('video.js');\nvar _asyncToGenerator = require('@babel/runtime/helpers/asyncToGenerator');\nvar _extends = require('@babel/runtime/helpers/extends');\n\nfunction _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }\n\nvar window__default = /*#__PURE__*/_interopDefaultLegacy(window$1);\nvar document__default = /*#__PURE__*/_interopDefaultLegacy(document$1);\nvar WebVRPolyfill__default = /*#__PURE__*/_interopDefaultLegacy(WebVRPolyfill);\nvar videojs__default = /*#__PURE__*/_interopDefaultLegacy(videojs);\nvar _asyncToGenerator__default = /*#__PURE__*/_interopDefaultLegacy(_asyncToGenerator);\nvar _extends__default = /*#__PURE__*/_interopDefaultLegacy(_extends);\n\nvar version = \"2.0.0\";\n\n// threejs.org/license\nconst REVISION = '125';\nconst MOUSE = {\n  LEFT: 0,\n  MIDDLE: 1,\n  RIGHT: 2,\n  ROTATE: 0,\n  DOLLY: 1,\n  PAN: 2\n};\nconst CullFaceNone = 0;\nconst CullFaceBack = 1;\nconst CullFaceFront = 2;\nconst PCFShadowMap = 1;\nconst PCFSoftShadowMap = 2;\nconst VSMShadowMap = 3;\nconst FrontSide = 0;\nconst BackSide = 1;\nconst DoubleSide = 2;\nconst FlatShading = 1;\nconst NoBlending = 0;\nconst NormalBlending = 1;\nconst AdditiveBlending = 2;\nconst SubtractiveBlending = 3;\nconst MultiplyBlending = 4;\nconst CustomBlending = 5;\nconst AddEquation = 100;\nconst SubtractEquation = 101;\nconst ReverseSubtractEquation = 102;\nconst MinEquation = 103;\nconst MaxEquation = 104;\nconst ZeroFactor = 200;\nconst OneFactor = 201;\nconst SrcColorFactor = 202;\nconst OneMinusSrcColorFactor = 203;\nconst SrcAlphaFactor = 204;\nconst OneMinusSrcAlphaFactor = 205;\nconst DstAlphaFactor = 206;\nconst OneMinusDstAlphaFactor = 207;\nconst DstColorFactor = 208;\nconst OneMinusDstColorFactor = 209;\nconst SrcAlphaSaturateFactor = 210;\nconst NeverDepth = 0;\nconst AlwaysDepth = 1;\nconst LessDepth = 2;\nconst LessEqualDepth = 3;\nconst EqualDepth = 4;\nconst GreaterEqualDepth = 5;\nconst GreaterDepth = 6;\nconst NotEqualDepth = 7;\nconst MultiplyOperation = 0;\nconst MixOperation = 1;\nconst AddOperation = 2;\nconst NoToneMapping = 0;\nconst LinearToneMapping = 1;\nconst ReinhardToneMapping = 2;\nconst CineonToneMapping = 3;\nconst ACESFilmicToneMapping = 4;\nconst CustomToneMapping = 5;\nconst UVMapping = 300;\nconst CubeReflectionMapping = 301;\nconst CubeRefractionMapping = 302;\nconst EquirectangularReflectionMapping = 303;\nconst EquirectangularRefractionMapping = 304;\nconst CubeUVReflectionMapping = 306;\nconst CubeUVRefractionMapping = 307;\nconst RepeatWrapping = 1000;\nconst ClampToEdgeWrapping = 1001;\nconst MirroredRepeatWrapping = 1002;\nconst NearestFilter = 1003;\nconst NearestMipmapNearestFilter = 1004;\nconst NearestMipmapLinearFilter = 1005;\nconst LinearFilter = 1006;\nconst LinearMipmapNearestFilter = 1007;\nconst LinearMipmapLinearFilter = 1008;\nconst UnsignedByteType = 1009;\nconst ByteType = 1010;\nconst ShortType = 1011;\nconst UnsignedShortType = 1012;\nconst IntType = 1013;\nconst UnsignedIntType = 1014;\nconst FloatType = 1015;\nconst HalfFloatType = 1016;\nconst UnsignedShort4444Type = 1017;\nconst UnsignedShort5551Type = 1018;\nconst UnsignedShort565Type = 1019;\nconst UnsignedInt248Type = 1020;\nconst AlphaFormat = 1021;\nconst RGBFormat = 1022;\nconst RGBAFormat = 1023;\nconst LuminanceFormat = 1024;\nconst LuminanceAlphaFormat = 1025;\nconst DepthFormat = 1026;\nconst DepthStencilFormat = 1027;\nconst RedFormat = 1028;\nconst RedIntegerFormat = 1029;\nconst RGFormat = 1030;\nconst RGIntegerFormat = 1031;\nconst RGBIntegerFormat = 1032;\nconst RGBAIntegerFormat = 1033;\nconst RGB_S3TC_DXT1_Format = 33776;\nconst RGBA_S3TC_DXT1_Format = 33777;\nconst RGBA_S3TC_DXT3_Format = 33778;\nconst RGBA_S3TC_DXT5_Format = 33779;\nconst RGB_PVRTC_4BPPV1_Format = 35840;\nconst RGB_PVRTC_2BPPV1_Format = 35841;\nconst RGBA_PVRTC_4BPPV1_Format = 35842;\nconst RGBA_PVRTC_2BPPV1_Format = 35843;\nconst RGB_ETC1_Format = 36196;\nconst RGB_ETC2_Format = 37492;\nconst RGBA_ETC2_EAC_Format = 37496;\nconst RGBA_ASTC_4x4_Format = 37808;\nconst RGBA_ASTC_5x4_Format = 37809;\nconst RGBA_ASTC_5x5_Format = 37810;\nconst RGBA_ASTC_6x5_Format = 37811;\nconst RGBA_ASTC_6x6_Format = 37812;\nconst RGBA_ASTC_8x5_Format = 37813;\nconst RGBA_ASTC_8x6_Format = 37814;\nconst RGBA_ASTC_8x8_Format = 37815;\nconst RGBA_ASTC_10x5_Format = 37816;\nconst RGBA_ASTC_10x6_Format = 37817;\nconst RGBA_ASTC_10x8_Format = 37818;\nconst RGBA_ASTC_10x10_Format = 37819;\nconst RGBA_ASTC_12x10_Format = 37820;\nconst RGBA_ASTC_12x12_Format = 37821;\nconst RGBA_BPTC_Format = 36492;\nconst SRGB8_ALPHA8_ASTC_4x4_Format = 37840;\nconst SRGB8_ALPHA8_ASTC_5x4_Format = 37841;\nconst SRGB8_ALPHA8_ASTC_5x5_Format = 37842;\nconst SRGB8_ALPHA8_ASTC_6x5_Format = 37843;\nconst SRGB8_ALPHA8_ASTC_6x6_Format = 37844;\nconst SRGB8_ALPHA8_ASTC_8x5_Format = 37845;\nconst SRGB8_ALPHA8_ASTC_8x6_Format = 37846;\nconst SRGB8_ALPHA8_ASTC_8x8_Format = 37847;\nconst SRGB8_ALPHA8_ASTC_10x5_Format = 37848;\nconst SRGB8_ALPHA8_ASTC_10x6_Format = 37849;\nconst SRGB8_ALPHA8_ASTC_10x8_Format = 37850;\nconst SRGB8_ALPHA8_ASTC_10x10_Format = 37851;\nconst SRGB8_ALPHA8_ASTC_12x10_Format = 37852;\nconst SRGB8_ALPHA8_ASTC_12x12_Format = 37853;\nconst LoopOnce = 2200;\nconst LoopRepeat = 2201;\nconst LoopPingPong = 2202;\nconst InterpolateDiscrete = 2300;\nconst InterpolateLinear = 2301;\nconst InterpolateSmooth = 2302;\nconst ZeroCurvatureEnding = 2400;\nconst ZeroSlopeEnding = 2401;\nconst WrapAroundEnding = 2402;\nconst NormalAnimationBlendMode = 2500;\nconst AdditiveAnimationBlendMode = 2501;\nconst TrianglesDrawMode = 0;\nconst LinearEncoding = 3000;\nconst sRGBEncoding = 3001;\nconst GammaEncoding = 3007;\nconst RGBEEncoding = 3002;\nconst LogLuvEncoding = 3003;\nconst RGBM7Encoding = 3004;\nconst RGBM16Encoding = 3005;\nconst RGBDEncoding = 3006;\nconst BasicDepthPacking = 3200;\nconst RGBADepthPacking = 3201;\nconst TangentSpaceNormalMap = 0;\nconst ObjectSpaceNormalMap = 1;\nconst KeepStencilOp = 7680;\nconst AlwaysStencilFunc = 519;\nconst StaticDrawUsage = 35044;\nconst DynamicDrawUsage = 35048;\nconst GLSL3 = '300 es';\n\n/**\n * https://github.com/mrdoob/eventdispatcher.js/\n */\n\nfunction EventDispatcher() {}\n_extends__default['default'](EventDispatcher.prototype, {\n  addEventListener: function (type, listener) {\n    if (this._listeners === undefined) this._listeners = {};\n    const listeners = this._listeners;\n    if (listeners[type] === undefined) {\n      listeners[type] = [];\n    }\n    if (listeners[type].indexOf(listener) === -1) {\n      listeners[type].push(listener);\n    }\n  },\n  hasEventListener: function (type, listener) {\n    if (this._listeners === undefined) return false;\n    const listeners = this._listeners;\n    return listeners[type] !== undefined && listeners[type].indexOf(listener) !== -1;\n  },\n  removeEventListener: function (type, listener) {\n    if (this._listeners === undefined) return;\n    const listeners = this._listeners;\n    const listenerArray = listeners[type];\n    if (listenerArray !== undefined) {\n      const index = listenerArray.indexOf(listener);\n      if (index !== -1) {\n        listenerArray.splice(index, 1);\n      }\n    }\n  },\n  dispatchEvent: function (event) {\n    if (this._listeners === undefined) return;\n    const listeners = this._listeners;\n    const listenerArray = listeners[event.type];\n    if (listenerArray !== undefined) {\n      event.target = this;\n\n      // Make a copy, in case listeners are removed while iterating.\n      const array = listenerArray.slice(0);\n      for (let i = 0, l = array.length; i < l; i++) {\n        array[i].call(this, event);\n      }\n    }\n  }\n});\nconst _lut = [];\nfor (let i = 0; i < 256; i++) {\n  _lut[i] = (i < 16 ? '0' : '') + i.toString(16);\n}\nlet _seed = 1234567;\nconst MathUtils = {\n  DEG2RAD: Math.PI / 180,\n  RAD2DEG: 180 / Math.PI,\n  generateUUID: function () {\n    // http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript/21963136#21963136\n\n    const d0 = Math.random() * 0xffffffff | 0;\n    const d1 = Math.random() * 0xffffffff | 0;\n    const d2 = Math.random() * 0xffffffff | 0;\n    const d3 = Math.random() * 0xffffffff | 0;\n    const uuid = _lut[d0 & 0xff] + _lut[d0 >> 8 & 0xff] + _lut[d0 >> 16 & 0xff] + _lut[d0 >> 24 & 0xff] + '-' + _lut[d1 & 0xff] + _lut[d1 >> 8 & 0xff] + '-' + _lut[d1 >> 16 & 0x0f | 0x40] + _lut[d1 >> 24 & 0xff] + '-' + _lut[d2 & 0x3f | 0x80] + _lut[d2 >> 8 & 0xff] + '-' + _lut[d2 >> 16 & 0xff] + _lut[d2 >> 24 & 0xff] + _lut[d3 & 0xff] + _lut[d3 >> 8 & 0xff] + _lut[d3 >> 16 & 0xff] + _lut[d3 >> 24 & 0xff];\n\n    // .toUpperCase() here flattens concatenated strings to save heap memory space.\n    return uuid.toUpperCase();\n  },\n  clamp: function (value, min, max) {\n    return Math.max(min, Math.min(max, value));\n  },\n  // compute euclidian modulo of m % n\n  // https://en.wikipedia.org/wiki/Modulo_operation\n\n  euclideanModulo: function (n, m) {\n    return (n % m + m) % m;\n  },\n  // Linear mapping from range <a1, a2> to range <b1, b2>\n\n  mapLinear: function (x, a1, a2, b1, b2) {\n    return b1 + (x - a1) * (b2 - b1) / (a2 - a1);\n  },\n  // https://en.wikipedia.org/wiki/Linear_interpolation\n\n  lerp: function (x, y, t) {\n    return (1 - t) * x + t * y;\n  },\n  // http://www.rorydriscoll.com/2016/03/07/frame-rate-independent-damping-using-lerp/\n\n  damp: function (x, y, lambda, dt) {\n    return MathUtils.lerp(x, y, 1 - Math.exp(-lambda * dt));\n  },\n  // https://www.desmos.com/calculator/vcsjnyz7x4\n\n  pingpong: function (x, length = 1) {\n    return length - Math.abs(MathUtils.euclideanModulo(x, length * 2) - length);\n  },\n  // http://en.wikipedia.org/wiki/Smoothstep\n\n  smoothstep: function (x, min, max) {\n    if (x <= min) return 0;\n    if (x >= max) return 1;\n    x = (x - min) / (max - min);\n    return x * x * (3 - 2 * x);\n  },\n  smootherstep: function (x, min, max) {\n    if (x <= min) return 0;\n    if (x >= max) return 1;\n    x = (x - min) / (max - min);\n    return x * x * x * (x * (x * 6 - 15) + 10);\n  },\n  // Random integer from <low, high> interval\n\n  randInt: function (low, high) {\n    return low + Math.floor(Math.random() * (high - low + 1));\n  },\n  // Random float from <low, high> interval\n\n  randFloat: function (low, high) {\n    return low + Math.random() * (high - low);\n  },\n  // Random float from <-range/2, range/2> interval\n\n  randFloatSpread: function (range) {\n    return range * (0.5 - Math.random());\n  },\n  // Deterministic pseudo-random float in the interval [ 0, 1 ]\n\n  seededRandom: function (s) {\n    if (s !== undefined) _seed = s % 2147483647;\n\n    // Park-Miller algorithm\n\n    _seed = _seed * 16807 % 2147483647;\n    return (_seed - 1) / 2147483646;\n  },\n  degToRad: function (degrees) {\n    return degrees * MathUtils.DEG2RAD;\n  },\n  radToDeg: function (radians) {\n    return radians * MathUtils.RAD2DEG;\n  },\n  isPowerOfTwo: function (value) {\n    return (value & value - 1) === 0 && value !== 0;\n  },\n  ceilPowerOfTwo: function (value) {\n    return Math.pow(2, Math.ceil(Math.log(value) / Math.LN2));\n  },\n  floorPowerOfTwo: function (value) {\n    return Math.pow(2, Math.floor(Math.log(value) / Math.LN2));\n  },\n  setQuaternionFromProperEuler: function (q, a, b, c, order) {\n    // Intrinsic Proper Euler Angles - see https://en.wikipedia.org/wiki/Euler_angles\n\n    // rotations are applied to the axes in the order specified by 'order'\n    // rotation by angle 'a' is applied first, then by angle 'b', then by angle 'c'\n    // angles are in radians\n\n    const cos = Math.cos;\n    const sin = Math.sin;\n    const c2 = cos(b / 2);\n    const s2 = sin(b / 2);\n    const c13 = cos((a + c) / 2);\n    const s13 = sin((a + c) / 2);\n    const c1_3 = cos((a - c) / 2);\n    const s1_3 = sin((a - c) / 2);\n    const c3_1 = cos((c - a) / 2);\n    const s3_1 = sin((c - a) / 2);\n    switch (order) {\n      case 'XYX':\n        q.set(c2 * s13, s2 * c1_3, s2 * s1_3, c2 * c13);\n        break;\n      case 'YZY':\n        q.set(s2 * s1_3, c2 * s13, s2 * c1_3, c2 * c13);\n        break;\n      case 'ZXZ':\n        q.set(s2 * c1_3, s2 * s1_3, c2 * s13, c2 * c13);\n        break;\n      case 'XZX':\n        q.set(c2 * s13, s2 * s3_1, s2 * c3_1, c2 * c13);\n        break;\n      case 'YXY':\n        q.set(s2 * c3_1, c2 * s13, s2 * s3_1, c2 * c13);\n        break;\n      case 'ZYZ':\n        q.set(s2 * s3_1, s2 * c3_1, c2 * s13, c2 * c13);\n        break;\n      default:\n        console.warn('THREE.MathUtils: .setQuaternionFromProperEuler() encountered an unknown order: ' + order);\n    }\n  }\n};\nclass Vector2 {\n  constructor(x = 0, y = 0) {\n    Object.defineProperty(this, 'isVector2', {\n      value: true\n    });\n    this.x = x;\n    this.y = y;\n  }\n  get width() {\n    return this.x;\n  }\n  set width(value) {\n    this.x = value;\n  }\n  get height() {\n    return this.y;\n  }\n  set height(value) {\n    this.y = value;\n  }\n  set(x, y) {\n    this.x = x;\n    this.y = y;\n    return this;\n  }\n  setScalar(scalar) {\n    this.x = scalar;\n    this.y = scalar;\n    return this;\n  }\n  setX(x) {\n    this.x = x;\n    return this;\n  }\n  setY(y) {\n    this.y = y;\n    return this;\n  }\n  setComponent(index, value) {\n    switch (index) {\n      case 0:\n        this.x = value;\n        break;\n      case 1:\n        this.y = value;\n        break;\n      default:\n        throw new Error('index is out of range: ' + index);\n    }\n    return this;\n  }\n  getComponent(index) {\n    switch (index) {\n      case 0:\n        return this.x;\n      case 1:\n        return this.y;\n      default:\n        throw new Error('index is out of range: ' + index);\n    }\n  }\n  clone() {\n    return new this.constructor(this.x, this.y);\n  }\n  copy(v) {\n    this.x = v.x;\n    this.y = v.y;\n    return this;\n  }\n  add(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');\n      return this.addVectors(v, w);\n    }\n    this.x += v.x;\n    this.y += v.y;\n    return this;\n  }\n  addScalar(s) {\n    this.x += s;\n    this.y += s;\n    return this;\n  }\n  addVectors(a, b) {\n    this.x = a.x + b.x;\n    this.y = a.y + b.y;\n    return this;\n  }\n  addScaledVector(v, s) {\n    this.x += v.x * s;\n    this.y += v.y * s;\n    return this;\n  }\n  sub(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');\n      return this.subVectors(v, w);\n    }\n    this.x -= v.x;\n    this.y -= v.y;\n    return this;\n  }\n  subScalar(s) {\n    this.x -= s;\n    this.y -= s;\n    return this;\n  }\n  subVectors(a, b) {\n    this.x = a.x - b.x;\n    this.y = a.y - b.y;\n    return this;\n  }\n  multiply(v) {\n    this.x *= v.x;\n    this.y *= v.y;\n    return this;\n  }\n  multiplyScalar(scalar) {\n    this.x *= scalar;\n    this.y *= scalar;\n    return this;\n  }\n  divide(v) {\n    this.x /= v.x;\n    this.y /= v.y;\n    return this;\n  }\n  divideScalar(scalar) {\n    return this.multiplyScalar(1 / scalar);\n  }\n  applyMatrix3(m) {\n    const x = this.x,\n      y = this.y;\n    const e = m.elements;\n    this.x = e[0] * x + e[3] * y + e[6];\n    this.y = e[1] * x + e[4] * y + e[7];\n    return this;\n  }\n  min(v) {\n    this.x = Math.min(this.x, v.x);\n    this.y = Math.min(this.y, v.y);\n    return this;\n  }\n  max(v) {\n    this.x = Math.max(this.x, v.x);\n    this.y = Math.max(this.y, v.y);\n    return this;\n  }\n  clamp(min, max) {\n    // assumes min < max, componentwise\n\n    this.x = Math.max(min.x, Math.min(max.x, this.x));\n    this.y = Math.max(min.y, Math.min(max.y, this.y));\n    return this;\n  }\n  clampScalar(minVal, maxVal) {\n    this.x = Math.max(minVal, Math.min(maxVal, this.x));\n    this.y = Math.max(minVal, Math.min(maxVal, this.y));\n    return this;\n  }\n  clampLength(min, max) {\n    const length = this.length();\n    return this.divideScalar(length || 1).multiplyScalar(Math.max(min, Math.min(max, length)));\n  }\n  floor() {\n    this.x = Math.floor(this.x);\n    this.y = Math.floor(this.y);\n    return this;\n  }\n  ceil() {\n    this.x = Math.ceil(this.x);\n    this.y = Math.ceil(this.y);\n    return this;\n  }\n  round() {\n    this.x = Math.round(this.x);\n    this.y = Math.round(this.y);\n    return this;\n  }\n  roundToZero() {\n    this.x = this.x < 0 ? Math.ceil(this.x) : Math.floor(this.x);\n    this.y = this.y < 0 ? Math.ceil(this.y) : Math.floor(this.y);\n    return this;\n  }\n  negate() {\n    this.x = -this.x;\n    this.y = -this.y;\n    return this;\n  }\n  dot(v) {\n    return this.x * v.x + this.y * v.y;\n  }\n  cross(v) {\n    return this.x * v.y - this.y * v.x;\n  }\n  lengthSq() {\n    return this.x * this.x + this.y * this.y;\n  }\n  length() {\n    return Math.sqrt(this.x * this.x + this.y * this.y);\n  }\n  manhattanLength() {\n    return Math.abs(this.x) + Math.abs(this.y);\n  }\n  normalize() {\n    return this.divideScalar(this.length() || 1);\n  }\n  angle() {\n    // computes the angle in radians with respect to the positive x-axis\n\n    const angle = Math.atan2(-this.y, -this.x) + Math.PI;\n    return angle;\n  }\n  distanceTo(v) {\n    return Math.sqrt(this.distanceToSquared(v));\n  }\n  distanceToSquared(v) {\n    const dx = this.x - v.x,\n      dy = this.y - v.y;\n    return dx * dx + dy * dy;\n  }\n  manhattanDistanceTo(v) {\n    return Math.abs(this.x - v.x) + Math.abs(this.y - v.y);\n  }\n  setLength(length) {\n    return this.normalize().multiplyScalar(length);\n  }\n  lerp(v, alpha) {\n    this.x += (v.x - this.x) * alpha;\n    this.y += (v.y - this.y) * alpha;\n    return this;\n  }\n  lerpVectors(v1, v2, alpha) {\n    this.x = v1.x + (v2.x - v1.x) * alpha;\n    this.y = v1.y + (v2.y - v1.y) * alpha;\n    return this;\n  }\n  equals(v) {\n    return v.x === this.x && v.y === this.y;\n  }\n  fromArray(array, offset = 0) {\n    this.x = array[offset];\n    this.y = array[offset + 1];\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    array[offset] = this.x;\n    array[offset + 1] = this.y;\n    return array;\n  }\n  fromBufferAttribute(attribute, index, offset) {\n    if (offset !== undefined) {\n      console.warn('THREE.Vector2: offset has been removed from .fromBufferAttribute().');\n    }\n    this.x = attribute.getX(index);\n    this.y = attribute.getY(index);\n    return this;\n  }\n  rotateAround(center, angle) {\n    const c = Math.cos(angle),\n      s = Math.sin(angle);\n    const x = this.x - center.x;\n    const y = this.y - center.y;\n    this.x = x * c - y * s + center.x;\n    this.y = x * s + y * c + center.y;\n    return this;\n  }\n  random() {\n    this.x = Math.random();\n    this.y = Math.random();\n    return this;\n  }\n}\nclass Matrix3 {\n  constructor() {\n    Object.defineProperty(this, 'isMatrix3', {\n      value: true\n    });\n    this.elements = [1, 0, 0, 0, 1, 0, 0, 0, 1];\n    if (arguments.length > 0) {\n      console.error('THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.');\n    }\n  }\n  set(n11, n12, n13, n21, n22, n23, n31, n32, n33) {\n    const te = this.elements;\n    te[0] = n11;\n    te[1] = n21;\n    te[2] = n31;\n    te[3] = n12;\n    te[4] = n22;\n    te[5] = n32;\n    te[6] = n13;\n    te[7] = n23;\n    te[8] = n33;\n    return this;\n  }\n  identity() {\n    this.set(1, 0, 0, 0, 1, 0, 0, 0, 1);\n    return this;\n  }\n  clone() {\n    return new this.constructor().fromArray(this.elements);\n  }\n  copy(m) {\n    const te = this.elements;\n    const me = m.elements;\n    te[0] = me[0];\n    te[1] = me[1];\n    te[2] = me[2];\n    te[3] = me[3];\n    te[4] = me[4];\n    te[5] = me[5];\n    te[6] = me[6];\n    te[7] = me[7];\n    te[8] = me[8];\n    return this;\n  }\n  extractBasis(xAxis, yAxis, zAxis) {\n    xAxis.setFromMatrix3Column(this, 0);\n    yAxis.setFromMatrix3Column(this, 1);\n    zAxis.setFromMatrix3Column(this, 2);\n    return this;\n  }\n  setFromMatrix4(m) {\n    const me = m.elements;\n    this.set(me[0], me[4], me[8], me[1], me[5], me[9], me[2], me[6], me[10]);\n    return this;\n  }\n  multiply(m) {\n    return this.multiplyMatrices(this, m);\n  }\n  premultiply(m) {\n    return this.multiplyMatrices(m, this);\n  }\n  multiplyMatrices(a, b) {\n    const ae = a.elements;\n    const be = b.elements;\n    const te = this.elements;\n    const a11 = ae[0],\n      a12 = ae[3],\n      a13 = ae[6];\n    const a21 = ae[1],\n      a22 = ae[4],\n      a23 = ae[7];\n    const a31 = ae[2],\n      a32 = ae[5],\n      a33 = ae[8];\n    const b11 = be[0],\n      b12 = be[3],\n      b13 = be[6];\n    const b21 = be[1],\n      b22 = be[4],\n      b23 = be[7];\n    const b31 = be[2],\n      b32 = be[5],\n      b33 = be[8];\n    te[0] = a11 * b11 + a12 * b21 + a13 * b31;\n    te[3] = a11 * b12 + a12 * b22 + a13 * b32;\n    te[6] = a11 * b13 + a12 * b23 + a13 * b33;\n    te[1] = a21 * b11 + a22 * b21 + a23 * b31;\n    te[4] = a21 * b12 + a22 * b22 + a23 * b32;\n    te[7] = a21 * b13 + a22 * b23 + a23 * b33;\n    te[2] = a31 * b11 + a32 * b21 + a33 * b31;\n    te[5] = a31 * b12 + a32 * b22 + a33 * b32;\n    te[8] = a31 * b13 + a32 * b23 + a33 * b33;\n    return this;\n  }\n  multiplyScalar(s) {\n    const te = this.elements;\n    te[0] *= s;\n    te[3] *= s;\n    te[6] *= s;\n    te[1] *= s;\n    te[4] *= s;\n    te[7] *= s;\n    te[2] *= s;\n    te[5] *= s;\n    te[8] *= s;\n    return this;\n  }\n  determinant() {\n    const te = this.elements;\n    const a = te[0],\n      b = te[1],\n      c = te[2],\n      d = te[3],\n      e = te[4],\n      f = te[5],\n      g = te[6],\n      h = te[7],\n      i = te[8];\n    return a * e * i - a * f * h - b * d * i + b * f * g + c * d * h - c * e * g;\n  }\n  invert() {\n    const te = this.elements,\n      n11 = te[0],\n      n21 = te[1],\n      n31 = te[2],\n      n12 = te[3],\n      n22 = te[4],\n      n32 = te[5],\n      n13 = te[6],\n      n23 = te[7],\n      n33 = te[8],\n      t11 = n33 * n22 - n32 * n23,\n      t12 = n32 * n13 - n33 * n12,\n      t13 = n23 * n12 - n22 * n13,\n      det = n11 * t11 + n21 * t12 + n31 * t13;\n    if (det === 0) return this.set(0, 0, 0, 0, 0, 0, 0, 0, 0);\n    const detInv = 1 / det;\n    te[0] = t11 * detInv;\n    te[1] = (n31 * n23 - n33 * n21) * detInv;\n    te[2] = (n32 * n21 - n31 * n22) * detInv;\n    te[3] = t12 * detInv;\n    te[4] = (n33 * n11 - n31 * n13) * detInv;\n    te[5] = (n31 * n12 - n32 * n11) * detInv;\n    te[6] = t13 * detInv;\n    te[7] = (n21 * n13 - n23 * n11) * detInv;\n    te[8] = (n22 * n11 - n21 * n12) * detInv;\n    return this;\n  }\n  transpose() {\n    let tmp;\n    const m = this.elements;\n    tmp = m[1];\n    m[1] = m[3];\n    m[3] = tmp;\n    tmp = m[2];\n    m[2] = m[6];\n    m[6] = tmp;\n    tmp = m[5];\n    m[5] = m[7];\n    m[7] = tmp;\n    return this;\n  }\n  getNormalMatrix(matrix4) {\n    return this.setFromMatrix4(matrix4).copy(this).invert().transpose();\n  }\n  transposeIntoArray(r) {\n    const m = this.elements;\n    r[0] = m[0];\n    r[1] = m[3];\n    r[2] = m[6];\n    r[3] = m[1];\n    r[4] = m[4];\n    r[5] = m[7];\n    r[6] = m[2];\n    r[7] = m[5];\n    r[8] = m[8];\n    return this;\n  }\n  setUvTransform(tx, ty, sx, sy, rotation, cx, cy) {\n    const c = Math.cos(rotation);\n    const s = Math.sin(rotation);\n    this.set(sx * c, sx * s, -sx * (c * cx + s * cy) + cx + tx, -sy * s, sy * c, -sy * (-s * cx + c * cy) + cy + ty, 0, 0, 1);\n    return this;\n  }\n  scale(sx, sy) {\n    const te = this.elements;\n    te[0] *= sx;\n    te[3] *= sx;\n    te[6] *= sx;\n    te[1] *= sy;\n    te[4] *= sy;\n    te[7] *= sy;\n    return this;\n  }\n  rotate(theta) {\n    const c = Math.cos(theta);\n    const s = Math.sin(theta);\n    const te = this.elements;\n    const a11 = te[0],\n      a12 = te[3],\n      a13 = te[6];\n    const a21 = te[1],\n      a22 = te[4],\n      a23 = te[7];\n    te[0] = c * a11 + s * a21;\n    te[3] = c * a12 + s * a22;\n    te[6] = c * a13 + s * a23;\n    te[1] = -s * a11 + c * a21;\n    te[4] = -s * a12 + c * a22;\n    te[7] = -s * a13 + c * a23;\n    return this;\n  }\n  translate(tx, ty) {\n    const te = this.elements;\n    te[0] += tx * te[2];\n    te[3] += tx * te[5];\n    te[6] += tx * te[8];\n    te[1] += ty * te[2];\n    te[4] += ty * te[5];\n    te[7] += ty * te[8];\n    return this;\n  }\n  equals(matrix) {\n    const te = this.elements;\n    const me = matrix.elements;\n    for (let i = 0; i < 9; i++) {\n      if (te[i] !== me[i]) return false;\n    }\n    return true;\n  }\n  fromArray(array, offset = 0) {\n    for (let i = 0; i < 9; i++) {\n      this.elements[i] = array[i + offset];\n    }\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    const te = this.elements;\n    array[offset] = te[0];\n    array[offset + 1] = te[1];\n    array[offset + 2] = te[2];\n    array[offset + 3] = te[3];\n    array[offset + 4] = te[4];\n    array[offset + 5] = te[5];\n    array[offset + 6] = te[6];\n    array[offset + 7] = te[7];\n    array[offset + 8] = te[8];\n    return array;\n  }\n}\nlet _canvas;\nconst ImageUtils = {\n  getDataURL: function (image) {\n    if (/^data:/i.test(image.src)) {\n      return image.src;\n    }\n    if (typeof HTMLCanvasElement == 'undefined') {\n      return image.src;\n    }\n    let canvas;\n    if (image instanceof HTMLCanvasElement) {\n      canvas = image;\n    } else {\n      if (_canvas === undefined) _canvas = document.createElementNS('http://www.w3.org/1999/xhtml', 'canvas');\n      _canvas.width = image.width;\n      _canvas.height = image.height;\n      const context = _canvas.getContext('2d');\n      if (image instanceof ImageData) {\n        context.putImageData(image, 0, 0);\n      } else {\n        context.drawImage(image, 0, 0, image.width, image.height);\n      }\n      canvas = _canvas;\n    }\n    if (canvas.width > 2048 || canvas.height > 2048) {\n      return canvas.toDataURL('image/jpeg', 0.6);\n    } else {\n      return canvas.toDataURL('image/png');\n    }\n  }\n};\nlet textureId = 0;\nfunction Texture(image = Texture.DEFAULT_IMAGE, mapping = Texture.DEFAULT_MAPPING, wrapS = ClampToEdgeWrapping, wrapT = ClampToEdgeWrapping, magFilter = LinearFilter, minFilter = LinearMipmapLinearFilter, format = RGBAFormat, type = UnsignedByteType, anisotropy = 1, encoding = LinearEncoding) {\n  Object.defineProperty(this, 'id', {\n    value: textureId++\n  });\n  this.uuid = MathUtils.generateUUID();\n  this.name = '';\n  this.image = image;\n  this.mipmaps = [];\n  this.mapping = mapping;\n  this.wrapS = wrapS;\n  this.wrapT = wrapT;\n  this.magFilter = magFilter;\n  this.minFilter = minFilter;\n  this.anisotropy = anisotropy;\n  this.format = format;\n  this.internalFormat = null;\n  this.type = type;\n  this.offset = new Vector2(0, 0);\n  this.repeat = new Vector2(1, 1);\n  this.center = new Vector2(0, 0);\n  this.rotation = 0;\n  this.matrixAutoUpdate = true;\n  this.matrix = new Matrix3();\n  this.generateMipmaps = true;\n  this.premultiplyAlpha = false;\n  this.flipY = true;\n  this.unpackAlignment = 4; // valid values: 1, 2, 4, 8 (see http://www.khronos.org/opengles/sdk/docs/man/xhtml/glPixelStorei.xml)\n\n  // Values of encoding !== THREE.LinearEncoding only supported on map, envMap and emissiveMap.\n  //\n  // Also changing the encoding after already used by a Material will not automatically make the Material\n  // update. You need to explicitly call Material.needsUpdate to trigger it to recompile.\n  this.encoding = encoding;\n  this.version = 0;\n  this.onUpdate = null;\n}\nTexture.DEFAULT_IMAGE = undefined;\nTexture.DEFAULT_MAPPING = UVMapping;\nTexture.prototype = _extends__default['default'](Object.create(EventDispatcher.prototype), {\n  constructor: Texture,\n  isTexture: true,\n  updateMatrix: function () {\n    this.matrix.setUvTransform(this.offset.x, this.offset.y, this.repeat.x, this.repeat.y, this.rotation, this.center.x, this.center.y);\n  },\n  clone: function () {\n    return new this.constructor().copy(this);\n  },\n  copy: function (source) {\n    this.name = source.name;\n    this.image = source.image;\n    this.mipmaps = source.mipmaps.slice(0);\n    this.mapping = source.mapping;\n    this.wrapS = source.wrapS;\n    this.wrapT = source.wrapT;\n    this.magFilter = source.magFilter;\n    this.minFilter = source.minFilter;\n    this.anisotropy = source.anisotropy;\n    this.format = source.format;\n    this.internalFormat = source.internalFormat;\n    this.type = source.type;\n    this.offset.copy(source.offset);\n    this.repeat.copy(source.repeat);\n    this.center.copy(source.center);\n    this.rotation = source.rotation;\n    this.matrixAutoUpdate = source.matrixAutoUpdate;\n    this.matrix.copy(source.matrix);\n    this.generateMipmaps = source.generateMipmaps;\n    this.premultiplyAlpha = source.premultiplyAlpha;\n    this.flipY = source.flipY;\n    this.unpackAlignment = source.unpackAlignment;\n    this.encoding = source.encoding;\n    return this;\n  },\n  toJSON: function (meta) {\n    const isRootObject = meta === undefined || typeof meta === 'string';\n    if (!isRootObject && meta.textures[this.uuid] !== undefined) {\n      return meta.textures[this.uuid];\n    }\n    const output = {\n      metadata: {\n        version: 4.5,\n        type: 'Texture',\n        generator: 'Texture.toJSON'\n      },\n      uuid: this.uuid,\n      name: this.name,\n      mapping: this.mapping,\n      repeat: [this.repeat.x, this.repeat.y],\n      offset: [this.offset.x, this.offset.y],\n      center: [this.center.x, this.center.y],\n      rotation: this.rotation,\n      wrap: [this.wrapS, this.wrapT],\n      format: this.format,\n      type: this.type,\n      encoding: this.encoding,\n      minFilter: this.minFilter,\n      magFilter: this.magFilter,\n      anisotropy: this.anisotropy,\n      flipY: this.flipY,\n      premultiplyAlpha: this.premultiplyAlpha,\n      unpackAlignment: this.unpackAlignment\n    };\n    if (this.image !== undefined) {\n      // TODO: Move to THREE.Image\n\n      const image = this.image;\n      if (image.uuid === undefined) {\n        image.uuid = MathUtils.generateUUID(); // UGH\n      }\n\n      if (!isRootObject && meta.images[image.uuid] === undefined) {\n        let url;\n        if (Array.isArray(image)) {\n          // process array of images e.g. CubeTexture\n\n          url = [];\n          for (let i = 0, l = image.length; i < l; i++) {\n            // check cube texture with data textures\n\n            if (image[i].isDataTexture) {\n              url.push(serializeImage(image[i].image));\n            } else {\n              url.push(serializeImage(image[i]));\n            }\n          }\n        } else {\n          // process single image\n\n          url = serializeImage(image);\n        }\n        meta.images[image.uuid] = {\n          uuid: image.uuid,\n          url: url\n        };\n      }\n      output.image = image.uuid;\n    }\n    if (!isRootObject) {\n      meta.textures[this.uuid] = output;\n    }\n    return output;\n  },\n  dispose: function () {\n    this.dispatchEvent({\n      type: 'dispose'\n    });\n  },\n  transformUv: function (uv) {\n    if (this.mapping !== UVMapping) return uv;\n    uv.applyMatrix3(this.matrix);\n    if (uv.x < 0 || uv.x > 1) {\n      switch (this.wrapS) {\n        case RepeatWrapping:\n          uv.x = uv.x - Math.floor(uv.x);\n          break;\n        case ClampToEdgeWrapping:\n          uv.x = uv.x < 0 ? 0 : 1;\n          break;\n        case MirroredRepeatWrapping:\n          if (Math.abs(Math.floor(uv.x) % 2) === 1) {\n            uv.x = Math.ceil(uv.x) - uv.x;\n          } else {\n            uv.x = uv.x - Math.floor(uv.x);\n          }\n          break;\n      }\n    }\n    if (uv.y < 0 || uv.y > 1) {\n      switch (this.wrapT) {\n        case RepeatWrapping:\n          uv.y = uv.y - Math.floor(uv.y);\n          break;\n        case ClampToEdgeWrapping:\n          uv.y = uv.y < 0 ? 0 : 1;\n          break;\n        case MirroredRepeatWrapping:\n          if (Math.abs(Math.floor(uv.y) % 2) === 1) {\n            uv.y = Math.ceil(uv.y) - uv.y;\n          } else {\n            uv.y = uv.y - Math.floor(uv.y);\n          }\n          break;\n      }\n    }\n    if (this.flipY) {\n      uv.y = 1 - uv.y;\n    }\n    return uv;\n  }\n});\nObject.defineProperty(Texture.prototype, 'needsUpdate', {\n  set: function (value) {\n    if (value === true) this.version++;\n  }\n});\nfunction serializeImage(image) {\n  if (typeof HTMLImageElement !== 'undefined' && image instanceof HTMLImageElement || typeof HTMLCanvasElement !== 'undefined' && image instanceof HTMLCanvasElement || typeof ImageBitmap !== 'undefined' && image instanceof ImageBitmap) {\n    // default images\n\n    return ImageUtils.getDataURL(image);\n  } else {\n    if (image.data) {\n      // images of DataTexture\n\n      return {\n        data: Array.prototype.slice.call(image.data),\n        width: image.width,\n        height: image.height,\n        type: image.data.constructor.name\n      };\n    } else {\n      console.warn('THREE.Texture: Unable to serialize Texture.');\n      return {};\n    }\n  }\n}\nclass Vector4 {\n  constructor(x = 0, y = 0, z = 0, w = 1) {\n    Object.defineProperty(this, 'isVector4', {\n      value: true\n    });\n    this.x = x;\n    this.y = y;\n    this.z = z;\n    this.w = w;\n  }\n  get width() {\n    return this.z;\n  }\n  set width(value) {\n    this.z = value;\n  }\n  get height() {\n    return this.w;\n  }\n  set height(value) {\n    this.w = value;\n  }\n  set(x, y, z, w) {\n    this.x = x;\n    this.y = y;\n    this.z = z;\n    this.w = w;\n    return this;\n  }\n  setScalar(scalar) {\n    this.x = scalar;\n    this.y = scalar;\n    this.z = scalar;\n    this.w = scalar;\n    return this;\n  }\n  setX(x) {\n    this.x = x;\n    return this;\n  }\n  setY(y) {\n    this.y = y;\n    return this;\n  }\n  setZ(z) {\n    this.z = z;\n    return this;\n  }\n  setW(w) {\n    this.w = w;\n    return this;\n  }\n  setComponent(index, value) {\n    switch (index) {\n      case 0:\n        this.x = value;\n        break;\n      case 1:\n        this.y = value;\n        break;\n      case 2:\n        this.z = value;\n        break;\n      case 3:\n        this.w = value;\n        break;\n      default:\n        throw new Error('index is out of range: ' + index);\n    }\n    return this;\n  }\n  getComponent(index) {\n    switch (index) {\n      case 0:\n        return this.x;\n      case 1:\n        return this.y;\n      case 2:\n        return this.z;\n      case 3:\n        return this.w;\n      default:\n        throw new Error('index is out of range: ' + index);\n    }\n  }\n  clone() {\n    return new this.constructor(this.x, this.y, this.z, this.w);\n  }\n  copy(v) {\n    this.x = v.x;\n    this.y = v.y;\n    this.z = v.z;\n    this.w = v.w !== undefined ? v.w : 1;\n    return this;\n  }\n  add(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');\n      return this.addVectors(v, w);\n    }\n    this.x += v.x;\n    this.y += v.y;\n    this.z += v.z;\n    this.w += v.w;\n    return this;\n  }\n  addScalar(s) {\n    this.x += s;\n    this.y += s;\n    this.z += s;\n    this.w += s;\n    return this;\n  }\n  addVectors(a, b) {\n    this.x = a.x + b.x;\n    this.y = a.y + b.y;\n    this.z = a.z + b.z;\n    this.w = a.w + b.w;\n    return this;\n  }\n  addScaledVector(v, s) {\n    this.x += v.x * s;\n    this.y += v.y * s;\n    this.z += v.z * s;\n    this.w += v.w * s;\n    return this;\n  }\n  sub(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');\n      return this.subVectors(v, w);\n    }\n    this.x -= v.x;\n    this.y -= v.y;\n    this.z -= v.z;\n    this.w -= v.w;\n    return this;\n  }\n  subScalar(s) {\n    this.x -= s;\n    this.y -= s;\n    this.z -= s;\n    this.w -= s;\n    return this;\n  }\n  subVectors(a, b) {\n    this.x = a.x - b.x;\n    this.y = a.y - b.y;\n    this.z = a.z - b.z;\n    this.w = a.w - b.w;\n    return this;\n  }\n  multiply(v) {\n    this.x *= v.x;\n    this.y *= v.y;\n    this.z *= v.z;\n    this.w *= v.w;\n    return this;\n  }\n  multiplyScalar(scalar) {\n    this.x *= scalar;\n    this.y *= scalar;\n    this.z *= scalar;\n    this.w *= scalar;\n    return this;\n  }\n  applyMatrix4(m) {\n    const x = this.x,\n      y = this.y,\n      z = this.z,\n      w = this.w;\n    const e = m.elements;\n    this.x = e[0] * x + e[4] * y + e[8] * z + e[12] * w;\n    this.y = e[1] * x + e[5] * y + e[9] * z + e[13] * w;\n    this.z = e[2] * x + e[6] * y + e[10] * z + e[14] * w;\n    this.w = e[3] * x + e[7] * y + e[11] * z + e[15] * w;\n    return this;\n  }\n  divideScalar(scalar) {\n    return this.multiplyScalar(1 / scalar);\n  }\n  setAxisAngleFromQuaternion(q) {\n    // http://www.euclideanspace.com/maths/geometry/rotations/conversions/quaternionToAngle/index.htm\n\n    // q is assumed to be normalized\n\n    this.w = 2 * Math.acos(q.w);\n    const s = Math.sqrt(1 - q.w * q.w);\n    if (s < 0.0001) {\n      this.x = 1;\n      this.y = 0;\n      this.z = 0;\n    } else {\n      this.x = q.x / s;\n      this.y = q.y / s;\n      this.z = q.z / s;\n    }\n    return this;\n  }\n  setAxisAngleFromRotationMatrix(m) {\n    // http://www.euclideanspace.com/maths/geometry/rotations/conversions/matrixToAngle/index.htm\n\n    // assumes the upper 3x3 of m is a pure rotation matrix (i.e, unscaled)\n\n    let angle, x, y, z; // variables for result\n    const epsilon = 0.01,\n      // margin to allow for rounding errors\n      epsilon2 = 0.1,\n      // margin to distinguish between 0 and 180 degrees\n\n      te = m.elements,\n      m11 = te[0],\n      m12 = te[4],\n      m13 = te[8],\n      m21 = te[1],\n      m22 = te[5],\n      m23 = te[9],\n      m31 = te[2],\n      m32 = te[6],\n      m33 = te[10];\n    if (Math.abs(m12 - m21) < epsilon && Math.abs(m13 - m31) < epsilon && Math.abs(m23 - m32) < epsilon) {\n      // singularity found\n      // first check for identity matrix which must have +1 for all terms\n      // in leading diagonal and zero in other terms\n\n      if (Math.abs(m12 + m21) < epsilon2 && Math.abs(m13 + m31) < epsilon2 && Math.abs(m23 + m32) < epsilon2 && Math.abs(m11 + m22 + m33 - 3) < epsilon2) {\n        // this singularity is identity matrix so angle = 0\n\n        this.set(1, 0, 0, 0);\n        return this; // zero angle, arbitrary axis\n      }\n\n      // otherwise this singularity is angle = 180\n\n      angle = Math.PI;\n      const xx = (m11 + 1) / 2;\n      const yy = (m22 + 1) / 2;\n      const zz = (m33 + 1) / 2;\n      const xy = (m12 + m21) / 4;\n      const xz = (m13 + m31) / 4;\n      const yz = (m23 + m32) / 4;\n      if (xx > yy && xx > zz) {\n        // m11 is the largest diagonal term\n\n        if (xx < epsilon) {\n          x = 0;\n          y = 0.707106781;\n          z = 0.707106781;\n        } else {\n          x = Math.sqrt(xx);\n          y = xy / x;\n          z = xz / x;\n        }\n      } else if (yy > zz) {\n        // m22 is the largest diagonal term\n\n        if (yy < epsilon) {\n          x = 0.707106781;\n          y = 0;\n          z = 0.707106781;\n        } else {\n          y = Math.sqrt(yy);\n          x = xy / y;\n          z = yz / y;\n        }\n      } else {\n        // m33 is the largest diagonal term so base result on this\n\n        if (zz < epsilon) {\n          x = 0.707106781;\n          y = 0.707106781;\n          z = 0;\n        } else {\n          z = Math.sqrt(zz);\n          x = xz / z;\n          y = yz / z;\n        }\n      }\n      this.set(x, y, z, angle);\n      return this; // return 180 deg rotation\n    }\n\n    // as we have reached here there are no singularities so we can handle normally\n\n    let s = Math.sqrt((m32 - m23) * (m32 - m23) + (m13 - m31) * (m13 - m31) + (m21 - m12) * (m21 - m12)); // used to normalize\n\n    if (Math.abs(s) < 0.001) s = 1;\n\n    // prevent divide by zero, should not happen if matrix is orthogonal and should be\n    // caught by singularity test above, but I've left it in just in case\n\n    this.x = (m32 - m23) / s;\n    this.y = (m13 - m31) / s;\n    this.z = (m21 - m12) / s;\n    this.w = Math.acos((m11 + m22 + m33 - 1) / 2);\n    return this;\n  }\n  min(v) {\n    this.x = Math.min(this.x, v.x);\n    this.y = Math.min(this.y, v.y);\n    this.z = Math.min(this.z, v.z);\n    this.w = Math.min(this.w, v.w);\n    return this;\n  }\n  max(v) {\n    this.x = Math.max(this.x, v.x);\n    this.y = Math.max(this.y, v.y);\n    this.z = Math.max(this.z, v.z);\n    this.w = Math.max(this.w, v.w);\n    return this;\n  }\n  clamp(min, max) {\n    // assumes min < max, componentwise\n\n    this.x = Math.max(min.x, Math.min(max.x, this.x));\n    this.y = Math.max(min.y, Math.min(max.y, this.y));\n    this.z = Math.max(min.z, Math.min(max.z, this.z));\n    this.w = Math.max(min.w, Math.min(max.w, this.w));\n    return this;\n  }\n  clampScalar(minVal, maxVal) {\n    this.x = Math.max(minVal, Math.min(maxVal, this.x));\n    this.y = Math.max(minVal, Math.min(maxVal, this.y));\n    this.z = Math.max(minVal, Math.min(maxVal, this.z));\n    this.w = Math.max(minVal, Math.min(maxVal, this.w));\n    return this;\n  }\n  clampLength(min, max) {\n    const length = this.length();\n    return this.divideScalar(length || 1).multiplyScalar(Math.max(min, Math.min(max, length)));\n  }\n  floor() {\n    this.x = Math.floor(this.x);\n    this.y = Math.floor(this.y);\n    this.z = Math.floor(this.z);\n    this.w = Math.floor(this.w);\n    return this;\n  }\n  ceil() {\n    this.x = Math.ceil(this.x);\n    this.y = Math.ceil(this.y);\n    this.z = Math.ceil(this.z);\n    this.w = Math.ceil(this.w);\n    return this;\n  }\n  round() {\n    this.x = Math.round(this.x);\n    this.y = Math.round(this.y);\n    this.z = Math.round(this.z);\n    this.w = Math.round(this.w);\n    return this;\n  }\n  roundToZero() {\n    this.x = this.x < 0 ? Math.ceil(this.x) : Math.floor(this.x);\n    this.y = this.y < 0 ? Math.ceil(this.y) : Math.floor(this.y);\n    this.z = this.z < 0 ? Math.ceil(this.z) : Math.floor(this.z);\n    this.w = this.w < 0 ? Math.ceil(this.w) : Math.floor(this.w);\n    return this;\n  }\n  negate() {\n    this.x = -this.x;\n    this.y = -this.y;\n    this.z = -this.z;\n    this.w = -this.w;\n    return this;\n  }\n  dot(v) {\n    return this.x * v.x + this.y * v.y + this.z * v.z + this.w * v.w;\n  }\n  lengthSq() {\n    return this.x * this.x + this.y * this.y + this.z * this.z + this.w * this.w;\n  }\n  length() {\n    return Math.sqrt(this.x * this.x + this.y * this.y + this.z * this.z + this.w * this.w);\n  }\n  manhattanLength() {\n    return Math.abs(this.x) + Math.abs(this.y) + Math.abs(this.z) + Math.abs(this.w);\n  }\n  normalize() {\n    return this.divideScalar(this.length() || 1);\n  }\n  setLength(length) {\n    return this.normalize().multiplyScalar(length);\n  }\n  lerp(v, alpha) {\n    this.x += (v.x - this.x) * alpha;\n    this.y += (v.y - this.y) * alpha;\n    this.z += (v.z - this.z) * alpha;\n    this.w += (v.w - this.w) * alpha;\n    return this;\n  }\n  lerpVectors(v1, v2, alpha) {\n    this.x = v1.x + (v2.x - v1.x) * alpha;\n    this.y = v1.y + (v2.y - v1.y) * alpha;\n    this.z = v1.z + (v2.z - v1.z) * alpha;\n    this.w = v1.w + (v2.w - v1.w) * alpha;\n    return this;\n  }\n  equals(v) {\n    return v.x === this.x && v.y === this.y && v.z === this.z && v.w === this.w;\n  }\n  fromArray(array, offset = 0) {\n    this.x = array[offset];\n    this.y = array[offset + 1];\n    this.z = array[offset + 2];\n    this.w = array[offset + 3];\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    array[offset] = this.x;\n    array[offset + 1] = this.y;\n    array[offset + 2] = this.z;\n    array[offset + 3] = this.w;\n    return array;\n  }\n  fromBufferAttribute(attribute, index, offset) {\n    if (offset !== undefined) {\n      console.warn('THREE.Vector4: offset has been removed from .fromBufferAttribute().');\n    }\n    this.x = attribute.getX(index);\n    this.y = attribute.getY(index);\n    this.z = attribute.getZ(index);\n    this.w = attribute.getW(index);\n    return this;\n  }\n  random() {\n    this.x = Math.random();\n    this.y = Math.random();\n    this.z = Math.random();\n    this.w = Math.random();\n    return this;\n  }\n}\n\n/*\n In options, we can specify:\n * Texture parameters for an auto-generated target texture\n * depthBuffer/stencilBuffer: Booleans to indicate if we should generate these buffers\n*/\nclass WebGLRenderTarget extends EventDispatcher {\n  constructor(width, height, options) {\n    super();\n    Object.defineProperty(this, 'isWebGLRenderTarget', {\n      value: true\n    });\n    this.width = width;\n    this.height = height;\n    this.scissor = new Vector4(0, 0, width, height);\n    this.scissorTest = false;\n    this.viewport = new Vector4(0, 0, width, height);\n    options = options || {};\n    this.texture = new Texture(undefined, options.mapping, options.wrapS, options.wrapT, options.magFilter, options.minFilter, options.format, options.type, options.anisotropy, options.encoding);\n    this.texture.image = {};\n    this.texture.image.width = width;\n    this.texture.image.height = height;\n    this.texture.generateMipmaps = options.generateMipmaps !== undefined ? options.generateMipmaps : false;\n    this.texture.minFilter = options.minFilter !== undefined ? options.minFilter : LinearFilter;\n    this.depthBuffer = options.depthBuffer !== undefined ? options.depthBuffer : true;\n    this.stencilBuffer = options.stencilBuffer !== undefined ? options.stencilBuffer : false;\n    this.depthTexture = options.depthTexture !== undefined ? options.depthTexture : null;\n  }\n  setSize(width, height) {\n    if (this.width !== width || this.height !== height) {\n      this.width = width;\n      this.height = height;\n      this.texture.image.width = width;\n      this.texture.image.height = height;\n      this.dispose();\n    }\n    this.viewport.set(0, 0, width, height);\n    this.scissor.set(0, 0, width, height);\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(source) {\n    this.width = source.width;\n    this.height = source.height;\n    this.viewport.copy(source.viewport);\n    this.texture = source.texture.clone();\n    this.depthBuffer = source.depthBuffer;\n    this.stencilBuffer = source.stencilBuffer;\n    this.depthTexture = source.depthTexture;\n    return this;\n  }\n  dispose() {\n    this.dispatchEvent({\n      type: 'dispose'\n    });\n  }\n}\nclass Quaternion {\n  constructor(x = 0, y = 0, z = 0, w = 1) {\n    Object.defineProperty(this, 'isQuaternion', {\n      value: true\n    });\n    this._x = x;\n    this._y = y;\n    this._z = z;\n    this._w = w;\n  }\n  static slerp(qa, qb, qm, t) {\n    return qm.copy(qa).slerp(qb, t);\n  }\n  static slerpFlat(dst, dstOffset, src0, srcOffset0, src1, srcOffset1, t) {\n    // fuzz-free, array-based Quaternion SLERP operation\n\n    let x0 = src0[srcOffset0 + 0],\n      y0 = src0[srcOffset0 + 1],\n      z0 = src0[srcOffset0 + 2],\n      w0 = src0[srcOffset0 + 3];\n    const x1 = src1[srcOffset1 + 0],\n      y1 = src1[srcOffset1 + 1],\n      z1 = src1[srcOffset1 + 2],\n      w1 = src1[srcOffset1 + 3];\n    if (w0 !== w1 || x0 !== x1 || y0 !== y1 || z0 !== z1) {\n      let s = 1 - t;\n      const cos = x0 * x1 + y0 * y1 + z0 * z1 + w0 * w1,\n        dir = cos >= 0 ? 1 : -1,\n        sqrSin = 1 - cos * cos;\n\n      // Skip the Slerp for tiny steps to avoid numeric problems:\n      if (sqrSin > Number.EPSILON) {\n        const sin = Math.sqrt(sqrSin),\n          len = Math.atan2(sin, cos * dir);\n        s = Math.sin(s * len) / sin;\n        t = Math.sin(t * len) / sin;\n      }\n      const tDir = t * dir;\n      x0 = x0 * s + x1 * tDir;\n      y0 = y0 * s + y1 * tDir;\n      z0 = z0 * s + z1 * tDir;\n      w0 = w0 * s + w1 * tDir;\n\n      // Normalize in case we just did a lerp:\n      if (s === 1 - t) {\n        const f = 1 / Math.sqrt(x0 * x0 + y0 * y0 + z0 * z0 + w0 * w0);\n        x0 *= f;\n        y0 *= f;\n        z0 *= f;\n        w0 *= f;\n      }\n    }\n    dst[dstOffset] = x0;\n    dst[dstOffset + 1] = y0;\n    dst[dstOffset + 2] = z0;\n    dst[dstOffset + 3] = w0;\n  }\n  static multiplyQuaternionsFlat(dst, dstOffset, src0, srcOffset0, src1, srcOffset1) {\n    const x0 = src0[srcOffset0];\n    const y0 = src0[srcOffset0 + 1];\n    const z0 = src0[srcOffset0 + 2];\n    const w0 = src0[srcOffset0 + 3];\n    const x1 = src1[srcOffset1];\n    const y1 = src1[srcOffset1 + 1];\n    const z1 = src1[srcOffset1 + 2];\n    const w1 = src1[srcOffset1 + 3];\n    dst[dstOffset] = x0 * w1 + w0 * x1 + y0 * z1 - z0 * y1;\n    dst[dstOffset + 1] = y0 * w1 + w0 * y1 + z0 * x1 - x0 * z1;\n    dst[dstOffset + 2] = z0 * w1 + w0 * z1 + x0 * y1 - y0 * x1;\n    dst[dstOffset + 3] = w0 * w1 - x0 * x1 - y0 * y1 - z0 * z1;\n    return dst;\n  }\n  get x() {\n    return this._x;\n  }\n  set x(value) {\n    this._x = value;\n    this._onChangeCallback();\n  }\n  get y() {\n    return this._y;\n  }\n  set y(value) {\n    this._y = value;\n    this._onChangeCallback();\n  }\n  get z() {\n    return this._z;\n  }\n  set z(value) {\n    this._z = value;\n    this._onChangeCallback();\n  }\n  get w() {\n    return this._w;\n  }\n  set w(value) {\n    this._w = value;\n    this._onChangeCallback();\n  }\n  set(x, y, z, w) {\n    this._x = x;\n    this._y = y;\n    this._z = z;\n    this._w = w;\n    this._onChangeCallback();\n    return this;\n  }\n  clone() {\n    return new this.constructor(this._x, this._y, this._z, this._w);\n  }\n  copy(quaternion) {\n    this._x = quaternion.x;\n    this._y = quaternion.y;\n    this._z = quaternion.z;\n    this._w = quaternion.w;\n    this._onChangeCallback();\n    return this;\n  }\n  setFromEuler(euler, update) {\n    if (!(euler && euler.isEuler)) {\n      throw new Error('THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.');\n    }\n    const x = euler._x,\n      y = euler._y,\n      z = euler._z,\n      order = euler._order;\n\n    // http://www.mathworks.com/matlabcentral/fileexchange/\n    // \t20696-function-to-convert-between-dcm-euler-angles-quaternions-and-euler-vectors/\n    //\tcontent/SpinCalc.m\n\n    const cos = Math.cos;\n    const sin = Math.sin;\n    const c1 = cos(x / 2);\n    const c2 = cos(y / 2);\n    const c3 = cos(z / 2);\n    const s1 = sin(x / 2);\n    const s2 = sin(y / 2);\n    const s3 = sin(z / 2);\n    switch (order) {\n      case 'XYZ':\n        this._x = s1 * c2 * c3 + c1 * s2 * s3;\n        this._y = c1 * s2 * c3 - s1 * c2 * s3;\n        this._z = c1 * c2 * s3 + s1 * s2 * c3;\n        this._w = c1 * c2 * c3 - s1 * s2 * s3;\n        break;\n      case 'YXZ':\n        this._x = s1 * c2 * c3 + c1 * s2 * s3;\n        this._y = c1 * s2 * c3 - s1 * c2 * s3;\n        this._z = c1 * c2 * s3 - s1 * s2 * c3;\n        this._w = c1 * c2 * c3 + s1 * s2 * s3;\n        break;\n      case 'ZXY':\n        this._x = s1 * c2 * c3 - c1 * s2 * s3;\n        this._y = c1 * s2 * c3 + s1 * c2 * s3;\n        this._z = c1 * c2 * s3 + s1 * s2 * c3;\n        this._w = c1 * c2 * c3 - s1 * s2 * s3;\n        break;\n      case 'ZYX':\n        this._x = s1 * c2 * c3 - c1 * s2 * s3;\n        this._y = c1 * s2 * c3 + s1 * c2 * s3;\n        this._z = c1 * c2 * s3 - s1 * s2 * c3;\n        this._w = c1 * c2 * c3 + s1 * s2 * s3;\n        break;\n      case 'YZX':\n        this._x = s1 * c2 * c3 + c1 * s2 * s3;\n        this._y = c1 * s2 * c3 + s1 * c2 * s3;\n        this._z = c1 * c2 * s3 - s1 * s2 * c3;\n        this._w = c1 * c2 * c3 - s1 * s2 * s3;\n        break;\n      case 'XZY':\n        this._x = s1 * c2 * c3 - c1 * s2 * s3;\n        this._y = c1 * s2 * c3 - s1 * c2 * s3;\n        this._z = c1 * c2 * s3 + s1 * s2 * c3;\n        this._w = c1 * c2 * c3 + s1 * s2 * s3;\n        break;\n      default:\n        console.warn('THREE.Quaternion: .setFromEuler() encountered an unknown order: ' + order);\n    }\n    if (update !== false) this._onChangeCallback();\n    return this;\n  }\n  setFromAxisAngle(axis, angle) {\n    // http://www.euclideanspace.com/maths/geometry/rotations/conversions/angleToQuaternion/index.htm\n\n    // assumes axis is normalized\n\n    const halfAngle = angle / 2,\n      s = Math.sin(halfAngle);\n    this._x = axis.x * s;\n    this._y = axis.y * s;\n    this._z = axis.z * s;\n    this._w = Math.cos(halfAngle);\n    this._onChangeCallback();\n    return this;\n  }\n  setFromRotationMatrix(m) {\n    // http://www.euclideanspace.com/maths/geometry/rotations/conversions/matrixToQuaternion/index.htm\n\n    // assumes the upper 3x3 of m is a pure rotation matrix (i.e, unscaled)\n\n    const te = m.elements,\n      m11 = te[0],\n      m12 = te[4],\n      m13 = te[8],\n      m21 = te[1],\n      m22 = te[5],\n      m23 = te[9],\n      m31 = te[2],\n      m32 = te[6],\n      m33 = te[10],\n      trace = m11 + m22 + m33;\n    if (trace > 0) {\n      const s = 0.5 / Math.sqrt(trace + 1.0);\n      this._w = 0.25 / s;\n      this._x = (m32 - m23) * s;\n      this._y = (m13 - m31) * s;\n      this._z = (m21 - m12) * s;\n    } else if (m11 > m22 && m11 > m33) {\n      const s = 2.0 * Math.sqrt(1.0 + m11 - m22 - m33);\n      this._w = (m32 - m23) / s;\n      this._x = 0.25 * s;\n      this._y = (m12 + m21) / s;\n      this._z = (m13 + m31) / s;\n    } else if (m22 > m33) {\n      const s = 2.0 * Math.sqrt(1.0 + m22 - m11 - m33);\n      this._w = (m13 - m31) / s;\n      this._x = (m12 + m21) / s;\n      this._y = 0.25 * s;\n      this._z = (m23 + m32) / s;\n    } else {\n      const s = 2.0 * Math.sqrt(1.0 + m33 - m11 - m22);\n      this._w = (m21 - m12) / s;\n      this._x = (m13 + m31) / s;\n      this._y = (m23 + m32) / s;\n      this._z = 0.25 * s;\n    }\n    this._onChangeCallback();\n    return this;\n  }\n  setFromUnitVectors(vFrom, vTo) {\n    // assumes direction vectors vFrom and vTo are normalized\n\n    const EPS = 0.000001;\n    let r = vFrom.dot(vTo) + 1;\n    if (r < EPS) {\n      r = 0;\n      if (Math.abs(vFrom.x) > Math.abs(vFrom.z)) {\n        this._x = -vFrom.y;\n        this._y = vFrom.x;\n        this._z = 0;\n        this._w = r;\n      } else {\n        this._x = 0;\n        this._y = -vFrom.z;\n        this._z = vFrom.y;\n        this._w = r;\n      }\n    } else {\n      // crossVectors( vFrom, vTo ); // inlined to avoid cyclic dependency on Vector3\n\n      this._x = vFrom.y * vTo.z - vFrom.z * vTo.y;\n      this._y = vFrom.z * vTo.x - vFrom.x * vTo.z;\n      this._z = vFrom.x * vTo.y - vFrom.y * vTo.x;\n      this._w = r;\n    }\n    return this.normalize();\n  }\n  angleTo(q) {\n    return 2 * Math.acos(Math.abs(MathUtils.clamp(this.dot(q), -1, 1)));\n  }\n  rotateTowards(q, step) {\n    const angle = this.angleTo(q);\n    if (angle === 0) return this;\n    const t = Math.min(1, step / angle);\n    this.slerp(q, t);\n    return this;\n  }\n  identity() {\n    return this.set(0, 0, 0, 1);\n  }\n  invert() {\n    // quaternion is assumed to have unit length\n\n    return this.conjugate();\n  }\n  conjugate() {\n    this._x *= -1;\n    this._y *= -1;\n    this._z *= -1;\n    this._onChangeCallback();\n    return this;\n  }\n  dot(v) {\n    return this._x * v._x + this._y * v._y + this._z * v._z + this._w * v._w;\n  }\n  lengthSq() {\n    return this._x * this._x + this._y * this._y + this._z * this._z + this._w * this._w;\n  }\n  length() {\n    return Math.sqrt(this._x * this._x + this._y * this._y + this._z * this._z + this._w * this._w);\n  }\n  normalize() {\n    let l = this.length();\n    if (l === 0) {\n      this._x = 0;\n      this._y = 0;\n      this._z = 0;\n      this._w = 1;\n    } else {\n      l = 1 / l;\n      this._x = this._x * l;\n      this._y = this._y * l;\n      this._z = this._z * l;\n      this._w = this._w * l;\n    }\n    this._onChangeCallback();\n    return this;\n  }\n  multiply(q, p) {\n    if (p !== undefined) {\n      console.warn('THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead.');\n      return this.multiplyQuaternions(q, p);\n    }\n    return this.multiplyQuaternions(this, q);\n  }\n  premultiply(q) {\n    return this.multiplyQuaternions(q, this);\n  }\n  multiplyQuaternions(a, b) {\n    // from http://www.euclideanspace.com/maths/algebra/realNormedAlgebra/quaternions/code/index.htm\n\n    const qax = a._x,\n      qay = a._y,\n      qaz = a._z,\n      qaw = a._w;\n    const qbx = b._x,\n      qby = b._y,\n      qbz = b._z,\n      qbw = b._w;\n    this._x = qax * qbw + qaw * qbx + qay * qbz - qaz * qby;\n    this._y = qay * qbw + qaw * qby + qaz * qbx - qax * qbz;\n    this._z = qaz * qbw + qaw * qbz + qax * qby - qay * qbx;\n    this._w = qaw * qbw - qax * qbx - qay * qby - qaz * qbz;\n    this._onChangeCallback();\n    return this;\n  }\n  slerp(qb, t) {\n    if (t === 0) return this;\n    if (t === 1) return this.copy(qb);\n    const x = this._x,\n      y = this._y,\n      z = this._z,\n      w = this._w;\n\n    // http://www.euclideanspace.com/maths/algebra/realNormedAlgebra/quaternions/slerp/\n\n    let cosHalfTheta = w * qb._w + x * qb._x + y * qb._y + z * qb._z;\n    if (cosHalfTheta < 0) {\n      this._w = -qb._w;\n      this._x = -qb._x;\n      this._y = -qb._y;\n      this._z = -qb._z;\n      cosHalfTheta = -cosHalfTheta;\n    } else {\n      this.copy(qb);\n    }\n    if (cosHalfTheta >= 1.0) {\n      this._w = w;\n      this._x = x;\n      this._y = y;\n      this._z = z;\n      return this;\n    }\n    const sqrSinHalfTheta = 1.0 - cosHalfTheta * cosHalfTheta;\n    if (sqrSinHalfTheta <= Number.EPSILON) {\n      const s = 1 - t;\n      this._w = s * w + t * this._w;\n      this._x = s * x + t * this._x;\n      this._y = s * y + t * this._y;\n      this._z = s * z + t * this._z;\n      this.normalize();\n      this._onChangeCallback();\n      return this;\n    }\n    const sinHalfTheta = Math.sqrt(sqrSinHalfTheta);\n    const halfTheta = Math.atan2(sinHalfTheta, cosHalfTheta);\n    const ratioA = Math.sin((1 - t) * halfTheta) / sinHalfTheta,\n      ratioB = Math.sin(t * halfTheta) / sinHalfTheta;\n    this._w = w * ratioA + this._w * ratioB;\n    this._x = x * ratioA + this._x * ratioB;\n    this._y = y * ratioA + this._y * ratioB;\n    this._z = z * ratioA + this._z * ratioB;\n    this._onChangeCallback();\n    return this;\n  }\n  equals(quaternion) {\n    return quaternion._x === this._x && quaternion._y === this._y && quaternion._z === this._z && quaternion._w === this._w;\n  }\n  fromArray(array, offset = 0) {\n    this._x = array[offset];\n    this._y = array[offset + 1];\n    this._z = array[offset + 2];\n    this._w = array[offset + 3];\n    this._onChangeCallback();\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    array[offset] = this._x;\n    array[offset + 1] = this._y;\n    array[offset + 2] = this._z;\n    array[offset + 3] = this._w;\n    return array;\n  }\n  fromBufferAttribute(attribute, index) {\n    this._x = attribute.getX(index);\n    this._y = attribute.getY(index);\n    this._z = attribute.getZ(index);\n    this._w = attribute.getW(index);\n    return this;\n  }\n  _onChange(callback) {\n    this._onChangeCallback = callback;\n    return this;\n  }\n  _onChangeCallback() {}\n}\nclass Vector3 {\n  constructor(x = 0, y = 0, z = 0) {\n    Object.defineProperty(this, 'isVector3', {\n      value: true\n    });\n    this.x = x;\n    this.y = y;\n    this.z = z;\n  }\n  set(x, y, z) {\n    if (z === undefined) z = this.z; // sprite.scale.set(x,y)\n\n    this.x = x;\n    this.y = y;\n    this.z = z;\n    return this;\n  }\n  setScalar(scalar) {\n    this.x = scalar;\n    this.y = scalar;\n    this.z = scalar;\n    return this;\n  }\n  setX(x) {\n    this.x = x;\n    return this;\n  }\n  setY(y) {\n    this.y = y;\n    return this;\n  }\n  setZ(z) {\n    this.z = z;\n    return this;\n  }\n  setComponent(index, value) {\n    switch (index) {\n      case 0:\n        this.x = value;\n        break;\n      case 1:\n        this.y = value;\n        break;\n      case 2:\n        this.z = value;\n        break;\n      default:\n        throw new Error('index is out of range: ' + index);\n    }\n    return this;\n  }\n  getComponent(index) {\n    switch (index) {\n      case 0:\n        return this.x;\n      case 1:\n        return this.y;\n      case 2:\n        return this.z;\n      default:\n        throw new Error('index is out of range: ' + index);\n    }\n  }\n  clone() {\n    return new this.constructor(this.x, this.y, this.z);\n  }\n  copy(v) {\n    this.x = v.x;\n    this.y = v.y;\n    this.z = v.z;\n    return this;\n  }\n  add(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');\n      return this.addVectors(v, w);\n    }\n    this.x += v.x;\n    this.y += v.y;\n    this.z += v.z;\n    return this;\n  }\n  addScalar(s) {\n    this.x += s;\n    this.y += s;\n    this.z += s;\n    return this;\n  }\n  addVectors(a, b) {\n    this.x = a.x + b.x;\n    this.y = a.y + b.y;\n    this.z = a.z + b.z;\n    return this;\n  }\n  addScaledVector(v, s) {\n    this.x += v.x * s;\n    this.y += v.y * s;\n    this.z += v.z * s;\n    return this;\n  }\n  sub(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');\n      return this.subVectors(v, w);\n    }\n    this.x -= v.x;\n    this.y -= v.y;\n    this.z -= v.z;\n    return this;\n  }\n  subScalar(s) {\n    this.x -= s;\n    this.y -= s;\n    this.z -= s;\n    return this;\n  }\n  subVectors(a, b) {\n    this.x = a.x - b.x;\n    this.y = a.y - b.y;\n    this.z = a.z - b.z;\n    return this;\n  }\n  multiply(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead.');\n      return this.multiplyVectors(v, w);\n    }\n    this.x *= v.x;\n    this.y *= v.y;\n    this.z *= v.z;\n    return this;\n  }\n  multiplyScalar(scalar) {\n    this.x *= scalar;\n    this.y *= scalar;\n    this.z *= scalar;\n    return this;\n  }\n  multiplyVectors(a, b) {\n    this.x = a.x * b.x;\n    this.y = a.y * b.y;\n    this.z = a.z * b.z;\n    return this;\n  }\n  applyEuler(euler) {\n    if (!(euler && euler.isEuler)) {\n      console.error('THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order.');\n    }\n    return this.applyQuaternion(_quaternion.setFromEuler(euler));\n  }\n  applyAxisAngle(axis, angle) {\n    return this.applyQuaternion(_quaternion.setFromAxisAngle(axis, angle));\n  }\n  applyMatrix3(m) {\n    const x = this.x,\n      y = this.y,\n      z = this.z;\n    const e = m.elements;\n    this.x = e[0] * x + e[3] * y + e[6] * z;\n    this.y = e[1] * x + e[4] * y + e[7] * z;\n    this.z = e[2] * x + e[5] * y + e[8] * z;\n    return this;\n  }\n  applyNormalMatrix(m) {\n    return this.applyMatrix3(m).normalize();\n  }\n  applyMatrix4(m) {\n    const x = this.x,\n      y = this.y,\n      z = this.z;\n    const e = m.elements;\n    const w = 1 / (e[3] * x + e[7] * y + e[11] * z + e[15]);\n    this.x = (e[0] * x + e[4] * y + e[8] * z + e[12]) * w;\n    this.y = (e[1] * x + e[5] * y + e[9] * z + e[13]) * w;\n    this.z = (e[2] * x + e[6] * y + e[10] * z + e[14]) * w;\n    return this;\n  }\n  applyQuaternion(q) {\n    const x = this.x,\n      y = this.y,\n      z = this.z;\n    const qx = q.x,\n      qy = q.y,\n      qz = q.z,\n      qw = q.w;\n\n    // calculate quat * vector\n\n    const ix = qw * x + qy * z - qz * y;\n    const iy = qw * y + qz * x - qx * z;\n    const iz = qw * z + qx * y - qy * x;\n    const iw = -qx * x - qy * y - qz * z;\n\n    // calculate result * inverse quat\n\n    this.x = ix * qw + iw * -qx + iy * -qz - iz * -qy;\n    this.y = iy * qw + iw * -qy + iz * -qx - ix * -qz;\n    this.z = iz * qw + iw * -qz + ix * -qy - iy * -qx;\n    return this;\n  }\n  project(camera) {\n    return this.applyMatrix4(camera.matrixWorldInverse).applyMatrix4(camera.projectionMatrix);\n  }\n  unproject(camera) {\n    return this.applyMatrix4(camera.projectionMatrixInverse).applyMatrix4(camera.matrixWorld);\n  }\n  transformDirection(m) {\n    // input: THREE.Matrix4 affine matrix\n    // vector interpreted as a direction\n\n    const x = this.x,\n      y = this.y,\n      z = this.z;\n    const e = m.elements;\n    this.x = e[0] * x + e[4] * y + e[8] * z;\n    this.y = e[1] * x + e[5] * y + e[9] * z;\n    this.z = e[2] * x + e[6] * y + e[10] * z;\n    return this.normalize();\n  }\n  divide(v) {\n    this.x /= v.x;\n    this.y /= v.y;\n    this.z /= v.z;\n    return this;\n  }\n  divideScalar(scalar) {\n    return this.multiplyScalar(1 / scalar);\n  }\n  min(v) {\n    this.x = Math.min(this.x, v.x);\n    this.y = Math.min(this.y, v.y);\n    this.z = Math.min(this.z, v.z);\n    return this;\n  }\n  max(v) {\n    this.x = Math.max(this.x, v.x);\n    this.y = Math.max(this.y, v.y);\n    this.z = Math.max(this.z, v.z);\n    return this;\n  }\n  clamp(min, max) {\n    // assumes min < max, componentwise\n\n    this.x = Math.max(min.x, Math.min(max.x, this.x));\n    this.y = Math.max(min.y, Math.min(max.y, this.y));\n    this.z = Math.max(min.z, Math.min(max.z, this.z));\n    return this;\n  }\n  clampScalar(minVal, maxVal) {\n    this.x = Math.max(minVal, Math.min(maxVal, this.x));\n    this.y = Math.max(minVal, Math.min(maxVal, this.y));\n    this.z = Math.max(minVal, Math.min(maxVal, this.z));\n    return this;\n  }\n  clampLength(min, max) {\n    const length = this.length();\n    return this.divideScalar(length || 1).multiplyScalar(Math.max(min, Math.min(max, length)));\n  }\n  floor() {\n    this.x = Math.floor(this.x);\n    this.y = Math.floor(this.y);\n    this.z = Math.floor(this.z);\n    return this;\n  }\n  ceil() {\n    this.x = Math.ceil(this.x);\n    this.y = Math.ceil(this.y);\n    this.z = Math.ceil(this.z);\n    return this;\n  }\n  round() {\n    this.x = Math.round(this.x);\n    this.y = Math.round(this.y);\n    this.z = Math.round(this.z);\n    return this;\n  }\n  roundToZero() {\n    this.x = this.x < 0 ? Math.ceil(this.x) : Math.floor(this.x);\n    this.y = this.y < 0 ? Math.ceil(this.y) : Math.floor(this.y);\n    this.z = this.z < 0 ? Math.ceil(this.z) : Math.floor(this.z);\n    return this;\n  }\n  negate() {\n    this.x = -this.x;\n    this.y = -this.y;\n    this.z = -this.z;\n    return this;\n  }\n  dot(v) {\n    return this.x * v.x + this.y * v.y + this.z * v.z;\n  }\n\n  // TODO lengthSquared?\n\n  lengthSq() {\n    return this.x * this.x + this.y * this.y + this.z * this.z;\n  }\n  length() {\n    return Math.sqrt(this.x * this.x + this.y * this.y + this.z * this.z);\n  }\n  manhattanLength() {\n    return Math.abs(this.x) + Math.abs(this.y) + Math.abs(this.z);\n  }\n  normalize() {\n    return this.divideScalar(this.length() || 1);\n  }\n  setLength(length) {\n    return this.normalize().multiplyScalar(length);\n  }\n  lerp(v, alpha) {\n    this.x += (v.x - this.x) * alpha;\n    this.y += (v.y - this.y) * alpha;\n    this.z += (v.z - this.z) * alpha;\n    return this;\n  }\n  lerpVectors(v1, v2, alpha) {\n    this.x = v1.x + (v2.x - v1.x) * alpha;\n    this.y = v1.y + (v2.y - v1.y) * alpha;\n    this.z = v1.z + (v2.z - v1.z) * alpha;\n    return this;\n  }\n  cross(v, w) {\n    if (w !== undefined) {\n      console.warn('THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead.');\n      return this.crossVectors(v, w);\n    }\n    return this.crossVectors(this, v);\n  }\n  crossVectors(a, b) {\n    const ax = a.x,\n      ay = a.y,\n      az = a.z;\n    const bx = b.x,\n      by = b.y,\n      bz = b.z;\n    this.x = ay * bz - az * by;\n    this.y = az * bx - ax * bz;\n    this.z = ax * by - ay * bx;\n    return this;\n  }\n  projectOnVector(v) {\n    const denominator = v.lengthSq();\n    if (denominator === 0) return this.set(0, 0, 0);\n    const scalar = v.dot(this) / denominator;\n    return this.copy(v).multiplyScalar(scalar);\n  }\n  projectOnPlane(planeNormal) {\n    _vector.copy(this).projectOnVector(planeNormal);\n    return this.sub(_vector);\n  }\n  reflect(normal) {\n    // reflect incident vector off plane orthogonal to normal\n    // normal is assumed to have unit length\n\n    return this.sub(_vector.copy(normal).multiplyScalar(2 * this.dot(normal)));\n  }\n  angleTo(v) {\n    const denominator = Math.sqrt(this.lengthSq() * v.lengthSq());\n    if (denominator === 0) return Math.PI / 2;\n    const theta = this.dot(v) / denominator;\n\n    // clamp, to handle numerical problems\n\n    return Math.acos(MathUtils.clamp(theta, -1, 1));\n  }\n  distanceTo(v) {\n    return Math.sqrt(this.distanceToSquared(v));\n  }\n  distanceToSquared(v) {\n    const dx = this.x - v.x,\n      dy = this.y - v.y,\n      dz = this.z - v.z;\n    return dx * dx + dy * dy + dz * dz;\n  }\n  manhattanDistanceTo(v) {\n    return Math.abs(this.x - v.x) + Math.abs(this.y - v.y) + Math.abs(this.z - v.z);\n  }\n  setFromSpherical(s) {\n    return this.setFromSphericalCoords(s.radius, s.phi, s.theta);\n  }\n  setFromSphericalCoords(radius, phi, theta) {\n    const sinPhiRadius = Math.sin(phi) * radius;\n    this.x = sinPhiRadius * Math.sin(theta);\n    this.y = Math.cos(phi) * radius;\n    this.z = sinPhiRadius * Math.cos(theta);\n    return this;\n  }\n  setFromCylindrical(c) {\n    return this.setFromCylindricalCoords(c.radius, c.theta, c.y);\n  }\n  setFromCylindricalCoords(radius, theta, y) {\n    this.x = radius * Math.sin(theta);\n    this.y = y;\n    this.z = radius * Math.cos(theta);\n    return this;\n  }\n  setFromMatrixPosition(m) {\n    const e = m.elements;\n    this.x = e[12];\n    this.y = e[13];\n    this.z = e[14];\n    return this;\n  }\n  setFromMatrixScale(m) {\n    const sx = this.setFromMatrixColumn(m, 0).length();\n    const sy = this.setFromMatrixColumn(m, 1).length();\n    const sz = this.setFromMatrixColumn(m, 2).length();\n    this.x = sx;\n    this.y = sy;\n    this.z = sz;\n    return this;\n  }\n  setFromMatrixColumn(m, index) {\n    return this.fromArray(m.elements, index * 4);\n  }\n  setFromMatrix3Column(m, index) {\n    return this.fromArray(m.elements, index * 3);\n  }\n  equals(v) {\n    return v.x === this.x && v.y === this.y && v.z === this.z;\n  }\n  fromArray(array, offset = 0) {\n    this.x = array[offset];\n    this.y = array[offset + 1];\n    this.z = array[offset + 2];\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    array[offset] = this.x;\n    array[offset + 1] = this.y;\n    array[offset + 2] = this.z;\n    return array;\n  }\n  fromBufferAttribute(attribute, index, offset) {\n    if (offset !== undefined) {\n      console.warn('THREE.Vector3: offset has been removed from .fromBufferAttribute().');\n    }\n    this.x = attribute.getX(index);\n    this.y = attribute.getY(index);\n    this.z = attribute.getZ(index);\n    return this;\n  }\n  random() {\n    this.x = Math.random();\n    this.y = Math.random();\n    this.z = Math.random();\n    return this;\n  }\n}\nconst _vector = /*@__PURE__*/new Vector3();\nconst _quaternion = /*@__PURE__*/new Quaternion();\nclass Box3 {\n  constructor(min, max) {\n    Object.defineProperty(this, 'isBox3', {\n      value: true\n    });\n    this.min = min !== undefined ? min : new Vector3(+Infinity, +Infinity, +Infinity);\n    this.max = max !== undefined ? max : new Vector3(-Infinity, -Infinity, -Infinity);\n  }\n  set(min, max) {\n    this.min.copy(min);\n    this.max.copy(max);\n    return this;\n  }\n  setFromArray(array) {\n    let minX = +Infinity;\n    let minY = +Infinity;\n    let minZ = +Infinity;\n    let maxX = -Infinity;\n    let maxY = -Infinity;\n    let maxZ = -Infinity;\n    for (let i = 0, l = array.length; i < l; i += 3) {\n      const x = array[i];\n      const y = array[i + 1];\n      const z = array[i + 2];\n      if (x < minX) minX = x;\n      if (y < minY) minY = y;\n      if (z < minZ) minZ = z;\n      if (x > maxX) maxX = x;\n      if (y > maxY) maxY = y;\n      if (z > maxZ) maxZ = z;\n    }\n    this.min.set(minX, minY, minZ);\n    this.max.set(maxX, maxY, maxZ);\n    return this;\n  }\n  setFromBufferAttribute(attribute) {\n    let minX = +Infinity;\n    let minY = +Infinity;\n    let minZ = +Infinity;\n    let maxX = -Infinity;\n    let maxY = -Infinity;\n    let maxZ = -Infinity;\n    for (let i = 0, l = attribute.count; i < l; i++) {\n      const x = attribute.getX(i);\n      const y = attribute.getY(i);\n      const z = attribute.getZ(i);\n      if (x < minX) minX = x;\n      if (y < minY) minY = y;\n      if (z < minZ) minZ = z;\n      if (x > maxX) maxX = x;\n      if (y > maxY) maxY = y;\n      if (z > maxZ) maxZ = z;\n    }\n    this.min.set(minX, minY, minZ);\n    this.max.set(maxX, maxY, maxZ);\n    return this;\n  }\n  setFromPoints(points) {\n    this.makeEmpty();\n    for (let i = 0, il = points.length; i < il; i++) {\n      this.expandByPoint(points[i]);\n    }\n    return this;\n  }\n  setFromCenterAndSize(center, size) {\n    const halfSize = _vector$1.copy(size).multiplyScalar(0.5);\n    this.min.copy(center).sub(halfSize);\n    this.max.copy(center).add(halfSize);\n    return this;\n  }\n  setFromObject(object) {\n    this.makeEmpty();\n    return this.expandByObject(object);\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(box) {\n    this.min.copy(box.min);\n    this.max.copy(box.max);\n    return this;\n  }\n  makeEmpty() {\n    this.min.x = this.min.y = this.min.z = +Infinity;\n    this.max.x = this.max.y = this.max.z = -Infinity;\n    return this;\n  }\n  isEmpty() {\n    // this is a more robust check for empty than ( volume <= 0 ) because volume can get positive with two negative axes\n\n    return this.max.x < this.min.x || this.max.y < this.min.y || this.max.z < this.min.z;\n  }\n  getCenter(target) {\n    if (target === undefined) {\n      console.warn('THREE.Box3: .getCenter() target is now required');\n      target = new Vector3();\n    }\n    return this.isEmpty() ? target.set(0, 0, 0) : target.addVectors(this.min, this.max).multiplyScalar(0.5);\n  }\n  getSize(target) {\n    if (target === undefined) {\n      console.warn('THREE.Box3: .getSize() target is now required');\n      target = new Vector3();\n    }\n    return this.isEmpty() ? target.set(0, 0, 0) : target.subVectors(this.max, this.min);\n  }\n  expandByPoint(point) {\n    this.min.min(point);\n    this.max.max(point);\n    return this;\n  }\n  expandByVector(vector) {\n    this.min.sub(vector);\n    this.max.add(vector);\n    return this;\n  }\n  expandByScalar(scalar) {\n    this.min.addScalar(-scalar);\n    this.max.addScalar(scalar);\n    return this;\n  }\n  expandByObject(object) {\n    // Computes the world-axis-aligned bounding box of an object (including its children),\n    // accounting for both the object's, and children's, world transforms\n\n    object.updateWorldMatrix(false, false);\n    const geometry = object.geometry;\n    if (geometry !== undefined) {\n      if (geometry.boundingBox === null) {\n        geometry.computeBoundingBox();\n      }\n      _box.copy(geometry.boundingBox);\n      _box.applyMatrix4(object.matrixWorld);\n      this.union(_box);\n    }\n    const children = object.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      this.expandByObject(children[i]);\n    }\n    return this;\n  }\n  containsPoint(point) {\n    return point.x < this.min.x || point.x > this.max.x || point.y < this.min.y || point.y > this.max.y || point.z < this.min.z || point.z > this.max.z ? false : true;\n  }\n  containsBox(box) {\n    return this.min.x <= box.min.x && box.max.x <= this.max.x && this.min.y <= box.min.y && box.max.y <= this.max.y && this.min.z <= box.min.z && box.max.z <= this.max.z;\n  }\n  getParameter(point, target) {\n    // This can potentially have a divide by zero if the box\n    // has a size dimension of 0.\n\n    if (target === undefined) {\n      console.warn('THREE.Box3: .getParameter() target is now required');\n      target = new Vector3();\n    }\n    return target.set((point.x - this.min.x) / (this.max.x - this.min.x), (point.y - this.min.y) / (this.max.y - this.min.y), (point.z - this.min.z) / (this.max.z - this.min.z));\n  }\n  intersectsBox(box) {\n    // using 6 splitting planes to rule out intersections.\n    return box.max.x < this.min.x || box.min.x > this.max.x || box.max.y < this.min.y || box.min.y > this.max.y || box.max.z < this.min.z || box.min.z > this.max.z ? false : true;\n  }\n  intersectsSphere(sphere) {\n    // Find the point on the AABB closest to the sphere center.\n    this.clampPoint(sphere.center, _vector$1);\n\n    // If that point is inside the sphere, the AABB and sphere intersect.\n    return _vector$1.distanceToSquared(sphere.center) <= sphere.radius * sphere.radius;\n  }\n  intersectsPlane(plane) {\n    // We compute the minimum and maximum dot product values. If those values\n    // are on the same side (back or front) of the plane, then there is no intersection.\n\n    let min, max;\n    if (plane.normal.x > 0) {\n      min = plane.normal.x * this.min.x;\n      max = plane.normal.x * this.max.x;\n    } else {\n      min = plane.normal.x * this.max.x;\n      max = plane.normal.x * this.min.x;\n    }\n    if (plane.normal.y > 0) {\n      min += plane.normal.y * this.min.y;\n      max += plane.normal.y * this.max.y;\n    } else {\n      min += plane.normal.y * this.max.y;\n      max += plane.normal.y * this.min.y;\n    }\n    if (plane.normal.z > 0) {\n      min += plane.normal.z * this.min.z;\n      max += plane.normal.z * this.max.z;\n    } else {\n      min += plane.normal.z * this.max.z;\n      max += plane.normal.z * this.min.z;\n    }\n    return min <= -plane.constant && max >= -plane.constant;\n  }\n  intersectsTriangle(triangle) {\n    if (this.isEmpty()) {\n      return false;\n    }\n\n    // compute box center and extents\n    this.getCenter(_center);\n    _extents.subVectors(this.max, _center);\n\n    // translate triangle to aabb origin\n    _v0.subVectors(triangle.a, _center);\n    _v1.subVectors(triangle.b, _center);\n    _v2.subVectors(triangle.c, _center);\n\n    // compute edge vectors for triangle\n    _f0.subVectors(_v1, _v0);\n    _f1.subVectors(_v2, _v1);\n    _f2.subVectors(_v0, _v2);\n\n    // test against axes that are given by cross product combinations of the edges of the triangle and the edges of the aabb\n    // make an axis testing of each of the 3 sides of the aabb against each of the 3 sides of the triangle = 9 axis of separation\n    // axis_ij = u_i x f_j (u0, u1, u2 = face normals of aabb = x,y,z axes vectors since aabb is axis aligned)\n    let axes = [0, -_f0.z, _f0.y, 0, -_f1.z, _f1.y, 0, -_f2.z, _f2.y, _f0.z, 0, -_f0.x, _f1.z, 0, -_f1.x, _f2.z, 0, -_f2.x, -_f0.y, _f0.x, 0, -_f1.y, _f1.x, 0, -_f2.y, _f2.x, 0];\n    if (!satForAxes(axes, _v0, _v1, _v2, _extents)) {\n      return false;\n    }\n\n    // test 3 face normals from the aabb\n    axes = [1, 0, 0, 0, 1, 0, 0, 0, 1];\n    if (!satForAxes(axes, _v0, _v1, _v2, _extents)) {\n      return false;\n    }\n\n    // finally testing the face normal of the triangle\n    // use already existing triangle edge vectors here\n    _triangleNormal.crossVectors(_f0, _f1);\n    axes = [_triangleNormal.x, _triangleNormal.y, _triangleNormal.z];\n    return satForAxes(axes, _v0, _v1, _v2, _extents);\n  }\n  clampPoint(point, target) {\n    if (target === undefined) {\n      console.warn('THREE.Box3: .clampPoint() target is now required');\n      target = new Vector3();\n    }\n    return target.copy(point).clamp(this.min, this.max);\n  }\n  distanceToPoint(point) {\n    const clampedPoint = _vector$1.copy(point).clamp(this.min, this.max);\n    return clampedPoint.sub(point).length();\n  }\n  getBoundingSphere(target) {\n    if (target === undefined) {\n      console.error('THREE.Box3: .getBoundingSphere() target is now required');\n      //target = new Sphere(); // removed to avoid cyclic dependency\n    }\n\n    this.getCenter(target.center);\n    target.radius = this.getSize(_vector$1).length() * 0.5;\n    return target;\n  }\n  intersect(box) {\n    this.min.max(box.min);\n    this.max.min(box.max);\n\n    // ensure that if there is no overlap, the result is fully empty, not slightly empty with non-inf/+inf values that will cause subsequence intersects to erroneously return valid values.\n    if (this.isEmpty()) this.makeEmpty();\n    return this;\n  }\n  union(box) {\n    this.min.min(box.min);\n    this.max.max(box.max);\n    return this;\n  }\n  applyMatrix4(matrix) {\n    // transform of empty box is an empty box.\n    if (this.isEmpty()) return this;\n\n    // NOTE: I am using a binary pattern to specify all 2^3 combinations below\n    _points[0].set(this.min.x, this.min.y, this.min.z).applyMatrix4(matrix); // 000\n    _points[1].set(this.min.x, this.min.y, this.max.z).applyMatrix4(matrix); // 001\n    _points[2].set(this.min.x, this.max.y, this.min.z).applyMatrix4(matrix); // 010\n    _points[3].set(this.min.x, this.max.y, this.max.z).applyMatrix4(matrix); // 011\n    _points[4].set(this.max.x, this.min.y, this.min.z).applyMatrix4(matrix); // 100\n    _points[5].set(this.max.x, this.min.y, this.max.z).applyMatrix4(matrix); // 101\n    _points[6].set(this.max.x, this.max.y, this.min.z).applyMatrix4(matrix); // 110\n    _points[7].set(this.max.x, this.max.y, this.max.z).applyMatrix4(matrix); // 111\n\n    this.setFromPoints(_points);\n    return this;\n  }\n  translate(offset) {\n    this.min.add(offset);\n    this.max.add(offset);\n    return this;\n  }\n  equals(box) {\n    return box.min.equals(this.min) && box.max.equals(this.max);\n  }\n}\nfunction satForAxes(axes, v0, v1, v2, extents) {\n  for (let i = 0, j = axes.length - 3; i <= j; i += 3) {\n    _testAxis.fromArray(axes, i);\n    // project the aabb onto the seperating axis\n    const r = extents.x * Math.abs(_testAxis.x) + extents.y * Math.abs(_testAxis.y) + extents.z * Math.abs(_testAxis.z);\n    // project all 3 vertices of the triangle onto the seperating axis\n    const p0 = v0.dot(_testAxis);\n    const p1 = v1.dot(_testAxis);\n    const p2 = v2.dot(_testAxis);\n    // actual test, basically see if either of the most extreme of the triangle points intersects r\n    if (Math.max(-Math.max(p0, p1, p2), Math.min(p0, p1, p2)) > r) {\n      // points of the projected triangle are outside the projected half-length of the aabb\n      // the axis is seperating and we can exit\n      return false;\n    }\n  }\n  return true;\n}\nconst _points = [/*@__PURE__*/new Vector3(), /*@__PURE__*/new Vector3(), /*@__PURE__*/new Vector3(), /*@__PURE__*/new Vector3(), /*@__PURE__*/new Vector3(), /*@__PURE__*/new Vector3(), /*@__PURE__*/new Vector3(), /*@__PURE__*/new Vector3()];\nconst _vector$1 = /*@__PURE__*/new Vector3();\nconst _box = /*@__PURE__*/new Box3();\n\n// triangle centered vertices\n\nconst _v0 = /*@__PURE__*/new Vector3();\nconst _v1 = /*@__PURE__*/new Vector3();\nconst _v2 = /*@__PURE__*/new Vector3();\n\n// triangle edge vectors\n\nconst _f0 = /*@__PURE__*/new Vector3();\nconst _f1 = /*@__PURE__*/new Vector3();\nconst _f2 = /*@__PURE__*/new Vector3();\nconst _center = /*@__PURE__*/new Vector3();\nconst _extents = /*@__PURE__*/new Vector3();\nconst _triangleNormal = /*@__PURE__*/new Vector3();\nconst _testAxis = /*@__PURE__*/new Vector3();\nconst _box$1 = /*@__PURE__*/new Box3();\nclass Sphere {\n  constructor(center, radius) {\n    this.center = center !== undefined ? center : new Vector3();\n    this.radius = radius !== undefined ? radius : -1;\n  }\n  set(center, radius) {\n    this.center.copy(center);\n    this.radius = radius;\n    return this;\n  }\n  setFromPoints(points, optionalCenter) {\n    const center = this.center;\n    if (optionalCenter !== undefined) {\n      center.copy(optionalCenter);\n    } else {\n      _box$1.setFromPoints(points).getCenter(center);\n    }\n    let maxRadiusSq = 0;\n    for (let i = 0, il = points.length; i < il; i++) {\n      maxRadiusSq = Math.max(maxRadiusSq, center.distanceToSquared(points[i]));\n    }\n    this.radius = Math.sqrt(maxRadiusSq);\n    return this;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(sphere) {\n    this.center.copy(sphere.center);\n    this.radius = sphere.radius;\n    return this;\n  }\n  isEmpty() {\n    return this.radius < 0;\n  }\n  makeEmpty() {\n    this.center.set(0, 0, 0);\n    this.radius = -1;\n    return this;\n  }\n  containsPoint(point) {\n    return point.distanceToSquared(this.center) <= this.radius * this.radius;\n  }\n  distanceToPoint(point) {\n    return point.distanceTo(this.center) - this.radius;\n  }\n  intersectsSphere(sphere) {\n    const radiusSum = this.radius + sphere.radius;\n    return sphere.center.distanceToSquared(this.center) <= radiusSum * radiusSum;\n  }\n  intersectsBox(box) {\n    return box.intersectsSphere(this);\n  }\n  intersectsPlane(plane) {\n    return Math.abs(plane.distanceToPoint(this.center)) <= this.radius;\n  }\n  clampPoint(point, target) {\n    const deltaLengthSq = this.center.distanceToSquared(point);\n    if (target === undefined) {\n      console.warn('THREE.Sphere: .clampPoint() target is now required');\n      target = new Vector3();\n    }\n    target.copy(point);\n    if (deltaLengthSq > this.radius * this.radius) {\n      target.sub(this.center).normalize();\n      target.multiplyScalar(this.radius).add(this.center);\n    }\n    return target;\n  }\n  getBoundingBox(target) {\n    if (target === undefined) {\n      console.warn('THREE.Sphere: .getBoundingBox() target is now required');\n      target = new Box3();\n    }\n    if (this.isEmpty()) {\n      // Empty sphere produces empty bounding box\n      target.makeEmpty();\n      return target;\n    }\n    target.set(this.center, this.center);\n    target.expandByScalar(this.radius);\n    return target;\n  }\n  applyMatrix4(matrix) {\n    this.center.applyMatrix4(matrix);\n    this.radius = this.radius * matrix.getMaxScaleOnAxis();\n    return this;\n  }\n  translate(offset) {\n    this.center.add(offset);\n    return this;\n  }\n  equals(sphere) {\n    return sphere.center.equals(this.center) && sphere.radius === this.radius;\n  }\n}\nconst _vector$2 = /*@__PURE__*/new Vector3();\nconst _segCenter = /*@__PURE__*/new Vector3();\nconst _segDir = /*@__PURE__*/new Vector3();\nconst _diff = /*@__PURE__*/new Vector3();\nconst _edge1 = /*@__PURE__*/new Vector3();\nconst _edge2 = /*@__PURE__*/new Vector3();\nconst _normal = /*@__PURE__*/new Vector3();\nclass Ray {\n  constructor(origin, direction) {\n    this.origin = origin !== undefined ? origin : new Vector3();\n    this.direction = direction !== undefined ? direction : new Vector3(0, 0, -1);\n  }\n  set(origin, direction) {\n    this.origin.copy(origin);\n    this.direction.copy(direction);\n    return this;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(ray) {\n    this.origin.copy(ray.origin);\n    this.direction.copy(ray.direction);\n    return this;\n  }\n  at(t, target) {\n    if (target === undefined) {\n      console.warn('THREE.Ray: .at() target is now required');\n      target = new Vector3();\n    }\n    return target.copy(this.direction).multiplyScalar(t).add(this.origin);\n  }\n  lookAt(v) {\n    this.direction.copy(v).sub(this.origin).normalize();\n    return this;\n  }\n  recast(t) {\n    this.origin.copy(this.at(t, _vector$2));\n    return this;\n  }\n  closestPointToPoint(point, target) {\n    if (target === undefined) {\n      console.warn('THREE.Ray: .closestPointToPoint() target is now required');\n      target = new Vector3();\n    }\n    target.subVectors(point, this.origin);\n    const directionDistance = target.dot(this.direction);\n    if (directionDistance < 0) {\n      return target.copy(this.origin);\n    }\n    return target.copy(this.direction).multiplyScalar(directionDistance).add(this.origin);\n  }\n  distanceToPoint(point) {\n    return Math.sqrt(this.distanceSqToPoint(point));\n  }\n  distanceSqToPoint(point) {\n    const directionDistance = _vector$2.subVectors(point, this.origin).dot(this.direction);\n\n    // point behind the ray\n\n    if (directionDistance < 0) {\n      return this.origin.distanceToSquared(point);\n    }\n    _vector$2.copy(this.direction).multiplyScalar(directionDistance).add(this.origin);\n    return _vector$2.distanceToSquared(point);\n  }\n  distanceSqToSegment(v0, v1, optionalPointOnRay, optionalPointOnSegment) {\n    // from http://www.geometrictools.com/GTEngine/Include/Mathematics/GteDistRaySegment.h\n    // It returns the min distance between the ray and the segment\n    // defined by v0 and v1\n    // It can also set two optional targets :\n    // - The closest point on the ray\n    // - The closest point on the segment\n\n    _segCenter.copy(v0).add(v1).multiplyScalar(0.5);\n    _segDir.copy(v1).sub(v0).normalize();\n    _diff.copy(this.origin).sub(_segCenter);\n    const segExtent = v0.distanceTo(v1) * 0.5;\n    const a01 = -this.direction.dot(_segDir);\n    const b0 = _diff.dot(this.direction);\n    const b1 = -_diff.dot(_segDir);\n    const c = _diff.lengthSq();\n    const det = Math.abs(1 - a01 * a01);\n    let s0, s1, sqrDist, extDet;\n    if (det > 0) {\n      // The ray and segment are not parallel.\n\n      s0 = a01 * b1 - b0;\n      s1 = a01 * b0 - b1;\n      extDet = segExtent * det;\n      if (s0 >= 0) {\n        if (s1 >= -extDet) {\n          if (s1 <= extDet) {\n            // region 0\n            // Minimum at interior points of ray and segment.\n\n            const invDet = 1 / det;\n            s0 *= invDet;\n            s1 *= invDet;\n            sqrDist = s0 * (s0 + a01 * s1 + 2 * b0) + s1 * (a01 * s0 + s1 + 2 * b1) + c;\n          } else {\n            // region 1\n\n            s1 = segExtent;\n            s0 = Math.max(0, -(a01 * s1 + b0));\n            sqrDist = -s0 * s0 + s1 * (s1 + 2 * b1) + c;\n          }\n        } else {\n          // region 5\n\n          s1 = -segExtent;\n          s0 = Math.max(0, -(a01 * s1 + b0));\n          sqrDist = -s0 * s0 + s1 * (s1 + 2 * b1) + c;\n        }\n      } else {\n        if (s1 <= -extDet) {\n          // region 4\n\n          s0 = Math.max(0, -(-a01 * segExtent + b0));\n          s1 = s0 > 0 ? -segExtent : Math.min(Math.max(-segExtent, -b1), segExtent);\n          sqrDist = -s0 * s0 + s1 * (s1 + 2 * b1) + c;\n        } else if (s1 <= extDet) {\n          // region 3\n\n          s0 = 0;\n          s1 = Math.min(Math.max(-segExtent, -b1), segExtent);\n          sqrDist = s1 * (s1 + 2 * b1) + c;\n        } else {\n          // region 2\n\n          s0 = Math.max(0, -(a01 * segExtent + b0));\n          s1 = s0 > 0 ? segExtent : Math.min(Math.max(-segExtent, -b1), segExtent);\n          sqrDist = -s0 * s0 + s1 * (s1 + 2 * b1) + c;\n        }\n      }\n    } else {\n      // Ray and segment are parallel.\n\n      s1 = a01 > 0 ? -segExtent : segExtent;\n      s0 = Math.max(0, -(a01 * s1 + b0));\n      sqrDist = -s0 * s0 + s1 * (s1 + 2 * b1) + c;\n    }\n    if (optionalPointOnRay) {\n      optionalPointOnRay.copy(this.direction).multiplyScalar(s0).add(this.origin);\n    }\n    if (optionalPointOnSegment) {\n      optionalPointOnSegment.copy(_segDir).multiplyScalar(s1).add(_segCenter);\n    }\n    return sqrDist;\n  }\n  intersectSphere(sphere, target) {\n    _vector$2.subVectors(sphere.center, this.origin);\n    const tca = _vector$2.dot(this.direction);\n    const d2 = _vector$2.dot(_vector$2) - tca * tca;\n    const radius2 = sphere.radius * sphere.radius;\n    if (d2 > radius2) return null;\n    const thc = Math.sqrt(radius2 - d2);\n\n    // t0 = first intersect point - entrance on front of sphere\n    const t0 = tca - thc;\n\n    // t1 = second intersect point - exit point on back of sphere\n    const t1 = tca + thc;\n\n    // test to see if both t0 and t1 are behind the ray - if so, return null\n    if (t0 < 0 && t1 < 0) return null;\n\n    // test to see if t0 is behind the ray:\n    // if it is, the ray is inside the sphere, so return the second exit point scaled by t1,\n    // in order to always return an intersect point that is in front of the ray.\n    if (t0 < 0) return this.at(t1, target);\n\n    // else t0 is in front of the ray, so return the first collision point scaled by t0\n    return this.at(t0, target);\n  }\n  intersectsSphere(sphere) {\n    return this.distanceSqToPoint(sphere.center) <= sphere.radius * sphere.radius;\n  }\n  distanceToPlane(plane) {\n    const denominator = plane.normal.dot(this.direction);\n    if (denominator === 0) {\n      // line is coplanar, return origin\n      if (plane.distanceToPoint(this.origin) === 0) {\n        return 0;\n      }\n\n      // Null is preferable to undefined since undefined means.... it is undefined\n\n      return null;\n    }\n    const t = -(this.origin.dot(plane.normal) + plane.constant) / denominator;\n\n    // Return if the ray never intersects the plane\n\n    return t >= 0 ? t : null;\n  }\n  intersectPlane(plane, target) {\n    const t = this.distanceToPlane(plane);\n    if (t === null) {\n      return null;\n    }\n    return this.at(t, target);\n  }\n  intersectsPlane(plane) {\n    // check if the ray lies on the plane first\n\n    const distToPoint = plane.distanceToPoint(this.origin);\n    if (distToPoint === 0) {\n      return true;\n    }\n    const denominator = plane.normal.dot(this.direction);\n    if (denominator * distToPoint < 0) {\n      return true;\n    }\n\n    // ray origin is behind the plane (and is pointing behind it)\n\n    return false;\n  }\n  intersectBox(box, target) {\n    let tmin, tmax, tymin, tymax, tzmin, tzmax;\n    const invdirx = 1 / this.direction.x,\n      invdiry = 1 / this.direction.y,\n      invdirz = 1 / this.direction.z;\n    const origin = this.origin;\n    if (invdirx >= 0) {\n      tmin = (box.min.x - origin.x) * invdirx;\n      tmax = (box.max.x - origin.x) * invdirx;\n    } else {\n      tmin = (box.max.x - origin.x) * invdirx;\n      tmax = (box.min.x - origin.x) * invdirx;\n    }\n    if (invdiry >= 0) {\n      tymin = (box.min.y - origin.y) * invdiry;\n      tymax = (box.max.y - origin.y) * invdiry;\n    } else {\n      tymin = (box.max.y - origin.y) * invdiry;\n      tymax = (box.min.y - origin.y) * invdiry;\n    }\n    if (tmin > tymax || tymin > tmax) return null;\n\n    // These lines also handle the case where tmin or tmax is NaN\n    // (result of 0 * Infinity). x !== x returns true if x is NaN\n\n    if (tymin > tmin || tmin !== tmin) tmin = tymin;\n    if (tymax < tmax || tmax !== tmax) tmax = tymax;\n    if (invdirz >= 0) {\n      tzmin = (box.min.z - origin.z) * invdirz;\n      tzmax = (box.max.z - origin.z) * invdirz;\n    } else {\n      tzmin = (box.max.z - origin.z) * invdirz;\n      tzmax = (box.min.z - origin.z) * invdirz;\n    }\n    if (tmin > tzmax || tzmin > tmax) return null;\n    if (tzmin > tmin || tmin !== tmin) tmin = tzmin;\n    if (tzmax < tmax || tmax !== tmax) tmax = tzmax;\n\n    //return point closest to the ray (positive side)\n\n    if (tmax < 0) return null;\n    return this.at(tmin >= 0 ? tmin : tmax, target);\n  }\n  intersectsBox(box) {\n    return this.intersectBox(box, _vector$2) !== null;\n  }\n  intersectTriangle(a, b, c, backfaceCulling, target) {\n    // Compute the offset origin, edges, and normal.\n\n    // from http://www.geometrictools.com/GTEngine/Include/Mathematics/GteIntrRay3Triangle3.h\n\n    _edge1.subVectors(b, a);\n    _edge2.subVectors(c, a);\n    _normal.crossVectors(_edge1, _edge2);\n\n    // Solve Q + t*D = b1*E1 + b2*E2 (Q = kDiff, D = ray direction,\n    // E1 = kEdge1, E2 = kEdge2, N = Cross(E1,E2)) by\n    //   |Dot(D,N)|*b1 = sign(Dot(D,N))*Dot(D,Cross(Q,E2))\n    //   |Dot(D,N)|*b2 = sign(Dot(D,N))*Dot(D,Cross(E1,Q))\n    //   |Dot(D,N)|*t = -sign(Dot(D,N))*Dot(Q,N)\n    let DdN = this.direction.dot(_normal);\n    let sign;\n    if (DdN > 0) {\n      if (backfaceCulling) return null;\n      sign = 1;\n    } else if (DdN < 0) {\n      sign = -1;\n      DdN = -DdN;\n    } else {\n      return null;\n    }\n    _diff.subVectors(this.origin, a);\n    const DdQxE2 = sign * this.direction.dot(_edge2.crossVectors(_diff, _edge2));\n\n    // b1 < 0, no intersection\n    if (DdQxE2 < 0) {\n      return null;\n    }\n    const DdE1xQ = sign * this.direction.dot(_edge1.cross(_diff));\n\n    // b2 < 0, no intersection\n    if (DdE1xQ < 0) {\n      return null;\n    }\n\n    // b1+b2 > 1, no intersection\n    if (DdQxE2 + DdE1xQ > DdN) {\n      return null;\n    }\n\n    // Line intersects triangle, check if ray does.\n    const QdN = -sign * _diff.dot(_normal);\n\n    // t < 0, no intersection\n    if (QdN < 0) {\n      return null;\n    }\n\n    // Ray intersects triangle.\n    return this.at(QdN / DdN, target);\n  }\n  applyMatrix4(matrix4) {\n    this.origin.applyMatrix4(matrix4);\n    this.direction.transformDirection(matrix4);\n    return this;\n  }\n  equals(ray) {\n    return ray.origin.equals(this.origin) && ray.direction.equals(this.direction);\n  }\n}\nclass Matrix4 {\n  constructor() {\n    Object.defineProperty(this, 'isMatrix4', {\n      value: true\n    });\n    this.elements = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1];\n    if (arguments.length > 0) {\n      console.error('THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.');\n    }\n  }\n  set(n11, n12, n13, n14, n21, n22, n23, n24, n31, n32, n33, n34, n41, n42, n43, n44) {\n    const te = this.elements;\n    te[0] = n11;\n    te[4] = n12;\n    te[8] = n13;\n    te[12] = n14;\n    te[1] = n21;\n    te[5] = n22;\n    te[9] = n23;\n    te[13] = n24;\n    te[2] = n31;\n    te[6] = n32;\n    te[10] = n33;\n    te[14] = n34;\n    te[3] = n41;\n    te[7] = n42;\n    te[11] = n43;\n    te[15] = n44;\n    return this;\n  }\n  identity() {\n    this.set(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n    return this;\n  }\n  clone() {\n    return new Matrix4().fromArray(this.elements);\n  }\n  copy(m) {\n    const te = this.elements;\n    const me = m.elements;\n    te[0] = me[0];\n    te[1] = me[1];\n    te[2] = me[2];\n    te[3] = me[3];\n    te[4] = me[4];\n    te[5] = me[5];\n    te[6] = me[6];\n    te[7] = me[7];\n    te[8] = me[8];\n    te[9] = me[9];\n    te[10] = me[10];\n    te[11] = me[11];\n    te[12] = me[12];\n    te[13] = me[13];\n    te[14] = me[14];\n    te[15] = me[15];\n    return this;\n  }\n  copyPosition(m) {\n    const te = this.elements,\n      me = m.elements;\n    te[12] = me[12];\n    te[13] = me[13];\n    te[14] = me[14];\n    return this;\n  }\n  setFromMatrix3(m) {\n    const me = m.elements;\n    this.set(me[0], me[3], me[6], 0, me[1], me[4], me[7], 0, me[2], me[5], me[8], 0, 0, 0, 0, 1);\n    return this;\n  }\n  extractBasis(xAxis, yAxis, zAxis) {\n    xAxis.setFromMatrixColumn(this, 0);\n    yAxis.setFromMatrixColumn(this, 1);\n    zAxis.setFromMatrixColumn(this, 2);\n    return this;\n  }\n  makeBasis(xAxis, yAxis, zAxis) {\n    this.set(xAxis.x, yAxis.x, zAxis.x, 0, xAxis.y, yAxis.y, zAxis.y, 0, xAxis.z, yAxis.z, zAxis.z, 0, 0, 0, 0, 1);\n    return this;\n  }\n  extractRotation(m) {\n    // this method does not support reflection matrices\n\n    const te = this.elements;\n    const me = m.elements;\n    const scaleX = 1 / _v1$1.setFromMatrixColumn(m, 0).length();\n    const scaleY = 1 / _v1$1.setFromMatrixColumn(m, 1).length();\n    const scaleZ = 1 / _v1$1.setFromMatrixColumn(m, 2).length();\n    te[0] = me[0] * scaleX;\n    te[1] = me[1] * scaleX;\n    te[2] = me[2] * scaleX;\n    te[3] = 0;\n    te[4] = me[4] * scaleY;\n    te[5] = me[5] * scaleY;\n    te[6] = me[6] * scaleY;\n    te[7] = 0;\n    te[8] = me[8] * scaleZ;\n    te[9] = me[9] * scaleZ;\n    te[10] = me[10] * scaleZ;\n    te[11] = 0;\n    te[12] = 0;\n    te[13] = 0;\n    te[14] = 0;\n    te[15] = 1;\n    return this;\n  }\n  makeRotationFromEuler(euler) {\n    if (!(euler && euler.isEuler)) {\n      console.error('THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.');\n    }\n    const te = this.elements;\n    const x = euler.x,\n      y = euler.y,\n      z = euler.z;\n    const a = Math.cos(x),\n      b = Math.sin(x);\n    const c = Math.cos(y),\n      d = Math.sin(y);\n    const e = Math.cos(z),\n      f = Math.sin(z);\n    if (euler.order === 'XYZ') {\n      const ae = a * e,\n        af = a * f,\n        be = b * e,\n        bf = b * f;\n      te[0] = c * e;\n      te[4] = -c * f;\n      te[8] = d;\n      te[1] = af + be * d;\n      te[5] = ae - bf * d;\n      te[9] = -b * c;\n      te[2] = bf - ae * d;\n      te[6] = be + af * d;\n      te[10] = a * c;\n    } else if (euler.order === 'YXZ') {\n      const ce = c * e,\n        cf = c * f,\n        de = d * e,\n        df = d * f;\n      te[0] = ce + df * b;\n      te[4] = de * b - cf;\n      te[8] = a * d;\n      te[1] = a * f;\n      te[5] = a * e;\n      te[9] = -b;\n      te[2] = cf * b - de;\n      te[6] = df + ce * b;\n      te[10] = a * c;\n    } else if (euler.order === 'ZXY') {\n      const ce = c * e,\n        cf = c * f,\n        de = d * e,\n        df = d * f;\n      te[0] = ce - df * b;\n      te[4] = -a * f;\n      te[8] = de + cf * b;\n      te[1] = cf + de * b;\n      te[5] = a * e;\n      te[9] = df - ce * b;\n      te[2] = -a * d;\n      te[6] = b;\n      te[10] = a * c;\n    } else if (euler.order === 'ZYX') {\n      const ae = a * e,\n        af = a * f,\n        be = b * e,\n        bf = b * f;\n      te[0] = c * e;\n      te[4] = be * d - af;\n      te[8] = ae * d + bf;\n      te[1] = c * f;\n      te[5] = bf * d + ae;\n      te[9] = af * d - be;\n      te[2] = -d;\n      te[6] = b * c;\n      te[10] = a * c;\n    } else if (euler.order === 'YZX') {\n      const ac = a * c,\n        ad = a * d,\n        bc = b * c,\n        bd = b * d;\n      te[0] = c * e;\n      te[4] = bd - ac * f;\n      te[8] = bc * f + ad;\n      te[1] = f;\n      te[5] = a * e;\n      te[9] = -b * e;\n      te[2] = -d * e;\n      te[6] = ad * f + bc;\n      te[10] = ac - bd * f;\n    } else if (euler.order === 'XZY') {\n      const ac = a * c,\n        ad = a * d,\n        bc = b * c,\n        bd = b * d;\n      te[0] = c * e;\n      te[4] = -f;\n      te[8] = d * e;\n      te[1] = ac * f + bd;\n      te[5] = a * e;\n      te[9] = ad * f - bc;\n      te[2] = bc * f - ad;\n      te[6] = b * e;\n      te[10] = bd * f + ac;\n    }\n\n    // bottom row\n    te[3] = 0;\n    te[7] = 0;\n    te[11] = 0;\n\n    // last column\n    te[12] = 0;\n    te[13] = 0;\n    te[14] = 0;\n    te[15] = 1;\n    return this;\n  }\n  makeRotationFromQuaternion(q) {\n    return this.compose(_zero, q, _one);\n  }\n  lookAt(eye, target, up) {\n    const te = this.elements;\n    _z.subVectors(eye, target);\n    if (_z.lengthSq() === 0) {\n      // eye and target are in the same position\n\n      _z.z = 1;\n    }\n    _z.normalize();\n    _x.crossVectors(up, _z);\n    if (_x.lengthSq() === 0) {\n      // up and z are parallel\n\n      if (Math.abs(up.z) === 1) {\n        _z.x += 0.0001;\n      } else {\n        _z.z += 0.0001;\n      }\n      _z.normalize();\n      _x.crossVectors(up, _z);\n    }\n    _x.normalize();\n    _y.crossVectors(_z, _x);\n    te[0] = _x.x;\n    te[4] = _y.x;\n    te[8] = _z.x;\n    te[1] = _x.y;\n    te[5] = _y.y;\n    te[9] = _z.y;\n    te[2] = _x.z;\n    te[6] = _y.z;\n    te[10] = _z.z;\n    return this;\n  }\n  multiply(m, n) {\n    if (n !== undefined) {\n      console.warn('THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead.');\n      return this.multiplyMatrices(m, n);\n    }\n    return this.multiplyMatrices(this, m);\n  }\n  premultiply(m) {\n    return this.multiplyMatrices(m, this);\n  }\n  multiplyMatrices(a, b) {\n    const ae = a.elements;\n    const be = b.elements;\n    const te = this.elements;\n    const a11 = ae[0],\n      a12 = ae[4],\n      a13 = ae[8],\n      a14 = ae[12];\n    const a21 = ae[1],\n      a22 = ae[5],\n      a23 = ae[9],\n      a24 = ae[13];\n    const a31 = ae[2],\n      a32 = ae[6],\n      a33 = ae[10],\n      a34 = ae[14];\n    const a41 = ae[3],\n      a42 = ae[7],\n      a43 = ae[11],\n      a44 = ae[15];\n    const b11 = be[0],\n      b12 = be[4],\n      b13 = be[8],\n      b14 = be[12];\n    const b21 = be[1],\n      b22 = be[5],\n      b23 = be[9],\n      b24 = be[13];\n    const b31 = be[2],\n      b32 = be[6],\n      b33 = be[10],\n      b34 = be[14];\n    const b41 = be[3],\n      b42 = be[7],\n      b43 = be[11],\n      b44 = be[15];\n    te[0] = a11 * b11 + a12 * b21 + a13 * b31 + a14 * b41;\n    te[4] = a11 * b12 + a12 * b22 + a13 * b32 + a14 * b42;\n    te[8] = a11 * b13 + a12 * b23 + a13 * b33 + a14 * b43;\n    te[12] = a11 * b14 + a12 * b24 + a13 * b34 + a14 * b44;\n    te[1] = a21 * b11 + a22 * b21 + a23 * b31 + a24 * b41;\n    te[5] = a21 * b12 + a22 * b22 + a23 * b32 + a24 * b42;\n    te[9] = a21 * b13 + a22 * b23 + a23 * b33 + a24 * b43;\n    te[13] = a21 * b14 + a22 * b24 + a23 * b34 + a24 * b44;\n    te[2] = a31 * b11 + a32 * b21 + a33 * b31 + a34 * b41;\n    te[6] = a31 * b12 + a32 * b22 + a33 * b32 + a34 * b42;\n    te[10] = a31 * b13 + a32 * b23 + a33 * b33 + a34 * b43;\n    te[14] = a31 * b14 + a32 * b24 + a33 * b34 + a34 * b44;\n    te[3] = a41 * b11 + a42 * b21 + a43 * b31 + a44 * b41;\n    te[7] = a41 * b12 + a42 * b22 + a43 * b32 + a44 * b42;\n    te[11] = a41 * b13 + a42 * b23 + a43 * b33 + a44 * b43;\n    te[15] = a41 * b14 + a42 * b24 + a43 * b34 + a44 * b44;\n    return this;\n  }\n  multiplyScalar(s) {\n    const te = this.elements;\n    te[0] *= s;\n    te[4] *= s;\n    te[8] *= s;\n    te[12] *= s;\n    te[1] *= s;\n    te[5] *= s;\n    te[9] *= s;\n    te[13] *= s;\n    te[2] *= s;\n    te[6] *= s;\n    te[10] *= s;\n    te[14] *= s;\n    te[3] *= s;\n    te[7] *= s;\n    te[11] *= s;\n    te[15] *= s;\n    return this;\n  }\n  determinant() {\n    const te = this.elements;\n    const n11 = te[0],\n      n12 = te[4],\n      n13 = te[8],\n      n14 = te[12];\n    const n21 = te[1],\n      n22 = te[5],\n      n23 = te[9],\n      n24 = te[13];\n    const n31 = te[2],\n      n32 = te[6],\n      n33 = te[10],\n      n34 = te[14];\n    const n41 = te[3],\n      n42 = te[7],\n      n43 = te[11],\n      n44 = te[15];\n\n    //TODO: make this more efficient\n    //( based on http://www.euclideanspace.com/maths/algebra/matrix/functions/inverse/fourD/index.htm )\n\n    return n41 * (+n14 * n23 * n32 - n13 * n24 * n32 - n14 * n22 * n33 + n12 * n24 * n33 + n13 * n22 * n34 - n12 * n23 * n34) + n42 * (+n11 * n23 * n34 - n11 * n24 * n33 + n14 * n21 * n33 - n13 * n21 * n34 + n13 * n24 * n31 - n14 * n23 * n31) + n43 * (+n11 * n24 * n32 - n11 * n22 * n34 - n14 * n21 * n32 + n12 * n21 * n34 + n14 * n22 * n31 - n12 * n24 * n31) + n44 * (-n13 * n22 * n31 - n11 * n23 * n32 + n11 * n22 * n33 + n13 * n21 * n32 - n12 * n21 * n33 + n12 * n23 * n31);\n  }\n  transpose() {\n    const te = this.elements;\n    let tmp;\n    tmp = te[1];\n    te[1] = te[4];\n    te[4] = tmp;\n    tmp = te[2];\n    te[2] = te[8];\n    te[8] = tmp;\n    tmp = te[6];\n    te[6] = te[9];\n    te[9] = tmp;\n    tmp = te[3];\n    te[3] = te[12];\n    te[12] = tmp;\n    tmp = te[7];\n    te[7] = te[13];\n    te[13] = tmp;\n    tmp = te[11];\n    te[11] = te[14];\n    te[14] = tmp;\n    return this;\n  }\n  setPosition(x, y, z) {\n    const te = this.elements;\n    if (x.isVector3) {\n      te[12] = x.x;\n      te[13] = x.y;\n      te[14] = x.z;\n    } else {\n      te[12] = x;\n      te[13] = y;\n      te[14] = z;\n    }\n    return this;\n  }\n  invert() {\n    // based on http://www.euclideanspace.com/maths/algebra/matrix/functions/inverse/fourD/index.htm\n    const te = this.elements,\n      n11 = te[0],\n      n21 = te[1],\n      n31 = te[2],\n      n41 = te[3],\n      n12 = te[4],\n      n22 = te[5],\n      n32 = te[6],\n      n42 = te[7],\n      n13 = te[8],\n      n23 = te[9],\n      n33 = te[10],\n      n43 = te[11],\n      n14 = te[12],\n      n24 = te[13],\n      n34 = te[14],\n      n44 = te[15],\n      t11 = n23 * n34 * n42 - n24 * n33 * n42 + n24 * n32 * n43 - n22 * n34 * n43 - n23 * n32 * n44 + n22 * n33 * n44,\n      t12 = n14 * n33 * n42 - n13 * n34 * n42 - n14 * n32 * n43 + n12 * n34 * n43 + n13 * n32 * n44 - n12 * n33 * n44,\n      t13 = n13 * n24 * n42 - n14 * n23 * n42 + n14 * n22 * n43 - n12 * n24 * n43 - n13 * n22 * n44 + n12 * n23 * n44,\n      t14 = n14 * n23 * n32 - n13 * n24 * n32 - n14 * n22 * n33 + n12 * n24 * n33 + n13 * n22 * n34 - n12 * n23 * n34;\n    const det = n11 * t11 + n21 * t12 + n31 * t13 + n41 * t14;\n    if (det === 0) return this.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);\n    const detInv = 1 / det;\n    te[0] = t11 * detInv;\n    te[1] = (n24 * n33 * n41 - n23 * n34 * n41 - n24 * n31 * n43 + n21 * n34 * n43 + n23 * n31 * n44 - n21 * n33 * n44) * detInv;\n    te[2] = (n22 * n34 * n41 - n24 * n32 * n41 + n24 * n31 * n42 - n21 * n34 * n42 - n22 * n31 * n44 + n21 * n32 * n44) * detInv;\n    te[3] = (n23 * n32 * n41 - n22 * n33 * n41 - n23 * n31 * n42 + n21 * n33 * n42 + n22 * n31 * n43 - n21 * n32 * n43) * detInv;\n    te[4] = t12 * detInv;\n    te[5] = (n13 * n34 * n41 - n14 * n33 * n41 + n14 * n31 * n43 - n11 * n34 * n43 - n13 * n31 * n44 + n11 * n33 * n44) * detInv;\n    te[6] = (n14 * n32 * n41 - n12 * n34 * n41 - n14 * n31 * n42 + n11 * n34 * n42 + n12 * n31 * n44 - n11 * n32 * n44) * detInv;\n    te[7] = (n12 * n33 * n41 - n13 * n32 * n41 + n13 * n31 * n42 - n11 * n33 * n42 - n12 * n31 * n43 + n11 * n32 * n43) * detInv;\n    te[8] = t13 * detInv;\n    te[9] = (n14 * n23 * n41 - n13 * n24 * n41 - n14 * n21 * n43 + n11 * n24 * n43 + n13 * n21 * n44 - n11 * n23 * n44) * detInv;\n    te[10] = (n12 * n24 * n41 - n14 * n22 * n41 + n14 * n21 * n42 - n11 * n24 * n42 - n12 * n21 * n44 + n11 * n22 * n44) * detInv;\n    te[11] = (n13 * n22 * n41 - n12 * n23 * n41 - n13 * n21 * n42 + n11 * n23 * n42 + n12 * n21 * n43 - n11 * n22 * n43) * detInv;\n    te[12] = t14 * detInv;\n    te[13] = (n13 * n24 * n31 - n14 * n23 * n31 + n14 * n21 * n33 - n11 * n24 * n33 - n13 * n21 * n34 + n11 * n23 * n34) * detInv;\n    te[14] = (n14 * n22 * n31 - n12 * n24 * n31 - n14 * n21 * n32 + n11 * n24 * n32 + n12 * n21 * n34 - n11 * n22 * n34) * detInv;\n    te[15] = (n12 * n23 * n31 - n13 * n22 * n31 + n13 * n21 * n32 - n11 * n23 * n32 - n12 * n21 * n33 + n11 * n22 * n33) * detInv;\n    return this;\n  }\n  scale(v) {\n    const te = this.elements;\n    const x = v.x,\n      y = v.y,\n      z = v.z;\n    te[0] *= x;\n    te[4] *= y;\n    te[8] *= z;\n    te[1] *= x;\n    te[5] *= y;\n    te[9] *= z;\n    te[2] *= x;\n    te[6] *= y;\n    te[10] *= z;\n    te[3] *= x;\n    te[7] *= y;\n    te[11] *= z;\n    return this;\n  }\n  getMaxScaleOnAxis() {\n    const te = this.elements;\n    const scaleXSq = te[0] * te[0] + te[1] * te[1] + te[2] * te[2];\n    const scaleYSq = te[4] * te[4] + te[5] * te[5] + te[6] * te[6];\n    const scaleZSq = te[8] * te[8] + te[9] * te[9] + te[10] * te[10];\n    return Math.sqrt(Math.max(scaleXSq, scaleYSq, scaleZSq));\n  }\n  makeTranslation(x, y, z) {\n    this.set(1, 0, 0, x, 0, 1, 0, y, 0, 0, 1, z, 0, 0, 0, 1);\n    return this;\n  }\n  makeRotationX(theta) {\n    const c = Math.cos(theta),\n      s = Math.sin(theta);\n    this.set(1, 0, 0, 0, 0, c, -s, 0, 0, s, c, 0, 0, 0, 0, 1);\n    return this;\n  }\n  makeRotationY(theta) {\n    const c = Math.cos(theta),\n      s = Math.sin(theta);\n    this.set(c, 0, s, 0, 0, 1, 0, 0, -s, 0, c, 0, 0, 0, 0, 1);\n    return this;\n  }\n  makeRotationZ(theta) {\n    const c = Math.cos(theta),\n      s = Math.sin(theta);\n    this.set(c, -s, 0, 0, s, c, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n    return this;\n  }\n  makeRotationAxis(axis, angle) {\n    // Based on http://www.gamedev.net/reference/articles/article1199.asp\n\n    const c = Math.cos(angle);\n    const s = Math.sin(angle);\n    const t = 1 - c;\n    const x = axis.x,\n      y = axis.y,\n      z = axis.z;\n    const tx = t * x,\n      ty = t * y;\n    this.set(tx * x + c, tx * y - s * z, tx * z + s * y, 0, tx * y + s * z, ty * y + c, ty * z - s * x, 0, tx * z - s * y, ty * z + s * x, t * z * z + c, 0, 0, 0, 0, 1);\n    return this;\n  }\n  makeScale(x, y, z) {\n    this.set(x, 0, 0, 0, 0, y, 0, 0, 0, 0, z, 0, 0, 0, 0, 1);\n    return this;\n  }\n  makeShear(x, y, z) {\n    this.set(1, y, z, 0, x, 1, z, 0, x, y, 1, 0, 0, 0, 0, 1);\n    return this;\n  }\n  compose(position, quaternion, scale) {\n    const te = this.elements;\n    const x = quaternion._x,\n      y = quaternion._y,\n      z = quaternion._z,\n      w = quaternion._w;\n    const x2 = x + x,\n      y2 = y + y,\n      z2 = z + z;\n    const xx = x * x2,\n      xy = x * y2,\n      xz = x * z2;\n    const yy = y * y2,\n      yz = y * z2,\n      zz = z * z2;\n    const wx = w * x2,\n      wy = w * y2,\n      wz = w * z2;\n    const sx = scale.x,\n      sy = scale.y,\n      sz = scale.z;\n    te[0] = (1 - (yy + zz)) * sx;\n    te[1] = (xy + wz) * sx;\n    te[2] = (xz - wy) * sx;\n    te[3] = 0;\n    te[4] = (xy - wz) * sy;\n    te[5] = (1 - (xx + zz)) * sy;\n    te[6] = (yz + wx) * sy;\n    te[7] = 0;\n    te[8] = (xz + wy) * sz;\n    te[9] = (yz - wx) * sz;\n    te[10] = (1 - (xx + yy)) * sz;\n    te[11] = 0;\n    te[12] = position.x;\n    te[13] = position.y;\n    te[14] = position.z;\n    te[15] = 1;\n    return this;\n  }\n  decompose(position, quaternion, scale) {\n    const te = this.elements;\n    let sx = _v1$1.set(te[0], te[1], te[2]).length();\n    const sy = _v1$1.set(te[4], te[5], te[6]).length();\n    const sz = _v1$1.set(te[8], te[9], te[10]).length();\n\n    // if determine is negative, we need to invert one scale\n    const det = this.determinant();\n    if (det < 0) sx = -sx;\n    position.x = te[12];\n    position.y = te[13];\n    position.z = te[14];\n\n    // scale the rotation part\n    _m1.copy(this);\n    const invSX = 1 / sx;\n    const invSY = 1 / sy;\n    const invSZ = 1 / sz;\n    _m1.elements[0] *= invSX;\n    _m1.elements[1] *= invSX;\n    _m1.elements[2] *= invSX;\n    _m1.elements[4] *= invSY;\n    _m1.elements[5] *= invSY;\n    _m1.elements[6] *= invSY;\n    _m1.elements[8] *= invSZ;\n    _m1.elements[9] *= invSZ;\n    _m1.elements[10] *= invSZ;\n    quaternion.setFromRotationMatrix(_m1);\n    scale.x = sx;\n    scale.y = sy;\n    scale.z = sz;\n    return this;\n  }\n  makePerspective(left, right, top, bottom, near, far) {\n    if (far === undefined) {\n      console.warn('THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.');\n    }\n    const te = this.elements;\n    const x = 2 * near / (right - left);\n    const y = 2 * near / (top - bottom);\n    const a = (right + left) / (right - left);\n    const b = (top + bottom) / (top - bottom);\n    const c = -(far + near) / (far - near);\n    const d = -2 * far * near / (far - near);\n    te[0] = x;\n    te[4] = 0;\n    te[8] = a;\n    te[12] = 0;\n    te[1] = 0;\n    te[5] = y;\n    te[9] = b;\n    te[13] = 0;\n    te[2] = 0;\n    te[6] = 0;\n    te[10] = c;\n    te[14] = d;\n    te[3] = 0;\n    te[7] = 0;\n    te[11] = -1;\n    te[15] = 0;\n    return this;\n  }\n  makeOrthographic(left, right, top, bottom, near, far) {\n    const te = this.elements;\n    const w = 1.0 / (right - left);\n    const h = 1.0 / (top - bottom);\n    const p = 1.0 / (far - near);\n    const x = (right + left) * w;\n    const y = (top + bottom) * h;\n    const z = (far + near) * p;\n    te[0] = 2 * w;\n    te[4] = 0;\n    te[8] = 0;\n    te[12] = -x;\n    te[1] = 0;\n    te[5] = 2 * h;\n    te[9] = 0;\n    te[13] = -y;\n    te[2] = 0;\n    te[6] = 0;\n    te[10] = -2 * p;\n    te[14] = -z;\n    te[3] = 0;\n    te[7] = 0;\n    te[11] = 0;\n    te[15] = 1;\n    return this;\n  }\n  equals(matrix) {\n    const te = this.elements;\n    const me = matrix.elements;\n    for (let i = 0; i < 16; i++) {\n      if (te[i] !== me[i]) return false;\n    }\n    return true;\n  }\n  fromArray(array, offset = 0) {\n    for (let i = 0; i < 16; i++) {\n      this.elements[i] = array[i + offset];\n    }\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    const te = this.elements;\n    array[offset] = te[0];\n    array[offset + 1] = te[1];\n    array[offset + 2] = te[2];\n    array[offset + 3] = te[3];\n    array[offset + 4] = te[4];\n    array[offset + 5] = te[5];\n    array[offset + 6] = te[6];\n    array[offset + 7] = te[7];\n    array[offset + 8] = te[8];\n    array[offset + 9] = te[9];\n    array[offset + 10] = te[10];\n    array[offset + 11] = te[11];\n    array[offset + 12] = te[12];\n    array[offset + 13] = te[13];\n    array[offset + 14] = te[14];\n    array[offset + 15] = te[15];\n    return array;\n  }\n}\nconst _v1$1 = /*@__PURE__*/new Vector3();\nconst _m1 = /*@__PURE__*/new Matrix4();\nconst _zero = /*@__PURE__*/new Vector3(0, 0, 0);\nconst _one = /*@__PURE__*/new Vector3(1, 1, 1);\nconst _x = /*@__PURE__*/new Vector3();\nconst _y = /*@__PURE__*/new Vector3();\nconst _z = /*@__PURE__*/new Vector3();\nclass Euler {\n  constructor(x = 0, y = 0, z = 0, order = Euler.DefaultOrder) {\n    Object.defineProperty(this, 'isEuler', {\n      value: true\n    });\n    this._x = x;\n    this._y = y;\n    this._z = z;\n    this._order = order;\n  }\n  get x() {\n    return this._x;\n  }\n  set x(value) {\n    this._x = value;\n    this._onChangeCallback();\n  }\n  get y() {\n    return this._y;\n  }\n  set y(value) {\n    this._y = value;\n    this._onChangeCallback();\n  }\n  get z() {\n    return this._z;\n  }\n  set z(value) {\n    this._z = value;\n    this._onChangeCallback();\n  }\n  get order() {\n    return this._order;\n  }\n  set order(value) {\n    this._order = value;\n    this._onChangeCallback();\n  }\n  set(x, y, z, order) {\n    this._x = x;\n    this._y = y;\n    this._z = z;\n    this._order = order || this._order;\n    this._onChangeCallback();\n    return this;\n  }\n  clone() {\n    return new this.constructor(this._x, this._y, this._z, this._order);\n  }\n  copy(euler) {\n    this._x = euler._x;\n    this._y = euler._y;\n    this._z = euler._z;\n    this._order = euler._order;\n    this._onChangeCallback();\n    return this;\n  }\n  setFromRotationMatrix(m, order, update) {\n    const clamp = MathUtils.clamp;\n\n    // assumes the upper 3x3 of m is a pure rotation matrix (i.e, unscaled)\n\n    const te = m.elements;\n    const m11 = te[0],\n      m12 = te[4],\n      m13 = te[8];\n    const m21 = te[1],\n      m22 = te[5],\n      m23 = te[9];\n    const m31 = te[2],\n      m32 = te[6],\n      m33 = te[10];\n    order = order || this._order;\n    switch (order) {\n      case 'XYZ':\n        this._y = Math.asin(clamp(m13, -1, 1));\n        if (Math.abs(m13) < 0.9999999) {\n          this._x = Math.atan2(-m23, m33);\n          this._z = Math.atan2(-m12, m11);\n        } else {\n          this._x = Math.atan2(m32, m22);\n          this._z = 0;\n        }\n        break;\n      case 'YXZ':\n        this._x = Math.asin(-clamp(m23, -1, 1));\n        if (Math.abs(m23) < 0.9999999) {\n          this._y = Math.atan2(m13, m33);\n          this._z = Math.atan2(m21, m22);\n        } else {\n          this._y = Math.atan2(-m31, m11);\n          this._z = 0;\n        }\n        break;\n      case 'ZXY':\n        this._x = Math.asin(clamp(m32, -1, 1));\n        if (Math.abs(m32) < 0.9999999) {\n          this._y = Math.atan2(-m31, m33);\n          this._z = Math.atan2(-m12, m22);\n        } else {\n          this._y = 0;\n          this._z = Math.atan2(m21, m11);\n        }\n        break;\n      case 'ZYX':\n        this._y = Math.asin(-clamp(m31, -1, 1));\n        if (Math.abs(m31) < 0.9999999) {\n          this._x = Math.atan2(m32, m33);\n          this._z = Math.atan2(m21, m11);\n        } else {\n          this._x = 0;\n          this._z = Math.atan2(-m12, m22);\n        }\n        break;\n      case 'YZX':\n        this._z = Math.asin(clamp(m21, -1, 1));\n        if (Math.abs(m21) < 0.9999999) {\n          this._x = Math.atan2(-m23, m22);\n          this._y = Math.atan2(-m31, m11);\n        } else {\n          this._x = 0;\n          this._y = Math.atan2(m13, m33);\n        }\n        break;\n      case 'XZY':\n        this._z = Math.asin(-clamp(m12, -1, 1));\n        if (Math.abs(m12) < 0.9999999) {\n          this._x = Math.atan2(m32, m22);\n          this._y = Math.atan2(m13, m11);\n        } else {\n          this._x = Math.atan2(-m23, m33);\n          this._y = 0;\n        }\n        break;\n      default:\n        console.warn('THREE.Euler: .setFromRotationMatrix() encountered an unknown order: ' + order);\n    }\n    this._order = order;\n    if (update !== false) this._onChangeCallback();\n    return this;\n  }\n  setFromQuaternion(q, order, update) {\n    _matrix.makeRotationFromQuaternion(q);\n    return this.setFromRotationMatrix(_matrix, order, update);\n  }\n  setFromVector3(v, order) {\n    return this.set(v.x, v.y, v.z, order || this._order);\n  }\n  reorder(newOrder) {\n    // WARNING: this discards revolution information -bhouston\n\n    _quaternion$1.setFromEuler(this);\n    return this.setFromQuaternion(_quaternion$1, newOrder);\n  }\n  equals(euler) {\n    return euler._x === this._x && euler._y === this._y && euler._z === this._z && euler._order === this._order;\n  }\n  fromArray(array) {\n    this._x = array[0];\n    this._y = array[1];\n    this._z = array[2];\n    if (array[3] !== undefined) this._order = array[3];\n    this._onChangeCallback();\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    array[offset] = this._x;\n    array[offset + 1] = this._y;\n    array[offset + 2] = this._z;\n    array[offset + 3] = this._order;\n    return array;\n  }\n  toVector3(optionalResult) {\n    if (optionalResult) {\n      return optionalResult.set(this._x, this._y, this._z);\n    } else {\n      return new Vector3(this._x, this._y, this._z);\n    }\n  }\n  _onChange(callback) {\n    this._onChangeCallback = callback;\n    return this;\n  }\n  _onChangeCallback() {}\n}\nEuler.DefaultOrder = 'XYZ';\nEuler.RotationOrders = ['XYZ', 'YZX', 'ZXY', 'XZY', 'YXZ', 'ZYX'];\nconst _matrix = /*@__PURE__*/new Matrix4();\nconst _quaternion$1 = /*@__PURE__*/new Quaternion();\nclass Layers {\n  constructor() {\n    this.mask = 1 | 0;\n  }\n  set(channel) {\n    this.mask = 1 << channel | 0;\n  }\n  enable(channel) {\n    this.mask |= 1 << channel | 0;\n  }\n  enableAll() {\n    this.mask = 0xffffffff | 0;\n  }\n  toggle(channel) {\n    this.mask ^= 1 << channel | 0;\n  }\n  disable(channel) {\n    this.mask &= ~(1 << channel | 0);\n  }\n  disableAll() {\n    this.mask = 0;\n  }\n  test(layers) {\n    return (this.mask & layers.mask) !== 0;\n  }\n}\nlet _object3DId = 0;\nconst _v1$2 = new Vector3();\nconst _q1 = new Quaternion();\nconst _m1$1 = new Matrix4();\nconst _target = new Vector3();\nconst _position = new Vector3();\nconst _scale = new Vector3();\nconst _quaternion$2 = new Quaternion();\nconst _xAxis = new Vector3(1, 0, 0);\nconst _yAxis = new Vector3(0, 1, 0);\nconst _zAxis = new Vector3(0, 0, 1);\nconst _addedEvent = {\n  type: 'added'\n};\nconst _removedEvent = {\n  type: 'removed'\n};\nfunction Object3D() {\n  Object.defineProperty(this, 'id', {\n    value: _object3DId++\n  });\n  this.uuid = MathUtils.generateUUID();\n  this.name = '';\n  this.type = 'Object3D';\n  this.parent = null;\n  this.children = [];\n  this.up = Object3D.DefaultUp.clone();\n  const position = new Vector3();\n  const rotation = new Euler();\n  const quaternion = new Quaternion();\n  const scale = new Vector3(1, 1, 1);\n  function onRotationChange() {\n    quaternion.setFromEuler(rotation, false);\n  }\n  function onQuaternionChange() {\n    rotation.setFromQuaternion(quaternion, undefined, false);\n  }\n  rotation._onChange(onRotationChange);\n  quaternion._onChange(onQuaternionChange);\n  Object.defineProperties(this, {\n    position: {\n      configurable: true,\n      enumerable: true,\n      value: position\n    },\n    rotation: {\n      configurable: true,\n      enumerable: true,\n      value: rotation\n    },\n    quaternion: {\n      configurable: true,\n      enumerable: true,\n      value: quaternion\n    },\n    scale: {\n      configurable: true,\n      enumerable: true,\n      value: scale\n    },\n    modelViewMatrix: {\n      value: new Matrix4()\n    },\n    normalMatrix: {\n      value: new Matrix3()\n    }\n  });\n  this.matrix = new Matrix4();\n  this.matrixWorld = new Matrix4();\n  this.matrixAutoUpdate = Object3D.DefaultMatrixAutoUpdate;\n  this.matrixWorldNeedsUpdate = false;\n  this.layers = new Layers();\n  this.visible = true;\n  this.castShadow = false;\n  this.receiveShadow = false;\n  this.frustumCulled = true;\n  this.renderOrder = 0;\n  this.animations = [];\n  this.userData = {};\n}\nObject3D.DefaultUp = new Vector3(0, 1, 0);\nObject3D.DefaultMatrixAutoUpdate = true;\nObject3D.prototype = _extends__default['default'](Object.create(EventDispatcher.prototype), {\n  constructor: Object3D,\n  isObject3D: true,\n  onBeforeRender: function () {},\n  onAfterRender: function () {},\n  applyMatrix4: function (matrix) {\n    if (this.matrixAutoUpdate) this.updateMatrix();\n    this.matrix.premultiply(matrix);\n    this.matrix.decompose(this.position, this.quaternion, this.scale);\n  },\n  applyQuaternion: function (q) {\n    this.quaternion.premultiply(q);\n    return this;\n  },\n  setRotationFromAxisAngle: function (axis, angle) {\n    // assumes axis is normalized\n\n    this.quaternion.setFromAxisAngle(axis, angle);\n  },\n  setRotationFromEuler: function (euler) {\n    this.quaternion.setFromEuler(euler, true);\n  },\n  setRotationFromMatrix: function (m) {\n    // assumes the upper 3x3 of m is a pure rotation matrix (i.e, unscaled)\n\n    this.quaternion.setFromRotationMatrix(m);\n  },\n  setRotationFromQuaternion: function (q) {\n    // assumes q is normalized\n\n    this.quaternion.copy(q);\n  },\n  rotateOnAxis: function (axis, angle) {\n    // rotate object on axis in object space\n    // axis is assumed to be normalized\n\n    _q1.setFromAxisAngle(axis, angle);\n    this.quaternion.multiply(_q1);\n    return this;\n  },\n  rotateOnWorldAxis: function (axis, angle) {\n    // rotate object on axis in world space\n    // axis is assumed to be normalized\n    // method assumes no rotated parent\n\n    _q1.setFromAxisAngle(axis, angle);\n    this.quaternion.premultiply(_q1);\n    return this;\n  },\n  rotateX: function (angle) {\n    return this.rotateOnAxis(_xAxis, angle);\n  },\n  rotateY: function (angle) {\n    return this.rotateOnAxis(_yAxis, angle);\n  },\n  rotateZ: function (angle) {\n    return this.rotateOnAxis(_zAxis, angle);\n  },\n  translateOnAxis: function (axis, distance) {\n    // translate object by distance along axis in object space\n    // axis is assumed to be normalized\n\n    _v1$2.copy(axis).applyQuaternion(this.quaternion);\n    this.position.add(_v1$2.multiplyScalar(distance));\n    return this;\n  },\n  translateX: function (distance) {\n    return this.translateOnAxis(_xAxis, distance);\n  },\n  translateY: function (distance) {\n    return this.translateOnAxis(_yAxis, distance);\n  },\n  translateZ: function (distance) {\n    return this.translateOnAxis(_zAxis, distance);\n  },\n  localToWorld: function (vector) {\n    return vector.applyMatrix4(this.matrixWorld);\n  },\n  worldToLocal: function (vector) {\n    return vector.applyMatrix4(_m1$1.copy(this.matrixWorld).invert());\n  },\n  lookAt: function (x, y, z) {\n    // This method does not support objects having non-uniformly-scaled parent(s)\n\n    if (x.isVector3) {\n      _target.copy(x);\n    } else {\n      _target.set(x, y, z);\n    }\n    const parent = this.parent;\n    this.updateWorldMatrix(true, false);\n    _position.setFromMatrixPosition(this.matrixWorld);\n    if (this.isCamera || this.isLight) {\n      _m1$1.lookAt(_position, _target, this.up);\n    } else {\n      _m1$1.lookAt(_target, _position, this.up);\n    }\n    this.quaternion.setFromRotationMatrix(_m1$1);\n    if (parent) {\n      _m1$1.extractRotation(parent.matrixWorld);\n      _q1.setFromRotationMatrix(_m1$1);\n      this.quaternion.premultiply(_q1.invert());\n    }\n  },\n  add: function (object) {\n    if (arguments.length > 1) {\n      for (let i = 0; i < arguments.length; i++) {\n        this.add(arguments[i]);\n      }\n      return this;\n    }\n    if (object === this) {\n      console.error('THREE.Object3D.add: object can\\'t be added as a child of itself.', object);\n      return this;\n    }\n    if (object && object.isObject3D) {\n      if (object.parent !== null) {\n        object.parent.remove(object);\n      }\n      object.parent = this;\n      this.children.push(object);\n      object.dispatchEvent(_addedEvent);\n    } else {\n      console.error('THREE.Object3D.add: object not an instance of THREE.Object3D.', object);\n    }\n    return this;\n  },\n  remove: function (object) {\n    if (arguments.length > 1) {\n      for (let i = 0; i < arguments.length; i++) {\n        this.remove(arguments[i]);\n      }\n      return this;\n    }\n    const index = this.children.indexOf(object);\n    if (index !== -1) {\n      object.parent = null;\n      this.children.splice(index, 1);\n      object.dispatchEvent(_removedEvent);\n    }\n    return this;\n  },\n  clear: function () {\n    for (let i = 0; i < this.children.length; i++) {\n      const object = this.children[i];\n      object.parent = null;\n      object.dispatchEvent(_removedEvent);\n    }\n    this.children.length = 0;\n    return this;\n  },\n  attach: function (object) {\n    // adds object as a child of this, while maintaining the object's world transform\n\n    this.updateWorldMatrix(true, false);\n    _m1$1.copy(this.matrixWorld).invert();\n    if (object.parent !== null) {\n      object.parent.updateWorldMatrix(true, false);\n      _m1$1.multiply(object.parent.matrixWorld);\n    }\n    object.applyMatrix4(_m1$1);\n    object.updateWorldMatrix(false, false);\n    this.add(object);\n    return this;\n  },\n  getObjectById: function (id) {\n    return this.getObjectByProperty('id', id);\n  },\n  getObjectByName: function (name) {\n    return this.getObjectByProperty('name', name);\n  },\n  getObjectByProperty: function (name, value) {\n    if (this[name] === value) return this;\n    for (let i = 0, l = this.children.length; i < l; i++) {\n      const child = this.children[i];\n      const object = child.getObjectByProperty(name, value);\n      if (object !== undefined) {\n        return object;\n      }\n    }\n    return undefined;\n  },\n  getWorldPosition: function (target) {\n    if (target === undefined) {\n      console.warn('THREE.Object3D: .getWorldPosition() target is now required');\n      target = new Vector3();\n    }\n    this.updateWorldMatrix(true, false);\n    return target.setFromMatrixPosition(this.matrixWorld);\n  },\n  getWorldQuaternion: function (target) {\n    if (target === undefined) {\n      console.warn('THREE.Object3D: .getWorldQuaternion() target is now required');\n      target = new Quaternion();\n    }\n    this.updateWorldMatrix(true, false);\n    this.matrixWorld.decompose(_position, target, _scale);\n    return target;\n  },\n  getWorldScale: function (target) {\n    if (target === undefined) {\n      console.warn('THREE.Object3D: .getWorldScale() target is now required');\n      target = new Vector3();\n    }\n    this.updateWorldMatrix(true, false);\n    this.matrixWorld.decompose(_position, _quaternion$2, target);\n    return target;\n  },\n  getWorldDirection: function (target) {\n    if (target === undefined) {\n      console.warn('THREE.Object3D: .getWorldDirection() target is now required');\n      target = new Vector3();\n    }\n    this.updateWorldMatrix(true, false);\n    const e = this.matrixWorld.elements;\n    return target.set(e[8], e[9], e[10]).normalize();\n  },\n  raycast: function () {},\n  traverse: function (callback) {\n    callback(this);\n    const children = this.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      children[i].traverse(callback);\n    }\n  },\n  traverseVisible: function (callback) {\n    if (this.visible === false) return;\n    callback(this);\n    const children = this.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      children[i].traverseVisible(callback);\n    }\n  },\n  traverseAncestors: function (callback) {\n    const parent = this.parent;\n    if (parent !== null) {\n      callback(parent);\n      parent.traverseAncestors(callback);\n    }\n  },\n  updateMatrix: function () {\n    this.matrix.compose(this.position, this.quaternion, this.scale);\n    this.matrixWorldNeedsUpdate = true;\n  },\n  updateMatrixWorld: function (force) {\n    if (this.matrixAutoUpdate) this.updateMatrix();\n    if (this.matrixWorldNeedsUpdate || force) {\n      if (this.parent === null) {\n        this.matrixWorld.copy(this.matrix);\n      } else {\n        this.matrixWorld.multiplyMatrices(this.parent.matrixWorld, this.matrix);\n      }\n      this.matrixWorldNeedsUpdate = false;\n      force = true;\n    }\n\n    // update children\n\n    const children = this.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      children[i].updateMatrixWorld(force);\n    }\n  },\n  updateWorldMatrix: function (updateParents, updateChildren) {\n    const parent = this.parent;\n    if (updateParents === true && parent !== null) {\n      parent.updateWorldMatrix(true, false);\n    }\n    if (this.matrixAutoUpdate) this.updateMatrix();\n    if (this.parent === null) {\n      this.matrixWorld.copy(this.matrix);\n    } else {\n      this.matrixWorld.multiplyMatrices(this.parent.matrixWorld, this.matrix);\n    }\n\n    // update children\n\n    if (updateChildren === true) {\n      const children = this.children;\n      for (let i = 0, l = children.length; i < l; i++) {\n        children[i].updateWorldMatrix(false, true);\n      }\n    }\n  },\n  toJSON: function (meta) {\n    // meta is a string when called from JSON.stringify\n    const isRootObject = meta === undefined || typeof meta === 'string';\n    const output = {};\n\n    // meta is a hash used to collect geometries, materials.\n    // not providing it implies that this is the root object\n    // being serialized.\n    if (isRootObject) {\n      // initialize meta obj\n      meta = {\n        geometries: {},\n        materials: {},\n        textures: {},\n        images: {},\n        shapes: {},\n        skeletons: {},\n        animations: {}\n      };\n      output.metadata = {\n        version: 4.5,\n        type: 'Object',\n        generator: 'Object3D.toJSON'\n      };\n    }\n\n    // standard Object3D serialization\n\n    const object = {};\n    object.uuid = this.uuid;\n    object.type = this.type;\n    if (this.name !== '') object.name = this.name;\n    if (this.castShadow === true) object.castShadow = true;\n    if (this.receiveShadow === true) object.receiveShadow = true;\n    if (this.visible === false) object.visible = false;\n    if (this.frustumCulled === false) object.frustumCulled = false;\n    if (this.renderOrder !== 0) object.renderOrder = this.renderOrder;\n    if (JSON.stringify(this.userData) !== '{}') object.userData = this.userData;\n    object.layers = this.layers.mask;\n    object.matrix = this.matrix.toArray();\n    if (this.matrixAutoUpdate === false) object.matrixAutoUpdate = false;\n\n    // object specific properties\n\n    if (this.isInstancedMesh) {\n      object.type = 'InstancedMesh';\n      object.count = this.count;\n      object.instanceMatrix = this.instanceMatrix.toJSON();\n    }\n\n    //\n\n    function serialize(library, element) {\n      if (library[element.uuid] === undefined) {\n        library[element.uuid] = element.toJSON(meta);\n      }\n      return element.uuid;\n    }\n    if (this.isMesh || this.isLine || this.isPoints) {\n      object.geometry = serialize(meta.geometries, this.geometry);\n      const parameters = this.geometry.parameters;\n      if (parameters !== undefined && parameters.shapes !== undefined) {\n        const shapes = parameters.shapes;\n        if (Array.isArray(shapes)) {\n          for (let i = 0, l = shapes.length; i < l; i++) {\n            const shape = shapes[i];\n            serialize(meta.shapes, shape);\n          }\n        } else {\n          serialize(meta.shapes, shapes);\n        }\n      }\n    }\n    if (this.isSkinnedMesh) {\n      object.bindMode = this.bindMode;\n      object.bindMatrix = this.bindMatrix.toArray();\n      if (this.skeleton !== undefined) {\n        serialize(meta.skeletons, this.skeleton);\n        object.skeleton = this.skeleton.uuid;\n      }\n    }\n    if (this.material !== undefined) {\n      if (Array.isArray(this.material)) {\n        const uuids = [];\n        for (let i = 0, l = this.material.length; i < l; i++) {\n          uuids.push(serialize(meta.materials, this.material[i]));\n        }\n        object.material = uuids;\n      } else {\n        object.material = serialize(meta.materials, this.material);\n      }\n    }\n\n    //\n\n    if (this.children.length > 0) {\n      object.children = [];\n      for (let i = 0; i < this.children.length; i++) {\n        object.children.push(this.children[i].toJSON(meta).object);\n      }\n    }\n\n    //\n\n    if (this.animations.length > 0) {\n      object.animations = [];\n      for (let i = 0; i < this.animations.length; i++) {\n        const animation = this.animations[i];\n        object.animations.push(serialize(meta.animations, animation));\n      }\n    }\n    if (isRootObject) {\n      const geometries = extractFromCache(meta.geometries);\n      const materials = extractFromCache(meta.materials);\n      const textures = extractFromCache(meta.textures);\n      const images = extractFromCache(meta.images);\n      const shapes = extractFromCache(meta.shapes);\n      const skeletons = extractFromCache(meta.skeletons);\n      const animations = extractFromCache(meta.animations);\n      if (geometries.length > 0) output.geometries = geometries;\n      if (materials.length > 0) output.materials = materials;\n      if (textures.length > 0) output.textures = textures;\n      if (images.length > 0) output.images = images;\n      if (shapes.length > 0) output.shapes = shapes;\n      if (skeletons.length > 0) output.skeletons = skeletons;\n      if (animations.length > 0) output.animations = animations;\n    }\n    output.object = object;\n    return output;\n\n    // extract data from the cache hash\n    // remove metadata on each item\n    // and return as array\n    function extractFromCache(cache) {\n      const values = [];\n      for (const key in cache) {\n        const data = cache[key];\n        delete data.metadata;\n        values.push(data);\n      }\n      return values;\n    }\n  },\n  clone: function (recursive) {\n    return new this.constructor().copy(this, recursive);\n  },\n  copy: function (source, recursive = true) {\n    this.name = source.name;\n    this.up.copy(source.up);\n    this.position.copy(source.position);\n    this.rotation.order = source.rotation.order;\n    this.quaternion.copy(source.quaternion);\n    this.scale.copy(source.scale);\n    this.matrix.copy(source.matrix);\n    this.matrixWorld.copy(source.matrixWorld);\n    this.matrixAutoUpdate = source.matrixAutoUpdate;\n    this.matrixWorldNeedsUpdate = source.matrixWorldNeedsUpdate;\n    this.layers.mask = source.layers.mask;\n    this.visible = source.visible;\n    this.castShadow = source.castShadow;\n    this.receiveShadow = source.receiveShadow;\n    this.frustumCulled = source.frustumCulled;\n    this.renderOrder = source.renderOrder;\n    this.userData = JSON.parse(JSON.stringify(source.userData));\n    if (recursive === true) {\n      for (let i = 0; i < source.children.length; i++) {\n        const child = source.children[i];\n        this.add(child.clone());\n      }\n    }\n    return this;\n  }\n});\nconst _vector1 = /*@__PURE__*/new Vector3();\nconst _vector2 = /*@__PURE__*/new Vector3();\nconst _normalMatrix = /*@__PURE__*/new Matrix3();\nclass Plane {\n  constructor(normal, constant) {\n    Object.defineProperty(this, 'isPlane', {\n      value: true\n    });\n\n    // normal is assumed to be normalized\n\n    this.normal = normal !== undefined ? normal : new Vector3(1, 0, 0);\n    this.constant = constant !== undefined ? constant : 0;\n  }\n  set(normal, constant) {\n    this.normal.copy(normal);\n    this.constant = constant;\n    return this;\n  }\n  setComponents(x, y, z, w) {\n    this.normal.set(x, y, z);\n    this.constant = w;\n    return this;\n  }\n  setFromNormalAndCoplanarPoint(normal, point) {\n    this.normal.copy(normal);\n    this.constant = -point.dot(this.normal);\n    return this;\n  }\n  setFromCoplanarPoints(a, b, c) {\n    const normal = _vector1.subVectors(c, b).cross(_vector2.subVectors(a, b)).normalize();\n\n    // Q: should an error be thrown if normal is zero (e.g. degenerate plane)?\n\n    this.setFromNormalAndCoplanarPoint(normal, a);\n    return this;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(plane) {\n    this.normal.copy(plane.normal);\n    this.constant = plane.constant;\n    return this;\n  }\n  normalize() {\n    // Note: will lead to a divide by zero if the plane is invalid.\n\n    const inverseNormalLength = 1.0 / this.normal.length();\n    this.normal.multiplyScalar(inverseNormalLength);\n    this.constant *= inverseNormalLength;\n    return this;\n  }\n  negate() {\n    this.constant *= -1;\n    this.normal.negate();\n    return this;\n  }\n  distanceToPoint(point) {\n    return this.normal.dot(point) + this.constant;\n  }\n  distanceToSphere(sphere) {\n    return this.distanceToPoint(sphere.center) - sphere.radius;\n  }\n  projectPoint(point, target) {\n    if (target === undefined) {\n      console.warn('THREE.Plane: .projectPoint() target is now required');\n      target = new Vector3();\n    }\n    return target.copy(this.normal).multiplyScalar(-this.distanceToPoint(point)).add(point);\n  }\n  intersectLine(line, target) {\n    if (target === undefined) {\n      console.warn('THREE.Plane: .intersectLine() target is now required');\n      target = new Vector3();\n    }\n    const direction = line.delta(_vector1);\n    const denominator = this.normal.dot(direction);\n    if (denominator === 0) {\n      // line is coplanar, return origin\n      if (this.distanceToPoint(line.start) === 0) {\n        return target.copy(line.start);\n      }\n\n      // Unsure if this is the correct method to handle this case.\n      return undefined;\n    }\n    const t = -(line.start.dot(this.normal) + this.constant) / denominator;\n    if (t < 0 || t > 1) {\n      return undefined;\n    }\n    return target.copy(direction).multiplyScalar(t).add(line.start);\n  }\n  intersectsLine(line) {\n    // Note: this tests if a line intersects the plane, not whether it (or its end-points) are coplanar with it.\n\n    const startSign = this.distanceToPoint(line.start);\n    const endSign = this.distanceToPoint(line.end);\n    return startSign < 0 && endSign > 0 || endSign < 0 && startSign > 0;\n  }\n  intersectsBox(box) {\n    return box.intersectsPlane(this);\n  }\n  intersectsSphere(sphere) {\n    return sphere.intersectsPlane(this);\n  }\n  coplanarPoint(target) {\n    if (target === undefined) {\n      console.warn('THREE.Plane: .coplanarPoint() target is now required');\n      target = new Vector3();\n    }\n    return target.copy(this.normal).multiplyScalar(-this.constant);\n  }\n  applyMatrix4(matrix, optionalNormalMatrix) {\n    const normalMatrix = optionalNormalMatrix || _normalMatrix.getNormalMatrix(matrix);\n    const referencePoint = this.coplanarPoint(_vector1).applyMatrix4(matrix);\n    const normal = this.normal.applyMatrix3(normalMatrix).normalize();\n    this.constant = -referencePoint.dot(normal);\n    return this;\n  }\n  translate(offset) {\n    this.constant -= offset.dot(this.normal);\n    return this;\n  }\n  equals(plane) {\n    return plane.normal.equals(this.normal) && plane.constant === this.constant;\n  }\n}\nconst _v0$1 = /*@__PURE__*/new Vector3();\nconst _v1$3 = /*@__PURE__*/new Vector3();\nconst _v2$1 = /*@__PURE__*/new Vector3();\nconst _v3 = /*@__PURE__*/new Vector3();\nconst _vab = /*@__PURE__*/new Vector3();\nconst _vac = /*@__PURE__*/new Vector3();\nconst _vbc = /*@__PURE__*/new Vector3();\nconst _vap = /*@__PURE__*/new Vector3();\nconst _vbp = /*@__PURE__*/new Vector3();\nconst _vcp = /*@__PURE__*/new Vector3();\nclass Triangle {\n  constructor(a, b, c) {\n    this.a = a !== undefined ? a : new Vector3();\n    this.b = b !== undefined ? b : new Vector3();\n    this.c = c !== undefined ? c : new Vector3();\n  }\n  static getNormal(a, b, c, target) {\n    if (target === undefined) {\n      console.warn('THREE.Triangle: .getNormal() target is now required');\n      target = new Vector3();\n    }\n    target.subVectors(c, b);\n    _v0$1.subVectors(a, b);\n    target.cross(_v0$1);\n    const targetLengthSq = target.lengthSq();\n    if (targetLengthSq > 0) {\n      return target.multiplyScalar(1 / Math.sqrt(targetLengthSq));\n    }\n    return target.set(0, 0, 0);\n  }\n\n  // static/instance method to calculate barycentric coordinates\n  // based on: http://www.blackpawn.com/texts/pointinpoly/default.html\n  static getBarycoord(point, a, b, c, target) {\n    _v0$1.subVectors(c, a);\n    _v1$3.subVectors(b, a);\n    _v2$1.subVectors(point, a);\n    const dot00 = _v0$1.dot(_v0$1);\n    const dot01 = _v0$1.dot(_v1$3);\n    const dot02 = _v0$1.dot(_v2$1);\n    const dot11 = _v1$3.dot(_v1$3);\n    const dot12 = _v1$3.dot(_v2$1);\n    const denom = dot00 * dot11 - dot01 * dot01;\n    if (target === undefined) {\n      console.warn('THREE.Triangle: .getBarycoord() target is now required');\n      target = new Vector3();\n    }\n\n    // collinear or singular triangle\n    if (denom === 0) {\n      // arbitrary location outside of triangle?\n      // not sure if this is the best idea, maybe should be returning undefined\n      return target.set(-2, -1, -1);\n    }\n    const invDenom = 1 / denom;\n    const u = (dot11 * dot02 - dot01 * dot12) * invDenom;\n    const v = (dot00 * dot12 - dot01 * dot02) * invDenom;\n\n    // barycentric coordinates must always sum to 1\n    return target.set(1 - u - v, v, u);\n  }\n  static containsPoint(point, a, b, c) {\n    this.getBarycoord(point, a, b, c, _v3);\n    return _v3.x >= 0 && _v3.y >= 0 && _v3.x + _v3.y <= 1;\n  }\n  static getUV(point, p1, p2, p3, uv1, uv2, uv3, target) {\n    this.getBarycoord(point, p1, p2, p3, _v3);\n    target.set(0, 0);\n    target.addScaledVector(uv1, _v3.x);\n    target.addScaledVector(uv2, _v3.y);\n    target.addScaledVector(uv3, _v3.z);\n    return target;\n  }\n  static isFrontFacing(a, b, c, direction) {\n    _v0$1.subVectors(c, b);\n    _v1$3.subVectors(a, b);\n\n    // strictly front facing\n    return _v0$1.cross(_v1$3).dot(direction) < 0 ? true : false;\n  }\n  set(a, b, c) {\n    this.a.copy(a);\n    this.b.copy(b);\n    this.c.copy(c);\n    return this;\n  }\n  setFromPointsAndIndices(points, i0, i1, i2) {\n    this.a.copy(points[i0]);\n    this.b.copy(points[i1]);\n    this.c.copy(points[i2]);\n    return this;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(triangle) {\n    this.a.copy(triangle.a);\n    this.b.copy(triangle.b);\n    this.c.copy(triangle.c);\n    return this;\n  }\n  getArea() {\n    _v0$1.subVectors(this.c, this.b);\n    _v1$3.subVectors(this.a, this.b);\n    return _v0$1.cross(_v1$3).length() * 0.5;\n  }\n  getMidpoint(target) {\n    if (target === undefined) {\n      console.warn('THREE.Triangle: .getMidpoint() target is now required');\n      target = new Vector3();\n    }\n    return target.addVectors(this.a, this.b).add(this.c).multiplyScalar(1 / 3);\n  }\n  getNormal(target) {\n    return Triangle.getNormal(this.a, this.b, this.c, target);\n  }\n  getPlane(target) {\n    if (target === undefined) {\n      console.warn('THREE.Triangle: .getPlane() target is now required');\n      target = new Plane();\n    }\n    return target.setFromCoplanarPoints(this.a, this.b, this.c);\n  }\n  getBarycoord(point, target) {\n    return Triangle.getBarycoord(point, this.a, this.b, this.c, target);\n  }\n  getUV(point, uv1, uv2, uv3, target) {\n    return Triangle.getUV(point, this.a, this.b, this.c, uv1, uv2, uv3, target);\n  }\n  containsPoint(point) {\n    return Triangle.containsPoint(point, this.a, this.b, this.c);\n  }\n  isFrontFacing(direction) {\n    return Triangle.isFrontFacing(this.a, this.b, this.c, direction);\n  }\n  intersectsBox(box) {\n    return box.intersectsTriangle(this);\n  }\n  closestPointToPoint(p, target) {\n    if (target === undefined) {\n      console.warn('THREE.Triangle: .closestPointToPoint() target is now required');\n      target = new Vector3();\n    }\n    const a = this.a,\n      b = this.b,\n      c = this.c;\n    let v, w;\n\n    // algorithm thanks to Real-Time Collision Detection by Christer Ericson,\n    // published by Morgan Kaufmann Publishers, (c) 2005 Elsevier Inc.,\n    // under the accompanying license; see chapter 5.1.5 for detailed explanation.\n    // basically, we're distinguishing which of the voronoi regions of the triangle\n    // the point lies in with the minimum amount of redundant computation.\n\n    _vab.subVectors(b, a);\n    _vac.subVectors(c, a);\n    _vap.subVectors(p, a);\n    const d1 = _vab.dot(_vap);\n    const d2 = _vac.dot(_vap);\n    if (d1 <= 0 && d2 <= 0) {\n      // vertex region of A; barycentric coords (1, 0, 0)\n      return target.copy(a);\n    }\n    _vbp.subVectors(p, b);\n    const d3 = _vab.dot(_vbp);\n    const d4 = _vac.dot(_vbp);\n    if (d3 >= 0 && d4 <= d3) {\n      // vertex region of B; barycentric coords (0, 1, 0)\n      return target.copy(b);\n    }\n    const vc = d1 * d4 - d3 * d2;\n    if (vc <= 0 && d1 >= 0 && d3 <= 0) {\n      v = d1 / (d1 - d3);\n      // edge region of AB; barycentric coords (1-v, v, 0)\n      return target.copy(a).addScaledVector(_vab, v);\n    }\n    _vcp.subVectors(p, c);\n    const d5 = _vab.dot(_vcp);\n    const d6 = _vac.dot(_vcp);\n    if (d6 >= 0 && d5 <= d6) {\n      // vertex region of C; barycentric coords (0, 0, 1)\n      return target.copy(c);\n    }\n    const vb = d5 * d2 - d1 * d6;\n    if (vb <= 0 && d2 >= 0 && d6 <= 0) {\n      w = d2 / (d2 - d6);\n      // edge region of AC; barycentric coords (1-w, 0, w)\n      return target.copy(a).addScaledVector(_vac, w);\n    }\n    const va = d3 * d6 - d5 * d4;\n    if (va <= 0 && d4 - d3 >= 0 && d5 - d6 >= 0) {\n      _vbc.subVectors(c, b);\n      w = (d4 - d3) / (d4 - d3 + (d5 - d6));\n      // edge region of BC; barycentric coords (0, 1-w, w)\n      return target.copy(b).addScaledVector(_vbc, w); // edge region of BC\n    }\n\n    // face region\n    const denom = 1 / (va + vb + vc);\n    // u = va * denom\n    v = vb * denom;\n    w = vc * denom;\n    return target.copy(a).addScaledVector(_vab, v).addScaledVector(_vac, w);\n  }\n  equals(triangle) {\n    return triangle.a.equals(this.a) && triangle.b.equals(this.b) && triangle.c.equals(this.c);\n  }\n}\nconst _colorKeywords = {\n  'aliceblue': 0xF0F8FF,\n  'antiquewhite': 0xFAEBD7,\n  'aqua': 0x00FFFF,\n  'aquamarine': 0x7FFFD4,\n  'azure': 0xF0FFFF,\n  'beige': 0xF5F5DC,\n  'bisque': 0xFFE4C4,\n  'black': 0x000000,\n  'blanchedalmond': 0xFFEBCD,\n  'blue': 0x0000FF,\n  'blueviolet': 0x8A2BE2,\n  'brown': 0xA52A2A,\n  'burlywood': 0xDEB887,\n  'cadetblue': 0x5F9EA0,\n  'chartreuse': 0x7FFF00,\n  'chocolate': 0xD2691E,\n  'coral': 0xFF7F50,\n  'cornflowerblue': 0x6495ED,\n  'cornsilk': 0xFFF8DC,\n  'crimson': 0xDC143C,\n  'cyan': 0x00FFFF,\n  'darkblue': 0x00008B,\n  'darkcyan': 0x008B8B,\n  'darkgoldenrod': 0xB8860B,\n  'darkgray': 0xA9A9A9,\n  'darkgreen': 0x006400,\n  'darkgrey': 0xA9A9A9,\n  'darkkhaki': 0xBDB76B,\n  'darkmagenta': 0x8B008B,\n  'darkolivegreen': 0x556B2F,\n  'darkorange': 0xFF8C00,\n  'darkorchid': 0x9932CC,\n  'darkred': 0x8B0000,\n  'darksalmon': 0xE9967A,\n  'darkseagreen': 0x8FBC8F,\n  'darkslateblue': 0x483D8B,\n  'darkslategray': 0x2F4F4F,\n  'darkslategrey': 0x2F4F4F,\n  'darkturquoise': 0x00CED1,\n  'darkviolet': 0x9400D3,\n  'deeppink': 0xFF1493,\n  'deepskyblue': 0x00BFFF,\n  'dimgray': 0x696969,\n  'dimgrey': 0x696969,\n  'dodgerblue': 0x1E90FF,\n  'firebrick': 0xB22222,\n  'floralwhite': 0xFFFAF0,\n  'forestgreen': 0x228B22,\n  'fuchsia': 0xFF00FF,\n  'gainsboro': 0xDCDCDC,\n  'ghostwhite': 0xF8F8FF,\n  'gold': 0xFFD700,\n  'goldenrod': 0xDAA520,\n  'gray': 0x808080,\n  'green': 0x008000,\n  'greenyellow': 0xADFF2F,\n  'grey': 0x808080,\n  'honeydew': 0xF0FFF0,\n  'hotpink': 0xFF69B4,\n  'indianred': 0xCD5C5C,\n  'indigo': 0x4B0082,\n  'ivory': 0xFFFFF0,\n  'khaki': 0xF0E68C,\n  'lavender': 0xE6E6FA,\n  'lavenderblush': 0xFFF0F5,\n  'lawngreen': 0x7CFC00,\n  'lemonchiffon': 0xFFFACD,\n  'lightblue': 0xADD8E6,\n  'lightcoral': 0xF08080,\n  'lightcyan': 0xE0FFFF,\n  'lightgoldenrodyellow': 0xFAFAD2,\n  'lightgray': 0xD3D3D3,\n  'lightgreen': 0x90EE90,\n  'lightgrey': 0xD3D3D3,\n  'lightpink': 0xFFB6C1,\n  'lightsalmon': 0xFFA07A,\n  'lightseagreen': 0x20B2AA,\n  'lightskyblue': 0x87CEFA,\n  'lightslategray': 0x778899,\n  'lightslategrey': 0x778899,\n  'lightsteelblue': 0xB0C4DE,\n  'lightyellow': 0xFFFFE0,\n  'lime': 0x00FF00,\n  'limegreen': 0x32CD32,\n  'linen': 0xFAF0E6,\n  'magenta': 0xFF00FF,\n  'maroon': 0x800000,\n  'mediumaquamarine': 0x66CDAA,\n  'mediumblue': 0x0000CD,\n  'mediumorchid': 0xBA55D3,\n  'mediumpurple': 0x9370DB,\n  'mediumseagreen': 0x3CB371,\n  'mediumslateblue': 0x7B68EE,\n  'mediumspringgreen': 0x00FA9A,\n  'mediumturquoise': 0x48D1CC,\n  'mediumvioletred': 0xC71585,\n  'midnightblue': 0x191970,\n  'mintcream': 0xF5FFFA,\n  'mistyrose': 0xFFE4E1,\n  'moccasin': 0xFFE4B5,\n  'navajowhite': 0xFFDEAD,\n  'navy': 0x000080,\n  'oldlace': 0xFDF5E6,\n  'olive': 0x808000,\n  'olivedrab': 0x6B8E23,\n  'orange': 0xFFA500,\n  'orangered': 0xFF4500,\n  'orchid': 0xDA70D6,\n  'palegoldenrod': 0xEEE8AA,\n  'palegreen': 0x98FB98,\n  'paleturquoise': 0xAFEEEE,\n  'palevioletred': 0xDB7093,\n  'papayawhip': 0xFFEFD5,\n  'peachpuff': 0xFFDAB9,\n  'peru': 0xCD853F,\n  'pink': 0xFFC0CB,\n  'plum': 0xDDA0DD,\n  'powderblue': 0xB0E0E6,\n  'purple': 0x800080,\n  'rebeccapurple': 0x663399,\n  'red': 0xFF0000,\n  'rosybrown': 0xBC8F8F,\n  'royalblue': 0x4169E1,\n  'saddlebrown': 0x8B4513,\n  'salmon': 0xFA8072,\n  'sandybrown': 0xF4A460,\n  'seagreen': 0x2E8B57,\n  'seashell': 0xFFF5EE,\n  'sienna': 0xA0522D,\n  'silver': 0xC0C0C0,\n  'skyblue': 0x87CEEB,\n  'slateblue': 0x6A5ACD,\n  'slategray': 0x708090,\n  'slategrey': 0x708090,\n  'snow': 0xFFFAFA,\n  'springgreen': 0x00FF7F,\n  'steelblue': 0x4682B4,\n  'tan': 0xD2B48C,\n  'teal': 0x008080,\n  'thistle': 0xD8BFD8,\n  'tomato': 0xFF6347,\n  'turquoise': 0x40E0D0,\n  'violet': 0xEE82EE,\n  'wheat': 0xF5DEB3,\n  'white': 0xFFFFFF,\n  'whitesmoke': 0xF5F5F5,\n  'yellow': 0xFFFF00,\n  'yellowgreen': 0x9ACD32\n};\nconst _hslA = {\n  h: 0,\n  s: 0,\n  l: 0\n};\nconst _hslB = {\n  h: 0,\n  s: 0,\n  l: 0\n};\nfunction hue2rgb(p, q, t) {\n  if (t < 0) t += 1;\n  if (t > 1) t -= 1;\n  if (t < 1 / 6) return p + (q - p) * 6 * t;\n  if (t < 1 / 2) return q;\n  if (t < 2 / 3) return p + (q - p) * 6 * (2 / 3 - t);\n  return p;\n}\nfunction SRGBToLinear(c) {\n  return c < 0.04045 ? c * 0.0773993808 : Math.pow(c * 0.9478672986 + 0.0521327014, 2.4);\n}\nfunction LinearToSRGB(c) {\n  return c < 0.0031308 ? c * 12.92 : 1.055 * Math.pow(c, 0.41666) - 0.055;\n}\nclass Color {\n  constructor(r, g, b) {\n    Object.defineProperty(this, 'isColor', {\n      value: true\n    });\n    if (g === undefined && b === undefined) {\n      // r is THREE.Color, hex or string\n      return this.set(r);\n    }\n    return this.setRGB(r, g, b);\n  }\n  set(value) {\n    if (value && value.isColor) {\n      this.copy(value);\n    } else if (typeof value === 'number') {\n      this.setHex(value);\n    } else if (typeof value === 'string') {\n      this.setStyle(value);\n    }\n    return this;\n  }\n  setScalar(scalar) {\n    this.r = scalar;\n    this.g = scalar;\n    this.b = scalar;\n    return this;\n  }\n  setHex(hex) {\n    hex = Math.floor(hex);\n    this.r = (hex >> 16 & 255) / 255;\n    this.g = (hex >> 8 & 255) / 255;\n    this.b = (hex & 255) / 255;\n    return this;\n  }\n  setRGB(r, g, b) {\n    this.r = r;\n    this.g = g;\n    this.b = b;\n    return this;\n  }\n  setHSL(h, s, l) {\n    // h,s,l ranges are in 0.0 - 1.0\n    h = MathUtils.euclideanModulo(h, 1);\n    s = MathUtils.clamp(s, 0, 1);\n    l = MathUtils.clamp(l, 0, 1);\n    if (s === 0) {\n      this.r = this.g = this.b = l;\n    } else {\n      const p = l <= 0.5 ? l * (1 + s) : l + s - l * s;\n      const q = 2 * l - p;\n      this.r = hue2rgb(q, p, h + 1 / 3);\n      this.g = hue2rgb(q, p, h);\n      this.b = hue2rgb(q, p, h - 1 / 3);\n    }\n    return this;\n  }\n  setStyle(style) {\n    function handleAlpha(string) {\n      if (string === undefined) return;\n      if (parseFloat(string) < 1) {\n        console.warn('THREE.Color: Alpha component of ' + style + ' will be ignored.');\n      }\n    }\n    let m;\n    if (m = /^((?:rgb|hsl)a?)\\(([^\\)]*)\\)/.exec(style)) {\n      // rgb / hsl\n\n      let color;\n      const name = m[1];\n      const components = m[2];\n      switch (name) {\n        case 'rgb':\n        case 'rgba':\n          if (color = /^\\s*(\\d+)\\s*,\\s*(\\d+)\\s*,\\s*(\\d+)\\s*(?:,\\s*(\\d*\\.?\\d+)\\s*)?$/.exec(components)) {\n            // rgb(255,0,0) rgba(255,0,0,0.5)\n            this.r = Math.min(255, parseInt(color[1], 10)) / 255;\n            this.g = Math.min(255, parseInt(color[2], 10)) / 255;\n            this.b = Math.min(255, parseInt(color[3], 10)) / 255;\n            handleAlpha(color[4]);\n            return this;\n          }\n          if (color = /^\\s*(\\d+)\\%\\s*,\\s*(\\d+)\\%\\s*,\\s*(\\d+)\\%\\s*(?:,\\s*(\\d*\\.?\\d+)\\s*)?$/.exec(components)) {\n            // rgb(100%,0%,0%) rgba(100%,0%,0%,0.5)\n            this.r = Math.min(100, parseInt(color[1], 10)) / 100;\n            this.g = Math.min(100, parseInt(color[2], 10)) / 100;\n            this.b = Math.min(100, parseInt(color[3], 10)) / 100;\n            handleAlpha(color[4]);\n            return this;\n          }\n          break;\n        case 'hsl':\n        case 'hsla':\n          if (color = /^\\s*(\\d*\\.?\\d+)\\s*,\\s*(\\d+)\\%\\s*,\\s*(\\d+)\\%\\s*(?:,\\s*(\\d*\\.?\\d+)\\s*)?$/.exec(components)) {\n            // hsl(120,50%,50%) hsla(120,50%,50%,0.5)\n            const h = parseFloat(color[1]) / 360;\n            const s = parseInt(color[2], 10) / 100;\n            const l = parseInt(color[3], 10) / 100;\n            handleAlpha(color[4]);\n            return this.setHSL(h, s, l);\n          }\n          break;\n      }\n    } else if (m = /^\\#([A-Fa-f\\d]+)$/.exec(style)) {\n      // hex color\n\n      const hex = m[1];\n      const size = hex.length;\n      if (size === 3) {\n        // #ff0\n        this.r = parseInt(hex.charAt(0) + hex.charAt(0), 16) / 255;\n        this.g = parseInt(hex.charAt(1) + hex.charAt(1), 16) / 255;\n        this.b = parseInt(hex.charAt(2) + hex.charAt(2), 16) / 255;\n        return this;\n      } else if (size === 6) {\n        // #ff0000\n        this.r = parseInt(hex.charAt(0) + hex.charAt(1), 16) / 255;\n        this.g = parseInt(hex.charAt(2) + hex.charAt(3), 16) / 255;\n        this.b = parseInt(hex.charAt(4) + hex.charAt(5), 16) / 255;\n        return this;\n      }\n    }\n    if (style && style.length > 0) {\n      return this.setColorName(style);\n    }\n    return this;\n  }\n  setColorName(style) {\n    // color keywords\n    const hex = _colorKeywords[style];\n    if (hex !== undefined) {\n      // red\n      this.setHex(hex);\n    } else {\n      // unknown color\n      console.warn('THREE.Color: Unknown color ' + style);\n    }\n    return this;\n  }\n  clone() {\n    return new this.constructor(this.r, this.g, this.b);\n  }\n  copy(color) {\n    this.r = color.r;\n    this.g = color.g;\n    this.b = color.b;\n    return this;\n  }\n  copyGammaToLinear(color, gammaFactor = 2.0) {\n    this.r = Math.pow(color.r, gammaFactor);\n    this.g = Math.pow(color.g, gammaFactor);\n    this.b = Math.pow(color.b, gammaFactor);\n    return this;\n  }\n  copyLinearToGamma(color, gammaFactor = 2.0) {\n    const safeInverse = gammaFactor > 0 ? 1.0 / gammaFactor : 1.0;\n    this.r = Math.pow(color.r, safeInverse);\n    this.g = Math.pow(color.g, safeInverse);\n    this.b = Math.pow(color.b, safeInverse);\n    return this;\n  }\n  convertGammaToLinear(gammaFactor) {\n    this.copyGammaToLinear(this, gammaFactor);\n    return this;\n  }\n  convertLinearToGamma(gammaFactor) {\n    this.copyLinearToGamma(this, gammaFactor);\n    return this;\n  }\n  copySRGBToLinear(color) {\n    this.r = SRGBToLinear(color.r);\n    this.g = SRGBToLinear(color.g);\n    this.b = SRGBToLinear(color.b);\n    return this;\n  }\n  copyLinearToSRGB(color) {\n    this.r = LinearToSRGB(color.r);\n    this.g = LinearToSRGB(color.g);\n    this.b = LinearToSRGB(color.b);\n    return this;\n  }\n  convertSRGBToLinear() {\n    this.copySRGBToLinear(this);\n    return this;\n  }\n  convertLinearToSRGB() {\n    this.copyLinearToSRGB(this);\n    return this;\n  }\n  getHex() {\n    return this.r * 255 << 16 ^ this.g * 255 << 8 ^ this.b * 255 << 0;\n  }\n  getHexString() {\n    return ('000000' + this.getHex().toString(16)).slice(-6);\n  }\n  getHSL(target) {\n    // h,s,l ranges are in 0.0 - 1.0\n\n    if (target === undefined) {\n      console.warn('THREE.Color: .getHSL() target is now required');\n      target = {\n        h: 0,\n        s: 0,\n        l: 0\n      };\n    }\n    const r = this.r,\n      g = this.g,\n      b = this.b;\n    const max = Math.max(r, g, b);\n    const min = Math.min(r, g, b);\n    let hue, saturation;\n    const lightness = (min + max) / 2.0;\n    if (min === max) {\n      hue = 0;\n      saturation = 0;\n    } else {\n      const delta = max - min;\n      saturation = lightness <= 0.5 ? delta / (max + min) : delta / (2 - max - min);\n      switch (max) {\n        case r:\n          hue = (g - b) / delta + (g < b ? 6 : 0);\n          break;\n        case g:\n          hue = (b - r) / delta + 2;\n          break;\n        case b:\n          hue = (r - g) / delta + 4;\n          break;\n      }\n      hue /= 6;\n    }\n    target.h = hue;\n    target.s = saturation;\n    target.l = lightness;\n    return target;\n  }\n  getStyle() {\n    return 'rgb(' + (this.r * 255 | 0) + ',' + (this.g * 255 | 0) + ',' + (this.b * 255 | 0) + ')';\n  }\n  offsetHSL(h, s, l) {\n    this.getHSL(_hslA);\n    _hslA.h += h;\n    _hslA.s += s;\n    _hslA.l += l;\n    this.setHSL(_hslA.h, _hslA.s, _hslA.l);\n    return this;\n  }\n  add(color) {\n    this.r += color.r;\n    this.g += color.g;\n    this.b += color.b;\n    return this;\n  }\n  addColors(color1, color2) {\n    this.r = color1.r + color2.r;\n    this.g = color1.g + color2.g;\n    this.b = color1.b + color2.b;\n    return this;\n  }\n  addScalar(s) {\n    this.r += s;\n    this.g += s;\n    this.b += s;\n    return this;\n  }\n  sub(color) {\n    this.r = Math.max(0, this.r - color.r);\n    this.g = Math.max(0, this.g - color.g);\n    this.b = Math.max(0, this.b - color.b);\n    return this;\n  }\n  multiply(color) {\n    this.r *= color.r;\n    this.g *= color.g;\n    this.b *= color.b;\n    return this;\n  }\n  multiplyScalar(s) {\n    this.r *= s;\n    this.g *= s;\n    this.b *= s;\n    return this;\n  }\n  lerp(color, alpha) {\n    this.r += (color.r - this.r) * alpha;\n    this.g += (color.g - this.g) * alpha;\n    this.b += (color.b - this.b) * alpha;\n    return this;\n  }\n  lerpColors(color1, color2, alpha) {\n    this.r = color1.r + (color2.r - color1.r) * alpha;\n    this.g = color1.g + (color2.g - color1.g) * alpha;\n    this.b = color1.b + (color2.b - color1.b) * alpha;\n    return this;\n  }\n  lerpHSL(color, alpha) {\n    this.getHSL(_hslA);\n    color.getHSL(_hslB);\n    const h = MathUtils.lerp(_hslA.h, _hslB.h, alpha);\n    const s = MathUtils.lerp(_hslA.s, _hslB.s, alpha);\n    const l = MathUtils.lerp(_hslA.l, _hslB.l, alpha);\n    this.setHSL(h, s, l);\n    return this;\n  }\n  equals(c) {\n    return c.r === this.r && c.g === this.g && c.b === this.b;\n  }\n  fromArray(array, offset = 0) {\n    this.r = array[offset];\n    this.g = array[offset + 1];\n    this.b = array[offset + 2];\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    array[offset] = this.r;\n    array[offset + 1] = this.g;\n    array[offset + 2] = this.b;\n    return array;\n  }\n  fromBufferAttribute(attribute, index) {\n    this.r = attribute.getX(index);\n    this.g = attribute.getY(index);\n    this.b = attribute.getZ(index);\n    if (attribute.normalized === true) {\n      // assuming Uint8Array\n\n      this.r /= 255;\n      this.g /= 255;\n      this.b /= 255;\n    }\n    return this;\n  }\n  toJSON() {\n    return this.getHex();\n  }\n}\nColor.NAMES = _colorKeywords;\nColor.prototype.r = 1;\nColor.prototype.g = 1;\nColor.prototype.b = 1;\nclass Face3 {\n  constructor(a, b, c, normal, color, materialIndex = 0) {\n    this.a = a;\n    this.b = b;\n    this.c = c;\n    this.normal = normal && normal.isVector3 ? normal : new Vector3();\n    this.vertexNormals = Array.isArray(normal) ? normal : [];\n    this.color = color && color.isColor ? color : new Color();\n    this.vertexColors = Array.isArray(color) ? color : [];\n    this.materialIndex = materialIndex;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(source) {\n    this.a = source.a;\n    this.b = source.b;\n    this.c = source.c;\n    this.normal.copy(source.normal);\n    this.color.copy(source.color);\n    this.materialIndex = source.materialIndex;\n    for (let i = 0, il = source.vertexNormals.length; i < il; i++) {\n      this.vertexNormals[i] = source.vertexNormals[i].clone();\n    }\n    for (let i = 0, il = source.vertexColors.length; i < il; i++) {\n      this.vertexColors[i] = source.vertexColors[i].clone();\n    }\n    return this;\n  }\n}\nlet materialId = 0;\nfunction Material() {\n  Object.defineProperty(this, 'id', {\n    value: materialId++\n  });\n  this.uuid = MathUtils.generateUUID();\n  this.name = '';\n  this.type = 'Material';\n  this.fog = true;\n  this.blending = NormalBlending;\n  this.side = FrontSide;\n  this.flatShading = false;\n  this.vertexColors = false;\n  this.opacity = 1;\n  this.transparent = false;\n  this.blendSrc = SrcAlphaFactor;\n  this.blendDst = OneMinusSrcAlphaFactor;\n  this.blendEquation = AddEquation;\n  this.blendSrcAlpha = null;\n  this.blendDstAlpha = null;\n  this.blendEquationAlpha = null;\n  this.depthFunc = LessEqualDepth;\n  this.depthTest = true;\n  this.depthWrite = true;\n  this.stencilWriteMask = 0xff;\n  this.stencilFunc = AlwaysStencilFunc;\n  this.stencilRef = 0;\n  this.stencilFuncMask = 0xff;\n  this.stencilFail = KeepStencilOp;\n  this.stencilZFail = KeepStencilOp;\n  this.stencilZPass = KeepStencilOp;\n  this.stencilWrite = false;\n  this.clippingPlanes = null;\n  this.clipIntersection = false;\n  this.clipShadows = false;\n  this.shadowSide = null;\n  this.colorWrite = true;\n  this.precision = null; // override the renderer's default precision for this material\n\n  this.polygonOffset = false;\n  this.polygonOffsetFactor = 0;\n  this.polygonOffsetUnits = 0;\n  this.dithering = false;\n  this.alphaTest = 0;\n  this.premultipliedAlpha = false;\n  this.visible = true;\n  this.toneMapped = true;\n  this.userData = {};\n  this.version = 0;\n}\nMaterial.prototype = _extends__default['default'](Object.create(EventDispatcher.prototype), {\n  constructor: Material,\n  isMaterial: true,\n  onBeforeCompile: function /* shaderobject, renderer */ () {},\n  customProgramCacheKey: function () {\n    return this.onBeforeCompile.toString();\n  },\n  setValues: function (values) {\n    if (values === undefined) return;\n    for (const key in values) {\n      const newValue = values[key];\n      if (newValue === undefined) {\n        console.warn('THREE.Material: \\'' + key + '\\' parameter is undefined.');\n        continue;\n      }\n\n      // for backward compatability if shading is set in the constructor\n      if (key === 'shading') {\n        console.warn('THREE.' + this.type + ': .shading has been removed. Use the boolean .flatShading instead.');\n        this.flatShading = newValue === FlatShading ? true : false;\n        continue;\n      }\n      const currentValue = this[key];\n      if (currentValue === undefined) {\n        console.warn('THREE.' + this.type + ': \\'' + key + '\\' is not a property of this material.');\n        continue;\n      }\n      if (currentValue && currentValue.isColor) {\n        currentValue.set(newValue);\n      } else if (currentValue && currentValue.isVector3 && newValue && newValue.isVector3) {\n        currentValue.copy(newValue);\n      } else {\n        this[key] = newValue;\n      }\n    }\n  },\n  toJSON: function (meta) {\n    const isRoot = meta === undefined || typeof meta === 'string';\n    if (isRoot) {\n      meta = {\n        textures: {},\n        images: {}\n      };\n    }\n    const data = {\n      metadata: {\n        version: 4.5,\n        type: 'Material',\n        generator: 'Material.toJSON'\n      }\n    };\n\n    // standard Material serialization\n    data.uuid = this.uuid;\n    data.type = this.type;\n    if (this.name !== '') data.name = this.name;\n    if (this.color && this.color.isColor) data.color = this.color.getHex();\n    if (this.roughness !== undefined) data.roughness = this.roughness;\n    if (this.metalness !== undefined) data.metalness = this.metalness;\n    if (this.sheen && this.sheen.isColor) data.sheen = this.sheen.getHex();\n    if (this.emissive && this.emissive.isColor) data.emissive = this.emissive.getHex();\n    if (this.emissiveIntensity && this.emissiveIntensity !== 1) data.emissiveIntensity = this.emissiveIntensity;\n    if (this.specular && this.specular.isColor) data.specular = this.specular.getHex();\n    if (this.shininess !== undefined) data.shininess = this.shininess;\n    if (this.clearcoat !== undefined) data.clearcoat = this.clearcoat;\n    if (this.clearcoatRoughness !== undefined) data.clearcoatRoughness = this.clearcoatRoughness;\n    if (this.clearcoatMap && this.clearcoatMap.isTexture) {\n      data.clearcoatMap = this.clearcoatMap.toJSON(meta).uuid;\n    }\n    if (this.clearcoatRoughnessMap && this.clearcoatRoughnessMap.isTexture) {\n      data.clearcoatRoughnessMap = this.clearcoatRoughnessMap.toJSON(meta).uuid;\n    }\n    if (this.clearcoatNormalMap && this.clearcoatNormalMap.isTexture) {\n      data.clearcoatNormalMap = this.clearcoatNormalMap.toJSON(meta).uuid;\n      data.clearcoatNormalScale = this.clearcoatNormalScale.toArray();\n    }\n    if (this.map && this.map.isTexture) data.map = this.map.toJSON(meta).uuid;\n    if (this.matcap && this.matcap.isTexture) data.matcap = this.matcap.toJSON(meta).uuid;\n    if (this.alphaMap && this.alphaMap.isTexture) data.alphaMap = this.alphaMap.toJSON(meta).uuid;\n    if (this.lightMap && this.lightMap.isTexture) data.lightMap = this.lightMap.toJSON(meta).uuid;\n    if (this.aoMap && this.aoMap.isTexture) {\n      data.aoMap = this.aoMap.toJSON(meta).uuid;\n      data.aoMapIntensity = this.aoMapIntensity;\n    }\n    if (this.bumpMap && this.bumpMap.isTexture) {\n      data.bumpMap = this.bumpMap.toJSON(meta).uuid;\n      data.bumpScale = this.bumpScale;\n    }\n    if (this.normalMap && this.normalMap.isTexture) {\n      data.normalMap = this.normalMap.toJSON(meta).uuid;\n      data.normalMapType = this.normalMapType;\n      data.normalScale = this.normalScale.toArray();\n    }\n    if (this.displacementMap && this.displacementMap.isTexture) {\n      data.displacementMap = this.displacementMap.toJSON(meta).uuid;\n      data.displacementScale = this.displacementScale;\n      data.displacementBias = this.displacementBias;\n    }\n    if (this.roughnessMap && this.roughnessMap.isTexture) data.roughnessMap = this.roughnessMap.toJSON(meta).uuid;\n    if (this.metalnessMap && this.metalnessMap.isTexture) data.metalnessMap = this.metalnessMap.toJSON(meta).uuid;\n    if (this.emissiveMap && this.emissiveMap.isTexture) data.emissiveMap = this.emissiveMap.toJSON(meta).uuid;\n    if (this.specularMap && this.specularMap.isTexture) data.specularMap = this.specularMap.toJSON(meta).uuid;\n    if (this.envMap && this.envMap.isTexture) {\n      data.envMap = this.envMap.toJSON(meta).uuid;\n      data.reflectivity = this.reflectivity; // Scale behind envMap\n      data.refractionRatio = this.refractionRatio;\n      if (this.combine !== undefined) data.combine = this.combine;\n      if (this.envMapIntensity !== undefined) data.envMapIntensity = this.envMapIntensity;\n    }\n    if (this.gradientMap && this.gradientMap.isTexture) {\n      data.gradientMap = this.gradientMap.toJSON(meta).uuid;\n    }\n    if (this.size !== undefined) data.size = this.size;\n    if (this.sizeAttenuation !== undefined) data.sizeAttenuation = this.sizeAttenuation;\n    if (this.blending !== NormalBlending) data.blending = this.blending;\n    if (this.flatShading === true) data.flatShading = this.flatShading;\n    if (this.side !== FrontSide) data.side = this.side;\n    if (this.vertexColors) data.vertexColors = true;\n    if (this.opacity < 1) data.opacity = this.opacity;\n    if (this.transparent === true) data.transparent = this.transparent;\n    data.depthFunc = this.depthFunc;\n    data.depthTest = this.depthTest;\n    data.depthWrite = this.depthWrite;\n    data.stencilWrite = this.stencilWrite;\n    data.stencilWriteMask = this.stencilWriteMask;\n    data.stencilFunc = this.stencilFunc;\n    data.stencilRef = this.stencilRef;\n    data.stencilFuncMask = this.stencilFuncMask;\n    data.stencilFail = this.stencilFail;\n    data.stencilZFail = this.stencilZFail;\n    data.stencilZPass = this.stencilZPass;\n\n    // rotation (SpriteMaterial)\n    if (this.rotation && this.rotation !== 0) data.rotation = this.rotation;\n    if (this.polygonOffset === true) data.polygonOffset = true;\n    if (this.polygonOffsetFactor !== 0) data.polygonOffsetFactor = this.polygonOffsetFactor;\n    if (this.polygonOffsetUnits !== 0) data.polygonOffsetUnits = this.polygonOffsetUnits;\n    if (this.linewidth && this.linewidth !== 1) data.linewidth = this.linewidth;\n    if (this.dashSize !== undefined) data.dashSize = this.dashSize;\n    if (this.gapSize !== undefined) data.gapSize = this.gapSize;\n    if (this.scale !== undefined) data.scale = this.scale;\n    if (this.dithering === true) data.dithering = true;\n    if (this.alphaTest > 0) data.alphaTest = this.alphaTest;\n    if (this.premultipliedAlpha === true) data.premultipliedAlpha = this.premultipliedAlpha;\n    if (this.wireframe === true) data.wireframe = this.wireframe;\n    if (this.wireframeLinewidth > 1) data.wireframeLinewidth = this.wireframeLinewidth;\n    if (this.wireframeLinecap !== 'round') data.wireframeLinecap = this.wireframeLinecap;\n    if (this.wireframeLinejoin !== 'round') data.wireframeLinejoin = this.wireframeLinejoin;\n    if (this.morphTargets === true) data.morphTargets = true;\n    if (this.morphNormals === true) data.morphNormals = true;\n    if (this.skinning === true) data.skinning = true;\n    if (this.visible === false) data.visible = false;\n    if (this.toneMapped === false) data.toneMapped = false;\n    if (JSON.stringify(this.userData) !== '{}') data.userData = this.userData;\n\n    // TODO: Copied from Object3D.toJSON\n\n    function extractFromCache(cache) {\n      const values = [];\n      for (const key in cache) {\n        const data = cache[key];\n        delete data.metadata;\n        values.push(data);\n      }\n      return values;\n    }\n    if (isRoot) {\n      const textures = extractFromCache(meta.textures);\n      const images = extractFromCache(meta.images);\n      if (textures.length > 0) data.textures = textures;\n      if (images.length > 0) data.images = images;\n    }\n    return data;\n  },\n  clone: function () {\n    return new this.constructor().copy(this);\n  },\n  copy: function (source) {\n    this.name = source.name;\n    this.fog = source.fog;\n    this.blending = source.blending;\n    this.side = source.side;\n    this.flatShading = source.flatShading;\n    this.vertexColors = source.vertexColors;\n    this.opacity = source.opacity;\n    this.transparent = source.transparent;\n    this.blendSrc = source.blendSrc;\n    this.blendDst = source.blendDst;\n    this.blendEquation = source.blendEquation;\n    this.blendSrcAlpha = source.blendSrcAlpha;\n    this.blendDstAlpha = source.blendDstAlpha;\n    this.blendEquationAlpha = source.blendEquationAlpha;\n    this.depthFunc = source.depthFunc;\n    this.depthTest = source.depthTest;\n    this.depthWrite = source.depthWrite;\n    this.stencilWriteMask = source.stencilWriteMask;\n    this.stencilFunc = source.stencilFunc;\n    this.stencilRef = source.stencilRef;\n    this.stencilFuncMask = source.stencilFuncMask;\n    this.stencilFail = source.stencilFail;\n    this.stencilZFail = source.stencilZFail;\n    this.stencilZPass = source.stencilZPass;\n    this.stencilWrite = source.stencilWrite;\n    const srcPlanes = source.clippingPlanes;\n    let dstPlanes = null;\n    if (srcPlanes !== null) {\n      const n = srcPlanes.length;\n      dstPlanes = new Array(n);\n      for (let i = 0; i !== n; ++i) {\n        dstPlanes[i] = srcPlanes[i].clone();\n      }\n    }\n    this.clippingPlanes = dstPlanes;\n    this.clipIntersection = source.clipIntersection;\n    this.clipShadows = source.clipShadows;\n    this.shadowSide = source.shadowSide;\n    this.colorWrite = source.colorWrite;\n    this.precision = source.precision;\n    this.polygonOffset = source.polygonOffset;\n    this.polygonOffsetFactor = source.polygonOffsetFactor;\n    this.polygonOffsetUnits = source.polygonOffsetUnits;\n    this.dithering = source.dithering;\n    this.alphaTest = source.alphaTest;\n    this.premultipliedAlpha = source.premultipliedAlpha;\n    this.visible = source.visible;\n    this.toneMapped = source.toneMapped;\n    this.userData = JSON.parse(JSON.stringify(source.userData));\n    return this;\n  },\n  dispose: function () {\n    this.dispatchEvent({\n      type: 'dispose'\n    });\n  }\n});\nObject.defineProperty(Material.prototype, 'needsUpdate', {\n  set: function (value) {\n    if (value === true) this.version++;\n  }\n});\n\n/**\n * parameters = {\n *  color: <hex>,\n *  opacity: <float>,\n *  map: new THREE.Texture( <Image> ),\n *\n *  lightMap: new THREE.Texture( <Image> ),\n *  lightMapIntensity: <float>\n *\n *  aoMap: new THREE.Texture( <Image> ),\n *  aoMapIntensity: <float>\n *\n *  specularMap: new THREE.Texture( <Image> ),\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  envMap: new THREE.CubeTexture( [posx, negx, posy, negy, posz, negz] ),\n *  combine: THREE.Multiply,\n *  reflectivity: <float>,\n *  refractionRatio: <float>,\n *\n *  depthTest: <bool>,\n *  depthWrite: <bool>,\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>,\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>\n * }\n */\n\nfunction MeshBasicMaterial(parameters) {\n  Material.call(this);\n  this.type = 'MeshBasicMaterial';\n  this.color = new Color(0xffffff); // emissive\n\n  this.map = null;\n  this.lightMap = null;\n  this.lightMapIntensity = 1.0;\n  this.aoMap = null;\n  this.aoMapIntensity = 1.0;\n  this.specularMap = null;\n  this.alphaMap = null;\n  this.envMap = null;\n  this.combine = MultiplyOperation;\n  this.reflectivity = 1;\n  this.refractionRatio = 0.98;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.wireframeLinecap = 'round';\n  this.wireframeLinejoin = 'round';\n  this.skinning = false;\n  this.morphTargets = false;\n  this.setValues(parameters);\n}\nMeshBasicMaterial.prototype = Object.create(Material.prototype);\nMeshBasicMaterial.prototype.constructor = MeshBasicMaterial;\nMeshBasicMaterial.prototype.isMeshBasicMaterial = true;\nMeshBasicMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  this.map = source.map;\n  this.lightMap = source.lightMap;\n  this.lightMapIntensity = source.lightMapIntensity;\n  this.aoMap = source.aoMap;\n  this.aoMapIntensity = source.aoMapIntensity;\n  this.specularMap = source.specularMap;\n  this.alphaMap = source.alphaMap;\n  this.envMap = source.envMap;\n  this.combine = source.combine;\n  this.reflectivity = source.reflectivity;\n  this.refractionRatio = source.refractionRatio;\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  this.wireframeLinecap = source.wireframeLinecap;\n  this.wireframeLinejoin = source.wireframeLinejoin;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  return this;\n};\nconst _vector$3 = new Vector3();\nconst _vector2$1 = new Vector2();\nfunction BufferAttribute(array, itemSize, normalized) {\n  if (Array.isArray(array)) {\n    throw new TypeError('THREE.BufferAttribute: array should be a Typed Array.');\n  }\n  this.name = '';\n  this.array = array;\n  this.itemSize = itemSize;\n  this.count = array !== undefined ? array.length / itemSize : 0;\n  this.normalized = normalized === true;\n  this.usage = StaticDrawUsage;\n  this.updateRange = {\n    offset: 0,\n    count: -1\n  };\n  this.version = 0;\n}\nObject.defineProperty(BufferAttribute.prototype, 'needsUpdate', {\n  set: function (value) {\n    if (value === true) this.version++;\n  }\n});\n_extends__default['default'](BufferAttribute.prototype, {\n  isBufferAttribute: true,\n  onUploadCallback: function () {},\n  setUsage: function (value) {\n    this.usage = value;\n    return this;\n  },\n  copy: function (source) {\n    this.name = source.name;\n    this.array = new source.array.constructor(source.array);\n    this.itemSize = source.itemSize;\n    this.count = source.count;\n    this.normalized = source.normalized;\n    this.usage = source.usage;\n    return this;\n  },\n  copyAt: function (index1, attribute, index2) {\n    index1 *= this.itemSize;\n    index2 *= attribute.itemSize;\n    for (let i = 0, l = this.itemSize; i < l; i++) {\n      this.array[index1 + i] = attribute.array[index2 + i];\n    }\n    return this;\n  },\n  copyArray: function (array) {\n    this.array.set(array);\n    return this;\n  },\n  copyColorsArray: function (colors) {\n    const array = this.array;\n    let offset = 0;\n    for (let i = 0, l = colors.length; i < l; i++) {\n      let color = colors[i];\n      if (color === undefined) {\n        console.warn('THREE.BufferAttribute.copyColorsArray(): color is undefined', i);\n        color = new Color();\n      }\n      array[offset++] = color.r;\n      array[offset++] = color.g;\n      array[offset++] = color.b;\n    }\n    return this;\n  },\n  copyVector2sArray: function (vectors) {\n    const array = this.array;\n    let offset = 0;\n    for (let i = 0, l = vectors.length; i < l; i++) {\n      let vector = vectors[i];\n      if (vector === undefined) {\n        console.warn('THREE.BufferAttribute.copyVector2sArray(): vector is undefined', i);\n        vector = new Vector2();\n      }\n      array[offset++] = vector.x;\n      array[offset++] = vector.y;\n    }\n    return this;\n  },\n  copyVector3sArray: function (vectors) {\n    const array = this.array;\n    let offset = 0;\n    for (let i = 0, l = vectors.length; i < l; i++) {\n      let vector = vectors[i];\n      if (vector === undefined) {\n        console.warn('THREE.BufferAttribute.copyVector3sArray(): vector is undefined', i);\n        vector = new Vector3();\n      }\n      array[offset++] = vector.x;\n      array[offset++] = vector.y;\n      array[offset++] = vector.z;\n    }\n    return this;\n  },\n  copyVector4sArray: function (vectors) {\n    const array = this.array;\n    let offset = 0;\n    for (let i = 0, l = vectors.length; i < l; i++) {\n      let vector = vectors[i];\n      if (vector === undefined) {\n        console.warn('THREE.BufferAttribute.copyVector4sArray(): vector is undefined', i);\n        vector = new Vector4();\n      }\n      array[offset++] = vector.x;\n      array[offset++] = vector.y;\n      array[offset++] = vector.z;\n      array[offset++] = vector.w;\n    }\n    return this;\n  },\n  applyMatrix3: function (m) {\n    if (this.itemSize === 2) {\n      for (let i = 0, l = this.count; i < l; i++) {\n        _vector2$1.fromBufferAttribute(this, i);\n        _vector2$1.applyMatrix3(m);\n        this.setXY(i, _vector2$1.x, _vector2$1.y);\n      }\n    } else if (this.itemSize === 3) {\n      for (let i = 0, l = this.count; i < l; i++) {\n        _vector$3.fromBufferAttribute(this, i);\n        _vector$3.applyMatrix3(m);\n        this.setXYZ(i, _vector$3.x, _vector$3.y, _vector$3.z);\n      }\n    }\n    return this;\n  },\n  applyMatrix4: function (m) {\n    for (let i = 0, l = this.count; i < l; i++) {\n      _vector$3.x = this.getX(i);\n      _vector$3.y = this.getY(i);\n      _vector$3.z = this.getZ(i);\n      _vector$3.applyMatrix4(m);\n      this.setXYZ(i, _vector$3.x, _vector$3.y, _vector$3.z);\n    }\n    return this;\n  },\n  applyNormalMatrix: function (m) {\n    for (let i = 0, l = this.count; i < l; i++) {\n      _vector$3.x = this.getX(i);\n      _vector$3.y = this.getY(i);\n      _vector$3.z = this.getZ(i);\n      _vector$3.applyNormalMatrix(m);\n      this.setXYZ(i, _vector$3.x, _vector$3.y, _vector$3.z);\n    }\n    return this;\n  },\n  transformDirection: function (m) {\n    for (let i = 0, l = this.count; i < l; i++) {\n      _vector$3.x = this.getX(i);\n      _vector$3.y = this.getY(i);\n      _vector$3.z = this.getZ(i);\n      _vector$3.transformDirection(m);\n      this.setXYZ(i, _vector$3.x, _vector$3.y, _vector$3.z);\n    }\n    return this;\n  },\n  set: function (value, offset = 0) {\n    this.array.set(value, offset);\n    return this;\n  },\n  getX: function (index) {\n    return this.array[index * this.itemSize];\n  },\n  setX: function (index, x) {\n    this.array[index * this.itemSize] = x;\n    return this;\n  },\n  getY: function (index) {\n    return this.array[index * this.itemSize + 1];\n  },\n  setY: function (index, y) {\n    this.array[index * this.itemSize + 1] = y;\n    return this;\n  },\n  getZ: function (index) {\n    return this.array[index * this.itemSize + 2];\n  },\n  setZ: function (index, z) {\n    this.array[index * this.itemSize + 2] = z;\n    return this;\n  },\n  getW: function (index) {\n    return this.array[index * this.itemSize + 3];\n  },\n  setW: function (index, w) {\n    this.array[index * this.itemSize + 3] = w;\n    return this;\n  },\n  setXY: function (index, x, y) {\n    index *= this.itemSize;\n    this.array[index + 0] = x;\n    this.array[index + 1] = y;\n    return this;\n  },\n  setXYZ: function (index, x, y, z) {\n    index *= this.itemSize;\n    this.array[index + 0] = x;\n    this.array[index + 1] = y;\n    this.array[index + 2] = z;\n    return this;\n  },\n  setXYZW: function (index, x, y, z, w) {\n    index *= this.itemSize;\n    this.array[index + 0] = x;\n    this.array[index + 1] = y;\n    this.array[index + 2] = z;\n    this.array[index + 3] = w;\n    return this;\n  },\n  onUpload: function (callback) {\n    this.onUploadCallback = callback;\n    return this;\n  },\n  clone: function () {\n    return new this.constructor(this.array, this.itemSize).copy(this);\n  },\n  toJSON: function () {\n    return {\n      itemSize: this.itemSize,\n      type: this.array.constructor.name,\n      array: Array.prototype.slice.call(this.array),\n      normalized: this.normalized\n    };\n  }\n});\n\n//\n\nfunction Int8BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Int8Array(array), itemSize, normalized);\n}\nInt8BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nInt8BufferAttribute.prototype.constructor = Int8BufferAttribute;\nfunction Uint8BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Uint8Array(array), itemSize, normalized);\n}\nUint8BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nUint8BufferAttribute.prototype.constructor = Uint8BufferAttribute;\nfunction Uint8ClampedBufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Uint8ClampedArray(array), itemSize, normalized);\n}\nUint8ClampedBufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nUint8ClampedBufferAttribute.prototype.constructor = Uint8ClampedBufferAttribute;\nfunction Int16BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Int16Array(array), itemSize, normalized);\n}\nInt16BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nInt16BufferAttribute.prototype.constructor = Int16BufferAttribute;\nfunction Uint16BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Uint16Array(array), itemSize, normalized);\n}\nUint16BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nUint16BufferAttribute.prototype.constructor = Uint16BufferAttribute;\nfunction Int32BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Int32Array(array), itemSize, normalized);\n}\nInt32BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nInt32BufferAttribute.prototype.constructor = Int32BufferAttribute;\nfunction Uint32BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Uint32Array(array), itemSize, normalized);\n}\nUint32BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nUint32BufferAttribute.prototype.constructor = Uint32BufferAttribute;\nfunction Float16BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Uint16Array(array), itemSize, normalized);\n}\nFloat16BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nFloat16BufferAttribute.prototype.constructor = Float16BufferAttribute;\nFloat16BufferAttribute.prototype.isFloat16BufferAttribute = true;\nfunction Float32BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Float32Array(array), itemSize, normalized);\n}\nFloat32BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nFloat32BufferAttribute.prototype.constructor = Float32BufferAttribute;\nfunction Float64BufferAttribute(array, itemSize, normalized) {\n  BufferAttribute.call(this, new Float64Array(array), itemSize, normalized);\n}\nFloat64BufferAttribute.prototype = Object.create(BufferAttribute.prototype);\nFloat64BufferAttribute.prototype.constructor = Float64BufferAttribute;\nfunction arrayMax(array) {\n  if (array.length === 0) return -Infinity;\n  let max = array[0];\n  for (let i = 1, l = array.length; i < l; ++i) {\n    if (array[i] > max) max = array[i];\n  }\n  return max;\n}\nconst TYPED_ARRAYS = {\n  Int8Array: Int8Array,\n  Uint8Array: Uint8Array,\n  // Workaround for IE11 pre KB2929437. See #11440\n  Uint8ClampedArray: typeof Uint8ClampedArray !== 'undefined' ? Uint8ClampedArray : Uint8Array,\n  Int16Array: Int16Array,\n  Uint16Array: Uint16Array,\n  Int32Array: Int32Array,\n  Uint32Array: Uint32Array,\n  Float32Array: Float32Array,\n  Float64Array: Float64Array\n};\nfunction getTypedArray(type, buffer) {\n  return new TYPED_ARRAYS[type](buffer);\n}\nlet _id = 0;\nconst _m1$2 = new Matrix4();\nconst _obj = new Object3D();\nconst _offset = new Vector3();\nconst _box$2 = new Box3();\nconst _boxMorphTargets = new Box3();\nconst _vector$4 = new Vector3();\nfunction BufferGeometry() {\n  Object.defineProperty(this, 'id', {\n    value: _id++\n  });\n  this.uuid = MathUtils.generateUUID();\n  this.name = '';\n  this.type = 'BufferGeometry';\n  this.index = null;\n  this.attributes = {};\n  this.morphAttributes = {};\n  this.morphTargetsRelative = false;\n  this.groups = [];\n  this.boundingBox = null;\n  this.boundingSphere = null;\n  this.drawRange = {\n    start: 0,\n    count: Infinity\n  };\n  this.userData = {};\n}\nBufferGeometry.prototype = _extends__default['default'](Object.create(EventDispatcher.prototype), {\n  constructor: BufferGeometry,\n  isBufferGeometry: true,\n  getIndex: function () {\n    return this.index;\n  },\n  setIndex: function (index) {\n    if (Array.isArray(index)) {\n      this.index = new (arrayMax(index) > 65535 ? Uint32BufferAttribute : Uint16BufferAttribute)(index, 1);\n    } else {\n      this.index = index;\n    }\n    return this;\n  },\n  getAttribute: function (name) {\n    return this.attributes[name];\n  },\n  setAttribute: function (name, attribute) {\n    this.attributes[name] = attribute;\n    return this;\n  },\n  deleteAttribute: function (name) {\n    delete this.attributes[name];\n    return this;\n  },\n  hasAttribute: function (name) {\n    return this.attributes[name] !== undefined;\n  },\n  addGroup: function (start, count, materialIndex = 0) {\n    this.groups.push({\n      start: start,\n      count: count,\n      materialIndex: materialIndex\n    });\n  },\n  clearGroups: function () {\n    this.groups = [];\n  },\n  setDrawRange: function (start, count) {\n    this.drawRange.start = start;\n    this.drawRange.count = count;\n  },\n  applyMatrix4: function (matrix) {\n    const position = this.attributes.position;\n    if (position !== undefined) {\n      position.applyMatrix4(matrix);\n      position.needsUpdate = true;\n    }\n    const normal = this.attributes.normal;\n    if (normal !== undefined) {\n      const normalMatrix = new Matrix3().getNormalMatrix(matrix);\n      normal.applyNormalMatrix(normalMatrix);\n      normal.needsUpdate = true;\n    }\n    const tangent = this.attributes.tangent;\n    if (tangent !== undefined) {\n      tangent.transformDirection(matrix);\n      tangent.needsUpdate = true;\n    }\n    if (this.boundingBox !== null) {\n      this.computeBoundingBox();\n    }\n    if (this.boundingSphere !== null) {\n      this.computeBoundingSphere();\n    }\n    return this;\n  },\n  rotateX: function (angle) {\n    // rotate geometry around world x-axis\n\n    _m1$2.makeRotationX(angle);\n    this.applyMatrix4(_m1$2);\n    return this;\n  },\n  rotateY: function (angle) {\n    // rotate geometry around world y-axis\n\n    _m1$2.makeRotationY(angle);\n    this.applyMatrix4(_m1$2);\n    return this;\n  },\n  rotateZ: function (angle) {\n    // rotate geometry around world z-axis\n\n    _m1$2.makeRotationZ(angle);\n    this.applyMatrix4(_m1$2);\n    return this;\n  },\n  translate: function (x, y, z) {\n    // translate geometry\n\n    _m1$2.makeTranslation(x, y, z);\n    this.applyMatrix4(_m1$2);\n    return this;\n  },\n  scale: function (x, y, z) {\n    // scale geometry\n\n    _m1$2.makeScale(x, y, z);\n    this.applyMatrix4(_m1$2);\n    return this;\n  },\n  lookAt: function (vector) {\n    _obj.lookAt(vector);\n    _obj.updateMatrix();\n    this.applyMatrix4(_obj.matrix);\n    return this;\n  },\n  center: function () {\n    this.computeBoundingBox();\n    this.boundingBox.getCenter(_offset).negate();\n    this.translate(_offset.x, _offset.y, _offset.z);\n    return this;\n  },\n  setFromPoints: function (points) {\n    const position = [];\n    for (let i = 0, l = points.length; i < l; i++) {\n      const point = points[i];\n      position.push(point.x, point.y, point.z || 0);\n    }\n    this.setAttribute('position', new Float32BufferAttribute(position, 3));\n    return this;\n  },\n  computeBoundingBox: function () {\n    if (this.boundingBox === null) {\n      this.boundingBox = new Box3();\n    }\n    const position = this.attributes.position;\n    const morphAttributesPosition = this.morphAttributes.position;\n    if (position && position.isGLBufferAttribute) {\n      console.error('THREE.BufferGeometry.computeBoundingBox(): GLBufferAttribute requires a manual bounding box. Alternatively set \"mesh.frustumCulled\" to \"false\".', this);\n      this.boundingBox.set(new Vector3(-Infinity, -Infinity, -Infinity), new Vector3(+Infinity, +Infinity, +Infinity));\n      return;\n    }\n    if (position !== undefined) {\n      this.boundingBox.setFromBufferAttribute(position);\n\n      // process morph attributes if present\n\n      if (morphAttributesPosition) {\n        for (let i = 0, il = morphAttributesPosition.length; i < il; i++) {\n          const morphAttribute = morphAttributesPosition[i];\n          _box$2.setFromBufferAttribute(morphAttribute);\n          if (this.morphTargetsRelative) {\n            _vector$4.addVectors(this.boundingBox.min, _box$2.min);\n            this.boundingBox.expandByPoint(_vector$4);\n            _vector$4.addVectors(this.boundingBox.max, _box$2.max);\n            this.boundingBox.expandByPoint(_vector$4);\n          } else {\n            this.boundingBox.expandByPoint(_box$2.min);\n            this.boundingBox.expandByPoint(_box$2.max);\n          }\n        }\n      }\n    } else {\n      this.boundingBox.makeEmpty();\n    }\n    if (isNaN(this.boundingBox.min.x) || isNaN(this.boundingBox.min.y) || isNaN(this.boundingBox.min.z)) {\n      console.error('THREE.BufferGeometry.computeBoundingBox(): Computed min/max have NaN values. The \"position\" attribute is likely to have NaN values.', this);\n    }\n  },\n  computeBoundingSphere: function () {\n    if (this.boundingSphere === null) {\n      this.boundingSphere = new Sphere();\n    }\n    const position = this.attributes.position;\n    const morphAttributesPosition = this.morphAttributes.position;\n    if (position && position.isGLBufferAttribute) {\n      console.error('THREE.BufferGeometry.computeBoundingSphere(): GLBufferAttribute requires a manual bounding sphere. Alternatively set \"mesh.frustumCulled\" to \"false\".', this);\n      this.boundingSphere.set(new Vector3(), Infinity);\n      return;\n    }\n    if (position) {\n      // first, find the center of the bounding sphere\n\n      const center = this.boundingSphere.center;\n      _box$2.setFromBufferAttribute(position);\n\n      // process morph attributes if present\n\n      if (morphAttributesPosition) {\n        for (let i = 0, il = morphAttributesPosition.length; i < il; i++) {\n          const morphAttribute = morphAttributesPosition[i];\n          _boxMorphTargets.setFromBufferAttribute(morphAttribute);\n          if (this.morphTargetsRelative) {\n            _vector$4.addVectors(_box$2.min, _boxMorphTargets.min);\n            _box$2.expandByPoint(_vector$4);\n            _vector$4.addVectors(_box$2.max, _boxMorphTargets.max);\n            _box$2.expandByPoint(_vector$4);\n          } else {\n            _box$2.expandByPoint(_boxMorphTargets.min);\n            _box$2.expandByPoint(_boxMorphTargets.max);\n          }\n        }\n      }\n      _box$2.getCenter(center);\n\n      // second, try to find a boundingSphere with a radius smaller than the\n      // boundingSphere of the boundingBox: sqrt(3) smaller in the best case\n\n      let maxRadiusSq = 0;\n      for (let i = 0, il = position.count; i < il; i++) {\n        _vector$4.fromBufferAttribute(position, i);\n        maxRadiusSq = Math.max(maxRadiusSq, center.distanceToSquared(_vector$4));\n      }\n\n      // process morph attributes if present\n\n      if (morphAttributesPosition) {\n        for (let i = 0, il = morphAttributesPosition.length; i < il; i++) {\n          const morphAttribute = morphAttributesPosition[i];\n          const morphTargetsRelative = this.morphTargetsRelative;\n          for (let j = 0, jl = morphAttribute.count; j < jl; j++) {\n            _vector$4.fromBufferAttribute(morphAttribute, j);\n            if (morphTargetsRelative) {\n              _offset.fromBufferAttribute(position, j);\n              _vector$4.add(_offset);\n            }\n            maxRadiusSq = Math.max(maxRadiusSq, center.distanceToSquared(_vector$4));\n          }\n        }\n      }\n      this.boundingSphere.radius = Math.sqrt(maxRadiusSq);\n      if (isNaN(this.boundingSphere.radius)) {\n        console.error('THREE.BufferGeometry.computeBoundingSphere(): Computed radius is NaN. The \"position\" attribute is likely to have NaN values.', this);\n      }\n    }\n  },\n  computeFaceNormals: function () {\n\n    // backwards compatibility\n  },\n  computeTangents: function () {\n    const index = this.index;\n    const attributes = this.attributes;\n\n    // based on http://www.terathon.com/code/tangent.html\n    // (per vertex tangents)\n\n    if (index === null || attributes.position === undefined || attributes.normal === undefined || attributes.uv === undefined) {\n      console.error('THREE.BufferGeometry: .computeTangents() failed. Missing required attributes (index, position, normal or uv)');\n      return;\n    }\n    const indices = index.array;\n    const positions = attributes.position.array;\n    const normals = attributes.normal.array;\n    const uvs = attributes.uv.array;\n    const nVertices = positions.length / 3;\n    if (attributes.tangent === undefined) {\n      this.setAttribute('tangent', new BufferAttribute(new Float32Array(4 * nVertices), 4));\n    }\n    const tangents = attributes.tangent.array;\n    const tan1 = [],\n      tan2 = [];\n    for (let i = 0; i < nVertices; i++) {\n      tan1[i] = new Vector3();\n      tan2[i] = new Vector3();\n    }\n    const vA = new Vector3(),\n      vB = new Vector3(),\n      vC = new Vector3(),\n      uvA = new Vector2(),\n      uvB = new Vector2(),\n      uvC = new Vector2(),\n      sdir = new Vector3(),\n      tdir = new Vector3();\n    function handleTriangle(a, b, c) {\n      vA.fromArray(positions, a * 3);\n      vB.fromArray(positions, b * 3);\n      vC.fromArray(positions, c * 3);\n      uvA.fromArray(uvs, a * 2);\n      uvB.fromArray(uvs, b * 2);\n      uvC.fromArray(uvs, c * 2);\n      vB.sub(vA);\n      vC.sub(vA);\n      uvB.sub(uvA);\n      uvC.sub(uvA);\n      const r = 1.0 / (uvB.x * uvC.y - uvC.x * uvB.y);\n\n      // silently ignore degenerate uv triangles having coincident or colinear vertices\n\n      if (!isFinite(r)) return;\n      sdir.copy(vB).multiplyScalar(uvC.y).addScaledVector(vC, -uvB.y).multiplyScalar(r);\n      tdir.copy(vC).multiplyScalar(uvB.x).addScaledVector(vB, -uvC.x).multiplyScalar(r);\n      tan1[a].add(sdir);\n      tan1[b].add(sdir);\n      tan1[c].add(sdir);\n      tan2[a].add(tdir);\n      tan2[b].add(tdir);\n      tan2[c].add(tdir);\n    }\n    let groups = this.groups;\n    if (groups.length === 0) {\n      groups = [{\n        start: 0,\n        count: indices.length\n      }];\n    }\n    for (let i = 0, il = groups.length; i < il; ++i) {\n      const group = groups[i];\n      const start = group.start;\n      const count = group.count;\n      for (let j = start, jl = start + count; j < jl; j += 3) {\n        handleTriangle(indices[j + 0], indices[j + 1], indices[j + 2]);\n      }\n    }\n    const tmp = new Vector3(),\n      tmp2 = new Vector3();\n    const n = new Vector3(),\n      n2 = new Vector3();\n    function handleVertex(v) {\n      n.fromArray(normals, v * 3);\n      n2.copy(n);\n      const t = tan1[v];\n\n      // Gram-Schmidt orthogonalize\n\n      tmp.copy(t);\n      tmp.sub(n.multiplyScalar(n.dot(t))).normalize();\n\n      // Calculate handedness\n\n      tmp2.crossVectors(n2, t);\n      const test = tmp2.dot(tan2[v]);\n      const w = test < 0.0 ? -1.0 : 1.0;\n      tangents[v * 4] = tmp.x;\n      tangents[v * 4 + 1] = tmp.y;\n      tangents[v * 4 + 2] = tmp.z;\n      tangents[v * 4 + 3] = w;\n    }\n    for (let i = 0, il = groups.length; i < il; ++i) {\n      const group = groups[i];\n      const start = group.start;\n      const count = group.count;\n      for (let j = start, jl = start + count; j < jl; j += 3) {\n        handleVertex(indices[j + 0]);\n        handleVertex(indices[j + 1]);\n        handleVertex(indices[j + 2]);\n      }\n    }\n  },\n  computeVertexNormals: function () {\n    const index = this.index;\n    const positionAttribute = this.getAttribute('position');\n    if (positionAttribute !== undefined) {\n      let normalAttribute = this.getAttribute('normal');\n      if (normalAttribute === undefined) {\n        normalAttribute = new BufferAttribute(new Float32Array(positionAttribute.count * 3), 3);\n        this.setAttribute('normal', normalAttribute);\n      } else {\n        // reset existing normals to zero\n\n        for (let i = 0, il = normalAttribute.count; i < il; i++) {\n          normalAttribute.setXYZ(i, 0, 0, 0);\n        }\n      }\n      const pA = new Vector3(),\n        pB = new Vector3(),\n        pC = new Vector3();\n      const nA = new Vector3(),\n        nB = new Vector3(),\n        nC = new Vector3();\n      const cb = new Vector3(),\n        ab = new Vector3();\n\n      // indexed elements\n\n      if (index) {\n        for (let i = 0, il = index.count; i < il; i += 3) {\n          const vA = index.getX(i + 0);\n          const vB = index.getX(i + 1);\n          const vC = index.getX(i + 2);\n          pA.fromBufferAttribute(positionAttribute, vA);\n          pB.fromBufferAttribute(positionAttribute, vB);\n          pC.fromBufferAttribute(positionAttribute, vC);\n          cb.subVectors(pC, pB);\n          ab.subVectors(pA, pB);\n          cb.cross(ab);\n          nA.fromBufferAttribute(normalAttribute, vA);\n          nB.fromBufferAttribute(normalAttribute, vB);\n          nC.fromBufferAttribute(normalAttribute, vC);\n          nA.add(cb);\n          nB.add(cb);\n          nC.add(cb);\n          normalAttribute.setXYZ(vA, nA.x, nA.y, nA.z);\n          normalAttribute.setXYZ(vB, nB.x, nB.y, nB.z);\n          normalAttribute.setXYZ(vC, nC.x, nC.y, nC.z);\n        }\n      } else {\n        // non-indexed elements (unconnected triangle soup)\n\n        for (let i = 0, il = positionAttribute.count; i < il; i += 3) {\n          pA.fromBufferAttribute(positionAttribute, i + 0);\n          pB.fromBufferAttribute(positionAttribute, i + 1);\n          pC.fromBufferAttribute(positionAttribute, i + 2);\n          cb.subVectors(pC, pB);\n          ab.subVectors(pA, pB);\n          cb.cross(ab);\n          normalAttribute.setXYZ(i + 0, cb.x, cb.y, cb.z);\n          normalAttribute.setXYZ(i + 1, cb.x, cb.y, cb.z);\n          normalAttribute.setXYZ(i + 2, cb.x, cb.y, cb.z);\n        }\n      }\n      this.normalizeNormals();\n      normalAttribute.needsUpdate = true;\n    }\n  },\n  merge: function (geometry, offset) {\n    if (!(geometry && geometry.isBufferGeometry)) {\n      console.error('THREE.BufferGeometry.merge(): geometry not an instance of THREE.BufferGeometry.', geometry);\n      return;\n    }\n    if (offset === undefined) {\n      offset = 0;\n      console.warn('THREE.BufferGeometry.merge(): Overwriting original geometry, starting at offset=0. ' + 'Use BufferGeometryUtils.mergeBufferGeometries() for lossless merge.');\n    }\n    const attributes = this.attributes;\n    for (const key in attributes) {\n      if (geometry.attributes[key] === undefined) continue;\n      const attribute1 = attributes[key];\n      const attributeArray1 = attribute1.array;\n      const attribute2 = geometry.attributes[key];\n      const attributeArray2 = attribute2.array;\n      const attributeOffset = attribute2.itemSize * offset;\n      const length = Math.min(attributeArray2.length, attributeArray1.length - attributeOffset);\n      for (let i = 0, j = attributeOffset; i < length; i++, j++) {\n        attributeArray1[j] = attributeArray2[i];\n      }\n    }\n    return this;\n  },\n  normalizeNormals: function () {\n    const normals = this.attributes.normal;\n    for (let i = 0, il = normals.count; i < il; i++) {\n      _vector$4.fromBufferAttribute(normals, i);\n      _vector$4.normalize();\n      normals.setXYZ(i, _vector$4.x, _vector$4.y, _vector$4.z);\n    }\n  },\n  toNonIndexed: function () {\n    function convertBufferAttribute(attribute, indices) {\n      const array = attribute.array;\n      const itemSize = attribute.itemSize;\n      const normalized = attribute.normalized;\n      const array2 = new array.constructor(indices.length * itemSize);\n      let index = 0,\n        index2 = 0;\n      for (let i = 0, l = indices.length; i < l; i++) {\n        index = indices[i] * itemSize;\n        for (let j = 0; j < itemSize; j++) {\n          array2[index2++] = array[index++];\n        }\n      }\n      return new BufferAttribute(array2, itemSize, normalized);\n    }\n\n    //\n\n    if (this.index === null) {\n      console.warn('THREE.BufferGeometry.toNonIndexed(): BufferGeometry is already non-indexed.');\n      return this;\n    }\n    const geometry2 = new BufferGeometry();\n    const indices = this.index.array;\n    const attributes = this.attributes;\n\n    // attributes\n\n    for (const name in attributes) {\n      const attribute = attributes[name];\n      const newAttribute = convertBufferAttribute(attribute, indices);\n      geometry2.setAttribute(name, newAttribute);\n    }\n\n    // morph attributes\n\n    const morphAttributes = this.morphAttributes;\n    for (const name in morphAttributes) {\n      const morphArray = [];\n      const morphAttribute = morphAttributes[name]; // morphAttribute: array of Float32BufferAttributes\n\n      for (let i = 0, il = morphAttribute.length; i < il; i++) {\n        const attribute = morphAttribute[i];\n        const newAttribute = convertBufferAttribute(attribute, indices);\n        morphArray.push(newAttribute);\n      }\n      geometry2.morphAttributes[name] = morphArray;\n    }\n    geometry2.morphTargetsRelative = this.morphTargetsRelative;\n\n    // groups\n\n    const groups = this.groups;\n    for (let i = 0, l = groups.length; i < l; i++) {\n      const group = groups[i];\n      geometry2.addGroup(group.start, group.count, group.materialIndex);\n    }\n    return geometry2;\n  },\n  toJSON: function () {\n    const data = {\n      metadata: {\n        version: 4.5,\n        type: 'BufferGeometry',\n        generator: 'BufferGeometry.toJSON'\n      }\n    };\n\n    // standard BufferGeometry serialization\n\n    data.uuid = this.uuid;\n    data.type = this.type;\n    if (this.name !== '') data.name = this.name;\n    if (Object.keys(this.userData).length > 0) data.userData = this.userData;\n    if (this.parameters !== undefined) {\n      const parameters = this.parameters;\n      for (const key in parameters) {\n        if (parameters[key] !== undefined) data[key] = parameters[key];\n      }\n      return data;\n    }\n    data.data = {\n      attributes: {}\n    };\n    const index = this.index;\n    if (index !== null) {\n      data.data.index = {\n        type: index.array.constructor.name,\n        array: Array.prototype.slice.call(index.array)\n      };\n    }\n    const attributes = this.attributes;\n    for (const key in attributes) {\n      const attribute = attributes[key];\n      const attributeData = attribute.toJSON(data.data);\n      if (attribute.name !== '') attributeData.name = attribute.name;\n      data.data.attributes[key] = attributeData;\n    }\n    const morphAttributes = {};\n    let hasMorphAttributes = false;\n    for (const key in this.morphAttributes) {\n      const attributeArray = this.morphAttributes[key];\n      const array = [];\n      for (let i = 0, il = attributeArray.length; i < il; i++) {\n        const attribute = attributeArray[i];\n        const attributeData = attribute.toJSON(data.data);\n        if (attribute.name !== '') attributeData.name = attribute.name;\n        array.push(attributeData);\n      }\n      if (array.length > 0) {\n        morphAttributes[key] = array;\n        hasMorphAttributes = true;\n      }\n    }\n    if (hasMorphAttributes) {\n      data.data.morphAttributes = morphAttributes;\n      data.data.morphTargetsRelative = this.morphTargetsRelative;\n    }\n    const groups = this.groups;\n    if (groups.length > 0) {\n      data.data.groups = JSON.parse(JSON.stringify(groups));\n    }\n    const boundingSphere = this.boundingSphere;\n    if (boundingSphere !== null) {\n      data.data.boundingSphere = {\n        center: boundingSphere.center.toArray(),\n        radius: boundingSphere.radius\n      };\n    }\n    return data;\n  },\n  clone: function () {\n    /*\n     // Handle primitives\n    \t const parameters = this.parameters;\n    \t if ( parameters !== undefined ) {\n    \t const values = [];\n    \t for ( const key in parameters ) {\n    \t values.push( parameters[ key ] );\n    \t }\n    \t const geometry = Object.create( this.constructor.prototype );\n     this.constructor.apply( geometry, values );\n     return geometry;\n    \t }\n    \t return new this.constructor().copy( this );\n     */\n\n    return new BufferGeometry().copy(this);\n  },\n  copy: function (source) {\n    // reset\n\n    this.index = null;\n    this.attributes = {};\n    this.morphAttributes = {};\n    this.groups = [];\n    this.boundingBox = null;\n    this.boundingSphere = null;\n\n    // used for storing cloned, shared data\n\n    const data = {};\n\n    // name\n\n    this.name = source.name;\n\n    // index\n\n    const index = source.index;\n    if (index !== null) {\n      this.setIndex(index.clone(data));\n    }\n\n    // attributes\n\n    const attributes = source.attributes;\n    for (const name in attributes) {\n      const attribute = attributes[name];\n      this.setAttribute(name, attribute.clone(data));\n    }\n\n    // morph attributes\n\n    const morphAttributes = source.morphAttributes;\n    for (const name in morphAttributes) {\n      const array = [];\n      const morphAttribute = morphAttributes[name]; // morphAttribute: array of Float32BufferAttributes\n\n      for (let i = 0, l = morphAttribute.length; i < l; i++) {\n        array.push(morphAttribute[i].clone(data));\n      }\n      this.morphAttributes[name] = array;\n    }\n    this.morphTargetsRelative = source.morphTargetsRelative;\n\n    // groups\n\n    const groups = source.groups;\n    for (let i = 0, l = groups.length; i < l; i++) {\n      const group = groups[i];\n      this.addGroup(group.start, group.count, group.materialIndex);\n    }\n\n    // bounding box\n\n    const boundingBox = source.boundingBox;\n    if (boundingBox !== null) {\n      this.boundingBox = boundingBox.clone();\n    }\n\n    // bounding sphere\n\n    const boundingSphere = source.boundingSphere;\n    if (boundingSphere !== null) {\n      this.boundingSphere = boundingSphere.clone();\n    }\n\n    // draw range\n\n    this.drawRange.start = source.drawRange.start;\n    this.drawRange.count = source.drawRange.count;\n\n    // user data\n\n    this.userData = source.userData;\n    return this;\n  },\n  dispose: function () {\n    this.dispatchEvent({\n      type: 'dispose'\n    });\n  }\n});\nconst _inverseMatrix = new Matrix4();\nconst _ray = new Ray();\nconst _sphere = new Sphere();\nconst _vA = new Vector3();\nconst _vB = new Vector3();\nconst _vC = new Vector3();\nconst _tempA = new Vector3();\nconst _tempB = new Vector3();\nconst _tempC = new Vector3();\nconst _morphA = new Vector3();\nconst _morphB = new Vector3();\nconst _morphC = new Vector3();\nconst _uvA = new Vector2();\nconst _uvB = new Vector2();\nconst _uvC = new Vector2();\nconst _intersectionPoint = new Vector3();\nconst _intersectionPointWorld = new Vector3();\nfunction Mesh(geometry = new BufferGeometry(), material = new MeshBasicMaterial()) {\n  Object3D.call(this);\n  this.type = 'Mesh';\n  this.geometry = geometry;\n  this.material = material;\n  this.updateMorphTargets();\n}\nMesh.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Mesh,\n  isMesh: true,\n  copy: function (source) {\n    Object3D.prototype.copy.call(this, source);\n    if (source.morphTargetInfluences !== undefined) {\n      this.morphTargetInfluences = source.morphTargetInfluences.slice();\n    }\n    if (source.morphTargetDictionary !== undefined) {\n      this.morphTargetDictionary = _extends__default['default']({}, source.morphTargetDictionary);\n    }\n    this.material = source.material;\n    this.geometry = source.geometry;\n    return this;\n  },\n  updateMorphTargets: function () {\n    const geometry = this.geometry;\n    if (geometry.isBufferGeometry) {\n      const morphAttributes = geometry.morphAttributes;\n      const keys = Object.keys(morphAttributes);\n      if (keys.length > 0) {\n        const morphAttribute = morphAttributes[keys[0]];\n        if (morphAttribute !== undefined) {\n          this.morphTargetInfluences = [];\n          this.morphTargetDictionary = {};\n          for (let m = 0, ml = morphAttribute.length; m < ml; m++) {\n            const name = morphAttribute[m].name || String(m);\n            this.morphTargetInfluences.push(0);\n            this.morphTargetDictionary[name] = m;\n          }\n        }\n      }\n    } else {\n      const morphTargets = geometry.morphTargets;\n      if (morphTargets !== undefined && morphTargets.length > 0) {\n        console.error('THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.');\n      }\n    }\n  },\n  raycast: function (raycaster, intersects) {\n    const geometry = this.geometry;\n    const material = this.material;\n    const matrixWorld = this.matrixWorld;\n    if (material === undefined) return;\n\n    // Checking boundingSphere distance to ray\n\n    if (geometry.boundingSphere === null) geometry.computeBoundingSphere();\n    _sphere.copy(geometry.boundingSphere);\n    _sphere.applyMatrix4(matrixWorld);\n    if (raycaster.ray.intersectsSphere(_sphere) === false) return;\n\n    //\n\n    _inverseMatrix.copy(matrixWorld).invert();\n    _ray.copy(raycaster.ray).applyMatrix4(_inverseMatrix);\n\n    // Check boundingBox before continuing\n\n    if (geometry.boundingBox !== null) {\n      if (_ray.intersectsBox(geometry.boundingBox) === false) return;\n    }\n    let intersection;\n    if (geometry.isBufferGeometry) {\n      const index = geometry.index;\n      const position = geometry.attributes.position;\n      const morphPosition = geometry.morphAttributes.position;\n      const morphTargetsRelative = geometry.morphTargetsRelative;\n      const uv = geometry.attributes.uv;\n      const uv2 = geometry.attributes.uv2;\n      const groups = geometry.groups;\n      const drawRange = geometry.drawRange;\n      if (index !== null) {\n        // indexed buffer geometry\n\n        if (Array.isArray(material)) {\n          for (let i = 0, il = groups.length; i < il; i++) {\n            const group = groups[i];\n            const groupMaterial = material[group.materialIndex];\n            const start = Math.max(group.start, drawRange.start);\n            const end = Math.min(group.start + group.count, drawRange.start + drawRange.count);\n            for (let j = start, jl = end; j < jl; j += 3) {\n              const a = index.getX(j);\n              const b = index.getX(j + 1);\n              const c = index.getX(j + 2);\n              intersection = checkBufferGeometryIntersection(this, groupMaterial, raycaster, _ray, position, morphPosition, morphTargetsRelative, uv, uv2, a, b, c);\n              if (intersection) {\n                intersection.faceIndex = Math.floor(j / 3); // triangle number in indexed buffer semantics\n                intersection.face.materialIndex = group.materialIndex;\n                intersects.push(intersection);\n              }\n            }\n          }\n        } else {\n          const start = Math.max(0, drawRange.start);\n          const end = Math.min(index.count, drawRange.start + drawRange.count);\n          for (let i = start, il = end; i < il; i += 3) {\n            const a = index.getX(i);\n            const b = index.getX(i + 1);\n            const c = index.getX(i + 2);\n            intersection = checkBufferGeometryIntersection(this, material, raycaster, _ray, position, morphPosition, morphTargetsRelative, uv, uv2, a, b, c);\n            if (intersection) {\n              intersection.faceIndex = Math.floor(i / 3); // triangle number in indexed buffer semantics\n              intersects.push(intersection);\n            }\n          }\n        }\n      } else if (position !== undefined) {\n        // non-indexed buffer geometry\n\n        if (Array.isArray(material)) {\n          for (let i = 0, il = groups.length; i < il; i++) {\n            const group = groups[i];\n            const groupMaterial = material[group.materialIndex];\n            const start = Math.max(group.start, drawRange.start);\n            const end = Math.min(group.start + group.count, drawRange.start + drawRange.count);\n            for (let j = start, jl = end; j < jl; j += 3) {\n              const a = j;\n              const b = j + 1;\n              const c = j + 2;\n              intersection = checkBufferGeometryIntersection(this, groupMaterial, raycaster, _ray, position, morphPosition, morphTargetsRelative, uv, uv2, a, b, c);\n              if (intersection) {\n                intersection.faceIndex = Math.floor(j / 3); // triangle number in non-indexed buffer semantics\n                intersection.face.materialIndex = group.materialIndex;\n                intersects.push(intersection);\n              }\n            }\n          }\n        } else {\n          const start = Math.max(0, drawRange.start);\n          const end = Math.min(position.count, drawRange.start + drawRange.count);\n          for (let i = start, il = end; i < il; i += 3) {\n            const a = i;\n            const b = i + 1;\n            const c = i + 2;\n            intersection = checkBufferGeometryIntersection(this, material, raycaster, _ray, position, morphPosition, morphTargetsRelative, uv, uv2, a, b, c);\n            if (intersection) {\n              intersection.faceIndex = Math.floor(i / 3); // triangle number in non-indexed buffer semantics\n              intersects.push(intersection);\n            }\n          }\n        }\n      }\n    } else if (geometry.isGeometry) {\n      console.error('THREE.Mesh.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.');\n    }\n  }\n});\nfunction checkIntersection(object, material, raycaster, ray, pA, pB, pC, point) {\n  let intersect;\n  if (material.side === BackSide) {\n    intersect = ray.intersectTriangle(pC, pB, pA, true, point);\n  } else {\n    intersect = ray.intersectTriangle(pA, pB, pC, material.side !== DoubleSide, point);\n  }\n  if (intersect === null) return null;\n  _intersectionPointWorld.copy(point);\n  _intersectionPointWorld.applyMatrix4(object.matrixWorld);\n  const distance = raycaster.ray.origin.distanceTo(_intersectionPointWorld);\n  if (distance < raycaster.near || distance > raycaster.far) return null;\n  return {\n    distance: distance,\n    point: _intersectionPointWorld.clone(),\n    object: object\n  };\n}\nfunction checkBufferGeometryIntersection(object, material, raycaster, ray, position, morphPosition, morphTargetsRelative, uv, uv2, a, b, c) {\n  _vA.fromBufferAttribute(position, a);\n  _vB.fromBufferAttribute(position, b);\n  _vC.fromBufferAttribute(position, c);\n  const morphInfluences = object.morphTargetInfluences;\n  if (material.morphTargets && morphPosition && morphInfluences) {\n    _morphA.set(0, 0, 0);\n    _morphB.set(0, 0, 0);\n    _morphC.set(0, 0, 0);\n    for (let i = 0, il = morphPosition.length; i < il; i++) {\n      const influence = morphInfluences[i];\n      const morphAttribute = morphPosition[i];\n      if (influence === 0) continue;\n      _tempA.fromBufferAttribute(morphAttribute, a);\n      _tempB.fromBufferAttribute(morphAttribute, b);\n      _tempC.fromBufferAttribute(morphAttribute, c);\n      if (morphTargetsRelative) {\n        _morphA.addScaledVector(_tempA, influence);\n        _morphB.addScaledVector(_tempB, influence);\n        _morphC.addScaledVector(_tempC, influence);\n      } else {\n        _morphA.addScaledVector(_tempA.sub(_vA), influence);\n        _morphB.addScaledVector(_tempB.sub(_vB), influence);\n        _morphC.addScaledVector(_tempC.sub(_vC), influence);\n      }\n    }\n    _vA.add(_morphA);\n    _vB.add(_morphB);\n    _vC.add(_morphC);\n  }\n  if (object.isSkinnedMesh) {\n    object.boneTransform(a, _vA);\n    object.boneTransform(b, _vB);\n    object.boneTransform(c, _vC);\n  }\n  const intersection = checkIntersection(object, material, raycaster, ray, _vA, _vB, _vC, _intersectionPoint);\n  if (intersection) {\n    if (uv) {\n      _uvA.fromBufferAttribute(uv, a);\n      _uvB.fromBufferAttribute(uv, b);\n      _uvC.fromBufferAttribute(uv, c);\n      intersection.uv = Triangle.getUV(_intersectionPoint, _vA, _vB, _vC, _uvA, _uvB, _uvC, new Vector2());\n    }\n    if (uv2) {\n      _uvA.fromBufferAttribute(uv2, a);\n      _uvB.fromBufferAttribute(uv2, b);\n      _uvC.fromBufferAttribute(uv2, c);\n      intersection.uv2 = Triangle.getUV(_intersectionPoint, _vA, _vB, _vC, _uvA, _uvB, _uvC, new Vector2());\n    }\n    const face = new Face3(a, b, c);\n    Triangle.getNormal(_vA, _vB, _vC, face.normal);\n    intersection.face = face;\n  }\n  return intersection;\n}\nclass BoxGeometry extends BufferGeometry {\n  constructor(width = 1, height = 1, depth = 1, widthSegments = 1, heightSegments = 1, depthSegments = 1) {\n    super();\n    this.type = 'BoxGeometry';\n    this.parameters = {\n      width: width,\n      height: height,\n      depth: depth,\n      widthSegments: widthSegments,\n      heightSegments: heightSegments,\n      depthSegments: depthSegments\n    };\n    const scope = this;\n\n    // segments\n\n    widthSegments = Math.floor(widthSegments);\n    heightSegments = Math.floor(heightSegments);\n    depthSegments = Math.floor(depthSegments);\n\n    // buffers\n\n    const indices = [];\n    const vertices = [];\n    const normals = [];\n    const uvs = [];\n\n    // helper variables\n\n    let numberOfVertices = 0;\n    let groupStart = 0;\n\n    // build each side of the box geometry\n\n    buildPlane('z', 'y', 'x', -1, -1, depth, height, width, depthSegments, heightSegments, 0); // px\n    buildPlane('z', 'y', 'x', 1, -1, depth, height, -width, depthSegments, heightSegments, 1); // nx\n    buildPlane('x', 'z', 'y', 1, 1, width, depth, height, widthSegments, depthSegments, 2); // py\n    buildPlane('x', 'z', 'y', 1, -1, width, depth, -height, widthSegments, depthSegments, 3); // ny\n    buildPlane('x', 'y', 'z', 1, -1, width, height, depth, widthSegments, heightSegments, 4); // pz\n    buildPlane('x', 'y', 'z', -1, -1, width, height, -depth, widthSegments, heightSegments, 5); // nz\n\n    // build geometry\n\n    this.setIndex(indices);\n    this.setAttribute('position', new Float32BufferAttribute(vertices, 3));\n    this.setAttribute('normal', new Float32BufferAttribute(normals, 3));\n    this.setAttribute('uv', new Float32BufferAttribute(uvs, 2));\n    function buildPlane(u, v, w, udir, vdir, width, height, depth, gridX, gridY, materialIndex) {\n      const segmentWidth = width / gridX;\n      const segmentHeight = height / gridY;\n      const widthHalf = width / 2;\n      const heightHalf = height / 2;\n      const depthHalf = depth / 2;\n      const gridX1 = gridX + 1;\n      const gridY1 = gridY + 1;\n      let vertexCounter = 0;\n      let groupCount = 0;\n      const vector = new Vector3();\n\n      // generate vertices, normals and uvs\n\n      for (let iy = 0; iy < gridY1; iy++) {\n        const y = iy * segmentHeight - heightHalf;\n        for (let ix = 0; ix < gridX1; ix++) {\n          const x = ix * segmentWidth - widthHalf;\n\n          // set values to correct vector component\n\n          vector[u] = x * udir;\n          vector[v] = y * vdir;\n          vector[w] = depthHalf;\n\n          // now apply vector to vertex buffer\n\n          vertices.push(vector.x, vector.y, vector.z);\n\n          // set values to correct vector component\n\n          vector[u] = 0;\n          vector[v] = 0;\n          vector[w] = depth > 0 ? 1 : -1;\n\n          // now apply vector to normal buffer\n\n          normals.push(vector.x, vector.y, vector.z);\n\n          // uvs\n\n          uvs.push(ix / gridX);\n          uvs.push(1 - iy / gridY);\n\n          // counters\n\n          vertexCounter += 1;\n        }\n      }\n\n      // indices\n\n      // 1. you need three indices to draw a single face\n      // 2. a single segment consists of two faces\n      // 3. so we need to generate six (2*3) indices per segment\n\n      for (let iy = 0; iy < gridY; iy++) {\n        for (let ix = 0; ix < gridX; ix++) {\n          const a = numberOfVertices + ix + gridX1 * iy;\n          const b = numberOfVertices + ix + gridX1 * (iy + 1);\n          const c = numberOfVertices + (ix + 1) + gridX1 * (iy + 1);\n          const d = numberOfVertices + (ix + 1) + gridX1 * iy;\n\n          // faces\n\n          indices.push(a, b, d);\n          indices.push(b, c, d);\n\n          // increase counter\n\n          groupCount += 6;\n        }\n      }\n\n      // add a group to the geometry. this will ensure multi material support\n\n      scope.addGroup(groupStart, groupCount, materialIndex);\n\n      // calculate new start value for groups\n\n      groupStart += groupCount;\n\n      // update total number of vertices\n\n      numberOfVertices += vertexCounter;\n    }\n  }\n}\n\n/**\n * Uniform Utilities\n */\n\nfunction cloneUniforms(src) {\n  const dst = {};\n  for (const u in src) {\n    dst[u] = {};\n    for (const p in src[u]) {\n      const property = src[u][p];\n      if (property && (property.isColor || property.isMatrix3 || property.isMatrix4 || property.isVector2 || property.isVector3 || property.isVector4 || property.isTexture)) {\n        dst[u][p] = property.clone();\n      } else if (Array.isArray(property)) {\n        dst[u][p] = property.slice();\n      } else {\n        dst[u][p] = property;\n      }\n    }\n  }\n  return dst;\n}\nfunction mergeUniforms(uniforms) {\n  const merged = {};\n  for (let u = 0; u < uniforms.length; u++) {\n    const tmp = cloneUniforms(uniforms[u]);\n    for (const p in tmp) {\n      merged[p] = tmp[p];\n    }\n  }\n  return merged;\n}\n\n// Legacy\n\nconst UniformsUtils = {\n  clone: cloneUniforms,\n  merge: mergeUniforms\n};\nvar default_vertex = \"void main() {\\n\\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\\n}\";\nvar default_fragment = \"void main() {\\n\\tgl_FragColor = vec4( 1.0, 0.0, 0.0, 1.0 );\\n}\";\n\n/**\n * parameters = {\n *  defines: { \"label\" : \"value\" },\n *  uniforms: { \"parameter1\": { value: 1.0 }, \"parameter2\": { value2: 2 } },\n *\n *  fragmentShader: <string>,\n *  vertexShader: <string>,\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>,\n *\n *  lights: <bool>,\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *  morphNormals: <bool>\n * }\n */\n\nfunction ShaderMaterial(parameters) {\n  Material.call(this);\n  this.type = 'ShaderMaterial';\n  this.defines = {};\n  this.uniforms = {};\n  this.vertexShader = default_vertex;\n  this.fragmentShader = default_fragment;\n  this.linewidth = 1;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.fog = false; // set to use scene fog\n  this.lights = false; // set to use scene lights\n  this.clipping = false; // set to use user-defined clipping planes\n\n  this.skinning = false; // set to use skinning attribute streams\n  this.morphTargets = false; // set to use morph targets\n  this.morphNormals = false; // set to use morph normals\n\n  this.extensions = {\n    derivatives: false,\n    // set to use derivatives\n    fragDepth: false,\n    // set to use fragment depth values\n    drawBuffers: false,\n    // set to use draw buffers\n    shaderTextureLOD: false // set to use shader texture LOD\n  };\n\n  // When rendered geometry doesn't include these attributes but the material does,\n  // use these default values in WebGL. This avoids errors when buffer data is missing.\n  this.defaultAttributeValues = {\n    'color': [1, 1, 1],\n    'uv': [0, 0],\n    'uv2': [0, 0]\n  };\n  this.index0AttributeName = undefined;\n  this.uniformsNeedUpdate = false;\n  this.glslVersion = null;\n  if (parameters !== undefined) {\n    if (parameters.attributes !== undefined) {\n      console.error('THREE.ShaderMaterial: attributes should now be defined in THREE.BufferGeometry instead.');\n    }\n    this.setValues(parameters);\n  }\n}\nShaderMaterial.prototype = Object.create(Material.prototype);\nShaderMaterial.prototype.constructor = ShaderMaterial;\nShaderMaterial.prototype.isShaderMaterial = true;\nShaderMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.fragmentShader = source.fragmentShader;\n  this.vertexShader = source.vertexShader;\n  this.uniforms = cloneUniforms(source.uniforms);\n  this.defines = _extends__default['default']({}, source.defines);\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  this.lights = source.lights;\n  this.clipping = source.clipping;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.morphNormals = source.morphNormals;\n  this.extensions = _extends__default['default']({}, source.extensions);\n  this.glslVersion = source.glslVersion;\n  return this;\n};\nShaderMaterial.prototype.toJSON = function (meta) {\n  const data = Material.prototype.toJSON.call(this, meta);\n  data.glslVersion = this.glslVersion;\n  data.uniforms = {};\n  for (const name in this.uniforms) {\n    const uniform = this.uniforms[name];\n    const value = uniform.value;\n    if (value && value.isTexture) {\n      data.uniforms[name] = {\n        type: 't',\n        value: value.toJSON(meta).uuid\n      };\n    } else if (value && value.isColor) {\n      data.uniforms[name] = {\n        type: 'c',\n        value: value.getHex()\n      };\n    } else if (value && value.isVector2) {\n      data.uniforms[name] = {\n        type: 'v2',\n        value: value.toArray()\n      };\n    } else if (value && value.isVector3) {\n      data.uniforms[name] = {\n        type: 'v3',\n        value: value.toArray()\n      };\n    } else if (value && value.isVector4) {\n      data.uniforms[name] = {\n        type: 'v4',\n        value: value.toArray()\n      };\n    } else if (value && value.isMatrix3) {\n      data.uniforms[name] = {\n        type: 'm3',\n        value: value.toArray()\n      };\n    } else if (value && value.isMatrix4) {\n      data.uniforms[name] = {\n        type: 'm4',\n        value: value.toArray()\n      };\n    } else {\n      data.uniforms[name] = {\n        value: value\n      };\n\n      // note: the array variants v2v, v3v, v4v, m4v and tv are not supported so far\n    }\n  }\n\n  if (Object.keys(this.defines).length > 0) data.defines = this.defines;\n  data.vertexShader = this.vertexShader;\n  data.fragmentShader = this.fragmentShader;\n  const extensions = {};\n  for (const key in this.extensions) {\n    if (this.extensions[key] === true) extensions[key] = true;\n  }\n  if (Object.keys(extensions).length > 0) data.extensions = extensions;\n  return data;\n};\nfunction Camera() {\n  Object3D.call(this);\n  this.type = 'Camera';\n  this.matrixWorldInverse = new Matrix4();\n  this.projectionMatrix = new Matrix4();\n  this.projectionMatrixInverse = new Matrix4();\n}\nCamera.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Camera,\n  isCamera: true,\n  copy: function (source, recursive) {\n    Object3D.prototype.copy.call(this, source, recursive);\n    this.matrixWorldInverse.copy(source.matrixWorldInverse);\n    this.projectionMatrix.copy(source.projectionMatrix);\n    this.projectionMatrixInverse.copy(source.projectionMatrixInverse);\n    return this;\n  },\n  getWorldDirection: function (target) {\n    if (target === undefined) {\n      console.warn('THREE.Camera: .getWorldDirection() target is now required');\n      target = new Vector3();\n    }\n    this.updateWorldMatrix(true, false);\n    const e = this.matrixWorld.elements;\n    return target.set(-e[8], -e[9], -e[10]).normalize();\n  },\n  updateMatrixWorld: function (force) {\n    Object3D.prototype.updateMatrixWorld.call(this, force);\n    this.matrixWorldInverse.copy(this.matrixWorld).invert();\n  },\n  updateWorldMatrix: function (updateParents, updateChildren) {\n    Object3D.prototype.updateWorldMatrix.call(this, updateParents, updateChildren);\n    this.matrixWorldInverse.copy(this.matrixWorld).invert();\n  },\n  clone: function () {\n    return new this.constructor().copy(this);\n  }\n});\nfunction PerspectiveCamera(fov = 50, aspect = 1, near = 0.1, far = 2000) {\n  Camera.call(this);\n  this.type = 'PerspectiveCamera';\n  this.fov = fov;\n  this.zoom = 1;\n  this.near = near;\n  this.far = far;\n  this.focus = 10;\n  this.aspect = aspect;\n  this.view = null;\n  this.filmGauge = 35; // width of the film (default in millimeters)\n  this.filmOffset = 0; // horizontal film offset (same unit as gauge)\n\n  this.updateProjectionMatrix();\n}\nPerspectiveCamera.prototype = _extends__default['default'](Object.create(Camera.prototype), {\n  constructor: PerspectiveCamera,\n  isPerspectiveCamera: true,\n  copy: function (source, recursive) {\n    Camera.prototype.copy.call(this, source, recursive);\n    this.fov = source.fov;\n    this.zoom = source.zoom;\n    this.near = source.near;\n    this.far = source.far;\n    this.focus = source.focus;\n    this.aspect = source.aspect;\n    this.view = source.view === null ? null : _extends__default['default']({}, source.view);\n    this.filmGauge = source.filmGauge;\n    this.filmOffset = source.filmOffset;\n    return this;\n  },\n  /**\n   * Sets the FOV by focal length in respect to the current .filmGauge.\n   *\n   * The default film gauge is 35, so that the focal length can be specified for\n   * a 35mm (full frame) camera.\n   *\n   * Values for focal length and film gauge must have the same unit.\n   */\n  setFocalLength: function (focalLength) {\n    /** see {@link http://www.bobatkins.com/photography/technical/field_of_view.html} */\n    const vExtentSlope = 0.5 * this.getFilmHeight() / focalLength;\n    this.fov = MathUtils.RAD2DEG * 2 * Math.atan(vExtentSlope);\n    this.updateProjectionMatrix();\n  },\n  /**\n   * Calculates the focal length from the current .fov and .filmGauge.\n   */\n  getFocalLength: function () {\n    const vExtentSlope = Math.tan(MathUtils.DEG2RAD * 0.5 * this.fov);\n    return 0.5 * this.getFilmHeight() / vExtentSlope;\n  },\n  getEffectiveFOV: function () {\n    return MathUtils.RAD2DEG * 2 * Math.atan(Math.tan(MathUtils.DEG2RAD * 0.5 * this.fov) / this.zoom);\n  },\n  getFilmWidth: function () {\n    // film not completely covered in portrait format (aspect < 1)\n    return this.filmGauge * Math.min(this.aspect, 1);\n  },\n  getFilmHeight: function () {\n    // film not completely covered in landscape format (aspect > 1)\n    return this.filmGauge / Math.max(this.aspect, 1);\n  },\n  /**\n   * Sets an offset in a larger frustum. This is useful for multi-window or\n   * multi-monitor/multi-machine setups.\n   *\n   * For example, if you have 3x2 monitors and each monitor is 1920x1080 and\n   * the monitors are in grid like this\n   *\n   *   +---+---+---+\n   *   | A | B | C |\n   *   +---+---+---+\n   *   | D | E | F |\n   *   +---+---+---+\n   *\n   * then for each monitor you would call it like this\n   *\n   *   const w = 1920;\n   *   const h = 1080;\n   *   const fullWidth = w * 3;\n   *   const fullHeight = h * 2;\n   *\n   *   --A--\n   *   camera.setViewOffset( fullWidth, fullHeight, w * 0, h * 0, w, h );\n   *   --B--\n   *   camera.setViewOffset( fullWidth, fullHeight, w * 1, h * 0, w, h );\n   *   --C--\n   *   camera.setViewOffset( fullWidth, fullHeight, w * 2, h * 0, w, h );\n   *   --D--\n   *   camera.setViewOffset( fullWidth, fullHeight, w * 0, h * 1, w, h );\n   *   --E--\n   *   camera.setViewOffset( fullWidth, fullHeight, w * 1, h * 1, w, h );\n   *   --F--\n   *   camera.setViewOffset( fullWidth, fullHeight, w * 2, h * 1, w, h );\n   *\n   *   Note there is no reason monitors have to be the same size or in a grid.\n   */\n  setViewOffset: function (fullWidth, fullHeight, x, y, width, height) {\n    this.aspect = fullWidth / fullHeight;\n    if (this.view === null) {\n      this.view = {\n        enabled: true,\n        fullWidth: 1,\n        fullHeight: 1,\n        offsetX: 0,\n        offsetY: 0,\n        width: 1,\n        height: 1\n      };\n    }\n    this.view.enabled = true;\n    this.view.fullWidth = fullWidth;\n    this.view.fullHeight = fullHeight;\n    this.view.offsetX = x;\n    this.view.offsetY = y;\n    this.view.width = width;\n    this.view.height = height;\n    this.updateProjectionMatrix();\n  },\n  clearViewOffset: function () {\n    if (this.view !== null) {\n      this.view.enabled = false;\n    }\n    this.updateProjectionMatrix();\n  },\n  updateProjectionMatrix: function () {\n    const near = this.near;\n    let top = near * Math.tan(MathUtils.DEG2RAD * 0.5 * this.fov) / this.zoom;\n    let height = 2 * top;\n    let width = this.aspect * height;\n    let left = -0.5 * width;\n    const view = this.view;\n    if (this.view !== null && this.view.enabled) {\n      const fullWidth = view.fullWidth,\n        fullHeight = view.fullHeight;\n      left += view.offsetX * width / fullWidth;\n      top -= view.offsetY * height / fullHeight;\n      width *= view.width / fullWidth;\n      height *= view.height / fullHeight;\n    }\n    const skew = this.filmOffset;\n    if (skew !== 0) left += near * skew / this.getFilmWidth();\n    this.projectionMatrix.makePerspective(left, left + width, top, top - height, near, this.far);\n    this.projectionMatrixInverse.copy(this.projectionMatrix).invert();\n  },\n  toJSON: function (meta) {\n    const data = Object3D.prototype.toJSON.call(this, meta);\n    data.object.fov = this.fov;\n    data.object.zoom = this.zoom;\n    data.object.near = this.near;\n    data.object.far = this.far;\n    data.object.focus = this.focus;\n    data.object.aspect = this.aspect;\n    if (this.view !== null) data.object.view = _extends__default['default']({}, this.view);\n    data.object.filmGauge = this.filmGauge;\n    data.object.filmOffset = this.filmOffset;\n    return data;\n  }\n});\nconst fov = 90,\n  aspect = 1;\nfunction CubeCamera(near, far, renderTarget) {\n  Object3D.call(this);\n  this.type = 'CubeCamera';\n  if (renderTarget.isWebGLCubeRenderTarget !== true) {\n    console.error('THREE.CubeCamera: The constructor now expects an instance of WebGLCubeRenderTarget as third parameter.');\n    return;\n  }\n  this.renderTarget = renderTarget;\n  const cameraPX = new PerspectiveCamera(fov, aspect, near, far);\n  cameraPX.layers = this.layers;\n  cameraPX.up.set(0, -1, 0);\n  cameraPX.lookAt(new Vector3(1, 0, 0));\n  this.add(cameraPX);\n  const cameraNX = new PerspectiveCamera(fov, aspect, near, far);\n  cameraNX.layers = this.layers;\n  cameraNX.up.set(0, -1, 0);\n  cameraNX.lookAt(new Vector3(-1, 0, 0));\n  this.add(cameraNX);\n  const cameraPY = new PerspectiveCamera(fov, aspect, near, far);\n  cameraPY.layers = this.layers;\n  cameraPY.up.set(0, 0, 1);\n  cameraPY.lookAt(new Vector3(0, 1, 0));\n  this.add(cameraPY);\n  const cameraNY = new PerspectiveCamera(fov, aspect, near, far);\n  cameraNY.layers = this.layers;\n  cameraNY.up.set(0, 0, -1);\n  cameraNY.lookAt(new Vector3(0, -1, 0));\n  this.add(cameraNY);\n  const cameraPZ = new PerspectiveCamera(fov, aspect, near, far);\n  cameraPZ.layers = this.layers;\n  cameraPZ.up.set(0, -1, 0);\n  cameraPZ.lookAt(new Vector3(0, 0, 1));\n  this.add(cameraPZ);\n  const cameraNZ = new PerspectiveCamera(fov, aspect, near, far);\n  cameraNZ.layers = this.layers;\n  cameraNZ.up.set(0, -1, 0);\n  cameraNZ.lookAt(new Vector3(0, 0, -1));\n  this.add(cameraNZ);\n  this.update = function (renderer, scene) {\n    if (this.parent === null) this.updateMatrixWorld();\n    const currentXrEnabled = renderer.xr.enabled;\n    const currentRenderTarget = renderer.getRenderTarget();\n    renderer.xr.enabled = false;\n    const generateMipmaps = renderTarget.texture.generateMipmaps;\n    renderTarget.texture.generateMipmaps = false;\n    renderer.setRenderTarget(renderTarget, 0);\n    renderer.render(scene, cameraPX);\n    renderer.setRenderTarget(renderTarget, 1);\n    renderer.render(scene, cameraNX);\n    renderer.setRenderTarget(renderTarget, 2);\n    renderer.render(scene, cameraPY);\n    renderer.setRenderTarget(renderTarget, 3);\n    renderer.render(scene, cameraNY);\n    renderer.setRenderTarget(renderTarget, 4);\n    renderer.render(scene, cameraPZ);\n    renderTarget.texture.generateMipmaps = generateMipmaps;\n    renderer.setRenderTarget(renderTarget, 5);\n    renderer.render(scene, cameraNZ);\n    renderer.setRenderTarget(currentRenderTarget);\n    renderer.xr.enabled = currentXrEnabled;\n  };\n}\nCubeCamera.prototype = Object.create(Object3D.prototype);\nCubeCamera.prototype.constructor = CubeCamera;\nfunction CubeTexture(images, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy, encoding) {\n  images = images !== undefined ? images : [];\n  mapping = mapping !== undefined ? mapping : CubeReflectionMapping;\n  format = format !== undefined ? format : RGBFormat;\n  Texture.call(this, images, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy, encoding);\n  this.flipY = false;\n\n  // Why CubeTexture._needsFlipEnvMap is necessary:\n  //\n  // By convention -- likely based on the RenderMan spec from the 1990's -- cube maps are specified by WebGL (and three.js)\n  // in a coordinate system in which positive-x is to the right when looking up the positive-z axis -- in other words,\n  // in a left-handed coordinate system. By continuing this convention, preexisting cube maps continued to render correctly.\n\n  // three.js uses a right-handed coordinate system. So environment maps used in three.js appear to have px and nx swapped\n  // and the flag _needsFlipEnvMap controls this conversion. The flip is not required (and thus _needsFlipEnvMap is set to false)\n  // when using WebGLCubeRenderTarget.texture as a cube texture.\n\n  this._needsFlipEnvMap = true;\n}\nCubeTexture.prototype = Object.create(Texture.prototype);\nCubeTexture.prototype.constructor = CubeTexture;\nCubeTexture.prototype.isCubeTexture = true;\nObject.defineProperty(CubeTexture.prototype, 'images', {\n  get: function () {\n    return this.image;\n  },\n  set: function (value) {\n    this.image = value;\n  }\n});\nclass WebGLCubeRenderTarget extends WebGLRenderTarget {\n  constructor(size, options, dummy) {\n    if (Number.isInteger(options)) {\n      console.warn('THREE.WebGLCubeRenderTarget: constructor signature is now WebGLCubeRenderTarget( size, options )');\n      options = dummy;\n    }\n    super(size, size, options);\n    Object.defineProperty(this, 'isWebGLCubeRenderTarget', {\n      value: true\n    });\n    options = options || {};\n    this.texture = new CubeTexture(undefined, options.mapping, options.wrapS, options.wrapT, options.magFilter, options.minFilter, options.format, options.type, options.anisotropy, options.encoding);\n    this.texture._needsFlipEnvMap = false;\n  }\n  fromEquirectangularTexture(renderer, texture) {\n    this.texture.type = texture.type;\n    this.texture.format = RGBAFormat; // see #18859\n    this.texture.encoding = texture.encoding;\n    this.texture.generateMipmaps = texture.generateMipmaps;\n    this.texture.minFilter = texture.minFilter;\n    this.texture.magFilter = texture.magFilter;\n    const shader = {\n      uniforms: {\n        tEquirect: {\n          value: null\n        }\n      },\n      vertexShader: /* glsl */`\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\tvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\n\t\t\t\t\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n\n\t\t\t\t}\n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvWorldDirection = transformDirection( position, modelMatrix );\n\n\t\t\t\t\t#include <begin_vertex>\n\t\t\t\t\t#include <project_vertex>\n\n\t\t\t\t}\n\t\t\t`,\n      fragmentShader: /* glsl */`\n\n\t\t\t\tuniform sampler2D tEquirect;\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\t#include <common>\n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvec3 direction = normalize( vWorldDirection );\n\n\t\t\t\t\tvec2 sampleUV = equirectUv( direction );\n\n\t\t\t\t\tgl_FragColor = texture2D( tEquirect, sampleUV );\n\n\t\t\t\t}\n\t\t\t`\n    };\n    const geometry = new BoxGeometry(5, 5, 5);\n    const material = new ShaderMaterial({\n      name: 'CubemapFromEquirect',\n      uniforms: cloneUniforms(shader.uniforms),\n      vertexShader: shader.vertexShader,\n      fragmentShader: shader.fragmentShader,\n      side: BackSide,\n      blending: NoBlending\n    });\n    material.uniforms.tEquirect.value = texture;\n    const mesh = new Mesh(geometry, material);\n    const currentMinFilter = texture.minFilter;\n\n    // Avoid blurred poles\n    if (texture.minFilter === LinearMipmapLinearFilter) texture.minFilter = LinearFilter;\n    const camera = new CubeCamera(1, 10, this);\n    camera.update(renderer, mesh);\n    texture.minFilter = currentMinFilter;\n    mesh.geometry.dispose();\n    mesh.material.dispose();\n    return this;\n  }\n  clear(renderer, color, depth, stencil) {\n    const currentRenderTarget = renderer.getRenderTarget();\n    for (let i = 0; i < 6; i++) {\n      renderer.setRenderTarget(this, i);\n      renderer.clear(color, depth, stencil);\n    }\n    renderer.setRenderTarget(currentRenderTarget);\n  }\n}\nfunction DataTexture(data, width, height, format, type, mapping, wrapS, wrapT, magFilter, minFilter, anisotropy, encoding) {\n  Texture.call(this, null, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy, encoding);\n  this.image = {\n    data: data || null,\n    width: width || 1,\n    height: height || 1\n  };\n  this.magFilter = magFilter !== undefined ? magFilter : NearestFilter;\n  this.minFilter = minFilter !== undefined ? minFilter : NearestFilter;\n  this.generateMipmaps = false;\n  this.flipY = false;\n  this.unpackAlignment = 1;\n  this.needsUpdate = true;\n}\nDataTexture.prototype = Object.create(Texture.prototype);\nDataTexture.prototype.constructor = DataTexture;\nDataTexture.prototype.isDataTexture = true;\nconst _sphere$1 = /*@__PURE__*/new Sphere();\nconst _vector$5 = /*@__PURE__*/new Vector3();\nclass Frustum {\n  constructor(p0, p1, p2, p3, p4, p5) {\n    this.planes = [p0 !== undefined ? p0 : new Plane(), p1 !== undefined ? p1 : new Plane(), p2 !== undefined ? p2 : new Plane(), p3 !== undefined ? p3 : new Plane(), p4 !== undefined ? p4 : new Plane(), p5 !== undefined ? p5 : new Plane()];\n  }\n  set(p0, p1, p2, p3, p4, p5) {\n    const planes = this.planes;\n    planes[0].copy(p0);\n    planes[1].copy(p1);\n    planes[2].copy(p2);\n    planes[3].copy(p3);\n    planes[4].copy(p4);\n    planes[5].copy(p5);\n    return this;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(frustum) {\n    const planes = this.planes;\n    for (let i = 0; i < 6; i++) {\n      planes[i].copy(frustum.planes[i]);\n    }\n    return this;\n  }\n  setFromProjectionMatrix(m) {\n    const planes = this.planes;\n    const me = m.elements;\n    const me0 = me[0],\n      me1 = me[1],\n      me2 = me[2],\n      me3 = me[3];\n    const me4 = me[4],\n      me5 = me[5],\n      me6 = me[6],\n      me7 = me[7];\n    const me8 = me[8],\n      me9 = me[9],\n      me10 = me[10],\n      me11 = me[11];\n    const me12 = me[12],\n      me13 = me[13],\n      me14 = me[14],\n      me15 = me[15];\n    planes[0].setComponents(me3 - me0, me7 - me4, me11 - me8, me15 - me12).normalize();\n    planes[1].setComponents(me3 + me0, me7 + me4, me11 + me8, me15 + me12).normalize();\n    planes[2].setComponents(me3 + me1, me7 + me5, me11 + me9, me15 + me13).normalize();\n    planes[3].setComponents(me3 - me1, me7 - me5, me11 - me9, me15 - me13).normalize();\n    planes[4].setComponents(me3 - me2, me7 - me6, me11 - me10, me15 - me14).normalize();\n    planes[5].setComponents(me3 + me2, me7 + me6, me11 + me10, me15 + me14).normalize();\n    return this;\n  }\n  intersectsObject(object) {\n    const geometry = object.geometry;\n    if (geometry.boundingSphere === null) geometry.computeBoundingSphere();\n    _sphere$1.copy(geometry.boundingSphere).applyMatrix4(object.matrixWorld);\n    return this.intersectsSphere(_sphere$1);\n  }\n  intersectsSprite(sprite) {\n    _sphere$1.center.set(0, 0, 0);\n    _sphere$1.radius = 0.7071067811865476;\n    _sphere$1.applyMatrix4(sprite.matrixWorld);\n    return this.intersectsSphere(_sphere$1);\n  }\n  intersectsSphere(sphere) {\n    const planes = this.planes;\n    const center = sphere.center;\n    const negRadius = -sphere.radius;\n    for (let i = 0; i < 6; i++) {\n      const distance = planes[i].distanceToPoint(center);\n      if (distance < negRadius) {\n        return false;\n      }\n    }\n    return true;\n  }\n  intersectsBox(box) {\n    const planes = this.planes;\n    for (let i = 0; i < 6; i++) {\n      const plane = planes[i];\n\n      // corner at max distance\n\n      _vector$5.x = plane.normal.x > 0 ? box.max.x : box.min.x;\n      _vector$5.y = plane.normal.y > 0 ? box.max.y : box.min.y;\n      _vector$5.z = plane.normal.z > 0 ? box.max.z : box.min.z;\n      if (plane.distanceToPoint(_vector$5) < 0) {\n        return false;\n      }\n    }\n    return true;\n  }\n  containsPoint(point) {\n    const planes = this.planes;\n    for (let i = 0; i < 6; i++) {\n      if (planes[i].distanceToPoint(point) < 0) {\n        return false;\n      }\n    }\n    return true;\n  }\n}\nfunction WebGLAnimation() {\n  let context = null;\n  let isAnimating = false;\n  let animationLoop = null;\n  let requestId = null;\n  function onAnimationFrame(time, frame) {\n    animationLoop(time, frame);\n    requestId = context.requestAnimationFrame(onAnimationFrame);\n  }\n  return {\n    start: function () {\n      if (isAnimating === true) return;\n      if (animationLoop === null) return;\n      requestId = context.requestAnimationFrame(onAnimationFrame);\n      isAnimating = true;\n    },\n    stop: function () {\n      context.cancelAnimationFrame(requestId);\n      isAnimating = false;\n    },\n    setAnimationLoop: function (callback) {\n      animationLoop = callback;\n    },\n    setContext: function (value) {\n      context = value;\n    }\n  };\n}\nfunction WebGLAttributes(gl, capabilities) {\n  const isWebGL2 = capabilities.isWebGL2;\n  const buffers = new WeakMap();\n  function createBuffer(attribute, bufferType) {\n    const array = attribute.array;\n    const usage = attribute.usage;\n    const buffer = gl.createBuffer();\n    gl.bindBuffer(bufferType, buffer);\n    gl.bufferData(bufferType, array, usage);\n    attribute.onUploadCallback();\n    let type = 5126;\n    if (array instanceof Float32Array) {\n      type = 5126;\n    } else if (array instanceof Float64Array) {\n      console.warn('THREE.WebGLAttributes: Unsupported data buffer format: Float64Array.');\n    } else if (array instanceof Uint16Array) {\n      if (attribute.isFloat16BufferAttribute) {\n        if (isWebGL2) {\n          type = 5131;\n        } else {\n          console.warn('THREE.WebGLAttributes: Usage of Float16BufferAttribute requires WebGL2.');\n        }\n      } else {\n        type = 5123;\n      }\n    } else if (array instanceof Int16Array) {\n      type = 5122;\n    } else if (array instanceof Uint32Array) {\n      type = 5125;\n    } else if (array instanceof Int32Array) {\n      type = 5124;\n    } else if (array instanceof Int8Array) {\n      type = 5120;\n    } else if (array instanceof Uint8Array) {\n      type = 5121;\n    }\n    return {\n      buffer: buffer,\n      type: type,\n      bytesPerElement: array.BYTES_PER_ELEMENT,\n      version: attribute.version\n    };\n  }\n  function updateBuffer(buffer, attribute, bufferType) {\n    const array = attribute.array;\n    const updateRange = attribute.updateRange;\n    gl.bindBuffer(bufferType, buffer);\n    if (updateRange.count === -1) {\n      // Not using update ranges\n\n      gl.bufferSubData(bufferType, 0, array);\n    } else {\n      if (isWebGL2) {\n        gl.bufferSubData(bufferType, updateRange.offset * array.BYTES_PER_ELEMENT, array, updateRange.offset, updateRange.count);\n      } else {\n        gl.bufferSubData(bufferType, updateRange.offset * array.BYTES_PER_ELEMENT, array.subarray(updateRange.offset, updateRange.offset + updateRange.count));\n      }\n      updateRange.count = -1; // reset range\n    }\n  }\n\n  //\n\n  function get(attribute) {\n    if (attribute.isInterleavedBufferAttribute) attribute = attribute.data;\n    return buffers.get(attribute);\n  }\n  function remove(attribute) {\n    if (attribute.isInterleavedBufferAttribute) attribute = attribute.data;\n    const data = buffers.get(attribute);\n    if (data) {\n      gl.deleteBuffer(data.buffer);\n      buffers.delete(attribute);\n    }\n  }\n  function update(attribute, bufferType) {\n    if (attribute.isGLBufferAttribute) {\n      const cached = buffers.get(attribute);\n      if (!cached || cached.version < attribute.version) {\n        buffers.set(attribute, {\n          buffer: attribute.buffer,\n          type: attribute.type,\n          bytesPerElement: attribute.elementSize,\n          version: attribute.version\n        });\n      }\n      return;\n    }\n    if (attribute.isInterleavedBufferAttribute) attribute = attribute.data;\n    const data = buffers.get(attribute);\n    if (data === undefined) {\n      buffers.set(attribute, createBuffer(attribute, bufferType));\n    } else if (data.version < attribute.version) {\n      updateBuffer(data.buffer, attribute, bufferType);\n      data.version = attribute.version;\n    }\n  }\n  return {\n    get: get,\n    remove: remove,\n    update: update\n  };\n}\nclass PlaneGeometry extends BufferGeometry {\n  constructor(width = 1, height = 1, widthSegments = 1, heightSegments = 1) {\n    super();\n    this.type = 'PlaneGeometry';\n    this.parameters = {\n      width: width,\n      height: height,\n      widthSegments: widthSegments,\n      heightSegments: heightSegments\n    };\n    const width_half = width / 2;\n    const height_half = height / 2;\n    const gridX = Math.floor(widthSegments);\n    const gridY = Math.floor(heightSegments);\n    const gridX1 = gridX + 1;\n    const gridY1 = gridY + 1;\n    const segment_width = width / gridX;\n    const segment_height = height / gridY;\n\n    //\n\n    const indices = [];\n    const vertices = [];\n    const normals = [];\n    const uvs = [];\n    for (let iy = 0; iy < gridY1; iy++) {\n      const y = iy * segment_height - height_half;\n      for (let ix = 0; ix < gridX1; ix++) {\n        const x = ix * segment_width - width_half;\n        vertices.push(x, -y, 0);\n        normals.push(0, 0, 1);\n        uvs.push(ix / gridX);\n        uvs.push(1 - iy / gridY);\n      }\n    }\n    for (let iy = 0; iy < gridY; iy++) {\n      for (let ix = 0; ix < gridX; ix++) {\n        const a = ix + gridX1 * iy;\n        const b = ix + gridX1 * (iy + 1);\n        const c = ix + 1 + gridX1 * (iy + 1);\n        const d = ix + 1 + gridX1 * iy;\n        indices.push(a, b, d);\n        indices.push(b, c, d);\n      }\n    }\n    this.setIndex(indices);\n    this.setAttribute('position', new Float32BufferAttribute(vertices, 3));\n    this.setAttribute('normal', new Float32BufferAttribute(normals, 3));\n    this.setAttribute('uv', new Float32BufferAttribute(uvs, 2));\n  }\n}\nvar alphamap_fragment = \"#ifdef USE_ALPHAMAP\\n\\tdiffuseColor.a *= texture2D( alphaMap, vUv ).g;\\n#endif\";\nvar alphamap_pars_fragment = \"#ifdef USE_ALPHAMAP\\n\\tuniform sampler2D alphaMap;\\n#endif\";\nvar alphatest_fragment = \"#ifdef ALPHATEST\\n\\tif ( diffuseColor.a < ALPHATEST ) discard;\\n#endif\";\nvar aomap_fragment = \"#ifdef USE_AOMAP\\n\\tfloat ambientOcclusion = ( texture2D( aoMap, vUv2 ).r - 1.0 ) * aoMapIntensity + 1.0;\\n\\treflectedLight.indirectDiffuse *= ambientOcclusion;\\n\\t#if defined( USE_ENVMAP ) && defined( STANDARD )\\n\\t\\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\\n\\t\\treflectedLight.indirectSpecular *= computeSpecularOcclusion( dotNV, ambientOcclusion, material.specularRoughness );\\n\\t#endif\\n#endif\";\nvar aomap_pars_fragment = \"#ifdef USE_AOMAP\\n\\tuniform sampler2D aoMap;\\n\\tuniform float aoMapIntensity;\\n#endif\";\nvar begin_vertex = \"vec3 transformed = vec3( position );\";\nvar beginnormal_vertex = \"vec3 objectNormal = vec3( normal );\\n#ifdef USE_TANGENT\\n\\tvec3 objectTangent = vec3( tangent.xyz );\\n#endif\";\nvar bsdfs = \"vec2 integrateSpecularBRDF( const in float dotNV, const in float roughness ) {\\n\\tconst vec4 c0 = vec4( - 1, - 0.0275, - 0.572, 0.022 );\\n\\tconst vec4 c1 = vec4( 1, 0.0425, 1.04, - 0.04 );\\n\\tvec4 r = roughness * c0 + c1;\\n\\tfloat a004 = min( r.x * r.x, exp2( - 9.28 * dotNV ) ) * r.x + r.y;\\n\\treturn vec2( -1.04, 1.04 ) * a004 + r.zw;\\n}\\nfloat punctualLightIntensityToIrradianceFactor( const in float lightDistance, const in float cutoffDistance, const in float decayExponent ) {\\n#if defined ( PHYSICALLY_CORRECT_LIGHTS )\\n\\tfloat distanceFalloff = 1.0 / max( pow( lightDistance, decayExponent ), 0.01 );\\n\\tif( cutoffDistance > 0.0 ) {\\n\\t\\tdistanceFalloff *= pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );\\n\\t}\\n\\treturn distanceFalloff;\\n#else\\n\\tif( cutoffDistance > 0.0 && decayExponent > 0.0 ) {\\n\\t\\treturn pow( saturate( -lightDistance / cutoffDistance + 1.0 ), decayExponent );\\n\\t}\\n\\treturn 1.0;\\n#endif\\n}\\nvec3 BRDF_Diffuse_Lambert( const in vec3 diffuseColor ) {\\n\\treturn RECIPROCAL_PI * diffuseColor;\\n}\\nvec3 F_Schlick( const in vec3 specularColor, const in float dotLH ) {\\n\\tfloat fresnel = exp2( ( -5.55473 * dotLH - 6.98316 ) * dotLH );\\n\\treturn ( 1.0 - specularColor ) * fresnel + specularColor;\\n}\\nvec3 F_Schlick_RoughnessDependent( const in vec3 F0, const in float dotNV, const in float roughness ) {\\n\\tfloat fresnel = exp2( ( -5.55473 * dotNV - 6.98316 ) * dotNV );\\n\\tvec3 Fr = max( vec3( 1.0 - roughness ), F0 ) - F0;\\n\\treturn Fr * fresnel + F0;\\n}\\nfloat G_GGX_Smith( const in float alpha, const in float dotNL, const in float dotNV ) {\\n\\tfloat a2 = pow2( alpha );\\n\\tfloat gl = dotNL + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\\n\\tfloat gv = dotNV + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\\n\\treturn 1.0 / ( gl * gv );\\n}\\nfloat G_GGX_SmithCorrelated( const in float alpha, const in float dotNL, const in float dotNV ) {\\n\\tfloat a2 = pow2( alpha );\\n\\tfloat gv = dotNL * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\\n\\tfloat gl = dotNV * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\\n\\treturn 0.5 / max( gv + gl, EPSILON );\\n}\\nfloat D_GGX( const in float alpha, const in float dotNH ) {\\n\\tfloat a2 = pow2( alpha );\\n\\tfloat denom = pow2( dotNH ) * ( a2 - 1.0 ) + 1.0;\\n\\treturn RECIPROCAL_PI * a2 / pow2( denom );\\n}\\nvec3 BRDF_Specular_GGX( const in IncidentLight incidentLight, const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float roughness ) {\\n\\tfloat alpha = pow2( roughness );\\n\\tvec3 halfDir = normalize( incidentLight.direction + viewDir );\\n\\tfloat dotNL = saturate( dot( normal, incidentLight.direction ) );\\n\\tfloat dotNV = saturate( dot( normal, viewDir ) );\\n\\tfloat dotNH = saturate( dot( normal, halfDir ) );\\n\\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\\n\\tvec3 F = F_Schlick( specularColor, dotLH );\\n\\tfloat G = G_GGX_SmithCorrelated( alpha, dotNL, dotNV );\\n\\tfloat D = D_GGX( alpha, dotNH );\\n\\treturn F * ( G * D );\\n}\\nvec2 LTC_Uv( const in vec3 N, const in vec3 V, const in float roughness ) {\\n\\tconst float LUT_SIZE = 64.0;\\n\\tconst float LUT_SCALE = ( LUT_SIZE - 1.0 ) / LUT_SIZE;\\n\\tconst float LUT_BIAS = 0.5 / LUT_SIZE;\\n\\tfloat dotNV = saturate( dot( N, V ) );\\n\\tvec2 uv = vec2( roughness, sqrt( 1.0 - dotNV ) );\\n\\tuv = uv * LUT_SCALE + LUT_BIAS;\\n\\treturn uv;\\n}\\nfloat LTC_ClippedSphereFormFactor( const in vec3 f ) {\\n\\tfloat l = length( f );\\n\\treturn max( ( l * l + f.z ) / ( l + 1.0 ), 0.0 );\\n}\\nvec3 LTC_EdgeVectorFormFactor( const in vec3 v1, const in vec3 v2 ) {\\n\\tfloat x = dot( v1, v2 );\\n\\tfloat y = abs( x );\\n\\tfloat a = 0.8543985 + ( 0.4965155 + 0.0145206 * y ) * y;\\n\\tfloat b = 3.4175940 + ( 4.1616724 + y ) * y;\\n\\tfloat v = a / b;\\n\\tfloat theta_sintheta = ( x > 0.0 ) ? v : 0.5 * inversesqrt( max( 1.0 - x * x, 1e-7 ) ) - v;\\n\\treturn cross( v1, v2 ) * theta_sintheta;\\n}\\nvec3 LTC_Evaluate( const in vec3 N, const in vec3 V, const in vec3 P, const in mat3 mInv, const in vec3 rectCoords[ 4 ] ) {\\n\\tvec3 v1 = rectCoords[ 1 ] - rectCoords[ 0 ];\\n\\tvec3 v2 = rectCoords[ 3 ] - rectCoords[ 0 ];\\n\\tvec3 lightNormal = cross( v1, v2 );\\n\\tif( dot( lightNormal, P - rectCoords[ 0 ] ) < 0.0 ) return vec3( 0.0 );\\n\\tvec3 T1, T2;\\n\\tT1 = normalize( V - N * dot( V, N ) );\\n\\tT2 = - cross( N, T1 );\\n\\tmat3 mat = mInv * transposeMat3( mat3( T1, T2, N ) );\\n\\tvec3 coords[ 4 ];\\n\\tcoords[ 0 ] = mat * ( rectCoords[ 0 ] - P );\\n\\tcoords[ 1 ] = mat * ( rectCoords[ 1 ] - P );\\n\\tcoords[ 2 ] = mat * ( rectCoords[ 2 ] - P );\\n\\tcoords[ 3 ] = mat * ( rectCoords[ 3 ] - P );\\n\\tcoords[ 0 ] = normalize( coords[ 0 ] );\\n\\tcoords[ 1 ] = normalize( coords[ 1 ] );\\n\\tcoords[ 2 ] = normalize( coords[ 2 ] );\\n\\tcoords[ 3 ] = normalize( coords[ 3 ] );\\n\\tvec3 vectorFormFactor = vec3( 0.0 );\\n\\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 0 ], coords[ 1 ] );\\n\\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 1 ], coords[ 2 ] );\\n\\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 2 ], coords[ 3 ] );\\n\\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 3 ], coords[ 0 ] );\\n\\tfloat result = LTC_ClippedSphereFormFactor( vectorFormFactor );\\n\\treturn vec3( result );\\n}\\nvec3 BRDF_Specular_GGX_Environment( const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float roughness ) {\\n\\tfloat dotNV = saturate( dot( normal, viewDir ) );\\n\\tvec2 brdf = integrateSpecularBRDF( dotNV, roughness );\\n\\treturn specularColor * brdf.x + brdf.y;\\n}\\nvoid BRDF_Specular_Multiscattering_Environment( const in GeometricContext geometry, const in vec3 specularColor, const in float roughness, inout vec3 singleScatter, inout vec3 multiScatter ) {\\n\\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\\n\\tvec3 F = F_Schlick_RoughnessDependent( specularColor, dotNV, roughness );\\n\\tvec2 brdf = integrateSpecularBRDF( dotNV, roughness );\\n\\tvec3 FssEss = F * brdf.x + brdf.y;\\n\\tfloat Ess = brdf.x + brdf.y;\\n\\tfloat Ems = 1.0 - Ess;\\n\\tvec3 Favg = specularColor + ( 1.0 - specularColor ) * 0.047619;\\tvec3 Fms = FssEss * Favg / ( 1.0 - Ems * Favg );\\n\\tsingleScatter += FssEss;\\n\\tmultiScatter += Fms * Ems;\\n}\\nfloat G_BlinnPhong_Implicit( ) {\\n\\treturn 0.25;\\n}\\nfloat D_BlinnPhong( const in float shininess, const in float dotNH ) {\\n\\treturn RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );\\n}\\nvec3 BRDF_Specular_BlinnPhong( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float shininess ) {\\n\\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\\n\\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\\n\\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\\n\\tvec3 F = F_Schlick( specularColor, dotLH );\\n\\tfloat G = G_BlinnPhong_Implicit( );\\n\\tfloat D = D_BlinnPhong( shininess, dotNH );\\n\\treturn F * ( G * D );\\n}\\nfloat GGXRoughnessToBlinnExponent( const in float ggxRoughness ) {\\n\\treturn ( 2.0 / pow2( ggxRoughness + 0.0001 ) - 2.0 );\\n}\\nfloat BlinnExponentToGGXRoughness( const in float blinnExponent ) {\\n\\treturn sqrt( 2.0 / ( blinnExponent + 2.0 ) );\\n}\\n#if defined( USE_SHEEN )\\nfloat D_Charlie(float roughness, float NoH) {\\n\\tfloat invAlpha = 1.0 / roughness;\\n\\tfloat cos2h = NoH * NoH;\\n\\tfloat sin2h = max(1.0 - cos2h, 0.0078125);\\treturn (2.0 + invAlpha) * pow(sin2h, invAlpha * 0.5) / (2.0 * PI);\\n}\\nfloat V_Neubelt(float NoV, float NoL) {\\n\\treturn saturate(1.0 / (4.0 * (NoL + NoV - NoL * NoV)));\\n}\\nvec3 BRDF_Specular_Sheen( const in float roughness, const in vec3 L, const in GeometricContext geometry, vec3 specularColor ) {\\n\\tvec3 N = geometry.normal;\\n\\tvec3 V = geometry.viewDir;\\n\\tvec3 H = normalize( V + L );\\n\\tfloat dotNH = saturate( dot( N, H ) );\\n\\treturn specularColor * D_Charlie( roughness, dotNH ) * V_Neubelt( dot(N, V), dot(N, L) );\\n}\\n#endif\";\nvar bumpmap_pars_fragment = \"#ifdef USE_BUMPMAP\\n\\tuniform sampler2D bumpMap;\\n\\tuniform float bumpScale;\\n\\tvec2 dHdxy_fwd() {\\n\\t\\tvec2 dSTdx = dFdx( vUv );\\n\\t\\tvec2 dSTdy = dFdy( vUv );\\n\\t\\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\\n\\t\\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\\n\\t\\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\\n\\t\\treturn vec2( dBx, dBy );\\n\\t}\\n\\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy ) {\\n\\t\\tvec3 vSigmaX = vec3( dFdx( surf_pos.x ), dFdx( surf_pos.y ), dFdx( surf_pos.z ) );\\n\\t\\tvec3 vSigmaY = vec3( dFdy( surf_pos.x ), dFdy( surf_pos.y ), dFdy( surf_pos.z ) );\\n\\t\\tvec3 vN = surf_norm;\\n\\t\\tvec3 R1 = cross( vSigmaY, vN );\\n\\t\\tvec3 R2 = cross( vN, vSigmaX );\\n\\t\\tfloat fDet = dot( vSigmaX, R1 );\\n\\t\\tfDet *= ( float( gl_FrontFacing ) * 2.0 - 1.0 );\\n\\t\\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\\n\\t\\treturn normalize( abs( fDet ) * surf_norm - vGrad );\\n\\t}\\n#endif\";\nvar clipping_planes_fragment = \"#if NUM_CLIPPING_PLANES > 0\\n\\tvec4 plane;\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < UNION_CLIPPING_PLANES; i ++ ) {\\n\\t\\tplane = clippingPlanes[ i ];\\n\\t\\tif ( dot( vClipPosition, plane.xyz ) > plane.w ) discard;\\n\\t}\\n\\t#pragma unroll_loop_end\\n\\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\\n\\t\\tbool clipped = true;\\n\\t\\t#pragma unroll_loop_start\\n\\t\\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; i ++ ) {\\n\\t\\t\\tplane = clippingPlanes[ i ];\\n\\t\\t\\tclipped = ( dot( vClipPosition, plane.xyz ) > plane.w ) && clipped;\\n\\t\\t}\\n\\t\\t#pragma unroll_loop_end\\n\\t\\tif ( clipped ) discard;\\n\\t#endif\\n#endif\";\nvar clipping_planes_pars_fragment = \"#if NUM_CLIPPING_PLANES > 0\\n\\tvarying vec3 vClipPosition;\\n\\tuniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];\\n#endif\";\nvar clipping_planes_pars_vertex = \"#if NUM_CLIPPING_PLANES > 0\\n\\tvarying vec3 vClipPosition;\\n#endif\";\nvar clipping_planes_vertex = \"#if NUM_CLIPPING_PLANES > 0\\n\\tvClipPosition = - mvPosition.xyz;\\n#endif\";\nvar color_fragment = \"#ifdef USE_COLOR\\n\\tdiffuseColor.rgb *= vColor;\\n#endif\";\nvar color_pars_fragment = \"#ifdef USE_COLOR\\n\\tvarying vec3 vColor;\\n#endif\";\nvar color_pars_vertex = \"#if defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\\n\\tvarying vec3 vColor;\\n#endif\";\nvar color_vertex = \"#if defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\\n\\tvColor = vec3( 1.0 );\\n#endif\\n#ifdef USE_COLOR\\n\\tvColor.xyz *= color.xyz;\\n#endif\\n#ifdef USE_INSTANCING_COLOR\\n\\tvColor.xyz *= instanceColor.xyz;\\n#endif\";\nvar common = \"#define PI 3.141592653589793\\n#define PI2 6.283185307179586\\n#define PI_HALF 1.5707963267948966\\n#define RECIPROCAL_PI 0.3183098861837907\\n#define RECIPROCAL_PI2 0.15915494309189535\\n#define EPSILON 1e-6\\n#ifndef saturate\\n#define saturate(a) clamp( a, 0.0, 1.0 )\\n#endif\\n#define whiteComplement(a) ( 1.0 - saturate( a ) )\\nfloat pow2( const in float x ) { return x*x; }\\nfloat pow3( const in float x ) { return x*x*x; }\\nfloat pow4( const in float x ) { float x2 = x*x; return x2*x2; }\\nfloat average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }\\nhighp float rand( const in vec2 uv ) {\\n\\tconst highp float a = 12.9898, b = 78.233, c = 43758.5453;\\n\\thighp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );\\n\\treturn fract(sin(sn) * c);\\n}\\n#ifdef HIGH_PRECISION\\n\\tfloat precisionSafeLength( vec3 v ) { return length( v ); }\\n#else\\n\\tfloat max3( vec3 v ) { return max( max( v.x, v.y ), v.z ); }\\n\\tfloat precisionSafeLength( vec3 v ) {\\n\\t\\tfloat maxComponent = max3( abs( v ) );\\n\\t\\treturn length( v / maxComponent ) * maxComponent;\\n\\t}\\n#endif\\nstruct IncidentLight {\\n\\tvec3 color;\\n\\tvec3 direction;\\n\\tbool visible;\\n};\\nstruct ReflectedLight {\\n\\tvec3 directDiffuse;\\n\\tvec3 directSpecular;\\n\\tvec3 indirectDiffuse;\\n\\tvec3 indirectSpecular;\\n};\\nstruct GeometricContext {\\n\\tvec3 position;\\n\\tvec3 normal;\\n\\tvec3 viewDir;\\n#ifdef CLEARCOAT\\n\\tvec3 clearcoatNormal;\\n#endif\\n};\\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\\n\\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\\n}\\nvec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {\\n\\treturn normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );\\n}\\nvec3 projectOnPlane(in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\\n\\tfloat distance = dot( planeNormal, point - pointOnPlane );\\n\\treturn - distance * planeNormal + point;\\n}\\nfloat sideOfPlane( in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\\n\\treturn sign( dot( point - pointOnPlane, planeNormal ) );\\n}\\nvec3 linePlaneIntersect( in vec3 pointOnLine, in vec3 lineDirection, in vec3 pointOnPlane, in vec3 planeNormal ) {\\n\\treturn lineDirection * ( dot( planeNormal, pointOnPlane - pointOnLine ) / dot( planeNormal, lineDirection ) ) + pointOnLine;\\n}\\nmat3 transposeMat3( const in mat3 m ) {\\n\\tmat3 tmp;\\n\\ttmp[ 0 ] = vec3( m[ 0 ].x, m[ 1 ].x, m[ 2 ].x );\\n\\ttmp[ 1 ] = vec3( m[ 0 ].y, m[ 1 ].y, m[ 2 ].y );\\n\\ttmp[ 2 ] = vec3( m[ 0 ].z, m[ 1 ].z, m[ 2 ].z );\\n\\treturn tmp;\\n}\\nfloat linearToRelativeLuminance( const in vec3 color ) {\\n\\tvec3 weights = vec3( 0.2126, 0.7152, 0.0722 );\\n\\treturn dot( weights, color.rgb );\\n}\\nbool isPerspectiveMatrix( mat4 m ) {\\n\\treturn m[ 2 ][ 3 ] == - 1.0;\\n}\\nvec2 equirectUv( in vec3 dir ) {\\n\\tfloat u = atan( dir.z, dir.x ) * RECIPROCAL_PI2 + 0.5;\\n\\tfloat v = asin( clamp( dir.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;\\n\\treturn vec2( u, v );\\n}\";\nvar cube_uv_reflection_fragment = \"#ifdef ENVMAP_TYPE_CUBE_UV\\n\\t#define cubeUV_maxMipLevel 8.0\\n\\t#define cubeUV_minMipLevel 4.0\\n\\t#define cubeUV_maxTileSize 256.0\\n\\t#define cubeUV_minTileSize 16.0\\n\\tfloat getFace( vec3 direction ) {\\n\\t\\tvec3 absDirection = abs( direction );\\n\\t\\tfloat face = - 1.0;\\n\\t\\tif ( absDirection.x > absDirection.z ) {\\n\\t\\t\\tif ( absDirection.x > absDirection.y )\\n\\t\\t\\t\\tface = direction.x > 0.0 ? 0.0 : 3.0;\\n\\t\\t\\telse\\n\\t\\t\\t\\tface = direction.y > 0.0 ? 1.0 : 4.0;\\n\\t\\t} else {\\n\\t\\t\\tif ( absDirection.z > absDirection.y )\\n\\t\\t\\t\\tface = direction.z > 0.0 ? 2.0 : 5.0;\\n\\t\\t\\telse\\n\\t\\t\\t\\tface = direction.y > 0.0 ? 1.0 : 4.0;\\n\\t\\t}\\n\\t\\treturn face;\\n\\t}\\n\\tvec2 getUV( vec3 direction, float face ) {\\n\\t\\tvec2 uv;\\n\\t\\tif ( face == 0.0 ) {\\n\\t\\t\\tuv = vec2( direction.z, direction.y ) / abs( direction.x );\\n\\t\\t} else if ( face == 1.0 ) {\\n\\t\\t\\tuv = vec2( - direction.x, - direction.z ) / abs( direction.y );\\n\\t\\t} else if ( face == 2.0 ) {\\n\\t\\t\\tuv = vec2( - direction.x, direction.y ) / abs( direction.z );\\n\\t\\t} else if ( face == 3.0 ) {\\n\\t\\t\\tuv = vec2( - direction.z, direction.y ) / abs( direction.x );\\n\\t\\t} else if ( face == 4.0 ) {\\n\\t\\t\\tuv = vec2( - direction.x, direction.z ) / abs( direction.y );\\n\\t\\t} else {\\n\\t\\t\\tuv = vec2( direction.x, direction.y ) / abs( direction.z );\\n\\t\\t}\\n\\t\\treturn 0.5 * ( uv + 1.0 );\\n\\t}\\n\\tvec3 bilinearCubeUV( sampler2D envMap, vec3 direction, float mipInt ) {\\n\\t\\tfloat face = getFace( direction );\\n\\t\\tfloat filterInt = max( cubeUV_minMipLevel - mipInt, 0.0 );\\n\\t\\tmipInt = max( mipInt, cubeUV_minMipLevel );\\n\\t\\tfloat faceSize = exp2( mipInt );\\n\\t\\tfloat texelSize = 1.0 / ( 3.0 * cubeUV_maxTileSize );\\n\\t\\tvec2 uv = getUV( direction, face ) * ( faceSize - 1.0 );\\n\\t\\tvec2 f = fract( uv );\\n\\t\\tuv += 0.5 - f;\\n\\t\\tif ( face > 2.0 ) {\\n\\t\\t\\tuv.y += faceSize;\\n\\t\\t\\tface -= 3.0;\\n\\t\\t}\\n\\t\\tuv.x += face * faceSize;\\n\\t\\tif ( mipInt < cubeUV_maxMipLevel ) {\\n\\t\\t\\tuv.y += 2.0 * cubeUV_maxTileSize;\\n\\t\\t}\\n\\t\\tuv.y += filterInt * 2.0 * cubeUV_minTileSize;\\n\\t\\tuv.x += 3.0 * max( 0.0, cubeUV_maxTileSize - 2.0 * faceSize );\\n\\t\\tuv *= texelSize;\\n\\t\\tvec3 tl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\\n\\t\\tuv.x += texelSize;\\n\\t\\tvec3 tr = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\\n\\t\\tuv.y += texelSize;\\n\\t\\tvec3 br = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\\n\\t\\tuv.x -= texelSize;\\n\\t\\tvec3 bl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\\n\\t\\tvec3 tm = mix( tl, tr, f.x );\\n\\t\\tvec3 bm = mix( bl, br, f.x );\\n\\t\\treturn mix( tm, bm, f.y );\\n\\t}\\n\\t#define r0 1.0\\n\\t#define v0 0.339\\n\\t#define m0 - 2.0\\n\\t#define r1 0.8\\n\\t#define v1 0.276\\n\\t#define m1 - 1.0\\n\\t#define r4 0.4\\n\\t#define v4 0.046\\n\\t#define m4 2.0\\n\\t#define r5 0.305\\n\\t#define v5 0.016\\n\\t#define m5 3.0\\n\\t#define r6 0.21\\n\\t#define v6 0.0038\\n\\t#define m6 4.0\\n\\tfloat roughnessToMip( float roughness ) {\\n\\t\\tfloat mip = 0.0;\\n\\t\\tif ( roughness >= r1 ) {\\n\\t\\t\\tmip = ( r0 - roughness ) * ( m1 - m0 ) / ( r0 - r1 ) + m0;\\n\\t\\t} else if ( roughness >= r4 ) {\\n\\t\\t\\tmip = ( r1 - roughness ) * ( m4 - m1 ) / ( r1 - r4 ) + m1;\\n\\t\\t} else if ( roughness >= r5 ) {\\n\\t\\t\\tmip = ( r4 - roughness ) * ( m5 - m4 ) / ( r4 - r5 ) + m4;\\n\\t\\t} else if ( roughness >= r6 ) {\\n\\t\\t\\tmip = ( r5 - roughness ) * ( m6 - m5 ) / ( r5 - r6 ) + m5;\\n\\t\\t} else {\\n\\t\\t\\tmip = - 2.0 * log2( 1.16 * roughness );\\t\\t}\\n\\t\\treturn mip;\\n\\t}\\n\\tvec4 textureCubeUV( sampler2D envMap, vec3 sampleDir, float roughness ) {\\n\\t\\tfloat mip = clamp( roughnessToMip( roughness ), m0, cubeUV_maxMipLevel );\\n\\t\\tfloat mipF = fract( mip );\\n\\t\\tfloat mipInt = floor( mip );\\n\\t\\tvec3 color0 = bilinearCubeUV( envMap, sampleDir, mipInt );\\n\\t\\tif ( mipF == 0.0 ) {\\n\\t\\t\\treturn vec4( color0, 1.0 );\\n\\t\\t} else {\\n\\t\\t\\tvec3 color1 = bilinearCubeUV( envMap, sampleDir, mipInt + 1.0 );\\n\\t\\t\\treturn vec4( mix( color0, color1, mipF ), 1.0 );\\n\\t\\t}\\n\\t}\\n#endif\";\nvar defaultnormal_vertex = \"vec3 transformedNormal = objectNormal;\\n#ifdef USE_INSTANCING\\n\\tmat3 m = mat3( instanceMatrix );\\n\\ttransformedNormal /= vec3( dot( m[ 0 ], m[ 0 ] ), dot( m[ 1 ], m[ 1 ] ), dot( m[ 2 ], m[ 2 ] ) );\\n\\ttransformedNormal = m * transformedNormal;\\n#endif\\ntransformedNormal = normalMatrix * transformedNormal;\\n#ifdef FLIP_SIDED\\n\\ttransformedNormal = - transformedNormal;\\n#endif\\n#ifdef USE_TANGENT\\n\\tvec3 transformedTangent = ( modelViewMatrix * vec4( objectTangent, 0.0 ) ).xyz;\\n\\t#ifdef FLIP_SIDED\\n\\t\\ttransformedTangent = - transformedTangent;\\n\\t#endif\\n#endif\";\nvar displacementmap_pars_vertex = \"#ifdef USE_DISPLACEMENTMAP\\n\\tuniform sampler2D displacementMap;\\n\\tuniform float displacementScale;\\n\\tuniform float displacementBias;\\n#endif\";\nvar displacementmap_vertex = \"#ifdef USE_DISPLACEMENTMAP\\n\\ttransformed += normalize( objectNormal ) * ( texture2D( displacementMap, vUv ).x * displacementScale + displacementBias );\\n#endif\";\nvar emissivemap_fragment = \"#ifdef USE_EMISSIVEMAP\\n\\tvec4 emissiveColor = texture2D( emissiveMap, vUv );\\n\\temissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;\\n\\ttotalEmissiveRadiance *= emissiveColor.rgb;\\n#endif\";\nvar emissivemap_pars_fragment = \"#ifdef USE_EMISSIVEMAP\\n\\tuniform sampler2D emissiveMap;\\n#endif\";\nvar encodings_fragment = \"gl_FragColor = linearToOutputTexel( gl_FragColor );\";\nvar encodings_pars_fragment = \"\\nvec4 LinearToLinear( in vec4 value ) {\\n\\treturn value;\\n}\\nvec4 GammaToLinear( in vec4 value, in float gammaFactor ) {\\n\\treturn vec4( pow( value.rgb, vec3( gammaFactor ) ), value.a );\\n}\\nvec4 LinearToGamma( in vec4 value, in float gammaFactor ) {\\n\\treturn vec4( pow( value.rgb, vec3( 1.0 / gammaFactor ) ), value.a );\\n}\\nvec4 sRGBToLinear( in vec4 value ) {\\n\\treturn vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.a );\\n}\\nvec4 LinearTosRGB( in vec4 value ) {\\n\\treturn vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.a );\\n}\\nvec4 RGBEToLinear( in vec4 value ) {\\n\\treturn vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );\\n}\\nvec4 LinearToRGBE( in vec4 value ) {\\n\\tfloat maxComponent = max( max( value.r, value.g ), value.b );\\n\\tfloat fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );\\n\\treturn vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );\\n}\\nvec4 RGBMToLinear( in vec4 value, in float maxRange ) {\\n\\treturn vec4( value.rgb * value.a * maxRange, 1.0 );\\n}\\nvec4 LinearToRGBM( in vec4 value, in float maxRange ) {\\n\\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\\n\\tfloat M = clamp( maxRGB / maxRange, 0.0, 1.0 );\\n\\tM = ceil( M * 255.0 ) / 255.0;\\n\\treturn vec4( value.rgb / ( M * maxRange ), M );\\n}\\nvec4 RGBDToLinear( in vec4 value, in float maxRange ) {\\n\\treturn vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );\\n}\\nvec4 LinearToRGBD( in vec4 value, in float maxRange ) {\\n\\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\\n\\tfloat D = max( maxRange / maxRGB, 1.0 );\\n\\tD = clamp( floor( D ) / 255.0, 0.0, 1.0 );\\n\\treturn vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );\\n}\\nconst mat3 cLogLuvM = mat3( 0.2209, 0.3390, 0.4184, 0.1138, 0.6780, 0.7319, 0.0102, 0.1130, 0.2969 );\\nvec4 LinearToLogLuv( in vec4 value ) {\\n\\tvec3 Xp_Y_XYZp = cLogLuvM * value.rgb;\\n\\tXp_Y_XYZp = max( Xp_Y_XYZp, vec3( 1e-6, 1e-6, 1e-6 ) );\\n\\tvec4 vResult;\\n\\tvResult.xy = Xp_Y_XYZp.xy / Xp_Y_XYZp.z;\\n\\tfloat Le = 2.0 * log2(Xp_Y_XYZp.y) + 127.0;\\n\\tvResult.w = fract( Le );\\n\\tvResult.z = ( Le - ( floor( vResult.w * 255.0 ) ) / 255.0 ) / 255.0;\\n\\treturn vResult;\\n}\\nconst mat3 cLogLuvInverseM = mat3( 6.0014, -2.7008, -1.7996, -1.3320, 3.1029, -5.7721, 0.3008, -1.0882, 5.6268 );\\nvec4 LogLuvToLinear( in vec4 value ) {\\n\\tfloat Le = value.z * 255.0 + value.w;\\n\\tvec3 Xp_Y_XYZp;\\n\\tXp_Y_XYZp.y = exp2( ( Le - 127.0 ) / 2.0 );\\n\\tXp_Y_XYZp.z = Xp_Y_XYZp.y / value.y;\\n\\tXp_Y_XYZp.x = value.x * Xp_Y_XYZp.z;\\n\\tvec3 vRGB = cLogLuvInverseM * Xp_Y_XYZp.rgb;\\n\\treturn vec4( max( vRGB, 0.0 ), 1.0 );\\n}\";\nvar envmap_fragment = \"#ifdef USE_ENVMAP\\n\\t#ifdef ENV_WORLDPOS\\n\\t\\tvec3 cameraToFrag;\\n\\t\\tif ( isOrthographic ) {\\n\\t\\t\\tcameraToFrag = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\\n\\t\\t} else {\\n\\t\\t\\tcameraToFrag = normalize( vWorldPosition - cameraPosition );\\n\\t\\t}\\n\\t\\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\\n\\t\\t#ifdef ENVMAP_MODE_REFLECTION\\n\\t\\t\\tvec3 reflectVec = reflect( cameraToFrag, worldNormal );\\n\\t\\t#else\\n\\t\\t\\tvec3 reflectVec = refract( cameraToFrag, worldNormal, refractionRatio );\\n\\t\\t#endif\\n\\t#else\\n\\t\\tvec3 reflectVec = vReflect;\\n\\t#endif\\n\\t#ifdef ENVMAP_TYPE_CUBE\\n\\t\\tvec4 envColor = textureCube( envMap, vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );\\n\\t#elif defined( ENVMAP_TYPE_CUBE_UV )\\n\\t\\tvec4 envColor = textureCubeUV( envMap, reflectVec, 0.0 );\\n\\t#else\\n\\t\\tvec4 envColor = vec4( 0.0 );\\n\\t#endif\\n\\t#ifndef ENVMAP_TYPE_CUBE_UV\\n\\t\\tenvColor = envMapTexelToLinear( envColor );\\n\\t#endif\\n\\t#ifdef ENVMAP_BLENDING_MULTIPLY\\n\\t\\toutgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );\\n\\t#elif defined( ENVMAP_BLENDING_MIX )\\n\\t\\toutgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );\\n\\t#elif defined( ENVMAP_BLENDING_ADD )\\n\\t\\toutgoingLight += envColor.xyz * specularStrength * reflectivity;\\n\\t#endif\\n#endif\";\nvar envmap_common_pars_fragment = \"#ifdef USE_ENVMAP\\n\\tuniform float envMapIntensity;\\n\\tuniform float flipEnvMap;\\n\\tuniform int maxMipLevel;\\n\\t#ifdef ENVMAP_TYPE_CUBE\\n\\t\\tuniform samplerCube envMap;\\n\\t#else\\n\\t\\tuniform sampler2D envMap;\\n\\t#endif\\n\\t\\n#endif\";\nvar envmap_pars_fragment = \"#ifdef USE_ENVMAP\\n\\tuniform float reflectivity;\\n\\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\\n\\t\\t#define ENV_WORLDPOS\\n\\t#endif\\n\\t#ifdef ENV_WORLDPOS\\n\\t\\tvarying vec3 vWorldPosition;\\n\\t\\tuniform float refractionRatio;\\n\\t#else\\n\\t\\tvarying vec3 vReflect;\\n\\t#endif\\n#endif\";\nvar envmap_pars_vertex = \"#ifdef USE_ENVMAP\\n\\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) ||defined( PHONG )\\n\\t\\t#define ENV_WORLDPOS\\n\\t#endif\\n\\t#ifdef ENV_WORLDPOS\\n\\t\\t\\n\\t\\tvarying vec3 vWorldPosition;\\n\\t#else\\n\\t\\tvarying vec3 vReflect;\\n\\t\\tuniform float refractionRatio;\\n\\t#endif\\n#endif\";\nvar envmap_vertex = \"#ifdef USE_ENVMAP\\n\\t#ifdef ENV_WORLDPOS\\n\\t\\tvWorldPosition = worldPosition.xyz;\\n\\t#else\\n\\t\\tvec3 cameraToVertex;\\n\\t\\tif ( isOrthographic ) {\\n\\t\\t\\tcameraToVertex = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\\n\\t\\t} else {\\n\\t\\t\\tcameraToVertex = normalize( worldPosition.xyz - cameraPosition );\\n\\t\\t}\\n\\t\\tvec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\\n\\t\\t#ifdef ENVMAP_MODE_REFLECTION\\n\\t\\t\\tvReflect = reflect( cameraToVertex, worldNormal );\\n\\t\\t#else\\n\\t\\t\\tvReflect = refract( cameraToVertex, worldNormal, refractionRatio );\\n\\t\\t#endif\\n\\t#endif\\n#endif\";\nvar fog_vertex = \"#ifdef USE_FOG\\n\\tfogDepth = - mvPosition.z;\\n#endif\";\nvar fog_pars_vertex = \"#ifdef USE_FOG\\n\\tvarying float fogDepth;\\n#endif\";\nvar fog_fragment = \"#ifdef USE_FOG\\n\\t#ifdef FOG_EXP2\\n\\t\\tfloat fogFactor = 1.0 - exp( - fogDensity * fogDensity * fogDepth * fogDepth );\\n\\t#else\\n\\t\\tfloat fogFactor = smoothstep( fogNear, fogFar, fogDepth );\\n\\t#endif\\n\\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\\n#endif\";\nvar fog_pars_fragment = \"#ifdef USE_FOG\\n\\tuniform vec3 fogColor;\\n\\tvarying float fogDepth;\\n\\t#ifdef FOG_EXP2\\n\\t\\tuniform float fogDensity;\\n\\t#else\\n\\t\\tuniform float fogNear;\\n\\t\\tuniform float fogFar;\\n\\t#endif\\n#endif\";\nvar gradientmap_pars_fragment = \"#ifdef USE_GRADIENTMAP\\n\\tuniform sampler2D gradientMap;\\n#endif\\nvec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {\\n\\tfloat dotNL = dot( normal, lightDirection );\\n\\tvec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );\\n\\t#ifdef USE_GRADIENTMAP\\n\\t\\treturn texture2D( gradientMap, coord ).rgb;\\n\\t#else\\n\\t\\treturn ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );\\n\\t#endif\\n}\";\nvar lightmap_fragment = \"#ifdef USE_LIGHTMAP\\n\\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\\n\\treflectedLight.indirectDiffuse += PI * lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\\n#endif\";\nvar lightmap_pars_fragment = \"#ifdef USE_LIGHTMAP\\n\\tuniform sampler2D lightMap;\\n\\tuniform float lightMapIntensity;\\n#endif\";\nvar lights_lambert_vertex = \"vec3 diffuse = vec3( 1.0 );\\nGeometricContext geometry;\\ngeometry.position = mvPosition.xyz;\\ngeometry.normal = normalize( transformedNormal );\\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( -mvPosition.xyz );\\nGeometricContext backGeometry;\\nbackGeometry.position = geometry.position;\\nbackGeometry.normal = -geometry.normal;\\nbackGeometry.viewDir = geometry.viewDir;\\nvLightFront = vec3( 0.0 );\\nvIndirectFront = vec3( 0.0 );\\n#ifdef DOUBLE_SIDED\\n\\tvLightBack = vec3( 0.0 );\\n\\tvIndirectBack = vec3( 0.0 );\\n#endif\\nIncidentLight directLight;\\nfloat dotNL;\\nvec3 directLightColor_Diffuse;\\nvIndirectFront += getAmbientLightIrradiance( ambientLightColor );\\nvIndirectFront += getLightProbeIrradiance( lightProbe, geometry );\\n#ifdef DOUBLE_SIDED\\n\\tvIndirectBack += getAmbientLightIrradiance( ambientLightColor );\\n\\tvIndirectBack += getLightProbeIrradiance( lightProbe, backGeometry );\\n#endif\\n#if NUM_POINT_LIGHTS > 0\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\\n\\t\\tgetPointDirectLightIrradiance( pointLights[ i ], geometry, directLight );\\n\\t\\tdotNL = dot( geometry.normal, directLight.direction );\\n\\t\\tdirectLightColor_Diffuse = PI * directLight.color;\\n\\t\\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\\n\\t\\t#ifdef DOUBLE_SIDED\\n\\t\\t\\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\\n\\t\\t#endif\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\\n#if NUM_SPOT_LIGHTS > 0\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\\n\\t\\tgetSpotDirectLightIrradiance( spotLights[ i ], geometry, directLight );\\n\\t\\tdotNL = dot( geometry.normal, directLight.direction );\\n\\t\\tdirectLightColor_Diffuse = PI * directLight.color;\\n\\t\\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\\n\\t\\t#ifdef DOUBLE_SIDED\\n\\t\\t\\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\\n\\t\\t#endif\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\\n#if NUM_DIR_LIGHTS > 0\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\\n\\t\\tgetDirectionalDirectLightIrradiance( directionalLights[ i ], geometry, directLight );\\n\\t\\tdotNL = dot( geometry.normal, directLight.direction );\\n\\t\\tdirectLightColor_Diffuse = PI * directLight.color;\\n\\t\\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\\n\\t\\t#ifdef DOUBLE_SIDED\\n\\t\\t\\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\\n\\t\\t#endif\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\\n#if NUM_HEMI_LIGHTS > 0\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\\n\\t\\tvIndirectFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\\n\\t\\t#ifdef DOUBLE_SIDED\\n\\t\\t\\tvIndirectBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry );\\n\\t\\t#endif\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\";\nvar lights_pars_begin = \"uniform bool receiveShadow;\\nuniform vec3 ambientLightColor;\\nuniform vec3 lightProbe[ 9 ];\\nvec3 shGetIrradianceAt( in vec3 normal, in vec3 shCoefficients[ 9 ] ) {\\n\\tfloat x = normal.x, y = normal.y, z = normal.z;\\n\\tvec3 result = shCoefficients[ 0 ] * 0.886227;\\n\\tresult += shCoefficients[ 1 ] * 2.0 * 0.511664 * y;\\n\\tresult += shCoefficients[ 2 ] * 2.0 * 0.511664 * z;\\n\\tresult += shCoefficients[ 3 ] * 2.0 * 0.511664 * x;\\n\\tresult += shCoefficients[ 4 ] * 2.0 * 0.429043 * x * y;\\n\\tresult += shCoefficients[ 5 ] * 2.0 * 0.429043 * y * z;\\n\\tresult += shCoefficients[ 6 ] * ( 0.743125 * z * z - 0.247708 );\\n\\tresult += shCoefficients[ 7 ] * 2.0 * 0.429043 * x * z;\\n\\tresult += shCoefficients[ 8 ] * 0.429043 * ( x * x - y * y );\\n\\treturn result;\\n}\\nvec3 getLightProbeIrradiance( const in vec3 lightProbe[ 9 ], const in GeometricContext geometry ) {\\n\\tvec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );\\n\\tvec3 irradiance = shGetIrradianceAt( worldNormal, lightProbe );\\n\\treturn irradiance;\\n}\\nvec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {\\n\\tvec3 irradiance = ambientLightColor;\\n\\t#ifndef PHYSICALLY_CORRECT_LIGHTS\\n\\t\\tirradiance *= PI;\\n\\t#endif\\n\\treturn irradiance;\\n}\\n#if NUM_DIR_LIGHTS > 0\\n\\tstruct DirectionalLight {\\n\\t\\tvec3 direction;\\n\\t\\tvec3 color;\\n\\t};\\n\\tuniform DirectionalLight directionalLights[ NUM_DIR_LIGHTS ];\\n\\tvoid getDirectionalDirectLightIrradiance( const in DirectionalLight directionalLight, const in GeometricContext geometry, out IncidentLight directLight ) {\\n\\t\\tdirectLight.color = directionalLight.color;\\n\\t\\tdirectLight.direction = directionalLight.direction;\\n\\t\\tdirectLight.visible = true;\\n\\t}\\n#endif\\n#if NUM_POINT_LIGHTS > 0\\n\\tstruct PointLight {\\n\\t\\tvec3 position;\\n\\t\\tvec3 color;\\n\\t\\tfloat distance;\\n\\t\\tfloat decay;\\n\\t};\\n\\tuniform PointLight pointLights[ NUM_POINT_LIGHTS ];\\n\\tvoid getPointDirectLightIrradiance( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight directLight ) {\\n\\t\\tvec3 lVector = pointLight.position - geometry.position;\\n\\t\\tdirectLight.direction = normalize( lVector );\\n\\t\\tfloat lightDistance = length( lVector );\\n\\t\\tdirectLight.color = pointLight.color;\\n\\t\\tdirectLight.color *= punctualLightIntensityToIrradianceFactor( lightDistance, pointLight.distance, pointLight.decay );\\n\\t\\tdirectLight.visible = ( directLight.color != vec3( 0.0 ) );\\n\\t}\\n#endif\\n#if NUM_SPOT_LIGHTS > 0\\n\\tstruct SpotLight {\\n\\t\\tvec3 position;\\n\\t\\tvec3 direction;\\n\\t\\tvec3 color;\\n\\t\\tfloat distance;\\n\\t\\tfloat decay;\\n\\t\\tfloat coneCos;\\n\\t\\tfloat penumbraCos;\\n\\t};\\n\\tuniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];\\n\\tvoid getSpotDirectLightIrradiance( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight directLight ) {\\n\\t\\tvec3 lVector = spotLight.position - geometry.position;\\n\\t\\tdirectLight.direction = normalize( lVector );\\n\\t\\tfloat lightDistance = length( lVector );\\n\\t\\tfloat angleCos = dot( directLight.direction, spotLight.direction );\\n\\t\\tif ( angleCos > spotLight.coneCos ) {\\n\\t\\t\\tfloat spotEffect = smoothstep( spotLight.coneCos, spotLight.penumbraCos, angleCos );\\n\\t\\t\\tdirectLight.color = spotLight.color;\\n\\t\\t\\tdirectLight.color *= spotEffect * punctualLightIntensityToIrradianceFactor( lightDistance, spotLight.distance, spotLight.decay );\\n\\t\\t\\tdirectLight.visible = true;\\n\\t\\t} else {\\n\\t\\t\\tdirectLight.color = vec3( 0.0 );\\n\\t\\t\\tdirectLight.visible = false;\\n\\t\\t}\\n\\t}\\n#endif\\n#if NUM_RECT_AREA_LIGHTS > 0\\n\\tstruct RectAreaLight {\\n\\t\\tvec3 color;\\n\\t\\tvec3 position;\\n\\t\\tvec3 halfWidth;\\n\\t\\tvec3 halfHeight;\\n\\t};\\n\\tuniform sampler2D ltc_1;\\tuniform sampler2D ltc_2;\\n\\tuniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];\\n#endif\\n#if NUM_HEMI_LIGHTS > 0\\n\\tstruct HemisphereLight {\\n\\t\\tvec3 direction;\\n\\t\\tvec3 skyColor;\\n\\t\\tvec3 groundColor;\\n\\t};\\n\\tuniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];\\n\\tvec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in GeometricContext geometry ) {\\n\\t\\tfloat dotNL = dot( geometry.normal, hemiLight.direction );\\n\\t\\tfloat hemiDiffuseWeight = 0.5 * dotNL + 0.5;\\n\\t\\tvec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );\\n\\t\\t#ifndef PHYSICALLY_CORRECT_LIGHTS\\n\\t\\t\\tirradiance *= PI;\\n\\t\\t#endif\\n\\t\\treturn irradiance;\\n\\t}\\n#endif\";\nvar envmap_physical_pars_fragment = \"#if defined( USE_ENVMAP )\\n\\t#ifdef ENVMAP_MODE_REFRACTION\\n\\t\\tuniform float refractionRatio;\\n\\t#endif\\n\\tvec3 getLightProbeIndirectIrradiance( const in GeometricContext geometry, const in int maxMIPLevel ) {\\n\\t\\tvec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );\\n\\t\\t#ifdef ENVMAP_TYPE_CUBE\\n\\t\\t\\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\\n\\t\\t\\t#ifdef TEXTURE_LOD_EXT\\n\\t\\t\\t\\tvec4 envMapColor = textureCubeLodEXT( envMap, queryVec, float( maxMIPLevel ) );\\n\\t\\t\\t#else\\n\\t\\t\\t\\tvec4 envMapColor = textureCube( envMap, queryVec, float( maxMIPLevel ) );\\n\\t\\t\\t#endif\\n\\t\\t\\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\\n\\t\\t#elif defined( ENVMAP_TYPE_CUBE_UV )\\n\\t\\t\\tvec4 envMapColor = textureCubeUV( envMap, worldNormal, 1.0 );\\n\\t\\t#else\\n\\t\\t\\tvec4 envMapColor = vec4( 0.0 );\\n\\t\\t#endif\\n\\t\\treturn PI * envMapColor.rgb * envMapIntensity;\\n\\t}\\n\\tfloat getSpecularMIPLevel( const in float roughness, const in int maxMIPLevel ) {\\n\\t\\tfloat maxMIPLevelScalar = float( maxMIPLevel );\\n\\t\\tfloat sigma = PI * roughness * roughness / ( 1.0 + roughness );\\n\\t\\tfloat desiredMIPLevel = maxMIPLevelScalar + log2( sigma );\\n\\t\\treturn clamp( desiredMIPLevel, 0.0, maxMIPLevelScalar );\\n\\t}\\n\\tvec3 getLightProbeIndirectRadiance( const in vec3 viewDir, const in vec3 normal, const in float roughness, const in int maxMIPLevel ) {\\n\\t\\t#ifdef ENVMAP_MODE_REFLECTION\\n\\t\\t\\tvec3 reflectVec = reflect( -viewDir, normal );\\n\\t\\t\\treflectVec = normalize( mix( reflectVec, normal, roughness * roughness) );\\n\\t\\t#else\\n\\t\\t\\tvec3 reflectVec = refract( -viewDir, normal, refractionRatio );\\n\\t\\t#endif\\n\\t\\treflectVec = inverseTransformDirection( reflectVec, viewMatrix );\\n\\t\\tfloat specularMIPLevel = getSpecularMIPLevel( roughness, maxMIPLevel );\\n\\t\\t#ifdef ENVMAP_TYPE_CUBE\\n\\t\\t\\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\\n\\t\\t\\t#ifdef TEXTURE_LOD_EXT\\n\\t\\t\\t\\tvec4 envMapColor = textureCubeLodEXT( envMap, queryReflectVec, specularMIPLevel );\\n\\t\\t\\t#else\\n\\t\\t\\t\\tvec4 envMapColor = textureCube( envMap, queryReflectVec, specularMIPLevel );\\n\\t\\t\\t#endif\\n\\t\\t\\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\\n\\t\\t#elif defined( ENVMAP_TYPE_CUBE_UV )\\n\\t\\t\\tvec4 envMapColor = textureCubeUV( envMap, reflectVec, roughness );\\n\\t\\t#endif\\n\\t\\treturn envMapColor.rgb * envMapIntensity;\\n\\t}\\n#endif\";\nvar lights_toon_fragment = \"ToonMaterial material;\\nmaterial.diffuseColor = diffuseColor.rgb;\";\nvar lights_toon_pars_fragment = \"varying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n#endif\\nstruct ToonMaterial {\\n\\tvec3 diffuseColor;\\n};\\nvoid RE_Direct_Toon( const in IncidentLight directLight, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\\n\\tvec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;\\n\\t#ifndef PHYSICALLY_CORRECT_LIGHTS\\n\\t\\tirradiance *= PI;\\n\\t#endif\\n\\treflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\\n}\\nvoid RE_IndirectDiffuse_Toon( const in vec3 irradiance, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\\n\\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\\n}\\n#define RE_Direct\\t\\t\\t\\tRE_Direct_Toon\\n#define RE_IndirectDiffuse\\t\\tRE_IndirectDiffuse_Toon\\n#define Material_LightProbeLOD( material )\\t(0)\";\nvar lights_phong_fragment = \"BlinnPhongMaterial material;\\nmaterial.diffuseColor = diffuseColor.rgb;\\nmaterial.specularColor = specular;\\nmaterial.specularShininess = shininess;\\nmaterial.specularStrength = specularStrength;\";\nvar lights_phong_pars_fragment = \"varying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n#endif\\nstruct BlinnPhongMaterial {\\n\\tvec3 diffuseColor;\\n\\tvec3 specularColor;\\n\\tfloat specularShininess;\\n\\tfloat specularStrength;\\n};\\nvoid RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\\n\\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\\n\\tvec3 irradiance = dotNL * directLight.color;\\n\\t#ifndef PHYSICALLY_CORRECT_LIGHTS\\n\\t\\tirradiance *= PI;\\n\\t#endif\\n\\treflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\\n\\treflectedLight.directSpecular += irradiance * BRDF_Specular_BlinnPhong( directLight, geometry, material.specularColor, material.specularShininess ) * material.specularStrength;\\n}\\nvoid RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\\n\\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\\n}\\n#define RE_Direct\\t\\t\\t\\tRE_Direct_BlinnPhong\\n#define RE_IndirectDiffuse\\t\\tRE_IndirectDiffuse_BlinnPhong\\n#define Material_LightProbeLOD( material )\\t(0)\";\nvar lights_physical_fragment = \"PhysicalMaterial material;\\nmaterial.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );\\nvec3 dxy = max( abs( dFdx( geometryNormal ) ), abs( dFdy( geometryNormal ) ) );\\nfloat geometryRoughness = max( max( dxy.x, dxy.y ), dxy.z );\\nmaterial.specularRoughness = max( roughnessFactor, 0.0525 );material.specularRoughness += geometryRoughness;\\nmaterial.specularRoughness = min( material.specularRoughness, 1.0 );\\n#ifdef REFLECTIVITY\\n\\tmaterial.specularColor = mix( vec3( MAXIMUM_SPECULAR_COEFFICIENT * pow2( reflectivity ) ), diffuseColor.rgb, metalnessFactor );\\n#else\\n\\tmaterial.specularColor = mix( vec3( DEFAULT_SPECULAR_COEFFICIENT ), diffuseColor.rgb, metalnessFactor );\\n#endif\\n#ifdef CLEARCOAT\\n\\tmaterial.clearcoat = clearcoat;\\n\\tmaterial.clearcoatRoughness = clearcoatRoughness;\\n\\t#ifdef USE_CLEARCOATMAP\\n\\t\\tmaterial.clearcoat *= texture2D( clearcoatMap, vUv ).x;\\n\\t#endif\\n\\t#ifdef USE_CLEARCOAT_ROUGHNESSMAP\\n\\t\\tmaterial.clearcoatRoughness *= texture2D( clearcoatRoughnessMap, vUv ).y;\\n\\t#endif\\n\\tmaterial.clearcoat = saturate( material.clearcoat );\\tmaterial.clearcoatRoughness = max( material.clearcoatRoughness, 0.0525 );\\n\\tmaterial.clearcoatRoughness += geometryRoughness;\\n\\tmaterial.clearcoatRoughness = min( material.clearcoatRoughness, 1.0 );\\n#endif\\n#ifdef USE_SHEEN\\n\\tmaterial.sheenColor = sheen;\\n#endif\";\nvar lights_physical_pars_fragment = \"struct PhysicalMaterial {\\n\\tvec3 diffuseColor;\\n\\tfloat specularRoughness;\\n\\tvec3 specularColor;\\n#ifdef CLEARCOAT\\n\\tfloat clearcoat;\\n\\tfloat clearcoatRoughness;\\n#endif\\n#ifdef USE_SHEEN\\n\\tvec3 sheenColor;\\n#endif\\n};\\n#define MAXIMUM_SPECULAR_COEFFICIENT 0.16\\n#define DEFAULT_SPECULAR_COEFFICIENT 0.04\\nfloat clearcoatDHRApprox( const in float roughness, const in float dotNL ) {\\n\\treturn DEFAULT_SPECULAR_COEFFICIENT + ( 1.0 - DEFAULT_SPECULAR_COEFFICIENT ) * ( pow( 1.0 - dotNL, 5.0 ) * pow( 1.0 - roughness, 2.0 ) );\\n}\\n#if NUM_RECT_AREA_LIGHTS > 0\\n\\tvoid RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\\n\\t\\tvec3 normal = geometry.normal;\\n\\t\\tvec3 viewDir = geometry.viewDir;\\n\\t\\tvec3 position = geometry.position;\\n\\t\\tvec3 lightPos = rectAreaLight.position;\\n\\t\\tvec3 halfWidth = rectAreaLight.halfWidth;\\n\\t\\tvec3 halfHeight = rectAreaLight.halfHeight;\\n\\t\\tvec3 lightColor = rectAreaLight.color;\\n\\t\\tfloat roughness = material.specularRoughness;\\n\\t\\tvec3 rectCoords[ 4 ];\\n\\t\\trectCoords[ 0 ] = lightPos + halfWidth - halfHeight;\\t\\trectCoords[ 1 ] = lightPos - halfWidth - halfHeight;\\n\\t\\trectCoords[ 2 ] = lightPos - halfWidth + halfHeight;\\n\\t\\trectCoords[ 3 ] = lightPos + halfWidth + halfHeight;\\n\\t\\tvec2 uv = LTC_Uv( normal, viewDir, roughness );\\n\\t\\tvec4 t1 = texture2D( ltc_1, uv );\\n\\t\\tvec4 t2 = texture2D( ltc_2, uv );\\n\\t\\tmat3 mInv = mat3(\\n\\t\\t\\tvec3( t1.x, 0, t1.y ),\\n\\t\\t\\tvec3(    0, 1,    0 ),\\n\\t\\t\\tvec3( t1.z, 0, t1.w )\\n\\t\\t);\\n\\t\\tvec3 fresnel = ( material.specularColor * t2.x + ( vec3( 1.0 ) - material.specularColor ) * t2.y );\\n\\t\\treflectedLight.directSpecular += lightColor * fresnel * LTC_Evaluate( normal, viewDir, position, mInv, rectCoords );\\n\\t\\treflectedLight.directDiffuse += lightColor * material.diffuseColor * LTC_Evaluate( normal, viewDir, position, mat3( 1.0 ), rectCoords );\\n\\t}\\n#endif\\nvoid RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\\n\\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\\n\\tvec3 irradiance = dotNL * directLight.color;\\n\\t#ifndef PHYSICALLY_CORRECT_LIGHTS\\n\\t\\tirradiance *= PI;\\n\\t#endif\\n\\t#ifdef CLEARCOAT\\n\\t\\tfloat ccDotNL = saturate( dot( geometry.clearcoatNormal, directLight.direction ) );\\n\\t\\tvec3 ccIrradiance = ccDotNL * directLight.color;\\n\\t\\t#ifndef PHYSICALLY_CORRECT_LIGHTS\\n\\t\\t\\tccIrradiance *= PI;\\n\\t\\t#endif\\n\\t\\tfloat clearcoatDHR = material.clearcoat * clearcoatDHRApprox( material.clearcoatRoughness, ccDotNL );\\n\\t\\treflectedLight.directSpecular += ccIrradiance * material.clearcoat * BRDF_Specular_GGX( directLight, geometry.viewDir, geometry.clearcoatNormal, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearcoatRoughness );\\n\\t#else\\n\\t\\tfloat clearcoatDHR = 0.0;\\n\\t#endif\\n\\t#ifdef USE_SHEEN\\n\\t\\treflectedLight.directSpecular += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Specular_Sheen(\\n\\t\\t\\tmaterial.specularRoughness,\\n\\t\\t\\tdirectLight.direction,\\n\\t\\t\\tgeometry,\\n\\t\\t\\tmaterial.sheenColor\\n\\t\\t);\\n\\t#else\\n\\t\\treflectedLight.directSpecular += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Specular_GGX( directLight, geometry.viewDir, geometry.normal, material.specularColor, material.specularRoughness);\\n\\t#endif\\n\\treflectedLight.directDiffuse += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\\n}\\nvoid RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\\n\\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\\n}\\nvoid RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 irradiance, const in vec3 clearcoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight) {\\n\\t#ifdef CLEARCOAT\\n\\t\\tfloat ccDotNV = saturate( dot( geometry.clearcoatNormal, geometry.viewDir ) );\\n\\t\\treflectedLight.indirectSpecular += clearcoatRadiance * material.clearcoat * BRDF_Specular_GGX_Environment( geometry.viewDir, geometry.clearcoatNormal, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearcoatRoughness );\\n\\t\\tfloat ccDotNL = ccDotNV;\\n\\t\\tfloat clearcoatDHR = material.clearcoat * clearcoatDHRApprox( material.clearcoatRoughness, ccDotNL );\\n\\t#else\\n\\t\\tfloat clearcoatDHR = 0.0;\\n\\t#endif\\n\\tfloat clearcoatInv = 1.0 - clearcoatDHR;\\n\\tvec3 singleScattering = vec3( 0.0 );\\n\\tvec3 multiScattering = vec3( 0.0 );\\n\\tvec3 cosineWeightedIrradiance = irradiance * RECIPROCAL_PI;\\n\\tBRDF_Specular_Multiscattering_Environment( geometry, material.specularColor, material.specularRoughness, singleScattering, multiScattering );\\n\\tvec3 diffuse = material.diffuseColor * ( 1.0 - ( singleScattering + multiScattering ) );\\n\\treflectedLight.indirectSpecular += clearcoatInv * radiance * singleScattering;\\n\\treflectedLight.indirectSpecular += multiScattering * cosineWeightedIrradiance;\\n\\treflectedLight.indirectDiffuse += diffuse * cosineWeightedIrradiance;\\n}\\n#define RE_Direct\\t\\t\\t\\tRE_Direct_Physical\\n#define RE_Direct_RectArea\\t\\tRE_Direct_RectArea_Physical\\n#define RE_IndirectDiffuse\\t\\tRE_IndirectDiffuse_Physical\\n#define RE_IndirectSpecular\\t\\tRE_IndirectSpecular_Physical\\nfloat computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {\\n\\treturn saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );\\n}\";\nvar lights_fragment_begin = \"\\nGeometricContext geometry;\\ngeometry.position = - vViewPosition;\\ngeometry.normal = normal;\\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( vViewPosition );\\n#ifdef CLEARCOAT\\n\\tgeometry.clearcoatNormal = clearcoatNormal;\\n#endif\\nIncidentLight directLight;\\n#if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )\\n\\tPointLight pointLight;\\n\\t#if defined( USE_SHADOWMAP ) && NUM_POINT_LIGHT_SHADOWS > 0\\n\\tPointLightShadow pointLightShadow;\\n\\t#endif\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\\n\\t\\tpointLight = pointLights[ i ];\\n\\t\\tgetPointDirectLightIrradiance( pointLight, geometry, directLight );\\n\\t\\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_POINT_LIGHT_SHADOWS )\\n\\t\\tpointLightShadow = pointLightShadows[ i ];\\n\\t\\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getPointShadow( pointShadowMap[ i ], pointLightShadow.shadowMapSize, pointLightShadow.shadowBias, pointLightShadow.shadowRadius, vPointShadowCoord[ i ], pointLightShadow.shadowCameraNear, pointLightShadow.shadowCameraFar ) : 1.0;\\n\\t\\t#endif\\n\\t\\tRE_Direct( directLight, geometry, material, reflectedLight );\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\\n#if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )\\n\\tSpotLight spotLight;\\n\\t#if defined( USE_SHADOWMAP ) && NUM_SPOT_LIGHT_SHADOWS > 0\\n\\tSpotLightShadow spotLightShadow;\\n\\t#endif\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\\n\\t\\tspotLight = spotLights[ i ];\\n\\t\\tgetSpotDirectLightIrradiance( spotLight, geometry, directLight );\\n\\t\\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_SPOT_LIGHT_SHADOWS )\\n\\t\\tspotLightShadow = spotLightShadows[ i ];\\n\\t\\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLightShadow.shadowMapSize, spotLightShadow.shadowBias, spotLightShadow.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\\n\\t\\t#endif\\n\\t\\tRE_Direct( directLight, geometry, material, reflectedLight );\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\\n#if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )\\n\\tDirectionalLight directionalLight;\\n\\t#if defined( USE_SHADOWMAP ) && NUM_DIR_LIGHT_SHADOWS > 0\\n\\tDirectionalLightShadow directionalLightShadow;\\n\\t#endif\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\\n\\t\\tdirectionalLight = directionalLights[ i ];\\n\\t\\tgetDirectionalDirectLightIrradiance( directionalLight, geometry, directLight );\\n\\t\\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_DIR_LIGHT_SHADOWS )\\n\\t\\tdirectionalLightShadow = directionalLightShadows[ i ];\\n\\t\\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( directionalShadowMap[ i ], directionalLightShadow.shadowMapSize, directionalLightShadow.shadowBias, directionalLightShadow.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\\n\\t\\t#endif\\n\\t\\tRE_Direct( directLight, geometry, material, reflectedLight );\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\\n#if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )\\n\\tRectAreaLight rectAreaLight;\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\\n\\t\\trectAreaLight = rectAreaLights[ i ];\\n\\t\\tRE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );\\n\\t}\\n\\t#pragma unroll_loop_end\\n#endif\\n#if defined( RE_IndirectDiffuse )\\n\\tvec3 iblIrradiance = vec3( 0.0 );\\n\\tvec3 irradiance = getAmbientLightIrradiance( ambientLightColor );\\n\\tirradiance += getLightProbeIrradiance( lightProbe, geometry );\\n\\t#if ( NUM_HEMI_LIGHTS > 0 )\\n\\t\\t#pragma unroll_loop_start\\n\\t\\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\\n\\t\\t\\tirradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\\n\\t\\t}\\n\\t\\t#pragma unroll_loop_end\\n\\t#endif\\n#endif\\n#if defined( RE_IndirectSpecular )\\n\\tvec3 radiance = vec3( 0.0 );\\n\\tvec3 clearcoatRadiance = vec3( 0.0 );\\n#endif\";\nvar lights_fragment_maps = \"#if defined( RE_IndirectDiffuse )\\n\\t#ifdef USE_LIGHTMAP\\n\\t\\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\\n\\t\\tvec3 lightMapIrradiance = lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\\n\\t\\t#ifndef PHYSICALLY_CORRECT_LIGHTS\\n\\t\\t\\tlightMapIrradiance *= PI;\\n\\t\\t#endif\\n\\t\\tirradiance += lightMapIrradiance;\\n\\t#endif\\n\\t#if defined( USE_ENVMAP ) && defined( STANDARD ) && defined( ENVMAP_TYPE_CUBE_UV )\\n\\t\\tiblIrradiance += getLightProbeIndirectIrradiance( geometry, maxMipLevel );\\n\\t#endif\\n#endif\\n#if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )\\n\\tradiance += getLightProbeIndirectRadiance( geometry.viewDir, geometry.normal, material.specularRoughness, maxMipLevel );\\n\\t#ifdef CLEARCOAT\\n\\t\\tclearcoatRadiance += getLightProbeIndirectRadiance( geometry.viewDir, geometry.clearcoatNormal, material.clearcoatRoughness, maxMipLevel );\\n\\t#endif\\n#endif\";\nvar lights_fragment_end = \"#if defined( RE_IndirectDiffuse )\\n\\tRE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );\\n#endif\\n#if defined( RE_IndirectSpecular )\\n\\tRE_IndirectSpecular( radiance, iblIrradiance, clearcoatRadiance, geometry, material, reflectedLight );\\n#endif\";\nvar logdepthbuf_fragment = \"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\\n\\tgl_FragDepthEXT = vIsPerspective == 0.0 ? gl_FragCoord.z : log2( vFragDepth ) * logDepthBufFC * 0.5;\\n#endif\";\nvar logdepthbuf_pars_fragment = \"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\\n\\tuniform float logDepthBufFC;\\n\\tvarying float vFragDepth;\\n\\tvarying float vIsPerspective;\\n#endif\";\nvar logdepthbuf_pars_vertex = \"#ifdef USE_LOGDEPTHBUF\\n\\t#ifdef USE_LOGDEPTHBUF_EXT\\n\\t\\tvarying float vFragDepth;\\n\\t\\tvarying float vIsPerspective;\\n\\t#else\\n\\t\\tuniform float logDepthBufFC;\\n\\t#endif\\n#endif\";\nvar logdepthbuf_vertex = \"#ifdef USE_LOGDEPTHBUF\\n\\t#ifdef USE_LOGDEPTHBUF_EXT\\n\\t\\tvFragDepth = 1.0 + gl_Position.w;\\n\\t\\tvIsPerspective = float( isPerspectiveMatrix( projectionMatrix ) );\\n\\t#else\\n\\t\\tif ( isPerspectiveMatrix( projectionMatrix ) ) {\\n\\t\\t\\tgl_Position.z = log2( max( EPSILON, gl_Position.w + 1.0 ) ) * logDepthBufFC - 1.0;\\n\\t\\t\\tgl_Position.z *= gl_Position.w;\\n\\t\\t}\\n\\t#endif\\n#endif\";\nvar map_fragment = \"#ifdef USE_MAP\\n\\tvec4 texelColor = texture2D( map, vUv );\\n\\ttexelColor = mapTexelToLinear( texelColor );\\n\\tdiffuseColor *= texelColor;\\n#endif\";\nvar map_pars_fragment = \"#ifdef USE_MAP\\n\\tuniform sampler2D map;\\n#endif\";\nvar map_particle_fragment = \"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\\n\\tvec2 uv = ( uvTransform * vec3( gl_PointCoord.x, 1.0 - gl_PointCoord.y, 1 ) ).xy;\\n#endif\\n#ifdef USE_MAP\\n\\tvec4 mapTexel = texture2D( map, uv );\\n\\tdiffuseColor *= mapTexelToLinear( mapTexel );\\n#endif\\n#ifdef USE_ALPHAMAP\\n\\tdiffuseColor.a *= texture2D( alphaMap, uv ).g;\\n#endif\";\nvar map_particle_pars_fragment = \"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\\n\\tuniform mat3 uvTransform;\\n#endif\\n#ifdef USE_MAP\\n\\tuniform sampler2D map;\\n#endif\\n#ifdef USE_ALPHAMAP\\n\\tuniform sampler2D alphaMap;\\n#endif\";\nvar metalnessmap_fragment = \"float metalnessFactor = metalness;\\n#ifdef USE_METALNESSMAP\\n\\tvec4 texelMetalness = texture2D( metalnessMap, vUv );\\n\\tmetalnessFactor *= texelMetalness.b;\\n#endif\";\nvar metalnessmap_pars_fragment = \"#ifdef USE_METALNESSMAP\\n\\tuniform sampler2D metalnessMap;\\n#endif\";\nvar morphnormal_vertex = \"#ifdef USE_MORPHNORMALS\\n\\tobjectNormal *= morphTargetBaseInfluence;\\n\\tobjectNormal += morphNormal0 * morphTargetInfluences[ 0 ];\\n\\tobjectNormal += morphNormal1 * morphTargetInfluences[ 1 ];\\n\\tobjectNormal += morphNormal2 * morphTargetInfluences[ 2 ];\\n\\tobjectNormal += morphNormal3 * morphTargetInfluences[ 3 ];\\n#endif\";\nvar morphtarget_pars_vertex = \"#ifdef USE_MORPHTARGETS\\n\\tuniform float morphTargetBaseInfluence;\\n\\t#ifndef USE_MORPHNORMALS\\n\\t\\tuniform float morphTargetInfluences[ 8 ];\\n\\t#else\\n\\t\\tuniform float morphTargetInfluences[ 4 ];\\n\\t#endif\\n#endif\";\nvar morphtarget_vertex = \"#ifdef USE_MORPHTARGETS\\n\\ttransformed *= morphTargetBaseInfluence;\\n\\ttransformed += morphTarget0 * morphTargetInfluences[ 0 ];\\n\\ttransformed += morphTarget1 * morphTargetInfluences[ 1 ];\\n\\ttransformed += morphTarget2 * morphTargetInfluences[ 2 ];\\n\\ttransformed += morphTarget3 * morphTargetInfluences[ 3 ];\\n\\t#ifndef USE_MORPHNORMALS\\n\\t\\ttransformed += morphTarget4 * morphTargetInfluences[ 4 ];\\n\\t\\ttransformed += morphTarget5 * morphTargetInfluences[ 5 ];\\n\\t\\ttransformed += morphTarget6 * morphTargetInfluences[ 6 ];\\n\\t\\ttransformed += morphTarget7 * morphTargetInfluences[ 7 ];\\n\\t#endif\\n#endif\";\nvar normal_fragment_begin = \"#ifdef FLAT_SHADED\\n\\tvec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );\\n\\tvec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );\\n\\tvec3 normal = normalize( cross( fdx, fdy ) );\\n#else\\n\\tvec3 normal = normalize( vNormal );\\n\\t#ifdef DOUBLE_SIDED\\n\\t\\tnormal = normal * ( float( gl_FrontFacing ) * 2.0 - 1.0 );\\n\\t#endif\\n\\t#ifdef USE_TANGENT\\n\\t\\tvec3 tangent = normalize( vTangent );\\n\\t\\tvec3 bitangent = normalize( vBitangent );\\n\\t\\t#ifdef DOUBLE_SIDED\\n\\t\\t\\ttangent = tangent * ( float( gl_FrontFacing ) * 2.0 - 1.0 );\\n\\t\\t\\tbitangent = bitangent * ( float( gl_FrontFacing ) * 2.0 - 1.0 );\\n\\t\\t#endif\\n\\t\\t#if defined( TANGENTSPACE_NORMALMAP ) || defined( USE_CLEARCOAT_NORMALMAP )\\n\\t\\t\\tmat3 vTBN = mat3( tangent, bitangent, normal );\\n\\t\\t#endif\\n\\t#endif\\n#endif\\nvec3 geometryNormal = normal;\";\nvar normal_fragment_maps = \"#ifdef OBJECTSPACE_NORMALMAP\\n\\tnormal = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\\n\\t#ifdef FLIP_SIDED\\n\\t\\tnormal = - normal;\\n\\t#endif\\n\\t#ifdef DOUBLE_SIDED\\n\\t\\tnormal = normal * ( float( gl_FrontFacing ) * 2.0 - 1.0 );\\n\\t#endif\\n\\tnormal = normalize( normalMatrix * normal );\\n#elif defined( TANGENTSPACE_NORMALMAP )\\n\\tvec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\\n\\tmapN.xy *= normalScale;\\n\\t#ifdef USE_TANGENT\\n\\t\\tnormal = normalize( vTBN * mapN );\\n\\t#else\\n\\t\\tnormal = perturbNormal2Arb( -vViewPosition, normal, mapN );\\n\\t#endif\\n#elif defined( USE_BUMPMAP )\\n\\tnormal = perturbNormalArb( -vViewPosition, normal, dHdxy_fwd() );\\n#endif\";\nvar normalmap_pars_fragment = \"#ifdef USE_NORMALMAP\\n\\tuniform sampler2D normalMap;\\n\\tuniform vec2 normalScale;\\n#endif\\n#ifdef OBJECTSPACE_NORMALMAP\\n\\tuniform mat3 normalMatrix;\\n#endif\\n#if ! defined ( USE_TANGENT ) && ( defined ( TANGENTSPACE_NORMALMAP ) || defined ( USE_CLEARCOAT_NORMALMAP ) )\\n\\tvec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm, vec3 mapN ) {\\n\\t\\tvec3 q0 = vec3( dFdx( eye_pos.x ), dFdx( eye_pos.y ), dFdx( eye_pos.z ) );\\n\\t\\tvec3 q1 = vec3( dFdy( eye_pos.x ), dFdy( eye_pos.y ), dFdy( eye_pos.z ) );\\n\\t\\tvec2 st0 = dFdx( vUv.st );\\n\\t\\tvec2 st1 = dFdy( vUv.st );\\n\\t\\tfloat scale = sign( st1.t * st0.s - st0.t * st1.s );\\n\\t\\tvec3 S = normalize( ( q0 * st1.t - q1 * st0.t ) * scale );\\n\\t\\tvec3 T = normalize( ( - q0 * st1.s + q1 * st0.s ) * scale );\\n\\t\\tvec3 N = normalize( surf_norm );\\n\\t\\tmat3 tsn = mat3( S, T, N );\\n\\t\\tmapN.xy *= ( float( gl_FrontFacing ) * 2.0 - 1.0 );\\n\\t\\treturn normalize( tsn * mapN );\\n\\t}\\n#endif\";\nvar clearcoat_normal_fragment_begin = \"#ifdef CLEARCOAT\\n\\tvec3 clearcoatNormal = geometryNormal;\\n#endif\";\nvar clearcoat_normal_fragment_maps = \"#ifdef USE_CLEARCOAT_NORMALMAP\\n\\tvec3 clearcoatMapN = texture2D( clearcoatNormalMap, vUv ).xyz * 2.0 - 1.0;\\n\\tclearcoatMapN.xy *= clearcoatNormalScale;\\n\\t#ifdef USE_TANGENT\\n\\t\\tclearcoatNormal = normalize( vTBN * clearcoatMapN );\\n\\t#else\\n\\t\\tclearcoatNormal = perturbNormal2Arb( - vViewPosition, clearcoatNormal, clearcoatMapN );\\n\\t#endif\\n#endif\";\nvar clearcoat_pars_fragment = \"#ifdef USE_CLEARCOATMAP\\n\\tuniform sampler2D clearcoatMap;\\n#endif\\n#ifdef USE_CLEARCOAT_ROUGHNESSMAP\\n\\tuniform sampler2D clearcoatRoughnessMap;\\n#endif\\n#ifdef USE_CLEARCOAT_NORMALMAP\\n\\tuniform sampler2D clearcoatNormalMap;\\n\\tuniform vec2 clearcoatNormalScale;\\n#endif\";\nvar packing = \"vec3 packNormalToRGB( const in vec3 normal ) {\\n\\treturn normalize( normal ) * 0.5 + 0.5;\\n}\\nvec3 unpackRGBToNormal( const in vec3 rgb ) {\\n\\treturn 2.0 * rgb.xyz - 1.0;\\n}\\nconst float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;\\nconst vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256., 256. );\\nconst vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );\\nconst float ShiftRight8 = 1. / 256.;\\nvec4 packDepthToRGBA( const in float v ) {\\n\\tvec4 r = vec4( fract( v * PackFactors ), v );\\n\\tr.yzw -= r.xyz * ShiftRight8;\\treturn r * PackUpscale;\\n}\\nfloat unpackRGBAToDepth( const in vec4 v ) {\\n\\treturn dot( v, UnpackFactors );\\n}\\nvec4 pack2HalfToRGBA( vec2 v ) {\\n\\tvec4 r = vec4( v.x, fract( v.x * 255.0 ), v.y, fract( v.y * 255.0 ));\\n\\treturn vec4( r.x - r.y / 255.0, r.y, r.z - r.w / 255.0, r.w);\\n}\\nvec2 unpackRGBATo2Half( vec4 v ) {\\n\\treturn vec2( v.x + ( v.y / 255.0 ), v.z + ( v.w / 255.0 ) );\\n}\\nfloat viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {\\n\\treturn ( viewZ + near ) / ( near - far );\\n}\\nfloat orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {\\n\\treturn linearClipZ * ( near - far ) - near;\\n}\\nfloat viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {\\n\\treturn (( near + viewZ ) * far ) / (( far - near ) * viewZ );\\n}\\nfloat perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {\\n\\treturn ( near * far ) / ( ( far - near ) * invClipZ - far );\\n}\";\nvar premultiplied_alpha_fragment = \"#ifdef PREMULTIPLIED_ALPHA\\n\\tgl_FragColor.rgb *= gl_FragColor.a;\\n#endif\";\nvar project_vertex = \"vec4 mvPosition = vec4( transformed, 1.0 );\\n#ifdef USE_INSTANCING\\n\\tmvPosition = instanceMatrix * mvPosition;\\n#endif\\nmvPosition = modelViewMatrix * mvPosition;\\ngl_Position = projectionMatrix * mvPosition;\";\nvar dithering_fragment = \"#ifdef DITHERING\\n\\tgl_FragColor.rgb = dithering( gl_FragColor.rgb );\\n#endif\";\nvar dithering_pars_fragment = \"#ifdef DITHERING\\n\\tvec3 dithering( vec3 color ) {\\n\\t\\tfloat grid_position = rand( gl_FragCoord.xy );\\n\\t\\tvec3 dither_shift_RGB = vec3( 0.25 / 255.0, -0.25 / 255.0, 0.25 / 255.0 );\\n\\t\\tdither_shift_RGB = mix( 2.0 * dither_shift_RGB, -2.0 * dither_shift_RGB, grid_position );\\n\\t\\treturn color + dither_shift_RGB;\\n\\t}\\n#endif\";\nvar roughnessmap_fragment = \"float roughnessFactor = roughness;\\n#ifdef USE_ROUGHNESSMAP\\n\\tvec4 texelRoughness = texture2D( roughnessMap, vUv );\\n\\troughnessFactor *= texelRoughness.g;\\n#endif\";\nvar roughnessmap_pars_fragment = \"#ifdef USE_ROUGHNESSMAP\\n\\tuniform sampler2D roughnessMap;\\n#endif\";\nvar shadowmap_pars_fragment = \"#ifdef USE_SHADOWMAP\\n\\t#if NUM_DIR_LIGHT_SHADOWS > 0\\n\\t\\tuniform sampler2D directionalShadowMap[ NUM_DIR_LIGHT_SHADOWS ];\\n\\t\\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\\n\\t\\tstruct DirectionalLightShadow {\\n\\t\\t\\tfloat shadowBias;\\n\\t\\t\\tfloat shadowNormalBias;\\n\\t\\t\\tfloat shadowRadius;\\n\\t\\t\\tvec2 shadowMapSize;\\n\\t\\t};\\n\\t\\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\\n\\t#endif\\n\\t#if NUM_SPOT_LIGHT_SHADOWS > 0\\n\\t\\tuniform sampler2D spotShadowMap[ NUM_SPOT_LIGHT_SHADOWS ];\\n\\t\\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\\n\\t\\tstruct SpotLightShadow {\\n\\t\\t\\tfloat shadowBias;\\n\\t\\t\\tfloat shadowNormalBias;\\n\\t\\t\\tfloat shadowRadius;\\n\\t\\t\\tvec2 shadowMapSize;\\n\\t\\t};\\n\\t\\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\\n\\t#endif\\n\\t#if NUM_POINT_LIGHT_SHADOWS > 0\\n\\t\\tuniform sampler2D pointShadowMap[ NUM_POINT_LIGHT_SHADOWS ];\\n\\t\\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\\n\\t\\tstruct PointLightShadow {\\n\\t\\t\\tfloat shadowBias;\\n\\t\\t\\tfloat shadowNormalBias;\\n\\t\\t\\tfloat shadowRadius;\\n\\t\\t\\tvec2 shadowMapSize;\\n\\t\\t\\tfloat shadowCameraNear;\\n\\t\\t\\tfloat shadowCameraFar;\\n\\t\\t};\\n\\t\\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\\n\\t#endif\\n\\tfloat texture2DCompare( sampler2D depths, vec2 uv, float compare ) {\\n\\t\\treturn step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );\\n\\t}\\n\\tvec2 texture2DDistribution( sampler2D shadow, vec2 uv ) {\\n\\t\\treturn unpackRGBATo2Half( texture2D( shadow, uv ) );\\n\\t}\\n\\tfloat VSMShadow (sampler2D shadow, vec2 uv, float compare ){\\n\\t\\tfloat occlusion = 1.0;\\n\\t\\tvec2 distribution = texture2DDistribution( shadow, uv );\\n\\t\\tfloat hard_shadow = step( compare , distribution.x );\\n\\t\\tif (hard_shadow != 1.0 ) {\\n\\t\\t\\tfloat distance = compare - distribution.x ;\\n\\t\\t\\tfloat variance = max( 0.00000, distribution.y * distribution.y );\\n\\t\\t\\tfloat softness_probability = variance / (variance + distance * distance );\\t\\t\\tsoftness_probability = clamp( ( softness_probability - 0.3 ) / ( 0.95 - 0.3 ), 0.0, 1.0 );\\t\\t\\tocclusion = clamp( max( hard_shadow, softness_probability ), 0.0, 1.0 );\\n\\t\\t}\\n\\t\\treturn occlusion;\\n\\t}\\n\\tfloat getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\\n\\t\\tfloat shadow = 1.0;\\n\\t\\tshadowCoord.xyz /= shadowCoord.w;\\n\\t\\tshadowCoord.z += shadowBias;\\n\\t\\tbvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );\\n\\t\\tbool inFrustum = all( inFrustumVec );\\n\\t\\tbvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );\\n\\t\\tbool frustumTest = all( frustumTestVec );\\n\\t\\tif ( frustumTest ) {\\n\\t\\t#if defined( SHADOWMAP_TYPE_PCF )\\n\\t\\t\\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\\n\\t\\t\\tfloat dx0 = - texelSize.x * shadowRadius;\\n\\t\\t\\tfloat dy0 = - texelSize.y * shadowRadius;\\n\\t\\t\\tfloat dx1 = + texelSize.x * shadowRadius;\\n\\t\\t\\tfloat dy1 = + texelSize.y * shadowRadius;\\n\\t\\t\\tfloat dx2 = dx0 / 2.0;\\n\\t\\t\\tfloat dy2 = dy0 / 2.0;\\n\\t\\t\\tfloat dx3 = dx1 / 2.0;\\n\\t\\t\\tfloat dy3 = dy1 / 2.0;\\n\\t\\t\\tshadow = (\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy2 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy2 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy2 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, 0.0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, 0.0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy3 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy3 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy3 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\\n\\t\\t\\t) * ( 1.0 / 17.0 );\\n\\t\\t#elif defined( SHADOWMAP_TYPE_PCF_SOFT )\\n\\t\\t\\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\\n\\t\\t\\tfloat dx = texelSize.x;\\n\\t\\t\\tfloat dy = texelSize.y;\\n\\t\\t\\tvec2 uv = shadowCoord.xy;\\n\\t\\t\\tvec2 f = fract( uv * shadowMapSize + 0.5 );\\n\\t\\t\\tuv -= f * texelSize;\\n\\t\\t\\tshadow = (\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, uv, shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, uv + vec2( dx, 0.0 ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, uv + vec2( 0.0, dy ), shadowCoord.z ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, uv + texelSize, shadowCoord.z ) +\\n\\t\\t\\t\\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, 0.0 ), shadowCoord.z ), \\n\\t\\t\\t\\t\\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 0.0 ), shadowCoord.z ),\\n\\t\\t\\t\\t\\t f.x ) +\\n\\t\\t\\t\\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, dy ), shadowCoord.z ), \\n\\t\\t\\t\\t\\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, dy ), shadowCoord.z ),\\n\\t\\t\\t\\t\\t f.x ) +\\n\\t\\t\\t\\tmix( texture2DCompare( shadowMap, uv + vec2( 0.0, -dy ), shadowCoord.z ), \\n\\t\\t\\t\\t\\t texture2DCompare( shadowMap, uv + vec2( 0.0, 2.0 * dy ), shadowCoord.z ),\\n\\t\\t\\t\\t\\t f.y ) +\\n\\t\\t\\t\\tmix( texture2DCompare( shadowMap, uv + vec2( dx, -dy ), shadowCoord.z ), \\n\\t\\t\\t\\t\\t texture2DCompare( shadowMap, uv + vec2( dx, 2.0 * dy ), shadowCoord.z ),\\n\\t\\t\\t\\t\\t f.y ) +\\n\\t\\t\\t\\tmix( mix( texture2DCompare( shadowMap, uv + vec2( -dx, -dy ), shadowCoord.z ), \\n\\t\\t\\t\\t\\t\\t  texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, -dy ), shadowCoord.z ),\\n\\t\\t\\t\\t\\t\\t  f.x ),\\n\\t\\t\\t\\t\\t mix( texture2DCompare( shadowMap, uv + vec2( -dx, 2.0 * dy ), shadowCoord.z ), \\n\\t\\t\\t\\t\\t\\t  texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 2.0 * dy ), shadowCoord.z ),\\n\\t\\t\\t\\t\\t\\t  f.x ),\\n\\t\\t\\t\\t\\t f.y )\\n\\t\\t\\t) * ( 1.0 / 9.0 );\\n\\t\\t#elif defined( SHADOWMAP_TYPE_VSM )\\n\\t\\t\\tshadow = VSMShadow( shadowMap, shadowCoord.xy, shadowCoord.z );\\n\\t\\t#else\\n\\t\\t\\tshadow = texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );\\n\\t\\t#endif\\n\\t\\t}\\n\\t\\treturn shadow;\\n\\t}\\n\\tvec2 cubeToUV( vec3 v, float texelSizeY ) {\\n\\t\\tvec3 absV = abs( v );\\n\\t\\tfloat scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );\\n\\t\\tabsV *= scaleToCube;\\n\\t\\tv *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );\\n\\t\\tvec2 planar = v.xy;\\n\\t\\tfloat almostATexel = 1.5 * texelSizeY;\\n\\t\\tfloat almostOne = 1.0 - almostATexel;\\n\\t\\tif ( absV.z >= almostOne ) {\\n\\t\\t\\tif ( v.z > 0.0 )\\n\\t\\t\\t\\tplanar.x = 4.0 - v.x;\\n\\t\\t} else if ( absV.x >= almostOne ) {\\n\\t\\t\\tfloat signX = sign( v.x );\\n\\t\\t\\tplanar.x = v.z * signX + 2.0 * signX;\\n\\t\\t} else if ( absV.y >= almostOne ) {\\n\\t\\t\\tfloat signY = sign( v.y );\\n\\t\\t\\tplanar.x = v.x + 2.0 * signY + 2.0;\\n\\t\\t\\tplanar.y = v.z * signY - 2.0;\\n\\t\\t}\\n\\t\\treturn vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );\\n\\t}\\n\\tfloat getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord, float shadowCameraNear, float shadowCameraFar ) {\\n\\t\\tvec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );\\n\\t\\tvec3 lightToPosition = shadowCoord.xyz;\\n\\t\\tfloat dp = ( length( lightToPosition ) - shadowCameraNear ) / ( shadowCameraFar - shadowCameraNear );\\t\\tdp += shadowBias;\\n\\t\\tvec3 bd3D = normalize( lightToPosition );\\n\\t\\t#if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT ) || defined( SHADOWMAP_TYPE_VSM )\\n\\t\\t\\tvec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;\\n\\t\\t\\treturn (\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +\\n\\t\\t\\t\\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )\\n\\t\\t\\t) * ( 1.0 / 9.0 );\\n\\t\\t#else\\n\\t\\t\\treturn texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );\\n\\t\\t#endif\\n\\t}\\n#endif\";\nvar shadowmap_pars_vertex = \"#ifdef USE_SHADOWMAP\\n\\t#if NUM_DIR_LIGHT_SHADOWS > 0\\n\\t\\tuniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHT_SHADOWS ];\\n\\t\\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\\n\\t\\tstruct DirectionalLightShadow {\\n\\t\\t\\tfloat shadowBias;\\n\\t\\t\\tfloat shadowNormalBias;\\n\\t\\t\\tfloat shadowRadius;\\n\\t\\t\\tvec2 shadowMapSize;\\n\\t\\t};\\n\\t\\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\\n\\t#endif\\n\\t#if NUM_SPOT_LIGHT_SHADOWS > 0\\n\\t\\tuniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHT_SHADOWS ];\\n\\t\\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\\n\\t\\tstruct SpotLightShadow {\\n\\t\\t\\tfloat shadowBias;\\n\\t\\t\\tfloat shadowNormalBias;\\n\\t\\t\\tfloat shadowRadius;\\n\\t\\t\\tvec2 shadowMapSize;\\n\\t\\t};\\n\\t\\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\\n\\t#endif\\n\\t#if NUM_POINT_LIGHT_SHADOWS > 0\\n\\t\\tuniform mat4 pointShadowMatrix[ NUM_POINT_LIGHT_SHADOWS ];\\n\\t\\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\\n\\t\\tstruct PointLightShadow {\\n\\t\\t\\tfloat shadowBias;\\n\\t\\t\\tfloat shadowNormalBias;\\n\\t\\t\\tfloat shadowRadius;\\n\\t\\t\\tvec2 shadowMapSize;\\n\\t\\t\\tfloat shadowCameraNear;\\n\\t\\t\\tfloat shadowCameraFar;\\n\\t\\t};\\n\\t\\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\\n\\t#endif\\n#endif\";\nvar shadowmap_vertex = \"#ifdef USE_SHADOWMAP\\n\\t#if NUM_DIR_LIGHT_SHADOWS > 0 || NUM_SPOT_LIGHT_SHADOWS > 0 || NUM_POINT_LIGHT_SHADOWS > 0\\n\\t\\tvec3 shadowWorldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\\n\\t\\tvec4 shadowWorldPosition;\\n\\t#endif\\n\\t#if NUM_DIR_LIGHT_SHADOWS > 0\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\\n\\t\\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * directionalLightShadows[ i ].shadowNormalBias, 0 );\\n\\t\\tvDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * shadowWorldPosition;\\n\\t}\\n\\t#pragma unroll_loop_end\\n\\t#endif\\n\\t#if NUM_SPOT_LIGHT_SHADOWS > 0\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\\n\\t\\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * spotLightShadows[ i ].shadowNormalBias, 0 );\\n\\t\\tvSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * shadowWorldPosition;\\n\\t}\\n\\t#pragma unroll_loop_end\\n\\t#endif\\n\\t#if NUM_POINT_LIGHT_SHADOWS > 0\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\\n\\t\\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * pointLightShadows[ i ].shadowNormalBias, 0 );\\n\\t\\tvPointShadowCoord[ i ] = pointShadowMatrix[ i ] * shadowWorldPosition;\\n\\t}\\n\\t#pragma unroll_loop_end\\n\\t#endif\\n#endif\";\nvar shadowmask_pars_fragment = \"float getShadowMask() {\\n\\tfloat shadow = 1.0;\\n\\t#ifdef USE_SHADOWMAP\\n\\t#if NUM_DIR_LIGHT_SHADOWS > 0\\n\\tDirectionalLightShadow directionalLight;\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\\n\\t\\tdirectionalLight = directionalLightShadows[ i ];\\n\\t\\tshadow *= receiveShadow ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\\n\\t}\\n\\t#pragma unroll_loop_end\\n\\t#endif\\n\\t#if NUM_SPOT_LIGHT_SHADOWS > 0\\n\\tSpotLightShadow spotLight;\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\\n\\t\\tspotLight = spotLightShadows[ i ];\\n\\t\\tshadow *= receiveShadow ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\\n\\t}\\n\\t#pragma unroll_loop_end\\n\\t#endif\\n\\t#if NUM_POINT_LIGHT_SHADOWS > 0\\n\\tPointLightShadow pointLight;\\n\\t#pragma unroll_loop_start\\n\\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\\n\\t\\tpointLight = pointLightShadows[ i ];\\n\\t\\tshadow *= receiveShadow ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;\\n\\t}\\n\\t#pragma unroll_loop_end\\n\\t#endif\\n\\t#endif\\n\\treturn shadow;\\n}\";\nvar skinbase_vertex = \"#ifdef USE_SKINNING\\n\\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\\n\\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\\n\\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\\n\\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\\n#endif\";\nvar skinning_pars_vertex = \"#ifdef USE_SKINNING\\n\\tuniform mat4 bindMatrix;\\n\\tuniform mat4 bindMatrixInverse;\\n\\t#ifdef BONE_TEXTURE\\n\\t\\tuniform highp sampler2D boneTexture;\\n\\t\\tuniform int boneTextureSize;\\n\\t\\tmat4 getBoneMatrix( const in float i ) {\\n\\t\\t\\tfloat j = i * 4.0;\\n\\t\\t\\tfloat x = mod( j, float( boneTextureSize ) );\\n\\t\\t\\tfloat y = floor( j / float( boneTextureSize ) );\\n\\t\\t\\tfloat dx = 1.0 / float( boneTextureSize );\\n\\t\\t\\tfloat dy = 1.0 / float( boneTextureSize );\\n\\t\\t\\ty = dy * ( y + 0.5 );\\n\\t\\t\\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\\n\\t\\t\\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\\n\\t\\t\\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\\n\\t\\t\\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\\n\\t\\t\\tmat4 bone = mat4( v1, v2, v3, v4 );\\n\\t\\t\\treturn bone;\\n\\t\\t}\\n\\t#else\\n\\t\\tuniform mat4 boneMatrices[ MAX_BONES ];\\n\\t\\tmat4 getBoneMatrix( const in float i ) {\\n\\t\\t\\tmat4 bone = boneMatrices[ int(i) ];\\n\\t\\t\\treturn bone;\\n\\t\\t}\\n\\t#endif\\n#endif\";\nvar skinning_vertex = \"#ifdef USE_SKINNING\\n\\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\\n\\tvec4 skinned = vec4( 0.0 );\\n\\tskinned += boneMatX * skinVertex * skinWeight.x;\\n\\tskinned += boneMatY * skinVertex * skinWeight.y;\\n\\tskinned += boneMatZ * skinVertex * skinWeight.z;\\n\\tskinned += boneMatW * skinVertex * skinWeight.w;\\n\\ttransformed = ( bindMatrixInverse * skinned ).xyz;\\n#endif\";\nvar skinnormal_vertex = \"#ifdef USE_SKINNING\\n\\tmat4 skinMatrix = mat4( 0.0 );\\n\\tskinMatrix += skinWeight.x * boneMatX;\\n\\tskinMatrix += skinWeight.y * boneMatY;\\n\\tskinMatrix += skinWeight.z * boneMatZ;\\n\\tskinMatrix += skinWeight.w * boneMatW;\\n\\tskinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;\\n\\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\\n\\t#ifdef USE_TANGENT\\n\\t\\tobjectTangent = vec4( skinMatrix * vec4( objectTangent, 0.0 ) ).xyz;\\n\\t#endif\\n#endif\";\nvar specularmap_fragment = \"float specularStrength;\\n#ifdef USE_SPECULARMAP\\n\\tvec4 texelSpecular = texture2D( specularMap, vUv );\\n\\tspecularStrength = texelSpecular.r;\\n#else\\n\\tspecularStrength = 1.0;\\n#endif\";\nvar specularmap_pars_fragment = \"#ifdef USE_SPECULARMAP\\n\\tuniform sampler2D specularMap;\\n#endif\";\nvar tonemapping_fragment = \"#if defined( TONE_MAPPING )\\n\\tgl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\\n#endif\";\nvar tonemapping_pars_fragment = \"#ifndef saturate\\n#define saturate(a) clamp( a, 0.0, 1.0 )\\n#endif\\nuniform float toneMappingExposure;\\nvec3 LinearToneMapping( vec3 color ) {\\n\\treturn toneMappingExposure * color;\\n}\\nvec3 ReinhardToneMapping( vec3 color ) {\\n\\tcolor *= toneMappingExposure;\\n\\treturn saturate( color / ( vec3( 1.0 ) + color ) );\\n}\\nvec3 OptimizedCineonToneMapping( vec3 color ) {\\n\\tcolor *= toneMappingExposure;\\n\\tcolor = max( vec3( 0.0 ), color - 0.004 );\\n\\treturn pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\\n}\\nvec3 RRTAndODTFit( vec3 v ) {\\n\\tvec3 a = v * ( v + 0.0245786 ) - 0.000090537;\\n\\tvec3 b = v * ( 0.983729 * v + 0.4329510 ) + 0.238081;\\n\\treturn a / b;\\n}\\nvec3 ACESFilmicToneMapping( vec3 color ) {\\n\\tconst mat3 ACESInputMat = mat3(\\n\\t\\tvec3( 0.59719, 0.07600, 0.02840 ),\\t\\tvec3( 0.35458, 0.90834, 0.13383 ),\\n\\t\\tvec3( 0.04823, 0.01566, 0.83777 )\\n\\t);\\n\\tconst mat3 ACESOutputMat = mat3(\\n\\t\\tvec3(  1.60475, -0.10208, -0.00327 ),\\t\\tvec3( -0.53108,  1.10813, -0.07276 ),\\n\\t\\tvec3( -0.07367, -0.00605,  1.07602 )\\n\\t);\\n\\tcolor *= toneMappingExposure / 0.6;\\n\\tcolor = ACESInputMat * color;\\n\\tcolor = RRTAndODTFit( color );\\n\\tcolor = ACESOutputMat * color;\\n\\treturn saturate( color );\\n}\\nvec3 CustomToneMapping( vec3 color ) { return color; }\";\nvar transmissionmap_fragment = \"#ifdef USE_TRANSMISSIONMAP\\n\\ttotalTransmission *= texture2D( transmissionMap, vUv ).r;\\n#endif\";\nvar transmissionmap_pars_fragment = \"#ifdef USE_TRANSMISSIONMAP\\n\\tuniform sampler2D transmissionMap;\\n#endif\";\nvar uv_pars_fragment = \"#if ( defined( USE_UV ) && ! defined( UVS_VERTEX_ONLY ) )\\n\\tvarying vec2 vUv;\\n#endif\";\nvar uv_pars_vertex = \"#ifdef USE_UV\\n\\t#ifdef UVS_VERTEX_ONLY\\n\\t\\tvec2 vUv;\\n\\t#else\\n\\t\\tvarying vec2 vUv;\\n\\t#endif\\n\\tuniform mat3 uvTransform;\\n#endif\";\nvar uv_vertex = \"#ifdef USE_UV\\n\\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\\n#endif\";\nvar uv2_pars_fragment = \"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\\n\\tvarying vec2 vUv2;\\n#endif\";\nvar uv2_pars_vertex = \"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\\n\\tattribute vec2 uv2;\\n\\tvarying vec2 vUv2;\\n\\tuniform mat3 uv2Transform;\\n#endif\";\nvar uv2_vertex = \"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\\n\\tvUv2 = ( uv2Transform * vec3( uv2, 1 ) ).xy;\\n#endif\";\nvar worldpos_vertex = \"#if defined( USE_ENVMAP ) || defined( DISTANCE ) || defined ( USE_SHADOWMAP )\\n\\tvec4 worldPosition = vec4( transformed, 1.0 );\\n\\t#ifdef USE_INSTANCING\\n\\t\\tworldPosition = instanceMatrix * worldPosition;\\n\\t#endif\\n\\tworldPosition = modelMatrix * worldPosition;\\n#endif\";\nvar background_frag = \"uniform sampler2D t2D;\\nvarying vec2 vUv;\\nvoid main() {\\n\\tvec4 texColor = texture2D( t2D, vUv );\\n\\tgl_FragColor = mapTexelToLinear( texColor );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n}\";\nvar background_vert = \"varying vec2 vUv;\\nuniform mat3 uvTransform;\\nvoid main() {\\n\\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\\n\\tgl_Position = vec4( position.xy, 1.0, 1.0 );\\n}\";\nvar cube_frag = \"#include <envmap_common_pars_fragment>\\nuniform float opacity;\\nvarying vec3 vWorldDirection;\\n#include <cube_uv_reflection_fragment>\\nvoid main() {\\n\\tvec3 vReflect = vWorldDirection;\\n\\t#include <envmap_fragment>\\n\\tgl_FragColor = envColor;\\n\\tgl_FragColor.a *= opacity;\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n}\";\nvar cube_vert = \"varying vec3 vWorldDirection;\\n#include <common>\\nvoid main() {\\n\\tvWorldDirection = transformDirection( position, modelMatrix );\\n\\t#include <begin_vertex>\\n\\t#include <project_vertex>\\n\\tgl_Position.z = gl_Position.w;\\n}\";\nvar depth_frag = \"#if DEPTH_PACKING == 3200\\n\\tuniform float opacity;\\n#endif\\n#include <common>\\n#include <packing>\\n#include <uv_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvarying vec2 vHighPrecisionZW;\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( 1.0 );\\n\\t#if DEPTH_PACKING == 3200\\n\\t\\tdiffuseColor.a = opacity;\\n\\t#endif\\n\\t#include <map_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\t#include <logdepthbuf_fragment>\\n\\tfloat fragCoordZ = 0.5 * vHighPrecisionZW[0] / vHighPrecisionZW[1] + 0.5;\\n\\t#if DEPTH_PACKING == 3200\\n\\t\\tgl_FragColor = vec4( vec3( 1.0 - fragCoordZ ), opacity );\\n\\t#elif DEPTH_PACKING == 3201\\n\\t\\tgl_FragColor = packDepthToRGBA( fragCoordZ );\\n\\t#endif\\n}\";\nvar depth_vert = \"#include <common>\\n#include <uv_pars_vertex>\\n#include <displacementmap_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvarying vec2 vHighPrecisionZW;\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#ifdef USE_DISPLACEMENTMAP\\n\\t\\t#include <beginnormal_vertex>\\n\\t\\t#include <morphnormal_vertex>\\n\\t\\t#include <skinnormal_vertex>\\n\\t#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <displacementmap_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\tvHighPrecisionZW = gl_Position.zw;\\n}\";\nvar distanceRGBA_frag = \"#define DISTANCE\\nuniform vec3 referencePosition;\\nuniform float nearDistance;\\nuniform float farDistance;\\nvarying vec3 vWorldPosition;\\n#include <common>\\n#include <packing>\\n#include <uv_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main () {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( 1.0 );\\n\\t#include <map_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\tfloat dist = length( vWorldPosition - referencePosition );\\n\\tdist = ( dist - nearDistance ) / ( farDistance - nearDistance );\\n\\tdist = saturate( dist );\\n\\tgl_FragColor = packDepthToRGBA( dist );\\n}\";\nvar distanceRGBA_vert = \"#define DISTANCE\\nvarying vec3 vWorldPosition;\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <displacementmap_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#ifdef USE_DISPLACEMENTMAP\\n\\t\\t#include <beginnormal_vertex>\\n\\t\\t#include <morphnormal_vertex>\\n\\t\\t#include <skinnormal_vertex>\\n\\t#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <displacementmap_vertex>\\n\\t#include <project_vertex>\\n\\t#include <worldpos_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\tvWorldPosition = worldPosition.xyz;\\n}\";\nvar equirect_frag = \"uniform sampler2D tEquirect;\\nvarying vec3 vWorldDirection;\\n#include <common>\\nvoid main() {\\n\\tvec3 direction = normalize( vWorldDirection );\\n\\tvec2 sampleUV = equirectUv( direction );\\n\\tvec4 texColor = texture2D( tEquirect, sampleUV );\\n\\tgl_FragColor = mapTexelToLinear( texColor );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n}\";\nvar equirect_vert = \"varying vec3 vWorldDirection;\\n#include <common>\\nvoid main() {\\n\\tvWorldDirection = transformDirection( position, modelMatrix );\\n\\t#include <begin_vertex>\\n\\t#include <project_vertex>\\n}\";\nvar linedashed_frag = \"uniform vec3 diffuse;\\nuniform float opacity;\\nuniform float dashSize;\\nuniform float totalSize;\\nvarying float vLineDistance;\\n#include <common>\\n#include <color_pars_fragment>\\n#include <fog_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tif ( mod( vLineDistance, totalSize ) > dashSize ) {\\n\\t\\tdiscard;\\n\\t}\\n\\tvec3 outgoingLight = vec3( 0.0 );\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <color_fragment>\\n\\toutgoingLight = diffuseColor.rgb;\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n}\";\nvar linedashed_vert = \"uniform float scale;\\nattribute float lineDistance;\\nvarying float vLineDistance;\\n#include <common>\\n#include <color_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\tvLineDistance = scale * lineDistance;\\n\\t#include <color_vertex>\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar meshbasic_frag = \"uniform vec3 diffuse;\\nuniform float opacity;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n#endif\\n#include <common>\\n#include <dithering_pars_fragment>\\n#include <color_pars_fragment>\\n#include <uv_pars_fragment>\\n#include <uv2_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <aomap_pars_fragment>\\n#include <lightmap_pars_fragment>\\n#include <envmap_common_pars_fragment>\\n#include <envmap_pars_fragment>\\n#include <cube_uv_reflection_fragment>\\n#include <fog_pars_fragment>\\n#include <specularmap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_fragment>\\n\\t#include <color_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\t#include <specularmap_fragment>\\n\\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\\n\\t#ifdef USE_LIGHTMAP\\n\\t\\n\\t\\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\\n\\t\\treflectedLight.indirectDiffuse += lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\\n\\t#else\\n\\t\\treflectedLight.indirectDiffuse += vec3( 1.0 );\\n\\t#endif\\n\\t#include <aomap_fragment>\\n\\treflectedLight.indirectDiffuse *= diffuseColor.rgb;\\n\\tvec3 outgoingLight = reflectedLight.indirectDiffuse;\\n\\t#include <envmap_fragment>\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n\\t#include <dithering_fragment>\\n}\";\nvar meshbasic_vert = \"#include <common>\\n#include <uv_pars_vertex>\\n#include <uv2_pars_vertex>\\n#include <envmap_pars_vertex>\\n#include <color_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <uv2_vertex>\\n\\t#include <color_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#ifdef USE_ENVMAP\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n\\t#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <worldpos_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\t#include <envmap_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar meshlambert_frag = \"uniform vec3 diffuse;\\nuniform vec3 emissive;\\nuniform float opacity;\\nvarying vec3 vLightFront;\\nvarying vec3 vIndirectFront;\\n#ifdef DOUBLE_SIDED\\n\\tvarying vec3 vLightBack;\\n\\tvarying vec3 vIndirectBack;\\n#endif\\n#include <common>\\n#include <packing>\\n#include <dithering_pars_fragment>\\n#include <color_pars_fragment>\\n#include <uv_pars_fragment>\\n#include <uv2_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <aomap_pars_fragment>\\n#include <lightmap_pars_fragment>\\n#include <emissivemap_pars_fragment>\\n#include <envmap_common_pars_fragment>\\n#include <envmap_pars_fragment>\\n#include <cube_uv_reflection_fragment>\\n#include <bsdfs>\\n#include <lights_pars_begin>\\n#include <fog_pars_fragment>\\n#include <shadowmap_pars_fragment>\\n#include <shadowmask_pars_fragment>\\n#include <specularmap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\\n\\tvec3 totalEmissiveRadiance = emissive;\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_fragment>\\n\\t#include <color_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\t#include <specularmap_fragment>\\n\\t#include <emissivemap_fragment>\\n\\t#ifdef DOUBLE_SIDED\\n\\t\\treflectedLight.indirectDiffuse += ( gl_FrontFacing ) ? vIndirectFront : vIndirectBack;\\n\\t#else\\n\\t\\treflectedLight.indirectDiffuse += vIndirectFront;\\n\\t#endif\\n\\t#include <lightmap_fragment>\\n\\treflectedLight.indirectDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb );\\n\\t#ifdef DOUBLE_SIDED\\n\\t\\treflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;\\n\\t#else\\n\\t\\treflectedLight.directDiffuse = vLightFront;\\n\\t#endif\\n\\treflectedLight.directDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb ) * getShadowMask();\\n\\t#include <aomap_fragment>\\n\\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\\n\\t#include <envmap_fragment>\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n\\t#include <dithering_fragment>\\n}\";\nvar meshlambert_vert = \"#define LAMBERT\\nvarying vec3 vLightFront;\\nvarying vec3 vIndirectFront;\\n#ifdef DOUBLE_SIDED\\n\\tvarying vec3 vLightBack;\\n\\tvarying vec3 vIndirectBack;\\n#endif\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <uv2_pars_vertex>\\n#include <envmap_pars_vertex>\\n#include <bsdfs>\\n#include <lights_pars_begin>\\n#include <color_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <shadowmap_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <uv2_vertex>\\n\\t#include <color_vertex>\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\t#include <worldpos_vertex>\\n\\t#include <envmap_vertex>\\n\\t#include <lights_lambert_vertex>\\n\\t#include <shadowmap_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar meshmatcap_frag = \"#define MATCAP\\nuniform vec3 diffuse;\\nuniform float opacity;\\nuniform sampler2D matcap;\\nvarying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n#endif\\n#include <common>\\n#include <dithering_pars_fragment>\\n#include <color_pars_fragment>\\n#include <uv_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <fog_pars_fragment>\\n#include <bumpmap_pars_fragment>\\n#include <normalmap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_fragment>\\n\\t#include <color_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\t#include <normal_fragment_begin>\\n\\t#include <normal_fragment_maps>\\n\\tvec3 viewDir = normalize( vViewPosition );\\n\\tvec3 x = normalize( vec3( viewDir.z, 0.0, - viewDir.x ) );\\n\\tvec3 y = cross( viewDir, x );\\n\\tvec2 uv = vec2( dot( x, normal ), dot( y, normal ) ) * 0.495 + 0.5;\\n\\t#ifdef USE_MATCAP\\n\\t\\tvec4 matcapColor = texture2D( matcap, uv );\\n\\t\\tmatcapColor = matcapTexelToLinear( matcapColor );\\n\\t#else\\n\\t\\tvec4 matcapColor = vec4( 1.0 );\\n\\t#endif\\n\\tvec3 outgoingLight = diffuseColor.rgb * matcapColor.rgb;\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n\\t#include <dithering_fragment>\\n}\";\nvar meshmatcap_vert = \"#define MATCAP\\nvarying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n#endif\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <color_pars_vertex>\\n#include <displacementmap_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <color_vertex>\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n\\t#ifndef FLAT_SHADED\\n\\t\\tvNormal = normalize( transformedNormal );\\n\\t#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <displacementmap_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\t#include <fog_vertex>\\n\\tvViewPosition = - mvPosition.xyz;\\n}\";\nvar meshtoon_frag = \"#define TOON\\nuniform vec3 diffuse;\\nuniform vec3 emissive;\\nuniform float opacity;\\n#include <common>\\n#include <packing>\\n#include <dithering_pars_fragment>\\n#include <color_pars_fragment>\\n#include <uv_pars_fragment>\\n#include <uv2_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <aomap_pars_fragment>\\n#include <lightmap_pars_fragment>\\n#include <emissivemap_pars_fragment>\\n#include <gradientmap_pars_fragment>\\n#include <fog_pars_fragment>\\n#include <bsdfs>\\n#include <lights_pars_begin>\\n#include <lights_toon_pars_fragment>\\n#include <shadowmap_pars_fragment>\\n#include <bumpmap_pars_fragment>\\n#include <normalmap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\\n\\tvec3 totalEmissiveRadiance = emissive;\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_fragment>\\n\\t#include <color_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\t#include <normal_fragment_begin>\\n\\t#include <normal_fragment_maps>\\n\\t#include <emissivemap_fragment>\\n\\t#include <lights_toon_fragment>\\n\\t#include <lights_fragment_begin>\\n\\t#include <lights_fragment_maps>\\n\\t#include <lights_fragment_end>\\n\\t#include <aomap_fragment>\\n\\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n\\t#include <dithering_fragment>\\n}\";\nvar meshtoon_vert = \"#define TOON\\nvarying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n#endif\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <uv2_pars_vertex>\\n#include <displacementmap_pars_vertex>\\n#include <color_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <shadowmap_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <uv2_vertex>\\n\\t#include <color_vertex>\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n#ifndef FLAT_SHADED\\n\\tvNormal = normalize( transformedNormal );\\n#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <displacementmap_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\tvViewPosition = - mvPosition.xyz;\\n\\t#include <worldpos_vertex>\\n\\t#include <shadowmap_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar meshphong_frag = \"#define PHONG\\nuniform vec3 diffuse;\\nuniform vec3 emissive;\\nuniform vec3 specular;\\nuniform float shininess;\\nuniform float opacity;\\n#include <common>\\n#include <packing>\\n#include <dithering_pars_fragment>\\n#include <color_pars_fragment>\\n#include <uv_pars_fragment>\\n#include <uv2_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <aomap_pars_fragment>\\n#include <lightmap_pars_fragment>\\n#include <emissivemap_pars_fragment>\\n#include <envmap_common_pars_fragment>\\n#include <envmap_pars_fragment>\\n#include <cube_uv_reflection_fragment>\\n#include <fog_pars_fragment>\\n#include <bsdfs>\\n#include <lights_pars_begin>\\n#include <lights_phong_pars_fragment>\\n#include <shadowmap_pars_fragment>\\n#include <bumpmap_pars_fragment>\\n#include <normalmap_pars_fragment>\\n#include <specularmap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\\n\\tvec3 totalEmissiveRadiance = emissive;\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_fragment>\\n\\t#include <color_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\t#include <specularmap_fragment>\\n\\t#include <normal_fragment_begin>\\n\\t#include <normal_fragment_maps>\\n\\t#include <emissivemap_fragment>\\n\\t#include <lights_phong_fragment>\\n\\t#include <lights_fragment_begin>\\n\\t#include <lights_fragment_maps>\\n\\t#include <lights_fragment_end>\\n\\t#include <aomap_fragment>\\n\\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\\n\\t#include <envmap_fragment>\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n\\t#include <dithering_fragment>\\n}\";\nvar meshphong_vert = \"#define PHONG\\nvarying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n#endif\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <uv2_pars_vertex>\\n#include <displacementmap_pars_vertex>\\n#include <envmap_pars_vertex>\\n#include <color_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <shadowmap_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <uv2_vertex>\\n\\t#include <color_vertex>\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n#ifndef FLAT_SHADED\\n\\tvNormal = normalize( transformedNormal );\\n#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <displacementmap_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\tvViewPosition = - mvPosition.xyz;\\n\\t#include <worldpos_vertex>\\n\\t#include <envmap_vertex>\\n\\t#include <shadowmap_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar meshphysical_frag = \"#define STANDARD\\n#ifdef PHYSICAL\\n\\t#define REFLECTIVITY\\n\\t#define CLEARCOAT\\n\\t#define TRANSMISSION\\n#endif\\nuniform vec3 diffuse;\\nuniform vec3 emissive;\\nuniform float roughness;\\nuniform float metalness;\\nuniform float opacity;\\n#ifdef TRANSMISSION\\n\\tuniform float transmission;\\n#endif\\n#ifdef REFLECTIVITY\\n\\tuniform float reflectivity;\\n#endif\\n#ifdef CLEARCOAT\\n\\tuniform float clearcoat;\\n\\tuniform float clearcoatRoughness;\\n#endif\\n#ifdef USE_SHEEN\\n\\tuniform vec3 sheen;\\n#endif\\nvarying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n\\t#ifdef USE_TANGENT\\n\\t\\tvarying vec3 vTangent;\\n\\t\\tvarying vec3 vBitangent;\\n\\t#endif\\n#endif\\n#include <common>\\n#include <packing>\\n#include <dithering_pars_fragment>\\n#include <color_pars_fragment>\\n#include <uv_pars_fragment>\\n#include <uv2_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <aomap_pars_fragment>\\n#include <lightmap_pars_fragment>\\n#include <emissivemap_pars_fragment>\\n#include <transmissionmap_pars_fragment>\\n#include <bsdfs>\\n#include <cube_uv_reflection_fragment>\\n#include <envmap_common_pars_fragment>\\n#include <envmap_physical_pars_fragment>\\n#include <fog_pars_fragment>\\n#include <lights_pars_begin>\\n#include <lights_physical_pars_fragment>\\n#include <shadowmap_pars_fragment>\\n#include <bumpmap_pars_fragment>\\n#include <normalmap_pars_fragment>\\n#include <clearcoat_pars_fragment>\\n#include <roughnessmap_pars_fragment>\\n#include <metalnessmap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\\n\\tvec3 totalEmissiveRadiance = emissive;\\n\\t#ifdef TRANSMISSION\\n\\t\\tfloat totalTransmission = transmission;\\n\\t#endif\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_fragment>\\n\\t#include <color_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\t#include <roughnessmap_fragment>\\n\\t#include <metalnessmap_fragment>\\n\\t#include <normal_fragment_begin>\\n\\t#include <normal_fragment_maps>\\n\\t#include <clearcoat_normal_fragment_begin>\\n\\t#include <clearcoat_normal_fragment_maps>\\n\\t#include <emissivemap_fragment>\\n\\t#include <transmissionmap_fragment>\\n\\t#include <lights_physical_fragment>\\n\\t#include <lights_fragment_begin>\\n\\t#include <lights_fragment_maps>\\n\\t#include <lights_fragment_end>\\n\\t#include <aomap_fragment>\\n\\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\\n\\t#ifdef TRANSMISSION\\n\\t\\tdiffuseColor.a *= mix( saturate( 1. - totalTransmission + linearToRelativeLuminance( reflectedLight.directSpecular + reflectedLight.indirectSpecular ) ), 1.0, metalness );\\n\\t#endif\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n\\t#include <dithering_fragment>\\n}\";\nvar meshphysical_vert = \"#define STANDARD\\nvarying vec3 vViewPosition;\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n\\t#ifdef USE_TANGENT\\n\\t\\tvarying vec3 vTangent;\\n\\t\\tvarying vec3 vBitangent;\\n\\t#endif\\n#endif\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <uv2_pars_vertex>\\n#include <displacementmap_pars_vertex>\\n#include <color_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <shadowmap_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <uv2_vertex>\\n\\t#include <color_vertex>\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n#ifndef FLAT_SHADED\\n\\tvNormal = normalize( transformedNormal );\\n\\t#ifdef USE_TANGENT\\n\\t\\tvTangent = normalize( transformedTangent );\\n\\t\\tvBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );\\n\\t#endif\\n#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <displacementmap_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\tvViewPosition = - mvPosition.xyz;\\n\\t#include <worldpos_vertex>\\n\\t#include <shadowmap_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar normal_frag = \"#define NORMAL\\nuniform float opacity;\\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\\n\\tvarying vec3 vViewPosition;\\n#endif\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n\\t#ifdef USE_TANGENT\\n\\t\\tvarying vec3 vTangent;\\n\\t\\tvarying vec3 vBitangent;\\n\\t#endif\\n#endif\\n#include <packing>\\n#include <uv_pars_fragment>\\n#include <bumpmap_pars_fragment>\\n#include <normalmap_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <normal_fragment_begin>\\n\\t#include <normal_fragment_maps>\\n\\tgl_FragColor = vec4( packNormalToRGB( normal ), opacity );\\n}\";\nvar normal_vert = \"#define NORMAL\\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\\n\\tvarying vec3 vViewPosition;\\n#endif\\n#ifndef FLAT_SHADED\\n\\tvarying vec3 vNormal;\\n\\t#ifdef USE_TANGENT\\n\\t\\tvarying vec3 vTangent;\\n\\t\\tvarying vec3 vBitangent;\\n\\t#endif\\n#endif\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <displacementmap_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <skinning_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n#ifndef FLAT_SHADED\\n\\tvNormal = normalize( transformedNormal );\\n\\t#ifdef USE_TANGENT\\n\\t\\tvTangent = normalize( transformedTangent );\\n\\t\\tvBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );\\n\\t#endif\\n#endif\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <skinning_vertex>\\n\\t#include <displacementmap_vertex>\\n\\t#include <project_vertex>\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\\n\\tvViewPosition = - mvPosition.xyz;\\n#endif\\n}\";\nvar points_frag = \"uniform vec3 diffuse;\\nuniform float opacity;\\n#include <common>\\n#include <color_pars_fragment>\\n#include <map_particle_pars_fragment>\\n#include <fog_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec3 outgoingLight = vec3( 0.0 );\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_particle_fragment>\\n\\t#include <color_fragment>\\n\\t#include <alphatest_fragment>\\n\\toutgoingLight = diffuseColor.rgb;\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n\\t#include <premultiplied_alpha_fragment>\\n}\";\nvar points_vert = \"uniform float size;\\nuniform float scale;\\n#include <common>\\n#include <color_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <morphtarget_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <color_vertex>\\n\\t#include <begin_vertex>\\n\\t#include <morphtarget_vertex>\\n\\t#include <project_vertex>\\n\\tgl_PointSize = size;\\n\\t#ifdef USE_SIZEATTENUATION\\n\\t\\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\\n\\t\\tif ( isPerspective ) gl_PointSize *= ( scale / - mvPosition.z );\\n\\t#endif\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\t#include <worldpos_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar shadow_frag = \"uniform vec3 color;\\nuniform float opacity;\\n#include <common>\\n#include <packing>\\n#include <fog_pars_fragment>\\n#include <bsdfs>\\n#include <lights_pars_begin>\\n#include <shadowmap_pars_fragment>\\n#include <shadowmask_pars_fragment>\\nvoid main() {\\n\\tgl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n}\";\nvar shadow_vert = \"#include <common>\\n#include <fog_pars_vertex>\\n#include <shadowmap_pars_vertex>\\nvoid main() {\\n\\t#include <begin_vertex>\\n\\t#include <project_vertex>\\n\\t#include <worldpos_vertex>\\n\\t#include <beginnormal_vertex>\\n\\t#include <morphnormal_vertex>\\n\\t#include <skinbase_vertex>\\n\\t#include <skinnormal_vertex>\\n\\t#include <defaultnormal_vertex>\\n\\t#include <shadowmap_vertex>\\n\\t#include <fog_vertex>\\n}\";\nvar sprite_frag = \"uniform vec3 diffuse;\\nuniform float opacity;\\n#include <common>\\n#include <uv_pars_fragment>\\n#include <map_pars_fragment>\\n#include <alphamap_pars_fragment>\\n#include <fog_pars_fragment>\\n#include <logdepthbuf_pars_fragment>\\n#include <clipping_planes_pars_fragment>\\nvoid main() {\\n\\t#include <clipping_planes_fragment>\\n\\tvec3 outgoingLight = vec3( 0.0 );\\n\\tvec4 diffuseColor = vec4( diffuse, opacity );\\n\\t#include <logdepthbuf_fragment>\\n\\t#include <map_fragment>\\n\\t#include <alphamap_fragment>\\n\\t#include <alphatest_fragment>\\n\\toutgoingLight = diffuseColor.rgb;\\n\\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\\n\\t#include <tonemapping_fragment>\\n\\t#include <encodings_fragment>\\n\\t#include <fog_fragment>\\n}\";\nvar sprite_vert = \"uniform float rotation;\\nuniform vec2 center;\\n#include <common>\\n#include <uv_pars_vertex>\\n#include <fog_pars_vertex>\\n#include <logdepthbuf_pars_vertex>\\n#include <clipping_planes_pars_vertex>\\nvoid main() {\\n\\t#include <uv_vertex>\\n\\tvec4 mvPosition = modelViewMatrix * vec4( 0.0, 0.0, 0.0, 1.0 );\\n\\tvec2 scale;\\n\\tscale.x = length( vec3( modelMatrix[ 0 ].x, modelMatrix[ 0 ].y, modelMatrix[ 0 ].z ) );\\n\\tscale.y = length( vec3( modelMatrix[ 1 ].x, modelMatrix[ 1 ].y, modelMatrix[ 1 ].z ) );\\n\\t#ifndef USE_SIZEATTENUATION\\n\\t\\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\\n\\t\\tif ( isPerspective ) scale *= - mvPosition.z;\\n\\t#endif\\n\\tvec2 alignedPosition = ( position.xy - ( center - vec2( 0.5 ) ) ) * scale;\\n\\tvec2 rotatedPosition;\\n\\trotatedPosition.x = cos( rotation ) * alignedPosition.x - sin( rotation ) * alignedPosition.y;\\n\\trotatedPosition.y = sin( rotation ) * alignedPosition.x + cos( rotation ) * alignedPosition.y;\\n\\tmvPosition.xy += rotatedPosition;\\n\\tgl_Position = projectionMatrix * mvPosition;\\n\\t#include <logdepthbuf_vertex>\\n\\t#include <clipping_planes_vertex>\\n\\t#include <fog_vertex>\\n}\";\nconst ShaderChunk = {\n  alphamap_fragment: alphamap_fragment,\n  alphamap_pars_fragment: alphamap_pars_fragment,\n  alphatest_fragment: alphatest_fragment,\n  aomap_fragment: aomap_fragment,\n  aomap_pars_fragment: aomap_pars_fragment,\n  begin_vertex: begin_vertex,\n  beginnormal_vertex: beginnormal_vertex,\n  bsdfs: bsdfs,\n  bumpmap_pars_fragment: bumpmap_pars_fragment,\n  clipping_planes_fragment: clipping_planes_fragment,\n  clipping_planes_pars_fragment: clipping_planes_pars_fragment,\n  clipping_planes_pars_vertex: clipping_planes_pars_vertex,\n  clipping_planes_vertex: clipping_planes_vertex,\n  color_fragment: color_fragment,\n  color_pars_fragment: color_pars_fragment,\n  color_pars_vertex: color_pars_vertex,\n  color_vertex: color_vertex,\n  common: common,\n  cube_uv_reflection_fragment: cube_uv_reflection_fragment,\n  defaultnormal_vertex: defaultnormal_vertex,\n  displacementmap_pars_vertex: displacementmap_pars_vertex,\n  displacementmap_vertex: displacementmap_vertex,\n  emissivemap_fragment: emissivemap_fragment,\n  emissivemap_pars_fragment: emissivemap_pars_fragment,\n  encodings_fragment: encodings_fragment,\n  encodings_pars_fragment: encodings_pars_fragment,\n  envmap_fragment: envmap_fragment,\n  envmap_common_pars_fragment: envmap_common_pars_fragment,\n  envmap_pars_fragment: envmap_pars_fragment,\n  envmap_pars_vertex: envmap_pars_vertex,\n  envmap_physical_pars_fragment: envmap_physical_pars_fragment,\n  envmap_vertex: envmap_vertex,\n  fog_vertex: fog_vertex,\n  fog_pars_vertex: fog_pars_vertex,\n  fog_fragment: fog_fragment,\n  fog_pars_fragment: fog_pars_fragment,\n  gradientmap_pars_fragment: gradientmap_pars_fragment,\n  lightmap_fragment: lightmap_fragment,\n  lightmap_pars_fragment: lightmap_pars_fragment,\n  lights_lambert_vertex: lights_lambert_vertex,\n  lights_pars_begin: lights_pars_begin,\n  lights_toon_fragment: lights_toon_fragment,\n  lights_toon_pars_fragment: lights_toon_pars_fragment,\n  lights_phong_fragment: lights_phong_fragment,\n  lights_phong_pars_fragment: lights_phong_pars_fragment,\n  lights_physical_fragment: lights_physical_fragment,\n  lights_physical_pars_fragment: lights_physical_pars_fragment,\n  lights_fragment_begin: lights_fragment_begin,\n  lights_fragment_maps: lights_fragment_maps,\n  lights_fragment_end: lights_fragment_end,\n  logdepthbuf_fragment: logdepthbuf_fragment,\n  logdepthbuf_pars_fragment: logdepthbuf_pars_fragment,\n  logdepthbuf_pars_vertex: logdepthbuf_pars_vertex,\n  logdepthbuf_vertex: logdepthbuf_vertex,\n  map_fragment: map_fragment,\n  map_pars_fragment: map_pars_fragment,\n  map_particle_fragment: map_particle_fragment,\n  map_particle_pars_fragment: map_particle_pars_fragment,\n  metalnessmap_fragment: metalnessmap_fragment,\n  metalnessmap_pars_fragment: metalnessmap_pars_fragment,\n  morphnormal_vertex: morphnormal_vertex,\n  morphtarget_pars_vertex: morphtarget_pars_vertex,\n  morphtarget_vertex: morphtarget_vertex,\n  normal_fragment_begin: normal_fragment_begin,\n  normal_fragment_maps: normal_fragment_maps,\n  normalmap_pars_fragment: normalmap_pars_fragment,\n  clearcoat_normal_fragment_begin: clearcoat_normal_fragment_begin,\n  clearcoat_normal_fragment_maps: clearcoat_normal_fragment_maps,\n  clearcoat_pars_fragment: clearcoat_pars_fragment,\n  packing: packing,\n  premultiplied_alpha_fragment: premultiplied_alpha_fragment,\n  project_vertex: project_vertex,\n  dithering_fragment: dithering_fragment,\n  dithering_pars_fragment: dithering_pars_fragment,\n  roughnessmap_fragment: roughnessmap_fragment,\n  roughnessmap_pars_fragment: roughnessmap_pars_fragment,\n  shadowmap_pars_fragment: shadowmap_pars_fragment,\n  shadowmap_pars_vertex: shadowmap_pars_vertex,\n  shadowmap_vertex: shadowmap_vertex,\n  shadowmask_pars_fragment: shadowmask_pars_fragment,\n  skinbase_vertex: skinbase_vertex,\n  skinning_pars_vertex: skinning_pars_vertex,\n  skinning_vertex: skinning_vertex,\n  skinnormal_vertex: skinnormal_vertex,\n  specularmap_fragment: specularmap_fragment,\n  specularmap_pars_fragment: specularmap_pars_fragment,\n  tonemapping_fragment: tonemapping_fragment,\n  tonemapping_pars_fragment: tonemapping_pars_fragment,\n  transmissionmap_fragment: transmissionmap_fragment,\n  transmissionmap_pars_fragment: transmissionmap_pars_fragment,\n  uv_pars_fragment: uv_pars_fragment,\n  uv_pars_vertex: uv_pars_vertex,\n  uv_vertex: uv_vertex,\n  uv2_pars_fragment: uv2_pars_fragment,\n  uv2_pars_vertex: uv2_pars_vertex,\n  uv2_vertex: uv2_vertex,\n  worldpos_vertex: worldpos_vertex,\n  background_frag: background_frag,\n  background_vert: background_vert,\n  cube_frag: cube_frag,\n  cube_vert: cube_vert,\n  depth_frag: depth_frag,\n  depth_vert: depth_vert,\n  distanceRGBA_frag: distanceRGBA_frag,\n  distanceRGBA_vert: distanceRGBA_vert,\n  equirect_frag: equirect_frag,\n  equirect_vert: equirect_vert,\n  linedashed_frag: linedashed_frag,\n  linedashed_vert: linedashed_vert,\n  meshbasic_frag: meshbasic_frag,\n  meshbasic_vert: meshbasic_vert,\n  meshlambert_frag: meshlambert_frag,\n  meshlambert_vert: meshlambert_vert,\n  meshmatcap_frag: meshmatcap_frag,\n  meshmatcap_vert: meshmatcap_vert,\n  meshtoon_frag: meshtoon_frag,\n  meshtoon_vert: meshtoon_vert,\n  meshphong_frag: meshphong_frag,\n  meshphong_vert: meshphong_vert,\n  meshphysical_frag: meshphysical_frag,\n  meshphysical_vert: meshphysical_vert,\n  normal_frag: normal_frag,\n  normal_vert: normal_vert,\n  points_frag: points_frag,\n  points_vert: points_vert,\n  shadow_frag: shadow_frag,\n  shadow_vert: shadow_vert,\n  sprite_frag: sprite_frag,\n  sprite_vert: sprite_vert\n};\n\n/**\n * Uniforms library for shared webgl shaders\n */\n\nconst UniformsLib = {\n  common: {\n    diffuse: {\n      value: new Color(0xeeeeee)\n    },\n    opacity: {\n      value: 1.0\n    },\n    map: {\n      value: null\n    },\n    uvTransform: {\n      value: new Matrix3()\n    },\n    uv2Transform: {\n      value: new Matrix3()\n    },\n    alphaMap: {\n      value: null\n    }\n  },\n  specularmap: {\n    specularMap: {\n      value: null\n    }\n  },\n  envmap: {\n    envMap: {\n      value: null\n    },\n    flipEnvMap: {\n      value: -1\n    },\n    reflectivity: {\n      value: 1.0\n    },\n    refractionRatio: {\n      value: 0.98\n    },\n    maxMipLevel: {\n      value: 0\n    }\n  },\n  aomap: {\n    aoMap: {\n      value: null\n    },\n    aoMapIntensity: {\n      value: 1\n    }\n  },\n  lightmap: {\n    lightMap: {\n      value: null\n    },\n    lightMapIntensity: {\n      value: 1\n    }\n  },\n  emissivemap: {\n    emissiveMap: {\n      value: null\n    }\n  },\n  bumpmap: {\n    bumpMap: {\n      value: null\n    },\n    bumpScale: {\n      value: 1\n    }\n  },\n  normalmap: {\n    normalMap: {\n      value: null\n    },\n    normalScale: {\n      value: new Vector2(1, 1)\n    }\n  },\n  displacementmap: {\n    displacementMap: {\n      value: null\n    },\n    displacementScale: {\n      value: 1\n    },\n    displacementBias: {\n      value: 0\n    }\n  },\n  roughnessmap: {\n    roughnessMap: {\n      value: null\n    }\n  },\n  metalnessmap: {\n    metalnessMap: {\n      value: null\n    }\n  },\n  gradientmap: {\n    gradientMap: {\n      value: null\n    }\n  },\n  fog: {\n    fogDensity: {\n      value: 0.00025\n    },\n    fogNear: {\n      value: 1\n    },\n    fogFar: {\n      value: 2000\n    },\n    fogColor: {\n      value: new Color(0xffffff)\n    }\n  },\n  lights: {\n    ambientLightColor: {\n      value: []\n    },\n    lightProbe: {\n      value: []\n    },\n    directionalLights: {\n      value: [],\n      properties: {\n        direction: {},\n        color: {}\n      }\n    },\n    directionalLightShadows: {\n      value: [],\n      properties: {\n        shadowBias: {},\n        shadowNormalBias: {},\n        shadowRadius: {},\n        shadowMapSize: {}\n      }\n    },\n    directionalShadowMap: {\n      value: []\n    },\n    directionalShadowMatrix: {\n      value: []\n    },\n    spotLights: {\n      value: [],\n      properties: {\n        color: {},\n        position: {},\n        direction: {},\n        distance: {},\n        coneCos: {},\n        penumbraCos: {},\n        decay: {}\n      }\n    },\n    spotLightShadows: {\n      value: [],\n      properties: {\n        shadowBias: {},\n        shadowNormalBias: {},\n        shadowRadius: {},\n        shadowMapSize: {}\n      }\n    },\n    spotShadowMap: {\n      value: []\n    },\n    spotShadowMatrix: {\n      value: []\n    },\n    pointLights: {\n      value: [],\n      properties: {\n        color: {},\n        position: {},\n        decay: {},\n        distance: {}\n      }\n    },\n    pointLightShadows: {\n      value: [],\n      properties: {\n        shadowBias: {},\n        shadowNormalBias: {},\n        shadowRadius: {},\n        shadowMapSize: {},\n        shadowCameraNear: {},\n        shadowCameraFar: {}\n      }\n    },\n    pointShadowMap: {\n      value: []\n    },\n    pointShadowMatrix: {\n      value: []\n    },\n    hemisphereLights: {\n      value: [],\n      properties: {\n        direction: {},\n        skyColor: {},\n        groundColor: {}\n      }\n    },\n    // TODO (abelnation): RectAreaLight BRDF data needs to be moved from example to main src\n    rectAreaLights: {\n      value: [],\n      properties: {\n        color: {},\n        position: {},\n        width: {},\n        height: {}\n      }\n    },\n    ltc_1: {\n      value: null\n    },\n    ltc_2: {\n      value: null\n    }\n  },\n  points: {\n    diffuse: {\n      value: new Color(0xeeeeee)\n    },\n    opacity: {\n      value: 1.0\n    },\n    size: {\n      value: 1.0\n    },\n    scale: {\n      value: 1.0\n    },\n    map: {\n      value: null\n    },\n    alphaMap: {\n      value: null\n    },\n    uvTransform: {\n      value: new Matrix3()\n    }\n  },\n  sprite: {\n    diffuse: {\n      value: new Color(0xeeeeee)\n    },\n    opacity: {\n      value: 1.0\n    },\n    center: {\n      value: new Vector2(0.5, 0.5)\n    },\n    rotation: {\n      value: 0.0\n    },\n    map: {\n      value: null\n    },\n    alphaMap: {\n      value: null\n    },\n    uvTransform: {\n      value: new Matrix3()\n    }\n  }\n};\nconst ShaderLib = {\n  basic: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.specularmap, UniformsLib.envmap, UniformsLib.aomap, UniformsLib.lightmap, UniformsLib.fog]),\n    vertexShader: ShaderChunk.meshbasic_vert,\n    fragmentShader: ShaderChunk.meshbasic_frag\n  },\n  lambert: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.specularmap, UniformsLib.envmap, UniformsLib.aomap, UniformsLib.lightmap, UniformsLib.emissivemap, UniformsLib.fog, UniformsLib.lights, {\n      emissive: {\n        value: new Color(0x000000)\n      }\n    }]),\n    vertexShader: ShaderChunk.meshlambert_vert,\n    fragmentShader: ShaderChunk.meshlambert_frag\n  },\n  phong: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.specularmap, UniformsLib.envmap, UniformsLib.aomap, UniformsLib.lightmap, UniformsLib.emissivemap, UniformsLib.bumpmap, UniformsLib.normalmap, UniformsLib.displacementmap, UniformsLib.fog, UniformsLib.lights, {\n      emissive: {\n        value: new Color(0x000000)\n      },\n      specular: {\n        value: new Color(0x111111)\n      },\n      shininess: {\n        value: 30\n      }\n    }]),\n    vertexShader: ShaderChunk.meshphong_vert,\n    fragmentShader: ShaderChunk.meshphong_frag\n  },\n  standard: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.envmap, UniformsLib.aomap, UniformsLib.lightmap, UniformsLib.emissivemap, UniformsLib.bumpmap, UniformsLib.normalmap, UniformsLib.displacementmap, UniformsLib.roughnessmap, UniformsLib.metalnessmap, UniformsLib.fog, UniformsLib.lights, {\n      emissive: {\n        value: new Color(0x000000)\n      },\n      roughness: {\n        value: 1.0\n      },\n      metalness: {\n        value: 0.0\n      },\n      envMapIntensity: {\n        value: 1\n      } // temporary\n    }]),\n\n    vertexShader: ShaderChunk.meshphysical_vert,\n    fragmentShader: ShaderChunk.meshphysical_frag\n  },\n  toon: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.aomap, UniformsLib.lightmap, UniformsLib.emissivemap, UniformsLib.bumpmap, UniformsLib.normalmap, UniformsLib.displacementmap, UniformsLib.gradientmap, UniformsLib.fog, UniformsLib.lights, {\n      emissive: {\n        value: new Color(0x000000)\n      }\n    }]),\n    vertexShader: ShaderChunk.meshtoon_vert,\n    fragmentShader: ShaderChunk.meshtoon_frag\n  },\n  matcap: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.bumpmap, UniformsLib.normalmap, UniformsLib.displacementmap, UniformsLib.fog, {\n      matcap: {\n        value: null\n      }\n    }]),\n    vertexShader: ShaderChunk.meshmatcap_vert,\n    fragmentShader: ShaderChunk.meshmatcap_frag\n  },\n  points: {\n    uniforms: mergeUniforms([UniformsLib.points, UniformsLib.fog]),\n    vertexShader: ShaderChunk.points_vert,\n    fragmentShader: ShaderChunk.points_frag\n  },\n  dashed: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.fog, {\n      scale: {\n        value: 1\n      },\n      dashSize: {\n        value: 1\n      },\n      totalSize: {\n        value: 2\n      }\n    }]),\n    vertexShader: ShaderChunk.linedashed_vert,\n    fragmentShader: ShaderChunk.linedashed_frag\n  },\n  depth: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.displacementmap]),\n    vertexShader: ShaderChunk.depth_vert,\n    fragmentShader: ShaderChunk.depth_frag\n  },\n  normal: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.bumpmap, UniformsLib.normalmap, UniformsLib.displacementmap, {\n      opacity: {\n        value: 1.0\n      }\n    }]),\n    vertexShader: ShaderChunk.normal_vert,\n    fragmentShader: ShaderChunk.normal_frag\n  },\n  sprite: {\n    uniforms: mergeUniforms([UniformsLib.sprite, UniformsLib.fog]),\n    vertexShader: ShaderChunk.sprite_vert,\n    fragmentShader: ShaderChunk.sprite_frag\n  },\n  background: {\n    uniforms: {\n      uvTransform: {\n        value: new Matrix3()\n      },\n      t2D: {\n        value: null\n      }\n    },\n    vertexShader: ShaderChunk.background_vert,\n    fragmentShader: ShaderChunk.background_frag\n  },\n  /* -------------------------------------------------------------------------\n  //\tCube map shader\n   ------------------------------------------------------------------------- */\n\n  cube: {\n    uniforms: mergeUniforms([UniformsLib.envmap, {\n      opacity: {\n        value: 1.0\n      }\n    }]),\n    vertexShader: ShaderChunk.cube_vert,\n    fragmentShader: ShaderChunk.cube_frag\n  },\n  equirect: {\n    uniforms: {\n      tEquirect: {\n        value: null\n      }\n    },\n    vertexShader: ShaderChunk.equirect_vert,\n    fragmentShader: ShaderChunk.equirect_frag\n  },\n  distanceRGBA: {\n    uniforms: mergeUniforms([UniformsLib.common, UniformsLib.displacementmap, {\n      referencePosition: {\n        value: new Vector3()\n      },\n      nearDistance: {\n        value: 1\n      },\n      farDistance: {\n        value: 1000\n      }\n    }]),\n    vertexShader: ShaderChunk.distanceRGBA_vert,\n    fragmentShader: ShaderChunk.distanceRGBA_frag\n  },\n  shadow: {\n    uniforms: mergeUniforms([UniformsLib.lights, UniformsLib.fog, {\n      color: {\n        value: new Color(0x00000)\n      },\n      opacity: {\n        value: 1.0\n      }\n    }]),\n    vertexShader: ShaderChunk.shadow_vert,\n    fragmentShader: ShaderChunk.shadow_frag\n  }\n};\nShaderLib.physical = {\n  uniforms: mergeUniforms([ShaderLib.standard.uniforms, {\n    clearcoat: {\n      value: 0\n    },\n    clearcoatMap: {\n      value: null\n    },\n    clearcoatRoughness: {\n      value: 0\n    },\n    clearcoatRoughnessMap: {\n      value: null\n    },\n    clearcoatNormalScale: {\n      value: new Vector2(1, 1)\n    },\n    clearcoatNormalMap: {\n      value: null\n    },\n    sheen: {\n      value: new Color(0x000000)\n    },\n    transmission: {\n      value: 0\n    },\n    transmissionMap: {\n      value: null\n    }\n  }]),\n  vertexShader: ShaderChunk.meshphysical_vert,\n  fragmentShader: ShaderChunk.meshphysical_frag\n};\nfunction WebGLBackground(renderer, cubemaps, state, objects, premultipliedAlpha) {\n  const clearColor = new Color(0x000000);\n  let clearAlpha = 0;\n  let planeMesh;\n  let boxMesh;\n  let currentBackground = null;\n  let currentBackgroundVersion = 0;\n  let currentTonemapping = null;\n  function render(renderList, scene, camera, forceClear) {\n    let background = scene.isScene === true ? scene.background : null;\n    if (background && background.isTexture) {\n      background = cubemaps.get(background);\n    }\n\n    // Ignore background in AR\n    // TODO: Reconsider this.\n\n    const xr = renderer.xr;\n    const session = xr.getSession && xr.getSession();\n    if (session && session.environmentBlendMode === 'additive') {\n      background = null;\n    }\n    if (background === null) {\n      setClear(clearColor, clearAlpha);\n    } else if (background && background.isColor) {\n      setClear(background, 1);\n      forceClear = true;\n    }\n    if (renderer.autoClear || forceClear) {\n      renderer.clear(renderer.autoClearColor, renderer.autoClearDepth, renderer.autoClearStencil);\n    }\n    if (background && (background.isCubeTexture || background.isWebGLCubeRenderTarget || background.mapping === CubeUVReflectionMapping)) {\n      if (boxMesh === undefined) {\n        boxMesh = new Mesh(new BoxGeometry(1, 1, 1), new ShaderMaterial({\n          name: 'BackgroundCubeMaterial',\n          uniforms: cloneUniforms(ShaderLib.cube.uniforms),\n          vertexShader: ShaderLib.cube.vertexShader,\n          fragmentShader: ShaderLib.cube.fragmentShader,\n          side: BackSide,\n          depthTest: false,\n          depthWrite: false,\n          fog: false\n        }));\n        boxMesh.geometry.deleteAttribute('normal');\n        boxMesh.geometry.deleteAttribute('uv');\n        boxMesh.onBeforeRender = function (renderer, scene, camera) {\n          this.matrixWorld.copyPosition(camera.matrixWorld);\n        };\n\n        // enable code injection for non-built-in material\n        Object.defineProperty(boxMesh.material, 'envMap', {\n          get: function () {\n            return this.uniforms.envMap.value;\n          }\n        });\n        objects.update(boxMesh);\n      }\n      if (background.isWebGLCubeRenderTarget) {\n        // TODO Deprecate\n\n        background = background.texture;\n      }\n      boxMesh.material.uniforms.envMap.value = background;\n      boxMesh.material.uniforms.flipEnvMap.value = background.isCubeTexture && background._needsFlipEnvMap ? -1 : 1;\n      if (currentBackground !== background || currentBackgroundVersion !== background.version || currentTonemapping !== renderer.toneMapping) {\n        boxMesh.material.needsUpdate = true;\n        currentBackground = background;\n        currentBackgroundVersion = background.version;\n        currentTonemapping = renderer.toneMapping;\n      }\n\n      // push to the pre-sorted opaque render list\n      renderList.unshift(boxMesh, boxMesh.geometry, boxMesh.material, 0, 0, null);\n    } else if (background && background.isTexture) {\n      if (planeMesh === undefined) {\n        planeMesh = new Mesh(new PlaneGeometry(2, 2), new ShaderMaterial({\n          name: 'BackgroundMaterial',\n          uniforms: cloneUniforms(ShaderLib.background.uniforms),\n          vertexShader: ShaderLib.background.vertexShader,\n          fragmentShader: ShaderLib.background.fragmentShader,\n          side: FrontSide,\n          depthTest: false,\n          depthWrite: false,\n          fog: false\n        }));\n        planeMesh.geometry.deleteAttribute('normal');\n\n        // enable code injection for non-built-in material\n        Object.defineProperty(planeMesh.material, 'map', {\n          get: function () {\n            return this.uniforms.t2D.value;\n          }\n        });\n        objects.update(planeMesh);\n      }\n      planeMesh.material.uniforms.t2D.value = background;\n      if (background.matrixAutoUpdate === true) {\n        background.updateMatrix();\n      }\n      planeMesh.material.uniforms.uvTransform.value.copy(background.matrix);\n      if (currentBackground !== background || currentBackgroundVersion !== background.version || currentTonemapping !== renderer.toneMapping) {\n        planeMesh.material.needsUpdate = true;\n        currentBackground = background;\n        currentBackgroundVersion = background.version;\n        currentTonemapping = renderer.toneMapping;\n      }\n\n      // push to the pre-sorted opaque render list\n      renderList.unshift(planeMesh, planeMesh.geometry, planeMesh.material, 0, 0, null);\n    }\n  }\n  function setClear(color, alpha) {\n    state.buffers.color.setClear(color.r, color.g, color.b, alpha, premultipliedAlpha);\n  }\n  return {\n    getClearColor: function () {\n      return clearColor;\n    },\n    setClearColor: function (color, alpha = 1) {\n      clearColor.set(color);\n      clearAlpha = alpha;\n      setClear(clearColor, clearAlpha);\n    },\n    getClearAlpha: function () {\n      return clearAlpha;\n    },\n    setClearAlpha: function (alpha) {\n      clearAlpha = alpha;\n      setClear(clearColor, clearAlpha);\n    },\n    render: render\n  };\n}\nfunction WebGLBindingStates(gl, extensions, attributes, capabilities) {\n  const maxVertexAttributes = gl.getParameter(34921);\n  const extension = capabilities.isWebGL2 ? null : extensions.get('OES_vertex_array_object');\n  const vaoAvailable = capabilities.isWebGL2 || extension !== null;\n  const bindingStates = {};\n  const defaultState = createBindingState(null);\n  let currentState = defaultState;\n  function setup(object, material, program, geometry, index) {\n    let updateBuffers = false;\n    if (vaoAvailable) {\n      const state = getBindingState(geometry, program, material);\n      if (currentState !== state) {\n        currentState = state;\n        bindVertexArrayObject(currentState.object);\n      }\n      updateBuffers = needsUpdate(geometry, index);\n      if (updateBuffers) saveCache(geometry, index);\n    } else {\n      const wireframe = material.wireframe === true;\n      if (currentState.geometry !== geometry.id || currentState.program !== program.id || currentState.wireframe !== wireframe) {\n        currentState.geometry = geometry.id;\n        currentState.program = program.id;\n        currentState.wireframe = wireframe;\n        updateBuffers = true;\n      }\n    }\n    if (object.isInstancedMesh === true) {\n      updateBuffers = true;\n    }\n    if (index !== null) {\n      attributes.update(index, 34963);\n    }\n    if (updateBuffers) {\n      setupVertexAttributes(object, material, program, geometry);\n      if (index !== null) {\n        gl.bindBuffer(34963, attributes.get(index).buffer);\n      }\n    }\n  }\n  function createVertexArrayObject() {\n    if (capabilities.isWebGL2) return gl.createVertexArray();\n    return extension.createVertexArrayOES();\n  }\n  function bindVertexArrayObject(vao) {\n    if (capabilities.isWebGL2) return gl.bindVertexArray(vao);\n    return extension.bindVertexArrayOES(vao);\n  }\n  function deleteVertexArrayObject(vao) {\n    if (capabilities.isWebGL2) return gl.deleteVertexArray(vao);\n    return extension.deleteVertexArrayOES(vao);\n  }\n  function getBindingState(geometry, program, material) {\n    const wireframe = material.wireframe === true;\n    let programMap = bindingStates[geometry.id];\n    if (programMap === undefined) {\n      programMap = {};\n      bindingStates[geometry.id] = programMap;\n    }\n    let stateMap = programMap[program.id];\n    if (stateMap === undefined) {\n      stateMap = {};\n      programMap[program.id] = stateMap;\n    }\n    let state = stateMap[wireframe];\n    if (state === undefined) {\n      state = createBindingState(createVertexArrayObject());\n      stateMap[wireframe] = state;\n    }\n    return state;\n  }\n  function createBindingState(vao) {\n    const newAttributes = [];\n    const enabledAttributes = [];\n    const attributeDivisors = [];\n    for (let i = 0; i < maxVertexAttributes; i++) {\n      newAttributes[i] = 0;\n      enabledAttributes[i] = 0;\n      attributeDivisors[i] = 0;\n    }\n    return {\n      // for backward compatibility on non-VAO support browser\n      geometry: null,\n      program: null,\n      wireframe: false,\n      newAttributes: newAttributes,\n      enabledAttributes: enabledAttributes,\n      attributeDivisors: attributeDivisors,\n      object: vao,\n      attributes: {},\n      index: null\n    };\n  }\n  function needsUpdate(geometry, index) {\n    const cachedAttributes = currentState.attributes;\n    const geometryAttributes = geometry.attributes;\n    let attributesNum = 0;\n    for (const key in geometryAttributes) {\n      const cachedAttribute = cachedAttributes[key];\n      const geometryAttribute = geometryAttributes[key];\n      if (cachedAttribute === undefined) return true;\n      if (cachedAttribute.attribute !== geometryAttribute) return true;\n      if (cachedAttribute.data !== geometryAttribute.data) return true;\n      attributesNum++;\n    }\n    if (currentState.attributesNum !== attributesNum) return true;\n    if (currentState.index !== index) return true;\n    return false;\n  }\n  function saveCache(geometry, index) {\n    const cache = {};\n    const attributes = geometry.attributes;\n    let attributesNum = 0;\n    for (const key in attributes) {\n      const attribute = attributes[key];\n      const data = {};\n      data.attribute = attribute;\n      if (attribute.data) {\n        data.data = attribute.data;\n      }\n      cache[key] = data;\n      attributesNum++;\n    }\n    currentState.attributes = cache;\n    currentState.attributesNum = attributesNum;\n    currentState.index = index;\n  }\n  function initAttributes() {\n    const newAttributes = currentState.newAttributes;\n    for (let i = 0, il = newAttributes.length; i < il; i++) {\n      newAttributes[i] = 0;\n    }\n  }\n  function enableAttribute(attribute) {\n    enableAttributeAndDivisor(attribute, 0);\n  }\n  function enableAttributeAndDivisor(attribute, meshPerAttribute) {\n    const newAttributes = currentState.newAttributes;\n    const enabledAttributes = currentState.enabledAttributes;\n    const attributeDivisors = currentState.attributeDivisors;\n    newAttributes[attribute] = 1;\n    if (enabledAttributes[attribute] === 0) {\n      gl.enableVertexAttribArray(attribute);\n      enabledAttributes[attribute] = 1;\n    }\n    if (attributeDivisors[attribute] !== meshPerAttribute) {\n      const extension = capabilities.isWebGL2 ? gl : extensions.get('ANGLE_instanced_arrays');\n      extension[capabilities.isWebGL2 ? 'vertexAttribDivisor' : 'vertexAttribDivisorANGLE'](attribute, meshPerAttribute);\n      attributeDivisors[attribute] = meshPerAttribute;\n    }\n  }\n  function disableUnusedAttributes() {\n    const newAttributes = currentState.newAttributes;\n    const enabledAttributes = currentState.enabledAttributes;\n    for (let i = 0, il = enabledAttributes.length; i < il; i++) {\n      if (enabledAttributes[i] !== newAttributes[i]) {\n        gl.disableVertexAttribArray(i);\n        enabledAttributes[i] = 0;\n      }\n    }\n  }\n  function vertexAttribPointer(index, size, type, normalized, stride, offset) {\n    if (capabilities.isWebGL2 === true && (type === 5124 || type === 5125)) {\n      gl.vertexAttribIPointer(index, size, type, stride, offset);\n    } else {\n      gl.vertexAttribPointer(index, size, type, normalized, stride, offset);\n    }\n  }\n  function setupVertexAttributes(object, material, program, geometry) {\n    if (capabilities.isWebGL2 === false && (object.isInstancedMesh || geometry.isInstancedBufferGeometry)) {\n      if (extensions.get('ANGLE_instanced_arrays') === null) return;\n    }\n    initAttributes();\n    const geometryAttributes = geometry.attributes;\n    const programAttributes = program.getAttributes();\n    const materialDefaultAttributeValues = material.defaultAttributeValues;\n    for (const name in programAttributes) {\n      const programAttribute = programAttributes[name];\n      if (programAttribute >= 0) {\n        const geometryAttribute = geometryAttributes[name];\n        if (geometryAttribute !== undefined) {\n          const normalized = geometryAttribute.normalized;\n          const size = geometryAttribute.itemSize;\n          const attribute = attributes.get(geometryAttribute);\n\n          // TODO Attribute may not be available on context restore\n\n          if (attribute === undefined) continue;\n          const buffer = attribute.buffer;\n          const type = attribute.type;\n          const bytesPerElement = attribute.bytesPerElement;\n          if (geometryAttribute.isInterleavedBufferAttribute) {\n            const data = geometryAttribute.data;\n            const stride = data.stride;\n            const offset = geometryAttribute.offset;\n            if (data && data.isInstancedInterleavedBuffer) {\n              enableAttributeAndDivisor(programAttribute, data.meshPerAttribute);\n              if (geometry._maxInstanceCount === undefined) {\n                geometry._maxInstanceCount = data.meshPerAttribute * data.count;\n              }\n            } else {\n              enableAttribute(programAttribute);\n            }\n            gl.bindBuffer(34962, buffer);\n            vertexAttribPointer(programAttribute, size, type, normalized, stride * bytesPerElement, offset * bytesPerElement);\n          } else {\n            if (geometryAttribute.isInstancedBufferAttribute) {\n              enableAttributeAndDivisor(programAttribute, geometryAttribute.meshPerAttribute);\n              if (geometry._maxInstanceCount === undefined) {\n                geometry._maxInstanceCount = geometryAttribute.meshPerAttribute * geometryAttribute.count;\n              }\n            } else {\n              enableAttribute(programAttribute);\n            }\n            gl.bindBuffer(34962, buffer);\n            vertexAttribPointer(programAttribute, size, type, normalized, 0, 0);\n          }\n        } else if (name === 'instanceMatrix') {\n          const attribute = attributes.get(object.instanceMatrix);\n\n          // TODO Attribute may not be available on context restore\n\n          if (attribute === undefined) continue;\n          const buffer = attribute.buffer;\n          const type = attribute.type;\n          enableAttributeAndDivisor(programAttribute + 0, 1);\n          enableAttributeAndDivisor(programAttribute + 1, 1);\n          enableAttributeAndDivisor(programAttribute + 2, 1);\n          enableAttributeAndDivisor(programAttribute + 3, 1);\n          gl.bindBuffer(34962, buffer);\n          gl.vertexAttribPointer(programAttribute + 0, 4, type, false, 64, 0);\n          gl.vertexAttribPointer(programAttribute + 1, 4, type, false, 64, 16);\n          gl.vertexAttribPointer(programAttribute + 2, 4, type, false, 64, 32);\n          gl.vertexAttribPointer(programAttribute + 3, 4, type, false, 64, 48);\n        } else if (name === 'instanceColor') {\n          const attribute = attributes.get(object.instanceColor);\n\n          // TODO Attribute may not be available on context restore\n\n          if (attribute === undefined) continue;\n          const buffer = attribute.buffer;\n          const type = attribute.type;\n          enableAttributeAndDivisor(programAttribute, 1);\n          gl.bindBuffer(34962, buffer);\n          gl.vertexAttribPointer(programAttribute, 3, type, false, 12, 0);\n        } else if (materialDefaultAttributeValues !== undefined) {\n          const value = materialDefaultAttributeValues[name];\n          if (value !== undefined) {\n            switch (value.length) {\n              case 2:\n                gl.vertexAttrib2fv(programAttribute, value);\n                break;\n              case 3:\n                gl.vertexAttrib3fv(programAttribute, value);\n                break;\n              case 4:\n                gl.vertexAttrib4fv(programAttribute, value);\n                break;\n              default:\n                gl.vertexAttrib1fv(programAttribute, value);\n            }\n          }\n        }\n      }\n    }\n    disableUnusedAttributes();\n  }\n  function dispose() {\n    reset();\n    for (const geometryId in bindingStates) {\n      const programMap = bindingStates[geometryId];\n      for (const programId in programMap) {\n        const stateMap = programMap[programId];\n        for (const wireframe in stateMap) {\n          deleteVertexArrayObject(stateMap[wireframe].object);\n          delete stateMap[wireframe];\n        }\n        delete programMap[programId];\n      }\n      delete bindingStates[geometryId];\n    }\n  }\n  function releaseStatesOfGeometry(geometry) {\n    if (bindingStates[geometry.id] === undefined) return;\n    const programMap = bindingStates[geometry.id];\n    for (const programId in programMap) {\n      const stateMap = programMap[programId];\n      for (const wireframe in stateMap) {\n        deleteVertexArrayObject(stateMap[wireframe].object);\n        delete stateMap[wireframe];\n      }\n      delete programMap[programId];\n    }\n    delete bindingStates[geometry.id];\n  }\n  function releaseStatesOfProgram(program) {\n    for (const geometryId in bindingStates) {\n      const programMap = bindingStates[geometryId];\n      if (programMap[program.id] === undefined) continue;\n      const stateMap = programMap[program.id];\n      for (const wireframe in stateMap) {\n        deleteVertexArrayObject(stateMap[wireframe].object);\n        delete stateMap[wireframe];\n      }\n      delete programMap[program.id];\n    }\n  }\n  function reset() {\n    resetDefaultState();\n    if (currentState === defaultState) return;\n    currentState = defaultState;\n    bindVertexArrayObject(currentState.object);\n  }\n\n  // for backward-compatilibity\n\n  function resetDefaultState() {\n    defaultState.geometry = null;\n    defaultState.program = null;\n    defaultState.wireframe = false;\n  }\n  return {\n    setup: setup,\n    reset: reset,\n    resetDefaultState: resetDefaultState,\n    dispose: dispose,\n    releaseStatesOfGeometry: releaseStatesOfGeometry,\n    releaseStatesOfProgram: releaseStatesOfProgram,\n    initAttributes: initAttributes,\n    enableAttribute: enableAttribute,\n    disableUnusedAttributes: disableUnusedAttributes\n  };\n}\nfunction WebGLBufferRenderer(gl, extensions, info, capabilities) {\n  const isWebGL2 = capabilities.isWebGL2;\n  let mode;\n  function setMode(value) {\n    mode = value;\n  }\n  function render(start, count) {\n    gl.drawArrays(mode, start, count);\n    info.update(count, mode, 1);\n  }\n  function renderInstances(start, count, primcount) {\n    if (primcount === 0) return;\n    let extension, methodName;\n    if (isWebGL2) {\n      extension = gl;\n      methodName = 'drawArraysInstanced';\n    } else {\n      extension = extensions.get('ANGLE_instanced_arrays');\n      methodName = 'drawArraysInstancedANGLE';\n      if (extension === null) {\n        console.error('THREE.WebGLBufferRenderer: using THREE.InstancedBufferGeometry but hardware does not support extension ANGLE_instanced_arrays.');\n        return;\n      }\n    }\n    extension[methodName](mode, start, count, primcount);\n    info.update(count, mode, primcount);\n  }\n\n  //\n\n  this.setMode = setMode;\n  this.render = render;\n  this.renderInstances = renderInstances;\n}\nfunction WebGLCapabilities(gl, extensions, parameters) {\n  let maxAnisotropy;\n  function getMaxAnisotropy() {\n    if (maxAnisotropy !== undefined) return maxAnisotropy;\n    const extension = extensions.get('EXT_texture_filter_anisotropic');\n    if (extension !== null) {\n      maxAnisotropy = gl.getParameter(extension.MAX_TEXTURE_MAX_ANISOTROPY_EXT);\n    } else {\n      maxAnisotropy = 0;\n    }\n    return maxAnisotropy;\n  }\n  function getMaxPrecision(precision) {\n    if (precision === 'highp') {\n      if (gl.getShaderPrecisionFormat(35633, 36338).precision > 0 && gl.getShaderPrecisionFormat(35632, 36338).precision > 0) {\n        return 'highp';\n      }\n      precision = 'mediump';\n    }\n    if (precision === 'mediump') {\n      if (gl.getShaderPrecisionFormat(35633, 36337).precision > 0 && gl.getShaderPrecisionFormat(35632, 36337).precision > 0) {\n        return 'mediump';\n      }\n    }\n    return 'lowp';\n  }\n\n  /* eslint-disable no-undef */\n  const isWebGL2 = typeof WebGL2RenderingContext !== 'undefined' && gl instanceof WebGL2RenderingContext || typeof WebGL2ComputeRenderingContext !== 'undefined' && gl instanceof WebGL2ComputeRenderingContext;\n  /* eslint-enable no-undef */\n\n  let precision = parameters.precision !== undefined ? parameters.precision : 'highp';\n  const maxPrecision = getMaxPrecision(precision);\n  if (maxPrecision !== precision) {\n    console.warn('THREE.WebGLRenderer:', precision, 'not supported, using', maxPrecision, 'instead.');\n    precision = maxPrecision;\n  }\n  const logarithmicDepthBuffer = parameters.logarithmicDepthBuffer === true;\n  const maxTextures = gl.getParameter(34930);\n  const maxVertexTextures = gl.getParameter(35660);\n  const maxTextureSize = gl.getParameter(3379);\n  const maxCubemapSize = gl.getParameter(34076);\n  const maxAttributes = gl.getParameter(34921);\n  const maxVertexUniforms = gl.getParameter(36347);\n  const maxVaryings = gl.getParameter(36348);\n  const maxFragmentUniforms = gl.getParameter(36349);\n  const vertexTextures = maxVertexTextures > 0;\n  const floatFragmentTextures = isWebGL2 || !!extensions.get('OES_texture_float');\n  const floatVertexTextures = vertexTextures && floatFragmentTextures;\n  const maxSamples = isWebGL2 ? gl.getParameter(36183) : 0;\n  return {\n    isWebGL2: isWebGL2,\n    getMaxAnisotropy: getMaxAnisotropy,\n    getMaxPrecision: getMaxPrecision,\n    precision: precision,\n    logarithmicDepthBuffer: logarithmicDepthBuffer,\n    maxTextures: maxTextures,\n    maxVertexTextures: maxVertexTextures,\n    maxTextureSize: maxTextureSize,\n    maxCubemapSize: maxCubemapSize,\n    maxAttributes: maxAttributes,\n    maxVertexUniforms: maxVertexUniforms,\n    maxVaryings: maxVaryings,\n    maxFragmentUniforms: maxFragmentUniforms,\n    vertexTextures: vertexTextures,\n    floatFragmentTextures: floatFragmentTextures,\n    floatVertexTextures: floatVertexTextures,\n    maxSamples: maxSamples\n  };\n}\nfunction WebGLClipping(properties) {\n  const scope = this;\n  let globalState = null,\n    numGlobalPlanes = 0,\n    localClippingEnabled = false,\n    renderingShadows = false;\n  const plane = new Plane(),\n    viewNormalMatrix = new Matrix3(),\n    uniform = {\n      value: null,\n      needsUpdate: false\n    };\n  this.uniform = uniform;\n  this.numPlanes = 0;\n  this.numIntersection = 0;\n  this.init = function (planes, enableLocalClipping, camera) {\n    const enabled = planes.length !== 0 || enableLocalClipping ||\n    // enable state of previous frame - the clipping code has to\n    // run another frame in order to reset the state:\n    numGlobalPlanes !== 0 || localClippingEnabled;\n    localClippingEnabled = enableLocalClipping;\n    globalState = projectPlanes(planes, camera, 0);\n    numGlobalPlanes = planes.length;\n    return enabled;\n  };\n  this.beginShadows = function () {\n    renderingShadows = true;\n    projectPlanes(null);\n  };\n  this.endShadows = function () {\n    renderingShadows = false;\n    resetGlobalState();\n  };\n  this.setState = function (material, camera, useCache) {\n    const planes = material.clippingPlanes,\n      clipIntersection = material.clipIntersection,\n      clipShadows = material.clipShadows;\n    const materialProperties = properties.get(material);\n    if (!localClippingEnabled || planes === null || planes.length === 0 || renderingShadows && !clipShadows) {\n      // there's no local clipping\n\n      if (renderingShadows) {\n        // there's no global clipping\n\n        projectPlanes(null);\n      } else {\n        resetGlobalState();\n      }\n    } else {\n      const nGlobal = renderingShadows ? 0 : numGlobalPlanes,\n        lGlobal = nGlobal * 4;\n      let dstArray = materialProperties.clippingState || null;\n      uniform.value = dstArray; // ensure unique state\n\n      dstArray = projectPlanes(planes, camera, lGlobal, useCache);\n      for (let i = 0; i !== lGlobal; ++i) {\n        dstArray[i] = globalState[i];\n      }\n      materialProperties.clippingState = dstArray;\n      this.numIntersection = clipIntersection ? this.numPlanes : 0;\n      this.numPlanes += nGlobal;\n    }\n  };\n  function resetGlobalState() {\n    if (uniform.value !== globalState) {\n      uniform.value = globalState;\n      uniform.needsUpdate = numGlobalPlanes > 0;\n    }\n    scope.numPlanes = numGlobalPlanes;\n    scope.numIntersection = 0;\n  }\n  function projectPlanes(planes, camera, dstOffset, skipTransform) {\n    const nPlanes = planes !== null ? planes.length : 0;\n    let dstArray = null;\n    if (nPlanes !== 0) {\n      dstArray = uniform.value;\n      if (skipTransform !== true || dstArray === null) {\n        const flatSize = dstOffset + nPlanes * 4,\n          viewMatrix = camera.matrixWorldInverse;\n        viewNormalMatrix.getNormalMatrix(viewMatrix);\n        if (dstArray === null || dstArray.length < flatSize) {\n          dstArray = new Float32Array(flatSize);\n        }\n        for (let i = 0, i4 = dstOffset; i !== nPlanes; ++i, i4 += 4) {\n          plane.copy(planes[i]).applyMatrix4(viewMatrix, viewNormalMatrix);\n          plane.normal.toArray(dstArray, i4);\n          dstArray[i4 + 3] = plane.constant;\n        }\n      }\n      uniform.value = dstArray;\n      uniform.needsUpdate = true;\n    }\n    scope.numPlanes = nPlanes;\n    scope.numIntersection = 0;\n    return dstArray;\n  }\n}\nfunction WebGLCubeMaps(renderer) {\n  let cubemaps = new WeakMap();\n  function mapTextureMapping(texture, mapping) {\n    if (mapping === EquirectangularReflectionMapping) {\n      texture.mapping = CubeReflectionMapping;\n    } else if (mapping === EquirectangularRefractionMapping) {\n      texture.mapping = CubeRefractionMapping;\n    }\n    return texture;\n  }\n  function get(texture) {\n    if (texture && texture.isTexture) {\n      const mapping = texture.mapping;\n      if (mapping === EquirectangularReflectionMapping || mapping === EquirectangularRefractionMapping) {\n        if (cubemaps.has(texture)) {\n          const cubemap = cubemaps.get(texture).texture;\n          return mapTextureMapping(cubemap, texture.mapping);\n        } else {\n          const image = texture.image;\n          if (image && image.height > 0) {\n            const currentRenderList = renderer.getRenderList();\n            const currentRenderTarget = renderer.getRenderTarget();\n            const renderTarget = new WebGLCubeRenderTarget(image.height / 2);\n            renderTarget.fromEquirectangularTexture(renderer, texture);\n            cubemaps.set(texture, renderTarget);\n            renderer.setRenderTarget(currentRenderTarget);\n            renderer.setRenderList(currentRenderList);\n            texture.addEventListener('dispose', onTextureDispose);\n            return mapTextureMapping(renderTarget.texture, texture.mapping);\n          } else {\n            // image not yet ready. try the conversion next frame\n\n            return null;\n          }\n        }\n      }\n    }\n    return texture;\n  }\n  function onTextureDispose(event) {\n    const texture = event.target;\n    texture.removeEventListener('dispose', onTextureDispose);\n    const cubemap = cubemaps.get(texture);\n    if (cubemap !== undefined) {\n      cubemaps.delete(texture);\n      cubemap.dispose();\n    }\n  }\n  function dispose() {\n    cubemaps = new WeakMap();\n  }\n  return {\n    get: get,\n    dispose: dispose\n  };\n}\nfunction WebGLExtensions(gl) {\n  const extensions = {};\n  function getExtension(name) {\n    if (extensions[name] !== undefined) {\n      return extensions[name];\n    }\n    let extension;\n    switch (name) {\n      case 'WEBGL_depth_texture':\n        extension = gl.getExtension('WEBGL_depth_texture') || gl.getExtension('MOZ_WEBGL_depth_texture') || gl.getExtension('WEBKIT_WEBGL_depth_texture');\n        break;\n      case 'EXT_texture_filter_anisotropic':\n        extension = gl.getExtension('EXT_texture_filter_anisotropic') || gl.getExtension('MOZ_EXT_texture_filter_anisotropic') || gl.getExtension('WEBKIT_EXT_texture_filter_anisotropic');\n        break;\n      case 'WEBGL_compressed_texture_s3tc':\n        extension = gl.getExtension('WEBGL_compressed_texture_s3tc') || gl.getExtension('MOZ_WEBGL_compressed_texture_s3tc') || gl.getExtension('WEBKIT_WEBGL_compressed_texture_s3tc');\n        break;\n      case 'WEBGL_compressed_texture_pvrtc':\n        extension = gl.getExtension('WEBGL_compressed_texture_pvrtc') || gl.getExtension('WEBKIT_WEBGL_compressed_texture_pvrtc');\n        break;\n      default:\n        extension = gl.getExtension(name);\n    }\n    extensions[name] = extension;\n    return extension;\n  }\n  return {\n    has: function (name) {\n      return getExtension(name) !== null;\n    },\n    init: function (capabilities) {\n      if (capabilities.isWebGL2) {\n        getExtension('EXT_color_buffer_float');\n      } else {\n        getExtension('WEBGL_depth_texture');\n        getExtension('OES_texture_float');\n        getExtension('OES_texture_half_float');\n        getExtension('OES_texture_half_float_linear');\n        getExtension('OES_standard_derivatives');\n        getExtension('OES_element_index_uint');\n        getExtension('OES_vertex_array_object');\n        getExtension('ANGLE_instanced_arrays');\n      }\n      getExtension('OES_texture_float_linear');\n      getExtension('EXT_color_buffer_half_float');\n    },\n    get: function (name) {\n      const extension = getExtension(name);\n      if (extension === null) {\n        console.warn('THREE.WebGLRenderer: ' + name + ' extension not supported.');\n      }\n      return extension;\n    }\n  };\n}\nfunction WebGLGeometries(gl, attributes, info, bindingStates) {\n  const geometries = {};\n  const wireframeAttributes = new WeakMap();\n  function onGeometryDispose(event) {\n    const geometry = event.target;\n    if (geometry.index !== null) {\n      attributes.remove(geometry.index);\n    }\n    for (const name in geometry.attributes) {\n      attributes.remove(geometry.attributes[name]);\n    }\n    geometry.removeEventListener('dispose', onGeometryDispose);\n    delete geometries[geometry.id];\n    const attribute = wireframeAttributes.get(geometry);\n    if (attribute) {\n      attributes.remove(attribute);\n      wireframeAttributes.delete(geometry);\n    }\n    bindingStates.releaseStatesOfGeometry(geometry);\n    if (geometry.isInstancedBufferGeometry === true) {\n      delete geometry._maxInstanceCount;\n    }\n\n    //\n\n    info.memory.geometries--;\n  }\n  function get(object, geometry) {\n    if (geometries[geometry.id] === true) return geometry;\n    geometry.addEventListener('dispose', onGeometryDispose);\n    geometries[geometry.id] = true;\n    info.memory.geometries++;\n    return geometry;\n  }\n  function update(geometry) {\n    const geometryAttributes = geometry.attributes;\n\n    // Updating index buffer in VAO now. See WebGLBindingStates.\n\n    for (const name in geometryAttributes) {\n      attributes.update(geometryAttributes[name], 34962);\n    }\n\n    // morph targets\n\n    const morphAttributes = geometry.morphAttributes;\n    for (const name in morphAttributes) {\n      const array = morphAttributes[name];\n      for (let i = 0, l = array.length; i < l; i++) {\n        attributes.update(array[i], 34962);\n      }\n    }\n  }\n  function updateWireframeAttribute(geometry) {\n    const indices = [];\n    const geometryIndex = geometry.index;\n    const geometryPosition = geometry.attributes.position;\n    let version = 0;\n    if (geometryIndex !== null) {\n      const array = geometryIndex.array;\n      version = geometryIndex.version;\n      for (let i = 0, l = array.length; i < l; i += 3) {\n        const a = array[i + 0];\n        const b = array[i + 1];\n        const c = array[i + 2];\n        indices.push(a, b, b, c, c, a);\n      }\n    } else {\n      const array = geometryPosition.array;\n      version = geometryPosition.version;\n      for (let i = 0, l = array.length / 3 - 1; i < l; i += 3) {\n        const a = i + 0;\n        const b = i + 1;\n        const c = i + 2;\n        indices.push(a, b, b, c, c, a);\n      }\n    }\n    const attribute = new (arrayMax(indices) > 65535 ? Uint32BufferAttribute : Uint16BufferAttribute)(indices, 1);\n    attribute.version = version;\n\n    // Updating index buffer in VAO now. See WebGLBindingStates\n\n    //\n\n    const previousAttribute = wireframeAttributes.get(geometry);\n    if (previousAttribute) attributes.remove(previousAttribute);\n\n    //\n\n    wireframeAttributes.set(geometry, attribute);\n  }\n  function getWireframeAttribute(geometry) {\n    const currentAttribute = wireframeAttributes.get(geometry);\n    if (currentAttribute) {\n      const geometryIndex = geometry.index;\n      if (geometryIndex !== null) {\n        // if the attribute is obsolete, create a new one\n\n        if (currentAttribute.version < geometryIndex.version) {\n          updateWireframeAttribute(geometry);\n        }\n      }\n    } else {\n      updateWireframeAttribute(geometry);\n    }\n    return wireframeAttributes.get(geometry);\n  }\n  return {\n    get: get,\n    update: update,\n    getWireframeAttribute: getWireframeAttribute\n  };\n}\nfunction WebGLIndexedBufferRenderer(gl, extensions, info, capabilities) {\n  const isWebGL2 = capabilities.isWebGL2;\n  let mode;\n  function setMode(value) {\n    mode = value;\n  }\n  let type, bytesPerElement;\n  function setIndex(value) {\n    type = value.type;\n    bytesPerElement = value.bytesPerElement;\n  }\n  function render(start, count) {\n    gl.drawElements(mode, count, type, start * bytesPerElement);\n    info.update(count, mode, 1);\n  }\n  function renderInstances(start, count, primcount) {\n    if (primcount === 0) return;\n    let extension, methodName;\n    if (isWebGL2) {\n      extension = gl;\n      methodName = 'drawElementsInstanced';\n    } else {\n      extension = extensions.get('ANGLE_instanced_arrays');\n      methodName = 'drawElementsInstancedANGLE';\n      if (extension === null) {\n        console.error('THREE.WebGLIndexedBufferRenderer: using THREE.InstancedBufferGeometry but hardware does not support extension ANGLE_instanced_arrays.');\n        return;\n      }\n    }\n    extension[methodName](mode, count, type, start * bytesPerElement, primcount);\n    info.update(count, mode, primcount);\n  }\n\n  //\n\n  this.setMode = setMode;\n  this.setIndex = setIndex;\n  this.render = render;\n  this.renderInstances = renderInstances;\n}\nfunction WebGLInfo(gl) {\n  const memory = {\n    geometries: 0,\n    textures: 0\n  };\n  const render = {\n    frame: 0,\n    calls: 0,\n    triangles: 0,\n    points: 0,\n    lines: 0\n  };\n  function update(count, mode, instanceCount) {\n    render.calls++;\n    switch (mode) {\n      case 4:\n        render.triangles += instanceCount * (count / 3);\n        break;\n      case 1:\n        render.lines += instanceCount * (count / 2);\n        break;\n      case 3:\n        render.lines += instanceCount * (count - 1);\n        break;\n      case 2:\n        render.lines += instanceCount * count;\n        break;\n      case 0:\n        render.points += instanceCount * count;\n        break;\n      default:\n        console.error('THREE.WebGLInfo: Unknown draw mode:', mode);\n        break;\n    }\n  }\n  function reset() {\n    render.frame++;\n    render.calls = 0;\n    render.triangles = 0;\n    render.points = 0;\n    render.lines = 0;\n  }\n  return {\n    memory: memory,\n    render: render,\n    programs: null,\n    autoReset: true,\n    reset: reset,\n    update: update\n  };\n}\nfunction numericalSort(a, b) {\n  return a[0] - b[0];\n}\nfunction absNumericalSort(a, b) {\n  return Math.abs(b[1]) - Math.abs(a[1]);\n}\nfunction WebGLMorphtargets(gl) {\n  const influencesList = {};\n  const morphInfluences = new Float32Array(8);\n  const workInfluences = [];\n  for (let i = 0; i < 8; i++) {\n    workInfluences[i] = [i, 0];\n  }\n  function update(object, geometry, material, program) {\n    const objectInfluences = object.morphTargetInfluences;\n\n    // When object doesn't have morph target influences defined, we treat it as a 0-length array\n    // This is important to make sure we set up morphTargetBaseInfluence / morphTargetInfluences\n\n    const length = objectInfluences === undefined ? 0 : objectInfluences.length;\n    let influences = influencesList[geometry.id];\n    if (influences === undefined) {\n      // initialise list\n\n      influences = [];\n      for (let i = 0; i < length; i++) {\n        influences[i] = [i, 0];\n      }\n      influencesList[geometry.id] = influences;\n    }\n\n    // Collect influences\n\n    for (let i = 0; i < length; i++) {\n      const influence = influences[i];\n      influence[0] = i;\n      influence[1] = objectInfluences[i];\n    }\n    influences.sort(absNumericalSort);\n    for (let i = 0; i < 8; i++) {\n      if (i < length && influences[i][1]) {\n        workInfluences[i][0] = influences[i][0];\n        workInfluences[i][1] = influences[i][1];\n      } else {\n        workInfluences[i][0] = Number.MAX_SAFE_INTEGER;\n        workInfluences[i][1] = 0;\n      }\n    }\n    workInfluences.sort(numericalSort);\n    const morphTargets = material.morphTargets && geometry.morphAttributes.position;\n    const morphNormals = material.morphNormals && geometry.morphAttributes.normal;\n    let morphInfluencesSum = 0;\n    for (let i = 0; i < 8; i++) {\n      const influence = workInfluences[i];\n      const index = influence[0];\n      const value = influence[1];\n      if (index !== Number.MAX_SAFE_INTEGER && value) {\n        if (morphTargets && geometry.getAttribute('morphTarget' + i) !== morphTargets[index]) {\n          geometry.setAttribute('morphTarget' + i, morphTargets[index]);\n        }\n        if (morphNormals && geometry.getAttribute('morphNormal' + i) !== morphNormals[index]) {\n          geometry.setAttribute('morphNormal' + i, morphNormals[index]);\n        }\n        morphInfluences[i] = value;\n        morphInfluencesSum += value;\n      } else {\n        if (morphTargets && geometry.hasAttribute('morphTarget' + i) === true) {\n          geometry.deleteAttribute('morphTarget' + i);\n        }\n        if (morphNormals && geometry.hasAttribute('morphNormal' + i) === true) {\n          geometry.deleteAttribute('morphNormal' + i);\n        }\n        morphInfluences[i] = 0;\n      }\n    }\n\n    // GLSL shader uses formula baseinfluence * base + sum(target * influence)\n    // This allows us to switch between absolute morphs and relative morphs without changing shader code\n    // When baseinfluence = 1 - sum(influence), the above is equivalent to sum((target - base) * influence)\n    const morphBaseInfluence = geometry.morphTargetsRelative ? 1 : 1 - morphInfluencesSum;\n    program.getUniforms().setValue(gl, 'morphTargetBaseInfluence', morphBaseInfluence);\n    program.getUniforms().setValue(gl, 'morphTargetInfluences', morphInfluences);\n  }\n  return {\n    update: update\n  };\n}\nfunction WebGLObjects(gl, geometries, attributes, info) {\n  let updateMap = new WeakMap();\n  function update(object) {\n    const frame = info.render.frame;\n    const geometry = object.geometry;\n    const buffergeometry = geometries.get(object, geometry);\n\n    // Update once per frame\n\n    if (updateMap.get(buffergeometry) !== frame) {\n      geometries.update(buffergeometry);\n      updateMap.set(buffergeometry, frame);\n    }\n    if (object.isInstancedMesh) {\n      if (object.hasEventListener('dispose', onInstancedMeshDispose) === false) {\n        object.addEventListener('dispose', onInstancedMeshDispose);\n      }\n      attributes.update(object.instanceMatrix, 34962);\n      if (object.instanceColor !== null) {\n        attributes.update(object.instanceColor, 34962);\n      }\n    }\n    return buffergeometry;\n  }\n  function dispose() {\n    updateMap = new WeakMap();\n  }\n  function onInstancedMeshDispose(event) {\n    const instancedMesh = event.target;\n    instancedMesh.removeEventListener('dispose', onInstancedMeshDispose);\n    attributes.remove(instancedMesh.instanceMatrix);\n    if (instancedMesh.instanceColor !== null) attributes.remove(instancedMesh.instanceColor);\n  }\n  return {\n    update: update,\n    dispose: dispose\n  };\n}\nfunction DataTexture2DArray(data = null, width = 1, height = 1, depth = 1) {\n  Texture.call(this, null);\n  this.image = {\n    data,\n    width,\n    height,\n    depth\n  };\n  this.magFilter = NearestFilter;\n  this.minFilter = NearestFilter;\n  this.wrapR = ClampToEdgeWrapping;\n  this.generateMipmaps = false;\n  this.flipY = false;\n  this.needsUpdate = true;\n}\nDataTexture2DArray.prototype = Object.create(Texture.prototype);\nDataTexture2DArray.prototype.constructor = DataTexture2DArray;\nDataTexture2DArray.prototype.isDataTexture2DArray = true;\nfunction DataTexture3D(data = null, width = 1, height = 1, depth = 1) {\n  // We're going to add .setXXX() methods for setting properties later.\n  // Users can still set in DataTexture3D directly.\n  //\n  //\tconst texture = new THREE.DataTexture3D( data, width, height, depth );\n  // \ttexture.anisotropy = 16;\n  //\n  // See #14839\n\n  Texture.call(this, null);\n  this.image = {\n    data,\n    width,\n    height,\n    depth\n  };\n  this.magFilter = NearestFilter;\n  this.minFilter = NearestFilter;\n  this.wrapR = ClampToEdgeWrapping;\n  this.generateMipmaps = false;\n  this.flipY = false;\n  this.needsUpdate = true;\n}\nDataTexture3D.prototype = Object.create(Texture.prototype);\nDataTexture3D.prototype.constructor = DataTexture3D;\nDataTexture3D.prototype.isDataTexture3D = true;\n\n/**\n * Uniforms of a program.\n * Those form a tree structure with a special top-level container for the root,\n * which you get by calling 'new WebGLUniforms( gl, program )'.\n *\n *\n * Properties of inner nodes including the top-level container:\n *\n * .seq - array of nested uniforms\n * .map - nested uniforms by name\n *\n *\n * Methods of all nodes except the top-level container:\n *\n * .setValue( gl, value, [textures] )\n *\n * \t\tuploads a uniform value(s)\n *  \tthe 'textures' parameter is needed for sampler uniforms\n *\n *\n * Static methods of the top-level container (textures factorizations):\n *\n * .upload( gl, seq, values, textures )\n *\n * \t\tsets uniforms in 'seq' to 'values[id].value'\n *\n * .seqWithValue( seq, values ) : filteredSeq\n *\n * \t\tfilters 'seq' entries with corresponding entry in values\n *\n *\n * Methods of the top-level container (textures factorizations):\n *\n * .setValue( gl, name, value, textures )\n *\n * \t\tsets uniform with  name 'name' to 'value'\n *\n * .setOptional( gl, obj, prop )\n *\n * \t\tlike .set for an optional property of the object\n *\n */\n\nconst emptyTexture = new Texture();\nconst emptyTexture2dArray = new DataTexture2DArray();\nconst emptyTexture3d = new DataTexture3D();\nconst emptyCubeTexture = new CubeTexture();\n\n// --- Utilities ---\n\n// Array Caches (provide typed arrays for temporary by size)\n\nconst arrayCacheF32 = [];\nconst arrayCacheI32 = [];\n\n// Float32Array caches used for uploading Matrix uniforms\n\nconst mat4array = new Float32Array(16);\nconst mat3array = new Float32Array(9);\nconst mat2array = new Float32Array(4);\n\n// Flattening for arrays of vectors and matrices\n\nfunction flatten(array, nBlocks, blockSize) {\n  const firstElem = array[0];\n  if (firstElem <= 0 || firstElem > 0) return array;\n  // unoptimized: ! isNaN( firstElem )\n  // see http://jacksondunstan.com/articles/983\n\n  const n = nBlocks * blockSize;\n  let r = arrayCacheF32[n];\n  if (r === undefined) {\n    r = new Float32Array(n);\n    arrayCacheF32[n] = r;\n  }\n  if (nBlocks !== 0) {\n    firstElem.toArray(r, 0);\n    for (let i = 1, offset = 0; i !== nBlocks; ++i) {\n      offset += blockSize;\n      array[i].toArray(r, offset);\n    }\n  }\n  return r;\n}\nfunction arraysEqual(a, b) {\n  if (a.length !== b.length) return false;\n  for (let i = 0, l = a.length; i < l; i++) {\n    if (a[i] !== b[i]) return false;\n  }\n  return true;\n}\nfunction copyArray(a, b) {\n  for (let i = 0, l = b.length; i < l; i++) {\n    a[i] = b[i];\n  }\n}\n\n// Texture unit allocation\n\nfunction allocTexUnits(textures, n) {\n  let r = arrayCacheI32[n];\n  if (r === undefined) {\n    r = new Int32Array(n);\n    arrayCacheI32[n] = r;\n  }\n  for (let i = 0; i !== n; ++i) {\n    r[i] = textures.allocateTextureUnit();\n  }\n  return r;\n}\n\n// --- Setters ---\n\n// Note: Defining these methods externally, because they come in a bunch\n// and this way their names minify.\n\n// Single scalar\n\nfunction setValueV1f(gl, v) {\n  const cache = this.cache;\n  if (cache[0] === v) return;\n  gl.uniform1f(this.addr, v);\n  cache[0] = v;\n}\n\n// Single float vector (from flat array or THREE.VectorN)\n\nfunction setValueV2f(gl, v) {\n  const cache = this.cache;\n  if (v.x !== undefined) {\n    if (cache[0] !== v.x || cache[1] !== v.y) {\n      gl.uniform2f(this.addr, v.x, v.y);\n      cache[0] = v.x;\n      cache[1] = v.y;\n    }\n  } else {\n    if (arraysEqual(cache, v)) return;\n    gl.uniform2fv(this.addr, v);\n    copyArray(cache, v);\n  }\n}\nfunction setValueV3f(gl, v) {\n  const cache = this.cache;\n  if (v.x !== undefined) {\n    if (cache[0] !== v.x || cache[1] !== v.y || cache[2] !== v.z) {\n      gl.uniform3f(this.addr, v.x, v.y, v.z);\n      cache[0] = v.x;\n      cache[1] = v.y;\n      cache[2] = v.z;\n    }\n  } else if (v.r !== undefined) {\n    if (cache[0] !== v.r || cache[1] !== v.g || cache[2] !== v.b) {\n      gl.uniform3f(this.addr, v.r, v.g, v.b);\n      cache[0] = v.r;\n      cache[1] = v.g;\n      cache[2] = v.b;\n    }\n  } else {\n    if (arraysEqual(cache, v)) return;\n    gl.uniform3fv(this.addr, v);\n    copyArray(cache, v);\n  }\n}\nfunction setValueV4f(gl, v) {\n  const cache = this.cache;\n  if (v.x !== undefined) {\n    if (cache[0] !== v.x || cache[1] !== v.y || cache[2] !== v.z || cache[3] !== v.w) {\n      gl.uniform4f(this.addr, v.x, v.y, v.z, v.w);\n      cache[0] = v.x;\n      cache[1] = v.y;\n      cache[2] = v.z;\n      cache[3] = v.w;\n    }\n  } else {\n    if (arraysEqual(cache, v)) return;\n    gl.uniform4fv(this.addr, v);\n    copyArray(cache, v);\n  }\n}\n\n// Single matrix (from flat array or MatrixN)\n\nfunction setValueM2(gl, v) {\n  const cache = this.cache;\n  const elements = v.elements;\n  if (elements === undefined) {\n    if (arraysEqual(cache, v)) return;\n    gl.uniformMatrix2fv(this.addr, false, v);\n    copyArray(cache, v);\n  } else {\n    if (arraysEqual(cache, elements)) return;\n    mat2array.set(elements);\n    gl.uniformMatrix2fv(this.addr, false, mat2array);\n    copyArray(cache, elements);\n  }\n}\nfunction setValueM3(gl, v) {\n  const cache = this.cache;\n  const elements = v.elements;\n  if (elements === undefined) {\n    if (arraysEqual(cache, v)) return;\n    gl.uniformMatrix3fv(this.addr, false, v);\n    copyArray(cache, v);\n  } else {\n    if (arraysEqual(cache, elements)) return;\n    mat3array.set(elements);\n    gl.uniformMatrix3fv(this.addr, false, mat3array);\n    copyArray(cache, elements);\n  }\n}\nfunction setValueM4(gl, v) {\n  const cache = this.cache;\n  const elements = v.elements;\n  if (elements === undefined) {\n    if (arraysEqual(cache, v)) return;\n    gl.uniformMatrix4fv(this.addr, false, v);\n    copyArray(cache, v);\n  } else {\n    if (arraysEqual(cache, elements)) return;\n    mat4array.set(elements);\n    gl.uniformMatrix4fv(this.addr, false, mat4array);\n    copyArray(cache, elements);\n  }\n}\n\n// Single texture (2D / Cube)\n\nfunction setValueT1(gl, v, textures) {\n  const cache = this.cache;\n  const unit = textures.allocateTextureUnit();\n  if (cache[0] !== unit) {\n    gl.uniform1i(this.addr, unit);\n    cache[0] = unit;\n  }\n  textures.safeSetTexture2D(v || emptyTexture, unit);\n}\nfunction setValueT2DArray1(gl, v, textures) {\n  const cache = this.cache;\n  const unit = textures.allocateTextureUnit();\n  if (cache[0] !== unit) {\n    gl.uniform1i(this.addr, unit);\n    cache[0] = unit;\n  }\n  textures.setTexture2DArray(v || emptyTexture2dArray, unit);\n}\nfunction setValueT3D1(gl, v, textures) {\n  const cache = this.cache;\n  const unit = textures.allocateTextureUnit();\n  if (cache[0] !== unit) {\n    gl.uniform1i(this.addr, unit);\n    cache[0] = unit;\n  }\n  textures.setTexture3D(v || emptyTexture3d, unit);\n}\nfunction setValueT6(gl, v, textures) {\n  const cache = this.cache;\n  const unit = textures.allocateTextureUnit();\n  if (cache[0] !== unit) {\n    gl.uniform1i(this.addr, unit);\n    cache[0] = unit;\n  }\n  textures.safeSetTextureCube(v || emptyCubeTexture, unit);\n}\n\n// Integer / Boolean vectors or arrays thereof (always flat arrays)\n\nfunction setValueV1i(gl, v) {\n  const cache = this.cache;\n  if (cache[0] === v) return;\n  gl.uniform1i(this.addr, v);\n  cache[0] = v;\n}\nfunction setValueV2i(gl, v) {\n  const cache = this.cache;\n  if (arraysEqual(cache, v)) return;\n  gl.uniform2iv(this.addr, v);\n  copyArray(cache, v);\n}\nfunction setValueV3i(gl, v) {\n  const cache = this.cache;\n  if (arraysEqual(cache, v)) return;\n  gl.uniform3iv(this.addr, v);\n  copyArray(cache, v);\n}\nfunction setValueV4i(gl, v) {\n  const cache = this.cache;\n  if (arraysEqual(cache, v)) return;\n  gl.uniform4iv(this.addr, v);\n  copyArray(cache, v);\n}\n\n// uint\n\nfunction setValueV1ui(gl, v) {\n  const cache = this.cache;\n  if (cache[0] === v) return;\n  gl.uniform1ui(this.addr, v);\n  cache[0] = v;\n}\n\n// Helper to pick the right setter for the singular case\n\nfunction getSingularSetter(type) {\n  switch (type) {\n    case 0x1406:\n      return setValueV1f;\n    // FLOAT\n    case 0x8b50:\n      return setValueV2f;\n    // _VEC2\n    case 0x8b51:\n      return setValueV3f;\n    // _VEC3\n    case 0x8b52:\n      return setValueV4f;\n    // _VEC4\n\n    case 0x8b5a:\n      return setValueM2;\n    // _MAT2\n    case 0x8b5b:\n      return setValueM3;\n    // _MAT3\n    case 0x8b5c:\n      return setValueM4;\n    // _MAT4\n\n    case 0x1404:\n    case 0x8b56:\n      return setValueV1i;\n    // INT, BOOL\n    case 0x8b53:\n    case 0x8b57:\n      return setValueV2i;\n    // _VEC2\n    case 0x8b54:\n    case 0x8b58:\n      return setValueV3i;\n    // _VEC3\n    case 0x8b55:\n    case 0x8b59:\n      return setValueV4i;\n    // _VEC4\n\n    case 0x1405:\n      return setValueV1ui;\n    // UINT\n\n    case 0x8b5e: // SAMPLER_2D\n    case 0x8d66: // SAMPLER_EXTERNAL_OES\n    case 0x8dca: // INT_SAMPLER_2D\n    case 0x8dd2: // UNSIGNED_INT_SAMPLER_2D\n    case 0x8b62:\n      // SAMPLER_2D_SHADOW\n      return setValueT1;\n    case 0x8b5f: // SAMPLER_3D\n    case 0x8dcb: // INT_SAMPLER_3D\n    case 0x8dd3:\n      // UNSIGNED_INT_SAMPLER_3D\n      return setValueT3D1;\n    case 0x8b60: // SAMPLER_CUBE\n    case 0x8dcc: // INT_SAMPLER_CUBE\n    case 0x8dd4: // UNSIGNED_INT_SAMPLER_CUBE\n    case 0x8dc5:\n      // SAMPLER_CUBE_SHADOW\n      return setValueT6;\n    case 0x8dc1: // SAMPLER_2D_ARRAY\n    case 0x8dcf: // INT_SAMPLER_2D_ARRAY\n    case 0x8dd7: // UNSIGNED_INT_SAMPLER_2D_ARRAY\n    case 0x8dc4:\n      // SAMPLER_2D_ARRAY_SHADOW\n      return setValueT2DArray1;\n  }\n}\n\n// Array of scalars\nfunction setValueV1fArray(gl, v) {\n  gl.uniform1fv(this.addr, v);\n}\n\n// Integer / Boolean vectors or arrays thereof (always flat arrays)\nfunction setValueV1iArray(gl, v) {\n  gl.uniform1iv(this.addr, v);\n}\nfunction setValueV2iArray(gl, v) {\n  gl.uniform2iv(this.addr, v);\n}\nfunction setValueV3iArray(gl, v) {\n  gl.uniform3iv(this.addr, v);\n}\nfunction setValueV4iArray(gl, v) {\n  gl.uniform4iv(this.addr, v);\n}\n\n// Array of vectors (flat or from THREE classes)\n\nfunction setValueV2fArray(gl, v) {\n  const data = flatten(v, this.size, 2);\n  gl.uniform2fv(this.addr, data);\n}\nfunction setValueV3fArray(gl, v) {\n  const data = flatten(v, this.size, 3);\n  gl.uniform3fv(this.addr, data);\n}\nfunction setValueV4fArray(gl, v) {\n  const data = flatten(v, this.size, 4);\n  gl.uniform4fv(this.addr, data);\n}\n\n// Array of matrices (flat or from THREE clases)\n\nfunction setValueM2Array(gl, v) {\n  const data = flatten(v, this.size, 4);\n  gl.uniformMatrix2fv(this.addr, false, data);\n}\nfunction setValueM3Array(gl, v) {\n  const data = flatten(v, this.size, 9);\n  gl.uniformMatrix3fv(this.addr, false, data);\n}\nfunction setValueM4Array(gl, v) {\n  const data = flatten(v, this.size, 16);\n  gl.uniformMatrix4fv(this.addr, false, data);\n}\n\n// Array of textures (2D / Cube)\n\nfunction setValueT1Array(gl, v, textures) {\n  const n = v.length;\n  const units = allocTexUnits(textures, n);\n  gl.uniform1iv(this.addr, units);\n  for (let i = 0; i !== n; ++i) {\n    textures.safeSetTexture2D(v[i] || emptyTexture, units[i]);\n  }\n}\nfunction setValueT6Array(gl, v, textures) {\n  const n = v.length;\n  const units = allocTexUnits(textures, n);\n  gl.uniform1iv(this.addr, units);\n  for (let i = 0; i !== n; ++i) {\n    textures.safeSetTextureCube(v[i] || emptyCubeTexture, units[i]);\n  }\n}\n\n// Helper to pick the right setter for a pure (bottom-level) array\n\nfunction getPureArraySetter(type) {\n  switch (type) {\n    case 0x1406:\n      return setValueV1fArray;\n    // FLOAT\n    case 0x8b50:\n      return setValueV2fArray;\n    // _VEC2\n    case 0x8b51:\n      return setValueV3fArray;\n    // _VEC3\n    case 0x8b52:\n      return setValueV4fArray;\n    // _VEC4\n\n    case 0x8b5a:\n      return setValueM2Array;\n    // _MAT2\n    case 0x8b5b:\n      return setValueM3Array;\n    // _MAT3\n    case 0x8b5c:\n      return setValueM4Array;\n    // _MAT4\n\n    case 0x1404:\n    case 0x8b56:\n      return setValueV1iArray;\n    // INT, BOOL\n    case 0x8b53:\n    case 0x8b57:\n      return setValueV2iArray;\n    // _VEC2\n    case 0x8b54:\n    case 0x8b58:\n      return setValueV3iArray;\n    // _VEC3\n    case 0x8b55:\n    case 0x8b59:\n      return setValueV4iArray;\n    // _VEC4\n\n    case 0x8b5e: // SAMPLER_2D\n    case 0x8d66: // SAMPLER_EXTERNAL_OES\n    case 0x8dca: // INT_SAMPLER_2D\n    case 0x8dd2: // UNSIGNED_INT_SAMPLER_2D\n    case 0x8b62:\n      // SAMPLER_2D_SHADOW\n      return setValueT1Array;\n    case 0x8b60: // SAMPLER_CUBE\n    case 0x8dcc: // INT_SAMPLER_CUBE\n    case 0x8dd4: // UNSIGNED_INT_SAMPLER_CUBE\n    case 0x8dc5:\n      // SAMPLER_CUBE_SHADOW\n      return setValueT6Array;\n  }\n}\n\n// --- Uniform Classes ---\n\nfunction SingleUniform(id, activeInfo, addr) {\n  this.id = id;\n  this.addr = addr;\n  this.cache = [];\n  this.setValue = getSingularSetter(activeInfo.type);\n\n  // this.path = activeInfo.name; // DEBUG\n}\n\nfunction PureArrayUniform(id, activeInfo, addr) {\n  this.id = id;\n  this.addr = addr;\n  this.cache = [];\n  this.size = activeInfo.size;\n  this.setValue = getPureArraySetter(activeInfo.type);\n\n  // this.path = activeInfo.name; // DEBUG\n}\n\nPureArrayUniform.prototype.updateCache = function (data) {\n  const cache = this.cache;\n  if (data instanceof Float32Array && cache.length !== data.length) {\n    this.cache = new Float32Array(data.length);\n  }\n  copyArray(cache, data);\n};\nfunction StructuredUniform(id) {\n  this.id = id;\n  this.seq = [];\n  this.map = {};\n}\nStructuredUniform.prototype.setValue = function (gl, value, textures) {\n  const seq = this.seq;\n  for (let i = 0, n = seq.length; i !== n; ++i) {\n    const u = seq[i];\n    u.setValue(gl, value[u.id], textures);\n  }\n};\n\n// --- Top-level ---\n\n// Parser - builds up the property tree from the path strings\n\nconst RePathPart = /(\\w+)(\\])?(\\[|\\.)?/g;\n\n// extracts\n// \t- the identifier (member name or array index)\n//  - followed by an optional right bracket (found when array index)\n//  - followed by an optional left bracket or dot (type of subscript)\n//\n// Note: These portions can be read in a non-overlapping fashion and\n// allow straightforward parsing of the hierarchy that WebGL encodes\n// in the uniform names.\n\nfunction addUniform(container, uniformObject) {\n  container.seq.push(uniformObject);\n  container.map[uniformObject.id] = uniformObject;\n}\nfunction parseUniform(activeInfo, addr, container) {\n  const path = activeInfo.name,\n    pathLength = path.length;\n\n  // reset RegExp object, because of the early exit of a previous run\n  RePathPart.lastIndex = 0;\n  while (true) {\n    const match = RePathPart.exec(path),\n      matchEnd = RePathPart.lastIndex;\n    let id = match[1];\n    const idIsIndex = match[2] === ']',\n      subscript = match[3];\n    if (idIsIndex) id = id | 0; // convert to integer\n\n    if (subscript === undefined || subscript === '[' && matchEnd + 2 === pathLength) {\n      // bare name or \"pure\" bottom-level array \"[0]\" suffix\n\n      addUniform(container, subscript === undefined ? new SingleUniform(id, activeInfo, addr) : new PureArrayUniform(id, activeInfo, addr));\n      break;\n    } else {\n      // step into inner node / create it in case it doesn't exist\n\n      const map = container.map;\n      let next = map[id];\n      if (next === undefined) {\n        next = new StructuredUniform(id);\n        addUniform(container, next);\n      }\n      container = next;\n    }\n  }\n}\n\n// Root Container\n\nfunction WebGLUniforms(gl, program) {\n  this.seq = [];\n  this.map = {};\n  const n = gl.getProgramParameter(program, 35718);\n  for (let i = 0; i < n; ++i) {\n    const info = gl.getActiveUniform(program, i),\n      addr = gl.getUniformLocation(program, info.name);\n    parseUniform(info, addr, this);\n  }\n}\nWebGLUniforms.prototype.setValue = function (gl, name, value, textures) {\n  const u = this.map[name];\n  if (u !== undefined) u.setValue(gl, value, textures);\n};\nWebGLUniforms.prototype.setOptional = function (gl, object, name) {\n  const v = object[name];\n  if (v !== undefined) this.setValue(gl, name, v);\n};\n\n// Static interface\n\nWebGLUniforms.upload = function (gl, seq, values, textures) {\n  for (let i = 0, n = seq.length; i !== n; ++i) {\n    const u = seq[i],\n      v = values[u.id];\n    if (v.needsUpdate !== false) {\n      // note: always updating when .needsUpdate is undefined\n      u.setValue(gl, v.value, textures);\n    }\n  }\n};\nWebGLUniforms.seqWithValue = function (seq, values) {\n  const r = [];\n  for (let i = 0, n = seq.length; i !== n; ++i) {\n    const u = seq[i];\n    if (u.id in values) r.push(u);\n  }\n  return r;\n};\nfunction WebGLShader(gl, type, string) {\n  const shader = gl.createShader(type);\n  gl.shaderSource(shader, string);\n  gl.compileShader(shader);\n  return shader;\n}\nlet programIdCount = 0;\nfunction addLineNumbers(string) {\n  const lines = string.split('\\n');\n  for (let i = 0; i < lines.length; i++) {\n    lines[i] = i + 1 + ': ' + lines[i];\n  }\n  return lines.join('\\n');\n}\nfunction getEncodingComponents(encoding) {\n  switch (encoding) {\n    case LinearEncoding:\n      return ['Linear', '( value )'];\n    case sRGBEncoding:\n      return ['sRGB', '( value )'];\n    case RGBEEncoding:\n      return ['RGBE', '( value )'];\n    case RGBM7Encoding:\n      return ['RGBM', '( value, 7.0 )'];\n    case RGBM16Encoding:\n      return ['RGBM', '( value, 16.0 )'];\n    case RGBDEncoding:\n      return ['RGBD', '( value, 256.0 )'];\n    case GammaEncoding:\n      return ['Gamma', '( value, float( GAMMA_FACTOR ) )'];\n    case LogLuvEncoding:\n      return ['LogLuv', '( value )'];\n    default:\n      console.warn('THREE.WebGLProgram: Unsupported encoding:', encoding);\n      return ['Linear', '( value )'];\n  }\n}\nfunction getShaderErrors(gl, shader, type) {\n  const status = gl.getShaderParameter(shader, 35713);\n  const log = gl.getShaderInfoLog(shader).trim();\n  if (status && log === '') return '';\n\n  // --enable-privileged-webgl-extension\n  // console.log( '**' + type + '**', gl.getExtension( 'WEBGL_debug_shaders' ).getTranslatedShaderSource( shader ) );\n\n  const source = gl.getShaderSource(shader);\n  return 'THREE.WebGLShader: gl.getShaderInfoLog() ' + type + '\\n' + log + addLineNumbers(source);\n}\nfunction getTexelDecodingFunction(functionName, encoding) {\n  const components = getEncodingComponents(encoding);\n  return 'vec4 ' + functionName + '( vec4 value ) { return ' + components[0] + 'ToLinear' + components[1] + '; }';\n}\nfunction getTexelEncodingFunction(functionName, encoding) {\n  const components = getEncodingComponents(encoding);\n  return 'vec4 ' + functionName + '( vec4 value ) { return LinearTo' + components[0] + components[1] + '; }';\n}\nfunction getToneMappingFunction(functionName, toneMapping) {\n  let toneMappingName;\n  switch (toneMapping) {\n    case LinearToneMapping:\n      toneMappingName = 'Linear';\n      break;\n    case ReinhardToneMapping:\n      toneMappingName = 'Reinhard';\n      break;\n    case CineonToneMapping:\n      toneMappingName = 'OptimizedCineon';\n      break;\n    case ACESFilmicToneMapping:\n      toneMappingName = 'ACESFilmic';\n      break;\n    case CustomToneMapping:\n      toneMappingName = 'Custom';\n      break;\n    default:\n      console.warn('THREE.WebGLProgram: Unsupported toneMapping:', toneMapping);\n      toneMappingName = 'Linear';\n  }\n  return 'vec3 ' + functionName + '( vec3 color ) { return ' + toneMappingName + 'ToneMapping( color ); }';\n}\nfunction generateExtensions(parameters) {\n  const chunks = [parameters.extensionDerivatives || parameters.envMapCubeUV || parameters.bumpMap || parameters.tangentSpaceNormalMap || parameters.clearcoatNormalMap || parameters.flatShading || parameters.shaderID === 'physical' ? '#extension GL_OES_standard_derivatives : enable' : '', (parameters.extensionFragDepth || parameters.logarithmicDepthBuffer) && parameters.rendererExtensionFragDepth ? '#extension GL_EXT_frag_depth : enable' : '', parameters.extensionDrawBuffers && parameters.rendererExtensionDrawBuffers ? '#extension GL_EXT_draw_buffers : require' : '', (parameters.extensionShaderTextureLOD || parameters.envMap) && parameters.rendererExtensionShaderTextureLod ? '#extension GL_EXT_shader_texture_lod : enable' : ''];\n  return chunks.filter(filterEmptyLine).join('\\n');\n}\nfunction generateDefines(defines) {\n  const chunks = [];\n  for (const name in defines) {\n    const value = defines[name];\n    if (value === false) continue;\n    chunks.push('#define ' + name + ' ' + value);\n  }\n  return chunks.join('\\n');\n}\nfunction fetchAttributeLocations(gl, program) {\n  const attributes = {};\n  const n = gl.getProgramParameter(program, 35721);\n  for (let i = 0; i < n; i++) {\n    const info = gl.getActiveAttrib(program, i);\n    const name = info.name;\n\n    // console.log( 'THREE.WebGLProgram: ACTIVE VERTEX ATTRIBUTE:', name, i );\n\n    attributes[name] = gl.getAttribLocation(program, name);\n  }\n  return attributes;\n}\nfunction filterEmptyLine(string) {\n  return string !== '';\n}\nfunction replaceLightNums(string, parameters) {\n  return string.replace(/NUM_DIR_LIGHTS/g, parameters.numDirLights).replace(/NUM_SPOT_LIGHTS/g, parameters.numSpotLights).replace(/NUM_RECT_AREA_LIGHTS/g, parameters.numRectAreaLights).replace(/NUM_POINT_LIGHTS/g, parameters.numPointLights).replace(/NUM_HEMI_LIGHTS/g, parameters.numHemiLights).replace(/NUM_DIR_LIGHT_SHADOWS/g, parameters.numDirLightShadows).replace(/NUM_SPOT_LIGHT_SHADOWS/g, parameters.numSpotLightShadows).replace(/NUM_POINT_LIGHT_SHADOWS/g, parameters.numPointLightShadows);\n}\nfunction replaceClippingPlaneNums(string, parameters) {\n  return string.replace(/NUM_CLIPPING_PLANES/g, parameters.numClippingPlanes).replace(/UNION_CLIPPING_PLANES/g, parameters.numClippingPlanes - parameters.numClipIntersection);\n}\n\n// Resolve Includes\n\nconst includePattern = /^[ \\t]*#include +<([\\w\\d./]+)>/gm;\nfunction resolveIncludes(string) {\n  return string.replace(includePattern, includeReplacer);\n}\nfunction includeReplacer(match, include) {\n  const string = ShaderChunk[include];\n  if (string === undefined) {\n    throw new Error('Can not resolve #include <' + include + '>');\n  }\n  return resolveIncludes(string);\n}\n\n// Unroll Loops\n\nconst deprecatedUnrollLoopPattern = /#pragma unroll_loop[\\s]+?for \\( int i \\= (\\d+)\\; i < (\\d+)\\; i \\+\\+ \\) \\{([\\s\\S]+?)(?=\\})\\}/g;\nconst unrollLoopPattern = /#pragma unroll_loop_start\\s+for\\s*\\(\\s*int\\s+i\\s*=\\s*(\\d+)\\s*;\\s*i\\s*<\\s*(\\d+)\\s*;\\s*i\\s*\\+\\+\\s*\\)\\s*{([\\s\\S]+?)}\\s+#pragma unroll_loop_end/g;\nfunction unrollLoops(string) {\n  return string.replace(unrollLoopPattern, loopReplacer).replace(deprecatedUnrollLoopPattern, deprecatedLoopReplacer);\n}\nfunction deprecatedLoopReplacer(match, start, end, snippet) {\n  console.warn('WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead.');\n  return loopReplacer(match, start, end, snippet);\n}\nfunction loopReplacer(match, start, end, snippet) {\n  let string = '';\n  for (let i = parseInt(start); i < parseInt(end); i++) {\n    string += snippet.replace(/\\[\\s*i\\s*\\]/g, '[ ' + i + ' ]').replace(/UNROLLED_LOOP_INDEX/g, i);\n  }\n  return string;\n}\n\n//\n\nfunction generatePrecision(parameters) {\n  let precisionstring = 'precision ' + parameters.precision + ' float;\\nprecision ' + parameters.precision + ' int;';\n  if (parameters.precision === 'highp') {\n    precisionstring += '\\n#define HIGH_PRECISION';\n  } else if (parameters.precision === 'mediump') {\n    precisionstring += '\\n#define MEDIUM_PRECISION';\n  } else if (parameters.precision === 'lowp') {\n    precisionstring += '\\n#define LOW_PRECISION';\n  }\n  return precisionstring;\n}\nfunction generateShadowMapTypeDefine(parameters) {\n  let shadowMapTypeDefine = 'SHADOWMAP_TYPE_BASIC';\n  if (parameters.shadowMapType === PCFShadowMap) {\n    shadowMapTypeDefine = 'SHADOWMAP_TYPE_PCF';\n  } else if (parameters.shadowMapType === PCFSoftShadowMap) {\n    shadowMapTypeDefine = 'SHADOWMAP_TYPE_PCF_SOFT';\n  } else if (parameters.shadowMapType === VSMShadowMap) {\n    shadowMapTypeDefine = 'SHADOWMAP_TYPE_VSM';\n  }\n  return shadowMapTypeDefine;\n}\nfunction generateEnvMapTypeDefine(parameters) {\n  let envMapTypeDefine = 'ENVMAP_TYPE_CUBE';\n  if (parameters.envMap) {\n    switch (parameters.envMapMode) {\n      case CubeReflectionMapping:\n      case CubeRefractionMapping:\n        envMapTypeDefine = 'ENVMAP_TYPE_CUBE';\n        break;\n      case CubeUVReflectionMapping:\n      case CubeUVRefractionMapping:\n        envMapTypeDefine = 'ENVMAP_TYPE_CUBE_UV';\n        break;\n    }\n  }\n  return envMapTypeDefine;\n}\nfunction generateEnvMapModeDefine(parameters) {\n  let envMapModeDefine = 'ENVMAP_MODE_REFLECTION';\n  if (parameters.envMap) {\n    switch (parameters.envMapMode) {\n      case CubeRefractionMapping:\n      case CubeUVRefractionMapping:\n        envMapModeDefine = 'ENVMAP_MODE_REFRACTION';\n        break;\n    }\n  }\n  return envMapModeDefine;\n}\nfunction generateEnvMapBlendingDefine(parameters) {\n  let envMapBlendingDefine = 'ENVMAP_BLENDING_NONE';\n  if (parameters.envMap) {\n    switch (parameters.combine) {\n      case MultiplyOperation:\n        envMapBlendingDefine = 'ENVMAP_BLENDING_MULTIPLY';\n        break;\n      case MixOperation:\n        envMapBlendingDefine = 'ENVMAP_BLENDING_MIX';\n        break;\n      case AddOperation:\n        envMapBlendingDefine = 'ENVMAP_BLENDING_ADD';\n        break;\n    }\n  }\n  return envMapBlendingDefine;\n}\nfunction WebGLProgram(renderer, cacheKey, parameters, bindingStates) {\n  const gl = renderer.getContext();\n  const defines = parameters.defines;\n  let vertexShader = parameters.vertexShader;\n  let fragmentShader = parameters.fragmentShader;\n  const shadowMapTypeDefine = generateShadowMapTypeDefine(parameters);\n  const envMapTypeDefine = generateEnvMapTypeDefine(parameters);\n  const envMapModeDefine = generateEnvMapModeDefine(parameters);\n  const envMapBlendingDefine = generateEnvMapBlendingDefine(parameters);\n  const gammaFactorDefine = renderer.gammaFactor > 0 ? renderer.gammaFactor : 1.0;\n  const customExtensions = parameters.isWebGL2 ? '' : generateExtensions(parameters);\n  const customDefines = generateDefines(defines);\n  const program = gl.createProgram();\n  let prefixVertex, prefixFragment;\n  let versionString = parameters.glslVersion ? '#version ' + parameters.glslVersion + '\\n' : '';\n  if (parameters.isRawShaderMaterial) {\n    prefixVertex = [customDefines].filter(filterEmptyLine).join('\\n');\n    if (prefixVertex.length > 0) {\n      prefixVertex += '\\n';\n    }\n    prefixFragment = [customExtensions, customDefines].filter(filterEmptyLine).join('\\n');\n    if (prefixFragment.length > 0) {\n      prefixFragment += '\\n';\n    }\n  } else {\n    prefixVertex = [generatePrecision(parameters), '#define SHADER_NAME ' + parameters.shaderName, customDefines, parameters.instancing ? '#define USE_INSTANCING' : '', parameters.instancingColor ? '#define USE_INSTANCING_COLOR' : '', parameters.supportsVertexTextures ? '#define VERTEX_TEXTURES' : '', '#define GAMMA_FACTOR ' + gammaFactorDefine, '#define MAX_BONES ' + parameters.maxBones, parameters.useFog && parameters.fog ? '#define USE_FOG' : '', parameters.useFog && parameters.fogExp2 ? '#define FOG_EXP2' : '', parameters.map ? '#define USE_MAP' : '', parameters.envMap ? '#define USE_ENVMAP' : '', parameters.envMap ? '#define ' + envMapModeDefine : '', parameters.lightMap ? '#define USE_LIGHTMAP' : '', parameters.aoMap ? '#define USE_AOMAP' : '', parameters.emissiveMap ? '#define USE_EMISSIVEMAP' : '', parameters.bumpMap ? '#define USE_BUMPMAP' : '', parameters.normalMap ? '#define USE_NORMALMAP' : '', parameters.normalMap && parameters.objectSpaceNormalMap ? '#define OBJECTSPACE_NORMALMAP' : '', parameters.normalMap && parameters.tangentSpaceNormalMap ? '#define TANGENTSPACE_NORMALMAP' : '', parameters.clearcoatMap ? '#define USE_CLEARCOATMAP' : '', parameters.clearcoatRoughnessMap ? '#define USE_CLEARCOAT_ROUGHNESSMAP' : '', parameters.clearcoatNormalMap ? '#define USE_CLEARCOAT_NORMALMAP' : '', parameters.displacementMap && parameters.supportsVertexTextures ? '#define USE_DISPLACEMENTMAP' : '', parameters.specularMap ? '#define USE_SPECULARMAP' : '', parameters.roughnessMap ? '#define USE_ROUGHNESSMAP' : '', parameters.metalnessMap ? '#define USE_METALNESSMAP' : '', parameters.alphaMap ? '#define USE_ALPHAMAP' : '', parameters.transmissionMap ? '#define USE_TRANSMISSIONMAP' : '', parameters.vertexTangents ? '#define USE_TANGENT' : '', parameters.vertexColors ? '#define USE_COLOR' : '', parameters.vertexUvs ? '#define USE_UV' : '', parameters.uvsVertexOnly ? '#define UVS_VERTEX_ONLY' : '', parameters.flatShading ? '#define FLAT_SHADED' : '', parameters.skinning ? '#define USE_SKINNING' : '', parameters.useVertexTexture ? '#define BONE_TEXTURE' : '', parameters.morphTargets ? '#define USE_MORPHTARGETS' : '', parameters.morphNormals && parameters.flatShading === false ? '#define USE_MORPHNORMALS' : '', parameters.doubleSided ? '#define DOUBLE_SIDED' : '', parameters.flipSided ? '#define FLIP_SIDED' : '', parameters.shadowMapEnabled ? '#define USE_SHADOWMAP' : '', parameters.shadowMapEnabled ? '#define ' + shadowMapTypeDefine : '', parameters.sizeAttenuation ? '#define USE_SIZEATTENUATION' : '', parameters.logarithmicDepthBuffer ? '#define USE_LOGDEPTHBUF' : '', parameters.logarithmicDepthBuffer && parameters.rendererExtensionFragDepth ? '#define USE_LOGDEPTHBUF_EXT' : '', 'uniform mat4 modelMatrix;', 'uniform mat4 modelViewMatrix;', 'uniform mat4 projectionMatrix;', 'uniform mat4 viewMatrix;', 'uniform mat3 normalMatrix;', 'uniform vec3 cameraPosition;', 'uniform bool isOrthographic;', '#ifdef USE_INSTANCING', '\tattribute mat4 instanceMatrix;', '#endif', '#ifdef USE_INSTANCING_COLOR', '\tattribute vec3 instanceColor;', '#endif', 'attribute vec3 position;', 'attribute vec3 normal;', 'attribute vec2 uv;', '#ifdef USE_TANGENT', '\tattribute vec4 tangent;', '#endif', '#ifdef USE_COLOR', '\tattribute vec3 color;', '#endif', '#ifdef USE_MORPHTARGETS', '\tattribute vec3 morphTarget0;', '\tattribute vec3 morphTarget1;', '\tattribute vec3 morphTarget2;', '\tattribute vec3 morphTarget3;', '\t#ifdef USE_MORPHNORMALS', '\t\tattribute vec3 morphNormal0;', '\t\tattribute vec3 morphNormal1;', '\t\tattribute vec3 morphNormal2;', '\t\tattribute vec3 morphNormal3;', '\t#else', '\t\tattribute vec3 morphTarget4;', '\t\tattribute vec3 morphTarget5;', '\t\tattribute vec3 morphTarget6;', '\t\tattribute vec3 morphTarget7;', '\t#endif', '#endif', '#ifdef USE_SKINNING', '\tattribute vec4 skinIndex;', '\tattribute vec4 skinWeight;', '#endif', '\\n'].filter(filterEmptyLine).join('\\n');\n    prefixFragment = [customExtensions, generatePrecision(parameters), '#define SHADER_NAME ' + parameters.shaderName, customDefines, parameters.alphaTest ? '#define ALPHATEST ' + parameters.alphaTest + (parameters.alphaTest % 1 ? '' : '.0') : '',\n    // add '.0' if integer\n\n    '#define GAMMA_FACTOR ' + gammaFactorDefine, parameters.useFog && parameters.fog ? '#define USE_FOG' : '', parameters.useFog && parameters.fogExp2 ? '#define FOG_EXP2' : '', parameters.map ? '#define USE_MAP' : '', parameters.matcap ? '#define USE_MATCAP' : '', parameters.envMap ? '#define USE_ENVMAP' : '', parameters.envMap ? '#define ' + envMapTypeDefine : '', parameters.envMap ? '#define ' + envMapModeDefine : '', parameters.envMap ? '#define ' + envMapBlendingDefine : '', parameters.lightMap ? '#define USE_LIGHTMAP' : '', parameters.aoMap ? '#define USE_AOMAP' : '', parameters.emissiveMap ? '#define USE_EMISSIVEMAP' : '', parameters.bumpMap ? '#define USE_BUMPMAP' : '', parameters.normalMap ? '#define USE_NORMALMAP' : '', parameters.normalMap && parameters.objectSpaceNormalMap ? '#define OBJECTSPACE_NORMALMAP' : '', parameters.normalMap && parameters.tangentSpaceNormalMap ? '#define TANGENTSPACE_NORMALMAP' : '', parameters.clearcoatMap ? '#define USE_CLEARCOATMAP' : '', parameters.clearcoatRoughnessMap ? '#define USE_CLEARCOAT_ROUGHNESSMAP' : '', parameters.clearcoatNormalMap ? '#define USE_CLEARCOAT_NORMALMAP' : '', parameters.specularMap ? '#define USE_SPECULARMAP' : '', parameters.roughnessMap ? '#define USE_ROUGHNESSMAP' : '', parameters.metalnessMap ? '#define USE_METALNESSMAP' : '', parameters.alphaMap ? '#define USE_ALPHAMAP' : '', parameters.sheen ? '#define USE_SHEEN' : '', parameters.transmissionMap ? '#define USE_TRANSMISSIONMAP' : '', parameters.vertexTangents ? '#define USE_TANGENT' : '', parameters.vertexColors || parameters.instancingColor ? '#define USE_COLOR' : '', parameters.vertexUvs ? '#define USE_UV' : '', parameters.uvsVertexOnly ? '#define UVS_VERTEX_ONLY' : '', parameters.gradientMap ? '#define USE_GRADIENTMAP' : '', parameters.flatShading ? '#define FLAT_SHADED' : '', parameters.doubleSided ? '#define DOUBLE_SIDED' : '', parameters.flipSided ? '#define FLIP_SIDED' : '', parameters.shadowMapEnabled ? '#define USE_SHADOWMAP' : '', parameters.shadowMapEnabled ? '#define ' + shadowMapTypeDefine : '', parameters.premultipliedAlpha ? '#define PREMULTIPLIED_ALPHA' : '', parameters.physicallyCorrectLights ? '#define PHYSICALLY_CORRECT_LIGHTS' : '', parameters.logarithmicDepthBuffer ? '#define USE_LOGDEPTHBUF' : '', parameters.logarithmicDepthBuffer && parameters.rendererExtensionFragDepth ? '#define USE_LOGDEPTHBUF_EXT' : '', (parameters.extensionShaderTextureLOD || parameters.envMap) && parameters.rendererExtensionShaderTextureLod ? '#define TEXTURE_LOD_EXT' : '', 'uniform mat4 viewMatrix;', 'uniform vec3 cameraPosition;', 'uniform bool isOrthographic;', parameters.toneMapping !== NoToneMapping ? '#define TONE_MAPPING' : '', parameters.toneMapping !== NoToneMapping ? ShaderChunk['tonemapping_pars_fragment'] : '',\n    // this code is required here because it is used by the toneMapping() function defined below\n    parameters.toneMapping !== NoToneMapping ? getToneMappingFunction('toneMapping', parameters.toneMapping) : '', parameters.dithering ? '#define DITHERING' : '', ShaderChunk['encodings_pars_fragment'],\n    // this code is required here because it is used by the various encoding/decoding function defined below\n    parameters.map ? getTexelDecodingFunction('mapTexelToLinear', parameters.mapEncoding) : '', parameters.matcap ? getTexelDecodingFunction('matcapTexelToLinear', parameters.matcapEncoding) : '', parameters.envMap ? getTexelDecodingFunction('envMapTexelToLinear', parameters.envMapEncoding) : '', parameters.emissiveMap ? getTexelDecodingFunction('emissiveMapTexelToLinear', parameters.emissiveMapEncoding) : '', parameters.lightMap ? getTexelDecodingFunction('lightMapTexelToLinear', parameters.lightMapEncoding) : '', getTexelEncodingFunction('linearToOutputTexel', parameters.outputEncoding), parameters.depthPacking ? '#define DEPTH_PACKING ' + parameters.depthPacking : '', '\\n'].filter(filterEmptyLine).join('\\n');\n  }\n  vertexShader = resolveIncludes(vertexShader);\n  vertexShader = replaceLightNums(vertexShader, parameters);\n  vertexShader = replaceClippingPlaneNums(vertexShader, parameters);\n  fragmentShader = resolveIncludes(fragmentShader);\n  fragmentShader = replaceLightNums(fragmentShader, parameters);\n  fragmentShader = replaceClippingPlaneNums(fragmentShader, parameters);\n  vertexShader = unrollLoops(vertexShader);\n  fragmentShader = unrollLoops(fragmentShader);\n  if (parameters.isWebGL2 && parameters.isRawShaderMaterial !== true) {\n    // GLSL 3.0 conversion for built-in materials and ShaderMaterial\n\n    versionString = '#version 300 es\\n';\n    prefixVertex = ['#define attribute in', '#define varying out', '#define texture2D texture'].join('\\n') + '\\n' + prefixVertex;\n    prefixFragment = ['#define varying in', parameters.glslVersion === GLSL3 ? '' : 'out highp vec4 pc_fragColor;', parameters.glslVersion === GLSL3 ? '' : '#define gl_FragColor pc_fragColor', '#define gl_FragDepthEXT gl_FragDepth', '#define texture2D texture', '#define textureCube texture', '#define texture2DProj textureProj', '#define texture2DLodEXT textureLod', '#define texture2DProjLodEXT textureProjLod', '#define textureCubeLodEXT textureLod', '#define texture2DGradEXT textureGrad', '#define texture2DProjGradEXT textureProjGrad', '#define textureCubeGradEXT textureGrad'].join('\\n') + '\\n' + prefixFragment;\n  }\n  const vertexGlsl = versionString + prefixVertex + vertexShader;\n  const fragmentGlsl = versionString + prefixFragment + fragmentShader;\n\n  // console.log( '*VERTEX*', vertexGlsl );\n  // console.log( '*FRAGMENT*', fragmentGlsl );\n\n  const glVertexShader = WebGLShader(gl, 35633, vertexGlsl);\n  const glFragmentShader = WebGLShader(gl, 35632, fragmentGlsl);\n  gl.attachShader(program, glVertexShader);\n  gl.attachShader(program, glFragmentShader);\n\n  // Force a particular attribute to index 0.\n\n  if (parameters.index0AttributeName !== undefined) {\n    gl.bindAttribLocation(program, 0, parameters.index0AttributeName);\n  } else if (parameters.morphTargets === true) {\n    // programs with morphTargets displace position out of attribute 0\n    gl.bindAttribLocation(program, 0, 'position');\n  }\n  gl.linkProgram(program);\n\n  // check for link errors\n  if (renderer.debug.checkShaderErrors) {\n    const programLog = gl.getProgramInfoLog(program).trim();\n    const vertexLog = gl.getShaderInfoLog(glVertexShader).trim();\n    const fragmentLog = gl.getShaderInfoLog(glFragmentShader).trim();\n    let runnable = true;\n    let haveDiagnostics = true;\n    if (gl.getProgramParameter(program, 35714) === false) {\n      runnable = false;\n      const vertexErrors = getShaderErrors(gl, glVertexShader, 'vertex');\n      const fragmentErrors = getShaderErrors(gl, glFragmentShader, 'fragment');\n      console.error('THREE.WebGLProgram: shader error: ', gl.getError(), '35715', gl.getProgramParameter(program, 35715), 'gl.getProgramInfoLog', programLog, vertexErrors, fragmentErrors);\n    } else if (programLog !== '') {\n      console.warn('THREE.WebGLProgram: gl.getProgramInfoLog()', programLog);\n    } else if (vertexLog === '' || fragmentLog === '') {\n      haveDiagnostics = false;\n    }\n    if (haveDiagnostics) {\n      this.diagnostics = {\n        runnable: runnable,\n        programLog: programLog,\n        vertexShader: {\n          log: vertexLog,\n          prefix: prefixVertex\n        },\n        fragmentShader: {\n          log: fragmentLog,\n          prefix: prefixFragment\n        }\n      };\n    }\n  }\n\n  // Clean up\n\n  // Crashes in iOS9 and iOS10. #18402\n  // gl.detachShader( program, glVertexShader );\n  // gl.detachShader( program, glFragmentShader );\n\n  gl.deleteShader(glVertexShader);\n  gl.deleteShader(glFragmentShader);\n\n  // set up caching for uniform locations\n\n  let cachedUniforms;\n  this.getUniforms = function () {\n    if (cachedUniforms === undefined) {\n      cachedUniforms = new WebGLUniforms(gl, program);\n    }\n    return cachedUniforms;\n  };\n\n  // set up caching for attribute locations\n\n  let cachedAttributes;\n  this.getAttributes = function () {\n    if (cachedAttributes === undefined) {\n      cachedAttributes = fetchAttributeLocations(gl, program);\n    }\n    return cachedAttributes;\n  };\n\n  // free resource\n\n  this.destroy = function () {\n    bindingStates.releaseStatesOfProgram(this);\n    gl.deleteProgram(program);\n    this.program = undefined;\n  };\n\n  //\n\n  this.name = parameters.shaderName;\n  this.id = programIdCount++;\n  this.cacheKey = cacheKey;\n  this.usedTimes = 1;\n  this.program = program;\n  this.vertexShader = glVertexShader;\n  this.fragmentShader = glFragmentShader;\n  return this;\n}\nfunction WebGLPrograms(renderer, cubemaps, extensions, capabilities, bindingStates, clipping) {\n  const programs = [];\n  const isWebGL2 = capabilities.isWebGL2;\n  const logarithmicDepthBuffer = capabilities.logarithmicDepthBuffer;\n  const floatVertexTextures = capabilities.floatVertexTextures;\n  const maxVertexUniforms = capabilities.maxVertexUniforms;\n  const vertexTextures = capabilities.vertexTextures;\n  let precision = capabilities.precision;\n  const shaderIDs = {\n    MeshDepthMaterial: 'depth',\n    MeshDistanceMaterial: 'distanceRGBA',\n    MeshNormalMaterial: 'normal',\n    MeshBasicMaterial: 'basic',\n    MeshLambertMaterial: 'lambert',\n    MeshPhongMaterial: 'phong',\n    MeshToonMaterial: 'toon',\n    MeshStandardMaterial: 'physical',\n    MeshPhysicalMaterial: 'physical',\n    MeshMatcapMaterial: 'matcap',\n    LineBasicMaterial: 'basic',\n    LineDashedMaterial: 'dashed',\n    PointsMaterial: 'points',\n    ShadowMaterial: 'shadow',\n    SpriteMaterial: 'sprite'\n  };\n  const parameterNames = ['precision', 'isWebGL2', 'supportsVertexTextures', 'outputEncoding', 'instancing', 'instancingColor', 'map', 'mapEncoding', 'matcap', 'matcapEncoding', 'envMap', 'envMapMode', 'envMapEncoding', 'envMapCubeUV', 'lightMap', 'lightMapEncoding', 'aoMap', 'emissiveMap', 'emissiveMapEncoding', 'bumpMap', 'normalMap', 'objectSpaceNormalMap', 'tangentSpaceNormalMap', 'clearcoatMap', 'clearcoatRoughnessMap', 'clearcoatNormalMap', 'displacementMap', 'specularMap', 'roughnessMap', 'metalnessMap', 'gradientMap', 'alphaMap', 'combine', 'vertexColors', 'vertexTangents', 'vertexUvs', 'uvsVertexOnly', 'fog', 'useFog', 'fogExp2', 'flatShading', 'sizeAttenuation', 'logarithmicDepthBuffer', 'skinning', 'maxBones', 'useVertexTexture', 'morphTargets', 'morphNormals', 'maxMorphTargets', 'maxMorphNormals', 'premultipliedAlpha', 'numDirLights', 'numPointLights', 'numSpotLights', 'numHemiLights', 'numRectAreaLights', 'numDirLightShadows', 'numPointLightShadows', 'numSpotLightShadows', 'shadowMapEnabled', 'shadowMapType', 'toneMapping', 'physicallyCorrectLights', 'alphaTest', 'doubleSided', 'flipSided', 'numClippingPlanes', 'numClipIntersection', 'depthPacking', 'dithering', 'sheen', 'transmissionMap'];\n  function getMaxBones(object) {\n    const skeleton = object.skeleton;\n    const bones = skeleton.bones;\n    if (floatVertexTextures) {\n      return 1024;\n    } else {\n      // default for when object is not specified\n      // ( for example when prebuilding shader to be used with multiple objects )\n      //\n      //  - leave some extra space for other uniforms\n      //  - limit here is ANGLE's 254 max uniform vectors\n      //    (up to 54 should be safe)\n\n      const nVertexUniforms = maxVertexUniforms;\n      const nVertexMatrices = Math.floor((nVertexUniforms - 20) / 4);\n      const maxBones = Math.min(nVertexMatrices, bones.length);\n      if (maxBones < bones.length) {\n        console.warn('THREE.WebGLRenderer: Skeleton has ' + bones.length + ' bones. This GPU supports ' + maxBones + '.');\n        return 0;\n      }\n      return maxBones;\n    }\n  }\n  function getTextureEncodingFromMap(map) {\n    let encoding;\n    if (map && map.isTexture) {\n      encoding = map.encoding;\n    } else if (map && map.isWebGLRenderTarget) {\n      console.warn('THREE.WebGLPrograms.getTextureEncodingFromMap: don\\'t use render targets as textures. Use their .texture property instead.');\n      encoding = map.texture.encoding;\n    } else {\n      encoding = LinearEncoding;\n    }\n    return encoding;\n  }\n  function getParameters(material, lights, shadows, scene, object) {\n    const fog = scene.fog;\n    const environment = material.isMeshStandardMaterial ? scene.environment : null;\n    const envMap = cubemaps.get(material.envMap || environment);\n    const shaderID = shaderIDs[material.type];\n\n    // heuristics to create shader parameters according to lights in the scene\n    // (not to blow over maxLights budget)\n\n    const maxBones = object.isSkinnedMesh ? getMaxBones(object) : 0;\n    if (material.precision !== null) {\n      precision = capabilities.getMaxPrecision(material.precision);\n      if (precision !== material.precision) {\n        console.warn('THREE.WebGLProgram.getParameters:', material.precision, 'not supported, using', precision, 'instead.');\n      }\n    }\n    let vertexShader, fragmentShader;\n    if (shaderID) {\n      const shader = ShaderLib[shaderID];\n      vertexShader = shader.vertexShader;\n      fragmentShader = shader.fragmentShader;\n    } else {\n      vertexShader = material.vertexShader;\n      fragmentShader = material.fragmentShader;\n    }\n    const currentRenderTarget = renderer.getRenderTarget();\n    const parameters = {\n      isWebGL2: isWebGL2,\n      shaderID: shaderID,\n      shaderName: material.type,\n      vertexShader: vertexShader,\n      fragmentShader: fragmentShader,\n      defines: material.defines,\n      isRawShaderMaterial: material.isRawShaderMaterial === true,\n      glslVersion: material.glslVersion,\n      precision: precision,\n      instancing: object.isInstancedMesh === true,\n      instancingColor: object.isInstancedMesh === true && object.instanceColor !== null,\n      supportsVertexTextures: vertexTextures,\n      outputEncoding: currentRenderTarget !== null ? getTextureEncodingFromMap(currentRenderTarget.texture) : renderer.outputEncoding,\n      map: !!material.map,\n      mapEncoding: getTextureEncodingFromMap(material.map),\n      matcap: !!material.matcap,\n      matcapEncoding: getTextureEncodingFromMap(material.matcap),\n      envMap: !!envMap,\n      envMapMode: envMap && envMap.mapping,\n      envMapEncoding: getTextureEncodingFromMap(envMap),\n      envMapCubeUV: !!envMap && (envMap.mapping === CubeUVReflectionMapping || envMap.mapping === CubeUVRefractionMapping),\n      lightMap: !!material.lightMap,\n      lightMapEncoding: getTextureEncodingFromMap(material.lightMap),\n      aoMap: !!material.aoMap,\n      emissiveMap: !!material.emissiveMap,\n      emissiveMapEncoding: getTextureEncodingFromMap(material.emissiveMap),\n      bumpMap: !!material.bumpMap,\n      normalMap: !!material.normalMap,\n      objectSpaceNormalMap: material.normalMapType === ObjectSpaceNormalMap,\n      tangentSpaceNormalMap: material.normalMapType === TangentSpaceNormalMap,\n      clearcoatMap: !!material.clearcoatMap,\n      clearcoatRoughnessMap: !!material.clearcoatRoughnessMap,\n      clearcoatNormalMap: !!material.clearcoatNormalMap,\n      displacementMap: !!material.displacementMap,\n      roughnessMap: !!material.roughnessMap,\n      metalnessMap: !!material.metalnessMap,\n      specularMap: !!material.specularMap,\n      alphaMap: !!material.alphaMap,\n      gradientMap: !!material.gradientMap,\n      sheen: !!material.sheen,\n      transmissionMap: !!material.transmissionMap,\n      combine: material.combine,\n      vertexTangents: material.normalMap && material.vertexTangents,\n      vertexColors: material.vertexColors,\n      vertexUvs: !!material.map || !!material.bumpMap || !!material.normalMap || !!material.specularMap || !!material.alphaMap || !!material.emissiveMap || !!material.roughnessMap || !!material.metalnessMap || !!material.clearcoatMap || !!material.clearcoatRoughnessMap || !!material.clearcoatNormalMap || !!material.displacementMap || !!material.transmissionMap,\n      uvsVertexOnly: !(!!material.map || !!material.bumpMap || !!material.normalMap || !!material.specularMap || !!material.alphaMap || !!material.emissiveMap || !!material.roughnessMap || !!material.metalnessMap || !!material.clearcoatNormalMap || !!material.transmissionMap) && !!material.displacementMap,\n      fog: !!fog,\n      useFog: material.fog,\n      fogExp2: fog && fog.isFogExp2,\n      flatShading: material.flatShading,\n      sizeAttenuation: material.sizeAttenuation,\n      logarithmicDepthBuffer: logarithmicDepthBuffer,\n      skinning: material.skinning && maxBones > 0,\n      maxBones: maxBones,\n      useVertexTexture: floatVertexTextures,\n      morphTargets: material.morphTargets,\n      morphNormals: material.morphNormals,\n      maxMorphTargets: renderer.maxMorphTargets,\n      maxMorphNormals: renderer.maxMorphNormals,\n      numDirLights: lights.directional.length,\n      numPointLights: lights.point.length,\n      numSpotLights: lights.spot.length,\n      numRectAreaLights: lights.rectArea.length,\n      numHemiLights: lights.hemi.length,\n      numDirLightShadows: lights.directionalShadowMap.length,\n      numPointLightShadows: lights.pointShadowMap.length,\n      numSpotLightShadows: lights.spotShadowMap.length,\n      numClippingPlanes: clipping.numPlanes,\n      numClipIntersection: clipping.numIntersection,\n      dithering: material.dithering,\n      shadowMapEnabled: renderer.shadowMap.enabled && shadows.length > 0,\n      shadowMapType: renderer.shadowMap.type,\n      toneMapping: material.toneMapped ? renderer.toneMapping : NoToneMapping,\n      physicallyCorrectLights: renderer.physicallyCorrectLights,\n      premultipliedAlpha: material.premultipliedAlpha,\n      alphaTest: material.alphaTest,\n      doubleSided: material.side === DoubleSide,\n      flipSided: material.side === BackSide,\n      depthPacking: material.depthPacking !== undefined ? material.depthPacking : false,\n      index0AttributeName: material.index0AttributeName,\n      extensionDerivatives: material.extensions && material.extensions.derivatives,\n      extensionFragDepth: material.extensions && material.extensions.fragDepth,\n      extensionDrawBuffers: material.extensions && material.extensions.drawBuffers,\n      extensionShaderTextureLOD: material.extensions && material.extensions.shaderTextureLOD,\n      rendererExtensionFragDepth: isWebGL2 || extensions.has('EXT_frag_depth'),\n      rendererExtensionDrawBuffers: isWebGL2 || extensions.has('WEBGL_draw_buffers'),\n      rendererExtensionShaderTextureLod: isWebGL2 || extensions.has('EXT_shader_texture_lod'),\n      customProgramCacheKey: material.customProgramCacheKey()\n    };\n    return parameters;\n  }\n  function getProgramCacheKey(parameters) {\n    const array = [];\n    if (parameters.shaderID) {\n      array.push(parameters.shaderID);\n    } else {\n      array.push(parameters.fragmentShader);\n      array.push(parameters.vertexShader);\n    }\n    if (parameters.defines !== undefined) {\n      for (const name in parameters.defines) {\n        array.push(name);\n        array.push(parameters.defines[name]);\n      }\n    }\n    if (parameters.isRawShaderMaterial === false) {\n      for (let i = 0; i < parameterNames.length; i++) {\n        array.push(parameters[parameterNames[i]]);\n      }\n      array.push(renderer.outputEncoding);\n      array.push(renderer.gammaFactor);\n    }\n    array.push(parameters.customProgramCacheKey);\n    return array.join();\n  }\n  function getUniforms(material) {\n    const shaderID = shaderIDs[material.type];\n    let uniforms;\n    if (shaderID) {\n      const shader = ShaderLib[shaderID];\n      uniforms = UniformsUtils.clone(shader.uniforms);\n    } else {\n      uniforms = material.uniforms;\n    }\n    return uniforms;\n  }\n  function acquireProgram(parameters, cacheKey) {\n    let program;\n\n    // Check if code has been already compiled\n    for (let p = 0, pl = programs.length; p < pl; p++) {\n      const preexistingProgram = programs[p];\n      if (preexistingProgram.cacheKey === cacheKey) {\n        program = preexistingProgram;\n        ++program.usedTimes;\n        break;\n      }\n    }\n    if (program === undefined) {\n      program = new WebGLProgram(renderer, cacheKey, parameters, bindingStates);\n      programs.push(program);\n    }\n    return program;\n  }\n  function releaseProgram(program) {\n    if (--program.usedTimes === 0) {\n      // Remove from unordered set\n      const i = programs.indexOf(program);\n      programs[i] = programs[programs.length - 1];\n      programs.pop();\n\n      // Free WebGL resources\n      program.destroy();\n    }\n  }\n  return {\n    getParameters: getParameters,\n    getProgramCacheKey: getProgramCacheKey,\n    getUniforms: getUniforms,\n    acquireProgram: acquireProgram,\n    releaseProgram: releaseProgram,\n    // Exposed for resource monitoring & error feedback via renderer.info:\n    programs: programs\n  };\n}\nfunction WebGLProperties() {\n  let properties = new WeakMap();\n  function get(object) {\n    let map = properties.get(object);\n    if (map === undefined) {\n      map = {};\n      properties.set(object, map);\n    }\n    return map;\n  }\n  function remove(object) {\n    properties.delete(object);\n  }\n  function update(object, key, value) {\n    properties.get(object)[key] = value;\n  }\n  function dispose() {\n    properties = new WeakMap();\n  }\n  return {\n    get: get,\n    remove: remove,\n    update: update,\n    dispose: dispose\n  };\n}\nfunction painterSortStable(a, b) {\n  if (a.groupOrder !== b.groupOrder) {\n    return a.groupOrder - b.groupOrder;\n  } else if (a.renderOrder !== b.renderOrder) {\n    return a.renderOrder - b.renderOrder;\n  } else if (a.program !== b.program) {\n    return a.program.id - b.program.id;\n  } else if (a.material.id !== b.material.id) {\n    return a.material.id - b.material.id;\n  } else if (a.z !== b.z) {\n    return a.z - b.z;\n  } else {\n    return a.id - b.id;\n  }\n}\nfunction reversePainterSortStable(a, b) {\n  if (a.groupOrder !== b.groupOrder) {\n    return a.groupOrder - b.groupOrder;\n  } else if (a.renderOrder !== b.renderOrder) {\n    return a.renderOrder - b.renderOrder;\n  } else if (a.z !== b.z) {\n    return b.z - a.z;\n  } else {\n    return a.id - b.id;\n  }\n}\nfunction WebGLRenderList(properties) {\n  const renderItems = [];\n  let renderItemsIndex = 0;\n  const opaque = [];\n  const transparent = [];\n  const defaultProgram = {\n    id: -1\n  };\n  function init() {\n    renderItemsIndex = 0;\n    opaque.length = 0;\n    transparent.length = 0;\n  }\n  function getNextRenderItem(object, geometry, material, groupOrder, z, group) {\n    let renderItem = renderItems[renderItemsIndex];\n    const materialProperties = properties.get(material);\n    if (renderItem === undefined) {\n      renderItem = {\n        id: object.id,\n        object: object,\n        geometry: geometry,\n        material: material,\n        program: materialProperties.program || defaultProgram,\n        groupOrder: groupOrder,\n        renderOrder: object.renderOrder,\n        z: z,\n        group: group\n      };\n      renderItems[renderItemsIndex] = renderItem;\n    } else {\n      renderItem.id = object.id;\n      renderItem.object = object;\n      renderItem.geometry = geometry;\n      renderItem.material = material;\n      renderItem.program = materialProperties.program || defaultProgram;\n      renderItem.groupOrder = groupOrder;\n      renderItem.renderOrder = object.renderOrder;\n      renderItem.z = z;\n      renderItem.group = group;\n    }\n    renderItemsIndex++;\n    return renderItem;\n  }\n  function push(object, geometry, material, groupOrder, z, group) {\n    const renderItem = getNextRenderItem(object, geometry, material, groupOrder, z, group);\n    (material.transparent === true ? transparent : opaque).push(renderItem);\n  }\n  function unshift(object, geometry, material, groupOrder, z, group) {\n    const renderItem = getNextRenderItem(object, geometry, material, groupOrder, z, group);\n    (material.transparent === true ? transparent : opaque).unshift(renderItem);\n  }\n  function sort(customOpaqueSort, customTransparentSort) {\n    if (opaque.length > 1) opaque.sort(customOpaqueSort || painterSortStable);\n    if (transparent.length > 1) transparent.sort(customTransparentSort || reversePainterSortStable);\n  }\n  function finish() {\n    // Clear references from inactive renderItems in the list\n\n    for (let i = renderItemsIndex, il = renderItems.length; i < il; i++) {\n      const renderItem = renderItems[i];\n      if (renderItem.id === null) break;\n      renderItem.id = null;\n      renderItem.object = null;\n      renderItem.geometry = null;\n      renderItem.material = null;\n      renderItem.program = null;\n      renderItem.group = null;\n    }\n  }\n  return {\n    opaque: opaque,\n    transparent: transparent,\n    init: init,\n    push: push,\n    unshift: unshift,\n    finish: finish,\n    sort: sort\n  };\n}\nfunction WebGLRenderLists(properties) {\n  let lists = new WeakMap();\n  function get(scene, camera) {\n    const cameras = lists.get(scene);\n    let list;\n    if (cameras === undefined) {\n      list = new WebGLRenderList(properties);\n      lists.set(scene, new WeakMap());\n      lists.get(scene).set(camera, list);\n    } else {\n      list = cameras.get(camera);\n      if (list === undefined) {\n        list = new WebGLRenderList(properties);\n        cameras.set(camera, list);\n      }\n    }\n    return list;\n  }\n  function dispose() {\n    lists = new WeakMap();\n  }\n  return {\n    get: get,\n    dispose: dispose\n  };\n}\nfunction UniformsCache() {\n  const lights = {};\n  return {\n    get: function (light) {\n      if (lights[light.id] !== undefined) {\n        return lights[light.id];\n      }\n      let uniforms;\n      switch (light.type) {\n        case 'DirectionalLight':\n          uniforms = {\n            direction: new Vector3(),\n            color: new Color()\n          };\n          break;\n        case 'SpotLight':\n          uniforms = {\n            position: new Vector3(),\n            direction: new Vector3(),\n            color: new Color(),\n            distance: 0,\n            coneCos: 0,\n            penumbraCos: 0,\n            decay: 0\n          };\n          break;\n        case 'PointLight':\n          uniforms = {\n            position: new Vector3(),\n            color: new Color(),\n            distance: 0,\n            decay: 0\n          };\n          break;\n        case 'HemisphereLight':\n          uniforms = {\n            direction: new Vector3(),\n            skyColor: new Color(),\n            groundColor: new Color()\n          };\n          break;\n        case 'RectAreaLight':\n          uniforms = {\n            color: new Color(),\n            position: new Vector3(),\n            halfWidth: new Vector3(),\n            halfHeight: new Vector3()\n          };\n          break;\n      }\n      lights[light.id] = uniforms;\n      return uniforms;\n    }\n  };\n}\nfunction ShadowUniformsCache() {\n  const lights = {};\n  return {\n    get: function (light) {\n      if (lights[light.id] !== undefined) {\n        return lights[light.id];\n      }\n      let uniforms;\n      switch (light.type) {\n        case 'DirectionalLight':\n          uniforms = {\n            shadowBias: 0,\n            shadowNormalBias: 0,\n            shadowRadius: 1,\n            shadowMapSize: new Vector2()\n          };\n          break;\n        case 'SpotLight':\n          uniforms = {\n            shadowBias: 0,\n            shadowNormalBias: 0,\n            shadowRadius: 1,\n            shadowMapSize: new Vector2()\n          };\n          break;\n        case 'PointLight':\n          uniforms = {\n            shadowBias: 0,\n            shadowNormalBias: 0,\n            shadowRadius: 1,\n            shadowMapSize: new Vector2(),\n            shadowCameraNear: 1,\n            shadowCameraFar: 1000\n          };\n          break;\n\n        // TODO (abelnation): set RectAreaLight shadow uniforms\n      }\n\n      lights[light.id] = uniforms;\n      return uniforms;\n    }\n  };\n}\nlet nextVersion = 0;\nfunction shadowCastingLightsFirst(lightA, lightB) {\n  return (lightB.castShadow ? 1 : 0) - (lightA.castShadow ? 1 : 0);\n}\nfunction WebGLLights(extensions, capabilities) {\n  const cache = new UniformsCache();\n  const shadowCache = ShadowUniformsCache();\n  const state = {\n    version: 0,\n    hash: {\n      directionalLength: -1,\n      pointLength: -1,\n      spotLength: -1,\n      rectAreaLength: -1,\n      hemiLength: -1,\n      numDirectionalShadows: -1,\n      numPointShadows: -1,\n      numSpotShadows: -1\n    },\n    ambient: [0, 0, 0],\n    probe: [],\n    directional: [],\n    directionalShadow: [],\n    directionalShadowMap: [],\n    directionalShadowMatrix: [],\n    spot: [],\n    spotShadow: [],\n    spotShadowMap: [],\n    spotShadowMatrix: [],\n    rectArea: [],\n    rectAreaLTC1: null,\n    rectAreaLTC2: null,\n    point: [],\n    pointShadow: [],\n    pointShadowMap: [],\n    pointShadowMatrix: [],\n    hemi: []\n  };\n  for (let i = 0; i < 9; i++) state.probe.push(new Vector3());\n  const vector3 = new Vector3();\n  const matrix4 = new Matrix4();\n  const matrix42 = new Matrix4();\n  function setup(lights) {\n    let r = 0,\n      g = 0,\n      b = 0;\n    for (let i = 0; i < 9; i++) state.probe[i].set(0, 0, 0);\n    let directionalLength = 0;\n    let pointLength = 0;\n    let spotLength = 0;\n    let rectAreaLength = 0;\n    let hemiLength = 0;\n    let numDirectionalShadows = 0;\n    let numPointShadows = 0;\n    let numSpotShadows = 0;\n    lights.sort(shadowCastingLightsFirst);\n    for (let i = 0, l = lights.length; i < l; i++) {\n      const light = lights[i];\n      const color = light.color;\n      const intensity = light.intensity;\n      const distance = light.distance;\n      const shadowMap = light.shadow && light.shadow.map ? light.shadow.map.texture : null;\n      if (light.isAmbientLight) {\n        r += color.r * intensity;\n        g += color.g * intensity;\n        b += color.b * intensity;\n      } else if (light.isLightProbe) {\n        for (let j = 0; j < 9; j++) {\n          state.probe[j].addScaledVector(light.sh.coefficients[j], intensity);\n        }\n      } else if (light.isDirectionalLight) {\n        const uniforms = cache.get(light);\n        uniforms.color.copy(light.color).multiplyScalar(light.intensity);\n        if (light.castShadow) {\n          const shadow = light.shadow;\n          const shadowUniforms = shadowCache.get(light);\n          shadowUniforms.shadowBias = shadow.bias;\n          shadowUniforms.shadowNormalBias = shadow.normalBias;\n          shadowUniforms.shadowRadius = shadow.radius;\n          shadowUniforms.shadowMapSize = shadow.mapSize;\n          state.directionalShadow[directionalLength] = shadowUniforms;\n          state.directionalShadowMap[directionalLength] = shadowMap;\n          state.directionalShadowMatrix[directionalLength] = light.shadow.matrix;\n          numDirectionalShadows++;\n        }\n        state.directional[directionalLength] = uniforms;\n        directionalLength++;\n      } else if (light.isSpotLight) {\n        const uniforms = cache.get(light);\n        uniforms.position.setFromMatrixPosition(light.matrixWorld);\n        uniforms.color.copy(color).multiplyScalar(intensity);\n        uniforms.distance = distance;\n        uniforms.coneCos = Math.cos(light.angle);\n        uniforms.penumbraCos = Math.cos(light.angle * (1 - light.penumbra));\n        uniforms.decay = light.decay;\n        if (light.castShadow) {\n          const shadow = light.shadow;\n          const shadowUniforms = shadowCache.get(light);\n          shadowUniforms.shadowBias = shadow.bias;\n          shadowUniforms.shadowNormalBias = shadow.normalBias;\n          shadowUniforms.shadowRadius = shadow.radius;\n          shadowUniforms.shadowMapSize = shadow.mapSize;\n          state.spotShadow[spotLength] = shadowUniforms;\n          state.spotShadowMap[spotLength] = shadowMap;\n          state.spotShadowMatrix[spotLength] = light.shadow.matrix;\n          numSpotShadows++;\n        }\n        state.spot[spotLength] = uniforms;\n        spotLength++;\n      } else if (light.isRectAreaLight) {\n        const uniforms = cache.get(light);\n\n        // (a) intensity is the total visible light emitted\n        //uniforms.color.copy( color ).multiplyScalar( intensity / ( light.width * light.height * Math.PI ) );\n\n        // (b) intensity is the brightness of the light\n        uniforms.color.copy(color).multiplyScalar(intensity);\n        uniforms.halfWidth.set(light.width * 0.5, 0.0, 0.0);\n        uniforms.halfHeight.set(0.0, light.height * 0.5, 0.0);\n        state.rectArea[rectAreaLength] = uniforms;\n        rectAreaLength++;\n      } else if (light.isPointLight) {\n        const uniforms = cache.get(light);\n        uniforms.color.copy(light.color).multiplyScalar(light.intensity);\n        uniforms.distance = light.distance;\n        uniforms.decay = light.decay;\n        if (light.castShadow) {\n          const shadow = light.shadow;\n          const shadowUniforms = shadowCache.get(light);\n          shadowUniforms.shadowBias = shadow.bias;\n          shadowUniforms.shadowNormalBias = shadow.normalBias;\n          shadowUniforms.shadowRadius = shadow.radius;\n          shadowUniforms.shadowMapSize = shadow.mapSize;\n          shadowUniforms.shadowCameraNear = shadow.camera.near;\n          shadowUniforms.shadowCameraFar = shadow.camera.far;\n          state.pointShadow[pointLength] = shadowUniforms;\n          state.pointShadowMap[pointLength] = shadowMap;\n          state.pointShadowMatrix[pointLength] = light.shadow.matrix;\n          numPointShadows++;\n        }\n        state.point[pointLength] = uniforms;\n        pointLength++;\n      } else if (light.isHemisphereLight) {\n        const uniforms = cache.get(light);\n        uniforms.skyColor.copy(light.color).multiplyScalar(intensity);\n        uniforms.groundColor.copy(light.groundColor).multiplyScalar(intensity);\n        state.hemi[hemiLength] = uniforms;\n        hemiLength++;\n      }\n    }\n    if (rectAreaLength > 0) {\n      if (capabilities.isWebGL2) {\n        // WebGL 2\n\n        state.rectAreaLTC1 = UniformsLib.LTC_FLOAT_1;\n        state.rectAreaLTC2 = UniformsLib.LTC_FLOAT_2;\n      } else {\n        // WebGL 1\n\n        if (extensions.has('OES_texture_float_linear') === true) {\n          state.rectAreaLTC1 = UniformsLib.LTC_FLOAT_1;\n          state.rectAreaLTC2 = UniformsLib.LTC_FLOAT_2;\n        } else if (extensions.has('OES_texture_half_float_linear') === true) {\n          state.rectAreaLTC1 = UniformsLib.LTC_HALF_1;\n          state.rectAreaLTC2 = UniformsLib.LTC_HALF_2;\n        } else {\n          console.error('THREE.WebGLRenderer: Unable to use RectAreaLight. Missing WebGL extensions.');\n        }\n      }\n    }\n    state.ambient[0] = r;\n    state.ambient[1] = g;\n    state.ambient[2] = b;\n    const hash = state.hash;\n    if (hash.directionalLength !== directionalLength || hash.pointLength !== pointLength || hash.spotLength !== spotLength || hash.rectAreaLength !== rectAreaLength || hash.hemiLength !== hemiLength || hash.numDirectionalShadows !== numDirectionalShadows || hash.numPointShadows !== numPointShadows || hash.numSpotShadows !== numSpotShadows) {\n      state.directional.length = directionalLength;\n      state.spot.length = spotLength;\n      state.rectArea.length = rectAreaLength;\n      state.point.length = pointLength;\n      state.hemi.length = hemiLength;\n      state.directionalShadow.length = numDirectionalShadows;\n      state.directionalShadowMap.length = numDirectionalShadows;\n      state.pointShadow.length = numPointShadows;\n      state.pointShadowMap.length = numPointShadows;\n      state.spotShadow.length = numSpotShadows;\n      state.spotShadowMap.length = numSpotShadows;\n      state.directionalShadowMatrix.length = numDirectionalShadows;\n      state.pointShadowMatrix.length = numPointShadows;\n      state.spotShadowMatrix.length = numSpotShadows;\n      hash.directionalLength = directionalLength;\n      hash.pointLength = pointLength;\n      hash.spotLength = spotLength;\n      hash.rectAreaLength = rectAreaLength;\n      hash.hemiLength = hemiLength;\n      hash.numDirectionalShadows = numDirectionalShadows;\n      hash.numPointShadows = numPointShadows;\n      hash.numSpotShadows = numSpotShadows;\n      state.version = nextVersion++;\n    }\n  }\n  function setupView(lights, camera) {\n    let directionalLength = 0;\n    let pointLength = 0;\n    let spotLength = 0;\n    let rectAreaLength = 0;\n    let hemiLength = 0;\n    const viewMatrix = camera.matrixWorldInverse;\n    for (let i = 0, l = lights.length; i < l; i++) {\n      const light = lights[i];\n      if (light.isDirectionalLight) {\n        const uniforms = state.directional[directionalLength];\n        uniforms.direction.setFromMatrixPosition(light.matrixWorld);\n        vector3.setFromMatrixPosition(light.target.matrixWorld);\n        uniforms.direction.sub(vector3);\n        uniforms.direction.transformDirection(viewMatrix);\n        directionalLength++;\n      } else if (light.isSpotLight) {\n        const uniforms = state.spot[spotLength];\n        uniforms.position.setFromMatrixPosition(light.matrixWorld);\n        uniforms.position.applyMatrix4(viewMatrix);\n        uniforms.direction.setFromMatrixPosition(light.matrixWorld);\n        vector3.setFromMatrixPosition(light.target.matrixWorld);\n        uniforms.direction.sub(vector3);\n        uniforms.direction.transformDirection(viewMatrix);\n        spotLength++;\n      } else if (light.isRectAreaLight) {\n        const uniforms = state.rectArea[rectAreaLength];\n        uniforms.position.setFromMatrixPosition(light.matrixWorld);\n        uniforms.position.applyMatrix4(viewMatrix);\n\n        // extract local rotation of light to derive width/height half vectors\n        matrix42.identity();\n        matrix4.copy(light.matrixWorld);\n        matrix4.premultiply(viewMatrix);\n        matrix42.extractRotation(matrix4);\n        uniforms.halfWidth.set(light.width * 0.5, 0.0, 0.0);\n        uniforms.halfHeight.set(0.0, light.height * 0.5, 0.0);\n        uniforms.halfWidth.applyMatrix4(matrix42);\n        uniforms.halfHeight.applyMatrix4(matrix42);\n        rectAreaLength++;\n      } else if (light.isPointLight) {\n        const uniforms = state.point[pointLength];\n        uniforms.position.setFromMatrixPosition(light.matrixWorld);\n        uniforms.position.applyMatrix4(viewMatrix);\n        pointLength++;\n      } else if (light.isHemisphereLight) {\n        const uniforms = state.hemi[hemiLength];\n        uniforms.direction.setFromMatrixPosition(light.matrixWorld);\n        uniforms.direction.transformDirection(viewMatrix);\n        uniforms.direction.normalize();\n        hemiLength++;\n      }\n    }\n  }\n  return {\n    setup: setup,\n    setupView: setupView,\n    state: state\n  };\n}\nfunction WebGLRenderState(extensions, capabilities) {\n  const lights = new WebGLLights(extensions, capabilities);\n  const lightsArray = [];\n  const shadowsArray = [];\n  function init() {\n    lightsArray.length = 0;\n    shadowsArray.length = 0;\n  }\n  function pushLight(light) {\n    lightsArray.push(light);\n  }\n  function pushShadow(shadowLight) {\n    shadowsArray.push(shadowLight);\n  }\n  function setupLights() {\n    lights.setup(lightsArray);\n  }\n  function setupLightsView(camera) {\n    lights.setupView(lightsArray, camera);\n  }\n  const state = {\n    lightsArray: lightsArray,\n    shadowsArray: shadowsArray,\n    lights: lights\n  };\n  return {\n    init: init,\n    state: state,\n    setupLights: setupLights,\n    setupLightsView: setupLightsView,\n    pushLight: pushLight,\n    pushShadow: pushShadow\n  };\n}\nfunction WebGLRenderStates(extensions, capabilities) {\n  let renderStates = new WeakMap();\n  function get(scene, renderCallDepth = 0) {\n    let renderState;\n    if (renderStates.has(scene) === false) {\n      renderState = new WebGLRenderState(extensions, capabilities);\n      renderStates.set(scene, []);\n      renderStates.get(scene).push(renderState);\n    } else {\n      if (renderCallDepth >= renderStates.get(scene).length) {\n        renderState = new WebGLRenderState(extensions, capabilities);\n        renderStates.get(scene).push(renderState);\n      } else {\n        renderState = renderStates.get(scene)[renderCallDepth];\n      }\n    }\n    return renderState;\n  }\n  function dispose() {\n    renderStates = new WeakMap();\n  }\n  return {\n    get: get,\n    dispose: dispose\n  };\n}\n\n/**\n * parameters = {\n *\n *  opacity: <float>,\n *\n *  map: new THREE.Texture( <Image> ),\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  displacementMap: new THREE.Texture( <Image> ),\n *  displacementScale: <float>,\n *  displacementBias: <float>,\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>\n * }\n */\n\nfunction MeshDepthMaterial(parameters) {\n  Material.call(this);\n  this.type = 'MeshDepthMaterial';\n  this.depthPacking = BasicDepthPacking;\n  this.skinning = false;\n  this.morphTargets = false;\n  this.map = null;\n  this.alphaMap = null;\n  this.displacementMap = null;\n  this.displacementScale = 1;\n  this.displacementBias = 0;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.fog = false;\n  this.setValues(parameters);\n}\nMeshDepthMaterial.prototype = Object.create(Material.prototype);\nMeshDepthMaterial.prototype.constructor = MeshDepthMaterial;\nMeshDepthMaterial.prototype.isMeshDepthMaterial = true;\nMeshDepthMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.depthPacking = source.depthPacking;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.map = source.map;\n  this.alphaMap = source.alphaMap;\n  this.displacementMap = source.displacementMap;\n  this.displacementScale = source.displacementScale;\n  this.displacementBias = source.displacementBias;\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  return this;\n};\n\n/**\n * parameters = {\n *\n *  referencePosition: <float>,\n *  nearDistance: <float>,\n *  farDistance: <float>,\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *\n *  map: new THREE.Texture( <Image> ),\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  displacementMap: new THREE.Texture( <Image> ),\n *  displacementScale: <float>,\n *  displacementBias: <float>\n *\n * }\n */\n\nfunction MeshDistanceMaterial(parameters) {\n  Material.call(this);\n  this.type = 'MeshDistanceMaterial';\n  this.referencePosition = new Vector3();\n  this.nearDistance = 1;\n  this.farDistance = 1000;\n  this.skinning = false;\n  this.morphTargets = false;\n  this.map = null;\n  this.alphaMap = null;\n  this.displacementMap = null;\n  this.displacementScale = 1;\n  this.displacementBias = 0;\n  this.fog = false;\n  this.setValues(parameters);\n}\nMeshDistanceMaterial.prototype = Object.create(Material.prototype);\nMeshDistanceMaterial.prototype.constructor = MeshDistanceMaterial;\nMeshDistanceMaterial.prototype.isMeshDistanceMaterial = true;\nMeshDistanceMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.referencePosition.copy(source.referencePosition);\n  this.nearDistance = source.nearDistance;\n  this.farDistance = source.farDistance;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.map = source.map;\n  this.alphaMap = source.alphaMap;\n  this.displacementMap = source.displacementMap;\n  this.displacementScale = source.displacementScale;\n  this.displacementBias = source.displacementBias;\n  return this;\n};\nvar vsm_frag = \"uniform sampler2D shadow_pass;\\nuniform vec2 resolution;\\nuniform float radius;\\n#include <packing>\\nvoid main() {\\n\\tfloat mean = 0.0;\\n\\tfloat squared_mean = 0.0;\\n\\tfloat depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy ) / resolution ) );\\n\\tfor ( float i = -1.0; i < 1.0 ; i += SAMPLE_RATE) {\\n\\t\\t#ifdef HORIZONTAL_PASS\\n\\t\\t\\tvec2 distribution = unpackRGBATo2Half( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( i, 0.0 ) * radius ) / resolution ) );\\n\\t\\t\\tmean += distribution.x;\\n\\t\\t\\tsquared_mean += distribution.y * distribution.y + distribution.x * distribution.x;\\n\\t\\t#else\\n\\t\\t\\tfloat depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( 0.0, i ) * radius ) / resolution ) );\\n\\t\\t\\tmean += depth;\\n\\t\\t\\tsquared_mean += depth * depth;\\n\\t\\t#endif\\n\\t}\\n\\tmean = mean * HALF_SAMPLE_RATE;\\n\\tsquared_mean = squared_mean * HALF_SAMPLE_RATE;\\n\\tfloat std_dev = sqrt( squared_mean - mean * mean );\\n\\tgl_FragColor = pack2HalfToRGBA( vec2( mean, std_dev ) );\\n}\";\nvar vsm_vert = \"void main() {\\n\\tgl_Position = vec4( position, 1.0 );\\n}\";\nfunction WebGLShadowMap(_renderer, _objects, maxTextureSize) {\n  let _frustum = new Frustum();\n  const _shadowMapSize = new Vector2(),\n    _viewportSize = new Vector2(),\n    _viewport = new Vector4(),\n    _depthMaterials = [],\n    _distanceMaterials = [],\n    _materialCache = {};\n  const shadowSide = {\n    0: BackSide,\n    1: FrontSide,\n    2: DoubleSide\n  };\n  const shadowMaterialVertical = new ShaderMaterial({\n    defines: {\n      SAMPLE_RATE: 2.0 / 8.0,\n      HALF_SAMPLE_RATE: 1.0 / 8.0\n    },\n    uniforms: {\n      shadow_pass: {\n        value: null\n      },\n      resolution: {\n        value: new Vector2()\n      },\n      radius: {\n        value: 4.0\n      }\n    },\n    vertexShader: vsm_vert,\n    fragmentShader: vsm_frag\n  });\n  const shadowMaterialHorizontal = shadowMaterialVertical.clone();\n  shadowMaterialHorizontal.defines.HORIZONTAL_PASS = 1;\n  const fullScreenTri = new BufferGeometry();\n  fullScreenTri.setAttribute('position', new BufferAttribute(new Float32Array([-1, -1, 0.5, 3, -1, 0.5, -1, 3, 0.5]), 3));\n  const fullScreenMesh = new Mesh(fullScreenTri, shadowMaterialVertical);\n  const scope = this;\n  this.enabled = false;\n  this.autoUpdate = true;\n  this.needsUpdate = false;\n  this.type = PCFShadowMap;\n  this.render = function (lights, scene, camera) {\n    if (scope.enabled === false) return;\n    if (scope.autoUpdate === false && scope.needsUpdate === false) return;\n    if (lights.length === 0) return;\n    const currentRenderTarget = _renderer.getRenderTarget();\n    const activeCubeFace = _renderer.getActiveCubeFace();\n    const activeMipmapLevel = _renderer.getActiveMipmapLevel();\n    const _state = _renderer.state;\n\n    // Set GL state for depth map.\n    _state.setBlending(NoBlending);\n    _state.buffers.color.setClear(1, 1, 1, 1);\n    _state.buffers.depth.setTest(true);\n    _state.setScissorTest(false);\n\n    // render depth map\n\n    for (let i = 0, il = lights.length; i < il; i++) {\n      const light = lights[i];\n      const shadow = light.shadow;\n      if (shadow === undefined) {\n        console.warn('THREE.WebGLShadowMap:', light, 'has no shadow.');\n        continue;\n      }\n      if (shadow.autoUpdate === false && shadow.needsUpdate === false) continue;\n      _shadowMapSize.copy(shadow.mapSize);\n      const shadowFrameExtents = shadow.getFrameExtents();\n      _shadowMapSize.multiply(shadowFrameExtents);\n      _viewportSize.copy(shadow.mapSize);\n      if (_shadowMapSize.x > maxTextureSize || _shadowMapSize.y > maxTextureSize) {\n        if (_shadowMapSize.x > maxTextureSize) {\n          _viewportSize.x = Math.floor(maxTextureSize / shadowFrameExtents.x);\n          _shadowMapSize.x = _viewportSize.x * shadowFrameExtents.x;\n          shadow.mapSize.x = _viewportSize.x;\n        }\n        if (_shadowMapSize.y > maxTextureSize) {\n          _viewportSize.y = Math.floor(maxTextureSize / shadowFrameExtents.y);\n          _shadowMapSize.y = _viewportSize.y * shadowFrameExtents.y;\n          shadow.mapSize.y = _viewportSize.y;\n        }\n      }\n      if (shadow.map === null && !shadow.isPointLightShadow && this.type === VSMShadowMap) {\n        const pars = {\n          minFilter: LinearFilter,\n          magFilter: LinearFilter,\n          format: RGBAFormat\n        };\n        shadow.map = new WebGLRenderTarget(_shadowMapSize.x, _shadowMapSize.y, pars);\n        shadow.map.texture.name = light.name + '.shadowMap';\n        shadow.mapPass = new WebGLRenderTarget(_shadowMapSize.x, _shadowMapSize.y, pars);\n        shadow.camera.updateProjectionMatrix();\n      }\n      if (shadow.map === null) {\n        const pars = {\n          minFilter: NearestFilter,\n          magFilter: NearestFilter,\n          format: RGBAFormat\n        };\n        shadow.map = new WebGLRenderTarget(_shadowMapSize.x, _shadowMapSize.y, pars);\n        shadow.map.texture.name = light.name + '.shadowMap';\n        shadow.camera.updateProjectionMatrix();\n      }\n      _renderer.setRenderTarget(shadow.map);\n      _renderer.clear();\n      const viewportCount = shadow.getViewportCount();\n      for (let vp = 0; vp < viewportCount; vp++) {\n        const viewport = shadow.getViewport(vp);\n        _viewport.set(_viewportSize.x * viewport.x, _viewportSize.y * viewport.y, _viewportSize.x * viewport.z, _viewportSize.y * viewport.w);\n        _state.viewport(_viewport);\n        shadow.updateMatrices(light, vp);\n        _frustum = shadow.getFrustum();\n        renderObject(scene, camera, shadow.camera, light, this.type);\n      }\n\n      // do blur pass for VSM\n\n      if (!shadow.isPointLightShadow && this.type === VSMShadowMap) {\n        VSMPass(shadow, camera);\n      }\n      shadow.needsUpdate = false;\n    }\n    scope.needsUpdate = false;\n    _renderer.setRenderTarget(currentRenderTarget, activeCubeFace, activeMipmapLevel);\n  };\n  function VSMPass(shadow, camera) {\n    const geometry = _objects.update(fullScreenMesh);\n\n    // vertical pass\n\n    shadowMaterialVertical.uniforms.shadow_pass.value = shadow.map.texture;\n    shadowMaterialVertical.uniforms.resolution.value = shadow.mapSize;\n    shadowMaterialVertical.uniforms.radius.value = shadow.radius;\n    _renderer.setRenderTarget(shadow.mapPass);\n    _renderer.clear();\n    _renderer.renderBufferDirect(camera, null, geometry, shadowMaterialVertical, fullScreenMesh, null);\n\n    // horizontal pass\n\n    shadowMaterialHorizontal.uniforms.shadow_pass.value = shadow.mapPass.texture;\n    shadowMaterialHorizontal.uniforms.resolution.value = shadow.mapSize;\n    shadowMaterialHorizontal.uniforms.radius.value = shadow.radius;\n    _renderer.setRenderTarget(shadow.map);\n    _renderer.clear();\n    _renderer.renderBufferDirect(camera, null, geometry, shadowMaterialHorizontal, fullScreenMesh, null);\n  }\n  function getDepthMaterialVariant(useMorphing, useSkinning, useInstancing) {\n    const index = useMorphing << 0 | useSkinning << 1 | useInstancing << 2;\n    let material = _depthMaterials[index];\n    if (material === undefined) {\n      material = new MeshDepthMaterial({\n        depthPacking: RGBADepthPacking,\n        morphTargets: useMorphing,\n        skinning: useSkinning\n      });\n      _depthMaterials[index] = material;\n    }\n    return material;\n  }\n  function getDistanceMaterialVariant(useMorphing, useSkinning, useInstancing) {\n    const index = useMorphing << 0 | useSkinning << 1 | useInstancing << 2;\n    let material = _distanceMaterials[index];\n    if (material === undefined) {\n      material = new MeshDistanceMaterial({\n        morphTargets: useMorphing,\n        skinning: useSkinning\n      });\n      _distanceMaterials[index] = material;\n    }\n    return material;\n  }\n  function getDepthMaterial(object, geometry, material, light, shadowCameraNear, shadowCameraFar, type) {\n    let result = null;\n    let getMaterialVariant = getDepthMaterialVariant;\n    let customMaterial = object.customDepthMaterial;\n    if (light.isPointLight === true) {\n      getMaterialVariant = getDistanceMaterialVariant;\n      customMaterial = object.customDistanceMaterial;\n    }\n    if (customMaterial === undefined) {\n      let useMorphing = false;\n      if (material.morphTargets === true) {\n        useMorphing = geometry.morphAttributes && geometry.morphAttributes.position && geometry.morphAttributes.position.length > 0;\n      }\n      let useSkinning = false;\n      if (object.isSkinnedMesh === true) {\n        if (material.skinning === true) {\n          useSkinning = true;\n        } else {\n          console.warn('THREE.WebGLShadowMap: THREE.SkinnedMesh with material.skinning set to false:', object);\n        }\n      }\n      const useInstancing = object.isInstancedMesh === true;\n      result = getMaterialVariant(useMorphing, useSkinning, useInstancing);\n    } else {\n      result = customMaterial;\n    }\n    if (_renderer.localClippingEnabled && material.clipShadows === true && material.clippingPlanes.length !== 0) {\n      // in this case we need a unique material instance reflecting the\n      // appropriate state\n\n      const keyA = result.uuid,\n        keyB = material.uuid;\n      let materialsForVariant = _materialCache[keyA];\n      if (materialsForVariant === undefined) {\n        materialsForVariant = {};\n        _materialCache[keyA] = materialsForVariant;\n      }\n      let cachedMaterial = materialsForVariant[keyB];\n      if (cachedMaterial === undefined) {\n        cachedMaterial = result.clone();\n        materialsForVariant[keyB] = cachedMaterial;\n      }\n      result = cachedMaterial;\n    }\n    result.visible = material.visible;\n    result.wireframe = material.wireframe;\n    if (type === VSMShadowMap) {\n      result.side = material.shadowSide !== null ? material.shadowSide : material.side;\n    } else {\n      result.side = material.shadowSide !== null ? material.shadowSide : shadowSide[material.side];\n    }\n    result.clipShadows = material.clipShadows;\n    result.clippingPlanes = material.clippingPlanes;\n    result.clipIntersection = material.clipIntersection;\n    result.wireframeLinewidth = material.wireframeLinewidth;\n    result.linewidth = material.linewidth;\n    if (light.isPointLight === true && result.isMeshDistanceMaterial === true) {\n      result.referencePosition.setFromMatrixPosition(light.matrixWorld);\n      result.nearDistance = shadowCameraNear;\n      result.farDistance = shadowCameraFar;\n    }\n    return result;\n  }\n  function renderObject(object, camera, shadowCamera, light, type) {\n    if (object.visible === false) return;\n    const visible = object.layers.test(camera.layers);\n    if (visible && (object.isMesh || object.isLine || object.isPoints)) {\n      if ((object.castShadow || object.receiveShadow && type === VSMShadowMap) && (!object.frustumCulled || _frustum.intersectsObject(object))) {\n        object.modelViewMatrix.multiplyMatrices(shadowCamera.matrixWorldInverse, object.matrixWorld);\n        const geometry = _objects.update(object);\n        const material = object.material;\n        if (Array.isArray(material)) {\n          const groups = geometry.groups;\n          for (let k = 0, kl = groups.length; k < kl; k++) {\n            const group = groups[k];\n            const groupMaterial = material[group.materialIndex];\n            if (groupMaterial && groupMaterial.visible) {\n              const depthMaterial = getDepthMaterial(object, geometry, groupMaterial, light, shadowCamera.near, shadowCamera.far, type);\n              _renderer.renderBufferDirect(shadowCamera, null, geometry, depthMaterial, object, group);\n            }\n          }\n        } else if (material.visible) {\n          const depthMaterial = getDepthMaterial(object, geometry, material, light, shadowCamera.near, shadowCamera.far, type);\n          _renderer.renderBufferDirect(shadowCamera, null, geometry, depthMaterial, object, null);\n        }\n      }\n    }\n    const children = object.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      renderObject(children[i], camera, shadowCamera, light, type);\n    }\n  }\n}\nfunction WebGLState(gl, extensions, capabilities) {\n  const isWebGL2 = capabilities.isWebGL2;\n  function ColorBuffer() {\n    let locked = false;\n    const color = new Vector4();\n    let currentColorMask = null;\n    const currentColorClear = new Vector4(0, 0, 0, 0);\n    return {\n      setMask: function (colorMask) {\n        if (currentColorMask !== colorMask && !locked) {\n          gl.colorMask(colorMask, colorMask, colorMask, colorMask);\n          currentColorMask = colorMask;\n        }\n      },\n      setLocked: function (lock) {\n        locked = lock;\n      },\n      setClear: function (r, g, b, a, premultipliedAlpha) {\n        if (premultipliedAlpha === true) {\n          r *= a;\n          g *= a;\n          b *= a;\n        }\n        color.set(r, g, b, a);\n        if (currentColorClear.equals(color) === false) {\n          gl.clearColor(r, g, b, a);\n          currentColorClear.copy(color);\n        }\n      },\n      reset: function () {\n        locked = false;\n        currentColorMask = null;\n        currentColorClear.set(-1, 0, 0, 0); // set to invalid state\n      }\n    };\n  }\n\n  function DepthBuffer() {\n    let locked = false;\n    let currentDepthMask = null;\n    let currentDepthFunc = null;\n    let currentDepthClear = null;\n    return {\n      setTest: function (depthTest) {\n        if (depthTest) {\n          enable(2929);\n        } else {\n          disable(2929);\n        }\n      },\n      setMask: function (depthMask) {\n        if (currentDepthMask !== depthMask && !locked) {\n          gl.depthMask(depthMask);\n          currentDepthMask = depthMask;\n        }\n      },\n      setFunc: function (depthFunc) {\n        if (currentDepthFunc !== depthFunc) {\n          if (depthFunc) {\n            switch (depthFunc) {\n              case NeverDepth:\n                gl.depthFunc(512);\n                break;\n              case AlwaysDepth:\n                gl.depthFunc(519);\n                break;\n              case LessDepth:\n                gl.depthFunc(513);\n                break;\n              case LessEqualDepth:\n                gl.depthFunc(515);\n                break;\n              case EqualDepth:\n                gl.depthFunc(514);\n                break;\n              case GreaterEqualDepth:\n                gl.depthFunc(518);\n                break;\n              case GreaterDepth:\n                gl.depthFunc(516);\n                break;\n              case NotEqualDepth:\n                gl.depthFunc(517);\n                break;\n              default:\n                gl.depthFunc(515);\n            }\n          } else {\n            gl.depthFunc(515);\n          }\n          currentDepthFunc = depthFunc;\n        }\n      },\n      setLocked: function (lock) {\n        locked = lock;\n      },\n      setClear: function (depth) {\n        if (currentDepthClear !== depth) {\n          gl.clearDepth(depth);\n          currentDepthClear = depth;\n        }\n      },\n      reset: function () {\n        locked = false;\n        currentDepthMask = null;\n        currentDepthFunc = null;\n        currentDepthClear = null;\n      }\n    };\n  }\n  function StencilBuffer() {\n    let locked = false;\n    let currentStencilMask = null;\n    let currentStencilFunc = null;\n    let currentStencilRef = null;\n    let currentStencilFuncMask = null;\n    let currentStencilFail = null;\n    let currentStencilZFail = null;\n    let currentStencilZPass = null;\n    let currentStencilClear = null;\n    return {\n      setTest: function (stencilTest) {\n        if (!locked) {\n          if (stencilTest) {\n            enable(2960);\n          } else {\n            disable(2960);\n          }\n        }\n      },\n      setMask: function (stencilMask) {\n        if (currentStencilMask !== stencilMask && !locked) {\n          gl.stencilMask(stencilMask);\n          currentStencilMask = stencilMask;\n        }\n      },\n      setFunc: function (stencilFunc, stencilRef, stencilMask) {\n        if (currentStencilFunc !== stencilFunc || currentStencilRef !== stencilRef || currentStencilFuncMask !== stencilMask) {\n          gl.stencilFunc(stencilFunc, stencilRef, stencilMask);\n          currentStencilFunc = stencilFunc;\n          currentStencilRef = stencilRef;\n          currentStencilFuncMask = stencilMask;\n        }\n      },\n      setOp: function (stencilFail, stencilZFail, stencilZPass) {\n        if (currentStencilFail !== stencilFail || currentStencilZFail !== stencilZFail || currentStencilZPass !== stencilZPass) {\n          gl.stencilOp(stencilFail, stencilZFail, stencilZPass);\n          currentStencilFail = stencilFail;\n          currentStencilZFail = stencilZFail;\n          currentStencilZPass = stencilZPass;\n        }\n      },\n      setLocked: function (lock) {\n        locked = lock;\n      },\n      setClear: function (stencil) {\n        if (currentStencilClear !== stencil) {\n          gl.clearStencil(stencil);\n          currentStencilClear = stencil;\n        }\n      },\n      reset: function () {\n        locked = false;\n        currentStencilMask = null;\n        currentStencilFunc = null;\n        currentStencilRef = null;\n        currentStencilFuncMask = null;\n        currentStencilFail = null;\n        currentStencilZFail = null;\n        currentStencilZPass = null;\n        currentStencilClear = null;\n      }\n    };\n  }\n\n  //\n\n  const colorBuffer = new ColorBuffer();\n  const depthBuffer = new DepthBuffer();\n  const stencilBuffer = new StencilBuffer();\n  let enabledCapabilities = {};\n  let currentProgram = null;\n  let currentBlendingEnabled = null;\n  let currentBlending = null;\n  let currentBlendEquation = null;\n  let currentBlendSrc = null;\n  let currentBlendDst = null;\n  let currentBlendEquationAlpha = null;\n  let currentBlendSrcAlpha = null;\n  let currentBlendDstAlpha = null;\n  let currentPremultipledAlpha = false;\n  let currentFlipSided = null;\n  let currentCullFace = null;\n  let currentLineWidth = null;\n  let currentPolygonOffsetFactor = null;\n  let currentPolygonOffsetUnits = null;\n  const maxTextures = gl.getParameter(35661);\n  let lineWidthAvailable = false;\n  let version = 0;\n  const glVersion = gl.getParameter(7938);\n  if (glVersion.indexOf('WebGL') !== -1) {\n    version = parseFloat(/^WebGL (\\d)/.exec(glVersion)[1]);\n    lineWidthAvailable = version >= 1.0;\n  } else if (glVersion.indexOf('OpenGL ES') !== -1) {\n    version = parseFloat(/^OpenGL ES (\\d)/.exec(glVersion)[1]);\n    lineWidthAvailable = version >= 2.0;\n  }\n  let currentTextureSlot = null;\n  let currentBoundTextures = {};\n  const currentScissor = new Vector4();\n  const currentViewport = new Vector4();\n  function createTexture(type, target, count) {\n    const data = new Uint8Array(4); // 4 is required to match default unpack alignment of 4.\n    const texture = gl.createTexture();\n    gl.bindTexture(type, texture);\n    gl.texParameteri(type, 10241, 9728);\n    gl.texParameteri(type, 10240, 9728);\n    for (let i = 0; i < count; i++) {\n      gl.texImage2D(target + i, 0, 6408, 1, 1, 0, 6408, 5121, data);\n    }\n    return texture;\n  }\n  const emptyTextures = {};\n  emptyTextures[3553] = createTexture(3553, 3553, 1);\n  emptyTextures[34067] = createTexture(34067, 34069, 6);\n\n  // init\n\n  colorBuffer.setClear(0, 0, 0, 1);\n  depthBuffer.setClear(1);\n  stencilBuffer.setClear(0);\n  enable(2929);\n  depthBuffer.setFunc(LessEqualDepth);\n  setFlipSided(false);\n  setCullFace(CullFaceBack);\n  enable(2884);\n  setBlending(NoBlending);\n\n  //\n\n  function enable(id) {\n    if (enabledCapabilities[id] !== true) {\n      gl.enable(id);\n      enabledCapabilities[id] = true;\n    }\n  }\n  function disable(id) {\n    if (enabledCapabilities[id] !== false) {\n      gl.disable(id);\n      enabledCapabilities[id] = false;\n    }\n  }\n  function useProgram(program) {\n    if (currentProgram !== program) {\n      gl.useProgram(program);\n      currentProgram = program;\n      return true;\n    }\n    return false;\n  }\n  const equationToGL = {\n    [AddEquation]: 32774,\n    [SubtractEquation]: 32778,\n    [ReverseSubtractEquation]: 32779\n  };\n  if (isWebGL2) {\n    equationToGL[MinEquation] = 32775;\n    equationToGL[MaxEquation] = 32776;\n  } else {\n    const extension = extensions.get('EXT_blend_minmax');\n    if (extension !== null) {\n      equationToGL[MinEquation] = extension.MIN_EXT;\n      equationToGL[MaxEquation] = extension.MAX_EXT;\n    }\n  }\n  const factorToGL = {\n    [ZeroFactor]: 0,\n    [OneFactor]: 1,\n    [SrcColorFactor]: 768,\n    [SrcAlphaFactor]: 770,\n    [SrcAlphaSaturateFactor]: 776,\n    [DstColorFactor]: 774,\n    [DstAlphaFactor]: 772,\n    [OneMinusSrcColorFactor]: 769,\n    [OneMinusSrcAlphaFactor]: 771,\n    [OneMinusDstColorFactor]: 775,\n    [OneMinusDstAlphaFactor]: 773\n  };\n  function setBlending(blending, blendEquation, blendSrc, blendDst, blendEquationAlpha, blendSrcAlpha, blendDstAlpha, premultipliedAlpha) {\n    if (blending === NoBlending) {\n      if (currentBlendingEnabled) {\n        disable(3042);\n        currentBlendingEnabled = false;\n      }\n      return;\n    }\n    if (!currentBlendingEnabled) {\n      enable(3042);\n      currentBlendingEnabled = true;\n    }\n    if (blending !== CustomBlending) {\n      if (blending !== currentBlending || premultipliedAlpha !== currentPremultipledAlpha) {\n        if (currentBlendEquation !== AddEquation || currentBlendEquationAlpha !== AddEquation) {\n          gl.blendEquation(32774);\n          currentBlendEquation = AddEquation;\n          currentBlendEquationAlpha = AddEquation;\n        }\n        if (premultipliedAlpha) {\n          switch (blending) {\n            case NormalBlending:\n              gl.blendFuncSeparate(1, 771, 1, 771);\n              break;\n            case AdditiveBlending:\n              gl.blendFunc(1, 1);\n              break;\n            case SubtractiveBlending:\n              gl.blendFuncSeparate(0, 0, 769, 771);\n              break;\n            case MultiplyBlending:\n              gl.blendFuncSeparate(0, 768, 0, 770);\n              break;\n            default:\n              console.error('THREE.WebGLState: Invalid blending: ', blending);\n              break;\n          }\n        } else {\n          switch (blending) {\n            case NormalBlending:\n              gl.blendFuncSeparate(770, 771, 1, 771);\n              break;\n            case AdditiveBlending:\n              gl.blendFunc(770, 1);\n              break;\n            case SubtractiveBlending:\n              gl.blendFunc(0, 769);\n              break;\n            case MultiplyBlending:\n              gl.blendFunc(0, 768);\n              break;\n            default:\n              console.error('THREE.WebGLState: Invalid blending: ', blending);\n              break;\n          }\n        }\n        currentBlendSrc = null;\n        currentBlendDst = null;\n        currentBlendSrcAlpha = null;\n        currentBlendDstAlpha = null;\n        currentBlending = blending;\n        currentPremultipledAlpha = premultipliedAlpha;\n      }\n      return;\n    }\n\n    // custom blending\n\n    blendEquationAlpha = blendEquationAlpha || blendEquation;\n    blendSrcAlpha = blendSrcAlpha || blendSrc;\n    blendDstAlpha = blendDstAlpha || blendDst;\n    if (blendEquation !== currentBlendEquation || blendEquationAlpha !== currentBlendEquationAlpha) {\n      gl.blendEquationSeparate(equationToGL[blendEquation], equationToGL[blendEquationAlpha]);\n      currentBlendEquation = blendEquation;\n      currentBlendEquationAlpha = blendEquationAlpha;\n    }\n    if (blendSrc !== currentBlendSrc || blendDst !== currentBlendDst || blendSrcAlpha !== currentBlendSrcAlpha || blendDstAlpha !== currentBlendDstAlpha) {\n      gl.blendFuncSeparate(factorToGL[blendSrc], factorToGL[blendDst], factorToGL[blendSrcAlpha], factorToGL[blendDstAlpha]);\n      currentBlendSrc = blendSrc;\n      currentBlendDst = blendDst;\n      currentBlendSrcAlpha = blendSrcAlpha;\n      currentBlendDstAlpha = blendDstAlpha;\n    }\n    currentBlending = blending;\n    currentPremultipledAlpha = null;\n  }\n  function setMaterial(material, frontFaceCW) {\n    material.side === DoubleSide ? disable(2884) : enable(2884);\n    let flipSided = material.side === BackSide;\n    if (frontFaceCW) flipSided = !flipSided;\n    setFlipSided(flipSided);\n    material.blending === NormalBlending && material.transparent === false ? setBlending(NoBlending) : setBlending(material.blending, material.blendEquation, material.blendSrc, material.blendDst, material.blendEquationAlpha, material.blendSrcAlpha, material.blendDstAlpha, material.premultipliedAlpha);\n    depthBuffer.setFunc(material.depthFunc);\n    depthBuffer.setTest(material.depthTest);\n    depthBuffer.setMask(material.depthWrite);\n    colorBuffer.setMask(material.colorWrite);\n    const stencilWrite = material.stencilWrite;\n    stencilBuffer.setTest(stencilWrite);\n    if (stencilWrite) {\n      stencilBuffer.setMask(material.stencilWriteMask);\n      stencilBuffer.setFunc(material.stencilFunc, material.stencilRef, material.stencilFuncMask);\n      stencilBuffer.setOp(material.stencilFail, material.stencilZFail, material.stencilZPass);\n    }\n    setPolygonOffset(material.polygonOffset, material.polygonOffsetFactor, material.polygonOffsetUnits);\n  }\n\n  //\n\n  function setFlipSided(flipSided) {\n    if (currentFlipSided !== flipSided) {\n      if (flipSided) {\n        gl.frontFace(2304);\n      } else {\n        gl.frontFace(2305);\n      }\n      currentFlipSided = flipSided;\n    }\n  }\n  function setCullFace(cullFace) {\n    if (cullFace !== CullFaceNone) {\n      enable(2884);\n      if (cullFace !== currentCullFace) {\n        if (cullFace === CullFaceBack) {\n          gl.cullFace(1029);\n        } else if (cullFace === CullFaceFront) {\n          gl.cullFace(1028);\n        } else {\n          gl.cullFace(1032);\n        }\n      }\n    } else {\n      disable(2884);\n    }\n    currentCullFace = cullFace;\n  }\n  function setLineWidth(width) {\n    if (width !== currentLineWidth) {\n      if (lineWidthAvailable) gl.lineWidth(width);\n      currentLineWidth = width;\n    }\n  }\n  function setPolygonOffset(polygonOffset, factor, units) {\n    if (polygonOffset) {\n      enable(32823);\n      if (currentPolygonOffsetFactor !== factor || currentPolygonOffsetUnits !== units) {\n        gl.polygonOffset(factor, units);\n        currentPolygonOffsetFactor = factor;\n        currentPolygonOffsetUnits = units;\n      }\n    } else {\n      disable(32823);\n    }\n  }\n  function setScissorTest(scissorTest) {\n    if (scissorTest) {\n      enable(3089);\n    } else {\n      disable(3089);\n    }\n  }\n\n  // texture\n\n  function activeTexture(webglSlot) {\n    if (webglSlot === undefined) webglSlot = 33984 + maxTextures - 1;\n    if (currentTextureSlot !== webglSlot) {\n      gl.activeTexture(webglSlot);\n      currentTextureSlot = webglSlot;\n    }\n  }\n  function bindTexture(webglType, webglTexture) {\n    if (currentTextureSlot === null) {\n      activeTexture();\n    }\n    let boundTexture = currentBoundTextures[currentTextureSlot];\n    if (boundTexture === undefined) {\n      boundTexture = {\n        type: undefined,\n        texture: undefined\n      };\n      currentBoundTextures[currentTextureSlot] = boundTexture;\n    }\n    if (boundTexture.type !== webglType || boundTexture.texture !== webglTexture) {\n      gl.bindTexture(webglType, webglTexture || emptyTextures[webglType]);\n      boundTexture.type = webglType;\n      boundTexture.texture = webglTexture;\n    }\n  }\n  function unbindTexture() {\n    const boundTexture = currentBoundTextures[currentTextureSlot];\n    if (boundTexture !== undefined && boundTexture.type !== undefined) {\n      gl.bindTexture(boundTexture.type, null);\n      boundTexture.type = undefined;\n      boundTexture.texture = undefined;\n    }\n  }\n  function compressedTexImage2D() {\n    try {\n      gl.compressedTexImage2D.apply(gl, arguments);\n    } catch (error) {\n      console.error('THREE.WebGLState:', error);\n    }\n  }\n  function texImage2D() {\n    try {\n      gl.texImage2D.apply(gl, arguments);\n    } catch (error) {\n      console.error('THREE.WebGLState:', error);\n    }\n  }\n  function texImage3D() {\n    try {\n      gl.texImage3D.apply(gl, arguments);\n    } catch (error) {\n      console.error('THREE.WebGLState:', error);\n    }\n  }\n\n  //\n\n  function scissor(scissor) {\n    if (currentScissor.equals(scissor) === false) {\n      gl.scissor(scissor.x, scissor.y, scissor.z, scissor.w);\n      currentScissor.copy(scissor);\n    }\n  }\n  function viewport(viewport) {\n    if (currentViewport.equals(viewport) === false) {\n      gl.viewport(viewport.x, viewport.y, viewport.z, viewport.w);\n      currentViewport.copy(viewport);\n    }\n  }\n\n  //\n\n  function reset() {\n    enabledCapabilities = {};\n    currentTextureSlot = null;\n    currentBoundTextures = {};\n    currentProgram = null;\n    currentBlendingEnabled = null;\n    currentBlending = null;\n    currentBlendEquation = null;\n    currentBlendSrc = null;\n    currentBlendDst = null;\n    currentBlendEquationAlpha = null;\n    currentBlendSrcAlpha = null;\n    currentBlendDstAlpha = null;\n    currentPremultipledAlpha = false;\n    currentFlipSided = null;\n    currentCullFace = null;\n    currentLineWidth = null;\n    currentPolygonOffsetFactor = null;\n    currentPolygonOffsetUnits = null;\n    colorBuffer.reset();\n    depthBuffer.reset();\n    stencilBuffer.reset();\n  }\n  return {\n    buffers: {\n      color: colorBuffer,\n      depth: depthBuffer,\n      stencil: stencilBuffer\n    },\n    enable: enable,\n    disable: disable,\n    useProgram: useProgram,\n    setBlending: setBlending,\n    setMaterial: setMaterial,\n    setFlipSided: setFlipSided,\n    setCullFace: setCullFace,\n    setLineWidth: setLineWidth,\n    setPolygonOffset: setPolygonOffset,\n    setScissorTest: setScissorTest,\n    activeTexture: activeTexture,\n    bindTexture: bindTexture,\n    unbindTexture: unbindTexture,\n    compressedTexImage2D: compressedTexImage2D,\n    texImage2D: texImage2D,\n    texImage3D: texImage3D,\n    scissor: scissor,\n    viewport: viewport,\n    reset: reset\n  };\n}\nfunction WebGLTextures(_gl, extensions, state, properties, capabilities, utils, info) {\n  const isWebGL2 = capabilities.isWebGL2;\n  const maxTextures = capabilities.maxTextures;\n  const maxCubemapSize = capabilities.maxCubemapSize;\n  const maxTextureSize = capabilities.maxTextureSize;\n  const maxSamples = capabilities.maxSamples;\n  const _videoTextures = new WeakMap();\n  let _canvas;\n\n  // cordova iOS (as of 5.0) still uses UIWebView, which provides OffscreenCanvas,\n  // also OffscreenCanvas.getContext(\"webgl\"), but not OffscreenCanvas.getContext(\"2d\")!\n  // Some implementations may only implement OffscreenCanvas partially (e.g. lacking 2d).\n\n  let useOffscreenCanvas = false;\n  try {\n    useOffscreenCanvas = typeof OffscreenCanvas !== 'undefined' && new OffscreenCanvas(1, 1).getContext('2d') !== null;\n  } catch (err) {\n\n    // Ignore any errors\n  }\n  function createCanvas(width, height) {\n    // Use OffscreenCanvas when available. Specially needed in web workers\n\n    return useOffscreenCanvas ? new OffscreenCanvas(width, height) : document.createElementNS('http://www.w3.org/1999/xhtml', 'canvas');\n  }\n  function resizeImage(image, needsPowerOfTwo, needsNewCanvas, maxSize) {\n    let scale = 1;\n\n    // handle case if texture exceeds max size\n\n    if (image.width > maxSize || image.height > maxSize) {\n      scale = maxSize / Math.max(image.width, image.height);\n    }\n\n    // only perform resize if necessary\n\n    if (scale < 1 || needsPowerOfTwo === true) {\n      // only perform resize for certain image types\n\n      if (typeof HTMLImageElement !== 'undefined' && image instanceof HTMLImageElement || typeof HTMLCanvasElement !== 'undefined' && image instanceof HTMLCanvasElement || typeof ImageBitmap !== 'undefined' && image instanceof ImageBitmap) {\n        const floor = needsPowerOfTwo ? MathUtils.floorPowerOfTwo : Math.floor;\n        const width = floor(scale * image.width);\n        const height = floor(scale * image.height);\n        if (_canvas === undefined) _canvas = createCanvas(width, height);\n\n        // cube textures can't reuse the same canvas\n\n        const canvas = needsNewCanvas ? createCanvas(width, height) : _canvas;\n        canvas.width = width;\n        canvas.height = height;\n        const context = canvas.getContext('2d');\n        context.drawImage(image, 0, 0, width, height);\n        console.warn('THREE.WebGLRenderer: Texture has been resized from (' + image.width + 'x' + image.height + ') to (' + width + 'x' + height + ').');\n        return canvas;\n      } else {\n        if ('data' in image) {\n          console.warn('THREE.WebGLRenderer: Image in DataTexture is too big (' + image.width + 'x' + image.height + ').');\n        }\n        return image;\n      }\n    }\n    return image;\n  }\n  function isPowerOfTwo(image) {\n    return MathUtils.isPowerOfTwo(image.width) && MathUtils.isPowerOfTwo(image.height);\n  }\n  function textureNeedsPowerOfTwo(texture) {\n    if (isWebGL2) return false;\n    return texture.wrapS !== ClampToEdgeWrapping || texture.wrapT !== ClampToEdgeWrapping || texture.minFilter !== NearestFilter && texture.minFilter !== LinearFilter;\n  }\n  function textureNeedsGenerateMipmaps(texture, supportsMips) {\n    return texture.generateMipmaps && supportsMips && texture.minFilter !== NearestFilter && texture.minFilter !== LinearFilter;\n  }\n  function generateMipmap(target, texture, width, height) {\n    _gl.generateMipmap(target);\n    const textureProperties = properties.get(texture);\n\n    // Note: Math.log( x ) * Math.LOG2E used instead of Math.log2( x ) which is not supported by IE11\n    textureProperties.__maxMipLevel = Math.log(Math.max(width, height)) * Math.LOG2E;\n  }\n  function getInternalFormat(internalFormatName, glFormat, glType) {\n    if (isWebGL2 === false) return glFormat;\n    if (internalFormatName !== null) {\n      if (_gl[internalFormatName] !== undefined) return _gl[internalFormatName];\n      console.warn('THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format \\'' + internalFormatName + '\\'');\n    }\n    let internalFormat = glFormat;\n    if (glFormat === 6403) {\n      if (glType === 5126) internalFormat = 33326;\n      if (glType === 5131) internalFormat = 33325;\n      if (glType === 5121) internalFormat = 33321;\n    }\n    if (glFormat === 6407) {\n      if (glType === 5126) internalFormat = 34837;\n      if (glType === 5131) internalFormat = 34843;\n      if (glType === 5121) internalFormat = 32849;\n    }\n    if (glFormat === 6408) {\n      if (glType === 5126) internalFormat = 34836;\n      if (glType === 5131) internalFormat = 34842;\n      if (glType === 5121) internalFormat = 32856;\n    }\n    if (internalFormat === 33325 || internalFormat === 33326 || internalFormat === 34842 || internalFormat === 34836) {\n      extensions.get('EXT_color_buffer_float');\n    }\n    return internalFormat;\n  }\n\n  // Fallback filters for non-power-of-2 textures\n\n  function filterFallback(f) {\n    if (f === NearestFilter || f === NearestMipmapNearestFilter || f === NearestMipmapLinearFilter) {\n      return 9728;\n    }\n    return 9729;\n  }\n\n  //\n\n  function onTextureDispose(event) {\n    const texture = event.target;\n    texture.removeEventListener('dispose', onTextureDispose);\n    deallocateTexture(texture);\n    if (texture.isVideoTexture) {\n      _videoTextures.delete(texture);\n    }\n    info.memory.textures--;\n  }\n  function onRenderTargetDispose(event) {\n    const renderTarget = event.target;\n    renderTarget.removeEventListener('dispose', onRenderTargetDispose);\n    deallocateRenderTarget(renderTarget);\n    info.memory.textures--;\n  }\n\n  //\n\n  function deallocateTexture(texture) {\n    const textureProperties = properties.get(texture);\n    if (textureProperties.__webglInit === undefined) return;\n    _gl.deleteTexture(textureProperties.__webglTexture);\n    properties.remove(texture);\n  }\n  function deallocateRenderTarget(renderTarget) {\n    const renderTargetProperties = properties.get(renderTarget);\n    const textureProperties = properties.get(renderTarget.texture);\n    if (!renderTarget) return;\n    if (textureProperties.__webglTexture !== undefined) {\n      _gl.deleteTexture(textureProperties.__webglTexture);\n    }\n    if (renderTarget.depthTexture) {\n      renderTarget.depthTexture.dispose();\n    }\n    if (renderTarget.isWebGLCubeRenderTarget) {\n      for (let i = 0; i < 6; i++) {\n        _gl.deleteFramebuffer(renderTargetProperties.__webglFramebuffer[i]);\n        if (renderTargetProperties.__webglDepthbuffer) _gl.deleteRenderbuffer(renderTargetProperties.__webglDepthbuffer[i]);\n      }\n    } else {\n      _gl.deleteFramebuffer(renderTargetProperties.__webglFramebuffer);\n      if (renderTargetProperties.__webglDepthbuffer) _gl.deleteRenderbuffer(renderTargetProperties.__webglDepthbuffer);\n      if (renderTargetProperties.__webglMultisampledFramebuffer) _gl.deleteFramebuffer(renderTargetProperties.__webglMultisampledFramebuffer);\n      if (renderTargetProperties.__webglColorRenderbuffer) _gl.deleteRenderbuffer(renderTargetProperties.__webglColorRenderbuffer);\n      if (renderTargetProperties.__webglDepthRenderbuffer) _gl.deleteRenderbuffer(renderTargetProperties.__webglDepthRenderbuffer);\n    }\n    properties.remove(renderTarget.texture);\n    properties.remove(renderTarget);\n  }\n\n  //\n\n  let textureUnits = 0;\n  function resetTextureUnits() {\n    textureUnits = 0;\n  }\n  function allocateTextureUnit() {\n    const textureUnit = textureUnits;\n    if (textureUnit >= maxTextures) {\n      console.warn('THREE.WebGLTextures: Trying to use ' + textureUnit + ' texture units while this GPU supports only ' + maxTextures);\n    }\n    textureUnits += 1;\n    return textureUnit;\n  }\n\n  //\n\n  function setTexture2D(texture, slot) {\n    const textureProperties = properties.get(texture);\n    if (texture.isVideoTexture) updateVideoTexture(texture);\n    if (texture.version > 0 && textureProperties.__version !== texture.version) {\n      const image = texture.image;\n      if (image === undefined) {\n        console.warn('THREE.WebGLRenderer: Texture marked for update but image is undefined');\n      } else if (image.complete === false) {\n        console.warn('THREE.WebGLRenderer: Texture marked for update but image is incomplete');\n      } else {\n        uploadTexture(textureProperties, texture, slot);\n        return;\n      }\n    }\n    state.activeTexture(33984 + slot);\n    state.bindTexture(3553, textureProperties.__webglTexture);\n  }\n  function setTexture2DArray(texture, slot) {\n    const textureProperties = properties.get(texture);\n    if (texture.version > 0 && textureProperties.__version !== texture.version) {\n      uploadTexture(textureProperties, texture, slot);\n      return;\n    }\n    state.activeTexture(33984 + slot);\n    state.bindTexture(35866, textureProperties.__webglTexture);\n  }\n  function setTexture3D(texture, slot) {\n    const textureProperties = properties.get(texture);\n    if (texture.version > 0 && textureProperties.__version !== texture.version) {\n      uploadTexture(textureProperties, texture, slot);\n      return;\n    }\n    state.activeTexture(33984 + slot);\n    state.bindTexture(32879, textureProperties.__webglTexture);\n  }\n  function setTextureCube(texture, slot) {\n    const textureProperties = properties.get(texture);\n    if (texture.version > 0 && textureProperties.__version !== texture.version) {\n      uploadCubeTexture(textureProperties, texture, slot);\n      return;\n    }\n    state.activeTexture(33984 + slot);\n    state.bindTexture(34067, textureProperties.__webglTexture);\n  }\n  const wrappingToGL = {\n    [RepeatWrapping]: 10497,\n    [ClampToEdgeWrapping]: 33071,\n    [MirroredRepeatWrapping]: 33648\n  };\n  const filterToGL = {\n    [NearestFilter]: 9728,\n    [NearestMipmapNearestFilter]: 9984,\n    [NearestMipmapLinearFilter]: 9986,\n    [LinearFilter]: 9729,\n    [LinearMipmapNearestFilter]: 9985,\n    [LinearMipmapLinearFilter]: 9987\n  };\n  function setTextureParameters(textureType, texture, supportsMips) {\n    if (supportsMips) {\n      _gl.texParameteri(textureType, 10242, wrappingToGL[texture.wrapS]);\n      _gl.texParameteri(textureType, 10243, wrappingToGL[texture.wrapT]);\n      if (textureType === 32879 || textureType === 35866) {\n        _gl.texParameteri(textureType, 32882, wrappingToGL[texture.wrapR]);\n      }\n      _gl.texParameteri(textureType, 10240, filterToGL[texture.magFilter]);\n      _gl.texParameteri(textureType, 10241, filterToGL[texture.minFilter]);\n    } else {\n      _gl.texParameteri(textureType, 10242, 33071);\n      _gl.texParameteri(textureType, 10243, 33071);\n      if (textureType === 32879 || textureType === 35866) {\n        _gl.texParameteri(textureType, 32882, 33071);\n      }\n      if (texture.wrapS !== ClampToEdgeWrapping || texture.wrapT !== ClampToEdgeWrapping) {\n        console.warn('THREE.WebGLRenderer: Texture is not power of two. Texture.wrapS and Texture.wrapT should be set to THREE.ClampToEdgeWrapping.');\n      }\n      _gl.texParameteri(textureType, 10240, filterFallback(texture.magFilter));\n      _gl.texParameteri(textureType, 10241, filterFallback(texture.minFilter));\n      if (texture.minFilter !== NearestFilter && texture.minFilter !== LinearFilter) {\n        console.warn('THREE.WebGLRenderer: Texture is not power of two. Texture.minFilter should be set to THREE.NearestFilter or THREE.LinearFilter.');\n      }\n    }\n    const extension = extensions.get('EXT_texture_filter_anisotropic');\n    if (extension) {\n      if (texture.type === FloatType && extensions.get('OES_texture_float_linear') === null) return;\n      if (texture.type === HalfFloatType && (isWebGL2 || extensions.get('OES_texture_half_float_linear')) === null) return;\n      if (texture.anisotropy > 1 || properties.get(texture).__currentAnisotropy) {\n        _gl.texParameterf(textureType, extension.TEXTURE_MAX_ANISOTROPY_EXT, Math.min(texture.anisotropy, capabilities.getMaxAnisotropy()));\n        properties.get(texture).__currentAnisotropy = texture.anisotropy;\n      }\n    }\n  }\n  function initTexture(textureProperties, texture) {\n    if (textureProperties.__webglInit === undefined) {\n      textureProperties.__webglInit = true;\n      texture.addEventListener('dispose', onTextureDispose);\n      textureProperties.__webglTexture = _gl.createTexture();\n      info.memory.textures++;\n    }\n  }\n  function uploadTexture(textureProperties, texture, slot) {\n    let textureType = 3553;\n    if (texture.isDataTexture2DArray) textureType = 35866;\n    if (texture.isDataTexture3D) textureType = 32879;\n    initTexture(textureProperties, texture);\n    state.activeTexture(33984 + slot);\n    state.bindTexture(textureType, textureProperties.__webglTexture);\n    _gl.pixelStorei(37440, texture.flipY);\n    _gl.pixelStorei(37441, texture.premultiplyAlpha);\n    _gl.pixelStorei(3317, texture.unpackAlignment);\n    const needsPowerOfTwo = textureNeedsPowerOfTwo(texture) && isPowerOfTwo(texture.image) === false;\n    const image = resizeImage(texture.image, needsPowerOfTwo, false, maxTextureSize);\n    const supportsMips = isPowerOfTwo(image) || isWebGL2,\n      glFormat = utils.convert(texture.format);\n    let glType = utils.convert(texture.type),\n      glInternalFormat = getInternalFormat(texture.internalFormat, glFormat, glType);\n    setTextureParameters(textureType, texture, supportsMips);\n    let mipmap;\n    const mipmaps = texture.mipmaps;\n    if (texture.isDepthTexture) {\n      // populate depth texture with dummy data\n\n      glInternalFormat = 6402;\n      if (isWebGL2) {\n        if (texture.type === FloatType) {\n          glInternalFormat = 36012;\n        } else if (texture.type === UnsignedIntType) {\n          glInternalFormat = 33190;\n        } else if (texture.type === UnsignedInt248Type) {\n          glInternalFormat = 35056;\n        } else {\n          glInternalFormat = 33189; // WebGL2 requires sized internalformat for glTexImage2D\n        }\n      } else {\n        if (texture.type === FloatType) {\n          console.error('WebGLRenderer: Floating point depth texture requires WebGL2.');\n        }\n      }\n\n      // validation checks for WebGL 1\n\n      if (texture.format === DepthFormat && glInternalFormat === 6402) {\n        // The error INVALID_OPERATION is generated by texImage2D if format and internalformat are\n        // DEPTH_COMPONENT and type is not UNSIGNED_SHORT or UNSIGNED_INT\n        // (https://www.khronos.org/registry/webgl/extensions/WEBGL_depth_texture/)\n        if (texture.type !== UnsignedShortType && texture.type !== UnsignedIntType) {\n          console.warn('THREE.WebGLRenderer: Use UnsignedShortType or UnsignedIntType for DepthFormat DepthTexture.');\n          texture.type = UnsignedShortType;\n          glType = utils.convert(texture.type);\n        }\n      }\n      if (texture.format === DepthStencilFormat && glInternalFormat === 6402) {\n        // Depth stencil textures need the DEPTH_STENCIL internal format\n        // (https://www.khronos.org/registry/webgl/extensions/WEBGL_depth_texture/)\n        glInternalFormat = 34041;\n\n        // The error INVALID_OPERATION is generated by texImage2D if format and internalformat are\n        // DEPTH_STENCIL and type is not UNSIGNED_INT_24_8_WEBGL.\n        // (https://www.khronos.org/registry/webgl/extensions/WEBGL_depth_texture/)\n        if (texture.type !== UnsignedInt248Type) {\n          console.warn('THREE.WebGLRenderer: Use UnsignedInt248Type for DepthStencilFormat DepthTexture.');\n          texture.type = UnsignedInt248Type;\n          glType = utils.convert(texture.type);\n        }\n      }\n\n      //\n\n      state.texImage2D(3553, 0, glInternalFormat, image.width, image.height, 0, glFormat, glType, null);\n    } else if (texture.isDataTexture) {\n      // use manually created mipmaps if available\n      // if there are no manual mipmaps\n      // set 0 level mipmap and then use GL to generate other mipmap levels\n\n      if (mipmaps.length > 0 && supportsMips) {\n        for (let i = 0, il = mipmaps.length; i < il; i++) {\n          mipmap = mipmaps[i];\n          state.texImage2D(3553, i, glInternalFormat, mipmap.width, mipmap.height, 0, glFormat, glType, mipmap.data);\n        }\n        texture.generateMipmaps = false;\n        textureProperties.__maxMipLevel = mipmaps.length - 1;\n      } else {\n        state.texImage2D(3553, 0, glInternalFormat, image.width, image.height, 0, glFormat, glType, image.data);\n        textureProperties.__maxMipLevel = 0;\n      }\n    } else if (texture.isCompressedTexture) {\n      for (let i = 0, il = mipmaps.length; i < il; i++) {\n        mipmap = mipmaps[i];\n        if (texture.format !== RGBAFormat && texture.format !== RGBFormat) {\n          if (glFormat !== null) {\n            state.compressedTexImage2D(3553, i, glInternalFormat, mipmap.width, mipmap.height, 0, mipmap.data);\n          } else {\n            console.warn('THREE.WebGLRenderer: Attempt to load unsupported compressed texture format in .uploadTexture()');\n          }\n        } else {\n          state.texImage2D(3553, i, glInternalFormat, mipmap.width, mipmap.height, 0, glFormat, glType, mipmap.data);\n        }\n      }\n      textureProperties.__maxMipLevel = mipmaps.length - 1;\n    } else if (texture.isDataTexture2DArray) {\n      state.texImage3D(35866, 0, glInternalFormat, image.width, image.height, image.depth, 0, glFormat, glType, image.data);\n      textureProperties.__maxMipLevel = 0;\n    } else if (texture.isDataTexture3D) {\n      state.texImage3D(32879, 0, glInternalFormat, image.width, image.height, image.depth, 0, glFormat, glType, image.data);\n      textureProperties.__maxMipLevel = 0;\n    } else {\n      // regular Texture (image, video, canvas)\n\n      // use manually created mipmaps if available\n      // if there are no manual mipmaps\n      // set 0 level mipmap and then use GL to generate other mipmap levels\n\n      if (mipmaps.length > 0 && supportsMips) {\n        for (let i = 0, il = mipmaps.length; i < il; i++) {\n          mipmap = mipmaps[i];\n          state.texImage2D(3553, i, glInternalFormat, glFormat, glType, mipmap);\n        }\n        texture.generateMipmaps = false;\n        textureProperties.__maxMipLevel = mipmaps.length - 1;\n      } else {\n        state.texImage2D(3553, 0, glInternalFormat, glFormat, glType, image);\n        textureProperties.__maxMipLevel = 0;\n      }\n    }\n    if (textureNeedsGenerateMipmaps(texture, supportsMips)) {\n      generateMipmap(textureType, texture, image.width, image.height);\n    }\n    textureProperties.__version = texture.version;\n    if (texture.onUpdate) texture.onUpdate(texture);\n  }\n  function uploadCubeTexture(textureProperties, texture, slot) {\n    if (texture.image.length !== 6) return;\n    initTexture(textureProperties, texture);\n    state.activeTexture(33984 + slot);\n    state.bindTexture(34067, textureProperties.__webglTexture);\n    _gl.pixelStorei(37440, texture.flipY);\n    _gl.pixelStorei(37441, texture.premultiplyAlpha);\n    _gl.pixelStorei(3317, texture.unpackAlignment);\n    const isCompressed = texture && (texture.isCompressedTexture || texture.image[0].isCompressedTexture);\n    const isDataTexture = texture.image[0] && texture.image[0].isDataTexture;\n    const cubeImage = [];\n    for (let i = 0; i < 6; i++) {\n      if (!isCompressed && !isDataTexture) {\n        cubeImage[i] = resizeImage(texture.image[i], false, true, maxCubemapSize);\n      } else {\n        cubeImage[i] = isDataTexture ? texture.image[i].image : texture.image[i];\n      }\n    }\n    const image = cubeImage[0],\n      supportsMips = isPowerOfTwo(image) || isWebGL2,\n      glFormat = utils.convert(texture.format),\n      glType = utils.convert(texture.type),\n      glInternalFormat = getInternalFormat(texture.internalFormat, glFormat, glType);\n    setTextureParameters(34067, texture, supportsMips);\n    let mipmaps;\n    if (isCompressed) {\n      for (let i = 0; i < 6; i++) {\n        mipmaps = cubeImage[i].mipmaps;\n        for (let j = 0; j < mipmaps.length; j++) {\n          const mipmap = mipmaps[j];\n          if (texture.format !== RGBAFormat && texture.format !== RGBFormat) {\n            if (glFormat !== null) {\n              state.compressedTexImage2D(34069 + i, j, glInternalFormat, mipmap.width, mipmap.height, 0, mipmap.data);\n            } else {\n              console.warn('THREE.WebGLRenderer: Attempt to load unsupported compressed texture format in .setTextureCube()');\n            }\n          } else {\n            state.texImage2D(34069 + i, j, glInternalFormat, mipmap.width, mipmap.height, 0, glFormat, glType, mipmap.data);\n          }\n        }\n      }\n      textureProperties.__maxMipLevel = mipmaps.length - 1;\n    } else {\n      mipmaps = texture.mipmaps;\n      for (let i = 0; i < 6; i++) {\n        if (isDataTexture) {\n          state.texImage2D(34069 + i, 0, glInternalFormat, cubeImage[i].width, cubeImage[i].height, 0, glFormat, glType, cubeImage[i].data);\n          for (let j = 0; j < mipmaps.length; j++) {\n            const mipmap = mipmaps[j];\n            const mipmapImage = mipmap.image[i].image;\n            state.texImage2D(34069 + i, j + 1, glInternalFormat, mipmapImage.width, mipmapImage.height, 0, glFormat, glType, mipmapImage.data);\n          }\n        } else {\n          state.texImage2D(34069 + i, 0, glInternalFormat, glFormat, glType, cubeImage[i]);\n          for (let j = 0; j < mipmaps.length; j++) {\n            const mipmap = mipmaps[j];\n            state.texImage2D(34069 + i, j + 1, glInternalFormat, glFormat, glType, mipmap.image[i]);\n          }\n        }\n      }\n      textureProperties.__maxMipLevel = mipmaps.length;\n    }\n    if (textureNeedsGenerateMipmaps(texture, supportsMips)) {\n      // We assume images for cube map have the same size.\n      generateMipmap(34067, texture, image.width, image.height);\n    }\n    textureProperties.__version = texture.version;\n    if (texture.onUpdate) texture.onUpdate(texture);\n  }\n\n  // Render targets\n\n  // Setup storage for target texture and bind it to correct framebuffer\n  function setupFrameBufferTexture(framebuffer, renderTarget, attachment, textureTarget) {\n    const glFormat = utils.convert(renderTarget.texture.format);\n    const glType = utils.convert(renderTarget.texture.type);\n    const glInternalFormat = getInternalFormat(renderTarget.texture.internalFormat, glFormat, glType);\n    state.texImage2D(textureTarget, 0, glInternalFormat, renderTarget.width, renderTarget.height, 0, glFormat, glType, null);\n    _gl.bindFramebuffer(36160, framebuffer);\n    _gl.framebufferTexture2D(36160, attachment, textureTarget, properties.get(renderTarget.texture).__webglTexture, 0);\n    _gl.bindFramebuffer(36160, null);\n  }\n\n  // Setup storage for internal depth/stencil buffers and bind to correct framebuffer\n  function setupRenderBufferStorage(renderbuffer, renderTarget, isMultisample) {\n    _gl.bindRenderbuffer(36161, renderbuffer);\n    if (renderTarget.depthBuffer && !renderTarget.stencilBuffer) {\n      let glInternalFormat = 33189;\n      if (isMultisample) {\n        const depthTexture = renderTarget.depthTexture;\n        if (depthTexture && depthTexture.isDepthTexture) {\n          if (depthTexture.type === FloatType) {\n            glInternalFormat = 36012;\n          } else if (depthTexture.type === UnsignedIntType) {\n            glInternalFormat = 33190;\n          }\n        }\n        const samples = getRenderTargetSamples(renderTarget);\n        _gl.renderbufferStorageMultisample(36161, samples, glInternalFormat, renderTarget.width, renderTarget.height);\n      } else {\n        _gl.renderbufferStorage(36161, glInternalFormat, renderTarget.width, renderTarget.height);\n      }\n      _gl.framebufferRenderbuffer(36160, 36096, 36161, renderbuffer);\n    } else if (renderTarget.depthBuffer && renderTarget.stencilBuffer) {\n      if (isMultisample) {\n        const samples = getRenderTargetSamples(renderTarget);\n        _gl.renderbufferStorageMultisample(36161, samples, 35056, renderTarget.width, renderTarget.height);\n      } else {\n        _gl.renderbufferStorage(36161, 34041, renderTarget.width, renderTarget.height);\n      }\n      _gl.framebufferRenderbuffer(36160, 33306, 36161, renderbuffer);\n    } else {\n      const glFormat = utils.convert(renderTarget.texture.format);\n      const glType = utils.convert(renderTarget.texture.type);\n      const glInternalFormat = getInternalFormat(renderTarget.texture.internalFormat, glFormat, glType);\n      if (isMultisample) {\n        const samples = getRenderTargetSamples(renderTarget);\n        _gl.renderbufferStorageMultisample(36161, samples, glInternalFormat, renderTarget.width, renderTarget.height);\n      } else {\n        _gl.renderbufferStorage(36161, glInternalFormat, renderTarget.width, renderTarget.height);\n      }\n    }\n    _gl.bindRenderbuffer(36161, null);\n  }\n\n  // Setup resources for a Depth Texture for a FBO (needs an extension)\n  function setupDepthTexture(framebuffer, renderTarget) {\n    const isCube = renderTarget && renderTarget.isWebGLCubeRenderTarget;\n    if (isCube) throw new Error('Depth Texture with cube render targets is not supported');\n    _gl.bindFramebuffer(36160, framebuffer);\n    if (!(renderTarget.depthTexture && renderTarget.depthTexture.isDepthTexture)) {\n      throw new Error('renderTarget.depthTexture must be an instance of THREE.DepthTexture');\n    }\n\n    // upload an empty depth texture with framebuffer size\n    if (!properties.get(renderTarget.depthTexture).__webglTexture || renderTarget.depthTexture.image.width !== renderTarget.width || renderTarget.depthTexture.image.height !== renderTarget.height) {\n      renderTarget.depthTexture.image.width = renderTarget.width;\n      renderTarget.depthTexture.image.height = renderTarget.height;\n      renderTarget.depthTexture.needsUpdate = true;\n    }\n    setTexture2D(renderTarget.depthTexture, 0);\n    const webglDepthTexture = properties.get(renderTarget.depthTexture).__webglTexture;\n    if (renderTarget.depthTexture.format === DepthFormat) {\n      _gl.framebufferTexture2D(36160, 36096, 3553, webglDepthTexture, 0);\n    } else if (renderTarget.depthTexture.format === DepthStencilFormat) {\n      _gl.framebufferTexture2D(36160, 33306, 3553, webglDepthTexture, 0);\n    } else {\n      throw new Error('Unknown depthTexture format');\n    }\n  }\n\n  // Setup GL resources for a non-texture depth buffer\n  function setupDepthRenderbuffer(renderTarget) {\n    const renderTargetProperties = properties.get(renderTarget);\n    const isCube = renderTarget.isWebGLCubeRenderTarget === true;\n    if (renderTarget.depthTexture) {\n      if (isCube) throw new Error('target.depthTexture not supported in Cube render targets');\n      setupDepthTexture(renderTargetProperties.__webglFramebuffer, renderTarget);\n    } else {\n      if (isCube) {\n        renderTargetProperties.__webglDepthbuffer = [];\n        for (let i = 0; i < 6; i++) {\n          _gl.bindFramebuffer(36160, renderTargetProperties.__webglFramebuffer[i]);\n          renderTargetProperties.__webglDepthbuffer[i] = _gl.createRenderbuffer();\n          setupRenderBufferStorage(renderTargetProperties.__webglDepthbuffer[i], renderTarget, false);\n        }\n      } else {\n        _gl.bindFramebuffer(36160, renderTargetProperties.__webglFramebuffer);\n        renderTargetProperties.__webglDepthbuffer = _gl.createRenderbuffer();\n        setupRenderBufferStorage(renderTargetProperties.__webglDepthbuffer, renderTarget, false);\n      }\n    }\n    _gl.bindFramebuffer(36160, null);\n  }\n\n  // Set up GL resources for the render target\n  function setupRenderTarget(renderTarget) {\n    const renderTargetProperties = properties.get(renderTarget);\n    const textureProperties = properties.get(renderTarget.texture);\n    renderTarget.addEventListener('dispose', onRenderTargetDispose);\n    textureProperties.__webglTexture = _gl.createTexture();\n    info.memory.textures++;\n    const isCube = renderTarget.isWebGLCubeRenderTarget === true;\n    const isMultisample = renderTarget.isWebGLMultisampleRenderTarget === true;\n    const supportsMips = isPowerOfTwo(renderTarget) || isWebGL2;\n\n    // Handles WebGL2 RGBFormat fallback - #18858\n\n    if (isWebGL2 && renderTarget.texture.format === RGBFormat && (renderTarget.texture.type === FloatType || renderTarget.texture.type === HalfFloatType)) {\n      renderTarget.texture.format = RGBAFormat;\n      console.warn('THREE.WebGLRenderer: Rendering to textures with RGB format is not supported. Using RGBA format instead.');\n    }\n\n    // Setup framebuffer\n\n    if (isCube) {\n      renderTargetProperties.__webglFramebuffer = [];\n      for (let i = 0; i < 6; i++) {\n        renderTargetProperties.__webglFramebuffer[i] = _gl.createFramebuffer();\n      }\n    } else {\n      renderTargetProperties.__webglFramebuffer = _gl.createFramebuffer();\n      if (isMultisample) {\n        if (isWebGL2) {\n          renderTargetProperties.__webglMultisampledFramebuffer = _gl.createFramebuffer();\n          renderTargetProperties.__webglColorRenderbuffer = _gl.createRenderbuffer();\n          _gl.bindRenderbuffer(36161, renderTargetProperties.__webglColorRenderbuffer);\n          const glFormat = utils.convert(renderTarget.texture.format);\n          const glType = utils.convert(renderTarget.texture.type);\n          const glInternalFormat = getInternalFormat(renderTarget.texture.internalFormat, glFormat, glType);\n          const samples = getRenderTargetSamples(renderTarget);\n          _gl.renderbufferStorageMultisample(36161, samples, glInternalFormat, renderTarget.width, renderTarget.height);\n          _gl.bindFramebuffer(36160, renderTargetProperties.__webglMultisampledFramebuffer);\n          _gl.framebufferRenderbuffer(36160, 36064, 36161, renderTargetProperties.__webglColorRenderbuffer);\n          _gl.bindRenderbuffer(36161, null);\n          if (renderTarget.depthBuffer) {\n            renderTargetProperties.__webglDepthRenderbuffer = _gl.createRenderbuffer();\n            setupRenderBufferStorage(renderTargetProperties.__webglDepthRenderbuffer, renderTarget, true);\n          }\n          _gl.bindFramebuffer(36160, null);\n        } else {\n          console.warn('THREE.WebGLRenderer: WebGLMultisampleRenderTarget can only be used with WebGL2.');\n        }\n      }\n    }\n\n    // Setup color buffer\n\n    if (isCube) {\n      state.bindTexture(34067, textureProperties.__webglTexture);\n      setTextureParameters(34067, renderTarget.texture, supportsMips);\n      for (let i = 0; i < 6; i++) {\n        setupFrameBufferTexture(renderTargetProperties.__webglFramebuffer[i], renderTarget, 36064, 34069 + i);\n      }\n      if (textureNeedsGenerateMipmaps(renderTarget.texture, supportsMips)) {\n        generateMipmap(34067, renderTarget.texture, renderTarget.width, renderTarget.height);\n      }\n      state.bindTexture(34067, null);\n    } else {\n      state.bindTexture(3553, textureProperties.__webglTexture);\n      setTextureParameters(3553, renderTarget.texture, supportsMips);\n      setupFrameBufferTexture(renderTargetProperties.__webglFramebuffer, renderTarget, 36064, 3553);\n      if (textureNeedsGenerateMipmaps(renderTarget.texture, supportsMips)) {\n        generateMipmap(3553, renderTarget.texture, renderTarget.width, renderTarget.height);\n      }\n      state.bindTexture(3553, null);\n    }\n\n    // Setup depth and stencil buffers\n\n    if (renderTarget.depthBuffer) {\n      setupDepthRenderbuffer(renderTarget);\n    }\n  }\n  function updateRenderTargetMipmap(renderTarget) {\n    const texture = renderTarget.texture;\n    const supportsMips = isPowerOfTwo(renderTarget) || isWebGL2;\n    if (textureNeedsGenerateMipmaps(texture, supportsMips)) {\n      const target = renderTarget.isWebGLCubeRenderTarget ? 34067 : 3553;\n      const webglTexture = properties.get(texture).__webglTexture;\n      state.bindTexture(target, webglTexture);\n      generateMipmap(target, texture, renderTarget.width, renderTarget.height);\n      state.bindTexture(target, null);\n    }\n  }\n  function updateMultisampleRenderTarget(renderTarget) {\n    if (renderTarget.isWebGLMultisampleRenderTarget) {\n      if (isWebGL2) {\n        const renderTargetProperties = properties.get(renderTarget);\n        _gl.bindFramebuffer(36008, renderTargetProperties.__webglMultisampledFramebuffer);\n        _gl.bindFramebuffer(36009, renderTargetProperties.__webglFramebuffer);\n        const width = renderTarget.width;\n        const height = renderTarget.height;\n        let mask = 16384;\n        if (renderTarget.depthBuffer) mask |= 256;\n        if (renderTarget.stencilBuffer) mask |= 1024;\n        _gl.blitFramebuffer(0, 0, width, height, 0, 0, width, height, mask, 9728);\n        _gl.bindFramebuffer(36160, renderTargetProperties.__webglMultisampledFramebuffer); // see #18905\n      } else {\n        console.warn('THREE.WebGLRenderer: WebGLMultisampleRenderTarget can only be used with WebGL2.');\n      }\n    }\n  }\n  function getRenderTargetSamples(renderTarget) {\n    return isWebGL2 && renderTarget.isWebGLMultisampleRenderTarget ? Math.min(maxSamples, renderTarget.samples) : 0;\n  }\n  function updateVideoTexture(texture) {\n    const frame = info.render.frame;\n\n    // Check the last frame we updated the VideoTexture\n\n    if (_videoTextures.get(texture) !== frame) {\n      _videoTextures.set(texture, frame);\n      texture.update();\n    }\n  }\n\n  // backwards compatibility\n\n  let warnedTexture2D = false;\n  let warnedTextureCube = false;\n  function safeSetTexture2D(texture, slot) {\n    if (texture && texture.isWebGLRenderTarget) {\n      if (warnedTexture2D === false) {\n        console.warn('THREE.WebGLTextures.safeSetTexture2D: don\\'t use render targets as textures. Use their .texture property instead.');\n        warnedTexture2D = true;\n      }\n      texture = texture.texture;\n    }\n    setTexture2D(texture, slot);\n  }\n  function safeSetTextureCube(texture, slot) {\n    if (texture && texture.isWebGLCubeRenderTarget) {\n      if (warnedTextureCube === false) {\n        console.warn('THREE.WebGLTextures.safeSetTextureCube: don\\'t use cube render targets as textures. Use their .texture property instead.');\n        warnedTextureCube = true;\n      }\n      texture = texture.texture;\n    }\n    setTextureCube(texture, slot);\n  }\n\n  //\n\n  this.allocateTextureUnit = allocateTextureUnit;\n  this.resetTextureUnits = resetTextureUnits;\n  this.setTexture2D = setTexture2D;\n  this.setTexture2DArray = setTexture2DArray;\n  this.setTexture3D = setTexture3D;\n  this.setTextureCube = setTextureCube;\n  this.setupRenderTarget = setupRenderTarget;\n  this.updateRenderTargetMipmap = updateRenderTargetMipmap;\n  this.updateMultisampleRenderTarget = updateMultisampleRenderTarget;\n  this.safeSetTexture2D = safeSetTexture2D;\n  this.safeSetTextureCube = safeSetTextureCube;\n}\nfunction WebGLUtils(gl, extensions, capabilities) {\n  const isWebGL2 = capabilities.isWebGL2;\n  function convert(p) {\n    let extension;\n    if (p === UnsignedByteType) return 5121;\n    if (p === UnsignedShort4444Type) return 32819;\n    if (p === UnsignedShort5551Type) return 32820;\n    if (p === UnsignedShort565Type) return 33635;\n    if (p === ByteType) return 5120;\n    if (p === ShortType) return 5122;\n    if (p === UnsignedShortType) return 5123;\n    if (p === IntType) return 5124;\n    if (p === UnsignedIntType) return 5125;\n    if (p === FloatType) return 5126;\n    if (p === HalfFloatType) {\n      if (isWebGL2) return 5131;\n      extension = extensions.get('OES_texture_half_float');\n      if (extension !== null) {\n        return extension.HALF_FLOAT_OES;\n      } else {\n        return null;\n      }\n    }\n    if (p === AlphaFormat) return 6406;\n    if (p === RGBFormat) return 6407;\n    if (p === RGBAFormat) return 6408;\n    if (p === LuminanceFormat) return 6409;\n    if (p === LuminanceAlphaFormat) return 6410;\n    if (p === DepthFormat) return 6402;\n    if (p === DepthStencilFormat) return 34041;\n    if (p === RedFormat) return 6403;\n\n    // WebGL2 formats.\n\n    if (p === RedIntegerFormat) return 36244;\n    if (p === RGFormat) return 33319;\n    if (p === RGIntegerFormat) return 33320;\n    if (p === RGBIntegerFormat) return 36248;\n    if (p === RGBAIntegerFormat) return 36249;\n    if (p === RGB_S3TC_DXT1_Format || p === RGBA_S3TC_DXT1_Format || p === RGBA_S3TC_DXT3_Format || p === RGBA_S3TC_DXT5_Format) {\n      extension = extensions.get('WEBGL_compressed_texture_s3tc');\n      if (extension !== null) {\n        if (p === RGB_S3TC_DXT1_Format) return extension.COMPRESSED_RGB_S3TC_DXT1_EXT;\n        if (p === RGBA_S3TC_DXT1_Format) return extension.COMPRESSED_RGBA_S3TC_DXT1_EXT;\n        if (p === RGBA_S3TC_DXT3_Format) return extension.COMPRESSED_RGBA_S3TC_DXT3_EXT;\n        if (p === RGBA_S3TC_DXT5_Format) return extension.COMPRESSED_RGBA_S3TC_DXT5_EXT;\n      } else {\n        return null;\n      }\n    }\n    if (p === RGB_PVRTC_4BPPV1_Format || p === RGB_PVRTC_2BPPV1_Format || p === RGBA_PVRTC_4BPPV1_Format || p === RGBA_PVRTC_2BPPV1_Format) {\n      extension = extensions.get('WEBGL_compressed_texture_pvrtc');\n      if (extension !== null) {\n        if (p === RGB_PVRTC_4BPPV1_Format) return extension.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;\n        if (p === RGB_PVRTC_2BPPV1_Format) return extension.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;\n        if (p === RGBA_PVRTC_4BPPV1_Format) return extension.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;\n        if (p === RGBA_PVRTC_2BPPV1_Format) return extension.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG;\n      } else {\n        return null;\n      }\n    }\n    if (p === RGB_ETC1_Format) {\n      extension = extensions.get('WEBGL_compressed_texture_etc1');\n      if (extension !== null) {\n        return extension.COMPRESSED_RGB_ETC1_WEBGL;\n      } else {\n        return null;\n      }\n    }\n    if (p === RGB_ETC2_Format || p === RGBA_ETC2_EAC_Format) {\n      extension = extensions.get('WEBGL_compressed_texture_etc');\n      if (extension !== null) {\n        if (p === RGB_ETC2_Format) return extension.COMPRESSED_RGB8_ETC2;\n        if (p === RGBA_ETC2_EAC_Format) return extension.COMPRESSED_RGBA8_ETC2_EAC;\n      }\n    }\n    if (p === RGBA_ASTC_4x4_Format || p === RGBA_ASTC_5x4_Format || p === RGBA_ASTC_5x5_Format || p === RGBA_ASTC_6x5_Format || p === RGBA_ASTC_6x6_Format || p === RGBA_ASTC_8x5_Format || p === RGBA_ASTC_8x6_Format || p === RGBA_ASTC_8x8_Format || p === RGBA_ASTC_10x5_Format || p === RGBA_ASTC_10x6_Format || p === RGBA_ASTC_10x8_Format || p === RGBA_ASTC_10x10_Format || p === RGBA_ASTC_12x10_Format || p === RGBA_ASTC_12x12_Format || p === SRGB8_ALPHA8_ASTC_4x4_Format || p === SRGB8_ALPHA8_ASTC_5x4_Format || p === SRGB8_ALPHA8_ASTC_5x5_Format || p === SRGB8_ALPHA8_ASTC_6x5_Format || p === SRGB8_ALPHA8_ASTC_6x6_Format || p === SRGB8_ALPHA8_ASTC_8x5_Format || p === SRGB8_ALPHA8_ASTC_8x6_Format || p === SRGB8_ALPHA8_ASTC_8x8_Format || p === SRGB8_ALPHA8_ASTC_10x5_Format || p === SRGB8_ALPHA8_ASTC_10x6_Format || p === SRGB8_ALPHA8_ASTC_10x8_Format || p === SRGB8_ALPHA8_ASTC_10x10_Format || p === SRGB8_ALPHA8_ASTC_12x10_Format || p === SRGB8_ALPHA8_ASTC_12x12_Format) {\n      extension = extensions.get('WEBGL_compressed_texture_astc');\n      if (extension !== null) {\n        // TODO Complete?\n\n        return p;\n      } else {\n        return null;\n      }\n    }\n    if (p === RGBA_BPTC_Format) {\n      extension = extensions.get('EXT_texture_compression_bptc');\n      if (extension !== null) {\n        // TODO Complete?\n\n        return p;\n      } else {\n        return null;\n      }\n    }\n    if (p === UnsignedInt248Type) {\n      if (isWebGL2) return 34042;\n      extension = extensions.get('WEBGL_depth_texture');\n      if (extension !== null) {\n        return extension.UNSIGNED_INT_24_8_WEBGL;\n      } else {\n        return null;\n      }\n    }\n  }\n  return {\n    convert: convert\n  };\n}\nfunction ArrayCamera(array = []) {\n  PerspectiveCamera.call(this);\n  this.cameras = array;\n}\nArrayCamera.prototype = _extends__default['default'](Object.create(PerspectiveCamera.prototype), {\n  constructor: ArrayCamera,\n  isArrayCamera: true\n});\nfunction Group() {\n  Object3D.call(this);\n  this.type = 'Group';\n}\nGroup.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Group,\n  isGroup: true\n});\nfunction WebXRController() {\n  this._targetRay = null;\n  this._grip = null;\n  this._hand = null;\n}\n_extends__default['default'](WebXRController.prototype, {\n  constructor: WebXRController,\n  getHandSpace: function () {\n    if (this._hand === null) {\n      this._hand = new Group();\n      this._hand.matrixAutoUpdate = false;\n      this._hand.visible = false;\n      this._hand.joints = {};\n      this._hand.inputState = {\n        pinching: false\n      };\n    }\n    return this._hand;\n  },\n  getTargetRaySpace: function () {\n    if (this._targetRay === null) {\n      this._targetRay = new Group();\n      this._targetRay.matrixAutoUpdate = false;\n      this._targetRay.visible = false;\n    }\n    return this._targetRay;\n  },\n  getGripSpace: function () {\n    if (this._grip === null) {\n      this._grip = new Group();\n      this._grip.matrixAutoUpdate = false;\n      this._grip.visible = false;\n    }\n    return this._grip;\n  },\n  dispatchEvent: function (event) {\n    if (this._targetRay !== null) {\n      this._targetRay.dispatchEvent(event);\n    }\n    if (this._grip !== null) {\n      this._grip.dispatchEvent(event);\n    }\n    if (this._hand !== null) {\n      this._hand.dispatchEvent(event);\n    }\n    return this;\n  },\n  disconnect: function (inputSource) {\n    this.dispatchEvent({\n      type: 'disconnected',\n      data: inputSource\n    });\n    if (this._targetRay !== null) {\n      this._targetRay.visible = false;\n    }\n    if (this._grip !== null) {\n      this._grip.visible = false;\n    }\n    if (this._hand !== null) {\n      this._hand.visible = false;\n    }\n    return this;\n  },\n  update: function (inputSource, frame, referenceSpace) {\n    let inputPose = null;\n    let gripPose = null;\n    let handPose = null;\n    const targetRay = this._targetRay;\n    const grip = this._grip;\n    const hand = this._hand;\n    if (inputSource && frame.session.visibilityState !== 'visible-blurred') {\n      if (hand && inputSource.hand) {\n        handPose = true;\n        for (const inputjoint of inputSource.hand.values()) {\n          // Update the joints groups with the XRJoint poses\n          const jointPose = frame.getJointPose(inputjoint, referenceSpace);\n          if (hand.joints[inputjoint.jointName] === undefined) {\n            // The transform of this joint will be updated with the joint pose on each frame\n            const joint = new Group();\n            joint.matrixAutoUpdate = false;\n            joint.visible = false;\n            hand.joints[inputjoint.jointName] = joint;\n            // ??\n            hand.add(joint);\n          }\n          const joint = hand.joints[inputjoint.jointName];\n          if (jointPose !== null) {\n            joint.matrix.fromArray(jointPose.transform.matrix);\n            joint.matrix.decompose(joint.position, joint.rotation, joint.scale);\n            joint.jointRadius = jointPose.radius;\n          }\n          joint.visible = jointPose !== null;\n        }\n\n        // Custom events\n\n        // Check pinchz\n        const indexTip = hand.joints['index-finger-tip'];\n        const thumbTip = hand.joints['thumb-tip'];\n        const distance = indexTip.position.distanceTo(thumbTip.position);\n        const distanceToPinch = 0.02;\n        const threshold = 0.005;\n        if (hand.inputState.pinching && distance > distanceToPinch + threshold) {\n          hand.inputState.pinching = false;\n          this.dispatchEvent({\n            type: 'pinchend',\n            handedness: inputSource.handedness,\n            target: this\n          });\n        } else if (!hand.inputState.pinching && distance <= distanceToPinch - threshold) {\n          hand.inputState.pinching = true;\n          this.dispatchEvent({\n            type: 'pinchstart',\n            handedness: inputSource.handedness,\n            target: this\n          });\n        }\n      } else {\n        if (targetRay !== null) {\n          inputPose = frame.getPose(inputSource.targetRaySpace, referenceSpace);\n          if (inputPose !== null) {\n            targetRay.matrix.fromArray(inputPose.transform.matrix);\n            targetRay.matrix.decompose(targetRay.position, targetRay.rotation, targetRay.scale);\n          }\n        }\n        if (grip !== null && inputSource.gripSpace) {\n          gripPose = frame.getPose(inputSource.gripSpace, referenceSpace);\n          if (gripPose !== null) {\n            grip.matrix.fromArray(gripPose.transform.matrix);\n            grip.matrix.decompose(grip.position, grip.rotation, grip.scale);\n          }\n        }\n      }\n    }\n    if (targetRay !== null) {\n      targetRay.visible = inputPose !== null;\n    }\n    if (grip !== null) {\n      grip.visible = gripPose !== null;\n    }\n    if (hand !== null) {\n      hand.visible = handPose !== null;\n    }\n    return this;\n  }\n});\nfunction WebXRManager(renderer, gl) {\n  const scope = this;\n  let session = null;\n  let framebufferScaleFactor = 1.0;\n  let referenceSpace = null;\n  let referenceSpaceType = 'local-floor';\n  let pose = null;\n  const controllers = [];\n  const inputSourcesMap = new Map();\n\n  //\n\n  const cameraL = new PerspectiveCamera();\n  cameraL.layers.enable(1);\n  cameraL.viewport = new Vector4();\n  const cameraR = new PerspectiveCamera();\n  cameraR.layers.enable(2);\n  cameraR.viewport = new Vector4();\n  const cameras = [cameraL, cameraR];\n  const cameraVR = new ArrayCamera();\n  cameraVR.layers.enable(1);\n  cameraVR.layers.enable(2);\n  let _currentDepthNear = null;\n  let _currentDepthFar = null;\n\n  //\n\n  this.enabled = false;\n  this.isPresenting = false;\n  this.getController = function (index) {\n    let controller = controllers[index];\n    if (controller === undefined) {\n      controller = new WebXRController();\n      controllers[index] = controller;\n    }\n    return controller.getTargetRaySpace();\n  };\n  this.getControllerGrip = function (index) {\n    let controller = controllers[index];\n    if (controller === undefined) {\n      controller = new WebXRController();\n      controllers[index] = controller;\n    }\n    return controller.getGripSpace();\n  };\n  this.getHand = function (index) {\n    let controller = controllers[index];\n    if (controller === undefined) {\n      controller = new WebXRController();\n      controllers[index] = controller;\n    }\n    return controller.getHandSpace();\n  };\n\n  //\n\n  function onSessionEvent(event) {\n    const controller = inputSourcesMap.get(event.inputSource);\n    if (controller) {\n      controller.dispatchEvent({\n        type: event.type,\n        data: event.inputSource\n      });\n    }\n  }\n  function onSessionEnd() {\n    inputSourcesMap.forEach(function (controller, inputSource) {\n      controller.disconnect(inputSource);\n    });\n    inputSourcesMap.clear();\n    _currentDepthNear = null;\n    _currentDepthFar = null;\n\n    //\n\n    renderer.setFramebuffer(null);\n    renderer.setRenderTarget(renderer.getRenderTarget()); // Hack #15830\n    animation.stop();\n    scope.isPresenting = false;\n    scope.dispatchEvent({\n      type: 'sessionend'\n    });\n  }\n  this.setFramebufferScaleFactor = function (value) {\n    framebufferScaleFactor = value;\n    if (scope.isPresenting === true) {\n      console.warn('THREE.WebXRManager: Cannot change framebuffer scale while presenting.');\n    }\n  };\n  this.setReferenceSpaceType = function (value) {\n    referenceSpaceType = value;\n    if (scope.isPresenting === true) {\n      console.warn('THREE.WebXRManager: Cannot change reference space type while presenting.');\n    }\n  };\n  this.getReferenceSpace = function () {\n    return referenceSpace;\n  };\n  this.getSession = function () {\n    return session;\n  };\n  this.setSession = /*#__PURE__*/function () {\n    var _ref = _asyncToGenerator__default['default'](function* (value) {\n      session = value;\n      if (session !== null) {\n        session.addEventListener('select', onSessionEvent);\n        session.addEventListener('selectstart', onSessionEvent);\n        session.addEventListener('selectend', onSessionEvent);\n        session.addEventListener('squeeze', onSessionEvent);\n        session.addEventListener('squeezestart', onSessionEvent);\n        session.addEventListener('squeezeend', onSessionEvent);\n        session.addEventListener('end', onSessionEnd);\n        session.addEventListener('inputsourceschange', onInputSourcesChange);\n        const attributes = gl.getContextAttributes();\n        if (attributes.xrCompatible !== true) {\n          yield gl.makeXRCompatible();\n        }\n        const layerInit = {\n          antialias: attributes.antialias,\n          alpha: attributes.alpha,\n          depth: attributes.depth,\n          stencil: attributes.stencil,\n          framebufferScaleFactor: framebufferScaleFactor\n        };\n\n        // eslint-disable-next-line no-undef\n        const baseLayer = new XRWebGLLayer(session, gl, layerInit);\n        session.updateRenderState({\n          baseLayer: baseLayer\n        });\n        referenceSpace = yield session.requestReferenceSpace(referenceSpaceType);\n        animation.setContext(session);\n        animation.start();\n        scope.isPresenting = true;\n        scope.dispatchEvent({\n          type: 'sessionstart'\n        });\n      }\n    });\n    return function (_x2) {\n      return _ref.apply(this, arguments);\n    };\n  }();\n  function onInputSourcesChange(event) {\n    const inputSources = session.inputSources;\n\n    // Assign inputSources to available controllers\n\n    for (let i = 0; i < controllers.length; i++) {\n      inputSourcesMap.set(inputSources[i], controllers[i]);\n    }\n\n    // Notify disconnected\n\n    for (let i = 0; i < event.removed.length; i++) {\n      const inputSource = event.removed[i];\n      const controller = inputSourcesMap.get(inputSource);\n      if (controller) {\n        controller.dispatchEvent({\n          type: 'disconnected',\n          data: inputSource\n        });\n        inputSourcesMap.delete(inputSource);\n      }\n    }\n\n    // Notify connected\n\n    for (let i = 0; i < event.added.length; i++) {\n      const inputSource = event.added[i];\n      const controller = inputSourcesMap.get(inputSource);\n      if (controller) {\n        controller.dispatchEvent({\n          type: 'connected',\n          data: inputSource\n        });\n      }\n    }\n  }\n\n  //\n\n  const cameraLPos = new Vector3();\n  const cameraRPos = new Vector3();\n\n  /**\n   * Assumes 2 cameras that are parallel and share an X-axis, and that\n   * the cameras' projection and world matrices have already been set.\n   * And that near and far planes are identical for both cameras.\n   * Visualization of this technique: https://computergraphics.stackexchange.com/a/4765\n   */\n  function setProjectionFromUnion(camera, cameraL, cameraR) {\n    cameraLPos.setFromMatrixPosition(cameraL.matrixWorld);\n    cameraRPos.setFromMatrixPosition(cameraR.matrixWorld);\n    const ipd = cameraLPos.distanceTo(cameraRPos);\n    const projL = cameraL.projectionMatrix.elements;\n    const projR = cameraR.projectionMatrix.elements;\n\n    // VR systems will have identical far and near planes, and\n    // most likely identical top and bottom frustum extents.\n    // Use the left camera for these values.\n    const near = projL[14] / (projL[10] - 1);\n    const far = projL[14] / (projL[10] + 1);\n    const topFov = (projL[9] + 1) / projL[5];\n    const bottomFov = (projL[9] - 1) / projL[5];\n    const leftFov = (projL[8] - 1) / projL[0];\n    const rightFov = (projR[8] + 1) / projR[0];\n    const left = near * leftFov;\n    const right = near * rightFov;\n\n    // Calculate the new camera's position offset from the\n    // left camera. xOffset should be roughly half `ipd`.\n    const zOffset = ipd / (-leftFov + rightFov);\n    const xOffset = zOffset * -leftFov;\n\n    // TODO: Better way to apply this offset?\n    cameraL.matrixWorld.decompose(camera.position, camera.quaternion, camera.scale);\n    camera.translateX(xOffset);\n    camera.translateZ(zOffset);\n    camera.matrixWorld.compose(camera.position, camera.quaternion, camera.scale);\n    camera.matrixWorldInverse.copy(camera.matrixWorld).invert();\n\n    // Find the union of the frustum values of the cameras and scale\n    // the values so that the near plane's position does not change in world space,\n    // although must now be relative to the new union camera.\n    const near2 = near + zOffset;\n    const far2 = far + zOffset;\n    const left2 = left - xOffset;\n    const right2 = right + (ipd - xOffset);\n    const top2 = topFov * far / far2 * near2;\n    const bottom2 = bottomFov * far / far2 * near2;\n    camera.projectionMatrix.makePerspective(left2, right2, top2, bottom2, near2, far2);\n  }\n  function updateCamera(camera, parent) {\n    if (parent === null) {\n      camera.matrixWorld.copy(camera.matrix);\n    } else {\n      camera.matrixWorld.multiplyMatrices(parent.matrixWorld, camera.matrix);\n    }\n    camera.matrixWorldInverse.copy(camera.matrixWorld).invert();\n  }\n  this.getCamera = function (camera) {\n    cameraVR.near = cameraR.near = cameraL.near = camera.near;\n    cameraVR.far = cameraR.far = cameraL.far = camera.far;\n    if (_currentDepthNear !== cameraVR.near || _currentDepthFar !== cameraVR.far) {\n      // Note that the new renderState won't apply until the next frame. See #18320\n\n      session.updateRenderState({\n        depthNear: cameraVR.near,\n        depthFar: cameraVR.far\n      });\n      _currentDepthNear = cameraVR.near;\n      _currentDepthFar = cameraVR.far;\n    }\n    const parent = camera.parent;\n    const cameras = cameraVR.cameras;\n    updateCamera(cameraVR, parent);\n    for (let i = 0; i < cameras.length; i++) {\n      updateCamera(cameras[i], parent);\n    }\n\n    // update camera and its children\n\n    camera.matrixWorld.copy(cameraVR.matrixWorld);\n    camera.matrix.copy(cameraVR.matrix);\n    camera.matrix.decompose(camera.position, camera.quaternion, camera.scale);\n    const children = camera.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      children[i].updateMatrixWorld(true);\n    }\n\n    // update projection matrix for proper view frustum culling\n\n    if (cameras.length === 2) {\n      setProjectionFromUnion(cameraVR, cameraL, cameraR);\n    } else {\n      // assume single camera setup (AR)\n\n      cameraVR.projectionMatrix.copy(cameraL.projectionMatrix);\n    }\n    return cameraVR;\n  };\n\n  // Animation Loop\n\n  let onAnimationFrameCallback = null;\n  function onAnimationFrame(time, frame) {\n    pose = frame.getViewerPose(referenceSpace);\n    if (pose !== null) {\n      const views = pose.views;\n      const baseLayer = session.renderState.baseLayer;\n      renderer.setFramebuffer(baseLayer.framebuffer);\n      let cameraVRNeedsUpdate = false;\n\n      // check if it's necessary to rebuild cameraVR's camera list\n\n      if (views.length !== cameraVR.cameras.length) {\n        cameraVR.cameras.length = 0;\n        cameraVRNeedsUpdate = true;\n      }\n      for (let i = 0; i < views.length; i++) {\n        const view = views[i];\n        const viewport = baseLayer.getViewport(view);\n        const camera = cameras[i];\n        camera.matrix.fromArray(view.transform.matrix);\n        camera.projectionMatrix.fromArray(view.projectionMatrix);\n        camera.viewport.set(viewport.x, viewport.y, viewport.width, viewport.height);\n        if (i === 0) {\n          cameraVR.matrix.copy(camera.matrix);\n        }\n        if (cameraVRNeedsUpdate === true) {\n          cameraVR.cameras.push(camera);\n        }\n      }\n    }\n\n    //\n\n    const inputSources = session.inputSources;\n    for (let i = 0; i < controllers.length; i++) {\n      const controller = controllers[i];\n      const inputSource = inputSources[i];\n      controller.update(inputSource, frame, referenceSpace);\n    }\n    if (onAnimationFrameCallback) onAnimationFrameCallback(time, frame);\n  }\n  const animation = new WebGLAnimation();\n  animation.setAnimationLoop(onAnimationFrame);\n  this.setAnimationLoop = function (callback) {\n    onAnimationFrameCallback = callback;\n  };\n  this.dispose = function () {};\n}\n_extends__default['default'](WebXRManager.prototype, EventDispatcher.prototype);\nfunction WebGLMaterials(properties) {\n  function refreshFogUniforms(uniforms, fog) {\n    uniforms.fogColor.value.copy(fog.color);\n    if (fog.isFog) {\n      uniforms.fogNear.value = fog.near;\n      uniforms.fogFar.value = fog.far;\n    } else if (fog.isFogExp2) {\n      uniforms.fogDensity.value = fog.density;\n    }\n  }\n  function refreshMaterialUniforms(uniforms, material, pixelRatio, height) {\n    if (material.isMeshBasicMaterial) {\n      refreshUniformsCommon(uniforms, material);\n    } else if (material.isMeshLambertMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      refreshUniformsLambert(uniforms, material);\n    } else if (material.isMeshToonMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      refreshUniformsToon(uniforms, material);\n    } else if (material.isMeshPhongMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      refreshUniformsPhong(uniforms, material);\n    } else if (material.isMeshStandardMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      if (material.isMeshPhysicalMaterial) {\n        refreshUniformsPhysical(uniforms, material);\n      } else {\n        refreshUniformsStandard(uniforms, material);\n      }\n    } else if (material.isMeshMatcapMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      refreshUniformsMatcap(uniforms, material);\n    } else if (material.isMeshDepthMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      refreshUniformsDepth(uniforms, material);\n    } else if (material.isMeshDistanceMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      refreshUniformsDistance(uniforms, material);\n    } else if (material.isMeshNormalMaterial) {\n      refreshUniformsCommon(uniforms, material);\n      refreshUniformsNormal(uniforms, material);\n    } else if (material.isLineBasicMaterial) {\n      refreshUniformsLine(uniforms, material);\n      if (material.isLineDashedMaterial) {\n        refreshUniformsDash(uniforms, material);\n      }\n    } else if (material.isPointsMaterial) {\n      refreshUniformsPoints(uniforms, material, pixelRatio, height);\n    } else if (material.isSpriteMaterial) {\n      refreshUniformsSprites(uniforms, material);\n    } else if (material.isShadowMaterial) {\n      uniforms.color.value.copy(material.color);\n      uniforms.opacity.value = material.opacity;\n    } else if (material.isShaderMaterial) {\n      material.uniformsNeedUpdate = false; // #15581\n    }\n  }\n\n  function refreshUniformsCommon(uniforms, material) {\n    uniforms.opacity.value = material.opacity;\n    if (material.color) {\n      uniforms.diffuse.value.copy(material.color);\n    }\n    if (material.emissive) {\n      uniforms.emissive.value.copy(material.emissive).multiplyScalar(material.emissiveIntensity);\n    }\n    if (material.map) {\n      uniforms.map.value = material.map;\n    }\n    if (material.alphaMap) {\n      uniforms.alphaMap.value = material.alphaMap;\n    }\n    if (material.specularMap) {\n      uniforms.specularMap.value = material.specularMap;\n    }\n    const envMap = properties.get(material).envMap;\n    if (envMap) {\n      uniforms.envMap.value = envMap;\n      uniforms.flipEnvMap.value = envMap.isCubeTexture && envMap._needsFlipEnvMap ? -1 : 1;\n      uniforms.reflectivity.value = material.reflectivity;\n      uniforms.refractionRatio.value = material.refractionRatio;\n      const maxMipLevel = properties.get(envMap).__maxMipLevel;\n      if (maxMipLevel !== undefined) {\n        uniforms.maxMipLevel.value = maxMipLevel;\n      }\n    }\n    if (material.lightMap) {\n      uniforms.lightMap.value = material.lightMap;\n      uniforms.lightMapIntensity.value = material.lightMapIntensity;\n    }\n    if (material.aoMap) {\n      uniforms.aoMap.value = material.aoMap;\n      uniforms.aoMapIntensity.value = material.aoMapIntensity;\n    }\n\n    // uv repeat and offset setting priorities\n    // 1. color map\n    // 2. specular map\n    // 3. displacementMap map\n    // 4. normal map\n    // 5. bump map\n    // 6. roughnessMap map\n    // 7. metalnessMap map\n    // 8. alphaMap map\n    // 9. emissiveMap map\n    // 10. clearcoat map\n    // 11. clearcoat normal map\n    // 12. clearcoat roughnessMap map\n\n    let uvScaleMap;\n    if (material.map) {\n      uvScaleMap = material.map;\n    } else if (material.specularMap) {\n      uvScaleMap = material.specularMap;\n    } else if (material.displacementMap) {\n      uvScaleMap = material.displacementMap;\n    } else if (material.normalMap) {\n      uvScaleMap = material.normalMap;\n    } else if (material.bumpMap) {\n      uvScaleMap = material.bumpMap;\n    } else if (material.roughnessMap) {\n      uvScaleMap = material.roughnessMap;\n    } else if (material.metalnessMap) {\n      uvScaleMap = material.metalnessMap;\n    } else if (material.alphaMap) {\n      uvScaleMap = material.alphaMap;\n    } else if (material.emissiveMap) {\n      uvScaleMap = material.emissiveMap;\n    } else if (material.clearcoatMap) {\n      uvScaleMap = material.clearcoatMap;\n    } else if (material.clearcoatNormalMap) {\n      uvScaleMap = material.clearcoatNormalMap;\n    } else if (material.clearcoatRoughnessMap) {\n      uvScaleMap = material.clearcoatRoughnessMap;\n    }\n    if (uvScaleMap !== undefined) {\n      // backwards compatibility\n      if (uvScaleMap.isWebGLRenderTarget) {\n        uvScaleMap = uvScaleMap.texture;\n      }\n      if (uvScaleMap.matrixAutoUpdate === true) {\n        uvScaleMap.updateMatrix();\n      }\n      uniforms.uvTransform.value.copy(uvScaleMap.matrix);\n    }\n\n    // uv repeat and offset setting priorities for uv2\n    // 1. ao map\n    // 2. light map\n\n    let uv2ScaleMap;\n    if (material.aoMap) {\n      uv2ScaleMap = material.aoMap;\n    } else if (material.lightMap) {\n      uv2ScaleMap = material.lightMap;\n    }\n    if (uv2ScaleMap !== undefined) {\n      // backwards compatibility\n      if (uv2ScaleMap.isWebGLRenderTarget) {\n        uv2ScaleMap = uv2ScaleMap.texture;\n      }\n      if (uv2ScaleMap.matrixAutoUpdate === true) {\n        uv2ScaleMap.updateMatrix();\n      }\n      uniforms.uv2Transform.value.copy(uv2ScaleMap.matrix);\n    }\n  }\n  function refreshUniformsLine(uniforms, material) {\n    uniforms.diffuse.value.copy(material.color);\n    uniforms.opacity.value = material.opacity;\n  }\n  function refreshUniformsDash(uniforms, material) {\n    uniforms.dashSize.value = material.dashSize;\n    uniforms.totalSize.value = material.dashSize + material.gapSize;\n    uniforms.scale.value = material.scale;\n  }\n  function refreshUniformsPoints(uniforms, material, pixelRatio, height) {\n    uniforms.diffuse.value.copy(material.color);\n    uniforms.opacity.value = material.opacity;\n    uniforms.size.value = material.size * pixelRatio;\n    uniforms.scale.value = height * 0.5;\n    if (material.map) {\n      uniforms.map.value = material.map;\n    }\n    if (material.alphaMap) {\n      uniforms.alphaMap.value = material.alphaMap;\n    }\n\n    // uv repeat and offset setting priorities\n    // 1. color map\n    // 2. alpha map\n\n    let uvScaleMap;\n    if (material.map) {\n      uvScaleMap = material.map;\n    } else if (material.alphaMap) {\n      uvScaleMap = material.alphaMap;\n    }\n    if (uvScaleMap !== undefined) {\n      if (uvScaleMap.matrixAutoUpdate === true) {\n        uvScaleMap.updateMatrix();\n      }\n      uniforms.uvTransform.value.copy(uvScaleMap.matrix);\n    }\n  }\n  function refreshUniformsSprites(uniforms, material) {\n    uniforms.diffuse.value.copy(material.color);\n    uniforms.opacity.value = material.opacity;\n    uniforms.rotation.value = material.rotation;\n    if (material.map) {\n      uniforms.map.value = material.map;\n    }\n    if (material.alphaMap) {\n      uniforms.alphaMap.value = material.alphaMap;\n    }\n\n    // uv repeat and offset setting priorities\n    // 1. color map\n    // 2. alpha map\n\n    let uvScaleMap;\n    if (material.map) {\n      uvScaleMap = material.map;\n    } else if (material.alphaMap) {\n      uvScaleMap = material.alphaMap;\n    }\n    if (uvScaleMap !== undefined) {\n      if (uvScaleMap.matrixAutoUpdate === true) {\n        uvScaleMap.updateMatrix();\n      }\n      uniforms.uvTransform.value.copy(uvScaleMap.matrix);\n    }\n  }\n  function refreshUniformsLambert(uniforms, material) {\n    if (material.emissiveMap) {\n      uniforms.emissiveMap.value = material.emissiveMap;\n    }\n  }\n  function refreshUniformsPhong(uniforms, material) {\n    uniforms.specular.value.copy(material.specular);\n    uniforms.shininess.value = Math.max(material.shininess, 1e-4); // to prevent pow( 0.0, 0.0 )\n\n    if (material.emissiveMap) {\n      uniforms.emissiveMap.value = material.emissiveMap;\n    }\n    if (material.bumpMap) {\n      uniforms.bumpMap.value = material.bumpMap;\n      uniforms.bumpScale.value = material.bumpScale;\n      if (material.side === BackSide) uniforms.bumpScale.value *= -1;\n    }\n    if (material.normalMap) {\n      uniforms.normalMap.value = material.normalMap;\n      uniforms.normalScale.value.copy(material.normalScale);\n      if (material.side === BackSide) uniforms.normalScale.value.negate();\n    }\n    if (material.displacementMap) {\n      uniforms.displacementMap.value = material.displacementMap;\n      uniforms.displacementScale.value = material.displacementScale;\n      uniforms.displacementBias.value = material.displacementBias;\n    }\n  }\n  function refreshUniformsToon(uniforms, material) {\n    if (material.gradientMap) {\n      uniforms.gradientMap.value = material.gradientMap;\n    }\n    if (material.emissiveMap) {\n      uniforms.emissiveMap.value = material.emissiveMap;\n    }\n    if (material.bumpMap) {\n      uniforms.bumpMap.value = material.bumpMap;\n      uniforms.bumpScale.value = material.bumpScale;\n      if (material.side === BackSide) uniforms.bumpScale.value *= -1;\n    }\n    if (material.normalMap) {\n      uniforms.normalMap.value = material.normalMap;\n      uniforms.normalScale.value.copy(material.normalScale);\n      if (material.side === BackSide) uniforms.normalScale.value.negate();\n    }\n    if (material.displacementMap) {\n      uniforms.displacementMap.value = material.displacementMap;\n      uniforms.displacementScale.value = material.displacementScale;\n      uniforms.displacementBias.value = material.displacementBias;\n    }\n  }\n  function refreshUniformsStandard(uniforms, material) {\n    uniforms.roughness.value = material.roughness;\n    uniforms.metalness.value = material.metalness;\n    if (material.roughnessMap) {\n      uniforms.roughnessMap.value = material.roughnessMap;\n    }\n    if (material.metalnessMap) {\n      uniforms.metalnessMap.value = material.metalnessMap;\n    }\n    if (material.emissiveMap) {\n      uniforms.emissiveMap.value = material.emissiveMap;\n    }\n    if (material.bumpMap) {\n      uniforms.bumpMap.value = material.bumpMap;\n      uniforms.bumpScale.value = material.bumpScale;\n      if (material.side === BackSide) uniforms.bumpScale.value *= -1;\n    }\n    if (material.normalMap) {\n      uniforms.normalMap.value = material.normalMap;\n      uniforms.normalScale.value.copy(material.normalScale);\n      if (material.side === BackSide) uniforms.normalScale.value.negate();\n    }\n    if (material.displacementMap) {\n      uniforms.displacementMap.value = material.displacementMap;\n      uniforms.displacementScale.value = material.displacementScale;\n      uniforms.displacementBias.value = material.displacementBias;\n    }\n    const envMap = properties.get(material).envMap;\n    if (envMap) {\n      //uniforms.envMap.value = material.envMap; // part of uniforms common\n      uniforms.envMapIntensity.value = material.envMapIntensity;\n    }\n  }\n  function refreshUniformsPhysical(uniforms, material) {\n    refreshUniformsStandard(uniforms, material);\n    uniforms.reflectivity.value = material.reflectivity; // also part of uniforms common\n\n    uniforms.clearcoat.value = material.clearcoat;\n    uniforms.clearcoatRoughness.value = material.clearcoatRoughness;\n    if (material.sheen) uniforms.sheen.value.copy(material.sheen);\n    if (material.clearcoatMap) {\n      uniforms.clearcoatMap.value = material.clearcoatMap;\n    }\n    if (material.clearcoatRoughnessMap) {\n      uniforms.clearcoatRoughnessMap.value = material.clearcoatRoughnessMap;\n    }\n    if (material.clearcoatNormalMap) {\n      uniforms.clearcoatNormalScale.value.copy(material.clearcoatNormalScale);\n      uniforms.clearcoatNormalMap.value = material.clearcoatNormalMap;\n      if (material.side === BackSide) {\n        uniforms.clearcoatNormalScale.value.negate();\n      }\n    }\n    uniforms.transmission.value = material.transmission;\n    if (material.transmissionMap) {\n      uniforms.transmissionMap.value = material.transmissionMap;\n    }\n  }\n  function refreshUniformsMatcap(uniforms, material) {\n    if (material.matcap) {\n      uniforms.matcap.value = material.matcap;\n    }\n    if (material.bumpMap) {\n      uniforms.bumpMap.value = material.bumpMap;\n      uniforms.bumpScale.value = material.bumpScale;\n      if (material.side === BackSide) uniforms.bumpScale.value *= -1;\n    }\n    if (material.normalMap) {\n      uniforms.normalMap.value = material.normalMap;\n      uniforms.normalScale.value.copy(material.normalScale);\n      if (material.side === BackSide) uniforms.normalScale.value.negate();\n    }\n    if (material.displacementMap) {\n      uniforms.displacementMap.value = material.displacementMap;\n      uniforms.displacementScale.value = material.displacementScale;\n      uniforms.displacementBias.value = material.displacementBias;\n    }\n  }\n  function refreshUniformsDepth(uniforms, material) {\n    if (material.displacementMap) {\n      uniforms.displacementMap.value = material.displacementMap;\n      uniforms.displacementScale.value = material.displacementScale;\n      uniforms.displacementBias.value = material.displacementBias;\n    }\n  }\n  function refreshUniformsDistance(uniforms, material) {\n    if (material.displacementMap) {\n      uniforms.displacementMap.value = material.displacementMap;\n      uniforms.displacementScale.value = material.displacementScale;\n      uniforms.displacementBias.value = material.displacementBias;\n    }\n    uniforms.referencePosition.value.copy(material.referencePosition);\n    uniforms.nearDistance.value = material.nearDistance;\n    uniforms.farDistance.value = material.farDistance;\n  }\n  function refreshUniformsNormal(uniforms, material) {\n    if (material.bumpMap) {\n      uniforms.bumpMap.value = material.bumpMap;\n      uniforms.bumpScale.value = material.bumpScale;\n      if (material.side === BackSide) uniforms.bumpScale.value *= -1;\n    }\n    if (material.normalMap) {\n      uniforms.normalMap.value = material.normalMap;\n      uniforms.normalScale.value.copy(material.normalScale);\n      if (material.side === BackSide) uniforms.normalScale.value.negate();\n    }\n    if (material.displacementMap) {\n      uniforms.displacementMap.value = material.displacementMap;\n      uniforms.displacementScale.value = material.displacementScale;\n      uniforms.displacementBias.value = material.displacementBias;\n    }\n  }\n  return {\n    refreshFogUniforms: refreshFogUniforms,\n    refreshMaterialUniforms: refreshMaterialUniforms\n  };\n}\nfunction createCanvasElement() {\n  const canvas = document.createElementNS('http://www.w3.org/1999/xhtml', 'canvas');\n  canvas.style.display = 'block';\n  return canvas;\n}\nfunction WebGLRenderer(parameters) {\n  parameters = parameters || {};\n  const _canvas = parameters.canvas !== undefined ? parameters.canvas : createCanvasElement(),\n    _context = parameters.context !== undefined ? parameters.context : null,\n    _alpha = parameters.alpha !== undefined ? parameters.alpha : false,\n    _depth = parameters.depth !== undefined ? parameters.depth : true,\n    _stencil = parameters.stencil !== undefined ? parameters.stencil : true,\n    _antialias = parameters.antialias !== undefined ? parameters.antialias : false,\n    _premultipliedAlpha = parameters.premultipliedAlpha !== undefined ? parameters.premultipliedAlpha : true,\n    _preserveDrawingBuffer = parameters.preserveDrawingBuffer !== undefined ? parameters.preserveDrawingBuffer : false,\n    _powerPreference = parameters.powerPreference !== undefined ? parameters.powerPreference : 'default',\n    _failIfMajorPerformanceCaveat = parameters.failIfMajorPerformanceCaveat !== undefined ? parameters.failIfMajorPerformanceCaveat : false;\n  let currentRenderList = null;\n  let currentRenderState = null;\n\n  // render() can be called from within a callback triggered by another render.\n  // We track this so that the nested render call gets its state isolated from the parent render call.\n\n  const renderStateStack = [];\n\n  // public properties\n\n  this.domElement = _canvas;\n\n  // Debug configuration container\n  this.debug = {\n    /**\n     * Enables error checking and reporting when shader programs are being compiled\n     * @type {boolean}\n     */\n    checkShaderErrors: true\n  };\n\n  // clearing\n\n  this.autoClear = true;\n  this.autoClearColor = true;\n  this.autoClearDepth = true;\n  this.autoClearStencil = true;\n\n  // scene graph\n\n  this.sortObjects = true;\n\n  // user-defined clipping\n\n  this.clippingPlanes = [];\n  this.localClippingEnabled = false;\n\n  // physically based shading\n\n  this.gammaFactor = 2.0; // for backwards compatibility\n  this.outputEncoding = LinearEncoding;\n\n  // physical lights\n\n  this.physicallyCorrectLights = false;\n\n  // tone mapping\n\n  this.toneMapping = NoToneMapping;\n  this.toneMappingExposure = 1.0;\n\n  // morphs\n\n  this.maxMorphTargets = 8;\n  this.maxMorphNormals = 4;\n\n  // internal properties\n\n  const _this = this;\n  let _isContextLost = false;\n\n  // internal state cache\n\n  let _framebuffer = null;\n  let _currentActiveCubeFace = 0;\n  let _currentActiveMipmapLevel = 0;\n  let _currentRenderTarget = null;\n  let _currentFramebuffer = null;\n  let _currentMaterialId = -1;\n  let _currentCamera = null;\n  const _currentViewport = new Vector4();\n  const _currentScissor = new Vector4();\n  let _currentScissorTest = null;\n\n  //\n\n  let _width = _canvas.width;\n  let _height = _canvas.height;\n  let _pixelRatio = 1;\n  let _opaqueSort = null;\n  let _transparentSort = null;\n  const _viewport = new Vector4(0, 0, _width, _height);\n  const _scissor = new Vector4(0, 0, _width, _height);\n  let _scissorTest = false;\n\n  // frustum\n\n  const _frustum = new Frustum();\n\n  // clipping\n\n  let _clippingEnabled = false;\n  let _localClippingEnabled = false;\n\n  // camera matrices cache\n\n  const _projScreenMatrix = new Matrix4();\n  const _vector3 = new Vector3();\n  const _emptyScene = {\n    background: null,\n    fog: null,\n    environment: null,\n    overrideMaterial: null,\n    isScene: true\n  };\n  function getTargetPixelRatio() {\n    return _currentRenderTarget === null ? _pixelRatio : 1;\n  }\n\n  // initialize\n\n  let _gl = _context;\n  function getContext(contextNames, contextAttributes) {\n    for (let i = 0; i < contextNames.length; i++) {\n      const contextName = contextNames[i];\n      const context = _canvas.getContext(contextName, contextAttributes);\n      if (context !== null) return context;\n    }\n    return null;\n  }\n  try {\n    const contextAttributes = {\n      alpha: _alpha,\n      depth: _depth,\n      stencil: _stencil,\n      antialias: _antialias,\n      premultipliedAlpha: _premultipliedAlpha,\n      preserveDrawingBuffer: _preserveDrawingBuffer,\n      powerPreference: _powerPreference,\n      failIfMajorPerformanceCaveat: _failIfMajorPerformanceCaveat\n    };\n\n    // event listeners must be registered before WebGL context is created, see #12753\n\n    _canvas.addEventListener('webglcontextlost', onContextLost, false);\n    _canvas.addEventListener('webglcontextrestored', onContextRestore, false);\n    if (_gl === null) {\n      const contextNames = ['webgl2', 'webgl', 'experimental-webgl'];\n      if (_this.isWebGL1Renderer === true) {\n        contextNames.shift();\n      }\n      _gl = getContext(contextNames, contextAttributes);\n      if (_gl === null) {\n        if (getContext(contextNames)) {\n          throw new Error('Error creating WebGL context with your selected attributes.');\n        } else {\n          throw new Error('Error creating WebGL context.');\n        }\n      }\n    }\n\n    // Some experimental-webgl implementations do not have getShaderPrecisionFormat\n\n    if (_gl.getShaderPrecisionFormat === undefined) {\n      _gl.getShaderPrecisionFormat = function () {\n        return {\n          'rangeMin': 1,\n          'rangeMax': 1,\n          'precision': 1\n        };\n      };\n    }\n  } catch (error) {\n    console.error('THREE.WebGLRenderer: ' + error.message);\n    throw error;\n  }\n  let extensions, capabilities, state, info;\n  let properties, textures, cubemaps, attributes, geometries, objects;\n  let programCache, materials, renderLists, renderStates, clipping;\n  let background, morphtargets, bufferRenderer, indexedBufferRenderer;\n  let utils, bindingStates;\n  function initGLContext() {\n    extensions = new WebGLExtensions(_gl);\n    capabilities = new WebGLCapabilities(_gl, extensions, parameters);\n    extensions.init(capabilities);\n    utils = new WebGLUtils(_gl, extensions, capabilities);\n    state = new WebGLState(_gl, extensions, capabilities);\n    state.scissor(_currentScissor.copy(_scissor).multiplyScalar(_pixelRatio).floor());\n    state.viewport(_currentViewport.copy(_viewport).multiplyScalar(_pixelRatio).floor());\n    info = new WebGLInfo(_gl);\n    properties = new WebGLProperties();\n    textures = new WebGLTextures(_gl, extensions, state, properties, capabilities, utils, info);\n    cubemaps = new WebGLCubeMaps(_this);\n    attributes = new WebGLAttributes(_gl, capabilities);\n    bindingStates = new WebGLBindingStates(_gl, extensions, attributes, capabilities);\n    geometries = new WebGLGeometries(_gl, attributes, info, bindingStates);\n    objects = new WebGLObjects(_gl, geometries, attributes, info);\n    morphtargets = new WebGLMorphtargets(_gl);\n    clipping = new WebGLClipping(properties);\n    programCache = new WebGLPrograms(_this, cubemaps, extensions, capabilities, bindingStates, clipping);\n    materials = new WebGLMaterials(properties);\n    renderLists = new WebGLRenderLists(properties);\n    renderStates = new WebGLRenderStates(extensions, capabilities);\n    background = new WebGLBackground(_this, cubemaps, state, objects, _premultipliedAlpha);\n    bufferRenderer = new WebGLBufferRenderer(_gl, extensions, info, capabilities);\n    indexedBufferRenderer = new WebGLIndexedBufferRenderer(_gl, extensions, info, capabilities);\n    info.programs = programCache.programs;\n    _this.capabilities = capabilities;\n    _this.extensions = extensions;\n    _this.properties = properties;\n    _this.renderLists = renderLists;\n    _this.state = state;\n    _this.info = info;\n  }\n  initGLContext();\n\n  // xr\n\n  const xr = new WebXRManager(_this, _gl);\n  this.xr = xr;\n\n  // shadow map\n\n  const shadowMap = new WebGLShadowMap(_this, objects, capabilities.maxTextureSize);\n  this.shadowMap = shadowMap;\n\n  // API\n\n  this.getContext = function () {\n    return _gl;\n  };\n  this.getContextAttributes = function () {\n    return _gl.getContextAttributes();\n  };\n  this.forceContextLoss = function () {\n    const extension = extensions.get('WEBGL_lose_context');\n    if (extension) extension.loseContext();\n  };\n  this.forceContextRestore = function () {\n    const extension = extensions.get('WEBGL_lose_context');\n    if (extension) extension.restoreContext();\n  };\n  this.getPixelRatio = function () {\n    return _pixelRatio;\n  };\n  this.setPixelRatio = function (value) {\n    if (value === undefined) return;\n    _pixelRatio = value;\n    this.setSize(_width, _height, false);\n  };\n  this.getSize = function (target) {\n    if (target === undefined) {\n      console.warn('WebGLRenderer: .getsize() now requires a Vector2 as an argument');\n      target = new Vector2();\n    }\n    return target.set(_width, _height);\n  };\n  this.setSize = function (width, height, updateStyle) {\n    if (xr.isPresenting) {\n      console.warn('THREE.WebGLRenderer: Can\\'t change size while VR device is presenting.');\n      return;\n    }\n    _width = width;\n    _height = height;\n    _canvas.width = Math.floor(width * _pixelRatio);\n    _canvas.height = Math.floor(height * _pixelRatio);\n    if (updateStyle !== false) {\n      _canvas.style.width = width + 'px';\n      _canvas.style.height = height + 'px';\n    }\n    this.setViewport(0, 0, width, height);\n  };\n  this.getDrawingBufferSize = function (target) {\n    if (target === undefined) {\n      console.warn('WebGLRenderer: .getdrawingBufferSize() now requires a Vector2 as an argument');\n      target = new Vector2();\n    }\n    return target.set(_width * _pixelRatio, _height * _pixelRatio).floor();\n  };\n  this.setDrawingBufferSize = function (width, height, pixelRatio) {\n    _width = width;\n    _height = height;\n    _pixelRatio = pixelRatio;\n    _canvas.width = Math.floor(width * pixelRatio);\n    _canvas.height = Math.floor(height * pixelRatio);\n    this.setViewport(0, 0, width, height);\n  };\n  this.getCurrentViewport = function (target) {\n    if (target === undefined) {\n      console.warn('WebGLRenderer: .getCurrentViewport() now requires a Vector4 as an argument');\n      target = new Vector4();\n    }\n    return target.copy(_currentViewport);\n  };\n  this.getViewport = function (target) {\n    return target.copy(_viewport);\n  };\n  this.setViewport = function (x, y, width, height) {\n    if (x.isVector4) {\n      _viewport.set(x.x, x.y, x.z, x.w);\n    } else {\n      _viewport.set(x, y, width, height);\n    }\n    state.viewport(_currentViewport.copy(_viewport).multiplyScalar(_pixelRatio).floor());\n  };\n  this.getScissor = function (target) {\n    return target.copy(_scissor);\n  };\n  this.setScissor = function (x, y, width, height) {\n    if (x.isVector4) {\n      _scissor.set(x.x, x.y, x.z, x.w);\n    } else {\n      _scissor.set(x, y, width, height);\n    }\n    state.scissor(_currentScissor.copy(_scissor).multiplyScalar(_pixelRatio).floor());\n  };\n  this.getScissorTest = function () {\n    return _scissorTest;\n  };\n  this.setScissorTest = function (boolean) {\n    state.setScissorTest(_scissorTest = boolean);\n  };\n  this.setOpaqueSort = function (method) {\n    _opaqueSort = method;\n  };\n  this.setTransparentSort = function (method) {\n    _transparentSort = method;\n  };\n\n  // Clearing\n\n  this.getClearColor = function (target) {\n    if (target === undefined) {\n      console.warn('WebGLRenderer: .getClearColor() now requires a Color as an argument');\n      target = new Color();\n    }\n    return target.copy(background.getClearColor());\n  };\n  this.setClearColor = function () {\n    background.setClearColor.apply(background, arguments);\n  };\n  this.getClearAlpha = function () {\n    return background.getClearAlpha();\n  };\n  this.setClearAlpha = function () {\n    background.setClearAlpha.apply(background, arguments);\n  };\n  this.clear = function (color, depth, stencil) {\n    let bits = 0;\n    if (color === undefined || color) bits |= 16384;\n    if (depth === undefined || depth) bits |= 256;\n    if (stencil === undefined || stencil) bits |= 1024;\n    _gl.clear(bits);\n  };\n  this.clearColor = function () {\n    this.clear(true, false, false);\n  };\n  this.clearDepth = function () {\n    this.clear(false, true, false);\n  };\n  this.clearStencil = function () {\n    this.clear(false, false, true);\n  };\n\n  //\n\n  this.dispose = function () {\n    _canvas.removeEventListener('webglcontextlost', onContextLost, false);\n    _canvas.removeEventListener('webglcontextrestored', onContextRestore, false);\n    renderLists.dispose();\n    renderStates.dispose();\n    properties.dispose();\n    cubemaps.dispose();\n    objects.dispose();\n    bindingStates.dispose();\n    xr.dispose();\n    animation.stop();\n  };\n\n  // Events\n\n  function onContextLost(event) {\n    event.preventDefault();\n    console.log('THREE.WebGLRenderer: Context Lost.');\n    _isContextLost = true;\n  }\n  function onContextRestore( /* event */\n  ) {\n    console.log('THREE.WebGLRenderer: Context Restored.');\n    _isContextLost = false;\n    initGLContext();\n  }\n  function onMaterialDispose(event) {\n    const material = event.target;\n    material.removeEventListener('dispose', onMaterialDispose);\n    deallocateMaterial(material);\n  }\n\n  // Buffer deallocation\n\n  function deallocateMaterial(material) {\n    releaseMaterialProgramReference(material);\n    properties.remove(material);\n  }\n  function releaseMaterialProgramReference(material) {\n    const programInfo = properties.get(material).program;\n    if (programInfo !== undefined) {\n      programCache.releaseProgram(programInfo);\n    }\n  }\n\n  // Buffer rendering\n\n  function renderObjectImmediate(object, program) {\n    object.render(function (object) {\n      _this.renderBufferImmediate(object, program);\n    });\n  }\n  this.renderBufferImmediate = function (object, program) {\n    bindingStates.initAttributes();\n    const buffers = properties.get(object);\n    if (object.hasPositions && !buffers.position) buffers.position = _gl.createBuffer();\n    if (object.hasNormals && !buffers.normal) buffers.normal = _gl.createBuffer();\n    if (object.hasUvs && !buffers.uv) buffers.uv = _gl.createBuffer();\n    if (object.hasColors && !buffers.color) buffers.color = _gl.createBuffer();\n    const programAttributes = program.getAttributes();\n    if (object.hasPositions) {\n      _gl.bindBuffer(34962, buffers.position);\n      _gl.bufferData(34962, object.positionArray, 35048);\n      bindingStates.enableAttribute(programAttributes.position);\n      _gl.vertexAttribPointer(programAttributes.position, 3, 5126, false, 0, 0);\n    }\n    if (object.hasNormals) {\n      _gl.bindBuffer(34962, buffers.normal);\n      _gl.bufferData(34962, object.normalArray, 35048);\n      bindingStates.enableAttribute(programAttributes.normal);\n      _gl.vertexAttribPointer(programAttributes.normal, 3, 5126, false, 0, 0);\n    }\n    if (object.hasUvs) {\n      _gl.bindBuffer(34962, buffers.uv);\n      _gl.bufferData(34962, object.uvArray, 35048);\n      bindingStates.enableAttribute(programAttributes.uv);\n      _gl.vertexAttribPointer(programAttributes.uv, 2, 5126, false, 0, 0);\n    }\n    if (object.hasColors) {\n      _gl.bindBuffer(34962, buffers.color);\n      _gl.bufferData(34962, object.colorArray, 35048);\n      bindingStates.enableAttribute(programAttributes.color);\n      _gl.vertexAttribPointer(programAttributes.color, 3, 5126, false, 0, 0);\n    }\n    bindingStates.disableUnusedAttributes();\n    _gl.drawArrays(4, 0, object.count);\n    object.count = 0;\n  };\n  this.renderBufferDirect = function (camera, scene, geometry, material, object, group) {\n    if (scene === null) scene = _emptyScene; // renderBufferDirect second parameter used to be fog (could be null)\n\n    const frontFaceCW = object.isMesh && object.matrixWorld.determinant() < 0;\n    const program = setProgram(camera, scene, material, object);\n    state.setMaterial(material, frontFaceCW);\n\n    //\n\n    let index = geometry.index;\n    const position = geometry.attributes.position;\n\n    //\n\n    if (index === null) {\n      if (position === undefined || position.count === 0) return;\n    } else if (index.count === 0) {\n      return;\n    }\n\n    //\n\n    let rangeFactor = 1;\n    if (material.wireframe === true) {\n      index = geometries.getWireframeAttribute(geometry);\n      rangeFactor = 2;\n    }\n    if (material.morphTargets || material.morphNormals) {\n      morphtargets.update(object, geometry, material, program);\n    }\n    bindingStates.setup(object, material, program, geometry, index);\n    let attribute;\n    let renderer = bufferRenderer;\n    if (index !== null) {\n      attribute = attributes.get(index);\n      renderer = indexedBufferRenderer;\n      renderer.setIndex(attribute);\n    }\n\n    //\n\n    const dataCount = index !== null ? index.count : position.count;\n    const rangeStart = geometry.drawRange.start * rangeFactor;\n    const rangeCount = geometry.drawRange.count * rangeFactor;\n    const groupStart = group !== null ? group.start * rangeFactor : 0;\n    const groupCount = group !== null ? group.count * rangeFactor : Infinity;\n    const drawStart = Math.max(rangeStart, groupStart);\n    const drawEnd = Math.min(dataCount, rangeStart + rangeCount, groupStart + groupCount) - 1;\n    const drawCount = Math.max(0, drawEnd - drawStart + 1);\n    if (drawCount === 0) return;\n\n    //\n\n    if (object.isMesh) {\n      if (material.wireframe === true) {\n        state.setLineWidth(material.wireframeLinewidth * getTargetPixelRatio());\n        renderer.setMode(1);\n      } else {\n        renderer.setMode(4);\n      }\n    } else if (object.isLine) {\n      let lineWidth = material.linewidth;\n      if (lineWidth === undefined) lineWidth = 1; // Not using Line*Material\n\n      state.setLineWidth(lineWidth * getTargetPixelRatio());\n      if (object.isLineSegments) {\n        renderer.setMode(1);\n      } else if (object.isLineLoop) {\n        renderer.setMode(2);\n      } else {\n        renderer.setMode(3);\n      }\n    } else if (object.isPoints) {\n      renderer.setMode(0);\n    } else if (object.isSprite) {\n      renderer.setMode(4);\n    }\n    if (object.isInstancedMesh) {\n      renderer.renderInstances(drawStart, drawCount, object.count);\n    } else if (geometry.isInstancedBufferGeometry) {\n      const instanceCount = Math.min(geometry.instanceCount, geometry._maxInstanceCount);\n      renderer.renderInstances(drawStart, drawCount, instanceCount);\n    } else {\n      renderer.render(drawStart, drawCount);\n    }\n  };\n\n  // Compile\n\n  this.compile = function (scene, camera) {\n    currentRenderState = renderStates.get(scene);\n    currentRenderState.init();\n    scene.traverseVisible(function (object) {\n      if (object.isLight && object.layers.test(camera.layers)) {\n        currentRenderState.pushLight(object);\n        if (object.castShadow) {\n          currentRenderState.pushShadow(object);\n        }\n      }\n    });\n    currentRenderState.setupLights();\n    const compiled = new WeakMap();\n    scene.traverse(function (object) {\n      const material = object.material;\n      if (material) {\n        if (Array.isArray(material)) {\n          for (let i = 0; i < material.length; i++) {\n            const material2 = material[i];\n            if (compiled.has(material2) === false) {\n              initMaterial(material2, scene, object);\n              compiled.set(material2);\n            }\n          }\n        } else if (compiled.has(material) === false) {\n          initMaterial(material, scene, object);\n          compiled.set(material);\n        }\n      }\n    });\n  };\n\n  // Animation Loop\n\n  let onAnimationFrameCallback = null;\n  function onAnimationFrame(time) {\n    if (xr.isPresenting) return;\n    if (onAnimationFrameCallback) onAnimationFrameCallback(time);\n  }\n  const animation = new WebGLAnimation();\n  animation.setAnimationLoop(onAnimationFrame);\n  if (typeof window !== 'undefined') animation.setContext(window);\n  this.setAnimationLoop = function (callback) {\n    onAnimationFrameCallback = callback;\n    xr.setAnimationLoop(callback);\n    callback === null ? animation.stop() : animation.start();\n  };\n\n  // Rendering\n\n  this.render = function (scene, camera) {\n    let renderTarget, forceClear;\n    if (arguments[2] !== undefined) {\n      console.warn('THREE.WebGLRenderer.render(): the renderTarget argument has been removed. Use .setRenderTarget() instead.');\n      renderTarget = arguments[2];\n    }\n    if (arguments[3] !== undefined) {\n      console.warn('THREE.WebGLRenderer.render(): the forceClear argument has been removed. Use .clear() instead.');\n      forceClear = arguments[3];\n    }\n    if (camera !== undefined && camera.isCamera !== true) {\n      console.error('THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.');\n      return;\n    }\n    if (_isContextLost === true) return;\n\n    // reset caching for this frame\n\n    bindingStates.resetDefaultState();\n    _currentMaterialId = -1;\n    _currentCamera = null;\n\n    // update scene graph\n\n    if (scene.autoUpdate === true) scene.updateMatrixWorld();\n\n    // update camera matrices and frustum\n\n    if (camera.parent === null) camera.updateMatrixWorld();\n    if (xr.enabled === true && xr.isPresenting === true) {\n      camera = xr.getCamera(camera);\n    }\n\n    //\n    if (scene.isScene === true) scene.onBeforeRender(_this, scene, camera, renderTarget || _currentRenderTarget);\n    currentRenderState = renderStates.get(scene, renderStateStack.length);\n    currentRenderState.init();\n    renderStateStack.push(currentRenderState);\n    _projScreenMatrix.multiplyMatrices(camera.projectionMatrix, camera.matrixWorldInverse);\n    _frustum.setFromProjectionMatrix(_projScreenMatrix);\n    _localClippingEnabled = this.localClippingEnabled;\n    _clippingEnabled = clipping.init(this.clippingPlanes, _localClippingEnabled, camera);\n    currentRenderList = renderLists.get(scene, camera);\n    currentRenderList.init();\n    projectObject(scene, camera, 0, _this.sortObjects);\n    currentRenderList.finish();\n    if (_this.sortObjects === true) {\n      currentRenderList.sort(_opaqueSort, _transparentSort);\n    }\n\n    //\n\n    if (_clippingEnabled === true) clipping.beginShadows();\n    const shadowsArray = currentRenderState.state.shadowsArray;\n    shadowMap.render(shadowsArray, scene, camera);\n    currentRenderState.setupLights();\n    currentRenderState.setupLightsView(camera);\n    if (_clippingEnabled === true) clipping.endShadows();\n\n    //\n\n    if (this.info.autoReset === true) this.info.reset();\n    if (renderTarget !== undefined) {\n      this.setRenderTarget(renderTarget);\n    }\n\n    //\n\n    background.render(currentRenderList, scene, camera, forceClear);\n\n    // render scene\n\n    const opaqueObjects = currentRenderList.opaque;\n    const transparentObjects = currentRenderList.transparent;\n    if (opaqueObjects.length > 0) renderObjects(opaqueObjects, scene, camera);\n    if (transparentObjects.length > 0) renderObjects(transparentObjects, scene, camera);\n\n    //\n\n    if (scene.isScene === true) scene.onAfterRender(_this, scene, camera);\n\n    //\n\n    if (_currentRenderTarget !== null) {\n      // Generate mipmap if we're using any kind of mipmap filtering\n\n      textures.updateRenderTargetMipmap(_currentRenderTarget);\n\n      // resolve multisample renderbuffers to a single-sample texture if necessary\n\n      textures.updateMultisampleRenderTarget(_currentRenderTarget);\n    }\n\n    // Ensure depth buffer writing is enabled so it can be cleared on next render\n\n    state.buffers.depth.setTest(true);\n    state.buffers.depth.setMask(true);\n    state.buffers.color.setMask(true);\n    state.setPolygonOffset(false);\n\n    // _gl.finish();\n\n    renderStateStack.pop();\n    if (renderStateStack.length > 0) {\n      currentRenderState = renderStateStack[renderStateStack.length - 1];\n    } else {\n      currentRenderState = null;\n    }\n    currentRenderList = null;\n  };\n  function projectObject(object, camera, groupOrder, sortObjects) {\n    if (object.visible === false) return;\n    const visible = object.layers.test(camera.layers);\n    if (visible) {\n      if (object.isGroup) {\n        groupOrder = object.renderOrder;\n      } else if (object.isLOD) {\n        if (object.autoUpdate === true) object.update(camera);\n      } else if (object.isLight) {\n        currentRenderState.pushLight(object);\n        if (object.castShadow) {\n          currentRenderState.pushShadow(object);\n        }\n      } else if (object.isSprite) {\n        if (!object.frustumCulled || _frustum.intersectsSprite(object)) {\n          if (sortObjects) {\n            _vector3.setFromMatrixPosition(object.matrixWorld).applyMatrix4(_projScreenMatrix);\n          }\n          const geometry = objects.update(object);\n          const material = object.material;\n          if (material.visible) {\n            currentRenderList.push(object, geometry, material, groupOrder, _vector3.z, null);\n          }\n        }\n      } else if (object.isImmediateRenderObject) {\n        if (sortObjects) {\n          _vector3.setFromMatrixPosition(object.matrixWorld).applyMatrix4(_projScreenMatrix);\n        }\n        currentRenderList.push(object, null, object.material, groupOrder, _vector3.z, null);\n      } else if (object.isMesh || object.isLine || object.isPoints) {\n        if (object.isSkinnedMesh) {\n          // update skeleton only once in a frame\n\n          if (object.skeleton.frame !== info.render.frame) {\n            object.skeleton.update();\n            object.skeleton.frame = info.render.frame;\n          }\n        }\n        if (!object.frustumCulled || _frustum.intersectsObject(object)) {\n          if (sortObjects) {\n            _vector3.setFromMatrixPosition(object.matrixWorld).applyMatrix4(_projScreenMatrix);\n          }\n          const geometry = objects.update(object);\n          const material = object.material;\n          if (Array.isArray(material)) {\n            const groups = geometry.groups;\n            for (let i = 0, l = groups.length; i < l; i++) {\n              const group = groups[i];\n              const groupMaterial = material[group.materialIndex];\n              if (groupMaterial && groupMaterial.visible) {\n                currentRenderList.push(object, geometry, groupMaterial, groupOrder, _vector3.z, group);\n              }\n            }\n          } else if (material.visible) {\n            currentRenderList.push(object, geometry, material, groupOrder, _vector3.z, null);\n          }\n        }\n      }\n    }\n    const children = object.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      projectObject(children[i], camera, groupOrder, sortObjects);\n    }\n  }\n  function renderObjects(renderList, scene, camera) {\n    const overrideMaterial = scene.isScene === true ? scene.overrideMaterial : null;\n    for (let i = 0, l = renderList.length; i < l; i++) {\n      const renderItem = renderList[i];\n      const object = renderItem.object;\n      const geometry = renderItem.geometry;\n      const material = overrideMaterial === null ? renderItem.material : overrideMaterial;\n      const group = renderItem.group;\n      if (camera.isArrayCamera) {\n        const cameras = camera.cameras;\n        for (let j = 0, jl = cameras.length; j < jl; j++) {\n          const camera2 = cameras[j];\n          if (object.layers.test(camera2.layers)) {\n            state.viewport(_currentViewport.copy(camera2.viewport));\n            currentRenderState.setupLightsView(camera2);\n            renderObject(object, scene, camera2, geometry, material, group);\n          }\n        }\n      } else {\n        renderObject(object, scene, camera, geometry, material, group);\n      }\n    }\n  }\n  function renderObject(object, scene, camera, geometry, material, group) {\n    object.onBeforeRender(_this, scene, camera, geometry, material, group);\n    object.modelViewMatrix.multiplyMatrices(camera.matrixWorldInverse, object.matrixWorld);\n    object.normalMatrix.getNormalMatrix(object.modelViewMatrix);\n    if (object.isImmediateRenderObject) {\n      const program = setProgram(camera, scene, material, object);\n      state.setMaterial(material);\n      bindingStates.reset();\n      renderObjectImmediate(object, program);\n    } else {\n      _this.renderBufferDirect(camera, scene, geometry, material, object, group);\n    }\n    object.onAfterRender(_this, scene, camera, geometry, material, group);\n  }\n  function initMaterial(material, scene, object) {\n    if (scene.isScene !== true) scene = _emptyScene; // scene could be a Mesh, Line, Points, ...\n\n    const materialProperties = properties.get(material);\n    const lights = currentRenderState.state.lights;\n    const shadowsArray = currentRenderState.state.shadowsArray;\n    const lightsStateVersion = lights.state.version;\n    const parameters = programCache.getParameters(material, lights.state, shadowsArray, scene, object);\n    const programCacheKey = programCache.getProgramCacheKey(parameters);\n    let program = materialProperties.program;\n    let programChange = true;\n\n    // always update environment and fog - changing these trigger an initMaterial call, but it's possible that the program doesn't change\n\n    materialProperties.environment = material.isMeshStandardMaterial ? scene.environment : null;\n    materialProperties.fog = scene.fog;\n    materialProperties.envMap = cubemaps.get(material.envMap || materialProperties.environment);\n    if (program === undefined) {\n      // new material\n      material.addEventListener('dispose', onMaterialDispose);\n    } else if (program.cacheKey !== programCacheKey) {\n      // changed glsl or parameters\n      releaseMaterialProgramReference(material);\n    } else if (materialProperties.lightsStateVersion !== lightsStateVersion) {\n      programChange = false;\n    } else if (parameters.shaderID !== undefined) {\n      // same glsl and uniform list\n      return;\n    } else {\n      // only rebuild uniform list\n      programChange = false;\n    }\n    if (programChange) {\n      parameters.uniforms = programCache.getUniforms(material);\n      material.onBeforeCompile(parameters, _this);\n      program = programCache.acquireProgram(parameters, programCacheKey);\n      materialProperties.program = program;\n      materialProperties.uniforms = parameters.uniforms;\n      materialProperties.outputEncoding = parameters.outputEncoding;\n    }\n    const uniforms = materialProperties.uniforms;\n    if (!material.isShaderMaterial && !material.isRawShaderMaterial || material.clipping === true) {\n      materialProperties.numClippingPlanes = clipping.numPlanes;\n      materialProperties.numIntersection = clipping.numIntersection;\n      uniforms.clippingPlanes = clipping.uniform;\n    }\n\n    // store the light setup it was created for\n\n    materialProperties.needsLights = materialNeedsLights(material);\n    materialProperties.lightsStateVersion = lightsStateVersion;\n    if (materialProperties.needsLights) {\n      // wire up the material to this renderer's lighting state\n\n      uniforms.ambientLightColor.value = lights.state.ambient;\n      uniforms.lightProbe.value = lights.state.probe;\n      uniforms.directionalLights.value = lights.state.directional;\n      uniforms.directionalLightShadows.value = lights.state.directionalShadow;\n      uniforms.spotLights.value = lights.state.spot;\n      uniforms.spotLightShadows.value = lights.state.spotShadow;\n      uniforms.rectAreaLights.value = lights.state.rectArea;\n      uniforms.ltc_1.value = lights.state.rectAreaLTC1;\n      uniforms.ltc_2.value = lights.state.rectAreaLTC2;\n      uniforms.pointLights.value = lights.state.point;\n      uniforms.pointLightShadows.value = lights.state.pointShadow;\n      uniforms.hemisphereLights.value = lights.state.hemi;\n      uniforms.directionalShadowMap.value = lights.state.directionalShadowMap;\n      uniforms.directionalShadowMatrix.value = lights.state.directionalShadowMatrix;\n      uniforms.spotShadowMap.value = lights.state.spotShadowMap;\n      uniforms.spotShadowMatrix.value = lights.state.spotShadowMatrix;\n      uniforms.pointShadowMap.value = lights.state.pointShadowMap;\n      uniforms.pointShadowMatrix.value = lights.state.pointShadowMatrix;\n      // TODO (abelnation): add area lights shadow info to uniforms\n    }\n\n    const progUniforms = materialProperties.program.getUniforms();\n    const uniformsList = WebGLUniforms.seqWithValue(progUniforms.seq, uniforms);\n    materialProperties.uniformsList = uniformsList;\n  }\n  function setProgram(camera, scene, material, object) {\n    if (scene.isScene !== true) scene = _emptyScene; // scene could be a Mesh, Line, Points, ...\n\n    textures.resetTextureUnits();\n    const fog = scene.fog;\n    const environment = material.isMeshStandardMaterial ? scene.environment : null;\n    const encoding = _currentRenderTarget === null ? _this.outputEncoding : _currentRenderTarget.texture.encoding;\n    const envMap = cubemaps.get(material.envMap || environment);\n    const materialProperties = properties.get(material);\n    const lights = currentRenderState.state.lights;\n    if (_clippingEnabled === true) {\n      if (_localClippingEnabled === true || camera !== _currentCamera) {\n        const useCache = camera === _currentCamera && material.id === _currentMaterialId;\n\n        // we might want to call this function with some ClippingGroup\n        // object instead of the material, once it becomes feasible\n        // (#8465, #8379)\n        clipping.setState(material, camera, useCache);\n      }\n    }\n    if (material.version === materialProperties.__version) {\n      if (material.fog && materialProperties.fog !== fog) {\n        initMaterial(material, scene, object);\n      } else if (materialProperties.environment !== environment) {\n        initMaterial(material, scene, object);\n      } else if (materialProperties.needsLights && materialProperties.lightsStateVersion !== lights.state.version) {\n        initMaterial(material, scene, object);\n      } else if (materialProperties.numClippingPlanes !== undefined && (materialProperties.numClippingPlanes !== clipping.numPlanes || materialProperties.numIntersection !== clipping.numIntersection)) {\n        initMaterial(material, scene, object);\n      } else if (materialProperties.outputEncoding !== encoding) {\n        initMaterial(material, scene, object);\n      } else if (materialProperties.envMap !== envMap) {\n        initMaterial(material, scene, object);\n      }\n    } else {\n      initMaterial(material, scene, object);\n      materialProperties.__version = material.version;\n    }\n    let refreshProgram = false;\n    let refreshMaterial = false;\n    let refreshLights = false;\n    const program = materialProperties.program,\n      p_uniforms = program.getUniforms(),\n      m_uniforms = materialProperties.uniforms;\n    if (state.useProgram(program.program)) {\n      refreshProgram = true;\n      refreshMaterial = true;\n      refreshLights = true;\n    }\n    if (material.id !== _currentMaterialId) {\n      _currentMaterialId = material.id;\n      refreshMaterial = true;\n    }\n    if (refreshProgram || _currentCamera !== camera) {\n      p_uniforms.setValue(_gl, 'projectionMatrix', camera.projectionMatrix);\n      if (capabilities.logarithmicDepthBuffer) {\n        p_uniforms.setValue(_gl, 'logDepthBufFC', 2.0 / (Math.log(camera.far + 1.0) / Math.LN2));\n      }\n      if (_currentCamera !== camera) {\n        _currentCamera = camera;\n\n        // lighting uniforms depend on the camera so enforce an update\n        // now, in case this material supports lights - or later, when\n        // the next material that does gets activated:\n\n        refreshMaterial = true; // set to true on material change\n        refreshLights = true; // remains set until update done\n      }\n\n      // load material specific uniforms\n      // (shader material also gets them for the sake of genericity)\n\n      if (material.isShaderMaterial || material.isMeshPhongMaterial || material.isMeshToonMaterial || material.isMeshStandardMaterial || material.envMap) {\n        const uCamPos = p_uniforms.map.cameraPosition;\n        if (uCamPos !== undefined) {\n          uCamPos.setValue(_gl, _vector3.setFromMatrixPosition(camera.matrixWorld));\n        }\n      }\n      if (material.isMeshPhongMaterial || material.isMeshToonMaterial || material.isMeshLambertMaterial || material.isMeshBasicMaterial || material.isMeshStandardMaterial || material.isShaderMaterial) {\n        p_uniforms.setValue(_gl, 'isOrthographic', camera.isOrthographicCamera === true);\n      }\n      if (material.isMeshPhongMaterial || material.isMeshToonMaterial || material.isMeshLambertMaterial || material.isMeshBasicMaterial || material.isMeshStandardMaterial || material.isShaderMaterial || material.isShadowMaterial || material.skinning) {\n        p_uniforms.setValue(_gl, 'viewMatrix', camera.matrixWorldInverse);\n      }\n    }\n\n    // skinning uniforms must be set even if material didn't change\n    // auto-setting of texture unit for bone texture must go before other textures\n    // otherwise textures used for skinning can take over texture units reserved for other material textures\n\n    if (material.skinning) {\n      p_uniforms.setOptional(_gl, object, 'bindMatrix');\n      p_uniforms.setOptional(_gl, object, 'bindMatrixInverse');\n      const skeleton = object.skeleton;\n      if (skeleton) {\n        const bones = skeleton.bones;\n        if (capabilities.floatVertexTextures) {\n          if (skeleton.boneTexture === null) {\n            // layout (1 matrix = 4 pixels)\n            //      RGBA RGBA RGBA RGBA (=> column1, column2, column3, column4)\n            //  with  8x8  pixel texture max   16 bones * 4 pixels =  (8 * 8)\n            //       16x16 pixel texture max   64 bones * 4 pixels = (16 * 16)\n            //       32x32 pixel texture max  256 bones * 4 pixels = (32 * 32)\n            //       64x64 pixel texture max 1024 bones * 4 pixels = (64 * 64)\n\n            let size = Math.sqrt(bones.length * 4); // 4 pixels needed for 1 matrix\n            size = MathUtils.ceilPowerOfTwo(size);\n            size = Math.max(size, 4);\n            const boneMatrices = new Float32Array(size * size * 4); // 4 floats per RGBA pixel\n            boneMatrices.set(skeleton.boneMatrices); // copy current values\n\n            const boneTexture = new DataTexture(boneMatrices, size, size, RGBAFormat, FloatType);\n            skeleton.boneMatrices = boneMatrices;\n            skeleton.boneTexture = boneTexture;\n            skeleton.boneTextureSize = size;\n          }\n          p_uniforms.setValue(_gl, 'boneTexture', skeleton.boneTexture, textures);\n          p_uniforms.setValue(_gl, 'boneTextureSize', skeleton.boneTextureSize);\n        } else {\n          p_uniforms.setOptional(_gl, skeleton, 'boneMatrices');\n        }\n      }\n    }\n    if (refreshMaterial || materialProperties.receiveShadow !== object.receiveShadow) {\n      materialProperties.receiveShadow = object.receiveShadow;\n      p_uniforms.setValue(_gl, 'receiveShadow', object.receiveShadow);\n    }\n    if (refreshMaterial) {\n      p_uniforms.setValue(_gl, 'toneMappingExposure', _this.toneMappingExposure);\n      if (materialProperties.needsLights) {\n        // the current material requires lighting info\n\n        // note: all lighting uniforms are always set correctly\n        // they simply reference the renderer's state for their\n        // values\n        //\n        // use the current material's .needsUpdate flags to set\n        // the GL state when required\n\n        markUniformsLightsNeedsUpdate(m_uniforms, refreshLights);\n      }\n\n      // refresh uniforms common to several materials\n\n      if (fog && material.fog) {\n        materials.refreshFogUniforms(m_uniforms, fog);\n      }\n      materials.refreshMaterialUniforms(m_uniforms, material, _pixelRatio, _height);\n      WebGLUniforms.upload(_gl, materialProperties.uniformsList, m_uniforms, textures);\n    }\n    if (material.isShaderMaterial && material.uniformsNeedUpdate === true) {\n      WebGLUniforms.upload(_gl, materialProperties.uniformsList, m_uniforms, textures);\n      material.uniformsNeedUpdate = false;\n    }\n    if (material.isSpriteMaterial) {\n      p_uniforms.setValue(_gl, 'center', object.center);\n    }\n\n    // common matrices\n\n    p_uniforms.setValue(_gl, 'modelViewMatrix', object.modelViewMatrix);\n    p_uniforms.setValue(_gl, 'normalMatrix', object.normalMatrix);\n    p_uniforms.setValue(_gl, 'modelMatrix', object.matrixWorld);\n    return program;\n  }\n\n  // If uniforms are marked as clean, they don't need to be loaded to the GPU.\n\n  function markUniformsLightsNeedsUpdate(uniforms, value) {\n    uniforms.ambientLightColor.needsUpdate = value;\n    uniforms.lightProbe.needsUpdate = value;\n    uniforms.directionalLights.needsUpdate = value;\n    uniforms.directionalLightShadows.needsUpdate = value;\n    uniforms.pointLights.needsUpdate = value;\n    uniforms.pointLightShadows.needsUpdate = value;\n    uniforms.spotLights.needsUpdate = value;\n    uniforms.spotLightShadows.needsUpdate = value;\n    uniforms.rectAreaLights.needsUpdate = value;\n    uniforms.hemisphereLights.needsUpdate = value;\n  }\n  function materialNeedsLights(material) {\n    return material.isMeshLambertMaterial || material.isMeshToonMaterial || material.isMeshPhongMaterial || material.isMeshStandardMaterial || material.isShadowMaterial || material.isShaderMaterial && material.lights === true;\n  }\n\n  //\n  this.setFramebuffer = function (value) {\n    if (_framebuffer !== value && _currentRenderTarget === null) _gl.bindFramebuffer(36160, value);\n    _framebuffer = value;\n  };\n  this.getActiveCubeFace = function () {\n    return _currentActiveCubeFace;\n  };\n  this.getActiveMipmapLevel = function () {\n    return _currentActiveMipmapLevel;\n  };\n  this.getRenderList = function () {\n    return currentRenderList;\n  };\n  this.setRenderList = function (renderList) {\n    currentRenderList = renderList;\n  };\n  this.getRenderTarget = function () {\n    return _currentRenderTarget;\n  };\n  this.setRenderTarget = function (renderTarget, activeCubeFace = 0, activeMipmapLevel = 0) {\n    _currentRenderTarget = renderTarget;\n    _currentActiveCubeFace = activeCubeFace;\n    _currentActiveMipmapLevel = activeMipmapLevel;\n    if (renderTarget && properties.get(renderTarget).__webglFramebuffer === undefined) {\n      textures.setupRenderTarget(renderTarget);\n    }\n    let framebuffer = _framebuffer;\n    let isCube = false;\n    if (renderTarget) {\n      const __webglFramebuffer = properties.get(renderTarget).__webglFramebuffer;\n      if (renderTarget.isWebGLCubeRenderTarget) {\n        framebuffer = __webglFramebuffer[activeCubeFace];\n        isCube = true;\n      } else if (renderTarget.isWebGLMultisampleRenderTarget) {\n        framebuffer = properties.get(renderTarget).__webglMultisampledFramebuffer;\n      } else {\n        framebuffer = __webglFramebuffer;\n      }\n      _currentViewport.copy(renderTarget.viewport);\n      _currentScissor.copy(renderTarget.scissor);\n      _currentScissorTest = renderTarget.scissorTest;\n    } else {\n      _currentViewport.copy(_viewport).multiplyScalar(_pixelRatio).floor();\n      _currentScissor.copy(_scissor).multiplyScalar(_pixelRatio).floor();\n      _currentScissorTest = _scissorTest;\n    }\n    if (_currentFramebuffer !== framebuffer) {\n      _gl.bindFramebuffer(36160, framebuffer);\n      _currentFramebuffer = framebuffer;\n    }\n    state.viewport(_currentViewport);\n    state.scissor(_currentScissor);\n    state.setScissorTest(_currentScissorTest);\n    if (isCube) {\n      const textureProperties = properties.get(renderTarget.texture);\n      _gl.framebufferTexture2D(36160, 36064, 34069 + activeCubeFace, textureProperties.__webglTexture, activeMipmapLevel);\n    }\n  };\n  this.readRenderTargetPixels = function (renderTarget, x, y, width, height, buffer, activeCubeFaceIndex) {\n    if (!(renderTarget && renderTarget.isWebGLRenderTarget)) {\n      console.error('THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.');\n      return;\n    }\n    let framebuffer = properties.get(renderTarget).__webglFramebuffer;\n    if (renderTarget.isWebGLCubeRenderTarget && activeCubeFaceIndex !== undefined) {\n      framebuffer = framebuffer[activeCubeFaceIndex];\n    }\n    if (framebuffer) {\n      let restore = false;\n      if (framebuffer !== _currentFramebuffer) {\n        _gl.bindFramebuffer(36160, framebuffer);\n        restore = true;\n      }\n      try {\n        const texture = renderTarget.texture;\n        const textureFormat = texture.format;\n        const textureType = texture.type;\n        if (textureFormat !== RGBAFormat && utils.convert(textureFormat) !== _gl.getParameter(35739)) {\n          console.error('THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format.');\n          return;\n        }\n        const halfFloatSupportedByExt = textureType === HalfFloatType && (extensions.has('EXT_color_buffer_half_float') || capabilities.isWebGL2 && extensions.has('EXT_color_buffer_float'));\n        if (textureType !== UnsignedByteType && utils.convert(textureType) !== _gl.getParameter(35738) &&\n        // IE11, Edge and Chrome Mac < 52 (#9513)\n        !(textureType === FloatType && (capabilities.isWebGL2 || extensions.has('OES_texture_float') || extensions.has('WEBGL_color_buffer_float'))) &&\n        // Chrome Mac >= 52 and Firefox\n        !halfFloatSupportedByExt) {\n          console.error('THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.');\n          return;\n        }\n        if (_gl.checkFramebufferStatus(36160) === 36053) {\n          // the following if statement ensures valid read requests (no out-of-bounds pixels, see #8604)\n\n          if (x >= 0 && x <= renderTarget.width - width && y >= 0 && y <= renderTarget.height - height) {\n            _gl.readPixels(x, y, width, height, utils.convert(textureFormat), utils.convert(textureType), buffer);\n          }\n        } else {\n          console.error('THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.');\n        }\n      } finally {\n        if (restore) {\n          _gl.bindFramebuffer(36160, _currentFramebuffer);\n        }\n      }\n    }\n  };\n  this.copyFramebufferToTexture = function (position, texture, level = 0) {\n    const levelScale = Math.pow(2, -level);\n    const width = Math.floor(texture.image.width * levelScale);\n    const height = Math.floor(texture.image.height * levelScale);\n    const glFormat = utils.convert(texture.format);\n    textures.setTexture2D(texture, 0);\n    _gl.copyTexImage2D(3553, level, glFormat, position.x, position.y, width, height, 0);\n    state.unbindTexture();\n  };\n  this.copyTextureToTexture = function (position, srcTexture, dstTexture, level = 0) {\n    const width = srcTexture.image.width;\n    const height = srcTexture.image.height;\n    const glFormat = utils.convert(dstTexture.format);\n    const glType = utils.convert(dstTexture.type);\n    textures.setTexture2D(dstTexture, 0);\n\n    // As another texture upload may have changed pixelStorei\n    // parameters, make sure they are correct for the dstTexture\n    _gl.pixelStorei(37440, dstTexture.flipY);\n    _gl.pixelStorei(37441, dstTexture.premultiplyAlpha);\n    _gl.pixelStorei(3317, dstTexture.unpackAlignment);\n    if (srcTexture.isDataTexture) {\n      _gl.texSubImage2D(3553, level, position.x, position.y, width, height, glFormat, glType, srcTexture.image.data);\n    } else {\n      if (srcTexture.isCompressedTexture) {\n        _gl.compressedTexSubImage2D(3553, level, position.x, position.y, srcTexture.mipmaps[0].width, srcTexture.mipmaps[0].height, glFormat, srcTexture.mipmaps[0].data);\n      } else {\n        _gl.texSubImage2D(3553, level, position.x, position.y, glFormat, glType, srcTexture.image);\n      }\n    }\n\n    // Generate mipmaps only when copying level 0\n    if (level === 0 && dstTexture.generateMipmaps) _gl.generateMipmap(3553);\n    state.unbindTexture();\n  };\n  this.initTexture = function (texture) {\n    textures.setTexture2D(texture, 0);\n    state.unbindTexture();\n  };\n  this.resetState = function () {\n    state.reset();\n    bindingStates.reset();\n  };\n  if (typeof __THREE_DEVTOOLS__ !== 'undefined') {\n    __THREE_DEVTOOLS__.dispatchEvent(new CustomEvent('observe', {\n      detail: this\n    })); // eslint-disable-line no-undef\n  }\n}\n\nfunction WebGL1Renderer(parameters) {\n  WebGLRenderer.call(this, parameters);\n}\nWebGL1Renderer.prototype = _extends__default['default'](Object.create(WebGLRenderer.prototype), {\n  constructor: WebGL1Renderer,\n  isWebGL1Renderer: true\n});\nclass Scene extends Object3D {\n  constructor() {\n    super();\n    Object.defineProperty(this, 'isScene', {\n      value: true\n    });\n    this.type = 'Scene';\n    this.background = null;\n    this.environment = null;\n    this.fog = null;\n    this.overrideMaterial = null;\n    this.autoUpdate = true; // checked by the renderer\n\n    if (typeof __THREE_DEVTOOLS__ !== 'undefined') {\n      __THREE_DEVTOOLS__.dispatchEvent(new CustomEvent('observe', {\n        detail: this\n      })); // eslint-disable-line no-undef\n    }\n  }\n\n  copy(source, recursive) {\n    super.copy(source, recursive);\n    if (source.background !== null) this.background = source.background.clone();\n    if (source.environment !== null) this.environment = source.environment.clone();\n    if (source.fog !== null) this.fog = source.fog.clone();\n    if (source.overrideMaterial !== null) this.overrideMaterial = source.overrideMaterial.clone();\n    this.autoUpdate = source.autoUpdate;\n    this.matrixAutoUpdate = source.matrixAutoUpdate;\n    return this;\n  }\n  toJSON(meta) {\n    const data = super.toJSON(meta);\n    if (this.background !== null) data.object.background = this.background.toJSON(meta);\n    if (this.environment !== null) data.object.environment = this.environment.toJSON(meta);\n    if (this.fog !== null) data.object.fog = this.fog.toJSON();\n    return data;\n  }\n}\nfunction InterleavedBuffer(array, stride) {\n  this.array = array;\n  this.stride = stride;\n  this.count = array !== undefined ? array.length / stride : 0;\n  this.usage = StaticDrawUsage;\n  this.updateRange = {\n    offset: 0,\n    count: -1\n  };\n  this.version = 0;\n  this.uuid = MathUtils.generateUUID();\n}\nObject.defineProperty(InterleavedBuffer.prototype, 'needsUpdate', {\n  set: function (value) {\n    if (value === true) this.version++;\n  }\n});\n_extends__default['default'](InterleavedBuffer.prototype, {\n  isInterleavedBuffer: true,\n  onUploadCallback: function () {},\n  setUsage: function (value) {\n    this.usage = value;\n    return this;\n  },\n  copy: function (source) {\n    this.array = new source.array.constructor(source.array);\n    this.count = source.count;\n    this.stride = source.stride;\n    this.usage = source.usage;\n    return this;\n  },\n  copyAt: function (index1, attribute, index2) {\n    index1 *= this.stride;\n    index2 *= attribute.stride;\n    for (let i = 0, l = this.stride; i < l; i++) {\n      this.array[index1 + i] = attribute.array[index2 + i];\n    }\n    return this;\n  },\n  set: function (value, offset = 0) {\n    this.array.set(value, offset);\n    return this;\n  },\n  clone: function (data) {\n    if (data.arrayBuffers === undefined) {\n      data.arrayBuffers = {};\n    }\n    if (this.array.buffer._uuid === undefined) {\n      this.array.buffer._uuid = MathUtils.generateUUID();\n    }\n    if (data.arrayBuffers[this.array.buffer._uuid] === undefined) {\n      data.arrayBuffers[this.array.buffer._uuid] = this.array.slice(0).buffer;\n    }\n    const array = new this.array.constructor(data.arrayBuffers[this.array.buffer._uuid]);\n    const ib = new InterleavedBuffer(array, this.stride);\n    ib.setUsage(this.usage);\n    return ib;\n  },\n  onUpload: function (callback) {\n    this.onUploadCallback = callback;\n    return this;\n  },\n  toJSON: function (data) {\n    if (data.arrayBuffers === undefined) {\n      data.arrayBuffers = {};\n    }\n\n    // generate UUID for array buffer if necessary\n\n    if (this.array.buffer._uuid === undefined) {\n      this.array.buffer._uuid = MathUtils.generateUUID();\n    }\n    if (data.arrayBuffers[this.array.buffer._uuid] === undefined) {\n      data.arrayBuffers[this.array.buffer._uuid] = Array.prototype.slice.call(new Uint32Array(this.array.buffer));\n    }\n\n    //\n\n    return {\n      uuid: this.uuid,\n      buffer: this.array.buffer._uuid,\n      type: this.array.constructor.name,\n      stride: this.stride\n    };\n  }\n});\nconst _vector$6 = new Vector3();\nfunction InterleavedBufferAttribute(interleavedBuffer, itemSize, offset, normalized) {\n  this.name = '';\n  this.data = interleavedBuffer;\n  this.itemSize = itemSize;\n  this.offset = offset;\n  this.normalized = normalized === true;\n}\nObject.defineProperties(InterleavedBufferAttribute.prototype, {\n  count: {\n    get: function () {\n      return this.data.count;\n    }\n  },\n  array: {\n    get: function () {\n      return this.data.array;\n    }\n  },\n  needsUpdate: {\n    set: function (value) {\n      this.data.needsUpdate = value;\n    }\n  }\n});\n_extends__default['default'](InterleavedBufferAttribute.prototype, {\n  isInterleavedBufferAttribute: true,\n  applyMatrix4: function (m) {\n    for (let i = 0, l = this.data.count; i < l; i++) {\n      _vector$6.x = this.getX(i);\n      _vector$6.y = this.getY(i);\n      _vector$6.z = this.getZ(i);\n      _vector$6.applyMatrix4(m);\n      this.setXYZ(i, _vector$6.x, _vector$6.y, _vector$6.z);\n    }\n    return this;\n  },\n  setX: function (index, x) {\n    this.data.array[index * this.data.stride + this.offset] = x;\n    return this;\n  },\n  setY: function (index, y) {\n    this.data.array[index * this.data.stride + this.offset + 1] = y;\n    return this;\n  },\n  setZ: function (index, z) {\n    this.data.array[index * this.data.stride + this.offset + 2] = z;\n    return this;\n  },\n  setW: function (index, w) {\n    this.data.array[index * this.data.stride + this.offset + 3] = w;\n    return this;\n  },\n  getX: function (index) {\n    return this.data.array[index * this.data.stride + this.offset];\n  },\n  getY: function (index) {\n    return this.data.array[index * this.data.stride + this.offset + 1];\n  },\n  getZ: function (index) {\n    return this.data.array[index * this.data.stride + this.offset + 2];\n  },\n  getW: function (index) {\n    return this.data.array[index * this.data.stride + this.offset + 3];\n  },\n  setXY: function (index, x, y) {\n    index = index * this.data.stride + this.offset;\n    this.data.array[index + 0] = x;\n    this.data.array[index + 1] = y;\n    return this;\n  },\n  setXYZ: function (index, x, y, z) {\n    index = index * this.data.stride + this.offset;\n    this.data.array[index + 0] = x;\n    this.data.array[index + 1] = y;\n    this.data.array[index + 2] = z;\n    return this;\n  },\n  setXYZW: function (index, x, y, z, w) {\n    index = index * this.data.stride + this.offset;\n    this.data.array[index + 0] = x;\n    this.data.array[index + 1] = y;\n    this.data.array[index + 2] = z;\n    this.data.array[index + 3] = w;\n    return this;\n  },\n  clone: function (data) {\n    if (data === undefined) {\n      console.log('THREE.InterleavedBufferAttribute.clone(): Cloning an interlaved buffer attribute will deinterleave buffer data.');\n      const array = [];\n      for (let i = 0; i < this.count; i++) {\n        const index = i * this.data.stride + this.offset;\n        for (let j = 0; j < this.itemSize; j++) {\n          array.push(this.data.array[index + j]);\n        }\n      }\n      return new BufferAttribute(new this.array.constructor(array), this.itemSize, this.normalized);\n    } else {\n      if (data.interleavedBuffers === undefined) {\n        data.interleavedBuffers = {};\n      }\n      if (data.interleavedBuffers[this.data.uuid] === undefined) {\n        data.interleavedBuffers[this.data.uuid] = this.data.clone(data);\n      }\n      return new InterleavedBufferAttribute(data.interleavedBuffers[this.data.uuid], this.itemSize, this.offset, this.normalized);\n    }\n  },\n  toJSON: function (data) {\n    if (data === undefined) {\n      console.log('THREE.InterleavedBufferAttribute.toJSON(): Serializing an interlaved buffer attribute will deinterleave buffer data.');\n      const array = [];\n      for (let i = 0; i < this.count; i++) {\n        const index = i * this.data.stride + this.offset;\n        for (let j = 0; j < this.itemSize; j++) {\n          array.push(this.data.array[index + j]);\n        }\n      }\n\n      // deinterleave data and save it as an ordinary buffer attribute for now\n\n      return {\n        itemSize: this.itemSize,\n        type: this.array.constructor.name,\n        array: array,\n        normalized: this.normalized\n      };\n    } else {\n      // save as true interlaved attribtue\n\n      if (data.interleavedBuffers === undefined) {\n        data.interleavedBuffers = {};\n      }\n      if (data.interleavedBuffers[this.data.uuid] === undefined) {\n        data.interleavedBuffers[this.data.uuid] = this.data.toJSON(data);\n      }\n      return {\n        isInterleavedBufferAttribute: true,\n        itemSize: this.itemSize,\n        data: this.data.uuid,\n        offset: this.offset,\n        normalized: this.normalized\n      };\n    }\n  }\n});\n\n/**\n * parameters = {\n *  color: <hex>,\n *  map: new THREE.Texture( <Image> ),\n *  alphaMap: new THREE.Texture( <Image> ),\n *  rotation: <float>,\n *  sizeAttenuation: <bool>\n * }\n */\n\nfunction SpriteMaterial(parameters) {\n  Material.call(this);\n  this.type = 'SpriteMaterial';\n  this.color = new Color(0xffffff);\n  this.map = null;\n  this.alphaMap = null;\n  this.rotation = 0;\n  this.sizeAttenuation = true;\n  this.transparent = true;\n  this.setValues(parameters);\n}\nSpriteMaterial.prototype = Object.create(Material.prototype);\nSpriteMaterial.prototype.constructor = SpriteMaterial;\nSpriteMaterial.prototype.isSpriteMaterial = true;\nSpriteMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  this.map = source.map;\n  this.alphaMap = source.alphaMap;\n  this.rotation = source.rotation;\n  this.sizeAttenuation = source.sizeAttenuation;\n  return this;\n};\nlet _geometry;\nconst _intersectPoint = new Vector3();\nconst _worldScale = new Vector3();\nconst _mvPosition = new Vector3();\nconst _alignedPosition = new Vector2();\nconst _rotatedPosition = new Vector2();\nconst _viewWorldMatrix = new Matrix4();\nconst _vA$1 = new Vector3();\nconst _vB$1 = new Vector3();\nconst _vC$1 = new Vector3();\nconst _uvA$1 = new Vector2();\nconst _uvB$1 = new Vector2();\nconst _uvC$1 = new Vector2();\nfunction Sprite(material) {\n  Object3D.call(this);\n  this.type = 'Sprite';\n  if (_geometry === undefined) {\n    _geometry = new BufferGeometry();\n    const float32Array = new Float32Array([-0.5, -0.5, 0, 0, 0, 0.5, -0.5, 0, 1, 0, 0.5, 0.5, 0, 1, 1, -0.5, 0.5, 0, 0, 1]);\n    const interleavedBuffer = new InterleavedBuffer(float32Array, 5);\n    _geometry.setIndex([0, 1, 2, 0, 2, 3]);\n    _geometry.setAttribute('position', new InterleavedBufferAttribute(interleavedBuffer, 3, 0, false));\n    _geometry.setAttribute('uv', new InterleavedBufferAttribute(interleavedBuffer, 2, 3, false));\n  }\n  this.geometry = _geometry;\n  this.material = material !== undefined ? material : new SpriteMaterial();\n  this.center = new Vector2(0.5, 0.5);\n}\nSprite.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Sprite,\n  isSprite: true,\n  raycast: function (raycaster, intersects) {\n    if (raycaster.camera === null) {\n      console.error('THREE.Sprite: \"Raycaster.camera\" needs to be set in order to raycast against sprites.');\n    }\n    _worldScale.setFromMatrixScale(this.matrixWorld);\n    _viewWorldMatrix.copy(raycaster.camera.matrixWorld);\n    this.modelViewMatrix.multiplyMatrices(raycaster.camera.matrixWorldInverse, this.matrixWorld);\n    _mvPosition.setFromMatrixPosition(this.modelViewMatrix);\n    if (raycaster.camera.isPerspectiveCamera && this.material.sizeAttenuation === false) {\n      _worldScale.multiplyScalar(-_mvPosition.z);\n    }\n    const rotation = this.material.rotation;\n    let sin, cos;\n    if (rotation !== 0) {\n      cos = Math.cos(rotation);\n      sin = Math.sin(rotation);\n    }\n    const center = this.center;\n    transformVertex(_vA$1.set(-0.5, -0.5, 0), _mvPosition, center, _worldScale, sin, cos);\n    transformVertex(_vB$1.set(0.5, -0.5, 0), _mvPosition, center, _worldScale, sin, cos);\n    transformVertex(_vC$1.set(0.5, 0.5, 0), _mvPosition, center, _worldScale, sin, cos);\n    _uvA$1.set(0, 0);\n    _uvB$1.set(1, 0);\n    _uvC$1.set(1, 1);\n\n    // check first triangle\n    let intersect = raycaster.ray.intersectTriangle(_vA$1, _vB$1, _vC$1, false, _intersectPoint);\n    if (intersect === null) {\n      // check second triangle\n      transformVertex(_vB$1.set(-0.5, 0.5, 0), _mvPosition, center, _worldScale, sin, cos);\n      _uvB$1.set(0, 1);\n      intersect = raycaster.ray.intersectTriangle(_vA$1, _vC$1, _vB$1, false, _intersectPoint);\n      if (intersect === null) {\n        return;\n      }\n    }\n    const distance = raycaster.ray.origin.distanceTo(_intersectPoint);\n    if (distance < raycaster.near || distance > raycaster.far) return;\n    intersects.push({\n      distance: distance,\n      point: _intersectPoint.clone(),\n      uv: Triangle.getUV(_intersectPoint, _vA$1, _vB$1, _vC$1, _uvA$1, _uvB$1, _uvC$1, new Vector2()),\n      face: null,\n      object: this\n    });\n  },\n  copy: function (source) {\n    Object3D.prototype.copy.call(this, source);\n    if (source.center !== undefined) this.center.copy(source.center);\n    this.material = source.material;\n    return this;\n  }\n});\nfunction transformVertex(vertexPosition, mvPosition, center, scale, sin, cos) {\n  // compute position in camera space\n  _alignedPosition.subVectors(vertexPosition, center).addScalar(0.5).multiply(scale);\n\n  // to check if rotation is not zero\n  if (sin !== undefined) {\n    _rotatedPosition.x = cos * _alignedPosition.x - sin * _alignedPosition.y;\n    _rotatedPosition.y = sin * _alignedPosition.x + cos * _alignedPosition.y;\n  } else {\n    _rotatedPosition.copy(_alignedPosition);\n  }\n  vertexPosition.copy(mvPosition);\n  vertexPosition.x += _rotatedPosition.x;\n  vertexPosition.y += _rotatedPosition.y;\n\n  // transform to world space\n  vertexPosition.applyMatrix4(_viewWorldMatrix);\n}\nconst _v1$4 = new Vector3();\nconst _v2$2 = new Vector3();\nfunction LOD() {\n  Object3D.call(this);\n  this._currentLevel = 0;\n  this.type = 'LOD';\n  Object.defineProperties(this, {\n    levels: {\n      enumerable: true,\n      value: []\n    }\n  });\n  this.autoUpdate = true;\n}\nLOD.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: LOD,\n  isLOD: true,\n  copy: function (source) {\n    Object3D.prototype.copy.call(this, source, false);\n    const levels = source.levels;\n    for (let i = 0, l = levels.length; i < l; i++) {\n      const level = levels[i];\n      this.addLevel(level.object.clone(), level.distance);\n    }\n    this.autoUpdate = source.autoUpdate;\n    return this;\n  },\n  addLevel: function (object, distance = 0) {\n    distance = Math.abs(distance);\n    const levels = this.levels;\n    let l;\n    for (l = 0; l < levels.length; l++) {\n      if (distance < levels[l].distance) {\n        break;\n      }\n    }\n    levels.splice(l, 0, {\n      distance: distance,\n      object: object\n    });\n    this.add(object);\n    return this;\n  },\n  getCurrentLevel: function () {\n    return this._currentLevel;\n  },\n  getObjectForDistance: function (distance) {\n    const levels = this.levels;\n    if (levels.length > 0) {\n      let i, l;\n      for (i = 1, l = levels.length; i < l; i++) {\n        if (distance < levels[i].distance) {\n          break;\n        }\n      }\n      return levels[i - 1].object;\n    }\n    return null;\n  },\n  raycast: function (raycaster, intersects) {\n    const levels = this.levels;\n    if (levels.length > 0) {\n      _v1$4.setFromMatrixPosition(this.matrixWorld);\n      const distance = raycaster.ray.origin.distanceTo(_v1$4);\n      this.getObjectForDistance(distance).raycast(raycaster, intersects);\n    }\n  },\n  update: function (camera) {\n    const levels = this.levels;\n    if (levels.length > 1) {\n      _v1$4.setFromMatrixPosition(camera.matrixWorld);\n      _v2$2.setFromMatrixPosition(this.matrixWorld);\n      const distance = _v1$4.distanceTo(_v2$2) / camera.zoom;\n      levels[0].object.visible = true;\n      let i, l;\n      for (i = 1, l = levels.length; i < l; i++) {\n        if (distance >= levels[i].distance) {\n          levels[i - 1].object.visible = false;\n          levels[i].object.visible = true;\n        } else {\n          break;\n        }\n      }\n      this._currentLevel = i - 1;\n      for (; i < l; i++) {\n        levels[i].object.visible = false;\n      }\n    }\n  },\n  toJSON: function (meta) {\n    const data = Object3D.prototype.toJSON.call(this, meta);\n    if (this.autoUpdate === false) data.object.autoUpdate = false;\n    data.object.levels = [];\n    const levels = this.levels;\n    for (let i = 0, l = levels.length; i < l; i++) {\n      const level = levels[i];\n      data.object.levels.push({\n        object: level.object.uuid,\n        distance: level.distance\n      });\n    }\n    return data;\n  }\n});\nconst _basePosition = new Vector3();\nconst _skinIndex = new Vector4();\nconst _skinWeight = new Vector4();\nconst _vector$7 = new Vector3();\nconst _matrix$1 = new Matrix4();\nfunction SkinnedMesh(geometry, material) {\n  if (geometry && geometry.isGeometry) {\n    console.error('THREE.SkinnedMesh no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.');\n  }\n  Mesh.call(this, geometry, material);\n  this.type = 'SkinnedMesh';\n  this.bindMode = 'attached';\n  this.bindMatrix = new Matrix4();\n  this.bindMatrixInverse = new Matrix4();\n}\nSkinnedMesh.prototype = _extends__default['default'](Object.create(Mesh.prototype), {\n  constructor: SkinnedMesh,\n  isSkinnedMesh: true,\n  copy: function (source) {\n    Mesh.prototype.copy.call(this, source);\n    this.bindMode = source.bindMode;\n    this.bindMatrix.copy(source.bindMatrix);\n    this.bindMatrixInverse.copy(source.bindMatrixInverse);\n    this.skeleton = source.skeleton;\n    return this;\n  },\n  bind: function (skeleton, bindMatrix) {\n    this.skeleton = skeleton;\n    if (bindMatrix === undefined) {\n      this.updateMatrixWorld(true);\n      this.skeleton.calculateInverses();\n      bindMatrix = this.matrixWorld;\n    }\n    this.bindMatrix.copy(bindMatrix);\n    this.bindMatrixInverse.copy(bindMatrix).invert();\n  },\n  pose: function () {\n    this.skeleton.pose();\n  },\n  normalizeSkinWeights: function () {\n    const vector = new Vector4();\n    const skinWeight = this.geometry.attributes.skinWeight;\n    for (let i = 0, l = skinWeight.count; i < l; i++) {\n      vector.x = skinWeight.getX(i);\n      vector.y = skinWeight.getY(i);\n      vector.z = skinWeight.getZ(i);\n      vector.w = skinWeight.getW(i);\n      const scale = 1.0 / vector.manhattanLength();\n      if (scale !== Infinity) {\n        vector.multiplyScalar(scale);\n      } else {\n        vector.set(1, 0, 0, 0); // do something reasonable\n      }\n\n      skinWeight.setXYZW(i, vector.x, vector.y, vector.z, vector.w);\n    }\n  },\n  updateMatrixWorld: function (force) {\n    Mesh.prototype.updateMatrixWorld.call(this, force);\n    if (this.bindMode === 'attached') {\n      this.bindMatrixInverse.copy(this.matrixWorld).invert();\n    } else if (this.bindMode === 'detached') {\n      this.bindMatrixInverse.copy(this.bindMatrix).invert();\n    } else {\n      console.warn('THREE.SkinnedMesh: Unrecognized bindMode: ' + this.bindMode);\n    }\n  },\n  boneTransform: function (index, target) {\n    const skeleton = this.skeleton;\n    const geometry = this.geometry;\n    _skinIndex.fromBufferAttribute(geometry.attributes.skinIndex, index);\n    _skinWeight.fromBufferAttribute(geometry.attributes.skinWeight, index);\n    _basePosition.fromBufferAttribute(geometry.attributes.position, index).applyMatrix4(this.bindMatrix);\n    target.set(0, 0, 0);\n    for (let i = 0; i < 4; i++) {\n      const weight = _skinWeight.getComponent(i);\n      if (weight !== 0) {\n        const boneIndex = _skinIndex.getComponent(i);\n        _matrix$1.multiplyMatrices(skeleton.bones[boneIndex].matrixWorld, skeleton.boneInverses[boneIndex]);\n        target.addScaledVector(_vector$7.copy(_basePosition).applyMatrix4(_matrix$1), weight);\n      }\n    }\n    return target.applyMatrix4(this.bindMatrixInverse);\n  }\n});\nfunction Bone() {\n  Object3D.call(this);\n  this.type = 'Bone';\n}\nBone.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Bone,\n  isBone: true\n});\nconst _offsetMatrix = new Matrix4();\nconst _identityMatrix = new Matrix4();\nfunction Skeleton(bones = [], boneInverses = []) {\n  this.uuid = MathUtils.generateUUID();\n  this.bones = bones.slice(0);\n  this.boneInverses = boneInverses;\n  this.boneMatrices = null;\n  this.boneTexture = null;\n  this.boneTextureSize = 0;\n  this.frame = -1;\n  this.init();\n}\n_extends__default['default'](Skeleton.prototype, {\n  init: function () {\n    const bones = this.bones;\n    const boneInverses = this.boneInverses;\n    this.boneMatrices = new Float32Array(bones.length * 16);\n\n    // calculate inverse bone matrices if necessary\n\n    if (boneInverses.length === 0) {\n      this.calculateInverses();\n    } else {\n      // handle special case\n\n      if (bones.length !== boneInverses.length) {\n        console.warn('THREE.Skeleton: Number of inverse bone matrices does not match amount of bones.');\n        this.boneInverses = [];\n        for (let i = 0, il = this.bones.length; i < il; i++) {\n          this.boneInverses.push(new Matrix4());\n        }\n      }\n    }\n  },\n  calculateInverses: function () {\n    this.boneInverses.length = 0;\n    for (let i = 0, il = this.bones.length; i < il; i++) {\n      const inverse = new Matrix4();\n      if (this.bones[i]) {\n        inverse.copy(this.bones[i].matrixWorld).invert();\n      }\n      this.boneInverses.push(inverse);\n    }\n  },\n  pose: function () {\n    // recover the bind-time world matrices\n\n    for (let i = 0, il = this.bones.length; i < il; i++) {\n      const bone = this.bones[i];\n      if (bone) {\n        bone.matrixWorld.copy(this.boneInverses[i]).invert();\n      }\n    }\n\n    // compute the local matrices, positions, rotations and scales\n\n    for (let i = 0, il = this.bones.length; i < il; i++) {\n      const bone = this.bones[i];\n      if (bone) {\n        if (bone.parent && bone.parent.isBone) {\n          bone.matrix.copy(bone.parent.matrixWorld).invert();\n          bone.matrix.multiply(bone.matrixWorld);\n        } else {\n          bone.matrix.copy(bone.matrixWorld);\n        }\n        bone.matrix.decompose(bone.position, bone.quaternion, bone.scale);\n      }\n    }\n  },\n  update: function () {\n    const bones = this.bones;\n    const boneInverses = this.boneInverses;\n    const boneMatrices = this.boneMatrices;\n    const boneTexture = this.boneTexture;\n\n    // flatten bone matrices to array\n\n    for (let i = 0, il = bones.length; i < il; i++) {\n      // compute the offset between the current and the original transform\n\n      const matrix = bones[i] ? bones[i].matrixWorld : _identityMatrix;\n      _offsetMatrix.multiplyMatrices(matrix, boneInverses[i]);\n      _offsetMatrix.toArray(boneMatrices, i * 16);\n    }\n    if (boneTexture !== null) {\n      boneTexture.needsUpdate = true;\n    }\n  },\n  clone: function () {\n    return new Skeleton(this.bones, this.boneInverses);\n  },\n  getBoneByName: function (name) {\n    for (let i = 0, il = this.bones.length; i < il; i++) {\n      const bone = this.bones[i];\n      if (bone.name === name) {\n        return bone;\n      }\n    }\n    return undefined;\n  },\n  dispose: function () {\n    if (this.boneTexture !== null) {\n      this.boneTexture.dispose();\n      this.boneTexture = null;\n    }\n  },\n  fromJSON: function (json, bones) {\n    this.uuid = json.uuid;\n    for (let i = 0, l = json.bones.length; i < l; i++) {\n      const uuid = json.bones[i];\n      let bone = bones[uuid];\n      if (bone === undefined) {\n        console.warn('THREE.Skeleton: No bone found with UUID:', uuid);\n        bone = new Bone();\n      }\n      this.bones.push(bone);\n      this.boneInverses.push(new Matrix4().fromArray(json.boneInverses[i]));\n    }\n    this.init();\n    return this;\n  },\n  toJSON: function () {\n    const data = {\n      metadata: {\n        version: 4.5,\n        type: 'Skeleton',\n        generator: 'Skeleton.toJSON'\n      },\n      bones: [],\n      boneInverses: []\n    };\n    data.uuid = this.uuid;\n    const bones = this.bones;\n    const boneInverses = this.boneInverses;\n    for (let i = 0, l = bones.length; i < l; i++) {\n      const bone = bones[i];\n      data.bones.push(bone.uuid);\n      const boneInverse = boneInverses[i];\n      data.boneInverses.push(boneInverse.toArray());\n    }\n    return data;\n  }\n});\nconst _instanceLocalMatrix = new Matrix4();\nconst _instanceWorldMatrix = new Matrix4();\nconst _instanceIntersects = [];\nconst _mesh = new Mesh();\nfunction InstancedMesh(geometry, material, count) {\n  Mesh.call(this, geometry, material);\n  this.instanceMatrix = new BufferAttribute(new Float32Array(count * 16), 16);\n  this.instanceColor = null;\n  this.count = count;\n  this.frustumCulled = false;\n}\nInstancedMesh.prototype = _extends__default['default'](Object.create(Mesh.prototype), {\n  constructor: InstancedMesh,\n  isInstancedMesh: true,\n  copy: function (source) {\n    Mesh.prototype.copy.call(this, source);\n    this.instanceMatrix.copy(source.instanceMatrix);\n    if (source.instanceColor !== null) this.instanceColor = source.instanceColor.clone();\n    this.count = source.count;\n    return this;\n  },\n  getColorAt: function (index, color) {\n    color.fromArray(this.instanceColor.array, index * 3);\n  },\n  getMatrixAt: function (index, matrix) {\n    matrix.fromArray(this.instanceMatrix.array, index * 16);\n  },\n  raycast: function (raycaster, intersects) {\n    const matrixWorld = this.matrixWorld;\n    const raycastTimes = this.count;\n    _mesh.geometry = this.geometry;\n    _mesh.material = this.material;\n    if (_mesh.material === undefined) return;\n    for (let instanceId = 0; instanceId < raycastTimes; instanceId++) {\n      // calculate the world matrix for each instance\n\n      this.getMatrixAt(instanceId, _instanceLocalMatrix);\n      _instanceWorldMatrix.multiplyMatrices(matrixWorld, _instanceLocalMatrix);\n\n      // the mesh represents this single instance\n\n      _mesh.matrixWorld = _instanceWorldMatrix;\n      _mesh.raycast(raycaster, _instanceIntersects);\n\n      // process the result of raycast\n\n      for (let i = 0, l = _instanceIntersects.length; i < l; i++) {\n        const intersect = _instanceIntersects[i];\n        intersect.instanceId = instanceId;\n        intersect.object = this;\n        intersects.push(intersect);\n      }\n      _instanceIntersects.length = 0;\n    }\n  },\n  setColorAt: function (index, color) {\n    if (this.instanceColor === null) {\n      this.instanceColor = new BufferAttribute(new Float32Array(this.count * 3), 3);\n    }\n    color.toArray(this.instanceColor.array, index * 3);\n  },\n  setMatrixAt: function (index, matrix) {\n    matrix.toArray(this.instanceMatrix.array, index * 16);\n  },\n  updateMorphTargets: function () {},\n  dispose: function () {\n    this.dispatchEvent({\n      type: 'dispose'\n    });\n  }\n});\n\n/**\n * parameters = {\n *  color: <hex>,\n *  opacity: <float>,\n *\n *  linewidth: <float>,\n *  linecap: \"round\",\n *  linejoin: \"round\"\n * }\n */\n\nfunction LineBasicMaterial(parameters) {\n  Material.call(this);\n  this.type = 'LineBasicMaterial';\n  this.color = new Color(0xffffff);\n  this.linewidth = 1;\n  this.linecap = 'round';\n  this.linejoin = 'round';\n  this.morphTargets = false;\n  this.setValues(parameters);\n}\nLineBasicMaterial.prototype = Object.create(Material.prototype);\nLineBasicMaterial.prototype.constructor = LineBasicMaterial;\nLineBasicMaterial.prototype.isLineBasicMaterial = true;\nLineBasicMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  this.linewidth = source.linewidth;\n  this.linecap = source.linecap;\n  this.linejoin = source.linejoin;\n  this.morphTargets = source.morphTargets;\n  return this;\n};\nconst _start = new Vector3();\nconst _end = new Vector3();\nconst _inverseMatrix$1 = new Matrix4();\nconst _ray$1 = new Ray();\nconst _sphere$2 = new Sphere();\nfunction Line(geometry = new BufferGeometry(), material = new LineBasicMaterial()) {\n  Object3D.call(this);\n  this.type = 'Line';\n  this.geometry = geometry;\n  this.material = material;\n  this.updateMorphTargets();\n}\nLine.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Line,\n  isLine: true,\n  copy: function (source) {\n    Object3D.prototype.copy.call(this, source);\n    this.material = source.material;\n    this.geometry = source.geometry;\n    return this;\n  },\n  computeLineDistances: function () {\n    const geometry = this.geometry;\n    if (geometry.isBufferGeometry) {\n      // we assume non-indexed geometry\n\n      if (geometry.index === null) {\n        const positionAttribute = geometry.attributes.position;\n        const lineDistances = [0];\n        for (let i = 1, l = positionAttribute.count; i < l; i++) {\n          _start.fromBufferAttribute(positionAttribute, i - 1);\n          _end.fromBufferAttribute(positionAttribute, i);\n          lineDistances[i] = lineDistances[i - 1];\n          lineDistances[i] += _start.distanceTo(_end);\n        }\n        geometry.setAttribute('lineDistance', new Float32BufferAttribute(lineDistances, 1));\n      } else {\n        console.warn('THREE.Line.computeLineDistances(): Computation only possible with non-indexed BufferGeometry.');\n      }\n    } else if (geometry.isGeometry) {\n      console.error('THREE.Line.computeLineDistances() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.');\n    }\n    return this;\n  },\n  raycast: function (raycaster, intersects) {\n    const geometry = this.geometry;\n    const matrixWorld = this.matrixWorld;\n    const threshold = raycaster.params.Line.threshold;\n\n    // Checking boundingSphere distance to ray\n\n    if (geometry.boundingSphere === null) geometry.computeBoundingSphere();\n    _sphere$2.copy(geometry.boundingSphere);\n    _sphere$2.applyMatrix4(matrixWorld);\n    _sphere$2.radius += threshold;\n    if (raycaster.ray.intersectsSphere(_sphere$2) === false) return;\n\n    //\n\n    _inverseMatrix$1.copy(matrixWorld).invert();\n    _ray$1.copy(raycaster.ray).applyMatrix4(_inverseMatrix$1);\n    const localThreshold = threshold / ((this.scale.x + this.scale.y + this.scale.z) / 3);\n    const localThresholdSq = localThreshold * localThreshold;\n    const vStart = new Vector3();\n    const vEnd = new Vector3();\n    const interSegment = new Vector3();\n    const interRay = new Vector3();\n    const step = this.isLineSegments ? 2 : 1;\n    if (geometry.isBufferGeometry) {\n      const index = geometry.index;\n      const attributes = geometry.attributes;\n      const positionAttribute = attributes.position;\n      if (index !== null) {\n        const indices = index.array;\n        for (let i = 0, l = indices.length - 1; i < l; i += step) {\n          const a = indices[i];\n          const b = indices[i + 1];\n          vStart.fromBufferAttribute(positionAttribute, a);\n          vEnd.fromBufferAttribute(positionAttribute, b);\n          const distSq = _ray$1.distanceSqToSegment(vStart, vEnd, interRay, interSegment);\n          if (distSq > localThresholdSq) continue;\n          interRay.applyMatrix4(this.matrixWorld); //Move back to world space for distance calculation\n\n          const distance = raycaster.ray.origin.distanceTo(interRay);\n          if (distance < raycaster.near || distance > raycaster.far) continue;\n          intersects.push({\n            distance: distance,\n            // What do we want? intersection point on the ray or on the segment??\n            // point: raycaster.ray.at( distance ),\n            point: interSegment.clone().applyMatrix4(this.matrixWorld),\n            index: i,\n            face: null,\n            faceIndex: null,\n            object: this\n          });\n        }\n      } else {\n        for (let i = 0, l = positionAttribute.count - 1; i < l; i += step) {\n          vStart.fromBufferAttribute(positionAttribute, i);\n          vEnd.fromBufferAttribute(positionAttribute, i + 1);\n          const distSq = _ray$1.distanceSqToSegment(vStart, vEnd, interRay, interSegment);\n          if (distSq > localThresholdSq) continue;\n          interRay.applyMatrix4(this.matrixWorld); //Move back to world space for distance calculation\n\n          const distance = raycaster.ray.origin.distanceTo(interRay);\n          if (distance < raycaster.near || distance > raycaster.far) continue;\n          intersects.push({\n            distance: distance,\n            // What do we want? intersection point on the ray or on the segment??\n            // point: raycaster.ray.at( distance ),\n            point: interSegment.clone().applyMatrix4(this.matrixWorld),\n            index: i,\n            face: null,\n            faceIndex: null,\n            object: this\n          });\n        }\n      }\n    } else if (geometry.isGeometry) {\n      console.error('THREE.Line.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.');\n    }\n  },\n  updateMorphTargets: function () {\n    const geometry = this.geometry;\n    if (geometry.isBufferGeometry) {\n      const morphAttributes = geometry.morphAttributes;\n      const keys = Object.keys(morphAttributes);\n      if (keys.length > 0) {\n        const morphAttribute = morphAttributes[keys[0]];\n        if (morphAttribute !== undefined) {\n          this.morphTargetInfluences = [];\n          this.morphTargetDictionary = {};\n          for (let m = 0, ml = morphAttribute.length; m < ml; m++) {\n            const name = morphAttribute[m].name || String(m);\n            this.morphTargetInfluences.push(0);\n            this.morphTargetDictionary[name] = m;\n          }\n        }\n      }\n    } else {\n      const morphTargets = geometry.morphTargets;\n      if (morphTargets !== undefined && morphTargets.length > 0) {\n        console.error('THREE.Line.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.');\n      }\n    }\n  }\n});\nconst _start$1 = new Vector3();\nconst _end$1 = new Vector3();\nfunction LineSegments(geometry, material) {\n  Line.call(this, geometry, material);\n  this.type = 'LineSegments';\n}\nLineSegments.prototype = _extends__default['default'](Object.create(Line.prototype), {\n  constructor: LineSegments,\n  isLineSegments: true,\n  computeLineDistances: function () {\n    const geometry = this.geometry;\n    if (geometry.isBufferGeometry) {\n      // we assume non-indexed geometry\n\n      if (geometry.index === null) {\n        const positionAttribute = geometry.attributes.position;\n        const lineDistances = [];\n        for (let i = 0, l = positionAttribute.count; i < l; i += 2) {\n          _start$1.fromBufferAttribute(positionAttribute, i);\n          _end$1.fromBufferAttribute(positionAttribute, i + 1);\n          lineDistances[i] = i === 0 ? 0 : lineDistances[i - 1];\n          lineDistances[i + 1] = lineDistances[i] + _start$1.distanceTo(_end$1);\n        }\n        geometry.setAttribute('lineDistance', new Float32BufferAttribute(lineDistances, 1));\n      } else {\n        console.warn('THREE.LineSegments.computeLineDistances(): Computation only possible with non-indexed BufferGeometry.');\n      }\n    } else if (geometry.isGeometry) {\n      console.error('THREE.LineSegments.computeLineDistances() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.');\n    }\n    return this;\n  }\n});\nfunction LineLoop(geometry, material) {\n  Line.call(this, geometry, material);\n  this.type = 'LineLoop';\n}\nLineLoop.prototype = _extends__default['default'](Object.create(Line.prototype), {\n  constructor: LineLoop,\n  isLineLoop: true\n});\n\n/**\n * parameters = {\n *  color: <hex>,\n *  opacity: <float>,\n *  map: new THREE.Texture( <Image> ),\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  size: <float>,\n *  sizeAttenuation: <bool>\n *\n *  morphTargets: <bool>\n * }\n */\n\nfunction PointsMaterial(parameters) {\n  Material.call(this);\n  this.type = 'PointsMaterial';\n  this.color = new Color(0xffffff);\n  this.map = null;\n  this.alphaMap = null;\n  this.size = 1;\n  this.sizeAttenuation = true;\n  this.morphTargets = false;\n  this.setValues(parameters);\n}\nPointsMaterial.prototype = Object.create(Material.prototype);\nPointsMaterial.prototype.constructor = PointsMaterial;\nPointsMaterial.prototype.isPointsMaterial = true;\nPointsMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  this.map = source.map;\n  this.alphaMap = source.alphaMap;\n  this.size = source.size;\n  this.sizeAttenuation = source.sizeAttenuation;\n  this.morphTargets = source.morphTargets;\n  return this;\n};\nconst _inverseMatrix$2 = new Matrix4();\nconst _ray$2 = new Ray();\nconst _sphere$3 = new Sphere();\nconst _position$1 = new Vector3();\nfunction Points(geometry = new BufferGeometry(), material = new PointsMaterial()) {\n  Object3D.call(this);\n  this.type = 'Points';\n  this.geometry = geometry;\n  this.material = material;\n  this.updateMorphTargets();\n}\nPoints.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Points,\n  isPoints: true,\n  copy: function (source) {\n    Object3D.prototype.copy.call(this, source);\n    this.material = source.material;\n    this.geometry = source.geometry;\n    return this;\n  },\n  raycast: function (raycaster, intersects) {\n    const geometry = this.geometry;\n    const matrixWorld = this.matrixWorld;\n    const threshold = raycaster.params.Points.threshold;\n\n    // Checking boundingSphere distance to ray\n\n    if (geometry.boundingSphere === null) geometry.computeBoundingSphere();\n    _sphere$3.copy(geometry.boundingSphere);\n    _sphere$3.applyMatrix4(matrixWorld);\n    _sphere$3.radius += threshold;\n    if (raycaster.ray.intersectsSphere(_sphere$3) === false) return;\n\n    //\n\n    _inverseMatrix$2.copy(matrixWorld).invert();\n    _ray$2.copy(raycaster.ray).applyMatrix4(_inverseMatrix$2);\n    const localThreshold = threshold / ((this.scale.x + this.scale.y + this.scale.z) / 3);\n    const localThresholdSq = localThreshold * localThreshold;\n    if (geometry.isBufferGeometry) {\n      const index = geometry.index;\n      const attributes = geometry.attributes;\n      const positionAttribute = attributes.position;\n      if (index !== null) {\n        const indices = index.array;\n        for (let i = 0, il = indices.length; i < il; i++) {\n          const a = indices[i];\n          _position$1.fromBufferAttribute(positionAttribute, a);\n          testPoint(_position$1, a, localThresholdSq, matrixWorld, raycaster, intersects, this);\n        }\n      } else {\n        for (let i = 0, l = positionAttribute.count; i < l; i++) {\n          _position$1.fromBufferAttribute(positionAttribute, i);\n          testPoint(_position$1, i, localThresholdSq, matrixWorld, raycaster, intersects, this);\n        }\n      }\n    } else {\n      console.error('THREE.Points.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.');\n    }\n  },\n  updateMorphTargets: function () {\n    const geometry = this.geometry;\n    if (geometry.isBufferGeometry) {\n      const morphAttributes = geometry.morphAttributes;\n      const keys = Object.keys(morphAttributes);\n      if (keys.length > 0) {\n        const morphAttribute = morphAttributes[keys[0]];\n        if (morphAttribute !== undefined) {\n          this.morphTargetInfluences = [];\n          this.morphTargetDictionary = {};\n          for (let m = 0, ml = morphAttribute.length; m < ml; m++) {\n            const name = morphAttribute[m].name || String(m);\n            this.morphTargetInfluences.push(0);\n            this.morphTargetDictionary[name] = m;\n          }\n        }\n      }\n    } else {\n      const morphTargets = geometry.morphTargets;\n      if (morphTargets !== undefined && morphTargets.length > 0) {\n        console.error('THREE.Points.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.');\n      }\n    }\n  }\n});\nfunction testPoint(point, index, localThresholdSq, matrixWorld, raycaster, intersects, object) {\n  const rayPointDistanceSq = _ray$2.distanceSqToPoint(point);\n  if (rayPointDistanceSq < localThresholdSq) {\n    const intersectPoint = new Vector3();\n    _ray$2.closestPointToPoint(point, intersectPoint);\n    intersectPoint.applyMatrix4(matrixWorld);\n    const distance = raycaster.ray.origin.distanceTo(intersectPoint);\n    if (distance < raycaster.near || distance > raycaster.far) return;\n    intersects.push({\n      distance: distance,\n      distanceToRay: Math.sqrt(rayPointDistanceSq),\n      point: intersectPoint,\n      index: index,\n      face: null,\n      object: object\n    });\n  }\n}\nfunction VideoTexture(video, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy) {\n  Texture.call(this, video, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy);\n  this.format = format !== undefined ? format : RGBFormat;\n  this.minFilter = minFilter !== undefined ? minFilter : LinearFilter;\n  this.magFilter = magFilter !== undefined ? magFilter : LinearFilter;\n  this.generateMipmaps = false;\n  const scope = this;\n  function updateVideo() {\n    scope.needsUpdate = true;\n    video.requestVideoFrameCallback(updateVideo);\n  }\n  if ('requestVideoFrameCallback' in video) {\n    video.requestVideoFrameCallback(updateVideo);\n  }\n}\nVideoTexture.prototype = _extends__default['default'](Object.create(Texture.prototype), {\n  constructor: VideoTexture,\n  clone: function () {\n    return new this.constructor(this.image).copy(this);\n  },\n  isVideoTexture: true,\n  update: function () {\n    const video = this.image;\n    const hasVideoFrameCallback = ('requestVideoFrameCallback' in video);\n    if (hasVideoFrameCallback === false && video.readyState >= video.HAVE_CURRENT_DATA) {\n      this.needsUpdate = true;\n    }\n  }\n});\nfunction CompressedTexture(mipmaps, width, height, format, type, mapping, wrapS, wrapT, magFilter, minFilter, anisotropy, encoding) {\n  Texture.call(this, null, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy, encoding);\n  this.image = {\n    width: width,\n    height: height\n  };\n  this.mipmaps = mipmaps;\n\n  // no flipping for cube textures\n  // (also flipping doesn't work for compressed textures )\n\n  this.flipY = false;\n\n  // can't generate mipmaps for compressed textures\n  // mips must be embedded in DDS files\n\n  this.generateMipmaps = false;\n}\nCompressedTexture.prototype = Object.create(Texture.prototype);\nCompressedTexture.prototype.constructor = CompressedTexture;\nCompressedTexture.prototype.isCompressedTexture = true;\nfunction CanvasTexture(canvas, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy) {\n  Texture.call(this, canvas, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy);\n  this.needsUpdate = true;\n}\nCanvasTexture.prototype = Object.create(Texture.prototype);\nCanvasTexture.prototype.constructor = CanvasTexture;\nCanvasTexture.prototype.isCanvasTexture = true;\nfunction DepthTexture(width, height, type, mapping, wrapS, wrapT, magFilter, minFilter, anisotropy, format) {\n  format = format !== undefined ? format : DepthFormat;\n  if (format !== DepthFormat && format !== DepthStencilFormat) {\n    throw new Error('DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat');\n  }\n  if (type === undefined && format === DepthFormat) type = UnsignedShortType;\n  if (type === undefined && format === DepthStencilFormat) type = UnsignedInt248Type;\n  Texture.call(this, null, mapping, wrapS, wrapT, magFilter, minFilter, format, type, anisotropy);\n  this.image = {\n    width: width,\n    height: height\n  };\n  this.magFilter = magFilter !== undefined ? magFilter : NearestFilter;\n  this.minFilter = minFilter !== undefined ? minFilter : NearestFilter;\n  this.flipY = false;\n  this.generateMipmaps = false;\n}\nDepthTexture.prototype = Object.create(Texture.prototype);\nDepthTexture.prototype.constructor = DepthTexture;\nDepthTexture.prototype.isDepthTexture = true;\nnew Vector3();\nnew Vector3();\nnew Vector3();\nnew Triangle();\n\n/**\n * Port from https://github.com/mapbox/earcut (v2.2.2)\n */\n\nconst Earcut = {\n  triangulate: function (data, holeIndices, dim) {\n    dim = dim || 2;\n    const hasHoles = holeIndices && holeIndices.length;\n    const outerLen = hasHoles ? holeIndices[0] * dim : data.length;\n    let outerNode = linkedList(data, 0, outerLen, dim, true);\n    const triangles = [];\n    if (!outerNode || outerNode.next === outerNode.prev) return triangles;\n    let minX, minY, maxX, maxY, x, y, invSize;\n    if (hasHoles) outerNode = eliminateHoles(data, holeIndices, outerNode, dim);\n\n    // if the shape is not too simple, we'll use z-order curve hash later; calculate polygon bbox\n    if (data.length > 80 * dim) {\n      minX = maxX = data[0];\n      minY = maxY = data[1];\n      for (let i = dim; i < outerLen; i += dim) {\n        x = data[i];\n        y = data[i + 1];\n        if (x < minX) minX = x;\n        if (y < minY) minY = y;\n        if (x > maxX) maxX = x;\n        if (y > maxY) maxY = y;\n      }\n\n      // minX, minY and invSize are later used to transform coords into integers for z-order calculation\n      invSize = Math.max(maxX - minX, maxY - minY);\n      invSize = invSize !== 0 ? 1 / invSize : 0;\n    }\n    earcutLinked(outerNode, triangles, dim, minX, minY, invSize);\n    return triangles;\n  }\n};\n\n// create a circular doubly linked list from polygon points in the specified winding order\nfunction linkedList(data, start, end, dim, clockwise) {\n  let i, last;\n  if (clockwise === signedArea(data, start, end, dim) > 0) {\n    for (i = start; i < end; i += dim) last = insertNode(i, data[i], data[i + 1], last);\n  } else {\n    for (i = end - dim; i >= start; i -= dim) last = insertNode(i, data[i], data[i + 1], last);\n  }\n  if (last && equals(last, last.next)) {\n    removeNode(last);\n    last = last.next;\n  }\n  return last;\n}\n\n// eliminate colinear or duplicate points\nfunction filterPoints(start, end) {\n  if (!start) return start;\n  if (!end) end = start;\n  let p = start,\n    again;\n  do {\n    again = false;\n    if (!p.steiner && (equals(p, p.next) || area(p.prev, p, p.next) === 0)) {\n      removeNode(p);\n      p = end = p.prev;\n      if (p === p.next) break;\n      again = true;\n    } else {\n      p = p.next;\n    }\n  } while (again || p !== end);\n  return end;\n}\n\n// main ear slicing loop which triangulates a polygon (given as a linked list)\nfunction earcutLinked(ear, triangles, dim, minX, minY, invSize, pass) {\n  if (!ear) return;\n\n  // interlink polygon nodes in z-order\n  if (!pass && invSize) indexCurve(ear, minX, minY, invSize);\n  let stop = ear,\n    prev,\n    next;\n\n  // iterate through ears, slicing them one by one\n  while (ear.prev !== ear.next) {\n    prev = ear.prev;\n    next = ear.next;\n    if (invSize ? isEarHashed(ear, minX, minY, invSize) : isEar(ear)) {\n      // cut off the triangle\n      triangles.push(prev.i / dim);\n      triangles.push(ear.i / dim);\n      triangles.push(next.i / dim);\n      removeNode(ear);\n\n      // skipping the next vertex leads to less sliver triangles\n      ear = next.next;\n      stop = next.next;\n      continue;\n    }\n    ear = next;\n\n    // if we looped through the whole remaining polygon and can't find any more ears\n    if (ear === stop) {\n      // try filtering points and slicing again\n      if (!pass) {\n        earcutLinked(filterPoints(ear), triangles, dim, minX, minY, invSize, 1);\n\n        // if this didn't work, try curing all small self-intersections locally\n      } else if (pass === 1) {\n        ear = cureLocalIntersections(filterPoints(ear), triangles, dim);\n        earcutLinked(ear, triangles, dim, minX, minY, invSize, 2);\n\n        // as a last resort, try splitting the remaining polygon into two\n      } else if (pass === 2) {\n        splitEarcut(ear, triangles, dim, minX, minY, invSize);\n      }\n      break;\n    }\n  }\n}\n\n// check whether a polygon node forms a valid ear with adjacent nodes\nfunction isEar(ear) {\n  const a = ear.prev,\n    b = ear,\n    c = ear.next;\n  if (area(a, b, c) >= 0) return false; // reflex, can't be an ear\n\n  // now make sure we don't have other points inside the potential ear\n  let p = ear.next.next;\n  while (p !== ear.prev) {\n    if (pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) && area(p.prev, p, p.next) >= 0) return false;\n    p = p.next;\n  }\n  return true;\n}\nfunction isEarHashed(ear, minX, minY, invSize) {\n  const a = ear.prev,\n    b = ear,\n    c = ear.next;\n  if (area(a, b, c) >= 0) return false; // reflex, can't be an ear\n\n  // triangle bbox; min & max are calculated like this for speed\n  const minTX = a.x < b.x ? a.x < c.x ? a.x : c.x : b.x < c.x ? b.x : c.x,\n    minTY = a.y < b.y ? a.y < c.y ? a.y : c.y : b.y < c.y ? b.y : c.y,\n    maxTX = a.x > b.x ? a.x > c.x ? a.x : c.x : b.x > c.x ? b.x : c.x,\n    maxTY = a.y > b.y ? a.y > c.y ? a.y : c.y : b.y > c.y ? b.y : c.y;\n\n  // z-order range for the current triangle bbox;\n  const minZ = zOrder(minTX, minTY, minX, minY, invSize),\n    maxZ = zOrder(maxTX, maxTY, minX, minY, invSize);\n  let p = ear.prevZ,\n    n = ear.nextZ;\n\n  // look for points inside the triangle in both directions\n  while (p && p.z >= minZ && n && n.z <= maxZ) {\n    if (p !== ear.prev && p !== ear.next && pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) && area(p.prev, p, p.next) >= 0) return false;\n    p = p.prevZ;\n    if (n !== ear.prev && n !== ear.next && pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, n.x, n.y) && area(n.prev, n, n.next) >= 0) return false;\n    n = n.nextZ;\n  }\n\n  // look for remaining points in decreasing z-order\n  while (p && p.z >= minZ) {\n    if (p !== ear.prev && p !== ear.next && pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) && area(p.prev, p, p.next) >= 0) return false;\n    p = p.prevZ;\n  }\n\n  // look for remaining points in increasing z-order\n  while (n && n.z <= maxZ) {\n    if (n !== ear.prev && n !== ear.next && pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, n.x, n.y) && area(n.prev, n, n.next) >= 0) return false;\n    n = n.nextZ;\n  }\n  return true;\n}\n\n// go through all polygon nodes and cure small local self-intersections\nfunction cureLocalIntersections(start, triangles, dim) {\n  let p = start;\n  do {\n    const a = p.prev,\n      b = p.next.next;\n    if (!equals(a, b) && intersects(a, p, p.next, b) && locallyInside(a, b) && locallyInside(b, a)) {\n      triangles.push(a.i / dim);\n      triangles.push(p.i / dim);\n      triangles.push(b.i / dim);\n\n      // remove two nodes involved\n      removeNode(p);\n      removeNode(p.next);\n      p = start = b;\n    }\n    p = p.next;\n  } while (p !== start);\n  return filterPoints(p);\n}\n\n// try splitting polygon into two and triangulate them independently\nfunction splitEarcut(start, triangles, dim, minX, minY, invSize) {\n  // look for a valid diagonal that divides the polygon into two\n  let a = start;\n  do {\n    let b = a.next.next;\n    while (b !== a.prev) {\n      if (a.i !== b.i && isValidDiagonal(a, b)) {\n        // split the polygon in two by the diagonal\n        let c = splitPolygon(a, b);\n\n        // filter colinear points around the cuts\n        a = filterPoints(a, a.next);\n        c = filterPoints(c, c.next);\n\n        // run earcut on each half\n        earcutLinked(a, triangles, dim, minX, minY, invSize);\n        earcutLinked(c, triangles, dim, minX, minY, invSize);\n        return;\n      }\n      b = b.next;\n    }\n    a = a.next;\n  } while (a !== start);\n}\n\n// link every hole into the outer loop, producing a single-ring polygon without holes\nfunction eliminateHoles(data, holeIndices, outerNode, dim) {\n  const queue = [];\n  let i, len, start, end, list;\n  for (i = 0, len = holeIndices.length; i < len; i++) {\n    start = holeIndices[i] * dim;\n    end = i < len - 1 ? holeIndices[i + 1] * dim : data.length;\n    list = linkedList(data, start, end, dim, false);\n    if (list === list.next) list.steiner = true;\n    queue.push(getLeftmost(list));\n  }\n  queue.sort(compareX);\n\n  // process holes from left to right\n  for (i = 0; i < queue.length; i++) {\n    eliminateHole(queue[i], outerNode);\n    outerNode = filterPoints(outerNode, outerNode.next);\n  }\n  return outerNode;\n}\nfunction compareX(a, b) {\n  return a.x - b.x;\n}\n\n// find a bridge between vertices that connects hole with an outer ring and and link it\nfunction eliminateHole(hole, outerNode) {\n  outerNode = findHoleBridge(hole, outerNode);\n  if (outerNode) {\n    const b = splitPolygon(outerNode, hole);\n\n    // filter collinear points around the cuts\n    filterPoints(outerNode, outerNode.next);\n    filterPoints(b, b.next);\n  }\n}\n\n// David Eberly's algorithm for finding a bridge between hole and outer polygon\nfunction findHoleBridge(hole, outerNode) {\n  let p = outerNode;\n  const hx = hole.x;\n  const hy = hole.y;\n  let qx = -Infinity,\n    m;\n\n  // find a segment intersected by a ray from the hole's leftmost point to the left;\n  // segment's endpoint with lesser x will be potential connection point\n  do {\n    if (hy <= p.y && hy >= p.next.y && p.next.y !== p.y) {\n      const x = p.x + (hy - p.y) * (p.next.x - p.x) / (p.next.y - p.y);\n      if (x <= hx && x > qx) {\n        qx = x;\n        if (x === hx) {\n          if (hy === p.y) return p;\n          if (hy === p.next.y) return p.next;\n        }\n        m = p.x < p.next.x ? p : p.next;\n      }\n    }\n    p = p.next;\n  } while (p !== outerNode);\n  if (!m) return null;\n  if (hx === qx) return m; // hole touches outer segment; pick leftmost endpoint\n\n  // look for points inside the triangle of hole point, segment intersection and endpoint;\n  // if there are no points found, we have a valid connection;\n  // otherwise choose the point of the minimum angle with the ray as connection point\n\n  const stop = m,\n    mx = m.x,\n    my = m.y;\n  let tanMin = Infinity,\n    tan;\n  p = m;\n  do {\n    if (hx >= p.x && p.x >= mx && hx !== p.x && pointInTriangle(hy < my ? hx : qx, hy, mx, my, hy < my ? qx : hx, hy, p.x, p.y)) {\n      tan = Math.abs(hy - p.y) / (hx - p.x); // tangential\n\n      if (locallyInside(p, hole) && (tan < tanMin || tan === tanMin && (p.x > m.x || p.x === m.x && sectorContainsSector(m, p)))) {\n        m = p;\n        tanMin = tan;\n      }\n    }\n    p = p.next;\n  } while (p !== stop);\n  return m;\n}\n\n// whether sector in vertex m contains sector in vertex p in the same coordinates\nfunction sectorContainsSector(m, p) {\n  return area(m.prev, m, p.prev) < 0 && area(p.next, m, m.next) < 0;\n}\n\n// interlink polygon nodes in z-order\nfunction indexCurve(start, minX, minY, invSize) {\n  let p = start;\n  do {\n    if (p.z === null) p.z = zOrder(p.x, p.y, minX, minY, invSize);\n    p.prevZ = p.prev;\n    p.nextZ = p.next;\n    p = p.next;\n  } while (p !== start);\n  p.prevZ.nextZ = null;\n  p.prevZ = null;\n  sortLinked(p);\n}\n\n// Simon Tatham's linked list merge sort algorithm\n// http://www.chiark.greenend.org.uk/~sgtatham/algorithms/listsort.html\nfunction sortLinked(list) {\n  let i,\n    p,\n    q,\n    e,\n    tail,\n    numMerges,\n    pSize,\n    qSize,\n    inSize = 1;\n  do {\n    p = list;\n    list = null;\n    tail = null;\n    numMerges = 0;\n    while (p) {\n      numMerges++;\n      q = p;\n      pSize = 0;\n      for (i = 0; i < inSize; i++) {\n        pSize++;\n        q = q.nextZ;\n        if (!q) break;\n      }\n      qSize = inSize;\n      while (pSize > 0 || qSize > 0 && q) {\n        if (pSize !== 0 && (qSize === 0 || !q || p.z <= q.z)) {\n          e = p;\n          p = p.nextZ;\n          pSize--;\n        } else {\n          e = q;\n          q = q.nextZ;\n          qSize--;\n        }\n        if (tail) tail.nextZ = e;else list = e;\n        e.prevZ = tail;\n        tail = e;\n      }\n      p = q;\n    }\n    tail.nextZ = null;\n    inSize *= 2;\n  } while (numMerges > 1);\n  return list;\n}\n\n// z-order of a point given coords and inverse of the longer side of data bbox\nfunction zOrder(x, y, minX, minY, invSize) {\n  // coords are transformed into non-negative 15-bit integer range\n  x = 32767 * (x - minX) * invSize;\n  y = 32767 * (y - minY) * invSize;\n  x = (x | x << 8) & 0x00FF00FF;\n  x = (x | x << 4) & 0x0F0F0F0F;\n  x = (x | x << 2) & 0x33333333;\n  x = (x | x << 1) & 0x55555555;\n  y = (y | y << 8) & 0x00FF00FF;\n  y = (y | y << 4) & 0x0F0F0F0F;\n  y = (y | y << 2) & 0x33333333;\n  y = (y | y << 1) & 0x55555555;\n  return x | y << 1;\n}\n\n// find the leftmost node of a polygon ring\nfunction getLeftmost(start) {\n  let p = start,\n    leftmost = start;\n  do {\n    if (p.x < leftmost.x || p.x === leftmost.x && p.y < leftmost.y) leftmost = p;\n    p = p.next;\n  } while (p !== start);\n  return leftmost;\n}\n\n// check if a point lies within a convex triangle\nfunction pointInTriangle(ax, ay, bx, by, cx, cy, px, py) {\n  return (cx - px) * (ay - py) - (ax - px) * (cy - py) >= 0 && (ax - px) * (by - py) - (bx - px) * (ay - py) >= 0 && (bx - px) * (cy - py) - (cx - px) * (by - py) >= 0;\n}\n\n// check if a diagonal between two polygon nodes is valid (lies in polygon interior)\nfunction isValidDiagonal(a, b) {\n  return a.next.i !== b.i && a.prev.i !== b.i && !intersectsPolygon(a, b) && (\n  // dones't intersect other edges\n  locallyInside(a, b) && locallyInside(b, a) && middleInside(a, b) && (\n  // locally visible\n  area(a.prev, a, b.prev) || area(a, b.prev, b)) ||\n  // does not create opposite-facing sectors\n  equals(a, b) && area(a.prev, a, a.next) > 0 && area(b.prev, b, b.next) > 0); // special zero-length case\n}\n\n// signed area of a triangle\nfunction area(p, q, r) {\n  return (q.y - p.y) * (r.x - q.x) - (q.x - p.x) * (r.y - q.y);\n}\n\n// check if two points are equal\nfunction equals(p1, p2) {\n  return p1.x === p2.x && p1.y === p2.y;\n}\n\n// check if two segments intersect\nfunction intersects(p1, q1, p2, q2) {\n  const o1 = sign(area(p1, q1, p2));\n  const o2 = sign(area(p1, q1, q2));\n  const o3 = sign(area(p2, q2, p1));\n  const o4 = sign(area(p2, q2, q1));\n  if (o1 !== o2 && o3 !== o4) return true; // general case\n\n  if (o1 === 0 && onSegment(p1, p2, q1)) return true; // p1, q1 and p2 are collinear and p2 lies on p1q1\n  if (o2 === 0 && onSegment(p1, q2, q1)) return true; // p1, q1 and q2 are collinear and q2 lies on p1q1\n  if (o3 === 0 && onSegment(p2, p1, q2)) return true; // p2, q2 and p1 are collinear and p1 lies on p2q2\n  if (o4 === 0 && onSegment(p2, q1, q2)) return true; // p2, q2 and q1 are collinear and q1 lies on p2q2\n\n  return false;\n}\n\n// for collinear points p, q, r, check if point q lies on segment pr\nfunction onSegment(p, q, r) {\n  return q.x <= Math.max(p.x, r.x) && q.x >= Math.min(p.x, r.x) && q.y <= Math.max(p.y, r.y) && q.y >= Math.min(p.y, r.y);\n}\nfunction sign(num) {\n  return num > 0 ? 1 : num < 0 ? -1 : 0;\n}\n\n// check if a polygon diagonal intersects any polygon segments\nfunction intersectsPolygon(a, b) {\n  let p = a;\n  do {\n    if (p.i !== a.i && p.next.i !== a.i && p.i !== b.i && p.next.i !== b.i && intersects(p, p.next, a, b)) return true;\n    p = p.next;\n  } while (p !== a);\n  return false;\n}\n\n// check if a polygon diagonal is locally inside the polygon\nfunction locallyInside(a, b) {\n  return area(a.prev, a, a.next) < 0 ? area(a, b, a.next) >= 0 && area(a, a.prev, b) >= 0 : area(a, b, a.prev) < 0 || area(a, a.next, b) < 0;\n}\n\n// check if the middle point of a polygon diagonal is inside the polygon\nfunction middleInside(a, b) {\n  let p = a,\n    inside = false;\n  const px = (a.x + b.x) / 2,\n    py = (a.y + b.y) / 2;\n  do {\n    if (p.y > py !== p.next.y > py && p.next.y !== p.y && px < (p.next.x - p.x) * (py - p.y) / (p.next.y - p.y) + p.x) inside = !inside;\n    p = p.next;\n  } while (p !== a);\n  return inside;\n}\n\n// link two polygon vertices with a bridge; if the vertices belong to the same ring, it splits polygon into two;\n// if one belongs to the outer ring and another to a hole, it merges it into a single ring\nfunction splitPolygon(a, b) {\n  const a2 = new Node(a.i, a.x, a.y),\n    b2 = new Node(b.i, b.x, b.y),\n    an = a.next,\n    bp = b.prev;\n  a.next = b;\n  b.prev = a;\n  a2.next = an;\n  an.prev = a2;\n  b2.next = a2;\n  a2.prev = b2;\n  bp.next = b2;\n  b2.prev = bp;\n  return b2;\n}\n\n// create a node and optionally link it with previous one (in a circular doubly linked list)\nfunction insertNode(i, x, y, last) {\n  const p = new Node(i, x, y);\n  if (!last) {\n    p.prev = p;\n    p.next = p;\n  } else {\n    p.next = last.next;\n    p.prev = last;\n    last.next.prev = p;\n    last.next = p;\n  }\n  return p;\n}\nfunction removeNode(p) {\n  p.next.prev = p.prev;\n  p.prev.next = p.next;\n  if (p.prevZ) p.prevZ.nextZ = p.nextZ;\n  if (p.nextZ) p.nextZ.prevZ = p.prevZ;\n}\nfunction Node(i, x, y) {\n  // vertex index in coordinates array\n  this.i = i;\n\n  // vertex coordinates\n  this.x = x;\n  this.y = y;\n\n  // previous and next vertex nodes in a polygon ring\n  this.prev = null;\n  this.next = null;\n\n  // z-order curve value\n  this.z = null;\n\n  // previous and next nodes in z-order\n  this.prevZ = null;\n  this.nextZ = null;\n\n  // indicates whether this is a steiner point\n  this.steiner = false;\n}\nfunction signedArea(data, start, end, dim) {\n  let sum = 0;\n  for (let i = start, j = end - dim; i < end; i += dim) {\n    sum += (data[j] - data[i]) * (data[i + 1] + data[j + 1]);\n    j = i;\n  }\n  return sum;\n}\nconst ShapeUtils = {\n  // calculate area of the contour polygon\n\n  area: function (contour) {\n    const n = contour.length;\n    let a = 0.0;\n    for (let p = n - 1, q = 0; q < n; p = q++) {\n      a += contour[p].x * contour[q].y - contour[q].x * contour[p].y;\n    }\n    return a * 0.5;\n  },\n  isClockWise: function (pts) {\n    return ShapeUtils.area(pts) < 0;\n  },\n  triangulateShape: function (contour, holes) {\n    const vertices = []; // flat array of vertices like [ x0,y0, x1,y1, x2,y2, ... ]\n    const holeIndices = []; // array of hole indices\n    const faces = []; // final array of vertex indices like [ [ a,b,d ], [ b,c,d ] ]\n\n    removeDupEndPts(contour);\n    addContour(vertices, contour);\n\n    //\n\n    let holeIndex = contour.length;\n    holes.forEach(removeDupEndPts);\n    for (let i = 0; i < holes.length; i++) {\n      holeIndices.push(holeIndex);\n      holeIndex += holes[i].length;\n      addContour(vertices, holes[i]);\n    }\n\n    //\n\n    const triangles = Earcut.triangulate(vertices, holeIndices);\n\n    //\n\n    for (let i = 0; i < triangles.length; i += 3) {\n      faces.push(triangles.slice(i, i + 3));\n    }\n    return faces;\n  }\n};\nfunction removeDupEndPts(points) {\n  const l = points.length;\n  if (l > 2 && points[l - 1].equals(points[0])) {\n    points.pop();\n  }\n}\nfunction addContour(vertices, contour) {\n  for (let i = 0; i < contour.length; i++) {\n    vertices.push(contour[i].x);\n    vertices.push(contour[i].y);\n  }\n}\n\n/**\n * Creates extruded geometry from a path shape.\n *\n * parameters = {\n *\n *  curveSegments: <int>, // number of points on the curves\n *  steps: <int>, // number of points for z-side extrusions / used for subdividing segments of extrude spline too\n *  depth: <float>, // Depth to extrude the shape\n *\n *  bevelEnabled: <bool>, // turn on bevel\n *  bevelThickness: <float>, // how deep into the original shape bevel goes\n *  bevelSize: <float>, // how far from shape outline (including bevelOffset) is bevel\n *  bevelOffset: <float>, // how far from shape outline does bevel start\n *  bevelSegments: <int>, // number of bevel layers\n *\n *  extrudePath: <THREE.Curve> // curve to extrude shape along\n *\n *  UVGenerator: <Object> // object that provides UV generator functions\n *\n * }\n */\n\nclass ExtrudeGeometry extends BufferGeometry {\n  constructor(shapes, options) {\n    super();\n    this.type = 'ExtrudeGeometry';\n    this.parameters = {\n      shapes: shapes,\n      options: options\n    };\n    shapes = Array.isArray(shapes) ? shapes : [shapes];\n    const scope = this;\n    const verticesArray = [];\n    const uvArray = [];\n    for (let i = 0, l = shapes.length; i < l; i++) {\n      const shape = shapes[i];\n      addShape(shape);\n    }\n\n    // build geometry\n\n    this.setAttribute('position', new Float32BufferAttribute(verticesArray, 3));\n    this.setAttribute('uv', new Float32BufferAttribute(uvArray, 2));\n    this.computeVertexNormals();\n\n    // functions\n\n    function addShape(shape) {\n      const placeholder = [];\n\n      // options\n\n      const curveSegments = options.curveSegments !== undefined ? options.curveSegments : 12;\n      const steps = options.steps !== undefined ? options.steps : 1;\n      let depth = options.depth !== undefined ? options.depth : 100;\n      let bevelEnabled = options.bevelEnabled !== undefined ? options.bevelEnabled : true;\n      let bevelThickness = options.bevelThickness !== undefined ? options.bevelThickness : 6;\n      let bevelSize = options.bevelSize !== undefined ? options.bevelSize : bevelThickness - 2;\n      let bevelOffset = options.bevelOffset !== undefined ? options.bevelOffset : 0;\n      let bevelSegments = options.bevelSegments !== undefined ? options.bevelSegments : 3;\n      const extrudePath = options.extrudePath;\n      const uvgen = options.UVGenerator !== undefined ? options.UVGenerator : WorldUVGenerator;\n\n      // deprecated options\n\n      if (options.amount !== undefined) {\n        console.warn('THREE.ExtrudeBufferGeometry: amount has been renamed to depth.');\n        depth = options.amount;\n      }\n\n      //\n\n      let extrudePts,\n        extrudeByPath = false;\n      let splineTube, binormal, normal, position2;\n      if (extrudePath) {\n        extrudePts = extrudePath.getSpacedPoints(steps);\n        extrudeByPath = true;\n        bevelEnabled = false; // bevels not supported for path extrusion\n\n        // SETUP TNB variables\n\n        // TODO1 - have a .isClosed in spline?\n\n        splineTube = extrudePath.computeFrenetFrames(steps, false);\n\n        // console.log(splineTube, 'splineTube', splineTube.normals.length, 'steps', steps, 'extrudePts', extrudePts.length);\n\n        binormal = new Vector3();\n        normal = new Vector3();\n        position2 = new Vector3();\n      }\n\n      // Safeguards if bevels are not enabled\n\n      if (!bevelEnabled) {\n        bevelSegments = 0;\n        bevelThickness = 0;\n        bevelSize = 0;\n        bevelOffset = 0;\n      }\n\n      // Variables initialization\n\n      const shapePoints = shape.extractPoints(curveSegments);\n      let vertices = shapePoints.shape;\n      const holes = shapePoints.holes;\n      const reverse = !ShapeUtils.isClockWise(vertices);\n      if (reverse) {\n        vertices = vertices.reverse();\n\n        // Maybe we should also check if holes are in the opposite direction, just to be safe ...\n\n        for (let h = 0, hl = holes.length; h < hl; h++) {\n          const ahole = holes[h];\n          if (ShapeUtils.isClockWise(ahole)) {\n            holes[h] = ahole.reverse();\n          }\n        }\n      }\n      const faces = ShapeUtils.triangulateShape(vertices, holes);\n\n      /* Vertices */\n\n      const contour = vertices; // vertices has all points but contour has only points of circumference\n\n      for (let h = 0, hl = holes.length; h < hl; h++) {\n        const ahole = holes[h];\n        vertices = vertices.concat(ahole);\n      }\n      function scalePt2(pt, vec, size) {\n        if (!vec) console.error('THREE.ExtrudeGeometry: vec does not exist');\n        return vec.clone().multiplyScalar(size).add(pt);\n      }\n      const vlen = vertices.length,\n        flen = faces.length;\n\n      // Find directions for point movement\n\n      function getBevelVec(inPt, inPrev, inNext) {\n        // computes for inPt the corresponding point inPt' on a new contour\n        //   shifted by 1 unit (length of normalized vector) to the left\n        // if we walk along contour clockwise, this new contour is outside the old one\n        //\n        // inPt' is the intersection of the two lines parallel to the two\n        //  adjacent edges of inPt at a distance of 1 unit on the left side.\n\n        let v_trans_x, v_trans_y, shrink_by; // resulting translation vector for inPt\n\n        // good reading for geometry algorithms (here: line-line intersection)\n        // http://geomalgorithms.com/a05-_intersect-1.html\n\n        const v_prev_x = inPt.x - inPrev.x,\n          v_prev_y = inPt.y - inPrev.y;\n        const v_next_x = inNext.x - inPt.x,\n          v_next_y = inNext.y - inPt.y;\n        const v_prev_lensq = v_prev_x * v_prev_x + v_prev_y * v_prev_y;\n\n        // check for collinear edges\n        const collinear0 = v_prev_x * v_next_y - v_prev_y * v_next_x;\n        if (Math.abs(collinear0) > Number.EPSILON) {\n          // not collinear\n\n          // length of vectors for normalizing\n\n          const v_prev_len = Math.sqrt(v_prev_lensq);\n          const v_next_len = Math.sqrt(v_next_x * v_next_x + v_next_y * v_next_y);\n\n          // shift adjacent points by unit vectors to the left\n\n          const ptPrevShift_x = inPrev.x - v_prev_y / v_prev_len;\n          const ptPrevShift_y = inPrev.y + v_prev_x / v_prev_len;\n          const ptNextShift_x = inNext.x - v_next_y / v_next_len;\n          const ptNextShift_y = inNext.y + v_next_x / v_next_len;\n\n          // scaling factor for v_prev to intersection point\n\n          const sf = ((ptNextShift_x - ptPrevShift_x) * v_next_y - (ptNextShift_y - ptPrevShift_y) * v_next_x) / (v_prev_x * v_next_y - v_prev_y * v_next_x);\n\n          // vector from inPt to intersection point\n\n          v_trans_x = ptPrevShift_x + v_prev_x * sf - inPt.x;\n          v_trans_y = ptPrevShift_y + v_prev_y * sf - inPt.y;\n\n          // Don't normalize!, otherwise sharp corners become ugly\n          //  but prevent crazy spikes\n          const v_trans_lensq = v_trans_x * v_trans_x + v_trans_y * v_trans_y;\n          if (v_trans_lensq <= 2) {\n            return new Vector2(v_trans_x, v_trans_y);\n          } else {\n            shrink_by = Math.sqrt(v_trans_lensq / 2);\n          }\n        } else {\n          // handle special case of collinear edges\n\n          let direction_eq = false; // assumes: opposite\n\n          if (v_prev_x > Number.EPSILON) {\n            if (v_next_x > Number.EPSILON) {\n              direction_eq = true;\n            }\n          } else {\n            if (v_prev_x < -Number.EPSILON) {\n              if (v_next_x < -Number.EPSILON) {\n                direction_eq = true;\n              }\n            } else {\n              if (Math.sign(v_prev_y) === Math.sign(v_next_y)) {\n                direction_eq = true;\n              }\n            }\n          }\n          if (direction_eq) {\n            // console.log(\"Warning: lines are a straight sequence\");\n            v_trans_x = -v_prev_y;\n            v_trans_y = v_prev_x;\n            shrink_by = Math.sqrt(v_prev_lensq);\n          } else {\n            // console.log(\"Warning: lines are a straight spike\");\n            v_trans_x = v_prev_x;\n            v_trans_y = v_prev_y;\n            shrink_by = Math.sqrt(v_prev_lensq / 2);\n          }\n        }\n        return new Vector2(v_trans_x / shrink_by, v_trans_y / shrink_by);\n      }\n      const contourMovements = [];\n      for (let i = 0, il = contour.length, j = il - 1, k = i + 1; i < il; i++, j++, k++) {\n        if (j === il) j = 0;\n        if (k === il) k = 0;\n\n        //  (j)---(i)---(k)\n        // console.log('i,j,k', i, j , k)\n\n        contourMovements[i] = getBevelVec(contour[i], contour[j], contour[k]);\n      }\n      const holesMovements = [];\n      let oneHoleMovements,\n        verticesMovements = contourMovements.concat();\n      for (let h = 0, hl = holes.length; h < hl; h++) {\n        const ahole = holes[h];\n        oneHoleMovements = [];\n        for (let i = 0, il = ahole.length, j = il - 1, k = i + 1; i < il; i++, j++, k++) {\n          if (j === il) j = 0;\n          if (k === il) k = 0;\n\n          //  (j)---(i)---(k)\n          oneHoleMovements[i] = getBevelVec(ahole[i], ahole[j], ahole[k]);\n        }\n        holesMovements.push(oneHoleMovements);\n        verticesMovements = verticesMovements.concat(oneHoleMovements);\n      }\n\n      // Loop bevelSegments, 1 for the front, 1 for the back\n\n      for (let b = 0; b < bevelSegments; b++) {\n        //for ( b = bevelSegments; b > 0; b -- ) {\n\n        const t = b / bevelSegments;\n        const z = bevelThickness * Math.cos(t * Math.PI / 2);\n        const bs = bevelSize * Math.sin(t * Math.PI / 2) + bevelOffset;\n\n        // contract shape\n\n        for (let i = 0, il = contour.length; i < il; i++) {\n          const vert = scalePt2(contour[i], contourMovements[i], bs);\n          v(vert.x, vert.y, -z);\n        }\n\n        // expand holes\n\n        for (let h = 0, hl = holes.length; h < hl; h++) {\n          const ahole = holes[h];\n          oneHoleMovements = holesMovements[h];\n          for (let i = 0, il = ahole.length; i < il; i++) {\n            const vert = scalePt2(ahole[i], oneHoleMovements[i], bs);\n            v(vert.x, vert.y, -z);\n          }\n        }\n      }\n      const bs = bevelSize + bevelOffset;\n\n      // Back facing vertices\n\n      for (let i = 0; i < vlen; i++) {\n        const vert = bevelEnabled ? scalePt2(vertices[i], verticesMovements[i], bs) : vertices[i];\n        if (!extrudeByPath) {\n          v(vert.x, vert.y, 0);\n        } else {\n          // v( vert.x, vert.y + extrudePts[ 0 ].y, extrudePts[ 0 ].x );\n\n          normal.copy(splineTube.normals[0]).multiplyScalar(vert.x);\n          binormal.copy(splineTube.binormals[0]).multiplyScalar(vert.y);\n          position2.copy(extrudePts[0]).add(normal).add(binormal);\n          v(position2.x, position2.y, position2.z);\n        }\n      }\n\n      // Add stepped vertices...\n      // Including front facing vertices\n\n      for (let s = 1; s <= steps; s++) {\n        for (let i = 0; i < vlen; i++) {\n          const vert = bevelEnabled ? scalePt2(vertices[i], verticesMovements[i], bs) : vertices[i];\n          if (!extrudeByPath) {\n            v(vert.x, vert.y, depth / steps * s);\n          } else {\n            // v( vert.x, vert.y + extrudePts[ s - 1 ].y, extrudePts[ s - 1 ].x );\n\n            normal.copy(splineTube.normals[s]).multiplyScalar(vert.x);\n            binormal.copy(splineTube.binormals[s]).multiplyScalar(vert.y);\n            position2.copy(extrudePts[s]).add(normal).add(binormal);\n            v(position2.x, position2.y, position2.z);\n          }\n        }\n      }\n\n      // Add bevel segments planes\n\n      //for ( b = 1; b <= bevelSegments; b ++ ) {\n      for (let b = bevelSegments - 1; b >= 0; b--) {\n        const t = b / bevelSegments;\n        const z = bevelThickness * Math.cos(t * Math.PI / 2);\n        const bs = bevelSize * Math.sin(t * Math.PI / 2) + bevelOffset;\n\n        // contract shape\n\n        for (let i = 0, il = contour.length; i < il; i++) {\n          const vert = scalePt2(contour[i], contourMovements[i], bs);\n          v(vert.x, vert.y, depth + z);\n        }\n\n        // expand holes\n\n        for (let h = 0, hl = holes.length; h < hl; h++) {\n          const ahole = holes[h];\n          oneHoleMovements = holesMovements[h];\n          for (let i = 0, il = ahole.length; i < il; i++) {\n            const vert = scalePt2(ahole[i], oneHoleMovements[i], bs);\n            if (!extrudeByPath) {\n              v(vert.x, vert.y, depth + z);\n            } else {\n              v(vert.x, vert.y + extrudePts[steps - 1].y, extrudePts[steps - 1].x + z);\n            }\n          }\n        }\n      }\n\n      /* Faces */\n\n      // Top and bottom faces\n\n      buildLidFaces();\n\n      // Sides faces\n\n      buildSideFaces();\n\n      /////  Internal functions\n\n      function buildLidFaces() {\n        const start = verticesArray.length / 3;\n        if (bevelEnabled) {\n          let layer = 0; // steps + 1\n          let offset = vlen * layer;\n\n          // Bottom faces\n\n          for (let i = 0; i < flen; i++) {\n            const face = faces[i];\n            f3(face[2] + offset, face[1] + offset, face[0] + offset);\n          }\n          layer = steps + bevelSegments * 2;\n          offset = vlen * layer;\n\n          // Top faces\n\n          for (let i = 0; i < flen; i++) {\n            const face = faces[i];\n            f3(face[0] + offset, face[1] + offset, face[2] + offset);\n          }\n        } else {\n          // Bottom faces\n\n          for (let i = 0; i < flen; i++) {\n            const face = faces[i];\n            f3(face[2], face[1], face[0]);\n          }\n\n          // Top faces\n\n          for (let i = 0; i < flen; i++) {\n            const face = faces[i];\n            f3(face[0] + vlen * steps, face[1] + vlen * steps, face[2] + vlen * steps);\n          }\n        }\n        scope.addGroup(start, verticesArray.length / 3 - start, 0);\n      }\n\n      // Create faces for the z-sides of the shape\n\n      function buildSideFaces() {\n        const start = verticesArray.length / 3;\n        let layeroffset = 0;\n        sidewalls(contour, layeroffset);\n        layeroffset += contour.length;\n        for (let h = 0, hl = holes.length; h < hl; h++) {\n          const ahole = holes[h];\n          sidewalls(ahole, layeroffset);\n\n          //, true\n          layeroffset += ahole.length;\n        }\n        scope.addGroup(start, verticesArray.length / 3 - start, 1);\n      }\n      function sidewalls(contour, layeroffset) {\n        let i = contour.length;\n        while (--i >= 0) {\n          const j = i;\n          let k = i - 1;\n          if (k < 0) k = contour.length - 1;\n\n          //console.log('b', i,j, i-1, k,vertices.length);\n\n          for (let s = 0, sl = steps + bevelSegments * 2; s < sl; s++) {\n            const slen1 = vlen * s;\n            const slen2 = vlen * (s + 1);\n            const a = layeroffset + j + slen1,\n              b = layeroffset + k + slen1,\n              c = layeroffset + k + slen2,\n              d = layeroffset + j + slen2;\n            f4(a, b, c, d);\n          }\n        }\n      }\n      function v(x, y, z) {\n        placeholder.push(x);\n        placeholder.push(y);\n        placeholder.push(z);\n      }\n      function f3(a, b, c) {\n        addVertex(a);\n        addVertex(b);\n        addVertex(c);\n        const nextIndex = verticesArray.length / 3;\n        const uvs = uvgen.generateTopUV(scope, verticesArray, nextIndex - 3, nextIndex - 2, nextIndex - 1);\n        addUV(uvs[0]);\n        addUV(uvs[1]);\n        addUV(uvs[2]);\n      }\n      function f4(a, b, c, d) {\n        addVertex(a);\n        addVertex(b);\n        addVertex(d);\n        addVertex(b);\n        addVertex(c);\n        addVertex(d);\n        const nextIndex = verticesArray.length / 3;\n        const uvs = uvgen.generateSideWallUV(scope, verticesArray, nextIndex - 6, nextIndex - 3, nextIndex - 2, nextIndex - 1);\n        addUV(uvs[0]);\n        addUV(uvs[1]);\n        addUV(uvs[3]);\n        addUV(uvs[1]);\n        addUV(uvs[2]);\n        addUV(uvs[3]);\n      }\n      function addVertex(index) {\n        verticesArray.push(placeholder[index * 3 + 0]);\n        verticesArray.push(placeholder[index * 3 + 1]);\n        verticesArray.push(placeholder[index * 3 + 2]);\n      }\n      function addUV(vector2) {\n        uvArray.push(vector2.x);\n        uvArray.push(vector2.y);\n      }\n    }\n  }\n  toJSON() {\n    const data = BufferGeometry.prototype.toJSON.call(this);\n    const shapes = this.parameters.shapes;\n    const options = this.parameters.options;\n    return toJSON(shapes, options, data);\n  }\n}\nconst WorldUVGenerator = {\n  generateTopUV: function (geometry, vertices, indexA, indexB, indexC) {\n    const a_x = vertices[indexA * 3];\n    const a_y = vertices[indexA * 3 + 1];\n    const b_x = vertices[indexB * 3];\n    const b_y = vertices[indexB * 3 + 1];\n    const c_x = vertices[indexC * 3];\n    const c_y = vertices[indexC * 3 + 1];\n    return [new Vector2(a_x, a_y), new Vector2(b_x, b_y), new Vector2(c_x, c_y)];\n  },\n  generateSideWallUV: function (geometry, vertices, indexA, indexB, indexC, indexD) {\n    const a_x = vertices[indexA * 3];\n    const a_y = vertices[indexA * 3 + 1];\n    const a_z = vertices[indexA * 3 + 2];\n    const b_x = vertices[indexB * 3];\n    const b_y = vertices[indexB * 3 + 1];\n    const b_z = vertices[indexB * 3 + 2];\n    const c_x = vertices[indexC * 3];\n    const c_y = vertices[indexC * 3 + 1];\n    const c_z = vertices[indexC * 3 + 2];\n    const d_x = vertices[indexD * 3];\n    const d_y = vertices[indexD * 3 + 1];\n    const d_z = vertices[indexD * 3 + 2];\n    if (Math.abs(a_y - b_y) < 0.01) {\n      return [new Vector2(a_x, 1 - a_z), new Vector2(b_x, 1 - b_z), new Vector2(c_x, 1 - c_z), new Vector2(d_x, 1 - d_z)];\n    } else {\n      return [new Vector2(a_y, 1 - a_z), new Vector2(b_y, 1 - b_z), new Vector2(c_y, 1 - c_z), new Vector2(d_y, 1 - d_z)];\n    }\n  }\n};\nfunction toJSON(shapes, options, data) {\n  data.shapes = [];\n  if (Array.isArray(shapes)) {\n    for (let i = 0, l = shapes.length; i < l; i++) {\n      const shape = shapes[i];\n      data.shapes.push(shape.uuid);\n    }\n  } else {\n    data.shapes.push(shapes.uuid);\n  }\n  if (options.extrudePath !== undefined) data.options.extrudePath = options.extrudePath.toJSON();\n  return data;\n}\n\n/**\n * Parametric Surfaces Geometry\n * based on the brilliant article by @prideout https://prideout.net/blog/old/blog/index.html@p=44.html\n */\n\nfunction ParametricGeometry(func, slices, stacks) {\n  BufferGeometry.call(this);\n  this.type = 'ParametricGeometry';\n  this.parameters = {\n    func: func,\n    slices: slices,\n    stacks: stacks\n  };\n\n  // buffers\n\n  const indices = [];\n  const vertices = [];\n  const normals = [];\n  const uvs = [];\n  const EPS = 0.00001;\n  const normal = new Vector3();\n  const p0 = new Vector3(),\n    p1 = new Vector3();\n  const pu = new Vector3(),\n    pv = new Vector3();\n  if (func.length < 3) {\n    console.error('THREE.ParametricGeometry: Function must now modify a Vector3 as third parameter.');\n  }\n\n  // generate vertices, normals and uvs\n\n  const sliceCount = slices + 1;\n  for (let i = 0; i <= stacks; i++) {\n    const v = i / stacks;\n    for (let j = 0; j <= slices; j++) {\n      const u = j / slices;\n\n      // vertex\n\n      func(u, v, p0);\n      vertices.push(p0.x, p0.y, p0.z);\n\n      // normal\n\n      // approximate tangent vectors via finite differences\n\n      if (u - EPS >= 0) {\n        func(u - EPS, v, p1);\n        pu.subVectors(p0, p1);\n      } else {\n        func(u + EPS, v, p1);\n        pu.subVectors(p1, p0);\n      }\n      if (v - EPS >= 0) {\n        func(u, v - EPS, p1);\n        pv.subVectors(p0, p1);\n      } else {\n        func(u, v + EPS, p1);\n        pv.subVectors(p1, p0);\n      }\n\n      // cross product of tangent vectors returns surface normal\n\n      normal.crossVectors(pu, pv).normalize();\n      normals.push(normal.x, normal.y, normal.z);\n\n      // uv\n\n      uvs.push(u, v);\n    }\n  }\n\n  // generate indices\n\n  for (let i = 0; i < stacks; i++) {\n    for (let j = 0; j < slices; j++) {\n      const a = i * sliceCount + j;\n      const b = i * sliceCount + j + 1;\n      const c = (i + 1) * sliceCount + j + 1;\n      const d = (i + 1) * sliceCount + j;\n\n      // faces one and two\n\n      indices.push(a, b, d);\n      indices.push(b, c, d);\n    }\n  }\n\n  // build geometry\n\n  this.setIndex(indices);\n  this.setAttribute('position', new Float32BufferAttribute(vertices, 3));\n  this.setAttribute('normal', new Float32BufferAttribute(normals, 3));\n  this.setAttribute('uv', new Float32BufferAttribute(uvs, 2));\n}\nParametricGeometry.prototype = Object.create(BufferGeometry.prototype);\nParametricGeometry.prototype.constructor = ParametricGeometry;\nclass ShapeGeometry extends BufferGeometry {\n  constructor(shapes, curveSegments = 12) {\n    super();\n    this.type = 'ShapeGeometry';\n    this.parameters = {\n      shapes: shapes,\n      curveSegments: curveSegments\n    };\n\n    // buffers\n\n    const indices = [];\n    const vertices = [];\n    const normals = [];\n    const uvs = [];\n\n    // helper variables\n\n    let groupStart = 0;\n    let groupCount = 0;\n\n    // allow single and array values for \"shapes\" parameter\n\n    if (Array.isArray(shapes) === false) {\n      addShape(shapes);\n    } else {\n      for (let i = 0; i < shapes.length; i++) {\n        addShape(shapes[i]);\n        this.addGroup(groupStart, groupCount, i); // enables MultiMaterial support\n\n        groupStart += groupCount;\n        groupCount = 0;\n      }\n    }\n\n    // build geometry\n\n    this.setIndex(indices);\n    this.setAttribute('position', new Float32BufferAttribute(vertices, 3));\n    this.setAttribute('normal', new Float32BufferAttribute(normals, 3));\n    this.setAttribute('uv', new Float32BufferAttribute(uvs, 2));\n\n    // helper functions\n\n    function addShape(shape) {\n      const indexOffset = vertices.length / 3;\n      const points = shape.extractPoints(curveSegments);\n      let shapeVertices = points.shape;\n      const shapeHoles = points.holes;\n\n      // check direction of vertices\n\n      if (ShapeUtils.isClockWise(shapeVertices) === false) {\n        shapeVertices = shapeVertices.reverse();\n      }\n      for (let i = 0, l = shapeHoles.length; i < l; i++) {\n        const shapeHole = shapeHoles[i];\n        if (ShapeUtils.isClockWise(shapeHole) === true) {\n          shapeHoles[i] = shapeHole.reverse();\n        }\n      }\n      const faces = ShapeUtils.triangulateShape(shapeVertices, shapeHoles);\n\n      // join vertices of inner and outer paths to a single array\n\n      for (let i = 0, l = shapeHoles.length; i < l; i++) {\n        const shapeHole = shapeHoles[i];\n        shapeVertices = shapeVertices.concat(shapeHole);\n      }\n\n      // vertices, normals, uvs\n\n      for (let i = 0, l = shapeVertices.length; i < l; i++) {\n        const vertex = shapeVertices[i];\n        vertices.push(vertex.x, vertex.y, 0);\n        normals.push(0, 0, 1);\n        uvs.push(vertex.x, vertex.y); // world uvs\n      }\n\n      // incides\n\n      for (let i = 0, l = faces.length; i < l; i++) {\n        const face = faces[i];\n        const a = face[0] + indexOffset;\n        const b = face[1] + indexOffset;\n        const c = face[2] + indexOffset;\n        indices.push(a, b, c);\n        groupCount += 3;\n      }\n    }\n  }\n  toJSON() {\n    const data = BufferGeometry.prototype.toJSON.call(this);\n    const shapes = this.parameters.shapes;\n    return toJSON$1(shapes, data);\n  }\n}\nfunction toJSON$1(shapes, data) {\n  data.shapes = [];\n  if (Array.isArray(shapes)) {\n    for (let i = 0, l = shapes.length; i < l; i++) {\n      const shape = shapes[i];\n      data.shapes.push(shape.uuid);\n    }\n  } else {\n    data.shapes.push(shapes.uuid);\n  }\n  return data;\n}\nclass SphereGeometry extends BufferGeometry {\n  constructor(radius = 1, widthSegments = 8, heightSegments = 6, phiStart = 0, phiLength = Math.PI * 2, thetaStart = 0, thetaLength = Math.PI) {\n    super();\n    this.type = 'SphereGeometry';\n    this.parameters = {\n      radius: radius,\n      widthSegments: widthSegments,\n      heightSegments: heightSegments,\n      phiStart: phiStart,\n      phiLength: phiLength,\n      thetaStart: thetaStart,\n      thetaLength: thetaLength\n    };\n    widthSegments = Math.max(3, Math.floor(widthSegments));\n    heightSegments = Math.max(2, Math.floor(heightSegments));\n    const thetaEnd = Math.min(thetaStart + thetaLength, Math.PI);\n    let index = 0;\n    const grid = [];\n    const vertex = new Vector3();\n    const normal = new Vector3();\n\n    // buffers\n\n    const indices = [];\n    const vertices = [];\n    const normals = [];\n    const uvs = [];\n\n    // generate vertices, normals and uvs\n\n    for (let iy = 0; iy <= heightSegments; iy++) {\n      const verticesRow = [];\n      const v = iy / heightSegments;\n\n      // special case for the poles\n\n      let uOffset = 0;\n      if (iy == 0 && thetaStart == 0) {\n        uOffset = 0.5 / widthSegments;\n      } else if (iy == heightSegments && thetaEnd == Math.PI) {\n        uOffset = -0.5 / widthSegments;\n      }\n      for (let ix = 0; ix <= widthSegments; ix++) {\n        const u = ix / widthSegments;\n\n        // vertex\n\n        vertex.x = -radius * Math.cos(phiStart + u * phiLength) * Math.sin(thetaStart + v * thetaLength);\n        vertex.y = radius * Math.cos(thetaStart + v * thetaLength);\n        vertex.z = radius * Math.sin(phiStart + u * phiLength) * Math.sin(thetaStart + v * thetaLength);\n        vertices.push(vertex.x, vertex.y, vertex.z);\n\n        // normal\n\n        normal.copy(vertex).normalize();\n        normals.push(normal.x, normal.y, normal.z);\n\n        // uv\n\n        uvs.push(u + uOffset, 1 - v);\n        verticesRow.push(index++);\n      }\n      grid.push(verticesRow);\n    }\n\n    // indices\n\n    for (let iy = 0; iy < heightSegments; iy++) {\n      for (let ix = 0; ix < widthSegments; ix++) {\n        const a = grid[iy][ix + 1];\n        const b = grid[iy][ix];\n        const c = grid[iy + 1][ix];\n        const d = grid[iy + 1][ix + 1];\n        if (iy !== 0 || thetaStart > 0) indices.push(a, b, d);\n        if (iy !== heightSegments - 1 || thetaEnd < Math.PI) indices.push(b, c, d);\n      }\n    }\n\n    // build geometry\n\n    this.setIndex(indices);\n    this.setAttribute('position', new Float32BufferAttribute(vertices, 3));\n    this.setAttribute('normal', new Float32BufferAttribute(normals, 3));\n    this.setAttribute('uv', new Float32BufferAttribute(uvs, 2));\n  }\n}\n\n/**\n * parameters = {\n *  color: <THREE.Color>\n * }\n */\n\nfunction ShadowMaterial(parameters) {\n  Material.call(this);\n  this.type = 'ShadowMaterial';\n  this.color = new Color(0x000000);\n  this.transparent = true;\n  this.setValues(parameters);\n}\nShadowMaterial.prototype = Object.create(Material.prototype);\nShadowMaterial.prototype.constructor = ShadowMaterial;\nShadowMaterial.prototype.isShadowMaterial = true;\nShadowMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  return this;\n};\nfunction RawShaderMaterial(parameters) {\n  ShaderMaterial.call(this, parameters);\n  this.type = 'RawShaderMaterial';\n}\nRawShaderMaterial.prototype = Object.create(ShaderMaterial.prototype);\nRawShaderMaterial.prototype.constructor = RawShaderMaterial;\nRawShaderMaterial.prototype.isRawShaderMaterial = true;\n\n/**\n * parameters = {\n *  color: <hex>,\n *  roughness: <float>,\n *  metalness: <float>,\n *  opacity: <float>,\n *\n *  map: new THREE.Texture( <Image> ),\n *\n *  lightMap: new THREE.Texture( <Image> ),\n *  lightMapIntensity: <float>\n *\n *  aoMap: new THREE.Texture( <Image> ),\n *  aoMapIntensity: <float>\n *\n *  emissive: <hex>,\n *  emissiveIntensity: <float>\n *  emissiveMap: new THREE.Texture( <Image> ),\n *\n *  bumpMap: new THREE.Texture( <Image> ),\n *  bumpScale: <float>,\n *\n *  normalMap: new THREE.Texture( <Image> ),\n *  normalMapType: THREE.TangentSpaceNormalMap,\n *  normalScale: <Vector2>,\n *\n *  displacementMap: new THREE.Texture( <Image> ),\n *  displacementScale: <float>,\n *  displacementBias: <float>,\n *\n *  roughnessMap: new THREE.Texture( <Image> ),\n *\n *  metalnessMap: new THREE.Texture( <Image> ),\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  envMap: new THREE.CubeTexture( [posx, negx, posy, negy, posz, negz] ),\n *  envMapIntensity: <float>\n *\n *  refractionRatio: <float>,\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>,\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *  morphNormals: <bool>\n * }\n */\n\nfunction MeshStandardMaterial(parameters) {\n  Material.call(this);\n  this.defines = {\n    'STANDARD': ''\n  };\n  this.type = 'MeshStandardMaterial';\n  this.color = new Color(0xffffff); // diffuse\n  this.roughness = 1.0;\n  this.metalness = 0.0;\n  this.map = null;\n  this.lightMap = null;\n  this.lightMapIntensity = 1.0;\n  this.aoMap = null;\n  this.aoMapIntensity = 1.0;\n  this.emissive = new Color(0x000000);\n  this.emissiveIntensity = 1.0;\n  this.emissiveMap = null;\n  this.bumpMap = null;\n  this.bumpScale = 1;\n  this.normalMap = null;\n  this.normalMapType = TangentSpaceNormalMap;\n  this.normalScale = new Vector2(1, 1);\n  this.displacementMap = null;\n  this.displacementScale = 1;\n  this.displacementBias = 0;\n  this.roughnessMap = null;\n  this.metalnessMap = null;\n  this.alphaMap = null;\n  this.envMap = null;\n  this.envMapIntensity = 1.0;\n  this.refractionRatio = 0.98;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.wireframeLinecap = 'round';\n  this.wireframeLinejoin = 'round';\n  this.skinning = false;\n  this.morphTargets = false;\n  this.morphNormals = false;\n  this.vertexTangents = false;\n  this.setValues(parameters);\n}\nMeshStandardMaterial.prototype = Object.create(Material.prototype);\nMeshStandardMaterial.prototype.constructor = MeshStandardMaterial;\nMeshStandardMaterial.prototype.isMeshStandardMaterial = true;\nMeshStandardMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.defines = {\n    'STANDARD': ''\n  };\n  this.color.copy(source.color);\n  this.roughness = source.roughness;\n  this.metalness = source.metalness;\n  this.map = source.map;\n  this.lightMap = source.lightMap;\n  this.lightMapIntensity = source.lightMapIntensity;\n  this.aoMap = source.aoMap;\n  this.aoMapIntensity = source.aoMapIntensity;\n  this.emissive.copy(source.emissive);\n  this.emissiveMap = source.emissiveMap;\n  this.emissiveIntensity = source.emissiveIntensity;\n  this.bumpMap = source.bumpMap;\n  this.bumpScale = source.bumpScale;\n  this.normalMap = source.normalMap;\n  this.normalMapType = source.normalMapType;\n  this.normalScale.copy(source.normalScale);\n  this.displacementMap = source.displacementMap;\n  this.displacementScale = source.displacementScale;\n  this.displacementBias = source.displacementBias;\n  this.roughnessMap = source.roughnessMap;\n  this.metalnessMap = source.metalnessMap;\n  this.alphaMap = source.alphaMap;\n  this.envMap = source.envMap;\n  this.envMapIntensity = source.envMapIntensity;\n  this.refractionRatio = source.refractionRatio;\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  this.wireframeLinecap = source.wireframeLinecap;\n  this.wireframeLinejoin = source.wireframeLinejoin;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.morphNormals = source.morphNormals;\n  this.vertexTangents = source.vertexTangents;\n  return this;\n};\n\n/**\n * parameters = {\n *  clearcoat: <float>,\n *  clearcoatMap: new THREE.Texture( <Image> ),\n *  clearcoatRoughness: <float>,\n *  clearcoatRoughnessMap: new THREE.Texture( <Image> ),\n *  clearcoatNormalScale: <Vector2>,\n *  clearcoatNormalMap: new THREE.Texture( <Image> ),\n *\n *  reflectivity: <float>,\n *  ior: <float>,\n *\n *  sheen: <Color>,\n *\n *  transmission: <float>,\n *  transmissionMap: new THREE.Texture( <Image> )\n * }\n */\n\nfunction MeshPhysicalMaterial(parameters) {\n  MeshStandardMaterial.call(this);\n  this.defines = {\n    'STANDARD': '',\n    'PHYSICAL': ''\n  };\n  this.type = 'MeshPhysicalMaterial';\n  this.clearcoat = 0.0;\n  this.clearcoatMap = null;\n  this.clearcoatRoughness = 0.0;\n  this.clearcoatRoughnessMap = null;\n  this.clearcoatNormalScale = new Vector2(1, 1);\n  this.clearcoatNormalMap = null;\n  this.reflectivity = 0.5; // maps to F0 = 0.04\n\n  Object.defineProperty(this, 'ior', {\n    get: function () {\n      return (1 + 0.4 * this.reflectivity) / (1 - 0.4 * this.reflectivity);\n    },\n    set: function (ior) {\n      this.reflectivity = MathUtils.clamp(2.5 * (ior - 1) / (ior + 1), 0, 1);\n    }\n  });\n  this.sheen = null; // null will disable sheen bsdf\n\n  this.transmission = 0.0;\n  this.transmissionMap = null;\n  this.setValues(parameters);\n}\nMeshPhysicalMaterial.prototype = Object.create(MeshStandardMaterial.prototype);\nMeshPhysicalMaterial.prototype.constructor = MeshPhysicalMaterial;\nMeshPhysicalMaterial.prototype.isMeshPhysicalMaterial = true;\nMeshPhysicalMaterial.prototype.copy = function (source) {\n  MeshStandardMaterial.prototype.copy.call(this, source);\n  this.defines = {\n    'STANDARD': '',\n    'PHYSICAL': ''\n  };\n  this.clearcoat = source.clearcoat;\n  this.clearcoatMap = source.clearcoatMap;\n  this.clearcoatRoughness = source.clearcoatRoughness;\n  this.clearcoatRoughnessMap = source.clearcoatRoughnessMap;\n  this.clearcoatNormalMap = source.clearcoatNormalMap;\n  this.clearcoatNormalScale.copy(source.clearcoatNormalScale);\n  this.reflectivity = source.reflectivity;\n  if (source.sheen) {\n    this.sheen = (this.sheen || new Color()).copy(source.sheen);\n  } else {\n    this.sheen = null;\n  }\n  this.transmission = source.transmission;\n  this.transmissionMap = source.transmissionMap;\n  return this;\n};\n\n/**\n * parameters = {\n *  color: <hex>,\n *  specular: <hex>,\n *  shininess: <float>,\n *  opacity: <float>,\n *\n *  map: new THREE.Texture( <Image> ),\n *\n *  lightMap: new THREE.Texture( <Image> ),\n *  lightMapIntensity: <float>\n *\n *  aoMap: new THREE.Texture( <Image> ),\n *  aoMapIntensity: <float>\n *\n *  emissive: <hex>,\n *  emissiveIntensity: <float>\n *  emissiveMap: new THREE.Texture( <Image> ),\n *\n *  bumpMap: new THREE.Texture( <Image> ),\n *  bumpScale: <float>,\n *\n *  normalMap: new THREE.Texture( <Image> ),\n *  normalMapType: THREE.TangentSpaceNormalMap,\n *  normalScale: <Vector2>,\n *\n *  displacementMap: new THREE.Texture( <Image> ),\n *  displacementScale: <float>,\n *  displacementBias: <float>,\n *\n *  specularMap: new THREE.Texture( <Image> ),\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  envMap: new THREE.CubeTexture( [posx, negx, posy, negy, posz, negz] ),\n *  combine: THREE.MultiplyOperation,\n *  reflectivity: <float>,\n *  refractionRatio: <float>,\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>,\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *  morphNormals: <bool>\n * }\n */\n\nfunction MeshPhongMaterial(parameters) {\n  Material.call(this);\n  this.type = 'MeshPhongMaterial';\n  this.color = new Color(0xffffff); // diffuse\n  this.specular = new Color(0x111111);\n  this.shininess = 30;\n  this.map = null;\n  this.lightMap = null;\n  this.lightMapIntensity = 1.0;\n  this.aoMap = null;\n  this.aoMapIntensity = 1.0;\n  this.emissive = new Color(0x000000);\n  this.emissiveIntensity = 1.0;\n  this.emissiveMap = null;\n  this.bumpMap = null;\n  this.bumpScale = 1;\n  this.normalMap = null;\n  this.normalMapType = TangentSpaceNormalMap;\n  this.normalScale = new Vector2(1, 1);\n  this.displacementMap = null;\n  this.displacementScale = 1;\n  this.displacementBias = 0;\n  this.specularMap = null;\n  this.alphaMap = null;\n  this.envMap = null;\n  this.combine = MultiplyOperation;\n  this.reflectivity = 1;\n  this.refractionRatio = 0.98;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.wireframeLinecap = 'round';\n  this.wireframeLinejoin = 'round';\n  this.skinning = false;\n  this.morphTargets = false;\n  this.morphNormals = false;\n  this.setValues(parameters);\n}\nMeshPhongMaterial.prototype = Object.create(Material.prototype);\nMeshPhongMaterial.prototype.constructor = MeshPhongMaterial;\nMeshPhongMaterial.prototype.isMeshPhongMaterial = true;\nMeshPhongMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  this.specular.copy(source.specular);\n  this.shininess = source.shininess;\n  this.map = source.map;\n  this.lightMap = source.lightMap;\n  this.lightMapIntensity = source.lightMapIntensity;\n  this.aoMap = source.aoMap;\n  this.aoMapIntensity = source.aoMapIntensity;\n  this.emissive.copy(source.emissive);\n  this.emissiveMap = source.emissiveMap;\n  this.emissiveIntensity = source.emissiveIntensity;\n  this.bumpMap = source.bumpMap;\n  this.bumpScale = source.bumpScale;\n  this.normalMap = source.normalMap;\n  this.normalMapType = source.normalMapType;\n  this.normalScale.copy(source.normalScale);\n  this.displacementMap = source.displacementMap;\n  this.displacementScale = source.displacementScale;\n  this.displacementBias = source.displacementBias;\n  this.specularMap = source.specularMap;\n  this.alphaMap = source.alphaMap;\n  this.envMap = source.envMap;\n  this.combine = source.combine;\n  this.reflectivity = source.reflectivity;\n  this.refractionRatio = source.refractionRatio;\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  this.wireframeLinecap = source.wireframeLinecap;\n  this.wireframeLinejoin = source.wireframeLinejoin;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.morphNormals = source.morphNormals;\n  return this;\n};\n\n/**\n * parameters = {\n *  color: <hex>,\n *\n *  map: new THREE.Texture( <Image> ),\n *  gradientMap: new THREE.Texture( <Image> ),\n *\n *  lightMap: new THREE.Texture( <Image> ),\n *  lightMapIntensity: <float>\n *\n *  aoMap: new THREE.Texture( <Image> ),\n *  aoMapIntensity: <float>\n *\n *  emissive: <hex>,\n *  emissiveIntensity: <float>\n *  emissiveMap: new THREE.Texture( <Image> ),\n *\n *  bumpMap: new THREE.Texture( <Image> ),\n *  bumpScale: <float>,\n *\n *  normalMap: new THREE.Texture( <Image> ),\n *  normalMapType: THREE.TangentSpaceNormalMap,\n *  normalScale: <Vector2>,\n *\n *  displacementMap: new THREE.Texture( <Image> ),\n *  displacementScale: <float>,\n *  displacementBias: <float>,\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>,\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *  morphNormals: <bool>\n * }\n */\n\nfunction MeshToonMaterial(parameters) {\n  Material.call(this);\n  this.defines = {\n    'TOON': ''\n  };\n  this.type = 'MeshToonMaterial';\n  this.color = new Color(0xffffff);\n  this.map = null;\n  this.gradientMap = null;\n  this.lightMap = null;\n  this.lightMapIntensity = 1.0;\n  this.aoMap = null;\n  this.aoMapIntensity = 1.0;\n  this.emissive = new Color(0x000000);\n  this.emissiveIntensity = 1.0;\n  this.emissiveMap = null;\n  this.bumpMap = null;\n  this.bumpScale = 1;\n  this.normalMap = null;\n  this.normalMapType = TangentSpaceNormalMap;\n  this.normalScale = new Vector2(1, 1);\n  this.displacementMap = null;\n  this.displacementScale = 1;\n  this.displacementBias = 0;\n  this.alphaMap = null;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.wireframeLinecap = 'round';\n  this.wireframeLinejoin = 'round';\n  this.skinning = false;\n  this.morphTargets = false;\n  this.morphNormals = false;\n  this.setValues(parameters);\n}\nMeshToonMaterial.prototype = Object.create(Material.prototype);\nMeshToonMaterial.prototype.constructor = MeshToonMaterial;\nMeshToonMaterial.prototype.isMeshToonMaterial = true;\nMeshToonMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  this.map = source.map;\n  this.gradientMap = source.gradientMap;\n  this.lightMap = source.lightMap;\n  this.lightMapIntensity = source.lightMapIntensity;\n  this.aoMap = source.aoMap;\n  this.aoMapIntensity = source.aoMapIntensity;\n  this.emissive.copy(source.emissive);\n  this.emissiveMap = source.emissiveMap;\n  this.emissiveIntensity = source.emissiveIntensity;\n  this.bumpMap = source.bumpMap;\n  this.bumpScale = source.bumpScale;\n  this.normalMap = source.normalMap;\n  this.normalMapType = source.normalMapType;\n  this.normalScale.copy(source.normalScale);\n  this.displacementMap = source.displacementMap;\n  this.displacementScale = source.displacementScale;\n  this.displacementBias = source.displacementBias;\n  this.alphaMap = source.alphaMap;\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  this.wireframeLinecap = source.wireframeLinecap;\n  this.wireframeLinejoin = source.wireframeLinejoin;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.morphNormals = source.morphNormals;\n  return this;\n};\n\n/**\n * parameters = {\n *  opacity: <float>,\n *\n *  bumpMap: new THREE.Texture( <Image> ),\n *  bumpScale: <float>,\n *\n *  normalMap: new THREE.Texture( <Image> ),\n *  normalMapType: THREE.TangentSpaceNormalMap,\n *  normalScale: <Vector2>,\n *\n *  displacementMap: new THREE.Texture( <Image> ),\n *  displacementScale: <float>,\n *  displacementBias: <float>,\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *  morphNormals: <bool>\n * }\n */\n\nfunction MeshNormalMaterial(parameters) {\n  Material.call(this);\n  this.type = 'MeshNormalMaterial';\n  this.bumpMap = null;\n  this.bumpScale = 1;\n  this.normalMap = null;\n  this.normalMapType = TangentSpaceNormalMap;\n  this.normalScale = new Vector2(1, 1);\n  this.displacementMap = null;\n  this.displacementScale = 1;\n  this.displacementBias = 0;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.fog = false;\n  this.skinning = false;\n  this.morphTargets = false;\n  this.morphNormals = false;\n  this.setValues(parameters);\n}\nMeshNormalMaterial.prototype = Object.create(Material.prototype);\nMeshNormalMaterial.prototype.constructor = MeshNormalMaterial;\nMeshNormalMaterial.prototype.isMeshNormalMaterial = true;\nMeshNormalMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.bumpMap = source.bumpMap;\n  this.bumpScale = source.bumpScale;\n  this.normalMap = source.normalMap;\n  this.normalMapType = source.normalMapType;\n  this.normalScale.copy(source.normalScale);\n  this.displacementMap = source.displacementMap;\n  this.displacementScale = source.displacementScale;\n  this.displacementBias = source.displacementBias;\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.morphNormals = source.morphNormals;\n  return this;\n};\n\n/**\n * parameters = {\n *  color: <hex>,\n *  opacity: <float>,\n *\n *  map: new THREE.Texture( <Image> ),\n *\n *  lightMap: new THREE.Texture( <Image> ),\n *  lightMapIntensity: <float>\n *\n *  aoMap: new THREE.Texture( <Image> ),\n *  aoMapIntensity: <float>\n *\n *  emissive: <hex>,\n *  emissiveIntensity: <float>\n *  emissiveMap: new THREE.Texture( <Image> ),\n *\n *  specularMap: new THREE.Texture( <Image> ),\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  envMap: new THREE.CubeTexture( [posx, negx, posy, negy, posz, negz] ),\n *  combine: THREE.Multiply,\n *  reflectivity: <float>,\n *  refractionRatio: <float>,\n *\n *  wireframe: <boolean>,\n *  wireframeLinewidth: <float>,\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *  morphNormals: <bool>\n * }\n */\n\nfunction MeshLambertMaterial(parameters) {\n  Material.call(this);\n  this.type = 'MeshLambertMaterial';\n  this.color = new Color(0xffffff); // diffuse\n\n  this.map = null;\n  this.lightMap = null;\n  this.lightMapIntensity = 1.0;\n  this.aoMap = null;\n  this.aoMapIntensity = 1.0;\n  this.emissive = new Color(0x000000);\n  this.emissiveIntensity = 1.0;\n  this.emissiveMap = null;\n  this.specularMap = null;\n  this.alphaMap = null;\n  this.envMap = null;\n  this.combine = MultiplyOperation;\n  this.reflectivity = 1;\n  this.refractionRatio = 0.98;\n  this.wireframe = false;\n  this.wireframeLinewidth = 1;\n  this.wireframeLinecap = 'round';\n  this.wireframeLinejoin = 'round';\n  this.skinning = false;\n  this.morphTargets = false;\n  this.morphNormals = false;\n  this.setValues(parameters);\n}\nMeshLambertMaterial.prototype = Object.create(Material.prototype);\nMeshLambertMaterial.prototype.constructor = MeshLambertMaterial;\nMeshLambertMaterial.prototype.isMeshLambertMaterial = true;\nMeshLambertMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.color.copy(source.color);\n  this.map = source.map;\n  this.lightMap = source.lightMap;\n  this.lightMapIntensity = source.lightMapIntensity;\n  this.aoMap = source.aoMap;\n  this.aoMapIntensity = source.aoMapIntensity;\n  this.emissive.copy(source.emissive);\n  this.emissiveMap = source.emissiveMap;\n  this.emissiveIntensity = source.emissiveIntensity;\n  this.specularMap = source.specularMap;\n  this.alphaMap = source.alphaMap;\n  this.envMap = source.envMap;\n  this.combine = source.combine;\n  this.reflectivity = source.reflectivity;\n  this.refractionRatio = source.refractionRatio;\n  this.wireframe = source.wireframe;\n  this.wireframeLinewidth = source.wireframeLinewidth;\n  this.wireframeLinecap = source.wireframeLinecap;\n  this.wireframeLinejoin = source.wireframeLinejoin;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.morphNormals = source.morphNormals;\n  return this;\n};\n\n/**\n * parameters = {\n *  color: <hex>,\n *  opacity: <float>,\n *\n *  matcap: new THREE.Texture( <Image> ),\n *\n *  map: new THREE.Texture( <Image> ),\n *\n *  bumpMap: new THREE.Texture( <Image> ),\n *  bumpScale: <float>,\n *\n *  normalMap: new THREE.Texture( <Image> ),\n *  normalMapType: THREE.TangentSpaceNormalMap,\n *  normalScale: <Vector2>,\n *\n *  displacementMap: new THREE.Texture( <Image> ),\n *  displacementScale: <float>,\n *  displacementBias: <float>,\n *\n *  alphaMap: new THREE.Texture( <Image> ),\n *\n *  skinning: <bool>,\n *  morphTargets: <bool>,\n *  morphNormals: <bool>\n * }\n */\n\nfunction MeshMatcapMaterial(parameters) {\n  Material.call(this);\n  this.defines = {\n    'MATCAP': ''\n  };\n  this.type = 'MeshMatcapMaterial';\n  this.color = new Color(0xffffff); // diffuse\n\n  this.matcap = null;\n  this.map = null;\n  this.bumpMap = null;\n  this.bumpScale = 1;\n  this.normalMap = null;\n  this.normalMapType = TangentSpaceNormalMap;\n  this.normalScale = new Vector2(1, 1);\n  this.displacementMap = null;\n  this.displacementScale = 1;\n  this.displacementBias = 0;\n  this.alphaMap = null;\n  this.skinning = false;\n  this.morphTargets = false;\n  this.morphNormals = false;\n  this.setValues(parameters);\n}\nMeshMatcapMaterial.prototype = Object.create(Material.prototype);\nMeshMatcapMaterial.prototype.constructor = MeshMatcapMaterial;\nMeshMatcapMaterial.prototype.isMeshMatcapMaterial = true;\nMeshMatcapMaterial.prototype.copy = function (source) {\n  Material.prototype.copy.call(this, source);\n  this.defines = {\n    'MATCAP': ''\n  };\n  this.color.copy(source.color);\n  this.matcap = source.matcap;\n  this.map = source.map;\n  this.bumpMap = source.bumpMap;\n  this.bumpScale = source.bumpScale;\n  this.normalMap = source.normalMap;\n  this.normalMapType = source.normalMapType;\n  this.normalScale.copy(source.normalScale);\n  this.displacementMap = source.displacementMap;\n  this.displacementScale = source.displacementScale;\n  this.displacementBias = source.displacementBias;\n  this.alphaMap = source.alphaMap;\n  this.skinning = source.skinning;\n  this.morphTargets = source.morphTargets;\n  this.morphNormals = source.morphNormals;\n  return this;\n};\n\n/**\n * parameters = {\n *  color: <hex>,\n *  opacity: <float>,\n *\n *  linewidth: <float>,\n *\n *  scale: <float>,\n *  dashSize: <float>,\n *  gapSize: <float>\n * }\n */\n\nfunction LineDashedMaterial(parameters) {\n  LineBasicMaterial.call(this);\n  this.type = 'LineDashedMaterial';\n  this.scale = 1;\n  this.dashSize = 3;\n  this.gapSize = 1;\n  this.setValues(parameters);\n}\nLineDashedMaterial.prototype = Object.create(LineBasicMaterial.prototype);\nLineDashedMaterial.prototype.constructor = LineDashedMaterial;\nLineDashedMaterial.prototype.isLineDashedMaterial = true;\nLineDashedMaterial.prototype.copy = function (source) {\n  LineBasicMaterial.prototype.copy.call(this, source);\n  this.scale = source.scale;\n  this.dashSize = source.dashSize;\n  this.gapSize = source.gapSize;\n  return this;\n};\nvar Materials = /*#__PURE__*/Object.freeze({\n  __proto__: null,\n  ShadowMaterial: ShadowMaterial,\n  SpriteMaterial: SpriteMaterial,\n  RawShaderMaterial: RawShaderMaterial,\n  ShaderMaterial: ShaderMaterial,\n  PointsMaterial: PointsMaterial,\n  MeshPhysicalMaterial: MeshPhysicalMaterial,\n  MeshStandardMaterial: MeshStandardMaterial,\n  MeshPhongMaterial: MeshPhongMaterial,\n  MeshToonMaterial: MeshToonMaterial,\n  MeshNormalMaterial: MeshNormalMaterial,\n  MeshLambertMaterial: MeshLambertMaterial,\n  MeshDepthMaterial: MeshDepthMaterial,\n  MeshDistanceMaterial: MeshDistanceMaterial,\n  MeshBasicMaterial: MeshBasicMaterial,\n  MeshMatcapMaterial: MeshMatcapMaterial,\n  LineDashedMaterial: LineDashedMaterial,\n  LineBasicMaterial: LineBasicMaterial,\n  Material: Material\n});\nconst AnimationUtils = {\n  // same as Array.prototype.slice, but also works on typed arrays\n  arraySlice: function (array, from, to) {\n    if (AnimationUtils.isTypedArray(array)) {\n      // in ios9 array.subarray(from, undefined) will return empty array\n      // but array.subarray(from) or array.subarray(from, len) is correct\n      return new array.constructor(array.subarray(from, to !== undefined ? to : array.length));\n    }\n    return array.slice(from, to);\n  },\n  // converts an array to a specific type\n  convertArray: function (array, type, forceClone) {\n    if (!array ||\n    // let 'undefined' and 'null' pass\n    !forceClone && array.constructor === type) return array;\n    if (typeof type.BYTES_PER_ELEMENT === 'number') {\n      return new type(array); // create typed array\n    }\n\n    return Array.prototype.slice.call(array); // create Array\n  },\n\n  isTypedArray: function (object) {\n    return ArrayBuffer.isView(object) && !(object instanceof DataView);\n  },\n  // returns an array by which times and values can be sorted\n  getKeyframeOrder: function (times) {\n    function compareTime(i, j) {\n      return times[i] - times[j];\n    }\n    const n = times.length;\n    const result = new Array(n);\n    for (let i = 0; i !== n; ++i) result[i] = i;\n    result.sort(compareTime);\n    return result;\n  },\n  // uses the array previously returned by 'getKeyframeOrder' to sort data\n  sortedArray: function (values, stride, order) {\n    const nValues = values.length;\n    const result = new values.constructor(nValues);\n    for (let i = 0, dstOffset = 0; dstOffset !== nValues; ++i) {\n      const srcOffset = order[i] * stride;\n      for (let j = 0; j !== stride; ++j) {\n        result[dstOffset++] = values[srcOffset + j];\n      }\n    }\n    return result;\n  },\n  // function for parsing AOS keyframe formats\n  flattenJSON: function (jsonKeys, times, values, valuePropertyName) {\n    let i = 1,\n      key = jsonKeys[0];\n    while (key !== undefined && key[valuePropertyName] === undefined) {\n      key = jsonKeys[i++];\n    }\n    if (key === undefined) return; // no data\n\n    let value = key[valuePropertyName];\n    if (value === undefined) return; // no data\n\n    if (Array.isArray(value)) {\n      do {\n        value = key[valuePropertyName];\n        if (value !== undefined) {\n          times.push(key.time);\n          values.push.apply(values, value); // push all elements\n        }\n\n        key = jsonKeys[i++];\n      } while (key !== undefined);\n    } else if (value.toArray !== undefined) {\n      // ...assume THREE.Math-ish\n\n      do {\n        value = key[valuePropertyName];\n        if (value !== undefined) {\n          times.push(key.time);\n          value.toArray(values, values.length);\n        }\n        key = jsonKeys[i++];\n      } while (key !== undefined);\n    } else {\n      // otherwise push as-is\n\n      do {\n        value = key[valuePropertyName];\n        if (value !== undefined) {\n          times.push(key.time);\n          values.push(value);\n        }\n        key = jsonKeys[i++];\n      } while (key !== undefined);\n    }\n  },\n  subclip: function (sourceClip, name, startFrame, endFrame, fps = 30) {\n    const clip = sourceClip.clone();\n    clip.name = name;\n    const tracks = [];\n    for (let i = 0; i < clip.tracks.length; ++i) {\n      const track = clip.tracks[i];\n      const valueSize = track.getValueSize();\n      const times = [];\n      const values = [];\n      for (let j = 0; j < track.times.length; ++j) {\n        const frame = track.times[j] * fps;\n        if (frame < startFrame || frame >= endFrame) continue;\n        times.push(track.times[j]);\n        for (let k = 0; k < valueSize; ++k) {\n          values.push(track.values[j * valueSize + k]);\n        }\n      }\n      if (times.length === 0) continue;\n      track.times = AnimationUtils.convertArray(times, track.times.constructor);\n      track.values = AnimationUtils.convertArray(values, track.values.constructor);\n      tracks.push(track);\n    }\n    clip.tracks = tracks;\n\n    // find minimum .times value across all tracks in the trimmed clip\n\n    let minStartTime = Infinity;\n    for (let i = 0; i < clip.tracks.length; ++i) {\n      if (minStartTime > clip.tracks[i].times[0]) {\n        minStartTime = clip.tracks[i].times[0];\n      }\n    }\n\n    // shift all tracks such that clip begins at t=0\n\n    for (let i = 0; i < clip.tracks.length; ++i) {\n      clip.tracks[i].shift(-1 * minStartTime);\n    }\n    clip.resetDuration();\n    return clip;\n  },\n  makeClipAdditive: function (targetClip, referenceFrame = 0, referenceClip = targetClip, fps = 30) {\n    if (fps <= 0) fps = 30;\n    const numTracks = referenceClip.tracks.length;\n    const referenceTime = referenceFrame / fps;\n\n    // Make each track's values relative to the values at the reference frame\n    for (let i = 0; i < numTracks; ++i) {\n      const referenceTrack = referenceClip.tracks[i];\n      const referenceTrackType = referenceTrack.ValueTypeName;\n\n      // Skip this track if it's non-numeric\n      if (referenceTrackType === 'bool' || referenceTrackType === 'string') continue;\n\n      // Find the track in the target clip whose name and type matches the reference track\n      const targetTrack = targetClip.tracks.find(function (track) {\n        return track.name === referenceTrack.name && track.ValueTypeName === referenceTrackType;\n      });\n      if (targetTrack === undefined) continue;\n      let referenceOffset = 0;\n      const referenceValueSize = referenceTrack.getValueSize();\n      if (referenceTrack.createInterpolant.isInterpolantFactoryMethodGLTFCubicSpline) {\n        referenceOffset = referenceValueSize / 3;\n      }\n      let targetOffset = 0;\n      const targetValueSize = targetTrack.getValueSize();\n      if (targetTrack.createInterpolant.isInterpolantFactoryMethodGLTFCubicSpline) {\n        targetOffset = targetValueSize / 3;\n      }\n      const lastIndex = referenceTrack.times.length - 1;\n      let referenceValue;\n\n      // Find the value to subtract out of the track\n      if (referenceTime <= referenceTrack.times[0]) {\n        // Reference frame is earlier than the first keyframe, so just use the first keyframe\n        const startIndex = referenceOffset;\n        const endIndex = referenceValueSize - referenceOffset;\n        referenceValue = AnimationUtils.arraySlice(referenceTrack.values, startIndex, endIndex);\n      } else if (referenceTime >= referenceTrack.times[lastIndex]) {\n        // Reference frame is after the last keyframe, so just use the last keyframe\n        const startIndex = lastIndex * referenceValueSize + referenceOffset;\n        const endIndex = startIndex + referenceValueSize - referenceOffset;\n        referenceValue = AnimationUtils.arraySlice(referenceTrack.values, startIndex, endIndex);\n      } else {\n        // Interpolate to the reference value\n        const interpolant = referenceTrack.createInterpolant();\n        const startIndex = referenceOffset;\n        const endIndex = referenceValueSize - referenceOffset;\n        interpolant.evaluate(referenceTime);\n        referenceValue = AnimationUtils.arraySlice(interpolant.resultBuffer, startIndex, endIndex);\n      }\n\n      // Conjugate the quaternion\n      if (referenceTrackType === 'quaternion') {\n        const referenceQuat = new Quaternion().fromArray(referenceValue).normalize().conjugate();\n        referenceQuat.toArray(referenceValue);\n      }\n\n      // Subtract the reference value from all of the track values\n\n      const numTimes = targetTrack.times.length;\n      for (let j = 0; j < numTimes; ++j) {\n        const valueStart = j * targetValueSize + targetOffset;\n        if (referenceTrackType === 'quaternion') {\n          // Multiply the conjugate for quaternion track types\n          Quaternion.multiplyQuaternionsFlat(targetTrack.values, valueStart, referenceValue, 0, targetTrack.values, valueStart);\n        } else {\n          const valueEnd = targetValueSize - targetOffset * 2;\n\n          // Subtract each value for all other numeric track types\n          for (let k = 0; k < valueEnd; ++k) {\n            targetTrack.values[valueStart + k] -= referenceValue[k];\n          }\n        }\n      }\n    }\n    targetClip.blendMode = AdditiveAnimationBlendMode;\n    return targetClip;\n  }\n};\n\n/**\n * Abstract base class of interpolants over parametric samples.\n *\n * The parameter domain is one dimensional, typically the time or a path\n * along a curve defined by the data.\n *\n * The sample values can have any dimensionality and derived classes may\n * apply special interpretations to the data.\n *\n * This class provides the interval seek in a Template Method, deferring\n * the actual interpolation to derived classes.\n *\n * Time complexity is O(1) for linear access crossing at most two points\n * and O(log N) for random access, where N is the number of positions.\n *\n * References:\n *\n * \t\thttp://www.oodesign.com/template-method-pattern.html\n *\n */\n\nfunction Interpolant(parameterPositions, sampleValues, sampleSize, resultBuffer) {\n  this.parameterPositions = parameterPositions;\n  this._cachedIndex = 0;\n  this.resultBuffer = resultBuffer !== undefined ? resultBuffer : new sampleValues.constructor(sampleSize);\n  this.sampleValues = sampleValues;\n  this.valueSize = sampleSize;\n}\n_extends__default['default'](Interpolant.prototype, {\n  evaluate: function (t) {\n    const pp = this.parameterPositions;\n    let i1 = this._cachedIndex,\n      t1 = pp[i1],\n      t0 = pp[i1 - 1];\n    validate_interval: {\n      seek: {\n        let right;\n        linear_scan: {\n          //- See http://jsperf.com/comparison-to-undefined/3\n          //- slower code:\n          //-\n          //- \t\t\t\tif ( t >= t1 || t1 === undefined ) {\n          forward_scan: if (!(t < t1)) {\n            for (let giveUpAt = i1 + 2;;) {\n              if (t1 === undefined) {\n                if (t < t0) break forward_scan;\n\n                // after end\n\n                i1 = pp.length;\n                this._cachedIndex = i1;\n                return this.afterEnd_(i1 - 1, t, t0);\n              }\n              if (i1 === giveUpAt) break; // this loop\n\n              t0 = t1;\n              t1 = pp[++i1];\n              if (t < t1) {\n                // we have arrived at the sought interval\n                break seek;\n              }\n            }\n\n            // prepare binary search on the right side of the index\n            right = pp.length;\n            break linear_scan;\n          }\n\n          //- slower code:\n          //-\t\t\t\t\tif ( t < t0 || t0 === undefined ) {\n          if (!(t >= t0)) {\n            // looping?\n\n            const t1global = pp[1];\n            if (t < t1global) {\n              i1 = 2; // + 1, using the scan for the details\n              t0 = t1global;\n            }\n\n            // linear reverse scan\n\n            for (let giveUpAt = i1 - 2;;) {\n              if (t0 === undefined) {\n                // before start\n\n                this._cachedIndex = 0;\n                return this.beforeStart_(0, t, t1);\n              }\n              if (i1 === giveUpAt) break; // this loop\n\n              t1 = t0;\n              t0 = pp[--i1 - 1];\n              if (t >= t0) {\n                // we have arrived at the sought interval\n                break seek;\n              }\n            }\n\n            // prepare binary search on the left side of the index\n            right = i1;\n            i1 = 0;\n            break linear_scan;\n          }\n\n          // the interval is valid\n\n          break validate_interval;\n        } // linear scan\n\n        // binary search\n\n        while (i1 < right) {\n          const mid = i1 + right >>> 1;\n          if (t < pp[mid]) {\n            right = mid;\n          } else {\n            i1 = mid + 1;\n          }\n        }\n        t1 = pp[i1];\n        t0 = pp[i1 - 1];\n\n        // check boundary cases, again\n\n        if (t0 === undefined) {\n          this._cachedIndex = 0;\n          return this.beforeStart_(0, t, t1);\n        }\n        if (t1 === undefined) {\n          i1 = pp.length;\n          this._cachedIndex = i1;\n          return this.afterEnd_(i1 - 1, t0, t);\n        }\n      } // seek\n\n      this._cachedIndex = i1;\n      this.intervalChanged_(i1, t0, t1);\n    } // validate_interval\n\n    return this.interpolate_(i1, t0, t, t1);\n  },\n  settings: null,\n  // optional, subclass-specific settings structure\n  // Note: The indirection allows central control of many interpolants.\n\n  // --- Protected interface\n\n  DefaultSettings_: {},\n  getSettings_: function () {\n    return this.settings || this.DefaultSettings_;\n  },\n  copySampleValue_: function (index) {\n    // copies a sample value to the result buffer\n\n    const result = this.resultBuffer,\n      values = this.sampleValues,\n      stride = this.valueSize,\n      offset = index * stride;\n    for (let i = 0; i !== stride; ++i) {\n      result[i] = values[offset + i];\n    }\n    return result;\n  },\n  // Template methods for derived classes:\n\n  interpolate_: function /* i1, t0, t, t1 */\n  () {\n    throw new Error('call to abstract method');\n    // implementations shall return this.resultBuffer\n  },\n\n  intervalChanged_: function /* i1, t0, t1 */\n  () {\n\n    // empty\n  }\n});\n\n// DECLARE ALIAS AFTER assign prototype\n_extends__default['default'](Interpolant.prototype, {\n  //( 0, t, t0 ), returns this.resultBuffer\n  beforeStart_: Interpolant.prototype.copySampleValue_,\n  //( N-1, tN-1, t ), returns this.resultBuffer\n  afterEnd_: Interpolant.prototype.copySampleValue_\n});\n\n/**\n * Fast and simple cubic spline interpolant.\n *\n * It was derived from a Hermitian construction setting the first derivative\n * at each sample position to the linear slope between neighboring positions\n * over their parameter interval.\n */\n\nfunction CubicInterpolant(parameterPositions, sampleValues, sampleSize, resultBuffer) {\n  Interpolant.call(this, parameterPositions, sampleValues, sampleSize, resultBuffer);\n  this._weightPrev = -0;\n  this._offsetPrev = -0;\n  this._weightNext = -0;\n  this._offsetNext = -0;\n}\nCubicInterpolant.prototype = _extends__default['default'](Object.create(Interpolant.prototype), {\n  constructor: CubicInterpolant,\n  DefaultSettings_: {\n    endingStart: ZeroCurvatureEnding,\n    endingEnd: ZeroCurvatureEnding\n  },\n  intervalChanged_: function (i1, t0, t1) {\n    const pp = this.parameterPositions;\n    let iPrev = i1 - 2,\n      iNext = i1 + 1,\n      tPrev = pp[iPrev],\n      tNext = pp[iNext];\n    if (tPrev === undefined) {\n      switch (this.getSettings_().endingStart) {\n        case ZeroSlopeEnding:\n          // f'(t0) = 0\n          iPrev = i1;\n          tPrev = 2 * t0 - t1;\n          break;\n        case WrapAroundEnding:\n          // use the other end of the curve\n          iPrev = pp.length - 2;\n          tPrev = t0 + pp[iPrev] - pp[iPrev + 1];\n          break;\n        default:\n          // ZeroCurvatureEnding\n\n          // f''(t0) = 0 a.k.a. Natural Spline\n          iPrev = i1;\n          tPrev = t1;\n      }\n    }\n    if (tNext === undefined) {\n      switch (this.getSettings_().endingEnd) {\n        case ZeroSlopeEnding:\n          // f'(tN) = 0\n          iNext = i1;\n          tNext = 2 * t1 - t0;\n          break;\n        case WrapAroundEnding:\n          // use the other end of the curve\n          iNext = 1;\n          tNext = t1 + pp[1] - pp[0];\n          break;\n        default:\n          // ZeroCurvatureEnding\n\n          // f''(tN) = 0, a.k.a. Natural Spline\n          iNext = i1 - 1;\n          tNext = t0;\n      }\n    }\n    const halfDt = (t1 - t0) * 0.5,\n      stride = this.valueSize;\n    this._weightPrev = halfDt / (t0 - tPrev);\n    this._weightNext = halfDt / (tNext - t1);\n    this._offsetPrev = iPrev * stride;\n    this._offsetNext = iNext * stride;\n  },\n  interpolate_: function (i1, t0, t, t1) {\n    const result = this.resultBuffer,\n      values = this.sampleValues,\n      stride = this.valueSize,\n      o1 = i1 * stride,\n      o0 = o1 - stride,\n      oP = this._offsetPrev,\n      oN = this._offsetNext,\n      wP = this._weightPrev,\n      wN = this._weightNext,\n      p = (t - t0) / (t1 - t0),\n      pp = p * p,\n      ppp = pp * p;\n\n    // evaluate polynomials\n\n    const sP = -wP * ppp + 2 * wP * pp - wP * p;\n    const s0 = (1 + wP) * ppp + (-1.5 - 2 * wP) * pp + (-0.5 + wP) * p + 1;\n    const s1 = (-1 - wN) * ppp + (1.5 + wN) * pp + 0.5 * p;\n    const sN = wN * ppp - wN * pp;\n\n    // combine data linearly\n\n    for (let i = 0; i !== stride; ++i) {\n      result[i] = sP * values[oP + i] + s0 * values[o0 + i] + s1 * values[o1 + i] + sN * values[oN + i];\n    }\n    return result;\n  }\n});\nfunction LinearInterpolant(parameterPositions, sampleValues, sampleSize, resultBuffer) {\n  Interpolant.call(this, parameterPositions, sampleValues, sampleSize, resultBuffer);\n}\nLinearInterpolant.prototype = _extends__default['default'](Object.create(Interpolant.prototype), {\n  constructor: LinearInterpolant,\n  interpolate_: function (i1, t0, t, t1) {\n    const result = this.resultBuffer,\n      values = this.sampleValues,\n      stride = this.valueSize,\n      offset1 = i1 * stride,\n      offset0 = offset1 - stride,\n      weight1 = (t - t0) / (t1 - t0),\n      weight0 = 1 - weight1;\n    for (let i = 0; i !== stride; ++i) {\n      result[i] = values[offset0 + i] * weight0 + values[offset1 + i] * weight1;\n    }\n    return result;\n  }\n});\n\n/**\n *\n * Interpolant that evaluates to the sample value at the position preceeding\n * the parameter.\n */\n\nfunction DiscreteInterpolant(parameterPositions, sampleValues, sampleSize, resultBuffer) {\n  Interpolant.call(this, parameterPositions, sampleValues, sampleSize, resultBuffer);\n}\nDiscreteInterpolant.prototype = _extends__default['default'](Object.create(Interpolant.prototype), {\n  constructor: DiscreteInterpolant,\n  interpolate_: function (i1 /*, t0, t, t1 */) {\n    return this.copySampleValue_(i1 - 1);\n  }\n});\nfunction KeyframeTrack(name, times, values, interpolation) {\n  if (name === undefined) throw new Error('THREE.KeyframeTrack: track name is undefined');\n  if (times === undefined || times.length === 0) throw new Error('THREE.KeyframeTrack: no keyframes in track named ' + name);\n  this.name = name;\n  this.times = AnimationUtils.convertArray(times, this.TimeBufferType);\n  this.values = AnimationUtils.convertArray(values, this.ValueBufferType);\n  this.setInterpolation(interpolation || this.DefaultInterpolation);\n}\n\n// Static methods\n\n_extends__default['default'](KeyframeTrack, {\n  // Serialization (in static context, because of constructor invocation\n  // and automatic invocation of .toJSON):\n\n  toJSON: function (track) {\n    const trackType = track.constructor;\n    let json;\n\n    // derived classes can define a static toJSON method\n    if (trackType.toJSON !== undefined) {\n      json = trackType.toJSON(track);\n    } else {\n      // by default, we assume the data can be serialized as-is\n      json = {\n        'name': track.name,\n        'times': AnimationUtils.convertArray(track.times, Array),\n        'values': AnimationUtils.convertArray(track.values, Array)\n      };\n      const interpolation = track.getInterpolation();\n      if (interpolation !== track.DefaultInterpolation) {\n        json.interpolation = interpolation;\n      }\n    }\n    json.type = track.ValueTypeName; // mandatory\n\n    return json;\n  }\n});\n_extends__default['default'](KeyframeTrack.prototype, {\n  constructor: KeyframeTrack,\n  TimeBufferType: Float32Array,\n  ValueBufferType: Float32Array,\n  DefaultInterpolation: InterpolateLinear,\n  InterpolantFactoryMethodDiscrete: function (result) {\n    return new DiscreteInterpolant(this.times, this.values, this.getValueSize(), result);\n  },\n  InterpolantFactoryMethodLinear: function (result) {\n    return new LinearInterpolant(this.times, this.values, this.getValueSize(), result);\n  },\n  InterpolantFactoryMethodSmooth: function (result) {\n    return new CubicInterpolant(this.times, this.values, this.getValueSize(), result);\n  },\n  setInterpolation: function (interpolation) {\n    let factoryMethod;\n    switch (interpolation) {\n      case InterpolateDiscrete:\n        factoryMethod = this.InterpolantFactoryMethodDiscrete;\n        break;\n      case InterpolateLinear:\n        factoryMethod = this.InterpolantFactoryMethodLinear;\n        break;\n      case InterpolateSmooth:\n        factoryMethod = this.InterpolantFactoryMethodSmooth;\n        break;\n    }\n    if (factoryMethod === undefined) {\n      const message = 'unsupported interpolation for ' + this.ValueTypeName + ' keyframe track named ' + this.name;\n      if (this.createInterpolant === undefined) {\n        // fall back to default, unless the default itself is messed up\n        if (interpolation !== this.DefaultInterpolation) {\n          this.setInterpolation(this.DefaultInterpolation);\n        } else {\n          throw new Error(message); // fatal, in this case\n        }\n      }\n\n      console.warn('THREE.KeyframeTrack:', message);\n      return this;\n    }\n    this.createInterpolant = factoryMethod;\n    return this;\n  },\n  getInterpolation: function () {\n    switch (this.createInterpolant) {\n      case this.InterpolantFactoryMethodDiscrete:\n        return InterpolateDiscrete;\n      case this.InterpolantFactoryMethodLinear:\n        return InterpolateLinear;\n      case this.InterpolantFactoryMethodSmooth:\n        return InterpolateSmooth;\n    }\n  },\n  getValueSize: function () {\n    return this.values.length / this.times.length;\n  },\n  // move all keyframes either forwards or backwards in time\n  shift: function (timeOffset) {\n    if (timeOffset !== 0.0) {\n      const times = this.times;\n      for (let i = 0, n = times.length; i !== n; ++i) {\n        times[i] += timeOffset;\n      }\n    }\n    return this;\n  },\n  // scale all keyframe times by a factor (useful for frame <-> seconds conversions)\n  scale: function (timeScale) {\n    if (timeScale !== 1.0) {\n      const times = this.times;\n      for (let i = 0, n = times.length; i !== n; ++i) {\n        times[i] *= timeScale;\n      }\n    }\n    return this;\n  },\n  // removes keyframes before and after animation without changing any values within the range [startTime, endTime].\n  // IMPORTANT: We do not shift around keys to the start of the track time, because for interpolated keys this will change their values\n  trim: function (startTime, endTime) {\n    const times = this.times,\n      nKeys = times.length;\n    let from = 0,\n      to = nKeys - 1;\n    while (from !== nKeys && times[from] < startTime) {\n      ++from;\n    }\n    while (to !== -1 && times[to] > endTime) {\n      --to;\n    }\n    ++to; // inclusive -> exclusive bound\n\n    if (from !== 0 || to !== nKeys) {\n      // empty tracks are forbidden, so keep at least one keyframe\n      if (from >= to) {\n        to = Math.max(to, 1);\n        from = to - 1;\n      }\n      const stride = this.getValueSize();\n      this.times = AnimationUtils.arraySlice(times, from, to);\n      this.values = AnimationUtils.arraySlice(this.values, from * stride, to * stride);\n    }\n    return this;\n  },\n  // ensure we do not get a GarbageInGarbageOut situation, make sure tracks are at least minimally viable\n  validate: function () {\n    let valid = true;\n    const valueSize = this.getValueSize();\n    if (valueSize - Math.floor(valueSize) !== 0) {\n      console.error('THREE.KeyframeTrack: Invalid value size in track.', this);\n      valid = false;\n    }\n    const times = this.times,\n      values = this.values,\n      nKeys = times.length;\n    if (nKeys === 0) {\n      console.error('THREE.KeyframeTrack: Track is empty.', this);\n      valid = false;\n    }\n    let prevTime = null;\n    for (let i = 0; i !== nKeys; i++) {\n      const currTime = times[i];\n      if (typeof currTime === 'number' && isNaN(currTime)) {\n        console.error('THREE.KeyframeTrack: Time is not a valid number.', this, i, currTime);\n        valid = false;\n        break;\n      }\n      if (prevTime !== null && prevTime > currTime) {\n        console.error('THREE.KeyframeTrack: Out of order keys.', this, i, currTime, prevTime);\n        valid = false;\n        break;\n      }\n      prevTime = currTime;\n    }\n    if (values !== undefined) {\n      if (AnimationUtils.isTypedArray(values)) {\n        for (let i = 0, n = values.length; i !== n; ++i) {\n          const value = values[i];\n          if (isNaN(value)) {\n            console.error('THREE.KeyframeTrack: Value is not a valid number.', this, i, value);\n            valid = false;\n            break;\n          }\n        }\n      }\n    }\n    return valid;\n  },\n  // removes equivalent sequential keys as common in morph target sequences\n  // (0,0,0,0,1,1,1,0,0,0,0,0,0,0) --> (0,0,1,1,0,0)\n  optimize: function () {\n    // times or values may be shared with other tracks, so overwriting is unsafe\n    const times = AnimationUtils.arraySlice(this.times),\n      values = AnimationUtils.arraySlice(this.values),\n      stride = this.getValueSize(),\n      smoothInterpolation = this.getInterpolation() === InterpolateSmooth,\n      lastIndex = times.length - 1;\n    let writeIndex = 1;\n    for (let i = 1; i < lastIndex; ++i) {\n      let keep = false;\n      const time = times[i];\n      const timeNext = times[i + 1];\n\n      // remove adjacent keyframes scheduled at the same time\n\n      if (time !== timeNext && (i !== 1 || time !== times[0])) {\n        if (!smoothInterpolation) {\n          // remove unnecessary keyframes same as their neighbors\n\n          const offset = i * stride,\n            offsetP = offset - stride,\n            offsetN = offset + stride;\n          for (let j = 0; j !== stride; ++j) {\n            const value = values[offset + j];\n            if (value !== values[offsetP + j] || value !== values[offsetN + j]) {\n              keep = true;\n              break;\n            }\n          }\n        } else {\n          keep = true;\n        }\n      }\n\n      // in-place compaction\n\n      if (keep) {\n        if (i !== writeIndex) {\n          times[writeIndex] = times[i];\n          const readOffset = i * stride,\n            writeOffset = writeIndex * stride;\n          for (let j = 0; j !== stride; ++j) {\n            values[writeOffset + j] = values[readOffset + j];\n          }\n        }\n        ++writeIndex;\n      }\n    }\n\n    // flush last keyframe (compaction looks ahead)\n\n    if (lastIndex > 0) {\n      times[writeIndex] = times[lastIndex];\n      for (let readOffset = lastIndex * stride, writeOffset = writeIndex * stride, j = 0; j !== stride; ++j) {\n        values[writeOffset + j] = values[readOffset + j];\n      }\n      ++writeIndex;\n    }\n    if (writeIndex !== times.length) {\n      this.times = AnimationUtils.arraySlice(times, 0, writeIndex);\n      this.values = AnimationUtils.arraySlice(values, 0, writeIndex * stride);\n    } else {\n      this.times = times;\n      this.values = values;\n    }\n    return this;\n  },\n  clone: function () {\n    const times = AnimationUtils.arraySlice(this.times, 0);\n    const values = AnimationUtils.arraySlice(this.values, 0);\n    const TypedKeyframeTrack = this.constructor;\n    const track = new TypedKeyframeTrack(this.name, times, values);\n\n    // Interpolant argument to constructor is not saved, so copy the factory method directly.\n    track.createInterpolant = this.createInterpolant;\n    return track;\n  }\n});\n\n/**\n * A Track of Boolean keyframe values.\n */\n\nfunction BooleanKeyframeTrack(name, times, values) {\n  KeyframeTrack.call(this, name, times, values);\n}\nBooleanKeyframeTrack.prototype = _extends__default['default'](Object.create(KeyframeTrack.prototype), {\n  constructor: BooleanKeyframeTrack,\n  ValueTypeName: 'bool',\n  ValueBufferType: Array,\n  DefaultInterpolation: InterpolateDiscrete,\n  InterpolantFactoryMethodLinear: undefined,\n  InterpolantFactoryMethodSmooth: undefined\n\n  // Note: Actually this track could have a optimized / compressed\n  // representation of a single value and a custom interpolant that\n  // computes \"firstValue ^ isOdd( index )\".\n});\n\n/**\n * A Track of keyframe values that represent color.\n */\n\nfunction ColorKeyframeTrack(name, times, values, interpolation) {\n  KeyframeTrack.call(this, name, times, values, interpolation);\n}\nColorKeyframeTrack.prototype = _extends__default['default'](Object.create(KeyframeTrack.prototype), {\n  constructor: ColorKeyframeTrack,\n  ValueTypeName: 'color'\n\n  // ValueBufferType is inherited\n\n  // DefaultInterpolation is inherited\n\n  // Note: Very basic implementation and nothing special yet.\n  // However, this is the place for color space parameterization.\n});\n\n/**\n * A Track of numeric keyframe values.\n */\n\nfunction NumberKeyframeTrack(name, times, values, interpolation) {\n  KeyframeTrack.call(this, name, times, values, interpolation);\n}\nNumberKeyframeTrack.prototype = _extends__default['default'](Object.create(KeyframeTrack.prototype), {\n  constructor: NumberKeyframeTrack,\n  ValueTypeName: 'number'\n\n  // ValueBufferType is inherited\n\n  // DefaultInterpolation is inherited\n});\n\n/**\n * Spherical linear unit quaternion interpolant.\n */\n\nfunction QuaternionLinearInterpolant(parameterPositions, sampleValues, sampleSize, resultBuffer) {\n  Interpolant.call(this, parameterPositions, sampleValues, sampleSize, resultBuffer);\n}\nQuaternionLinearInterpolant.prototype = _extends__default['default'](Object.create(Interpolant.prototype), {\n  constructor: QuaternionLinearInterpolant,\n  interpolate_: function (i1, t0, t, t1) {\n    const result = this.resultBuffer,\n      values = this.sampleValues,\n      stride = this.valueSize,\n      alpha = (t - t0) / (t1 - t0);\n    let offset = i1 * stride;\n    for (let end = offset + stride; offset !== end; offset += 4) {\n      Quaternion.slerpFlat(result, 0, values, offset - stride, values, offset, alpha);\n    }\n    return result;\n  }\n});\n\n/**\n * A Track of quaternion keyframe values.\n */\n\nfunction QuaternionKeyframeTrack(name, times, values, interpolation) {\n  KeyframeTrack.call(this, name, times, values, interpolation);\n}\nQuaternionKeyframeTrack.prototype = _extends__default['default'](Object.create(KeyframeTrack.prototype), {\n  constructor: QuaternionKeyframeTrack,\n  ValueTypeName: 'quaternion',\n  // ValueBufferType is inherited\n\n  DefaultInterpolation: InterpolateLinear,\n  InterpolantFactoryMethodLinear: function (result) {\n    return new QuaternionLinearInterpolant(this.times, this.values, this.getValueSize(), result);\n  },\n  InterpolantFactoryMethodSmooth: undefined // not yet implemented\n});\n\n/**\n * A Track that interpolates Strings\n */\n\nfunction StringKeyframeTrack(name, times, values, interpolation) {\n  KeyframeTrack.call(this, name, times, values, interpolation);\n}\nStringKeyframeTrack.prototype = _extends__default['default'](Object.create(KeyframeTrack.prototype), {\n  constructor: StringKeyframeTrack,\n  ValueTypeName: 'string',\n  ValueBufferType: Array,\n  DefaultInterpolation: InterpolateDiscrete,\n  InterpolantFactoryMethodLinear: undefined,\n  InterpolantFactoryMethodSmooth: undefined\n});\n\n/**\n * A Track of vectored keyframe values.\n */\n\nfunction VectorKeyframeTrack(name, times, values, interpolation) {\n  KeyframeTrack.call(this, name, times, values, interpolation);\n}\nVectorKeyframeTrack.prototype = _extends__default['default'](Object.create(KeyframeTrack.prototype), {\n  constructor: VectorKeyframeTrack,\n  ValueTypeName: 'vector'\n\n  // ValueBufferType is inherited\n\n  // DefaultInterpolation is inherited\n});\n\nfunction AnimationClip(name, duration = -1, tracks, blendMode = NormalAnimationBlendMode) {\n  this.name = name;\n  this.tracks = tracks;\n  this.duration = duration;\n  this.blendMode = blendMode;\n  this.uuid = MathUtils.generateUUID();\n\n  // this means it should figure out its duration by scanning the tracks\n  if (this.duration < 0) {\n    this.resetDuration();\n  }\n}\nfunction getTrackTypeForValueTypeName(typeName) {\n  switch (typeName.toLowerCase()) {\n    case 'scalar':\n    case 'double':\n    case 'float':\n    case 'number':\n    case 'integer':\n      return NumberKeyframeTrack;\n    case 'vector':\n    case 'vector2':\n    case 'vector3':\n    case 'vector4':\n      return VectorKeyframeTrack;\n    case 'color':\n      return ColorKeyframeTrack;\n    case 'quaternion':\n      return QuaternionKeyframeTrack;\n    case 'bool':\n    case 'boolean':\n      return BooleanKeyframeTrack;\n    case 'string':\n      return StringKeyframeTrack;\n  }\n  throw new Error('THREE.KeyframeTrack: Unsupported typeName: ' + typeName);\n}\nfunction parseKeyframeTrack(json) {\n  if (json.type === undefined) {\n    throw new Error('THREE.KeyframeTrack: track type undefined, can not parse');\n  }\n  const trackType = getTrackTypeForValueTypeName(json.type);\n  if (json.times === undefined) {\n    const times = [],\n      values = [];\n    AnimationUtils.flattenJSON(json.keys, times, values, 'value');\n    json.times = times;\n    json.values = values;\n  }\n\n  // derived classes can define a static parse method\n  if (trackType.parse !== undefined) {\n    return trackType.parse(json);\n  } else {\n    // by default, we assume a constructor compatible with the base\n    return new trackType(json.name, json.times, json.values, json.interpolation);\n  }\n}\n_extends__default['default'](AnimationClip, {\n  parse: function (json) {\n    const tracks = [],\n      jsonTracks = json.tracks,\n      frameTime = 1.0 / (json.fps || 1.0);\n    for (let i = 0, n = jsonTracks.length; i !== n; ++i) {\n      tracks.push(parseKeyframeTrack(jsonTracks[i]).scale(frameTime));\n    }\n    const clip = new AnimationClip(json.name, json.duration, tracks, json.blendMode);\n    clip.uuid = json.uuid;\n    return clip;\n  },\n  toJSON: function (clip) {\n    const tracks = [],\n      clipTracks = clip.tracks;\n    const json = {\n      'name': clip.name,\n      'duration': clip.duration,\n      'tracks': tracks,\n      'uuid': clip.uuid,\n      'blendMode': clip.blendMode\n    };\n    for (let i = 0, n = clipTracks.length; i !== n; ++i) {\n      tracks.push(KeyframeTrack.toJSON(clipTracks[i]));\n    }\n    return json;\n  },\n  CreateFromMorphTargetSequence: function (name, morphTargetSequence, fps, noLoop) {\n    const numMorphTargets = morphTargetSequence.length;\n    const tracks = [];\n    for (let i = 0; i < numMorphTargets; i++) {\n      let times = [];\n      let values = [];\n      times.push((i + numMorphTargets - 1) % numMorphTargets, i, (i + 1) % numMorphTargets);\n      values.push(0, 1, 0);\n      const order = AnimationUtils.getKeyframeOrder(times);\n      times = AnimationUtils.sortedArray(times, 1, order);\n      values = AnimationUtils.sortedArray(values, 1, order);\n\n      // if there is a key at the first frame, duplicate it as the\n      // last frame as well for perfect loop.\n      if (!noLoop && times[0] === 0) {\n        times.push(numMorphTargets);\n        values.push(values[0]);\n      }\n      tracks.push(new NumberKeyframeTrack('.morphTargetInfluences[' + morphTargetSequence[i].name + ']', times, values).scale(1.0 / fps));\n    }\n    return new AnimationClip(name, -1, tracks);\n  },\n  findByName: function (objectOrClipArray, name) {\n    let clipArray = objectOrClipArray;\n    if (!Array.isArray(objectOrClipArray)) {\n      const o = objectOrClipArray;\n      clipArray = o.geometry && o.geometry.animations || o.animations;\n    }\n    for (let i = 0; i < clipArray.length; i++) {\n      if (clipArray[i].name === name) {\n        return clipArray[i];\n      }\n    }\n    return null;\n  },\n  CreateClipsFromMorphTargetSequences: function (morphTargets, fps, noLoop) {\n    const animationToMorphTargets = {};\n\n    // tested with https://regex101.com/ on trick sequences\n    // such flamingo_flyA_003, flamingo_run1_003, crdeath0059\n    const pattern = /^([\\w-]*?)([\\d]+)$/;\n\n    // sort morph target names into animation groups based\n    // patterns like Walk_001, Walk_002, Run_001, Run_002\n    for (let i = 0, il = morphTargets.length; i < il; i++) {\n      const morphTarget = morphTargets[i];\n      const parts = morphTarget.name.match(pattern);\n      if (parts && parts.length > 1) {\n        const name = parts[1];\n        let animationMorphTargets = animationToMorphTargets[name];\n        if (!animationMorphTargets) {\n          animationToMorphTargets[name] = animationMorphTargets = [];\n        }\n        animationMorphTargets.push(morphTarget);\n      }\n    }\n    const clips = [];\n    for (const name in animationToMorphTargets) {\n      clips.push(AnimationClip.CreateFromMorphTargetSequence(name, animationToMorphTargets[name], fps, noLoop));\n    }\n    return clips;\n  },\n  // parse the animation.hierarchy format\n  parseAnimation: function (animation, bones) {\n    if (!animation) {\n      console.error('THREE.AnimationClip: No animation in JSONLoader data.');\n      return null;\n    }\n    const addNonemptyTrack = function (trackType, trackName, animationKeys, propertyName, destTracks) {\n      // only return track if there are actually keys.\n      if (animationKeys.length !== 0) {\n        const times = [];\n        const values = [];\n        AnimationUtils.flattenJSON(animationKeys, times, values, propertyName);\n\n        // empty keys are filtered out, so check again\n        if (times.length !== 0) {\n          destTracks.push(new trackType(trackName, times, values));\n        }\n      }\n    };\n    const tracks = [];\n    const clipName = animation.name || 'default';\n    const fps = animation.fps || 30;\n    const blendMode = animation.blendMode;\n\n    // automatic length determination in AnimationClip.\n    let duration = animation.length || -1;\n    const hierarchyTracks = animation.hierarchy || [];\n    for (let h = 0; h < hierarchyTracks.length; h++) {\n      const animationKeys = hierarchyTracks[h].keys;\n\n      // skip empty tracks\n      if (!animationKeys || animationKeys.length === 0) continue;\n\n      // process morph targets\n      if (animationKeys[0].morphTargets) {\n        // figure out all morph targets used in this track\n        const morphTargetNames = {};\n        let k;\n        for (k = 0; k < animationKeys.length; k++) {\n          if (animationKeys[k].morphTargets) {\n            for (let m = 0; m < animationKeys[k].morphTargets.length; m++) {\n              morphTargetNames[animationKeys[k].morphTargets[m]] = -1;\n            }\n          }\n        }\n\n        // create a track for each morph target with all zero\n        // morphTargetInfluences except for the keys in which\n        // the morphTarget is named.\n        for (const morphTargetName in morphTargetNames) {\n          const times = [];\n          const values = [];\n          for (let m = 0; m !== animationKeys[k].morphTargets.length; ++m) {\n            const animationKey = animationKeys[k];\n            times.push(animationKey.time);\n            values.push(animationKey.morphTarget === morphTargetName ? 1 : 0);\n          }\n          tracks.push(new NumberKeyframeTrack('.morphTargetInfluence[' + morphTargetName + ']', times, values));\n        }\n        duration = morphTargetNames.length * (fps || 1.0);\n      } else {\n        // ...assume skeletal animation\n\n        const boneName = '.bones[' + bones[h].name + ']';\n        addNonemptyTrack(VectorKeyframeTrack, boneName + '.position', animationKeys, 'pos', tracks);\n        addNonemptyTrack(QuaternionKeyframeTrack, boneName + '.quaternion', animationKeys, 'rot', tracks);\n        addNonemptyTrack(VectorKeyframeTrack, boneName + '.scale', animationKeys, 'scl', tracks);\n      }\n    }\n    if (tracks.length === 0) {\n      return null;\n    }\n    const clip = new AnimationClip(clipName, duration, tracks, blendMode);\n    return clip;\n  }\n});\n_extends__default['default'](AnimationClip.prototype, {\n  resetDuration: function () {\n    const tracks = this.tracks;\n    let duration = 0;\n    for (let i = 0, n = tracks.length; i !== n; ++i) {\n      const track = this.tracks[i];\n      duration = Math.max(duration, track.times[track.times.length - 1]);\n    }\n    this.duration = duration;\n    return this;\n  },\n  trim: function () {\n    for (let i = 0; i < this.tracks.length; i++) {\n      this.tracks[i].trim(0, this.duration);\n    }\n    return this;\n  },\n  validate: function () {\n    let valid = true;\n    for (let i = 0; i < this.tracks.length; i++) {\n      valid = valid && this.tracks[i].validate();\n    }\n    return valid;\n  },\n  optimize: function () {\n    for (let i = 0; i < this.tracks.length; i++) {\n      this.tracks[i].optimize();\n    }\n    return this;\n  },\n  clone: function () {\n    const tracks = [];\n    for (let i = 0; i < this.tracks.length; i++) {\n      tracks.push(this.tracks[i].clone());\n    }\n    return new AnimationClip(this.name, this.duration, tracks, this.blendMode);\n  },\n  toJSON: function () {\n    return AnimationClip.toJSON(this);\n  }\n});\nconst Cache = {\n  enabled: false,\n  files: {},\n  add: function (key, file) {\n    if (this.enabled === false) return;\n\n    // console.log( 'THREE.Cache', 'Adding key:', key );\n\n    this.files[key] = file;\n  },\n  get: function (key) {\n    if (this.enabled === false) return;\n\n    // console.log( 'THREE.Cache', 'Checking key:', key );\n\n    return this.files[key];\n  },\n  remove: function (key) {\n    delete this.files[key];\n  },\n  clear: function () {\n    this.files = {};\n  }\n};\nfunction LoadingManager(onLoad, onProgress, onError) {\n  const scope = this;\n  let isLoading = false;\n  let itemsLoaded = 0;\n  let itemsTotal = 0;\n  let urlModifier = undefined;\n  const handlers = [];\n\n  // Refer to #5689 for the reason why we don't set .onStart\n  // in the constructor\n\n  this.onStart = undefined;\n  this.onLoad = onLoad;\n  this.onProgress = onProgress;\n  this.onError = onError;\n  this.itemStart = function (url) {\n    itemsTotal++;\n    if (isLoading === false) {\n      if (scope.onStart !== undefined) {\n        scope.onStart(url, itemsLoaded, itemsTotal);\n      }\n    }\n    isLoading = true;\n  };\n  this.itemEnd = function (url) {\n    itemsLoaded++;\n    if (scope.onProgress !== undefined) {\n      scope.onProgress(url, itemsLoaded, itemsTotal);\n    }\n    if (itemsLoaded === itemsTotal) {\n      isLoading = false;\n      if (scope.onLoad !== undefined) {\n        scope.onLoad();\n      }\n    }\n  };\n  this.itemError = function (url) {\n    if (scope.onError !== undefined) {\n      scope.onError(url);\n    }\n  };\n  this.resolveURL = function (url) {\n    if (urlModifier) {\n      return urlModifier(url);\n    }\n    return url;\n  };\n  this.setURLModifier = function (transform) {\n    urlModifier = transform;\n    return this;\n  };\n  this.addHandler = function (regex, loader) {\n    handlers.push(regex, loader);\n    return this;\n  };\n  this.removeHandler = function (regex) {\n    const index = handlers.indexOf(regex);\n    if (index !== -1) {\n      handlers.splice(index, 2);\n    }\n    return this;\n  };\n  this.getHandler = function (file) {\n    for (let i = 0, l = handlers.length; i < l; i += 2) {\n      const regex = handlers[i];\n      const loader = handlers[i + 1];\n      if (regex.global) regex.lastIndex = 0; // see #17920\n\n      if (regex.test(file)) {\n        return loader;\n      }\n    }\n    return null;\n  };\n}\nconst DefaultLoadingManager = new LoadingManager();\nfunction Loader(manager) {\n  this.manager = manager !== undefined ? manager : DefaultLoadingManager;\n  this.crossOrigin = 'anonymous';\n  this.withCredentials = false;\n  this.path = '';\n  this.resourcePath = '';\n  this.requestHeader = {};\n}\n_extends__default['default'](Loader.prototype, {\n  load: function /* url, onLoad, onProgress, onError */ () {},\n  loadAsync: function (url, onProgress) {\n    const scope = this;\n    return new Promise(function (resolve, reject) {\n      scope.load(url, resolve, onProgress, reject);\n    });\n  },\n  parse: function /* data */ () {},\n  setCrossOrigin: function (crossOrigin) {\n    this.crossOrigin = crossOrigin;\n    return this;\n  },\n  setWithCredentials: function (value) {\n    this.withCredentials = value;\n    return this;\n  },\n  setPath: function (path) {\n    this.path = path;\n    return this;\n  },\n  setResourcePath: function (resourcePath) {\n    this.resourcePath = resourcePath;\n    return this;\n  },\n  setRequestHeader: function (requestHeader) {\n    this.requestHeader = requestHeader;\n    return this;\n  }\n});\nconst loading = {};\nfunction FileLoader(manager) {\n  Loader.call(this, manager);\n}\nFileLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: FileLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    if (url === undefined) url = '';\n    if (this.path !== undefined) url = this.path + url;\n    url = this.manager.resolveURL(url);\n    const scope = this;\n    const cached = Cache.get(url);\n    if (cached !== undefined) {\n      scope.manager.itemStart(url);\n      setTimeout(function () {\n        if (onLoad) onLoad(cached);\n        scope.manager.itemEnd(url);\n      }, 0);\n      return cached;\n    }\n\n    // Check if request is duplicate\n\n    if (loading[url] !== undefined) {\n      loading[url].push({\n        onLoad: onLoad,\n        onProgress: onProgress,\n        onError: onError\n      });\n      return;\n    }\n\n    // Check for data: URI\n    const dataUriRegex = /^data:(.*?)(;base64)?,(.*)$/;\n    const dataUriRegexResult = url.match(dataUriRegex);\n    let request;\n\n    // Safari can not handle Data URIs through XMLHttpRequest so process manually\n    if (dataUriRegexResult) {\n      const mimeType = dataUriRegexResult[1];\n      const isBase64 = !!dataUriRegexResult[2];\n      let data = dataUriRegexResult[3];\n      data = decodeURIComponent(data);\n      if (isBase64) data = atob(data);\n      try {\n        let response;\n        const responseType = (this.responseType || '').toLowerCase();\n        switch (responseType) {\n          case 'arraybuffer':\n          case 'blob':\n            const view = new Uint8Array(data.length);\n            for (let i = 0; i < data.length; i++) {\n              view[i] = data.charCodeAt(i);\n            }\n            if (responseType === 'blob') {\n              response = new Blob([view.buffer], {\n                type: mimeType\n              });\n            } else {\n              response = view.buffer;\n            }\n            break;\n          case 'document':\n            const parser = new DOMParser();\n            response = parser.parseFromString(data, mimeType);\n            break;\n          case 'json':\n            response = JSON.parse(data);\n            break;\n          default:\n            // 'text' or other\n\n            response = data;\n            break;\n        }\n\n        // Wait for next browser tick like standard XMLHttpRequest event dispatching does\n        setTimeout(function () {\n          if (onLoad) onLoad(response);\n          scope.manager.itemEnd(url);\n        }, 0);\n      } catch (error) {\n        // Wait for next browser tick like standard XMLHttpRequest event dispatching does\n        setTimeout(function () {\n          if (onError) onError(error);\n          scope.manager.itemError(url);\n          scope.manager.itemEnd(url);\n        }, 0);\n      }\n    } else {\n      // Initialise array for duplicate requests\n\n      loading[url] = [];\n      loading[url].push({\n        onLoad: onLoad,\n        onProgress: onProgress,\n        onError: onError\n      });\n      request = new XMLHttpRequest();\n      request.open('GET', url, true);\n      request.addEventListener('load', function (event) {\n        const response = this.response;\n        const callbacks = loading[url];\n        delete loading[url];\n        if (this.status === 200 || this.status === 0) {\n          // Some browsers return HTTP Status 0 when using non-http protocol\n          // e.g. 'file://' or 'data://'. Handle as success.\n\n          if (this.status === 0) console.warn('THREE.FileLoader: HTTP Status 0 received.');\n\n          // Add to cache only on HTTP success, so that we do not cache\n          // error response bodies as proper responses to requests.\n          Cache.add(url, response);\n          for (let i = 0, il = callbacks.length; i < il; i++) {\n            const callback = callbacks[i];\n            if (callback.onLoad) callback.onLoad(response);\n          }\n          scope.manager.itemEnd(url);\n        } else {\n          for (let i = 0, il = callbacks.length; i < il; i++) {\n            const callback = callbacks[i];\n            if (callback.onError) callback.onError(event);\n          }\n          scope.manager.itemError(url);\n          scope.manager.itemEnd(url);\n        }\n      }, false);\n      request.addEventListener('progress', function (event) {\n        const callbacks = loading[url];\n        for (let i = 0, il = callbacks.length; i < il; i++) {\n          const callback = callbacks[i];\n          if (callback.onProgress) callback.onProgress(event);\n        }\n      }, false);\n      request.addEventListener('error', function (event) {\n        const callbacks = loading[url];\n        delete loading[url];\n        for (let i = 0, il = callbacks.length; i < il; i++) {\n          const callback = callbacks[i];\n          if (callback.onError) callback.onError(event);\n        }\n        scope.manager.itemError(url);\n        scope.manager.itemEnd(url);\n      }, false);\n      request.addEventListener('abort', function (event) {\n        const callbacks = loading[url];\n        delete loading[url];\n        for (let i = 0, il = callbacks.length; i < il; i++) {\n          const callback = callbacks[i];\n          if (callback.onError) callback.onError(event);\n        }\n        scope.manager.itemError(url);\n        scope.manager.itemEnd(url);\n      }, false);\n      if (this.responseType !== undefined) request.responseType = this.responseType;\n      if (this.withCredentials !== undefined) request.withCredentials = this.withCredentials;\n      if (request.overrideMimeType) request.overrideMimeType(this.mimeType !== undefined ? this.mimeType : 'text/plain');\n      for (const header in this.requestHeader) {\n        request.setRequestHeader(header, this.requestHeader[header]);\n      }\n      request.send(null);\n    }\n    scope.manager.itemStart(url);\n    return request;\n  },\n  setResponseType: function (value) {\n    this.responseType = value;\n    return this;\n  },\n  setMimeType: function (value) {\n    this.mimeType = value;\n    return this;\n  }\n});\nfunction AnimationLoader(manager) {\n  Loader.call(this, manager);\n}\nAnimationLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: AnimationLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const scope = this;\n    const loader = new FileLoader(scope.manager);\n    loader.setPath(scope.path);\n    loader.setRequestHeader(scope.requestHeader);\n    loader.setWithCredentials(scope.withCredentials);\n    loader.load(url, function (text) {\n      try {\n        onLoad(scope.parse(JSON.parse(text)));\n      } catch (e) {\n        if (onError) {\n          onError(e);\n        } else {\n          console.error(e);\n        }\n        scope.manager.itemError(url);\n      }\n    }, onProgress, onError);\n  },\n  parse: function (json) {\n    const animations = [];\n    for (let i = 0; i < json.length; i++) {\n      const clip = AnimationClip.parse(json[i]);\n      animations.push(clip);\n    }\n    return animations;\n  }\n});\n\n/**\n * Abstract Base class to block based textures loader (dds, pvr, ...)\n *\n * Sub classes have to implement the parse() method which will be used in load().\n */\n\nfunction CompressedTextureLoader(manager) {\n  Loader.call(this, manager);\n}\nCompressedTextureLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: CompressedTextureLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const scope = this;\n    const images = [];\n    const texture = new CompressedTexture();\n    const loader = new FileLoader(this.manager);\n    loader.setPath(this.path);\n    loader.setResponseType('arraybuffer');\n    loader.setRequestHeader(this.requestHeader);\n    loader.setWithCredentials(scope.withCredentials);\n    let loaded = 0;\n    function loadTexture(i) {\n      loader.load(url[i], function (buffer) {\n        const texDatas = scope.parse(buffer, true);\n        images[i] = {\n          width: texDatas.width,\n          height: texDatas.height,\n          format: texDatas.format,\n          mipmaps: texDatas.mipmaps\n        };\n        loaded += 1;\n        if (loaded === 6) {\n          if (texDatas.mipmapCount === 1) texture.minFilter = LinearFilter;\n          texture.image = images;\n          texture.format = texDatas.format;\n          texture.needsUpdate = true;\n          if (onLoad) onLoad(texture);\n        }\n      }, onProgress, onError);\n    }\n    if (Array.isArray(url)) {\n      for (let i = 0, il = url.length; i < il; ++i) {\n        loadTexture(i);\n      }\n    } else {\n      // compressed cubemap texture stored in a single DDS file\n\n      loader.load(url, function (buffer) {\n        const texDatas = scope.parse(buffer, true);\n        if (texDatas.isCubemap) {\n          const faces = texDatas.mipmaps.length / texDatas.mipmapCount;\n          for (let f = 0; f < faces; f++) {\n            images[f] = {\n              mipmaps: []\n            };\n            for (let i = 0; i < texDatas.mipmapCount; i++) {\n              images[f].mipmaps.push(texDatas.mipmaps[f * texDatas.mipmapCount + i]);\n              images[f].format = texDatas.format;\n              images[f].width = texDatas.width;\n              images[f].height = texDatas.height;\n            }\n          }\n          texture.image = images;\n        } else {\n          texture.image.width = texDatas.width;\n          texture.image.height = texDatas.height;\n          texture.mipmaps = texDatas.mipmaps;\n        }\n        if (texDatas.mipmapCount === 1) {\n          texture.minFilter = LinearFilter;\n        }\n        texture.format = texDatas.format;\n        texture.needsUpdate = true;\n        if (onLoad) onLoad(texture);\n      }, onProgress, onError);\n    }\n    return texture;\n  }\n});\nfunction ImageLoader(manager) {\n  Loader.call(this, manager);\n}\nImageLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: ImageLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    if (this.path !== undefined) url = this.path + url;\n    url = this.manager.resolveURL(url);\n    const scope = this;\n    const cached = Cache.get(url);\n    if (cached !== undefined) {\n      scope.manager.itemStart(url);\n      setTimeout(function () {\n        if (onLoad) onLoad(cached);\n        scope.manager.itemEnd(url);\n      }, 0);\n      return cached;\n    }\n    const image = document.createElementNS('http://www.w3.org/1999/xhtml', 'img');\n    function onImageLoad() {\n      image.removeEventListener('load', onImageLoad, false);\n      image.removeEventListener('error', onImageError, false);\n      Cache.add(url, this);\n      if (onLoad) onLoad(this);\n      scope.manager.itemEnd(url);\n    }\n    function onImageError(event) {\n      image.removeEventListener('load', onImageLoad, false);\n      image.removeEventListener('error', onImageError, false);\n      if (onError) onError(event);\n      scope.manager.itemError(url);\n      scope.manager.itemEnd(url);\n    }\n    image.addEventListener('load', onImageLoad, false);\n    image.addEventListener('error', onImageError, false);\n    if (url.substr(0, 5) !== 'data:') {\n      if (this.crossOrigin !== undefined) image.crossOrigin = this.crossOrigin;\n    }\n    scope.manager.itemStart(url);\n    image.src = url;\n    return image;\n  }\n});\nfunction CubeTextureLoader(manager) {\n  Loader.call(this, manager);\n}\nCubeTextureLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: CubeTextureLoader,\n  load: function (urls, onLoad, onProgress, onError) {\n    const texture = new CubeTexture();\n    const loader = new ImageLoader(this.manager);\n    loader.setCrossOrigin(this.crossOrigin);\n    loader.setPath(this.path);\n    let loaded = 0;\n    function loadTexture(i) {\n      loader.load(urls[i], function (image) {\n        texture.images[i] = image;\n        loaded++;\n        if (loaded === 6) {\n          texture.needsUpdate = true;\n          if (onLoad) onLoad(texture);\n        }\n      }, undefined, onError);\n    }\n    for (let i = 0; i < urls.length; ++i) {\n      loadTexture(i);\n    }\n    return texture;\n  }\n});\n\n/**\n * Abstract Base class to load generic binary textures formats (rgbe, hdr, ...)\n *\n * Sub classes have to implement the parse() method which will be used in load().\n */\n\nfunction DataTextureLoader(manager) {\n  Loader.call(this, manager);\n}\nDataTextureLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: DataTextureLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const scope = this;\n    const texture = new DataTexture();\n    const loader = new FileLoader(this.manager);\n    loader.setResponseType('arraybuffer');\n    loader.setRequestHeader(this.requestHeader);\n    loader.setPath(this.path);\n    loader.setWithCredentials(scope.withCredentials);\n    loader.load(url, function (buffer) {\n      const texData = scope.parse(buffer);\n      if (!texData) return;\n      if (texData.image !== undefined) {\n        texture.image = texData.image;\n      } else if (texData.data !== undefined) {\n        texture.image.width = texData.width;\n        texture.image.height = texData.height;\n        texture.image.data = texData.data;\n      }\n      texture.wrapS = texData.wrapS !== undefined ? texData.wrapS : ClampToEdgeWrapping;\n      texture.wrapT = texData.wrapT !== undefined ? texData.wrapT : ClampToEdgeWrapping;\n      texture.magFilter = texData.magFilter !== undefined ? texData.magFilter : LinearFilter;\n      texture.minFilter = texData.minFilter !== undefined ? texData.minFilter : LinearFilter;\n      texture.anisotropy = texData.anisotropy !== undefined ? texData.anisotropy : 1;\n      if (texData.encoding !== undefined) {\n        texture.encoding = texData.encoding;\n      }\n      if (texData.flipY !== undefined) {\n        texture.flipY = texData.flipY;\n      }\n      if (texData.format !== undefined) {\n        texture.format = texData.format;\n      }\n      if (texData.type !== undefined) {\n        texture.type = texData.type;\n      }\n      if (texData.mipmaps !== undefined) {\n        texture.mipmaps = texData.mipmaps;\n        texture.minFilter = LinearMipmapLinearFilter; // presumably...\n      }\n\n      if (texData.mipmapCount === 1) {\n        texture.minFilter = LinearFilter;\n      }\n      texture.needsUpdate = true;\n      if (onLoad) onLoad(texture, texData);\n    }, onProgress, onError);\n    return texture;\n  }\n});\nfunction TextureLoader(manager) {\n  Loader.call(this, manager);\n}\nTextureLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: TextureLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const texture = new Texture();\n    const loader = new ImageLoader(this.manager);\n    loader.setCrossOrigin(this.crossOrigin);\n    loader.setPath(this.path);\n    loader.load(url, function (image) {\n      texture.image = image;\n\n      // JPEGs can't have an alpha channel, so memory can be saved by storing them as RGB.\n      const isJPEG = url.search(/\\.jpe?g($|\\?)/i) > 0 || url.search(/^data\\:image\\/jpeg/) === 0;\n      texture.format = isJPEG ? RGBFormat : RGBAFormat;\n      texture.needsUpdate = true;\n      if (onLoad !== undefined) {\n        onLoad(texture);\n      }\n    }, onProgress, onError);\n    return texture;\n  }\n});\n\n/**\n * Extensible curve object.\n *\n * Some common of curve methods:\n * .getPoint( t, optionalTarget ), .getTangent( t, optionalTarget )\n * .getPointAt( u, optionalTarget ), .getTangentAt( u, optionalTarget )\n * .getPoints(), .getSpacedPoints()\n * .getLength()\n * .updateArcLengths()\n *\n * This following curves inherit from THREE.Curve:\n *\n * -- 2D curves --\n * THREE.ArcCurve\n * THREE.CubicBezierCurve\n * THREE.EllipseCurve\n * THREE.LineCurve\n * THREE.QuadraticBezierCurve\n * THREE.SplineCurve\n *\n * -- 3D curves --\n * THREE.CatmullRomCurve3\n * THREE.CubicBezierCurve3\n * THREE.LineCurve3\n * THREE.QuadraticBezierCurve3\n *\n * A series of curves can be represented as a THREE.CurvePath.\n *\n **/\n\nfunction Curve() {\n  this.type = 'Curve';\n  this.arcLengthDivisions = 200;\n}\n_extends__default['default'](Curve.prototype, {\n  // Virtual base class method to overwrite and implement in subclasses\n  //\t- t [0 .. 1]\n\n  getPoint: function /* t, optionalTarget */\n  () {\n    console.warn('THREE.Curve: .getPoint() not implemented.');\n    return null;\n  },\n  // Get point at relative position in curve according to arc length\n  // - u [0 .. 1]\n\n  getPointAt: function (u, optionalTarget) {\n    const t = this.getUtoTmapping(u);\n    return this.getPoint(t, optionalTarget);\n  },\n  // Get sequence of points using getPoint( t )\n\n  getPoints: function (divisions = 5) {\n    const points = [];\n    for (let d = 0; d <= divisions; d++) {\n      points.push(this.getPoint(d / divisions));\n    }\n    return points;\n  },\n  // Get sequence of points using getPointAt( u )\n\n  getSpacedPoints: function (divisions = 5) {\n    const points = [];\n    for (let d = 0; d <= divisions; d++) {\n      points.push(this.getPointAt(d / divisions));\n    }\n    return points;\n  },\n  // Get total curve arc length\n\n  getLength: function () {\n    const lengths = this.getLengths();\n    return lengths[lengths.length - 1];\n  },\n  // Get list of cumulative segment lengths\n\n  getLengths: function (divisions) {\n    if (divisions === undefined) divisions = this.arcLengthDivisions;\n    if (this.cacheArcLengths && this.cacheArcLengths.length === divisions + 1 && !this.needsUpdate) {\n      return this.cacheArcLengths;\n    }\n    this.needsUpdate = false;\n    const cache = [];\n    let current,\n      last = this.getPoint(0);\n    let sum = 0;\n    cache.push(0);\n    for (let p = 1; p <= divisions; p++) {\n      current = this.getPoint(p / divisions);\n      sum += current.distanceTo(last);\n      cache.push(sum);\n      last = current;\n    }\n    this.cacheArcLengths = cache;\n    return cache; // { sums: cache, sum: sum }; Sum is in the last element.\n  },\n\n  updateArcLengths: function () {\n    this.needsUpdate = true;\n    this.getLengths();\n  },\n  // Given u ( 0 .. 1 ), get a t to find p. This gives you points which are equidistant\n\n  getUtoTmapping: function (u, distance) {\n    const arcLengths = this.getLengths();\n    let i = 0;\n    const il = arcLengths.length;\n    let targetArcLength; // The targeted u distance value to get\n\n    if (distance) {\n      targetArcLength = distance;\n    } else {\n      targetArcLength = u * arcLengths[il - 1];\n    }\n\n    // binary search for the index with largest value smaller than target u distance\n\n    let low = 0,\n      high = il - 1,\n      comparison;\n    while (low <= high) {\n      i = Math.floor(low + (high - low) / 2); // less likely to overflow, though probably not issue here, JS doesn't really have integers, all numbers are floats\n\n      comparison = arcLengths[i] - targetArcLength;\n      if (comparison < 0) {\n        low = i + 1;\n      } else if (comparison > 0) {\n        high = i - 1;\n      } else {\n        high = i;\n        break;\n\n        // DONE\n      }\n    }\n\n    i = high;\n    if (arcLengths[i] === targetArcLength) {\n      return i / (il - 1);\n    }\n\n    // we could get finer grain at lengths, or use simple interpolation between two points\n\n    const lengthBefore = arcLengths[i];\n    const lengthAfter = arcLengths[i + 1];\n    const segmentLength = lengthAfter - lengthBefore;\n\n    // determine where we are between the 'before' and 'after' points\n\n    const segmentFraction = (targetArcLength - lengthBefore) / segmentLength;\n\n    // add that fractional amount to t\n\n    const t = (i + segmentFraction) / (il - 1);\n    return t;\n  },\n  // Returns a unit vector tangent at t\n  // In case any sub curve does not implement its tangent derivation,\n  // 2 points a small delta apart will be used to find its gradient\n  // which seems to give a reasonable approximation\n\n  getTangent: function (t, optionalTarget) {\n    const delta = 0.0001;\n    let t1 = t - delta;\n    let t2 = t + delta;\n\n    // Capping in case of danger\n\n    if (t1 < 0) t1 = 0;\n    if (t2 > 1) t2 = 1;\n    const pt1 = this.getPoint(t1);\n    const pt2 = this.getPoint(t2);\n    const tangent = optionalTarget || (pt1.isVector2 ? new Vector2() : new Vector3());\n    tangent.copy(pt2).sub(pt1).normalize();\n    return tangent;\n  },\n  getTangentAt: function (u, optionalTarget) {\n    const t = this.getUtoTmapping(u);\n    return this.getTangent(t, optionalTarget);\n  },\n  computeFrenetFrames: function (segments, closed) {\n    // see http://www.cs.indiana.edu/pub/techreports/TR425.pdf\n\n    const normal = new Vector3();\n    const tangents = [];\n    const normals = [];\n    const binormals = [];\n    const vec = new Vector3();\n    const mat = new Matrix4();\n\n    // compute the tangent vectors for each segment on the curve\n\n    for (let i = 0; i <= segments; i++) {\n      const u = i / segments;\n      tangents[i] = this.getTangentAt(u, new Vector3());\n      tangents[i].normalize();\n    }\n\n    // select an initial normal vector perpendicular to the first tangent vector,\n    // and in the direction of the minimum tangent xyz component\n\n    normals[0] = new Vector3();\n    binormals[0] = new Vector3();\n    let min = Number.MAX_VALUE;\n    const tx = Math.abs(tangents[0].x);\n    const ty = Math.abs(tangents[0].y);\n    const tz = Math.abs(tangents[0].z);\n    if (tx <= min) {\n      min = tx;\n      normal.set(1, 0, 0);\n    }\n    if (ty <= min) {\n      min = ty;\n      normal.set(0, 1, 0);\n    }\n    if (tz <= min) {\n      normal.set(0, 0, 1);\n    }\n    vec.crossVectors(tangents[0], normal).normalize();\n    normals[0].crossVectors(tangents[0], vec);\n    binormals[0].crossVectors(tangents[0], normals[0]);\n\n    // compute the slowly-varying normal and binormal vectors for each segment on the curve\n\n    for (let i = 1; i <= segments; i++) {\n      normals[i] = normals[i - 1].clone();\n      binormals[i] = binormals[i - 1].clone();\n      vec.crossVectors(tangents[i - 1], tangents[i]);\n      if (vec.length() > Number.EPSILON) {\n        vec.normalize();\n        const theta = Math.acos(MathUtils.clamp(tangents[i - 1].dot(tangents[i]), -1, 1)); // clamp for floating pt errors\n\n        normals[i].applyMatrix4(mat.makeRotationAxis(vec, theta));\n      }\n      binormals[i].crossVectors(tangents[i], normals[i]);\n    }\n\n    // if the curve is closed, postprocess the vectors so the first and last normal vectors are the same\n\n    if (closed === true) {\n      let theta = Math.acos(MathUtils.clamp(normals[0].dot(normals[segments]), -1, 1));\n      theta /= segments;\n      if (tangents[0].dot(vec.crossVectors(normals[0], normals[segments])) > 0) {\n        theta = -theta;\n      }\n      for (let i = 1; i <= segments; i++) {\n        // twist a little...\n        normals[i].applyMatrix4(mat.makeRotationAxis(tangents[i], theta * i));\n        binormals[i].crossVectors(tangents[i], normals[i]);\n      }\n    }\n    return {\n      tangents: tangents,\n      normals: normals,\n      binormals: binormals\n    };\n  },\n  clone: function () {\n    return new this.constructor().copy(this);\n  },\n  copy: function (source) {\n    this.arcLengthDivisions = source.arcLengthDivisions;\n    return this;\n  },\n  toJSON: function () {\n    const data = {\n      metadata: {\n        version: 4.5,\n        type: 'Curve',\n        generator: 'Curve.toJSON'\n      }\n    };\n    data.arcLengthDivisions = this.arcLengthDivisions;\n    data.type = this.type;\n    return data;\n  },\n  fromJSON: function (json) {\n    this.arcLengthDivisions = json.arcLengthDivisions;\n    return this;\n  }\n});\nfunction EllipseCurve(aX, aY, xRadius, yRadius, aStartAngle, aEndAngle, aClockwise, aRotation) {\n  Curve.call(this);\n  this.type = 'EllipseCurve';\n  this.aX = aX || 0;\n  this.aY = aY || 0;\n  this.xRadius = xRadius || 1;\n  this.yRadius = yRadius || 1;\n  this.aStartAngle = aStartAngle || 0;\n  this.aEndAngle = aEndAngle || 2 * Math.PI;\n  this.aClockwise = aClockwise || false;\n  this.aRotation = aRotation || 0;\n}\nEllipseCurve.prototype = Object.create(Curve.prototype);\nEllipseCurve.prototype.constructor = EllipseCurve;\nEllipseCurve.prototype.isEllipseCurve = true;\nEllipseCurve.prototype.getPoint = function (t, optionalTarget) {\n  const point = optionalTarget || new Vector2();\n  const twoPi = Math.PI * 2;\n  let deltaAngle = this.aEndAngle - this.aStartAngle;\n  const samePoints = Math.abs(deltaAngle) < Number.EPSILON;\n\n  // ensures that deltaAngle is 0 .. 2 PI\n  while (deltaAngle < 0) deltaAngle += twoPi;\n  while (deltaAngle > twoPi) deltaAngle -= twoPi;\n  if (deltaAngle < Number.EPSILON) {\n    if (samePoints) {\n      deltaAngle = 0;\n    } else {\n      deltaAngle = twoPi;\n    }\n  }\n  if (this.aClockwise === true && !samePoints) {\n    if (deltaAngle === twoPi) {\n      deltaAngle = -twoPi;\n    } else {\n      deltaAngle = deltaAngle - twoPi;\n    }\n  }\n  const angle = this.aStartAngle + t * deltaAngle;\n  let x = this.aX + this.xRadius * Math.cos(angle);\n  let y = this.aY + this.yRadius * Math.sin(angle);\n  if (this.aRotation !== 0) {\n    const cos = Math.cos(this.aRotation);\n    const sin = Math.sin(this.aRotation);\n    const tx = x - this.aX;\n    const ty = y - this.aY;\n\n    // Rotate the point about the center of the ellipse.\n    x = tx * cos - ty * sin + this.aX;\n    y = tx * sin + ty * cos + this.aY;\n  }\n  return point.set(x, y);\n};\nEllipseCurve.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.aX = source.aX;\n  this.aY = source.aY;\n  this.xRadius = source.xRadius;\n  this.yRadius = source.yRadius;\n  this.aStartAngle = source.aStartAngle;\n  this.aEndAngle = source.aEndAngle;\n  this.aClockwise = source.aClockwise;\n  this.aRotation = source.aRotation;\n  return this;\n};\nEllipseCurve.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.aX = this.aX;\n  data.aY = this.aY;\n  data.xRadius = this.xRadius;\n  data.yRadius = this.yRadius;\n  data.aStartAngle = this.aStartAngle;\n  data.aEndAngle = this.aEndAngle;\n  data.aClockwise = this.aClockwise;\n  data.aRotation = this.aRotation;\n  return data;\n};\nEllipseCurve.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.aX = json.aX;\n  this.aY = json.aY;\n  this.xRadius = json.xRadius;\n  this.yRadius = json.yRadius;\n  this.aStartAngle = json.aStartAngle;\n  this.aEndAngle = json.aEndAngle;\n  this.aClockwise = json.aClockwise;\n  this.aRotation = json.aRotation;\n  return this;\n};\nfunction ArcCurve(aX, aY, aRadius, aStartAngle, aEndAngle, aClockwise) {\n  EllipseCurve.call(this, aX, aY, aRadius, aRadius, aStartAngle, aEndAngle, aClockwise);\n  this.type = 'ArcCurve';\n}\nArcCurve.prototype = Object.create(EllipseCurve.prototype);\nArcCurve.prototype.constructor = ArcCurve;\nArcCurve.prototype.isArcCurve = true;\n\n/**\n * Centripetal CatmullRom Curve - which is useful for avoiding\n * cusps and self-intersections in non-uniform catmull rom curves.\n * http://www.cemyuksel.com/research/catmullrom_param/catmullrom.pdf\n *\n * curve.type accepts centripetal(default), chordal and catmullrom\n * curve.tension is used for catmullrom which defaults to 0.5\n */\n\n/*\nBased on an optimized c++ solution in\n - http://stackoverflow.com/questions/9489736/catmull-rom-curve-with-no-cusps-and-no-self-intersections/\n - http://ideone.com/NoEbVM\n\nThis CubicPoly class could be used for reusing some variables and calculations,\nbut for three.js curve use, it could be possible inlined and flatten into a single function call\nwhich can be placed in CurveUtils.\n*/\n\nfunction CubicPoly() {\n  let c0 = 0,\n    c1 = 0,\n    c2 = 0,\n    c3 = 0;\n\n  /*\n   * Compute coefficients for a cubic polynomial\n   *   p(s) = c0 + c1*s + c2*s^2 + c3*s^3\n   * such that\n   *   p(0) = x0, p(1) = x1\n   *  and\n   *   p'(0) = t0, p'(1) = t1.\n   */\n  function init(x0, x1, t0, t1) {\n    c0 = x0;\n    c1 = t0;\n    c2 = -3 * x0 + 3 * x1 - 2 * t0 - t1;\n    c3 = 2 * x0 - 2 * x1 + t0 + t1;\n  }\n  return {\n    initCatmullRom: function (x0, x1, x2, x3, tension) {\n      init(x1, x2, tension * (x2 - x0), tension * (x3 - x1));\n    },\n    initNonuniformCatmullRom: function (x0, x1, x2, x3, dt0, dt1, dt2) {\n      // compute tangents when parameterized in [t1,t2]\n      let t1 = (x1 - x0) / dt0 - (x2 - x0) / (dt0 + dt1) + (x2 - x1) / dt1;\n      let t2 = (x2 - x1) / dt1 - (x3 - x1) / (dt1 + dt2) + (x3 - x2) / dt2;\n\n      // rescale tangents for parametrization in [0,1]\n      t1 *= dt1;\n      t2 *= dt1;\n      init(x1, x2, t1, t2);\n    },\n    calc: function (t) {\n      const t2 = t * t;\n      const t3 = t2 * t;\n      return c0 + c1 * t + c2 * t2 + c3 * t3;\n    }\n  };\n}\n\n//\n\nconst tmp = new Vector3();\nconst px = new CubicPoly(),\n  py = new CubicPoly(),\n  pz = new CubicPoly();\nfunction CatmullRomCurve3(points = [], closed = false, curveType = 'centripetal', tension = 0.5) {\n  Curve.call(this);\n  this.type = 'CatmullRomCurve3';\n  this.points = points;\n  this.closed = closed;\n  this.curveType = curveType;\n  this.tension = tension;\n}\nCatmullRomCurve3.prototype = Object.create(Curve.prototype);\nCatmullRomCurve3.prototype.constructor = CatmullRomCurve3;\nCatmullRomCurve3.prototype.isCatmullRomCurve3 = true;\nCatmullRomCurve3.prototype.getPoint = function (t, optionalTarget = new Vector3()) {\n  const point = optionalTarget;\n  const points = this.points;\n  const l = points.length;\n  const p = (l - (this.closed ? 0 : 1)) * t;\n  let intPoint = Math.floor(p);\n  let weight = p - intPoint;\n  if (this.closed) {\n    intPoint += intPoint > 0 ? 0 : (Math.floor(Math.abs(intPoint) / l) + 1) * l;\n  } else if (weight === 0 && intPoint === l - 1) {\n    intPoint = l - 2;\n    weight = 1;\n  }\n  let p0, p3; // 4 points (p1 & p2 defined below)\n\n  if (this.closed || intPoint > 0) {\n    p0 = points[(intPoint - 1) % l];\n  } else {\n    // extrapolate first point\n    tmp.subVectors(points[0], points[1]).add(points[0]);\n    p0 = tmp;\n  }\n  const p1 = points[intPoint % l];\n  const p2 = points[(intPoint + 1) % l];\n  if (this.closed || intPoint + 2 < l) {\n    p3 = points[(intPoint + 2) % l];\n  } else {\n    // extrapolate last point\n    tmp.subVectors(points[l - 1], points[l - 2]).add(points[l - 1]);\n    p3 = tmp;\n  }\n  if (this.curveType === 'centripetal' || this.curveType === 'chordal') {\n    // init Centripetal / Chordal Catmull-Rom\n    const pow = this.curveType === 'chordal' ? 0.5 : 0.25;\n    let dt0 = Math.pow(p0.distanceToSquared(p1), pow);\n    let dt1 = Math.pow(p1.distanceToSquared(p2), pow);\n    let dt2 = Math.pow(p2.distanceToSquared(p3), pow);\n\n    // safety check for repeated points\n    if (dt1 < 1e-4) dt1 = 1.0;\n    if (dt0 < 1e-4) dt0 = dt1;\n    if (dt2 < 1e-4) dt2 = dt1;\n    px.initNonuniformCatmullRom(p0.x, p1.x, p2.x, p3.x, dt0, dt1, dt2);\n    py.initNonuniformCatmullRom(p0.y, p1.y, p2.y, p3.y, dt0, dt1, dt2);\n    pz.initNonuniformCatmullRom(p0.z, p1.z, p2.z, p3.z, dt0, dt1, dt2);\n  } else if (this.curveType === 'catmullrom') {\n    px.initCatmullRom(p0.x, p1.x, p2.x, p3.x, this.tension);\n    py.initCatmullRom(p0.y, p1.y, p2.y, p3.y, this.tension);\n    pz.initCatmullRom(p0.z, p1.z, p2.z, p3.z, this.tension);\n  }\n  point.set(px.calc(weight), py.calc(weight), pz.calc(weight));\n  return point;\n};\nCatmullRomCurve3.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.points = [];\n  for (let i = 0, l = source.points.length; i < l; i++) {\n    const point = source.points[i];\n    this.points.push(point.clone());\n  }\n  this.closed = source.closed;\n  this.curveType = source.curveType;\n  this.tension = source.tension;\n  return this;\n};\nCatmullRomCurve3.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.points = [];\n  for (let i = 0, l = this.points.length; i < l; i++) {\n    const point = this.points[i];\n    data.points.push(point.toArray());\n  }\n  data.closed = this.closed;\n  data.curveType = this.curveType;\n  data.tension = this.tension;\n  return data;\n};\nCatmullRomCurve3.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.points = [];\n  for (let i = 0, l = json.points.length; i < l; i++) {\n    const point = json.points[i];\n    this.points.push(new Vector3().fromArray(point));\n  }\n  this.closed = json.closed;\n  this.curveType = json.curveType;\n  this.tension = json.tension;\n  return this;\n};\n\n/**\n * Bezier Curves formulas obtained from\n * http://en.wikipedia.org/wiki/Bézier_curve\n */\n\nfunction CatmullRom(t, p0, p1, p2, p3) {\n  const v0 = (p2 - p0) * 0.5;\n  const v1 = (p3 - p1) * 0.5;\n  const t2 = t * t;\n  const t3 = t * t2;\n  return (2 * p1 - 2 * p2 + v0 + v1) * t3 + (-3 * p1 + 3 * p2 - 2 * v0 - v1) * t2 + v0 * t + p1;\n}\n\n//\n\nfunction QuadraticBezierP0(t, p) {\n  const k = 1 - t;\n  return k * k * p;\n}\nfunction QuadraticBezierP1(t, p) {\n  return 2 * (1 - t) * t * p;\n}\nfunction QuadraticBezierP2(t, p) {\n  return t * t * p;\n}\nfunction QuadraticBezier(t, p0, p1, p2) {\n  return QuadraticBezierP0(t, p0) + QuadraticBezierP1(t, p1) + QuadraticBezierP2(t, p2);\n}\n\n//\n\nfunction CubicBezierP0(t, p) {\n  const k = 1 - t;\n  return k * k * k * p;\n}\nfunction CubicBezierP1(t, p) {\n  const k = 1 - t;\n  return 3 * k * k * t * p;\n}\nfunction CubicBezierP2(t, p) {\n  return 3 * (1 - t) * t * t * p;\n}\nfunction CubicBezierP3(t, p) {\n  return t * t * t * p;\n}\nfunction CubicBezier(t, p0, p1, p2, p3) {\n  return CubicBezierP0(t, p0) + CubicBezierP1(t, p1) + CubicBezierP2(t, p2) + CubicBezierP3(t, p3);\n}\nfunction CubicBezierCurve(v0 = new Vector2(), v1 = new Vector2(), v2 = new Vector2(), v3 = new Vector2()) {\n  Curve.call(this);\n  this.type = 'CubicBezierCurve';\n  this.v0 = v0;\n  this.v1 = v1;\n  this.v2 = v2;\n  this.v3 = v3;\n}\nCubicBezierCurve.prototype = Object.create(Curve.prototype);\nCubicBezierCurve.prototype.constructor = CubicBezierCurve;\nCubicBezierCurve.prototype.isCubicBezierCurve = true;\nCubicBezierCurve.prototype.getPoint = function (t, optionalTarget = new Vector2()) {\n  const point = optionalTarget;\n  const v0 = this.v0,\n    v1 = this.v1,\n    v2 = this.v2,\n    v3 = this.v3;\n  point.set(CubicBezier(t, v0.x, v1.x, v2.x, v3.x), CubicBezier(t, v0.y, v1.y, v2.y, v3.y));\n  return point;\n};\nCubicBezierCurve.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.v0.copy(source.v0);\n  this.v1.copy(source.v1);\n  this.v2.copy(source.v2);\n  this.v3.copy(source.v3);\n  return this;\n};\nCubicBezierCurve.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.v0 = this.v0.toArray();\n  data.v1 = this.v1.toArray();\n  data.v2 = this.v2.toArray();\n  data.v3 = this.v3.toArray();\n  return data;\n};\nCubicBezierCurve.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.v0.fromArray(json.v0);\n  this.v1.fromArray(json.v1);\n  this.v2.fromArray(json.v2);\n  this.v3.fromArray(json.v3);\n  return this;\n};\nfunction CubicBezierCurve3(v0 = new Vector3(), v1 = new Vector3(), v2 = new Vector3(), v3 = new Vector3()) {\n  Curve.call(this);\n  this.type = 'CubicBezierCurve3';\n  this.v0 = v0;\n  this.v1 = v1;\n  this.v2 = v2;\n  this.v3 = v3;\n}\nCubicBezierCurve3.prototype = Object.create(Curve.prototype);\nCubicBezierCurve3.prototype.constructor = CubicBezierCurve3;\nCubicBezierCurve3.prototype.isCubicBezierCurve3 = true;\nCubicBezierCurve3.prototype.getPoint = function (t, optionalTarget = new Vector3()) {\n  const point = optionalTarget;\n  const v0 = this.v0,\n    v1 = this.v1,\n    v2 = this.v2,\n    v3 = this.v3;\n  point.set(CubicBezier(t, v0.x, v1.x, v2.x, v3.x), CubicBezier(t, v0.y, v1.y, v2.y, v3.y), CubicBezier(t, v0.z, v1.z, v2.z, v3.z));\n  return point;\n};\nCubicBezierCurve3.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.v0.copy(source.v0);\n  this.v1.copy(source.v1);\n  this.v2.copy(source.v2);\n  this.v3.copy(source.v3);\n  return this;\n};\nCubicBezierCurve3.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.v0 = this.v0.toArray();\n  data.v1 = this.v1.toArray();\n  data.v2 = this.v2.toArray();\n  data.v3 = this.v3.toArray();\n  return data;\n};\nCubicBezierCurve3.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.v0.fromArray(json.v0);\n  this.v1.fromArray(json.v1);\n  this.v2.fromArray(json.v2);\n  this.v3.fromArray(json.v3);\n  return this;\n};\nfunction LineCurve(v1 = new Vector2(), v2 = new Vector2()) {\n  Curve.call(this);\n  this.type = 'LineCurve';\n  this.v1 = v1;\n  this.v2 = v2;\n}\nLineCurve.prototype = Object.create(Curve.prototype);\nLineCurve.prototype.constructor = LineCurve;\nLineCurve.prototype.isLineCurve = true;\nLineCurve.prototype.getPoint = function (t, optionalTarget = new Vector2()) {\n  const point = optionalTarget;\n  if (t === 1) {\n    point.copy(this.v2);\n  } else {\n    point.copy(this.v2).sub(this.v1);\n    point.multiplyScalar(t).add(this.v1);\n  }\n  return point;\n};\n\n// Line curve is linear, so we can overwrite default getPointAt\n\nLineCurve.prototype.getPointAt = function (u, optionalTarget) {\n  return this.getPoint(u, optionalTarget);\n};\nLineCurve.prototype.getTangent = function (t, optionalTarget) {\n  const tangent = optionalTarget || new Vector2();\n  tangent.copy(this.v2).sub(this.v1).normalize();\n  return tangent;\n};\nLineCurve.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.v1.copy(source.v1);\n  this.v2.copy(source.v2);\n  return this;\n};\nLineCurve.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.v1 = this.v1.toArray();\n  data.v2 = this.v2.toArray();\n  return data;\n};\nLineCurve.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.v1.fromArray(json.v1);\n  this.v2.fromArray(json.v2);\n  return this;\n};\nfunction LineCurve3(v1 = new Vector3(), v2 = new Vector3()) {\n  Curve.call(this);\n  this.type = 'LineCurve3';\n  this.v1 = v1;\n  this.v2 = v2;\n}\nLineCurve3.prototype = Object.create(Curve.prototype);\nLineCurve3.prototype.constructor = LineCurve3;\nLineCurve3.prototype.isLineCurve3 = true;\nLineCurve3.prototype.getPoint = function (t, optionalTarget = new Vector3()) {\n  const point = optionalTarget;\n  if (t === 1) {\n    point.copy(this.v2);\n  } else {\n    point.copy(this.v2).sub(this.v1);\n    point.multiplyScalar(t).add(this.v1);\n  }\n  return point;\n};\n\n// Line curve is linear, so we can overwrite default getPointAt\n\nLineCurve3.prototype.getPointAt = function (u, optionalTarget) {\n  return this.getPoint(u, optionalTarget);\n};\nLineCurve3.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.v1.copy(source.v1);\n  this.v2.copy(source.v2);\n  return this;\n};\nLineCurve3.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.v1 = this.v1.toArray();\n  data.v2 = this.v2.toArray();\n  return data;\n};\nLineCurve3.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.v1.fromArray(json.v1);\n  this.v2.fromArray(json.v2);\n  return this;\n};\nfunction QuadraticBezierCurve(v0 = new Vector2(), v1 = new Vector2(), v2 = new Vector2()) {\n  Curve.call(this);\n  this.type = 'QuadraticBezierCurve';\n  this.v0 = v0;\n  this.v1 = v1;\n  this.v2 = v2;\n}\nQuadraticBezierCurve.prototype = Object.create(Curve.prototype);\nQuadraticBezierCurve.prototype.constructor = QuadraticBezierCurve;\nQuadraticBezierCurve.prototype.isQuadraticBezierCurve = true;\nQuadraticBezierCurve.prototype.getPoint = function (t, optionalTarget = new Vector2()) {\n  const point = optionalTarget;\n  const v0 = this.v0,\n    v1 = this.v1,\n    v2 = this.v2;\n  point.set(QuadraticBezier(t, v0.x, v1.x, v2.x), QuadraticBezier(t, v0.y, v1.y, v2.y));\n  return point;\n};\nQuadraticBezierCurve.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.v0.copy(source.v0);\n  this.v1.copy(source.v1);\n  this.v2.copy(source.v2);\n  return this;\n};\nQuadraticBezierCurve.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.v0 = this.v0.toArray();\n  data.v1 = this.v1.toArray();\n  data.v2 = this.v2.toArray();\n  return data;\n};\nQuadraticBezierCurve.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.v0.fromArray(json.v0);\n  this.v1.fromArray(json.v1);\n  this.v2.fromArray(json.v2);\n  return this;\n};\nfunction QuadraticBezierCurve3(v0 = new Vector3(), v1 = new Vector3(), v2 = new Vector3()) {\n  Curve.call(this);\n  this.type = 'QuadraticBezierCurve3';\n  this.v0 = v0;\n  this.v1 = v1;\n  this.v2 = v2;\n}\nQuadraticBezierCurve3.prototype = Object.create(Curve.prototype);\nQuadraticBezierCurve3.prototype.constructor = QuadraticBezierCurve3;\nQuadraticBezierCurve3.prototype.isQuadraticBezierCurve3 = true;\nQuadraticBezierCurve3.prototype.getPoint = function (t, optionalTarget = new Vector3()) {\n  const point = optionalTarget;\n  const v0 = this.v0,\n    v1 = this.v1,\n    v2 = this.v2;\n  point.set(QuadraticBezier(t, v0.x, v1.x, v2.x), QuadraticBezier(t, v0.y, v1.y, v2.y), QuadraticBezier(t, v0.z, v1.z, v2.z));\n  return point;\n};\nQuadraticBezierCurve3.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.v0.copy(source.v0);\n  this.v1.copy(source.v1);\n  this.v2.copy(source.v2);\n  return this;\n};\nQuadraticBezierCurve3.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.v0 = this.v0.toArray();\n  data.v1 = this.v1.toArray();\n  data.v2 = this.v2.toArray();\n  return data;\n};\nQuadraticBezierCurve3.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.v0.fromArray(json.v0);\n  this.v1.fromArray(json.v1);\n  this.v2.fromArray(json.v2);\n  return this;\n};\nfunction SplineCurve(points = []) {\n  Curve.call(this);\n  this.type = 'SplineCurve';\n  this.points = points;\n}\nSplineCurve.prototype = Object.create(Curve.prototype);\nSplineCurve.prototype.constructor = SplineCurve;\nSplineCurve.prototype.isSplineCurve = true;\nSplineCurve.prototype.getPoint = function (t, optionalTarget = new Vector2()) {\n  const point = optionalTarget;\n  const points = this.points;\n  const p = (points.length - 1) * t;\n  const intPoint = Math.floor(p);\n  const weight = p - intPoint;\n  const p0 = points[intPoint === 0 ? intPoint : intPoint - 1];\n  const p1 = points[intPoint];\n  const p2 = points[intPoint > points.length - 2 ? points.length - 1 : intPoint + 1];\n  const p3 = points[intPoint > points.length - 3 ? points.length - 1 : intPoint + 2];\n  point.set(CatmullRom(weight, p0.x, p1.x, p2.x, p3.x), CatmullRom(weight, p0.y, p1.y, p2.y, p3.y));\n  return point;\n};\nSplineCurve.prototype.copy = function (source) {\n  Curve.prototype.copy.call(this, source);\n  this.points = [];\n  for (let i = 0, l = source.points.length; i < l; i++) {\n    const point = source.points[i];\n    this.points.push(point.clone());\n  }\n  return this;\n};\nSplineCurve.prototype.toJSON = function () {\n  const data = Curve.prototype.toJSON.call(this);\n  data.points = [];\n  for (let i = 0, l = this.points.length; i < l; i++) {\n    const point = this.points[i];\n    data.points.push(point.toArray());\n  }\n  return data;\n};\nSplineCurve.prototype.fromJSON = function (json) {\n  Curve.prototype.fromJSON.call(this, json);\n  this.points = [];\n  for (let i = 0, l = json.points.length; i < l; i++) {\n    const point = json.points[i];\n    this.points.push(new Vector2().fromArray(point));\n  }\n  return this;\n};\nvar Curves = /*#__PURE__*/Object.freeze({\n  __proto__: null,\n  ArcCurve: ArcCurve,\n  CatmullRomCurve3: CatmullRomCurve3,\n  CubicBezierCurve: CubicBezierCurve,\n  CubicBezierCurve3: CubicBezierCurve3,\n  EllipseCurve: EllipseCurve,\n  LineCurve: LineCurve,\n  LineCurve3: LineCurve3,\n  QuadraticBezierCurve: QuadraticBezierCurve,\n  QuadraticBezierCurve3: QuadraticBezierCurve3,\n  SplineCurve: SplineCurve\n});\n\n/**************************************************************\n *\tCurved Path - a curve path is simply a array of connected\n *  curves, but retains the api of a curve\n **************************************************************/\n\nfunction CurvePath() {\n  Curve.call(this);\n  this.type = 'CurvePath';\n  this.curves = [];\n  this.autoClose = false; // Automatically closes the path\n}\n\nCurvePath.prototype = _extends__default['default'](Object.create(Curve.prototype), {\n  constructor: CurvePath,\n  add: function (curve) {\n    this.curves.push(curve);\n  },\n  closePath: function () {\n    // Add a line curve if start and end of lines are not connected\n    const startPoint = this.curves[0].getPoint(0);\n    const endPoint = this.curves[this.curves.length - 1].getPoint(1);\n    if (!startPoint.equals(endPoint)) {\n      this.curves.push(new LineCurve(endPoint, startPoint));\n    }\n  },\n  // To get accurate point with reference to\n  // entire path distance at time t,\n  // following has to be done:\n\n  // 1. Length of each sub path have to be known\n  // 2. Locate and identify type of curve\n  // 3. Get t for the curve\n  // 4. Return curve.getPointAt(t')\n\n  getPoint: function (t) {\n    const d = t * this.getLength();\n    const curveLengths = this.getCurveLengths();\n    let i = 0;\n\n    // To think about boundaries points.\n\n    while (i < curveLengths.length) {\n      if (curveLengths[i] >= d) {\n        const diff = curveLengths[i] - d;\n        const curve = this.curves[i];\n        const segmentLength = curve.getLength();\n        const u = segmentLength === 0 ? 0 : 1 - diff / segmentLength;\n        return curve.getPointAt(u);\n      }\n      i++;\n    }\n    return null;\n\n    // loop where sum != 0, sum > d , sum+1 <d\n  },\n\n  // We cannot use the default THREE.Curve getPoint() with getLength() because in\n  // THREE.Curve, getLength() depends on getPoint() but in THREE.CurvePath\n  // getPoint() depends on getLength\n\n  getLength: function () {\n    const lens = this.getCurveLengths();\n    return lens[lens.length - 1];\n  },\n  // cacheLengths must be recalculated.\n  updateArcLengths: function () {\n    this.needsUpdate = true;\n    this.cacheLengths = null;\n    this.getCurveLengths();\n  },\n  // Compute lengths and cache them\n  // We cannot overwrite getLengths() because UtoT mapping uses it.\n\n  getCurveLengths: function () {\n    // We use cache values if curves and cache array are same length\n\n    if (this.cacheLengths && this.cacheLengths.length === this.curves.length) {\n      return this.cacheLengths;\n    }\n\n    // Get length of sub-curve\n    // Push sums into cached array\n\n    const lengths = [];\n    let sums = 0;\n    for (let i = 0, l = this.curves.length; i < l; i++) {\n      sums += this.curves[i].getLength();\n      lengths.push(sums);\n    }\n    this.cacheLengths = lengths;\n    return lengths;\n  },\n  getSpacedPoints: function (divisions = 40) {\n    const points = [];\n    for (let i = 0; i <= divisions; i++) {\n      points.push(this.getPoint(i / divisions));\n    }\n    if (this.autoClose) {\n      points.push(points[0]);\n    }\n    return points;\n  },\n  getPoints: function (divisions = 12) {\n    const points = [];\n    let last;\n    for (let i = 0, curves = this.curves; i < curves.length; i++) {\n      const curve = curves[i];\n      const resolution = curve && curve.isEllipseCurve ? divisions * 2 : curve && (curve.isLineCurve || curve.isLineCurve3) ? 1 : curve && curve.isSplineCurve ? divisions * curve.points.length : divisions;\n      const pts = curve.getPoints(resolution);\n      for (let j = 0; j < pts.length; j++) {\n        const point = pts[j];\n        if (last && last.equals(point)) continue; // ensures no consecutive points are duplicates\n\n        points.push(point);\n        last = point;\n      }\n    }\n    if (this.autoClose && points.length > 1 && !points[points.length - 1].equals(points[0])) {\n      points.push(points[0]);\n    }\n    return points;\n  },\n  copy: function (source) {\n    Curve.prototype.copy.call(this, source);\n    this.curves = [];\n    for (let i = 0, l = source.curves.length; i < l; i++) {\n      const curve = source.curves[i];\n      this.curves.push(curve.clone());\n    }\n    this.autoClose = source.autoClose;\n    return this;\n  },\n  toJSON: function () {\n    const data = Curve.prototype.toJSON.call(this);\n    data.autoClose = this.autoClose;\n    data.curves = [];\n    for (let i = 0, l = this.curves.length; i < l; i++) {\n      const curve = this.curves[i];\n      data.curves.push(curve.toJSON());\n    }\n    return data;\n  },\n  fromJSON: function (json) {\n    Curve.prototype.fromJSON.call(this, json);\n    this.autoClose = json.autoClose;\n    this.curves = [];\n    for (let i = 0, l = json.curves.length; i < l; i++) {\n      const curve = json.curves[i];\n      this.curves.push(new Curves[curve.type]().fromJSON(curve));\n    }\n    return this;\n  }\n});\nfunction Path(points) {\n  CurvePath.call(this);\n  this.type = 'Path';\n  this.currentPoint = new Vector2();\n  if (points) {\n    this.setFromPoints(points);\n  }\n}\nPath.prototype = _extends__default['default'](Object.create(CurvePath.prototype), {\n  constructor: Path,\n  setFromPoints: function (points) {\n    this.moveTo(points[0].x, points[0].y);\n    for (let i = 1, l = points.length; i < l; i++) {\n      this.lineTo(points[i].x, points[i].y);\n    }\n    return this;\n  },\n  moveTo: function (x, y) {\n    this.currentPoint.set(x, y); // TODO consider referencing vectors instead of copying?\n\n    return this;\n  },\n  lineTo: function (x, y) {\n    const curve = new LineCurve(this.currentPoint.clone(), new Vector2(x, y));\n    this.curves.push(curve);\n    this.currentPoint.set(x, y);\n    return this;\n  },\n  quadraticCurveTo: function (aCPx, aCPy, aX, aY) {\n    const curve = new QuadraticBezierCurve(this.currentPoint.clone(), new Vector2(aCPx, aCPy), new Vector2(aX, aY));\n    this.curves.push(curve);\n    this.currentPoint.set(aX, aY);\n    return this;\n  },\n  bezierCurveTo: function (aCP1x, aCP1y, aCP2x, aCP2y, aX, aY) {\n    const curve = new CubicBezierCurve(this.currentPoint.clone(), new Vector2(aCP1x, aCP1y), new Vector2(aCP2x, aCP2y), new Vector2(aX, aY));\n    this.curves.push(curve);\n    this.currentPoint.set(aX, aY);\n    return this;\n  },\n  splineThru: function (pts /*Array of Vector*/) {\n    const npts = [this.currentPoint.clone()].concat(pts);\n    const curve = new SplineCurve(npts);\n    this.curves.push(curve);\n    this.currentPoint.copy(pts[pts.length - 1]);\n    return this;\n  },\n  arc: function (aX, aY, aRadius, aStartAngle, aEndAngle, aClockwise) {\n    const x0 = this.currentPoint.x;\n    const y0 = this.currentPoint.y;\n    this.absarc(aX + x0, aY + y0, aRadius, aStartAngle, aEndAngle, aClockwise);\n    return this;\n  },\n  absarc: function (aX, aY, aRadius, aStartAngle, aEndAngle, aClockwise) {\n    this.absellipse(aX, aY, aRadius, aRadius, aStartAngle, aEndAngle, aClockwise);\n    return this;\n  },\n  ellipse: function (aX, aY, xRadius, yRadius, aStartAngle, aEndAngle, aClockwise, aRotation) {\n    const x0 = this.currentPoint.x;\n    const y0 = this.currentPoint.y;\n    this.absellipse(aX + x0, aY + y0, xRadius, yRadius, aStartAngle, aEndAngle, aClockwise, aRotation);\n    return this;\n  },\n  absellipse: function (aX, aY, xRadius, yRadius, aStartAngle, aEndAngle, aClockwise, aRotation) {\n    const curve = new EllipseCurve(aX, aY, xRadius, yRadius, aStartAngle, aEndAngle, aClockwise, aRotation);\n    if (this.curves.length > 0) {\n      // if a previous curve is present, attempt to join\n      const firstPoint = curve.getPoint(0);\n      if (!firstPoint.equals(this.currentPoint)) {\n        this.lineTo(firstPoint.x, firstPoint.y);\n      }\n    }\n    this.curves.push(curve);\n    const lastPoint = curve.getPoint(1);\n    this.currentPoint.copy(lastPoint);\n    return this;\n  },\n  copy: function (source) {\n    CurvePath.prototype.copy.call(this, source);\n    this.currentPoint.copy(source.currentPoint);\n    return this;\n  },\n  toJSON: function () {\n    const data = CurvePath.prototype.toJSON.call(this);\n    data.currentPoint = this.currentPoint.toArray();\n    return data;\n  },\n  fromJSON: function (json) {\n    CurvePath.prototype.fromJSON.call(this, json);\n    this.currentPoint.fromArray(json.currentPoint);\n    return this;\n  }\n});\nfunction Shape(points) {\n  Path.call(this, points);\n  this.uuid = MathUtils.generateUUID();\n  this.type = 'Shape';\n  this.holes = [];\n}\nShape.prototype = _extends__default['default'](Object.create(Path.prototype), {\n  constructor: Shape,\n  getPointsHoles: function (divisions) {\n    const holesPts = [];\n    for (let i = 0, l = this.holes.length; i < l; i++) {\n      holesPts[i] = this.holes[i].getPoints(divisions);\n    }\n    return holesPts;\n  },\n  // get points of shape and holes (keypoints based on segments parameter)\n\n  extractPoints: function (divisions) {\n    return {\n      shape: this.getPoints(divisions),\n      holes: this.getPointsHoles(divisions)\n    };\n  },\n  copy: function (source) {\n    Path.prototype.copy.call(this, source);\n    this.holes = [];\n    for (let i = 0, l = source.holes.length; i < l; i++) {\n      const hole = source.holes[i];\n      this.holes.push(hole.clone());\n    }\n    return this;\n  },\n  toJSON: function () {\n    const data = Path.prototype.toJSON.call(this);\n    data.uuid = this.uuid;\n    data.holes = [];\n    for (let i = 0, l = this.holes.length; i < l; i++) {\n      const hole = this.holes[i];\n      data.holes.push(hole.toJSON());\n    }\n    return data;\n  },\n  fromJSON: function (json) {\n    Path.prototype.fromJSON.call(this, json);\n    this.uuid = json.uuid;\n    this.holes = [];\n    for (let i = 0, l = json.holes.length; i < l; i++) {\n      const hole = json.holes[i];\n      this.holes.push(new Path().fromJSON(hole));\n    }\n    return this;\n  }\n});\nfunction Light(color, intensity = 1) {\n  Object3D.call(this);\n  this.type = 'Light';\n  this.color = new Color(color);\n  this.intensity = intensity;\n}\nLight.prototype = _extends__default['default'](Object.create(Object3D.prototype), {\n  constructor: Light,\n  isLight: true,\n  copy: function (source) {\n    Object3D.prototype.copy.call(this, source);\n    this.color.copy(source.color);\n    this.intensity = source.intensity;\n    return this;\n  },\n  toJSON: function (meta) {\n    const data = Object3D.prototype.toJSON.call(this, meta);\n    data.object.color = this.color.getHex();\n    data.object.intensity = this.intensity;\n    if (this.groundColor !== undefined) data.object.groundColor = this.groundColor.getHex();\n    if (this.distance !== undefined) data.object.distance = this.distance;\n    if (this.angle !== undefined) data.object.angle = this.angle;\n    if (this.decay !== undefined) data.object.decay = this.decay;\n    if (this.penumbra !== undefined) data.object.penumbra = this.penumbra;\n    if (this.shadow !== undefined) data.object.shadow = this.shadow.toJSON();\n    return data;\n  }\n});\nfunction HemisphereLight(skyColor, groundColor, intensity) {\n  Light.call(this, skyColor, intensity);\n  this.type = 'HemisphereLight';\n  this.position.copy(Object3D.DefaultUp);\n  this.updateMatrix();\n  this.groundColor = new Color(groundColor);\n}\nHemisphereLight.prototype = _extends__default['default'](Object.create(Light.prototype), {\n  constructor: HemisphereLight,\n  isHemisphereLight: true,\n  copy: function (source) {\n    Light.prototype.copy.call(this, source);\n    this.groundColor.copy(source.groundColor);\n    return this;\n  }\n});\nfunction LightShadow(camera) {\n  this.camera = camera;\n  this.bias = 0;\n  this.normalBias = 0;\n  this.radius = 1;\n  this.mapSize = new Vector2(512, 512);\n  this.map = null;\n  this.mapPass = null;\n  this.matrix = new Matrix4();\n  this.autoUpdate = true;\n  this.needsUpdate = false;\n  this._frustum = new Frustum();\n  this._frameExtents = new Vector2(1, 1);\n  this._viewportCount = 1;\n  this._viewports = [new Vector4(0, 0, 1, 1)];\n}\n_extends__default['default'](LightShadow.prototype, {\n  _projScreenMatrix: new Matrix4(),\n  _lightPositionWorld: new Vector3(),\n  _lookTarget: new Vector3(),\n  getViewportCount: function () {\n    return this._viewportCount;\n  },\n  getFrustum: function () {\n    return this._frustum;\n  },\n  updateMatrices: function (light) {\n    const shadowCamera = this.camera,\n      shadowMatrix = this.matrix,\n      projScreenMatrix = this._projScreenMatrix,\n      lookTarget = this._lookTarget,\n      lightPositionWorld = this._lightPositionWorld;\n    lightPositionWorld.setFromMatrixPosition(light.matrixWorld);\n    shadowCamera.position.copy(lightPositionWorld);\n    lookTarget.setFromMatrixPosition(light.target.matrixWorld);\n    shadowCamera.lookAt(lookTarget);\n    shadowCamera.updateMatrixWorld();\n    projScreenMatrix.multiplyMatrices(shadowCamera.projectionMatrix, shadowCamera.matrixWorldInverse);\n    this._frustum.setFromProjectionMatrix(projScreenMatrix);\n    shadowMatrix.set(0.5, 0.0, 0.0, 0.5, 0.0, 0.5, 0.0, 0.5, 0.0, 0.0, 0.5, 0.5, 0.0, 0.0, 0.0, 1.0);\n    shadowMatrix.multiply(shadowCamera.projectionMatrix);\n    shadowMatrix.multiply(shadowCamera.matrixWorldInverse);\n  },\n  getViewport: function (viewportIndex) {\n    return this._viewports[viewportIndex];\n  },\n  getFrameExtents: function () {\n    return this._frameExtents;\n  },\n  copy: function (source) {\n    this.camera = source.camera.clone();\n    this.bias = source.bias;\n    this.radius = source.radius;\n    this.mapSize.copy(source.mapSize);\n    return this;\n  },\n  clone: function () {\n    return new this.constructor().copy(this);\n  },\n  toJSON: function () {\n    const object = {};\n    if (this.bias !== 0) object.bias = this.bias;\n    if (this.normalBias !== 0) object.normalBias = this.normalBias;\n    if (this.radius !== 1) object.radius = this.radius;\n    if (this.mapSize.x !== 512 || this.mapSize.y !== 512) object.mapSize = this.mapSize.toArray();\n    object.camera = this.camera.toJSON(false).object;\n    delete object.camera.matrix;\n    return object;\n  }\n});\nfunction SpotLightShadow() {\n  LightShadow.call(this, new PerspectiveCamera(50, 1, 0.5, 500));\n  this.focus = 1;\n}\nSpotLightShadow.prototype = _extends__default['default'](Object.create(LightShadow.prototype), {\n  constructor: SpotLightShadow,\n  isSpotLightShadow: true,\n  updateMatrices: function (light) {\n    const camera = this.camera;\n    const fov = MathUtils.RAD2DEG * 2 * light.angle * this.focus;\n    const aspect = this.mapSize.width / this.mapSize.height;\n    const far = light.distance || camera.far;\n    if (fov !== camera.fov || aspect !== camera.aspect || far !== camera.far) {\n      camera.fov = fov;\n      camera.aspect = aspect;\n      camera.far = far;\n      camera.updateProjectionMatrix();\n    }\n    LightShadow.prototype.updateMatrices.call(this, light);\n  }\n});\nfunction SpotLight(color, intensity, distance, angle, penumbra, decay) {\n  Light.call(this, color, intensity);\n  this.type = 'SpotLight';\n  this.position.copy(Object3D.DefaultUp);\n  this.updateMatrix();\n  this.target = new Object3D();\n  Object.defineProperty(this, 'power', {\n    get: function () {\n      // intensity = power per solid angle.\n      // ref: equation (17) from https://seblagarde.files.wordpress.com/2015/07/course_notes_moving_frostbite_to_pbr_v32.pdf\n      return this.intensity * Math.PI;\n    },\n    set: function (power) {\n      // intensity = power per solid angle.\n      // ref: equation (17) from https://seblagarde.files.wordpress.com/2015/07/course_notes_moving_frostbite_to_pbr_v32.pdf\n      this.intensity = power / Math.PI;\n    }\n  });\n  this.distance = distance !== undefined ? distance : 0;\n  this.angle = angle !== undefined ? angle : Math.PI / 3;\n  this.penumbra = penumbra !== undefined ? penumbra : 0;\n  this.decay = decay !== undefined ? decay : 1; // for physically correct lights, should be 2.\n\n  this.shadow = new SpotLightShadow();\n}\nSpotLight.prototype = _extends__default['default'](Object.create(Light.prototype), {\n  constructor: SpotLight,\n  isSpotLight: true,\n  copy: function (source) {\n    Light.prototype.copy.call(this, source);\n    this.distance = source.distance;\n    this.angle = source.angle;\n    this.penumbra = source.penumbra;\n    this.decay = source.decay;\n    this.target = source.target.clone();\n    this.shadow = source.shadow.clone();\n    return this;\n  }\n});\nfunction PointLightShadow() {\n  LightShadow.call(this, new PerspectiveCamera(90, 1, 0.5, 500));\n  this._frameExtents = new Vector2(4, 2);\n  this._viewportCount = 6;\n  this._viewports = [\n  // These viewports map a cube-map onto a 2D texture with the\n  // following orientation:\n  //\n  //  xzXZ\n  //   y Y\n  //\n  // X - Positive x direction\n  // x - Negative x direction\n  // Y - Positive y direction\n  // y - Negative y direction\n  // Z - Positive z direction\n  // z - Negative z direction\n\n  // positive X\n  new Vector4(2, 1, 1, 1),\n  // negative X\n  new Vector4(0, 1, 1, 1),\n  // positive Z\n  new Vector4(3, 1, 1, 1),\n  // negative Z\n  new Vector4(1, 1, 1, 1),\n  // positive Y\n  new Vector4(3, 0, 1, 1),\n  // negative Y\n  new Vector4(1, 0, 1, 1)];\n  this._cubeDirections = [new Vector3(1, 0, 0), new Vector3(-1, 0, 0), new Vector3(0, 0, 1), new Vector3(0, 0, -1), new Vector3(0, 1, 0), new Vector3(0, -1, 0)];\n  this._cubeUps = [new Vector3(0, 1, 0), new Vector3(0, 1, 0), new Vector3(0, 1, 0), new Vector3(0, 1, 0), new Vector3(0, 0, 1), new Vector3(0, 0, -1)];\n}\nPointLightShadow.prototype = _extends__default['default'](Object.create(LightShadow.prototype), {\n  constructor: PointLightShadow,\n  isPointLightShadow: true,\n  updateMatrices: function (light, viewportIndex = 0) {\n    const camera = this.camera,\n      shadowMatrix = this.matrix,\n      lightPositionWorld = this._lightPositionWorld,\n      lookTarget = this._lookTarget,\n      projScreenMatrix = this._projScreenMatrix;\n    lightPositionWorld.setFromMatrixPosition(light.matrixWorld);\n    camera.position.copy(lightPositionWorld);\n    lookTarget.copy(camera.position);\n    lookTarget.add(this._cubeDirections[viewportIndex]);\n    camera.up.copy(this._cubeUps[viewportIndex]);\n    camera.lookAt(lookTarget);\n    camera.updateMatrixWorld();\n    shadowMatrix.makeTranslation(-lightPositionWorld.x, -lightPositionWorld.y, -lightPositionWorld.z);\n    projScreenMatrix.multiplyMatrices(camera.projectionMatrix, camera.matrixWorldInverse);\n    this._frustum.setFromProjectionMatrix(projScreenMatrix);\n  }\n});\nfunction PointLight(color, intensity, distance, decay) {\n  Light.call(this, color, intensity);\n  this.type = 'PointLight';\n  Object.defineProperty(this, 'power', {\n    get: function () {\n      // intensity = power per solid angle.\n      // ref: equation (15) from https://seblagarde.files.wordpress.com/2015/07/course_notes_moving_frostbite_to_pbr_v32.pdf\n      return this.intensity * 4 * Math.PI;\n    },\n    set: function (power) {\n      // intensity = power per solid angle.\n      // ref: equation (15) from https://seblagarde.files.wordpress.com/2015/07/course_notes_moving_frostbite_to_pbr_v32.pdf\n      this.intensity = power / (4 * Math.PI);\n    }\n  });\n  this.distance = distance !== undefined ? distance : 0;\n  this.decay = decay !== undefined ? decay : 1; // for physically correct lights, should be 2.\n\n  this.shadow = new PointLightShadow();\n}\nPointLight.prototype = _extends__default['default'](Object.create(Light.prototype), {\n  constructor: PointLight,\n  isPointLight: true,\n  copy: function (source) {\n    Light.prototype.copy.call(this, source);\n    this.distance = source.distance;\n    this.decay = source.decay;\n    this.shadow = source.shadow.clone();\n    return this;\n  }\n});\nfunction OrthographicCamera(left = -1, right = 1, top = 1, bottom = -1, near = 0.1, far = 2000) {\n  Camera.call(this);\n  this.type = 'OrthographicCamera';\n  this.zoom = 1;\n  this.view = null;\n  this.left = left;\n  this.right = right;\n  this.top = top;\n  this.bottom = bottom;\n  this.near = near;\n  this.far = far;\n  this.updateProjectionMatrix();\n}\nOrthographicCamera.prototype = _extends__default['default'](Object.create(Camera.prototype), {\n  constructor: OrthographicCamera,\n  isOrthographicCamera: true,\n  copy: function (source, recursive) {\n    Camera.prototype.copy.call(this, source, recursive);\n    this.left = source.left;\n    this.right = source.right;\n    this.top = source.top;\n    this.bottom = source.bottom;\n    this.near = source.near;\n    this.far = source.far;\n    this.zoom = source.zoom;\n    this.view = source.view === null ? null : _extends__default['default']({}, source.view);\n    return this;\n  },\n  setViewOffset: function (fullWidth, fullHeight, x, y, width, height) {\n    if (this.view === null) {\n      this.view = {\n        enabled: true,\n        fullWidth: 1,\n        fullHeight: 1,\n        offsetX: 0,\n        offsetY: 0,\n        width: 1,\n        height: 1\n      };\n    }\n    this.view.enabled = true;\n    this.view.fullWidth = fullWidth;\n    this.view.fullHeight = fullHeight;\n    this.view.offsetX = x;\n    this.view.offsetY = y;\n    this.view.width = width;\n    this.view.height = height;\n    this.updateProjectionMatrix();\n  },\n  clearViewOffset: function () {\n    if (this.view !== null) {\n      this.view.enabled = false;\n    }\n    this.updateProjectionMatrix();\n  },\n  updateProjectionMatrix: function () {\n    const dx = (this.right - this.left) / (2 * this.zoom);\n    const dy = (this.top - this.bottom) / (2 * this.zoom);\n    const cx = (this.right + this.left) / 2;\n    const cy = (this.top + this.bottom) / 2;\n    let left = cx - dx;\n    let right = cx + dx;\n    let top = cy + dy;\n    let bottom = cy - dy;\n    if (this.view !== null && this.view.enabled) {\n      const scaleW = (this.right - this.left) / this.view.fullWidth / this.zoom;\n      const scaleH = (this.top - this.bottom) / this.view.fullHeight / this.zoom;\n      left += scaleW * this.view.offsetX;\n      right = left + scaleW * this.view.width;\n      top -= scaleH * this.view.offsetY;\n      bottom = top - scaleH * this.view.height;\n    }\n    this.projectionMatrix.makeOrthographic(left, right, top, bottom, this.near, this.far);\n    this.projectionMatrixInverse.copy(this.projectionMatrix).invert();\n  },\n  toJSON: function (meta) {\n    const data = Object3D.prototype.toJSON.call(this, meta);\n    data.object.zoom = this.zoom;\n    data.object.left = this.left;\n    data.object.right = this.right;\n    data.object.top = this.top;\n    data.object.bottom = this.bottom;\n    data.object.near = this.near;\n    data.object.far = this.far;\n    if (this.view !== null) data.object.view = _extends__default['default']({}, this.view);\n    return data;\n  }\n});\nfunction DirectionalLightShadow() {\n  LightShadow.call(this, new OrthographicCamera(-5, 5, 5, -5, 0.5, 500));\n}\nDirectionalLightShadow.prototype = _extends__default['default'](Object.create(LightShadow.prototype), {\n  constructor: DirectionalLightShadow,\n  isDirectionalLightShadow: true,\n  updateMatrices: function (light) {\n    LightShadow.prototype.updateMatrices.call(this, light);\n  }\n});\nfunction DirectionalLight(color, intensity) {\n  Light.call(this, color, intensity);\n  this.type = 'DirectionalLight';\n  this.position.copy(Object3D.DefaultUp);\n  this.updateMatrix();\n  this.target = new Object3D();\n  this.shadow = new DirectionalLightShadow();\n}\nDirectionalLight.prototype = _extends__default['default'](Object.create(Light.prototype), {\n  constructor: DirectionalLight,\n  isDirectionalLight: true,\n  copy: function (source) {\n    Light.prototype.copy.call(this, source);\n    this.target = source.target.clone();\n    this.shadow = source.shadow.clone();\n    return this;\n  }\n});\nfunction AmbientLight(color, intensity) {\n  Light.call(this, color, intensity);\n  this.type = 'AmbientLight';\n}\nAmbientLight.prototype = _extends__default['default'](Object.create(Light.prototype), {\n  constructor: AmbientLight,\n  isAmbientLight: true\n});\nfunction RectAreaLight(color, intensity, width, height) {\n  Light.call(this, color, intensity);\n  this.type = 'RectAreaLight';\n  this.width = width !== undefined ? width : 10;\n  this.height = height !== undefined ? height : 10;\n}\nRectAreaLight.prototype = _extends__default['default'](Object.create(Light.prototype), {\n  constructor: RectAreaLight,\n  isRectAreaLight: true,\n  copy: function (source) {\n    Light.prototype.copy.call(this, source);\n    this.width = source.width;\n    this.height = source.height;\n    return this;\n  },\n  toJSON: function (meta) {\n    const data = Light.prototype.toJSON.call(this, meta);\n    data.object.width = this.width;\n    data.object.height = this.height;\n    return data;\n  }\n});\n\n/**\n * Primary reference:\n *   https://graphics.stanford.edu/papers/envmap/envmap.pdf\n *\n * Secondary reference:\n *   https://www.ppsloan.org/publications/StupidSH36.pdf\n */\n\n// 3-band SH defined by 9 coefficients\n\nclass SphericalHarmonics3 {\n  constructor() {\n    Object.defineProperty(this, 'isSphericalHarmonics3', {\n      value: true\n    });\n    this.coefficients = [];\n    for (let i = 0; i < 9; i++) {\n      this.coefficients.push(new Vector3());\n    }\n  }\n  set(coefficients) {\n    for (let i = 0; i < 9; i++) {\n      this.coefficients[i].copy(coefficients[i]);\n    }\n    return this;\n  }\n  zero() {\n    for (let i = 0; i < 9; i++) {\n      this.coefficients[i].set(0, 0, 0);\n    }\n    return this;\n  }\n\n  // get the radiance in the direction of the normal\n  // target is a Vector3\n  getAt(normal, target) {\n    // normal is assumed to be unit length\n\n    const x = normal.x,\n      y = normal.y,\n      z = normal.z;\n    const coeff = this.coefficients;\n\n    // band 0\n    target.copy(coeff[0]).multiplyScalar(0.282095);\n\n    // band 1\n    target.addScaledVector(coeff[1], 0.488603 * y);\n    target.addScaledVector(coeff[2], 0.488603 * z);\n    target.addScaledVector(coeff[3], 0.488603 * x);\n\n    // band 2\n    target.addScaledVector(coeff[4], 1.092548 * (x * y));\n    target.addScaledVector(coeff[5], 1.092548 * (y * z));\n    target.addScaledVector(coeff[6], 0.315392 * (3.0 * z * z - 1.0));\n    target.addScaledVector(coeff[7], 1.092548 * (x * z));\n    target.addScaledVector(coeff[8], 0.546274 * (x * x - y * y));\n    return target;\n  }\n\n  // get the irradiance (radiance convolved with cosine lobe) in the direction of the normal\n  // target is a Vector3\n  // https://graphics.stanford.edu/papers/envmap/envmap.pdf\n  getIrradianceAt(normal, target) {\n    // normal is assumed to be unit length\n\n    const x = normal.x,\n      y = normal.y,\n      z = normal.z;\n    const coeff = this.coefficients;\n\n    // band 0\n    target.copy(coeff[0]).multiplyScalar(0.886227); // π * 0.282095\n\n    // band 1\n    target.addScaledVector(coeff[1], 2.0 * 0.511664 * y); // ( 2 * π / 3 ) * 0.488603\n    target.addScaledVector(coeff[2], 2.0 * 0.511664 * z);\n    target.addScaledVector(coeff[3], 2.0 * 0.511664 * x);\n\n    // band 2\n    target.addScaledVector(coeff[4], 2.0 * 0.429043 * x * y); // ( π / 4 ) * 1.092548\n    target.addScaledVector(coeff[5], 2.0 * 0.429043 * y * z);\n    target.addScaledVector(coeff[6], 0.743125 * z * z - 0.247708); // ( π / 4 ) * 0.315392 * 3\n    target.addScaledVector(coeff[7], 2.0 * 0.429043 * x * z);\n    target.addScaledVector(coeff[8], 0.429043 * (x * x - y * y)); // ( π / 4 ) * 0.546274\n\n    return target;\n  }\n  add(sh) {\n    for (let i = 0; i < 9; i++) {\n      this.coefficients[i].add(sh.coefficients[i]);\n    }\n    return this;\n  }\n  addScaledSH(sh, s) {\n    for (let i = 0; i < 9; i++) {\n      this.coefficients[i].addScaledVector(sh.coefficients[i], s);\n    }\n    return this;\n  }\n  scale(s) {\n    for (let i = 0; i < 9; i++) {\n      this.coefficients[i].multiplyScalar(s);\n    }\n    return this;\n  }\n  lerp(sh, alpha) {\n    for (let i = 0; i < 9; i++) {\n      this.coefficients[i].lerp(sh.coefficients[i], alpha);\n    }\n    return this;\n  }\n  equals(sh) {\n    for (let i = 0; i < 9; i++) {\n      if (!this.coefficients[i].equals(sh.coefficients[i])) {\n        return false;\n      }\n    }\n    return true;\n  }\n  copy(sh) {\n    return this.set(sh.coefficients);\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  fromArray(array, offset = 0) {\n    const coefficients = this.coefficients;\n    for (let i = 0; i < 9; i++) {\n      coefficients[i].fromArray(array, offset + i * 3);\n    }\n    return this;\n  }\n  toArray(array = [], offset = 0) {\n    const coefficients = this.coefficients;\n    for (let i = 0; i < 9; i++) {\n      coefficients[i].toArray(array, offset + i * 3);\n    }\n    return array;\n  }\n\n  // evaluate the basis functions\n  // shBasis is an Array[ 9 ]\n  static getBasisAt(normal, shBasis) {\n    // normal is assumed to be unit length\n\n    const x = normal.x,\n      y = normal.y,\n      z = normal.z;\n\n    // band 0\n    shBasis[0] = 0.282095;\n\n    // band 1\n    shBasis[1] = 0.488603 * y;\n    shBasis[2] = 0.488603 * z;\n    shBasis[3] = 0.488603 * x;\n\n    // band 2\n    shBasis[4] = 1.092548 * x * y;\n    shBasis[5] = 1.092548 * y * z;\n    shBasis[6] = 0.315392 * (3 * z * z - 1);\n    shBasis[7] = 1.092548 * x * z;\n    shBasis[8] = 0.546274 * (x * x - y * y);\n  }\n}\nfunction LightProbe(sh, intensity) {\n  Light.call(this, undefined, intensity);\n  this.type = 'LightProbe';\n  this.sh = sh !== undefined ? sh : new SphericalHarmonics3();\n}\nLightProbe.prototype = _extends__default['default'](Object.create(Light.prototype), {\n  constructor: LightProbe,\n  isLightProbe: true,\n  copy: function (source) {\n    Light.prototype.copy.call(this, source);\n    this.sh.copy(source.sh);\n    return this;\n  },\n  fromJSON: function (json) {\n    this.intensity = json.intensity; // TODO: Move this bit to Light.fromJSON();\n    this.sh.fromArray(json.sh);\n    return this;\n  },\n  toJSON: function (meta) {\n    const data = Light.prototype.toJSON.call(this, meta);\n    data.object.sh = this.sh.toArray();\n    return data;\n  }\n});\nfunction MaterialLoader(manager) {\n  Loader.call(this, manager);\n  this.textures = {};\n}\nMaterialLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: MaterialLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const scope = this;\n    const loader = new FileLoader(scope.manager);\n    loader.setPath(scope.path);\n    loader.setRequestHeader(scope.requestHeader);\n    loader.setWithCredentials(scope.withCredentials);\n    loader.load(url, function (text) {\n      try {\n        onLoad(scope.parse(JSON.parse(text)));\n      } catch (e) {\n        if (onError) {\n          onError(e);\n        } else {\n          console.error(e);\n        }\n        scope.manager.itemError(url);\n      }\n    }, onProgress, onError);\n  },\n  parse: function (json) {\n    const textures = this.textures;\n    function getTexture(name) {\n      if (textures[name] === undefined) {\n        console.warn('THREE.MaterialLoader: Undefined texture', name);\n      }\n      return textures[name];\n    }\n    const material = new Materials[json.type]();\n    if (json.uuid !== undefined) material.uuid = json.uuid;\n    if (json.name !== undefined) material.name = json.name;\n    if (json.color !== undefined && material.color !== undefined) material.color.setHex(json.color);\n    if (json.roughness !== undefined) material.roughness = json.roughness;\n    if (json.metalness !== undefined) material.metalness = json.metalness;\n    if (json.sheen !== undefined) material.sheen = new Color().setHex(json.sheen);\n    if (json.emissive !== undefined && material.emissive !== undefined) material.emissive.setHex(json.emissive);\n    if (json.specular !== undefined && material.specular !== undefined) material.specular.setHex(json.specular);\n    if (json.shininess !== undefined) material.shininess = json.shininess;\n    if (json.clearcoat !== undefined) material.clearcoat = json.clearcoat;\n    if (json.clearcoatRoughness !== undefined) material.clearcoatRoughness = json.clearcoatRoughness;\n    if (json.fog !== undefined) material.fog = json.fog;\n    if (json.flatShading !== undefined) material.flatShading = json.flatShading;\n    if (json.blending !== undefined) material.blending = json.blending;\n    if (json.combine !== undefined) material.combine = json.combine;\n    if (json.side !== undefined) material.side = json.side;\n    if (json.opacity !== undefined) material.opacity = json.opacity;\n    if (json.transparent !== undefined) material.transparent = json.transparent;\n    if (json.alphaTest !== undefined) material.alphaTest = json.alphaTest;\n    if (json.depthTest !== undefined) material.depthTest = json.depthTest;\n    if (json.depthWrite !== undefined) material.depthWrite = json.depthWrite;\n    if (json.colorWrite !== undefined) material.colorWrite = json.colorWrite;\n    if (json.stencilWrite !== undefined) material.stencilWrite = json.stencilWrite;\n    if (json.stencilWriteMask !== undefined) material.stencilWriteMask = json.stencilWriteMask;\n    if (json.stencilFunc !== undefined) material.stencilFunc = json.stencilFunc;\n    if (json.stencilRef !== undefined) material.stencilRef = json.stencilRef;\n    if (json.stencilFuncMask !== undefined) material.stencilFuncMask = json.stencilFuncMask;\n    if (json.stencilFail !== undefined) material.stencilFail = json.stencilFail;\n    if (json.stencilZFail !== undefined) material.stencilZFail = json.stencilZFail;\n    if (json.stencilZPass !== undefined) material.stencilZPass = json.stencilZPass;\n    if (json.wireframe !== undefined) material.wireframe = json.wireframe;\n    if (json.wireframeLinewidth !== undefined) material.wireframeLinewidth = json.wireframeLinewidth;\n    if (json.wireframeLinecap !== undefined) material.wireframeLinecap = json.wireframeLinecap;\n    if (json.wireframeLinejoin !== undefined) material.wireframeLinejoin = json.wireframeLinejoin;\n    if (json.rotation !== undefined) material.rotation = json.rotation;\n    if (json.linewidth !== 1) material.linewidth = json.linewidth;\n    if (json.dashSize !== undefined) material.dashSize = json.dashSize;\n    if (json.gapSize !== undefined) material.gapSize = json.gapSize;\n    if (json.scale !== undefined) material.scale = json.scale;\n    if (json.polygonOffset !== undefined) material.polygonOffset = json.polygonOffset;\n    if (json.polygonOffsetFactor !== undefined) material.polygonOffsetFactor = json.polygonOffsetFactor;\n    if (json.polygonOffsetUnits !== undefined) material.polygonOffsetUnits = json.polygonOffsetUnits;\n    if (json.skinning !== undefined) material.skinning = json.skinning;\n    if (json.morphTargets !== undefined) material.morphTargets = json.morphTargets;\n    if (json.morphNormals !== undefined) material.morphNormals = json.morphNormals;\n    if (json.dithering !== undefined) material.dithering = json.dithering;\n    if (json.vertexTangents !== undefined) material.vertexTangents = json.vertexTangents;\n    if (json.visible !== undefined) material.visible = json.visible;\n    if (json.toneMapped !== undefined) material.toneMapped = json.toneMapped;\n    if (json.userData !== undefined) material.userData = json.userData;\n    if (json.vertexColors !== undefined) {\n      if (typeof json.vertexColors === 'number') {\n        material.vertexColors = json.vertexColors > 0 ? true : false;\n      } else {\n        material.vertexColors = json.vertexColors;\n      }\n    }\n\n    // Shader Material\n\n    if (json.uniforms !== undefined) {\n      for (const name in json.uniforms) {\n        const uniform = json.uniforms[name];\n        material.uniforms[name] = {};\n        switch (uniform.type) {\n          case 't':\n            material.uniforms[name].value = getTexture(uniform.value);\n            break;\n          case 'c':\n            material.uniforms[name].value = new Color().setHex(uniform.value);\n            break;\n          case 'v2':\n            material.uniforms[name].value = new Vector2().fromArray(uniform.value);\n            break;\n          case 'v3':\n            material.uniforms[name].value = new Vector3().fromArray(uniform.value);\n            break;\n          case 'v4':\n            material.uniforms[name].value = new Vector4().fromArray(uniform.value);\n            break;\n          case 'm3':\n            material.uniforms[name].value = new Matrix3().fromArray(uniform.value);\n            break;\n          case 'm4':\n            material.uniforms[name].value = new Matrix4().fromArray(uniform.value);\n            break;\n          default:\n            material.uniforms[name].value = uniform.value;\n        }\n      }\n    }\n    if (json.defines !== undefined) material.defines = json.defines;\n    if (json.vertexShader !== undefined) material.vertexShader = json.vertexShader;\n    if (json.fragmentShader !== undefined) material.fragmentShader = json.fragmentShader;\n    if (json.extensions !== undefined) {\n      for (const key in json.extensions) {\n        material.extensions[key] = json.extensions[key];\n      }\n    }\n\n    // Deprecated\n\n    if (json.shading !== undefined) material.flatShading = json.shading === 1; // THREE.FlatShading\n\n    // for PointsMaterial\n\n    if (json.size !== undefined) material.size = json.size;\n    if (json.sizeAttenuation !== undefined) material.sizeAttenuation = json.sizeAttenuation;\n\n    // maps\n\n    if (json.map !== undefined) material.map = getTexture(json.map);\n    if (json.matcap !== undefined) material.matcap = getTexture(json.matcap);\n    if (json.alphaMap !== undefined) material.alphaMap = getTexture(json.alphaMap);\n    if (json.bumpMap !== undefined) material.bumpMap = getTexture(json.bumpMap);\n    if (json.bumpScale !== undefined) material.bumpScale = json.bumpScale;\n    if (json.normalMap !== undefined) material.normalMap = getTexture(json.normalMap);\n    if (json.normalMapType !== undefined) material.normalMapType = json.normalMapType;\n    if (json.normalScale !== undefined) {\n      let normalScale = json.normalScale;\n      if (Array.isArray(normalScale) === false) {\n        // Blender exporter used to export a scalar. See #7459\n\n        normalScale = [normalScale, normalScale];\n      }\n      material.normalScale = new Vector2().fromArray(normalScale);\n    }\n    if (json.displacementMap !== undefined) material.displacementMap = getTexture(json.displacementMap);\n    if (json.displacementScale !== undefined) material.displacementScale = json.displacementScale;\n    if (json.displacementBias !== undefined) material.displacementBias = json.displacementBias;\n    if (json.roughnessMap !== undefined) material.roughnessMap = getTexture(json.roughnessMap);\n    if (json.metalnessMap !== undefined) material.metalnessMap = getTexture(json.metalnessMap);\n    if (json.emissiveMap !== undefined) material.emissiveMap = getTexture(json.emissiveMap);\n    if (json.emissiveIntensity !== undefined) material.emissiveIntensity = json.emissiveIntensity;\n    if (json.specularMap !== undefined) material.specularMap = getTexture(json.specularMap);\n    if (json.envMap !== undefined) material.envMap = getTexture(json.envMap);\n    if (json.envMapIntensity !== undefined) material.envMapIntensity = json.envMapIntensity;\n    if (json.reflectivity !== undefined) material.reflectivity = json.reflectivity;\n    if (json.refractionRatio !== undefined) material.refractionRatio = json.refractionRatio;\n    if (json.lightMap !== undefined) material.lightMap = getTexture(json.lightMap);\n    if (json.lightMapIntensity !== undefined) material.lightMapIntensity = json.lightMapIntensity;\n    if (json.aoMap !== undefined) material.aoMap = getTexture(json.aoMap);\n    if (json.aoMapIntensity !== undefined) material.aoMapIntensity = json.aoMapIntensity;\n    if (json.gradientMap !== undefined) material.gradientMap = getTexture(json.gradientMap);\n    if (json.clearcoatMap !== undefined) material.clearcoatMap = getTexture(json.clearcoatMap);\n    if (json.clearcoatRoughnessMap !== undefined) material.clearcoatRoughnessMap = getTexture(json.clearcoatRoughnessMap);\n    if (json.clearcoatNormalMap !== undefined) material.clearcoatNormalMap = getTexture(json.clearcoatNormalMap);\n    if (json.clearcoatNormalScale !== undefined) material.clearcoatNormalScale = new Vector2().fromArray(json.clearcoatNormalScale);\n    if (json.transmission !== undefined) material.transmission = json.transmission;\n    if (json.transmissionMap !== undefined) material.transmissionMap = getTexture(json.transmissionMap);\n    return material;\n  },\n  setTextures: function (value) {\n    this.textures = value;\n    return this;\n  }\n});\nconst LoaderUtils = {\n  decodeText: function (array) {\n    if (typeof TextDecoder !== 'undefined') {\n      return new TextDecoder().decode(array);\n    }\n\n    // Avoid the String.fromCharCode.apply(null, array) shortcut, which\n    // throws a \"maximum call stack size exceeded\" error for large arrays.\n\n    let s = '';\n    for (let i = 0, il = array.length; i < il; i++) {\n      // Implicitly assumes little-endian.\n      s += String.fromCharCode(array[i]);\n    }\n    try {\n      // merges multi-byte utf-8 characters.\n\n      return decodeURIComponent(escape(s));\n    } catch (e) {\n      // see #16358\n\n      return s;\n    }\n  },\n  extractUrlBase: function (url) {\n    const index = url.lastIndexOf('/');\n    if (index === -1) return './';\n    return url.substr(0, index + 1);\n  }\n};\nfunction InstancedBufferGeometry() {\n  BufferGeometry.call(this);\n  this.type = 'InstancedBufferGeometry';\n  this.instanceCount = Infinity;\n}\nInstancedBufferGeometry.prototype = _extends__default['default'](Object.create(BufferGeometry.prototype), {\n  constructor: InstancedBufferGeometry,\n  isInstancedBufferGeometry: true,\n  copy: function (source) {\n    BufferGeometry.prototype.copy.call(this, source);\n    this.instanceCount = source.instanceCount;\n    return this;\n  },\n  clone: function () {\n    return new this.constructor().copy(this);\n  },\n  toJSON: function () {\n    const data = BufferGeometry.prototype.toJSON.call(this);\n    data.instanceCount = this.instanceCount;\n    data.isInstancedBufferGeometry = true;\n    return data;\n  }\n});\nfunction InstancedBufferAttribute(array, itemSize, normalized, meshPerAttribute) {\n  if (typeof normalized === 'number') {\n    meshPerAttribute = normalized;\n    normalized = false;\n    console.error('THREE.InstancedBufferAttribute: The constructor now expects normalized as the third argument.');\n  }\n  BufferAttribute.call(this, array, itemSize, normalized);\n  this.meshPerAttribute = meshPerAttribute || 1;\n}\nInstancedBufferAttribute.prototype = _extends__default['default'](Object.create(BufferAttribute.prototype), {\n  constructor: InstancedBufferAttribute,\n  isInstancedBufferAttribute: true,\n  copy: function (source) {\n    BufferAttribute.prototype.copy.call(this, source);\n    this.meshPerAttribute = source.meshPerAttribute;\n    return this;\n  },\n  toJSON: function () {\n    const data = BufferAttribute.prototype.toJSON.call(this);\n    data.meshPerAttribute = this.meshPerAttribute;\n    data.isInstancedBufferAttribute = true;\n    return data;\n  }\n});\nfunction BufferGeometryLoader(manager) {\n  Loader.call(this, manager);\n}\nBufferGeometryLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: BufferGeometryLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const scope = this;\n    const loader = new FileLoader(scope.manager);\n    loader.setPath(scope.path);\n    loader.setRequestHeader(scope.requestHeader);\n    loader.setWithCredentials(scope.withCredentials);\n    loader.load(url, function (text) {\n      try {\n        onLoad(scope.parse(JSON.parse(text)));\n      } catch (e) {\n        if (onError) {\n          onError(e);\n        } else {\n          console.error(e);\n        }\n        scope.manager.itemError(url);\n      }\n    }, onProgress, onError);\n  },\n  parse: function (json) {\n    const interleavedBufferMap = {};\n    const arrayBufferMap = {};\n    function getInterleavedBuffer(json, uuid) {\n      if (interleavedBufferMap[uuid] !== undefined) return interleavedBufferMap[uuid];\n      const interleavedBuffers = json.interleavedBuffers;\n      const interleavedBuffer = interleavedBuffers[uuid];\n      const buffer = getArrayBuffer(json, interleavedBuffer.buffer);\n      const array = getTypedArray(interleavedBuffer.type, buffer);\n      const ib = new InterleavedBuffer(array, interleavedBuffer.stride);\n      ib.uuid = interleavedBuffer.uuid;\n      interleavedBufferMap[uuid] = ib;\n      return ib;\n    }\n    function getArrayBuffer(json, uuid) {\n      if (arrayBufferMap[uuid] !== undefined) return arrayBufferMap[uuid];\n      const arrayBuffers = json.arrayBuffers;\n      const arrayBuffer = arrayBuffers[uuid];\n      const ab = new Uint32Array(arrayBuffer).buffer;\n      arrayBufferMap[uuid] = ab;\n      return ab;\n    }\n    const geometry = json.isInstancedBufferGeometry ? new InstancedBufferGeometry() : new BufferGeometry();\n    const index = json.data.index;\n    if (index !== undefined) {\n      const typedArray = getTypedArray(index.type, index.array);\n      geometry.setIndex(new BufferAttribute(typedArray, 1));\n    }\n    const attributes = json.data.attributes;\n    for (const key in attributes) {\n      const attribute = attributes[key];\n      let bufferAttribute;\n      if (attribute.isInterleavedBufferAttribute) {\n        const interleavedBuffer = getInterleavedBuffer(json.data, attribute.data);\n        bufferAttribute = new InterleavedBufferAttribute(interleavedBuffer, attribute.itemSize, attribute.offset, attribute.normalized);\n      } else {\n        const typedArray = getTypedArray(attribute.type, attribute.array);\n        const bufferAttributeConstr = attribute.isInstancedBufferAttribute ? InstancedBufferAttribute : BufferAttribute;\n        bufferAttribute = new bufferAttributeConstr(typedArray, attribute.itemSize, attribute.normalized);\n      }\n      if (attribute.name !== undefined) bufferAttribute.name = attribute.name;\n      geometry.setAttribute(key, bufferAttribute);\n    }\n    const morphAttributes = json.data.morphAttributes;\n    if (morphAttributes) {\n      for (const key in morphAttributes) {\n        const attributeArray = morphAttributes[key];\n        const array = [];\n        for (let i = 0, il = attributeArray.length; i < il; i++) {\n          const attribute = attributeArray[i];\n          let bufferAttribute;\n          if (attribute.isInterleavedBufferAttribute) {\n            const interleavedBuffer = getInterleavedBuffer(json.data, attribute.data);\n            bufferAttribute = new InterleavedBufferAttribute(interleavedBuffer, attribute.itemSize, attribute.offset, attribute.normalized);\n          } else {\n            const typedArray = getTypedArray(attribute.type, attribute.array);\n            bufferAttribute = new BufferAttribute(typedArray, attribute.itemSize, attribute.normalized);\n          }\n          if (attribute.name !== undefined) bufferAttribute.name = attribute.name;\n          array.push(bufferAttribute);\n        }\n        geometry.morphAttributes[key] = array;\n      }\n    }\n    const morphTargetsRelative = json.data.morphTargetsRelative;\n    if (morphTargetsRelative) {\n      geometry.morphTargetsRelative = true;\n    }\n    const groups = json.data.groups || json.data.drawcalls || json.data.offsets;\n    if (groups !== undefined) {\n      for (let i = 0, n = groups.length; i !== n; ++i) {\n        const group = groups[i];\n        geometry.addGroup(group.start, group.count, group.materialIndex);\n      }\n    }\n    const boundingSphere = json.data.boundingSphere;\n    if (boundingSphere !== undefined) {\n      const center = new Vector3();\n      if (boundingSphere.center !== undefined) {\n        center.fromArray(boundingSphere.center);\n      }\n      geometry.boundingSphere = new Sphere(center, boundingSphere.radius);\n    }\n    if (json.name) geometry.name = json.name;\n    if (json.userData) geometry.userData = json.userData;\n    return geometry;\n  }\n});\nfunction ImageBitmapLoader(manager) {\n  if (typeof createImageBitmap === 'undefined') {\n    console.warn('THREE.ImageBitmapLoader: createImageBitmap() not supported.');\n  }\n  if (typeof fetch === 'undefined') {\n    console.warn('THREE.ImageBitmapLoader: fetch() not supported.');\n  }\n  Loader.call(this, manager);\n  this.options = {\n    premultiplyAlpha: 'none'\n  };\n}\nImageBitmapLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: ImageBitmapLoader,\n  isImageBitmapLoader: true,\n  setOptions: function setOptions(options) {\n    this.options = options;\n    return this;\n  },\n  load: function (url, onLoad, onProgress, onError) {\n    if (url === undefined) url = '';\n    if (this.path !== undefined) url = this.path + url;\n    url = this.manager.resolveURL(url);\n    const scope = this;\n    const cached = Cache.get(url);\n    if (cached !== undefined) {\n      scope.manager.itemStart(url);\n      setTimeout(function () {\n        if (onLoad) onLoad(cached);\n        scope.manager.itemEnd(url);\n      }, 0);\n      return cached;\n    }\n    const fetchOptions = {};\n    fetchOptions.credentials = this.crossOrigin === 'anonymous' ? 'same-origin' : 'include';\n    fetch(url, fetchOptions).then(function (res) {\n      return res.blob();\n    }).then(function (blob) {\n      return createImageBitmap(blob, scope.options);\n    }).then(function (imageBitmap) {\n      Cache.add(url, imageBitmap);\n      if (onLoad) onLoad(imageBitmap);\n      scope.manager.itemEnd(url);\n    }).catch(function (e) {\n      if (onError) onError(e);\n      scope.manager.itemError(url);\n      scope.manager.itemEnd(url);\n    });\n    scope.manager.itemStart(url);\n  }\n});\nfunction ShapePath() {\n  this.type = 'ShapePath';\n  this.color = new Color();\n  this.subPaths = [];\n  this.currentPath = null;\n}\n_extends__default['default'](ShapePath.prototype, {\n  moveTo: function (x, y) {\n    this.currentPath = new Path();\n    this.subPaths.push(this.currentPath);\n    this.currentPath.moveTo(x, y);\n    return this;\n  },\n  lineTo: function (x, y) {\n    this.currentPath.lineTo(x, y);\n    return this;\n  },\n  quadraticCurveTo: function (aCPx, aCPy, aX, aY) {\n    this.currentPath.quadraticCurveTo(aCPx, aCPy, aX, aY);\n    return this;\n  },\n  bezierCurveTo: function (aCP1x, aCP1y, aCP2x, aCP2y, aX, aY) {\n    this.currentPath.bezierCurveTo(aCP1x, aCP1y, aCP2x, aCP2y, aX, aY);\n    return this;\n  },\n  splineThru: function (pts) {\n    this.currentPath.splineThru(pts);\n    return this;\n  },\n  toShapes: function (isCCW, noHoles) {\n    function toShapesNoHoles(inSubpaths) {\n      const shapes = [];\n      for (let i = 0, l = inSubpaths.length; i < l; i++) {\n        const tmpPath = inSubpaths[i];\n        const tmpShape = new Shape();\n        tmpShape.curves = tmpPath.curves;\n        shapes.push(tmpShape);\n      }\n      return shapes;\n    }\n    function isPointInsidePolygon(inPt, inPolygon) {\n      const polyLen = inPolygon.length;\n\n      // inPt on polygon contour => immediate success    or\n      // toggling of inside/outside at every single! intersection point of an edge\n      //  with the horizontal line through inPt, left of inPt\n      //  not counting lowerY endpoints of edges and whole edges on that line\n      let inside = false;\n      for (let p = polyLen - 1, q = 0; q < polyLen; p = q++) {\n        let edgeLowPt = inPolygon[p];\n        let edgeHighPt = inPolygon[q];\n        let edgeDx = edgeHighPt.x - edgeLowPt.x;\n        let edgeDy = edgeHighPt.y - edgeLowPt.y;\n        if (Math.abs(edgeDy) > Number.EPSILON) {\n          // not parallel\n          if (edgeDy < 0) {\n            edgeLowPt = inPolygon[q];\n            edgeDx = -edgeDx;\n            edgeHighPt = inPolygon[p];\n            edgeDy = -edgeDy;\n          }\n          if (inPt.y < edgeLowPt.y || inPt.y > edgeHighPt.y) continue;\n          if (inPt.y === edgeLowPt.y) {\n            if (inPt.x === edgeLowPt.x) return true; // inPt is on contour ?\n            // continue;\t\t\t\t// no intersection or edgeLowPt => doesn't count !!!\n          } else {\n            const perpEdge = edgeDy * (inPt.x - edgeLowPt.x) - edgeDx * (inPt.y - edgeLowPt.y);\n            if (perpEdge === 0) return true; // inPt is on contour ?\n            if (perpEdge < 0) continue;\n            inside = !inside; // true intersection left of inPt\n          }\n        } else {\n          // parallel or collinear\n          if (inPt.y !== edgeLowPt.y) continue; // parallel\n          // edge lies on the same horizontal line as inPt\n          if (edgeHighPt.x <= inPt.x && inPt.x <= edgeLowPt.x || edgeLowPt.x <= inPt.x && inPt.x <= edgeHighPt.x) return true; // inPt: Point on contour !\n          // continue;\n        }\n      }\n\n      return inside;\n    }\n    const isClockWise = ShapeUtils.isClockWise;\n    const subPaths = this.subPaths;\n    if (subPaths.length === 0) return [];\n    if (noHoles === true) return toShapesNoHoles(subPaths);\n    let solid, tmpPath, tmpShape;\n    const shapes = [];\n    if (subPaths.length === 1) {\n      tmpPath = subPaths[0];\n      tmpShape = new Shape();\n      tmpShape.curves = tmpPath.curves;\n      shapes.push(tmpShape);\n      return shapes;\n    }\n    let holesFirst = !isClockWise(subPaths[0].getPoints());\n    holesFirst = isCCW ? !holesFirst : holesFirst;\n\n    // console.log(\"Holes first\", holesFirst);\n\n    const betterShapeHoles = [];\n    const newShapes = [];\n    let newShapeHoles = [];\n    let mainIdx = 0;\n    let tmpPoints;\n    newShapes[mainIdx] = undefined;\n    newShapeHoles[mainIdx] = [];\n    for (let i = 0, l = subPaths.length; i < l; i++) {\n      tmpPath = subPaths[i];\n      tmpPoints = tmpPath.getPoints();\n      solid = isClockWise(tmpPoints);\n      solid = isCCW ? !solid : solid;\n      if (solid) {\n        if (!holesFirst && newShapes[mainIdx]) mainIdx++;\n        newShapes[mainIdx] = {\n          s: new Shape(),\n          p: tmpPoints\n        };\n        newShapes[mainIdx].s.curves = tmpPath.curves;\n        if (holesFirst) mainIdx++;\n        newShapeHoles[mainIdx] = [];\n\n        //console.log('cw', i);\n      } else {\n        newShapeHoles[mainIdx].push({\n          h: tmpPath,\n          p: tmpPoints[0]\n        });\n\n        //console.log('ccw', i);\n      }\n    }\n\n    // only Holes? -> probably all Shapes with wrong orientation\n    if (!newShapes[0]) return toShapesNoHoles(subPaths);\n    if (newShapes.length > 1) {\n      let ambiguous = false;\n      const toChange = [];\n      for (let sIdx = 0, sLen = newShapes.length; sIdx < sLen; sIdx++) {\n        betterShapeHoles[sIdx] = [];\n      }\n      for (let sIdx = 0, sLen = newShapes.length; sIdx < sLen; sIdx++) {\n        const sho = newShapeHoles[sIdx];\n        for (let hIdx = 0; hIdx < sho.length; hIdx++) {\n          const ho = sho[hIdx];\n          let hole_unassigned = true;\n          for (let s2Idx = 0; s2Idx < newShapes.length; s2Idx++) {\n            if (isPointInsidePolygon(ho.p, newShapes[s2Idx].p)) {\n              if (sIdx !== s2Idx) toChange.push({\n                froms: sIdx,\n                tos: s2Idx,\n                hole: hIdx\n              });\n              if (hole_unassigned) {\n                hole_unassigned = false;\n                betterShapeHoles[s2Idx].push(ho);\n              } else {\n                ambiguous = true;\n              }\n            }\n          }\n          if (hole_unassigned) {\n            betterShapeHoles[sIdx].push(ho);\n          }\n        }\n      }\n      // console.log(\"ambiguous: \", ambiguous);\n\n      if (toChange.length > 0) {\n        // console.log(\"to change: \", toChange);\n        if (!ambiguous) newShapeHoles = betterShapeHoles;\n      }\n    }\n    let tmpHoles;\n    for (let i = 0, il = newShapes.length; i < il; i++) {\n      tmpShape = newShapes[i].s;\n      shapes.push(tmpShape);\n      tmpHoles = newShapeHoles[i];\n      for (let j = 0, jl = tmpHoles.length; j < jl; j++) {\n        tmpShape.holes.push(tmpHoles[j].h);\n      }\n    }\n\n    //console.log(\"shape\", shapes);\n\n    return shapes;\n  }\n});\nclass Font {\n  constructor(data) {\n    Object.defineProperty(this, 'isFont', {\n      value: true\n    });\n    this.type = 'Font';\n    this.data = data;\n  }\n  generateShapes(text, size = 100) {\n    const shapes = [];\n    const paths = createPaths(text, size, this.data);\n    for (let p = 0, pl = paths.length; p < pl; p++) {\n      Array.prototype.push.apply(shapes, paths[p].toShapes());\n    }\n    return shapes;\n  }\n}\nfunction createPaths(text, size, data) {\n  const chars = Array.from ? Array.from(text) : String(text).split(''); // workaround for IE11, see #13988\n  const scale = size / data.resolution;\n  const line_height = (data.boundingBox.yMax - data.boundingBox.yMin + data.underlineThickness) * scale;\n  const paths = [];\n  let offsetX = 0,\n    offsetY = 0;\n  for (let i = 0; i < chars.length; i++) {\n    const char = chars[i];\n    if (char === '\\n') {\n      offsetX = 0;\n      offsetY -= line_height;\n    } else {\n      const ret = createPath(char, scale, offsetX, offsetY, data);\n      offsetX += ret.offsetX;\n      paths.push(ret.path);\n    }\n  }\n  return paths;\n}\nfunction createPath(char, scale, offsetX, offsetY, data) {\n  const glyph = data.glyphs[char] || data.glyphs['?'];\n  if (!glyph) {\n    console.error('THREE.Font: character \"' + char + '\" does not exists in font family ' + data.familyName + '.');\n    return;\n  }\n  const path = new ShapePath();\n  let x, y, cpx, cpy, cpx1, cpy1, cpx2, cpy2;\n  if (glyph.o) {\n    const outline = glyph._cachedOutline || (glyph._cachedOutline = glyph.o.split(' '));\n    for (let i = 0, l = outline.length; i < l;) {\n      const action = outline[i++];\n      switch (action) {\n        case 'm':\n          // moveTo\n\n          x = outline[i++] * scale + offsetX;\n          y = outline[i++] * scale + offsetY;\n          path.moveTo(x, y);\n          break;\n        case 'l':\n          // lineTo\n\n          x = outline[i++] * scale + offsetX;\n          y = outline[i++] * scale + offsetY;\n          path.lineTo(x, y);\n          break;\n        case 'q':\n          // quadraticCurveTo\n\n          cpx = outline[i++] * scale + offsetX;\n          cpy = outline[i++] * scale + offsetY;\n          cpx1 = outline[i++] * scale + offsetX;\n          cpy1 = outline[i++] * scale + offsetY;\n          path.quadraticCurveTo(cpx1, cpy1, cpx, cpy);\n          break;\n        case 'b':\n          // bezierCurveTo\n\n          cpx = outline[i++] * scale + offsetX;\n          cpy = outline[i++] * scale + offsetY;\n          cpx1 = outline[i++] * scale + offsetX;\n          cpy1 = outline[i++] * scale + offsetY;\n          cpx2 = outline[i++] * scale + offsetX;\n          cpy2 = outline[i++] * scale + offsetY;\n          path.bezierCurveTo(cpx1, cpy1, cpx2, cpy2, cpx, cpy);\n          break;\n      }\n    }\n  }\n  return {\n    offsetX: glyph.ha * scale,\n    path: path\n  };\n}\nfunction FontLoader(manager) {\n  Loader.call(this, manager);\n}\nFontLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: FontLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const scope = this;\n    const loader = new FileLoader(this.manager);\n    loader.setPath(this.path);\n    loader.setRequestHeader(this.requestHeader);\n    loader.setWithCredentials(scope.withCredentials);\n    loader.load(url, function (text) {\n      let json;\n      try {\n        json = JSON.parse(text);\n      } catch (e) {\n        console.warn('THREE.FontLoader: typeface.js support is being deprecated. Use typeface.json instead.');\n        json = JSON.parse(text.substring(65, text.length - 2));\n      }\n      const font = scope.parse(json);\n      if (onLoad) onLoad(font);\n    }, onProgress, onError);\n  },\n  parse: function (json) {\n    return new Font(json);\n  }\n});\nlet _context;\nconst AudioContext = {\n  getContext: function () {\n    if (_context === undefined) {\n      _context = new (window.AudioContext || window.webkitAudioContext)();\n    }\n    return _context;\n  },\n  setContext: function (value) {\n    _context = value;\n  }\n};\nfunction AudioLoader(manager) {\n  Loader.call(this, manager);\n}\nAudioLoader.prototype = _extends__default['default'](Object.create(Loader.prototype), {\n  constructor: AudioLoader,\n  load: function (url, onLoad, onProgress, onError) {\n    const scope = this;\n    const loader = new FileLoader(scope.manager);\n    loader.setResponseType('arraybuffer');\n    loader.setPath(scope.path);\n    loader.setRequestHeader(scope.requestHeader);\n    loader.setWithCredentials(scope.withCredentials);\n    loader.load(url, function (buffer) {\n      try {\n        // Create a copy of the buffer. The `decodeAudioData` method\n        // detaches the buffer when complete, preventing reuse.\n        const bufferCopy = buffer.slice(0);\n        const context = AudioContext.getContext();\n        context.decodeAudioData(bufferCopy, function (audioBuffer) {\n          onLoad(audioBuffer);\n        });\n      } catch (e) {\n        if (onError) {\n          onError(e);\n        } else {\n          console.error(e);\n        }\n        scope.manager.itemError(url);\n      }\n    }, onProgress, onError);\n  }\n});\nfunction HemisphereLightProbe(skyColor, groundColor, intensity) {\n  LightProbe.call(this, undefined, intensity);\n  const color1 = new Color().set(skyColor);\n  const color2 = new Color().set(groundColor);\n  const sky = new Vector3(color1.r, color1.g, color1.b);\n  const ground = new Vector3(color2.r, color2.g, color2.b);\n\n  // without extra factor of PI in the shader, should = 1 / Math.sqrt( Math.PI );\n  const c0 = Math.sqrt(Math.PI);\n  const c1 = c0 * Math.sqrt(0.75);\n  this.sh.coefficients[0].copy(sky).add(ground).multiplyScalar(c0);\n  this.sh.coefficients[1].copy(sky).sub(ground).multiplyScalar(c1);\n}\nHemisphereLightProbe.prototype = _extends__default['default'](Object.create(LightProbe.prototype), {\n  constructor: HemisphereLightProbe,\n  isHemisphereLightProbe: true,\n  copy: function (source) {\n    // modifying colors not currently supported\n\n    LightProbe.prototype.copy.call(this, source);\n    return this;\n  },\n  toJSON: function (meta) {\n    const data = LightProbe.prototype.toJSON.call(this, meta);\n\n    // data.sh = this.sh.toArray(); // todo\n\n    return data;\n  }\n});\nfunction AmbientLightProbe(color, intensity) {\n  LightProbe.call(this, undefined, intensity);\n  const color1 = new Color().set(color);\n\n  // without extra factor of PI in the shader, would be 2 / Math.sqrt( Math.PI );\n  this.sh.coefficients[0].set(color1.r, color1.g, color1.b).multiplyScalar(2 * Math.sqrt(Math.PI));\n}\nAmbientLightProbe.prototype = _extends__default['default'](Object.create(LightProbe.prototype), {\n  constructor: AmbientLightProbe,\n  isAmbientLightProbe: true,\n  copy: function (source) {\n    // modifying color not currently supported\n\n    LightProbe.prototype.copy.call(this, source);\n    return this;\n  },\n  toJSON: function (meta) {\n    const data = LightProbe.prototype.toJSON.call(this, meta);\n\n    // data.sh = this.sh.toArray(); // todo\n\n    return data;\n  }\n});\nconst _eyeRight = new Matrix4();\nconst _eyeLeft = new Matrix4();\nfunction StereoCamera() {\n  this.type = 'StereoCamera';\n  this.aspect = 1;\n  this.eyeSep = 0.064;\n  this.cameraL = new PerspectiveCamera();\n  this.cameraL.layers.enable(1);\n  this.cameraL.matrixAutoUpdate = false;\n  this.cameraR = new PerspectiveCamera();\n  this.cameraR.layers.enable(2);\n  this.cameraR.matrixAutoUpdate = false;\n  this._cache = {\n    focus: null,\n    fov: null,\n    aspect: null,\n    near: null,\n    far: null,\n    zoom: null,\n    eyeSep: null\n  };\n}\n_extends__default['default'](StereoCamera.prototype, {\n  update: function (camera) {\n    const cache = this._cache;\n    const needsUpdate = cache.focus !== camera.focus || cache.fov !== camera.fov || cache.aspect !== camera.aspect * this.aspect || cache.near !== camera.near || cache.far !== camera.far || cache.zoom !== camera.zoom || cache.eyeSep !== this.eyeSep;\n    if (needsUpdate) {\n      cache.focus = camera.focus;\n      cache.fov = camera.fov;\n      cache.aspect = camera.aspect * this.aspect;\n      cache.near = camera.near;\n      cache.far = camera.far;\n      cache.zoom = camera.zoom;\n      cache.eyeSep = this.eyeSep;\n\n      // Off-axis stereoscopic effect based on\n      // http://paulbourke.net/stereographics/stereorender/\n\n      const projectionMatrix = camera.projectionMatrix.clone();\n      const eyeSepHalf = cache.eyeSep / 2;\n      const eyeSepOnProjection = eyeSepHalf * cache.near / cache.focus;\n      const ymax = cache.near * Math.tan(MathUtils.DEG2RAD * cache.fov * 0.5) / cache.zoom;\n      let xmin, xmax;\n\n      // translate xOffset\n\n      _eyeLeft.elements[12] = -eyeSepHalf;\n      _eyeRight.elements[12] = eyeSepHalf;\n\n      // for left eye\n\n      xmin = -ymax * cache.aspect + eyeSepOnProjection;\n      xmax = ymax * cache.aspect + eyeSepOnProjection;\n      projectionMatrix.elements[0] = 2 * cache.near / (xmax - xmin);\n      projectionMatrix.elements[8] = (xmax + xmin) / (xmax - xmin);\n      this.cameraL.projectionMatrix.copy(projectionMatrix);\n\n      // for right eye\n\n      xmin = -ymax * cache.aspect - eyeSepOnProjection;\n      xmax = ymax * cache.aspect - eyeSepOnProjection;\n      projectionMatrix.elements[0] = 2 * cache.near / (xmax - xmin);\n      projectionMatrix.elements[8] = (xmax + xmin) / (xmax - xmin);\n      this.cameraR.projectionMatrix.copy(projectionMatrix);\n    }\n    this.cameraL.matrixWorld.copy(camera.matrixWorld).multiply(_eyeLeft);\n    this.cameraR.matrixWorld.copy(camera.matrixWorld).multiply(_eyeRight);\n  }\n});\nclass Audio extends Object3D {\n  constructor(listener) {\n    super();\n    this.type = 'Audio';\n    this.listener = listener;\n    this.context = listener.context;\n    this.gain = this.context.createGain();\n    this.gain.connect(listener.getInput());\n    this.autoplay = false;\n    this.buffer = null;\n    this.detune = 0;\n    this.loop = false;\n    this.loopStart = 0;\n    this.loopEnd = 0;\n    this.offset = 0;\n    this.duration = undefined;\n    this.playbackRate = 1;\n    this.isPlaying = false;\n    this.hasPlaybackControl = true;\n    this.source = null;\n    this.sourceType = 'empty';\n    this._startedAt = 0;\n    this._progress = 0;\n    this._connected = false;\n    this.filters = [];\n  }\n  getOutput() {\n    return this.gain;\n  }\n  setNodeSource(audioNode) {\n    this.hasPlaybackControl = false;\n    this.sourceType = 'audioNode';\n    this.source = audioNode;\n    this.connect();\n    return this;\n  }\n  setMediaElementSource(mediaElement) {\n    this.hasPlaybackControl = false;\n    this.sourceType = 'mediaNode';\n    this.source = this.context.createMediaElementSource(mediaElement);\n    this.connect();\n    return this;\n  }\n  setMediaStreamSource(mediaStream) {\n    this.hasPlaybackControl = false;\n    this.sourceType = 'mediaStreamNode';\n    this.source = this.context.createMediaStreamSource(mediaStream);\n    this.connect();\n    return this;\n  }\n  setBuffer(audioBuffer) {\n    this.buffer = audioBuffer;\n    this.sourceType = 'buffer';\n    if (this.autoplay) this.play();\n    return this;\n  }\n  play(delay = 0) {\n    if (this.isPlaying === true) {\n      console.warn('THREE.Audio: Audio is already playing.');\n      return;\n    }\n    if (this.hasPlaybackControl === false) {\n      console.warn('THREE.Audio: this Audio has no playback control.');\n      return;\n    }\n    this._startedAt = this.context.currentTime + delay;\n    const source = this.context.createBufferSource();\n    source.buffer = this.buffer;\n    source.loop = this.loop;\n    source.loopStart = this.loopStart;\n    source.loopEnd = this.loopEnd;\n    source.onended = this.onEnded.bind(this);\n    source.start(this._startedAt, this._progress + this.offset, this.duration);\n    this.isPlaying = true;\n    this.source = source;\n    this.setDetune(this.detune);\n    this.setPlaybackRate(this.playbackRate);\n    return this.connect();\n  }\n  pause() {\n    if (this.hasPlaybackControl === false) {\n      console.warn('THREE.Audio: this Audio has no playback control.');\n      return;\n    }\n    if (this.isPlaying === true) {\n      // update current progress\n\n      this._progress += Math.max(this.context.currentTime - this._startedAt, 0) * this.playbackRate;\n      if (this.loop === true) {\n        // ensure _progress does not exceed duration with looped audios\n\n        this._progress = this._progress % (this.duration || this.buffer.duration);\n      }\n      this.source.stop();\n      this.source.onended = null;\n      this.isPlaying = false;\n    }\n    return this;\n  }\n  stop() {\n    if (this.hasPlaybackControl === false) {\n      console.warn('THREE.Audio: this Audio has no playback control.');\n      return;\n    }\n    this._progress = 0;\n    this.source.stop();\n    this.source.onended = null;\n    this.isPlaying = false;\n    return this;\n  }\n  connect() {\n    if (this.filters.length > 0) {\n      this.source.connect(this.filters[0]);\n      for (let i = 1, l = this.filters.length; i < l; i++) {\n        this.filters[i - 1].connect(this.filters[i]);\n      }\n      this.filters[this.filters.length - 1].connect(this.getOutput());\n    } else {\n      this.source.connect(this.getOutput());\n    }\n    this._connected = true;\n    return this;\n  }\n  disconnect() {\n    if (this.filters.length > 0) {\n      this.source.disconnect(this.filters[0]);\n      for (let i = 1, l = this.filters.length; i < l; i++) {\n        this.filters[i - 1].disconnect(this.filters[i]);\n      }\n      this.filters[this.filters.length - 1].disconnect(this.getOutput());\n    } else {\n      this.source.disconnect(this.getOutput());\n    }\n    this._connected = false;\n    return this;\n  }\n  getFilters() {\n    return this.filters;\n  }\n  setFilters(value) {\n    if (!value) value = [];\n    if (this._connected === true) {\n      this.disconnect();\n      this.filters = value.slice();\n      this.connect();\n    } else {\n      this.filters = value.slice();\n    }\n    return this;\n  }\n  setDetune(value) {\n    this.detune = value;\n    if (this.source.detune === undefined) return; // only set detune when available\n\n    if (this.isPlaying === true) {\n      this.source.detune.setTargetAtTime(this.detune, this.context.currentTime, 0.01);\n    }\n    return this;\n  }\n  getDetune() {\n    return this.detune;\n  }\n  getFilter() {\n    return this.getFilters()[0];\n  }\n  setFilter(filter) {\n    return this.setFilters(filter ? [filter] : []);\n  }\n  setPlaybackRate(value) {\n    if (this.hasPlaybackControl === false) {\n      console.warn('THREE.Audio: this Audio has no playback control.');\n      return;\n    }\n    this.playbackRate = value;\n    if (this.isPlaying === true) {\n      this.source.playbackRate.setTargetAtTime(this.playbackRate, this.context.currentTime, 0.01);\n    }\n    return this;\n  }\n  getPlaybackRate() {\n    return this.playbackRate;\n  }\n  onEnded() {\n    this.isPlaying = false;\n  }\n  getLoop() {\n    if (this.hasPlaybackControl === false) {\n      console.warn('THREE.Audio: this Audio has no playback control.');\n      return false;\n    }\n    return this.loop;\n  }\n  setLoop(value) {\n    if (this.hasPlaybackControl === false) {\n      console.warn('THREE.Audio: this Audio has no playback control.');\n      return;\n    }\n    this.loop = value;\n    if (this.isPlaying === true) {\n      this.source.loop = this.loop;\n    }\n    return this;\n  }\n  setLoopStart(value) {\n    this.loopStart = value;\n    return this;\n  }\n  setLoopEnd(value) {\n    this.loopEnd = value;\n    return this;\n  }\n  getVolume() {\n    return this.gain.gain.value;\n  }\n  setVolume(value) {\n    this.gain.gain.setTargetAtTime(value, this.context.currentTime, 0.01);\n    return this;\n  }\n}\nfunction PropertyMixer(binding, typeName, valueSize) {\n  this.binding = binding;\n  this.valueSize = valueSize;\n  let mixFunction, mixFunctionAdditive, setIdentity;\n\n  // buffer layout: [ incoming | accu0 | accu1 | orig | addAccu | (optional work) ]\n  //\n  // interpolators can use .buffer as their .result\n  // the data then goes to 'incoming'\n  //\n  // 'accu0' and 'accu1' are used frame-interleaved for\n  // the cumulative result and are compared to detect\n  // changes\n  //\n  // 'orig' stores the original state of the property\n  //\n  // 'add' is used for additive cumulative results\n  //\n  // 'work' is optional and is only present for quaternion types. It is used\n  // to store intermediate quaternion multiplication results\n\n  switch (typeName) {\n    case 'quaternion':\n      mixFunction = this._slerp;\n      mixFunctionAdditive = this._slerpAdditive;\n      setIdentity = this._setAdditiveIdentityQuaternion;\n      this.buffer = new Float64Array(valueSize * 6);\n      this._workIndex = 5;\n      break;\n    case 'string':\n    case 'bool':\n      mixFunction = this._select;\n\n      // Use the regular mix function and for additive on these types,\n      // additive is not relevant for non-numeric types\n      mixFunctionAdditive = this._select;\n      setIdentity = this._setAdditiveIdentityOther;\n      this.buffer = new Array(valueSize * 5);\n      break;\n    default:\n      mixFunction = this._lerp;\n      mixFunctionAdditive = this._lerpAdditive;\n      setIdentity = this._setAdditiveIdentityNumeric;\n      this.buffer = new Float64Array(valueSize * 5);\n  }\n  this._mixBufferRegion = mixFunction;\n  this._mixBufferRegionAdditive = mixFunctionAdditive;\n  this._setIdentity = setIdentity;\n  this._origIndex = 3;\n  this._addIndex = 4;\n  this.cumulativeWeight = 0;\n  this.cumulativeWeightAdditive = 0;\n  this.useCount = 0;\n  this.referenceCount = 0;\n}\n_extends__default['default'](PropertyMixer.prototype, {\n  // accumulate data in the 'incoming' region into 'accu<i>'\n  accumulate: function (accuIndex, weight) {\n    // note: happily accumulating nothing when weight = 0, the caller knows\n    // the weight and shouldn't have made the call in the first place\n\n    const buffer = this.buffer,\n      stride = this.valueSize,\n      offset = accuIndex * stride + stride;\n    let currentWeight = this.cumulativeWeight;\n    if (currentWeight === 0) {\n      // accuN := incoming * weight\n\n      for (let i = 0; i !== stride; ++i) {\n        buffer[offset + i] = buffer[i];\n      }\n      currentWeight = weight;\n    } else {\n      // accuN := accuN + incoming * weight\n\n      currentWeight += weight;\n      const mix = weight / currentWeight;\n      this._mixBufferRegion(buffer, offset, 0, mix, stride);\n    }\n    this.cumulativeWeight = currentWeight;\n  },\n  // accumulate data in the 'incoming' region into 'add'\n  accumulateAdditive: function (weight) {\n    const buffer = this.buffer,\n      stride = this.valueSize,\n      offset = stride * this._addIndex;\n    if (this.cumulativeWeightAdditive === 0) {\n      // add = identity\n\n      this._setIdentity();\n    }\n\n    // add := add + incoming * weight\n\n    this._mixBufferRegionAdditive(buffer, offset, 0, weight, stride);\n    this.cumulativeWeightAdditive += weight;\n  },\n  // apply the state of 'accu<i>' to the binding when accus differ\n  apply: function (accuIndex) {\n    const stride = this.valueSize,\n      buffer = this.buffer,\n      offset = accuIndex * stride + stride,\n      weight = this.cumulativeWeight,\n      weightAdditive = this.cumulativeWeightAdditive,\n      binding = this.binding;\n    this.cumulativeWeight = 0;\n    this.cumulativeWeightAdditive = 0;\n    if (weight < 1) {\n      // accuN := accuN + original * ( 1 - cumulativeWeight )\n\n      const originalValueOffset = stride * this._origIndex;\n      this._mixBufferRegion(buffer, offset, originalValueOffset, 1 - weight, stride);\n    }\n    if (weightAdditive > 0) {\n      // accuN := accuN + additive accuN\n\n      this._mixBufferRegionAdditive(buffer, offset, this._addIndex * stride, 1, stride);\n    }\n    for (let i = stride, e = stride + stride; i !== e; ++i) {\n      if (buffer[i] !== buffer[i + stride]) {\n        // value has changed -> update scene graph\n\n        binding.setValue(buffer, offset);\n        break;\n      }\n    }\n  },\n  // remember the state of the bound property and copy it to both accus\n  saveOriginalState: function () {\n    const binding = this.binding;\n    const buffer = this.buffer,\n      stride = this.valueSize,\n      originalValueOffset = stride * this._origIndex;\n    binding.getValue(buffer, originalValueOffset);\n\n    // accu[0..1] := orig -- initially detect changes against the original\n    for (let i = stride, e = originalValueOffset; i !== e; ++i) {\n      buffer[i] = buffer[originalValueOffset + i % stride];\n    }\n\n    // Add to identity for additive\n    this._setIdentity();\n    this.cumulativeWeight = 0;\n    this.cumulativeWeightAdditive = 0;\n  },\n  // apply the state previously taken via 'saveOriginalState' to the binding\n  restoreOriginalState: function () {\n    const originalValueOffset = this.valueSize * 3;\n    this.binding.setValue(this.buffer, originalValueOffset);\n  },\n  _setAdditiveIdentityNumeric: function () {\n    const startIndex = this._addIndex * this.valueSize;\n    const endIndex = startIndex + this.valueSize;\n    for (let i = startIndex; i < endIndex; i++) {\n      this.buffer[i] = 0;\n    }\n  },\n  _setAdditiveIdentityQuaternion: function () {\n    this._setAdditiveIdentityNumeric();\n    this.buffer[this._addIndex * this.valueSize + 3] = 1;\n  },\n  _setAdditiveIdentityOther: function () {\n    const startIndex = this._origIndex * this.valueSize;\n    const targetIndex = this._addIndex * this.valueSize;\n    for (let i = 0; i < this.valueSize; i++) {\n      this.buffer[targetIndex + i] = this.buffer[startIndex + i];\n    }\n  },\n  // mix functions\n\n  _select: function (buffer, dstOffset, srcOffset, t, stride) {\n    if (t >= 0.5) {\n      for (let i = 0; i !== stride; ++i) {\n        buffer[dstOffset + i] = buffer[srcOffset + i];\n      }\n    }\n  },\n  _slerp: function (buffer, dstOffset, srcOffset, t) {\n    Quaternion.slerpFlat(buffer, dstOffset, buffer, dstOffset, buffer, srcOffset, t);\n  },\n  _slerpAdditive: function (buffer, dstOffset, srcOffset, t, stride) {\n    const workOffset = this._workIndex * stride;\n\n    // Store result in intermediate buffer offset\n    Quaternion.multiplyQuaternionsFlat(buffer, workOffset, buffer, dstOffset, buffer, srcOffset);\n\n    // Slerp to the intermediate result\n    Quaternion.slerpFlat(buffer, dstOffset, buffer, dstOffset, buffer, workOffset, t);\n  },\n  _lerp: function (buffer, dstOffset, srcOffset, t, stride) {\n    const s = 1 - t;\n    for (let i = 0; i !== stride; ++i) {\n      const j = dstOffset + i;\n      buffer[j] = buffer[j] * s + buffer[srcOffset + i] * t;\n    }\n  },\n  _lerpAdditive: function (buffer, dstOffset, srcOffset, t, stride) {\n    for (let i = 0; i !== stride; ++i) {\n      const j = dstOffset + i;\n      buffer[j] = buffer[j] + buffer[srcOffset + i] * t;\n    }\n  }\n});\n\n// Characters [].:/ are reserved for track binding syntax.\nconst _RESERVED_CHARS_RE = '\\\\[\\\\]\\\\.:\\\\/';\nconst _reservedRe = new RegExp('[' + _RESERVED_CHARS_RE + ']', 'g');\n\n// Attempts to allow node names from any language. ES5's `\\w` regexp matches\n// only latin characters, and the unicode \\p{L} is not yet supported. So\n// instead, we exclude reserved characters and match everything else.\nconst _wordChar = '[^' + _RESERVED_CHARS_RE + ']';\nconst _wordCharOrDot = '[^' + _RESERVED_CHARS_RE.replace('\\\\.', '') + ']';\n\n// Parent directories, delimited by '/' or ':'. Currently unused, but must\n// be matched to parse the rest of the track name.\nconst _directoryRe = /((?:WC+[\\/:])*)/.source.replace('WC', _wordChar);\n\n// Target node. May contain word characters (a-zA-Z0-9_) and '.' or '-'.\nconst _nodeRe = /(WCOD+)?/.source.replace('WCOD', _wordCharOrDot);\n\n// Object on target node, and accessor. May not contain reserved\n// characters. Accessor may contain any character except closing bracket.\nconst _objectRe = /(?:\\.(WC+)(?:\\[(.+)\\])?)?/.source.replace('WC', _wordChar);\n\n// Property and accessor. May not contain reserved characters. Accessor may\n// contain any non-bracket characters.\nconst _propertyRe = /\\.(WC+)(?:\\[(.+)\\])?/.source.replace('WC', _wordChar);\nconst _trackRe = new RegExp('' + '^' + _directoryRe + _nodeRe + _objectRe + _propertyRe + '$');\nconst _supportedObjectNames = ['material', 'materials', 'bones'];\nfunction Composite(targetGroup, path, optionalParsedPath) {\n  const parsedPath = optionalParsedPath || PropertyBinding.parseTrackName(path);\n  this._targetGroup = targetGroup;\n  this._bindings = targetGroup.subscribe_(path, parsedPath);\n}\n_extends__default['default'](Composite.prototype, {\n  getValue: function (array, offset) {\n    this.bind(); // bind all binding\n\n    const firstValidIndex = this._targetGroup.nCachedObjects_,\n      binding = this._bindings[firstValidIndex];\n\n    // and only call .getValue on the first\n    if (binding !== undefined) binding.getValue(array, offset);\n  },\n  setValue: function (array, offset) {\n    const bindings = this._bindings;\n    for (let i = this._targetGroup.nCachedObjects_, n = bindings.length; i !== n; ++i) {\n      bindings[i].setValue(array, offset);\n    }\n  },\n  bind: function () {\n    const bindings = this._bindings;\n    for (let i = this._targetGroup.nCachedObjects_, n = bindings.length; i !== n; ++i) {\n      bindings[i].bind();\n    }\n  },\n  unbind: function () {\n    const bindings = this._bindings;\n    for (let i = this._targetGroup.nCachedObjects_, n = bindings.length; i !== n; ++i) {\n      bindings[i].unbind();\n    }\n  }\n});\nfunction PropertyBinding(rootNode, path, parsedPath) {\n  this.path = path;\n  this.parsedPath = parsedPath || PropertyBinding.parseTrackName(path);\n  this.node = PropertyBinding.findNode(rootNode, this.parsedPath.nodeName) || rootNode;\n  this.rootNode = rootNode;\n}\n_extends__default['default'](PropertyBinding, {\n  Composite: Composite,\n  create: function (root, path, parsedPath) {\n    if (!(root && root.isAnimationObjectGroup)) {\n      return new PropertyBinding(root, path, parsedPath);\n    } else {\n      return new PropertyBinding.Composite(root, path, parsedPath);\n    }\n  },\n  /**\n   * Replaces spaces with underscores and removes unsupported characters from\n   * node names, to ensure compatibility with parseTrackName().\n   *\n   * @param {string} name Node name to be sanitized.\n   * @return {string}\n   */\n  sanitizeNodeName: function (name) {\n    return name.replace(/\\s/g, '_').replace(_reservedRe, '');\n  },\n  parseTrackName: function (trackName) {\n    const matches = _trackRe.exec(trackName);\n    if (!matches) {\n      throw new Error('PropertyBinding: Cannot parse trackName: ' + trackName);\n    }\n    const results = {\n      // directoryName: matches[ 1 ], // (tschw) currently unused\n      nodeName: matches[2],\n      objectName: matches[3],\n      objectIndex: matches[4],\n      propertyName: matches[5],\n      // required\n      propertyIndex: matches[6]\n    };\n    const lastDot = results.nodeName && results.nodeName.lastIndexOf('.');\n    if (lastDot !== undefined && lastDot !== -1) {\n      const objectName = results.nodeName.substring(lastDot + 1);\n\n      // Object names must be checked against an allowlist. Otherwise, there\n      // is no way to parse 'foo.bar.baz': 'baz' must be a property, but\n      // 'bar' could be the objectName, or part of a nodeName (which can\n      // include '.' characters).\n      if (_supportedObjectNames.indexOf(objectName) !== -1) {\n        results.nodeName = results.nodeName.substring(0, lastDot);\n        results.objectName = objectName;\n      }\n    }\n    if (results.propertyName === null || results.propertyName.length === 0) {\n      throw new Error('PropertyBinding: can not parse propertyName from trackName: ' + trackName);\n    }\n    return results;\n  },\n  findNode: function (root, nodeName) {\n    if (!nodeName || nodeName === '' || nodeName === '.' || nodeName === -1 || nodeName === root.name || nodeName === root.uuid) {\n      return root;\n    }\n\n    // search into skeleton bones.\n    if (root.skeleton) {\n      const bone = root.skeleton.getBoneByName(nodeName);\n      if (bone !== undefined) {\n        return bone;\n      }\n    }\n\n    // search into node subtree.\n    if (root.children) {\n      const searchNodeSubtree = function (children) {\n        for (let i = 0; i < children.length; i++) {\n          const childNode = children[i];\n          if (childNode.name === nodeName || childNode.uuid === nodeName) {\n            return childNode;\n          }\n          const result = searchNodeSubtree(childNode.children);\n          if (result) return result;\n        }\n        return null;\n      };\n      const subTreeNode = searchNodeSubtree(root.children);\n      if (subTreeNode) {\n        return subTreeNode;\n      }\n    }\n    return null;\n  }\n});\n_extends__default['default'](PropertyBinding.prototype, {\n  // prototype, continued\n\n  // these are used to \"bind\" a nonexistent property\n  _getValue_unavailable: function () {},\n  _setValue_unavailable: function () {},\n  BindingType: {\n    Direct: 0,\n    EntireArray: 1,\n    ArrayElement: 2,\n    HasFromToArray: 3\n  },\n  Versioning: {\n    None: 0,\n    NeedsUpdate: 1,\n    MatrixWorldNeedsUpdate: 2\n  },\n  GetterByBindingType: [function getValue_direct(buffer, offset) {\n    buffer[offset] = this.node[this.propertyName];\n  }, function getValue_array(buffer, offset) {\n    const source = this.resolvedProperty;\n    for (let i = 0, n = source.length; i !== n; ++i) {\n      buffer[offset++] = source[i];\n    }\n  }, function getValue_arrayElement(buffer, offset) {\n    buffer[offset] = this.resolvedProperty[this.propertyIndex];\n  }, function getValue_toArray(buffer, offset) {\n    this.resolvedProperty.toArray(buffer, offset);\n  }],\n  SetterByBindingTypeAndVersioning: [[\n  // Direct\n\n  function setValue_direct(buffer, offset) {\n    this.targetObject[this.propertyName] = buffer[offset];\n  }, function setValue_direct_setNeedsUpdate(buffer, offset) {\n    this.targetObject[this.propertyName] = buffer[offset];\n    this.targetObject.needsUpdate = true;\n  }, function setValue_direct_setMatrixWorldNeedsUpdate(buffer, offset) {\n    this.targetObject[this.propertyName] = buffer[offset];\n    this.targetObject.matrixWorldNeedsUpdate = true;\n  }], [\n  // EntireArray\n\n  function setValue_array(buffer, offset) {\n    const dest = this.resolvedProperty;\n    for (let i = 0, n = dest.length; i !== n; ++i) {\n      dest[i] = buffer[offset++];\n    }\n  }, function setValue_array_setNeedsUpdate(buffer, offset) {\n    const dest = this.resolvedProperty;\n    for (let i = 0, n = dest.length; i !== n; ++i) {\n      dest[i] = buffer[offset++];\n    }\n    this.targetObject.needsUpdate = true;\n  }, function setValue_array_setMatrixWorldNeedsUpdate(buffer, offset) {\n    const dest = this.resolvedProperty;\n    for (let i = 0, n = dest.length; i !== n; ++i) {\n      dest[i] = buffer[offset++];\n    }\n    this.targetObject.matrixWorldNeedsUpdate = true;\n  }], [\n  // ArrayElement\n\n  function setValue_arrayElement(buffer, offset) {\n    this.resolvedProperty[this.propertyIndex] = buffer[offset];\n  }, function setValue_arrayElement_setNeedsUpdate(buffer, offset) {\n    this.resolvedProperty[this.propertyIndex] = buffer[offset];\n    this.targetObject.needsUpdate = true;\n  }, function setValue_arrayElement_setMatrixWorldNeedsUpdate(buffer, offset) {\n    this.resolvedProperty[this.propertyIndex] = buffer[offset];\n    this.targetObject.matrixWorldNeedsUpdate = true;\n  }], [\n  // HasToFromArray\n\n  function setValue_fromArray(buffer, offset) {\n    this.resolvedProperty.fromArray(buffer, offset);\n  }, function setValue_fromArray_setNeedsUpdate(buffer, offset) {\n    this.resolvedProperty.fromArray(buffer, offset);\n    this.targetObject.needsUpdate = true;\n  }, function setValue_fromArray_setMatrixWorldNeedsUpdate(buffer, offset) {\n    this.resolvedProperty.fromArray(buffer, offset);\n    this.targetObject.matrixWorldNeedsUpdate = true;\n  }]],\n  getValue: function getValue_unbound(targetArray, offset) {\n    this.bind();\n    this.getValue(targetArray, offset);\n\n    // Note: This class uses a State pattern on a per-method basis:\n    // 'bind' sets 'this.getValue' / 'setValue' and shadows the\n    // prototype version of these methods with one that represents\n    // the bound state. When the property is not found, the methods\n    // become no-ops.\n  },\n\n  setValue: function getValue_unbound(sourceArray, offset) {\n    this.bind();\n    this.setValue(sourceArray, offset);\n  },\n  // create getter / setter pair for a property in the scene graph\n  bind: function () {\n    let targetObject = this.node;\n    const parsedPath = this.parsedPath;\n    const objectName = parsedPath.objectName;\n    const propertyName = parsedPath.propertyName;\n    let propertyIndex = parsedPath.propertyIndex;\n    if (!targetObject) {\n      targetObject = PropertyBinding.findNode(this.rootNode, parsedPath.nodeName) || this.rootNode;\n      this.node = targetObject;\n    }\n\n    // set fail state so we can just 'return' on error\n    this.getValue = this._getValue_unavailable;\n    this.setValue = this._setValue_unavailable;\n\n    // ensure there is a value node\n    if (!targetObject) {\n      console.error('THREE.PropertyBinding: Trying to update node for track: ' + this.path + ' but it wasn\\'t found.');\n      return;\n    }\n    if (objectName) {\n      let objectIndex = parsedPath.objectIndex;\n\n      // special cases were we need to reach deeper into the hierarchy to get the face materials....\n      switch (objectName) {\n        case 'materials':\n          if (!targetObject.material) {\n            console.error('THREE.PropertyBinding: Can not bind to material as node does not have a material.', this);\n            return;\n          }\n          if (!targetObject.material.materials) {\n            console.error('THREE.PropertyBinding: Can not bind to material.materials as node.material does not have a materials array.', this);\n            return;\n          }\n          targetObject = targetObject.material.materials;\n          break;\n        case 'bones':\n          if (!targetObject.skeleton) {\n            console.error('THREE.PropertyBinding: Can not bind to bones as node does not have a skeleton.', this);\n            return;\n          }\n\n          // potential future optimization: skip this if propertyIndex is already an integer\n          // and convert the integer string to a true integer.\n\n          targetObject = targetObject.skeleton.bones;\n\n          // support resolving morphTarget names into indices.\n          for (let i = 0; i < targetObject.length; i++) {\n            if (targetObject[i].name === objectIndex) {\n              objectIndex = i;\n              break;\n            }\n          }\n          break;\n        default:\n          if (targetObject[objectName] === undefined) {\n            console.error('THREE.PropertyBinding: Can not bind to objectName of node undefined.', this);\n            return;\n          }\n          targetObject = targetObject[objectName];\n      }\n      if (objectIndex !== undefined) {\n        if (targetObject[objectIndex] === undefined) {\n          console.error('THREE.PropertyBinding: Trying to bind to objectIndex of objectName, but is undefined.', this, targetObject);\n          return;\n        }\n        targetObject = targetObject[objectIndex];\n      }\n    }\n\n    // resolve property\n    const nodeProperty = targetObject[propertyName];\n    if (nodeProperty === undefined) {\n      const nodeName = parsedPath.nodeName;\n      console.error('THREE.PropertyBinding: Trying to update property for track: ' + nodeName + '.' + propertyName + ' but it wasn\\'t found.', targetObject);\n      return;\n    }\n\n    // determine versioning scheme\n    let versioning = this.Versioning.None;\n    this.targetObject = targetObject;\n    if (targetObject.needsUpdate !== undefined) {\n      // material\n\n      versioning = this.Versioning.NeedsUpdate;\n    } else if (targetObject.matrixWorldNeedsUpdate !== undefined) {\n      // node transform\n\n      versioning = this.Versioning.MatrixWorldNeedsUpdate;\n    }\n\n    // determine how the property gets bound\n    let bindingType = this.BindingType.Direct;\n    if (propertyIndex !== undefined) {\n      // access a sub element of the property array (only primitives are supported right now)\n\n      if (propertyName === 'morphTargetInfluences') {\n        // potential optimization, skip this if propertyIndex is already an integer, and convert the integer string to a true integer.\n\n        // support resolving morphTarget names into indices.\n        if (!targetObject.geometry) {\n          console.error('THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.', this);\n          return;\n        }\n        if (targetObject.geometry.isBufferGeometry) {\n          if (!targetObject.geometry.morphAttributes) {\n            console.error('THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.morphAttributes.', this);\n            return;\n          }\n          if (targetObject.morphTargetDictionary[propertyIndex] !== undefined) {\n            propertyIndex = targetObject.morphTargetDictionary[propertyIndex];\n          }\n        } else {\n          console.error('THREE.PropertyBinding: Can not bind to morphTargetInfluences on THREE.Geometry. Use THREE.BufferGeometry instead.', this);\n          return;\n        }\n      }\n      bindingType = this.BindingType.ArrayElement;\n      this.resolvedProperty = nodeProperty;\n      this.propertyIndex = propertyIndex;\n    } else if (nodeProperty.fromArray !== undefined && nodeProperty.toArray !== undefined) {\n      // must use copy for Object3D.Euler/Quaternion\n\n      bindingType = this.BindingType.HasFromToArray;\n      this.resolvedProperty = nodeProperty;\n    } else if (Array.isArray(nodeProperty)) {\n      bindingType = this.BindingType.EntireArray;\n      this.resolvedProperty = nodeProperty;\n    } else {\n      this.propertyName = propertyName;\n    }\n\n    // select getter / setter\n    this.getValue = this.GetterByBindingType[bindingType];\n    this.setValue = this.SetterByBindingTypeAndVersioning[bindingType][versioning];\n  },\n  unbind: function () {\n    this.node = null;\n\n    // back to the prototype version of getValue / setValue\n    // note: avoiding to mutate the shape of 'this' via 'delete'\n    this.getValue = this._getValue_unbound;\n    this.setValue = this._setValue_unbound;\n  }\n});\n\n// DECLARE ALIAS AFTER assign prototype\n_extends__default['default'](PropertyBinding.prototype, {\n  // initial state of these methods that calls 'bind'\n  _getValue_unbound: PropertyBinding.prototype.getValue,\n  _setValue_unbound: PropertyBinding.prototype.setValue\n});\n\n/**\n *\n * A group of objects that receives a shared animation state.\n *\n * Usage:\n *\n *  - Add objects you would otherwise pass as 'root' to the\n *    constructor or the .clipAction method of AnimationMixer.\n *\n *  - Instead pass this object as 'root'.\n *\n *  - You can also add and remove objects later when the mixer\n *    is running.\n *\n * Note:\n *\n *    Objects of this class appear as one object to the mixer,\n *    so cache control of the individual objects must be done\n *    on the group.\n *\n * Limitation:\n *\n *  - The animated properties must be compatible among the\n *    all objects in the group.\n *\n *  - A single property can either be controlled through a\n *    target group or directly, but not both.\n */\n\nfunction AnimationObjectGroup() {\n  this.uuid = MathUtils.generateUUID();\n\n  // cached objects followed by the active ones\n  this._objects = Array.prototype.slice.call(arguments);\n  this.nCachedObjects_ = 0; // threshold\n  // note: read by PropertyBinding.Composite\n\n  const indices = {};\n  this._indicesByUUID = indices; // for bookkeeping\n\n  for (let i = 0, n = arguments.length; i !== n; ++i) {\n    indices[arguments[i].uuid] = i;\n  }\n  this._paths = []; // inside: string\n  this._parsedPaths = []; // inside: { we don't care, here }\n  this._bindings = []; // inside: Array< PropertyBinding >\n  this._bindingsIndicesByPath = {}; // inside: indices in these arrays\n\n  const scope = this;\n  this.stats = {\n    objects: {\n      get total() {\n        return scope._objects.length;\n      },\n      get inUse() {\n        return this.total - scope.nCachedObjects_;\n      }\n    },\n    get bindingsPerObject() {\n      return scope._bindings.length;\n    }\n  };\n}\n_extends__default['default'](AnimationObjectGroup.prototype, {\n  isAnimationObjectGroup: true,\n  add: function () {\n    const objects = this._objects,\n      indicesByUUID = this._indicesByUUID,\n      paths = this._paths,\n      parsedPaths = this._parsedPaths,\n      bindings = this._bindings,\n      nBindings = bindings.length;\n    let knownObject = undefined,\n      nObjects = objects.length,\n      nCachedObjects = this.nCachedObjects_;\n    for (let i = 0, n = arguments.length; i !== n; ++i) {\n      const object = arguments[i],\n        uuid = object.uuid;\n      let index = indicesByUUID[uuid];\n      if (index === undefined) {\n        // unknown object -> add it to the ACTIVE region\n\n        index = nObjects++;\n        indicesByUUID[uuid] = index;\n        objects.push(object);\n\n        // accounting is done, now do the same for all bindings\n\n        for (let j = 0, m = nBindings; j !== m; ++j) {\n          bindings[j].push(new PropertyBinding(object, paths[j], parsedPaths[j]));\n        }\n      } else if (index < nCachedObjects) {\n        knownObject = objects[index];\n\n        // move existing object to the ACTIVE region\n\n        const firstActiveIndex = --nCachedObjects,\n          lastCachedObject = objects[firstActiveIndex];\n        indicesByUUID[lastCachedObject.uuid] = index;\n        objects[index] = lastCachedObject;\n        indicesByUUID[uuid] = firstActiveIndex;\n        objects[firstActiveIndex] = object;\n\n        // accounting is done, now do the same for all bindings\n\n        for (let j = 0, m = nBindings; j !== m; ++j) {\n          const bindingsForPath = bindings[j],\n            lastCached = bindingsForPath[firstActiveIndex];\n          let binding = bindingsForPath[index];\n          bindingsForPath[index] = lastCached;\n          if (binding === undefined) {\n            // since we do not bother to create new bindings\n            // for objects that are cached, the binding may\n            // or may not exist\n\n            binding = new PropertyBinding(object, paths[j], parsedPaths[j]);\n          }\n          bindingsForPath[firstActiveIndex] = binding;\n        }\n      } else if (objects[index] !== knownObject) {\n        console.error('THREE.AnimationObjectGroup: Different objects with the same UUID ' + 'detected. Clean the caches or recreate your infrastructure when reloading scenes.');\n      } // else the object is already where we want it to be\n    } // for arguments\n\n    this.nCachedObjects_ = nCachedObjects;\n  },\n  remove: function () {\n    const objects = this._objects,\n      indicesByUUID = this._indicesByUUID,\n      bindings = this._bindings,\n      nBindings = bindings.length;\n    let nCachedObjects = this.nCachedObjects_;\n    for (let i = 0, n = arguments.length; i !== n; ++i) {\n      const object = arguments[i],\n        uuid = object.uuid,\n        index = indicesByUUID[uuid];\n      if (index !== undefined && index >= nCachedObjects) {\n        // move existing object into the CACHED region\n\n        const lastCachedIndex = nCachedObjects++,\n          firstActiveObject = objects[lastCachedIndex];\n        indicesByUUID[firstActiveObject.uuid] = index;\n        objects[index] = firstActiveObject;\n        indicesByUUID[uuid] = lastCachedIndex;\n        objects[lastCachedIndex] = object;\n\n        // accounting is done, now do the same for all bindings\n\n        for (let j = 0, m = nBindings; j !== m; ++j) {\n          const bindingsForPath = bindings[j],\n            firstActive = bindingsForPath[lastCachedIndex],\n            binding = bindingsForPath[index];\n          bindingsForPath[index] = firstActive;\n          bindingsForPath[lastCachedIndex] = binding;\n        }\n      }\n    } // for arguments\n\n    this.nCachedObjects_ = nCachedObjects;\n  },\n  // remove & forget\n  uncache: function () {\n    const objects = this._objects,\n      indicesByUUID = this._indicesByUUID,\n      bindings = this._bindings,\n      nBindings = bindings.length;\n    let nCachedObjects = this.nCachedObjects_,\n      nObjects = objects.length;\n    for (let i = 0, n = arguments.length; i !== n; ++i) {\n      const object = arguments[i],\n        uuid = object.uuid,\n        index = indicesByUUID[uuid];\n      if (index !== undefined) {\n        delete indicesByUUID[uuid];\n        if (index < nCachedObjects) {\n          // object is cached, shrink the CACHED region\n\n          const firstActiveIndex = --nCachedObjects,\n            lastCachedObject = objects[firstActiveIndex],\n            lastIndex = --nObjects,\n            lastObject = objects[lastIndex];\n\n          // last cached object takes this object's place\n          indicesByUUID[lastCachedObject.uuid] = index;\n          objects[index] = lastCachedObject;\n\n          // last object goes to the activated slot and pop\n          indicesByUUID[lastObject.uuid] = firstActiveIndex;\n          objects[firstActiveIndex] = lastObject;\n          objects.pop();\n\n          // accounting is done, now do the same for all bindings\n\n          for (let j = 0, m = nBindings; j !== m; ++j) {\n            const bindingsForPath = bindings[j],\n              lastCached = bindingsForPath[firstActiveIndex],\n              last = bindingsForPath[lastIndex];\n            bindingsForPath[index] = lastCached;\n            bindingsForPath[firstActiveIndex] = last;\n            bindingsForPath.pop();\n          }\n        } else {\n          // object is active, just swap with the last and pop\n\n          const lastIndex = --nObjects,\n            lastObject = objects[lastIndex];\n          if (lastIndex > 0) {\n            indicesByUUID[lastObject.uuid] = index;\n          }\n          objects[index] = lastObject;\n          objects.pop();\n\n          // accounting is done, now do the same for all bindings\n\n          for (let j = 0, m = nBindings; j !== m; ++j) {\n            const bindingsForPath = bindings[j];\n            bindingsForPath[index] = bindingsForPath[lastIndex];\n            bindingsForPath.pop();\n          }\n        } // cached or active\n      } // if object is known\n    } // for arguments\n\n    this.nCachedObjects_ = nCachedObjects;\n  },\n  // Internal interface used by befriended PropertyBinding.Composite:\n\n  subscribe_: function (path, parsedPath) {\n    // returns an array of bindings for the given path that is changed\n    // according to the contained objects in the group\n\n    const indicesByPath = this._bindingsIndicesByPath;\n    let index = indicesByPath[path];\n    const bindings = this._bindings;\n    if (index !== undefined) return bindings[index];\n    const paths = this._paths,\n      parsedPaths = this._parsedPaths,\n      objects = this._objects,\n      nObjects = objects.length,\n      nCachedObjects = this.nCachedObjects_,\n      bindingsForPath = new Array(nObjects);\n    index = bindings.length;\n    indicesByPath[path] = index;\n    paths.push(path);\n    parsedPaths.push(parsedPath);\n    bindings.push(bindingsForPath);\n    for (let i = nCachedObjects, n = objects.length; i !== n; ++i) {\n      const object = objects[i];\n      bindingsForPath[i] = new PropertyBinding(object, path, parsedPath);\n    }\n    return bindingsForPath;\n  },\n  unsubscribe_: function (path) {\n    // tells the group to forget about a property path and no longer\n    // update the array previously obtained with 'subscribe_'\n\n    const indicesByPath = this._bindingsIndicesByPath,\n      index = indicesByPath[path];\n    if (index !== undefined) {\n      const paths = this._paths,\n        parsedPaths = this._parsedPaths,\n        bindings = this._bindings,\n        lastBindingsIndex = bindings.length - 1,\n        lastBindings = bindings[lastBindingsIndex],\n        lastBindingsPath = path[lastBindingsIndex];\n      indicesByPath[lastBindingsPath] = index;\n      bindings[index] = lastBindings;\n      bindings.pop();\n      parsedPaths[index] = parsedPaths[lastBindingsIndex];\n      parsedPaths.pop();\n      paths[index] = paths[lastBindingsIndex];\n      paths.pop();\n    }\n  }\n});\nclass AnimationAction {\n  constructor(mixer, clip, localRoot = null, blendMode = clip.blendMode) {\n    this._mixer = mixer;\n    this._clip = clip;\n    this._localRoot = localRoot;\n    this.blendMode = blendMode;\n    const tracks = clip.tracks,\n      nTracks = tracks.length,\n      interpolants = new Array(nTracks);\n    const interpolantSettings = {\n      endingStart: ZeroCurvatureEnding,\n      endingEnd: ZeroCurvatureEnding\n    };\n    for (let i = 0; i !== nTracks; ++i) {\n      const interpolant = tracks[i].createInterpolant(null);\n      interpolants[i] = interpolant;\n      interpolant.settings = interpolantSettings;\n    }\n    this._interpolantSettings = interpolantSettings;\n    this._interpolants = interpolants; // bound by the mixer\n\n    // inside: PropertyMixer (managed by the mixer)\n    this._propertyBindings = new Array(nTracks);\n    this._cacheIndex = null; // for the memory manager\n    this._byClipCacheIndex = null; // for the memory manager\n\n    this._timeScaleInterpolant = null;\n    this._weightInterpolant = null;\n    this.loop = LoopRepeat;\n    this._loopCount = -1;\n\n    // global mixer time when the action is to be started\n    // it's set back to 'null' upon start of the action\n    this._startTime = null;\n\n    // scaled local time of the action\n    // gets clamped or wrapped to 0..clip.duration according to loop\n    this.time = 0;\n    this.timeScale = 1;\n    this._effectiveTimeScale = 1;\n    this.weight = 1;\n    this._effectiveWeight = 1;\n    this.repetitions = Infinity; // no. of repetitions when looping\n\n    this.paused = false; // true -> zero effective time scale\n    this.enabled = true; // false -> zero effective weight\n\n    this.clampWhenFinished = false; // keep feeding the last frame?\n\n    this.zeroSlopeAtStart = true; // for smooth interpolation w/o separate\n    this.zeroSlopeAtEnd = true; // clips for start, loop and end\n  }\n\n  // State & Scheduling\n\n  play() {\n    this._mixer._activateAction(this);\n    return this;\n  }\n  stop() {\n    this._mixer._deactivateAction(this);\n    return this.reset();\n  }\n  reset() {\n    this.paused = false;\n    this.enabled = true;\n    this.time = 0; // restart clip\n    this._loopCount = -1; // forget previous loops\n    this._startTime = null; // forget scheduling\n\n    return this.stopFading().stopWarping();\n  }\n  isRunning() {\n    return this.enabled && !this.paused && this.timeScale !== 0 && this._startTime === null && this._mixer._isActiveAction(this);\n  }\n\n  // return true when play has been called\n  isScheduled() {\n    return this._mixer._isActiveAction(this);\n  }\n  startAt(time) {\n    this._startTime = time;\n    return this;\n  }\n  setLoop(mode, repetitions) {\n    this.loop = mode;\n    this.repetitions = repetitions;\n    return this;\n  }\n\n  // Weight\n\n  // set the weight stopping any scheduled fading\n  // although .enabled = false yields an effective weight of zero, this\n  // method does *not* change .enabled, because it would be confusing\n  setEffectiveWeight(weight) {\n    this.weight = weight;\n\n    // note: same logic as when updated at runtime\n    this._effectiveWeight = this.enabled ? weight : 0;\n    return this.stopFading();\n  }\n\n  // return the weight considering fading and .enabled\n  getEffectiveWeight() {\n    return this._effectiveWeight;\n  }\n  fadeIn(duration) {\n    return this._scheduleFading(duration, 0, 1);\n  }\n  fadeOut(duration) {\n    return this._scheduleFading(duration, 1, 0);\n  }\n  crossFadeFrom(fadeOutAction, duration, warp) {\n    fadeOutAction.fadeOut(duration);\n    this.fadeIn(duration);\n    if (warp) {\n      const fadeInDuration = this._clip.duration,\n        fadeOutDuration = fadeOutAction._clip.duration,\n        startEndRatio = fadeOutDuration / fadeInDuration,\n        endStartRatio = fadeInDuration / fadeOutDuration;\n      fadeOutAction.warp(1.0, startEndRatio, duration);\n      this.warp(endStartRatio, 1.0, duration);\n    }\n    return this;\n  }\n  crossFadeTo(fadeInAction, duration, warp) {\n    return fadeInAction.crossFadeFrom(this, duration, warp);\n  }\n  stopFading() {\n    const weightInterpolant = this._weightInterpolant;\n    if (weightInterpolant !== null) {\n      this._weightInterpolant = null;\n      this._mixer._takeBackControlInterpolant(weightInterpolant);\n    }\n    return this;\n  }\n\n  // Time Scale Control\n\n  // set the time scale stopping any scheduled warping\n  // although .paused = true yields an effective time scale of zero, this\n  // method does *not* change .paused, because it would be confusing\n  setEffectiveTimeScale(timeScale) {\n    this.timeScale = timeScale;\n    this._effectiveTimeScale = this.paused ? 0 : timeScale;\n    return this.stopWarping();\n  }\n\n  // return the time scale considering warping and .paused\n  getEffectiveTimeScale() {\n    return this._effectiveTimeScale;\n  }\n  setDuration(duration) {\n    this.timeScale = this._clip.duration / duration;\n    return this.stopWarping();\n  }\n  syncWith(action) {\n    this.time = action.time;\n    this.timeScale = action.timeScale;\n    return this.stopWarping();\n  }\n  halt(duration) {\n    return this.warp(this._effectiveTimeScale, 0, duration);\n  }\n  warp(startTimeScale, endTimeScale, duration) {\n    const mixer = this._mixer,\n      now = mixer.time,\n      timeScale = this.timeScale;\n    let interpolant = this._timeScaleInterpolant;\n    if (interpolant === null) {\n      interpolant = mixer._lendControlInterpolant();\n      this._timeScaleInterpolant = interpolant;\n    }\n    const times = interpolant.parameterPositions,\n      values = interpolant.sampleValues;\n    times[0] = now;\n    times[1] = now + duration;\n    values[0] = startTimeScale / timeScale;\n    values[1] = endTimeScale / timeScale;\n    return this;\n  }\n  stopWarping() {\n    const timeScaleInterpolant = this._timeScaleInterpolant;\n    if (timeScaleInterpolant !== null) {\n      this._timeScaleInterpolant = null;\n      this._mixer._takeBackControlInterpolant(timeScaleInterpolant);\n    }\n    return this;\n  }\n\n  // Object Accessors\n\n  getMixer() {\n    return this._mixer;\n  }\n  getClip() {\n    return this._clip;\n  }\n  getRoot() {\n    return this._localRoot || this._mixer._root;\n  }\n\n  // Interna\n\n  _update(time, deltaTime, timeDirection, accuIndex) {\n    // called by the mixer\n\n    if (!this.enabled) {\n      // call ._updateWeight() to update ._effectiveWeight\n\n      this._updateWeight(time);\n      return;\n    }\n    const startTime = this._startTime;\n    if (startTime !== null) {\n      // check for scheduled start of action\n\n      const timeRunning = (time - startTime) * timeDirection;\n      if (timeRunning < 0 || timeDirection === 0) {\n        return; // yet to come / don't decide when delta = 0\n      }\n\n      // start\n\n      this._startTime = null; // unschedule\n      deltaTime = timeDirection * timeRunning;\n    }\n\n    // apply time scale and advance time\n\n    deltaTime *= this._updateTimeScale(time);\n    const clipTime = this._updateTime(deltaTime);\n\n    // note: _updateTime may disable the action resulting in\n    // an effective weight of 0\n\n    const weight = this._updateWeight(time);\n    if (weight > 0) {\n      const interpolants = this._interpolants;\n      const propertyMixers = this._propertyBindings;\n      switch (this.blendMode) {\n        case AdditiveAnimationBlendMode:\n          for (let j = 0, m = interpolants.length; j !== m; ++j) {\n            interpolants[j].evaluate(clipTime);\n            propertyMixers[j].accumulateAdditive(weight);\n          }\n          break;\n        case NormalAnimationBlendMode:\n        default:\n          for (let j = 0, m = interpolants.length; j !== m; ++j) {\n            interpolants[j].evaluate(clipTime);\n            propertyMixers[j].accumulate(accuIndex, weight);\n          }\n      }\n    }\n  }\n  _updateWeight(time) {\n    let weight = 0;\n    if (this.enabled) {\n      weight = this.weight;\n      const interpolant = this._weightInterpolant;\n      if (interpolant !== null) {\n        const interpolantValue = interpolant.evaluate(time)[0];\n        weight *= interpolantValue;\n        if (time > interpolant.parameterPositions[1]) {\n          this.stopFading();\n          if (interpolantValue === 0) {\n            // faded out, disable\n            this.enabled = false;\n          }\n        }\n      }\n    }\n    this._effectiveWeight = weight;\n    return weight;\n  }\n  _updateTimeScale(time) {\n    let timeScale = 0;\n    if (!this.paused) {\n      timeScale = this.timeScale;\n      const interpolant = this._timeScaleInterpolant;\n      if (interpolant !== null) {\n        const interpolantValue = interpolant.evaluate(time)[0];\n        timeScale *= interpolantValue;\n        if (time > interpolant.parameterPositions[1]) {\n          this.stopWarping();\n          if (timeScale === 0) {\n            // motion has halted, pause\n            this.paused = true;\n          } else {\n            // warp done - apply final time scale\n            this.timeScale = timeScale;\n          }\n        }\n      }\n    }\n    this._effectiveTimeScale = timeScale;\n    return timeScale;\n  }\n  _updateTime(deltaTime) {\n    const duration = this._clip.duration;\n    const loop = this.loop;\n    let time = this.time + deltaTime;\n    let loopCount = this._loopCount;\n    const pingPong = loop === LoopPingPong;\n    if (deltaTime === 0) {\n      if (loopCount === -1) return time;\n      return pingPong && (loopCount & 1) === 1 ? duration - time : time;\n    }\n    if (loop === LoopOnce) {\n      if (loopCount === -1) {\n        // just started\n\n        this._loopCount = 0;\n        this._setEndings(true, true, false);\n      }\n      handle_stop: {\n        if (time >= duration) {\n          time = duration;\n        } else if (time < 0) {\n          time = 0;\n        } else {\n          this.time = time;\n          break handle_stop;\n        }\n        if (this.clampWhenFinished) this.paused = true;else this.enabled = false;\n        this.time = time;\n        this._mixer.dispatchEvent({\n          type: 'finished',\n          action: this,\n          direction: deltaTime < 0 ? -1 : 1\n        });\n      }\n    } else {\n      // repetitive Repeat or PingPong\n\n      if (loopCount === -1) {\n        // just started\n\n        if (deltaTime >= 0) {\n          loopCount = 0;\n          this._setEndings(true, this.repetitions === 0, pingPong);\n        } else {\n          // when looping in reverse direction, the initial\n          // transition through zero counts as a repetition,\n          // so leave loopCount at -1\n\n          this._setEndings(this.repetitions === 0, true, pingPong);\n        }\n      }\n      if (time >= duration || time < 0) {\n        // wrap around\n\n        const loopDelta = Math.floor(time / duration); // signed\n        time -= duration * loopDelta;\n        loopCount += Math.abs(loopDelta);\n        const pending = this.repetitions - loopCount;\n        if (pending <= 0) {\n          // have to stop (switch state, clamp time, fire event)\n\n          if (this.clampWhenFinished) this.paused = true;else this.enabled = false;\n          time = deltaTime > 0 ? duration : 0;\n          this.time = time;\n          this._mixer.dispatchEvent({\n            type: 'finished',\n            action: this,\n            direction: deltaTime > 0 ? 1 : -1\n          });\n        } else {\n          // keep running\n\n          if (pending === 1) {\n            // entering the last round\n\n            const atStart = deltaTime < 0;\n            this._setEndings(atStart, !atStart, pingPong);\n          } else {\n            this._setEndings(false, false, pingPong);\n          }\n          this._loopCount = loopCount;\n          this.time = time;\n          this._mixer.dispatchEvent({\n            type: 'loop',\n            action: this,\n            loopDelta: loopDelta\n          });\n        }\n      } else {\n        this.time = time;\n      }\n      if (pingPong && (loopCount & 1) === 1) {\n        // invert time for the \"pong round\"\n\n        return duration - time;\n      }\n    }\n    return time;\n  }\n  _setEndings(atStart, atEnd, pingPong) {\n    const settings = this._interpolantSettings;\n    if (pingPong) {\n      settings.endingStart = ZeroSlopeEnding;\n      settings.endingEnd = ZeroSlopeEnding;\n    } else {\n      // assuming for LoopOnce atStart == atEnd == true\n\n      if (atStart) {\n        settings.endingStart = this.zeroSlopeAtStart ? ZeroSlopeEnding : ZeroCurvatureEnding;\n      } else {\n        settings.endingStart = WrapAroundEnding;\n      }\n      if (atEnd) {\n        settings.endingEnd = this.zeroSlopeAtEnd ? ZeroSlopeEnding : ZeroCurvatureEnding;\n      } else {\n        settings.endingEnd = WrapAroundEnding;\n      }\n    }\n  }\n  _scheduleFading(duration, weightNow, weightThen) {\n    const mixer = this._mixer,\n      now = mixer.time;\n    let interpolant = this._weightInterpolant;\n    if (interpolant === null) {\n      interpolant = mixer._lendControlInterpolant();\n      this._weightInterpolant = interpolant;\n    }\n    const times = interpolant.parameterPositions,\n      values = interpolant.sampleValues;\n    times[0] = now;\n    values[0] = weightNow;\n    times[1] = now + duration;\n    values[1] = weightThen;\n    return this;\n  }\n}\nfunction AnimationMixer(root) {\n  this._root = root;\n  this._initMemoryManager();\n  this._accuIndex = 0;\n  this.time = 0;\n  this.timeScale = 1.0;\n}\nAnimationMixer.prototype = _extends__default['default'](Object.create(EventDispatcher.prototype), {\n  constructor: AnimationMixer,\n  _bindAction: function (action, prototypeAction) {\n    const root = action._localRoot || this._root,\n      tracks = action._clip.tracks,\n      nTracks = tracks.length,\n      bindings = action._propertyBindings,\n      interpolants = action._interpolants,\n      rootUuid = root.uuid,\n      bindingsByRoot = this._bindingsByRootAndName;\n    let bindingsByName = bindingsByRoot[rootUuid];\n    if (bindingsByName === undefined) {\n      bindingsByName = {};\n      bindingsByRoot[rootUuid] = bindingsByName;\n    }\n    for (let i = 0; i !== nTracks; ++i) {\n      const track = tracks[i],\n        trackName = track.name;\n      let binding = bindingsByName[trackName];\n      if (binding !== undefined) {\n        bindings[i] = binding;\n      } else {\n        binding = bindings[i];\n        if (binding !== undefined) {\n          // existing binding, make sure the cache knows\n\n          if (binding._cacheIndex === null) {\n            ++binding.referenceCount;\n            this._addInactiveBinding(binding, rootUuid, trackName);\n          }\n          continue;\n        }\n        const path = prototypeAction && prototypeAction._propertyBindings[i].binding.parsedPath;\n        binding = new PropertyMixer(PropertyBinding.create(root, trackName, path), track.ValueTypeName, track.getValueSize());\n        ++binding.referenceCount;\n        this._addInactiveBinding(binding, rootUuid, trackName);\n        bindings[i] = binding;\n      }\n      interpolants[i].resultBuffer = binding.buffer;\n    }\n  },\n  _activateAction: function (action) {\n    if (!this._isActiveAction(action)) {\n      if (action._cacheIndex === null) {\n        // this action has been forgotten by the cache, but the user\n        // appears to be still using it -> rebind\n\n        const rootUuid = (action._localRoot || this._root).uuid,\n          clipUuid = action._clip.uuid,\n          actionsForClip = this._actionsByClip[clipUuid];\n        this._bindAction(action, actionsForClip && actionsForClip.knownActions[0]);\n        this._addInactiveAction(action, clipUuid, rootUuid);\n      }\n      const bindings = action._propertyBindings;\n\n      // increment reference counts / sort out state\n      for (let i = 0, n = bindings.length; i !== n; ++i) {\n        const binding = bindings[i];\n        if (binding.useCount++ === 0) {\n          this._lendBinding(binding);\n          binding.saveOriginalState();\n        }\n      }\n      this._lendAction(action);\n    }\n  },\n  _deactivateAction: function (action) {\n    if (this._isActiveAction(action)) {\n      const bindings = action._propertyBindings;\n\n      // decrement reference counts / sort out state\n      for (let i = 0, n = bindings.length; i !== n; ++i) {\n        const binding = bindings[i];\n        if (--binding.useCount === 0) {\n          binding.restoreOriginalState();\n          this._takeBackBinding(binding);\n        }\n      }\n      this._takeBackAction(action);\n    }\n  },\n  // Memory manager\n\n  _initMemoryManager: function () {\n    this._actions = []; // 'nActiveActions' followed by inactive ones\n    this._nActiveActions = 0;\n    this._actionsByClip = {};\n    // inside:\n    // {\n    // \tknownActions: Array< AnimationAction > - used as prototypes\n    // \tactionByRoot: AnimationAction - lookup\n    // }\n\n    this._bindings = []; // 'nActiveBindings' followed by inactive ones\n    this._nActiveBindings = 0;\n    this._bindingsByRootAndName = {}; // inside: Map< name, PropertyMixer >\n\n    this._controlInterpolants = []; // same game as above\n    this._nActiveControlInterpolants = 0;\n    const scope = this;\n    this.stats = {\n      actions: {\n        get total() {\n          return scope._actions.length;\n        },\n        get inUse() {\n          return scope._nActiveActions;\n        }\n      },\n      bindings: {\n        get total() {\n          return scope._bindings.length;\n        },\n        get inUse() {\n          return scope._nActiveBindings;\n        }\n      },\n      controlInterpolants: {\n        get total() {\n          return scope._controlInterpolants.length;\n        },\n        get inUse() {\n          return scope._nActiveControlInterpolants;\n        }\n      }\n    };\n  },\n  // Memory management for AnimationAction objects\n\n  _isActiveAction: function (action) {\n    const index = action._cacheIndex;\n    return index !== null && index < this._nActiveActions;\n  },\n  _addInactiveAction: function (action, clipUuid, rootUuid) {\n    const actions = this._actions,\n      actionsByClip = this._actionsByClip;\n    let actionsForClip = actionsByClip[clipUuid];\n    if (actionsForClip === undefined) {\n      actionsForClip = {\n        knownActions: [action],\n        actionByRoot: {}\n      };\n      action._byClipCacheIndex = 0;\n      actionsByClip[clipUuid] = actionsForClip;\n    } else {\n      const knownActions = actionsForClip.knownActions;\n      action._byClipCacheIndex = knownActions.length;\n      knownActions.push(action);\n    }\n    action._cacheIndex = actions.length;\n    actions.push(action);\n    actionsForClip.actionByRoot[rootUuid] = action;\n  },\n  _removeInactiveAction: function (action) {\n    const actions = this._actions,\n      lastInactiveAction = actions[actions.length - 1],\n      cacheIndex = action._cacheIndex;\n    lastInactiveAction._cacheIndex = cacheIndex;\n    actions[cacheIndex] = lastInactiveAction;\n    actions.pop();\n    action._cacheIndex = null;\n    const clipUuid = action._clip.uuid,\n      actionsByClip = this._actionsByClip,\n      actionsForClip = actionsByClip[clipUuid],\n      knownActionsForClip = actionsForClip.knownActions,\n      lastKnownAction = knownActionsForClip[knownActionsForClip.length - 1],\n      byClipCacheIndex = action._byClipCacheIndex;\n    lastKnownAction._byClipCacheIndex = byClipCacheIndex;\n    knownActionsForClip[byClipCacheIndex] = lastKnownAction;\n    knownActionsForClip.pop();\n    action._byClipCacheIndex = null;\n    const actionByRoot = actionsForClip.actionByRoot,\n      rootUuid = (action._localRoot || this._root).uuid;\n    delete actionByRoot[rootUuid];\n    if (knownActionsForClip.length === 0) {\n      delete actionsByClip[clipUuid];\n    }\n    this._removeInactiveBindingsForAction(action);\n  },\n  _removeInactiveBindingsForAction: function (action) {\n    const bindings = action._propertyBindings;\n    for (let i = 0, n = bindings.length; i !== n; ++i) {\n      const binding = bindings[i];\n      if (--binding.referenceCount === 0) {\n        this._removeInactiveBinding(binding);\n      }\n    }\n  },\n  _lendAction: function (action) {\n    // [ active actions |  inactive actions  ]\n    // [  active actions >| inactive actions ]\n    //                 s        a\n    //                  <-swap->\n    //                 a        s\n\n    const actions = this._actions,\n      prevIndex = action._cacheIndex,\n      lastActiveIndex = this._nActiveActions++,\n      firstInactiveAction = actions[lastActiveIndex];\n    action._cacheIndex = lastActiveIndex;\n    actions[lastActiveIndex] = action;\n    firstInactiveAction._cacheIndex = prevIndex;\n    actions[prevIndex] = firstInactiveAction;\n  },\n  _takeBackAction: function (action) {\n    // [  active actions  | inactive actions ]\n    // [ active actions |< inactive actions  ]\n    //        a        s\n    //         <-swap->\n    //        s        a\n\n    const actions = this._actions,\n      prevIndex = action._cacheIndex,\n      firstInactiveIndex = --this._nActiveActions,\n      lastActiveAction = actions[firstInactiveIndex];\n    action._cacheIndex = firstInactiveIndex;\n    actions[firstInactiveIndex] = action;\n    lastActiveAction._cacheIndex = prevIndex;\n    actions[prevIndex] = lastActiveAction;\n  },\n  // Memory management for PropertyMixer objects\n\n  _addInactiveBinding: function (binding, rootUuid, trackName) {\n    const bindingsByRoot = this._bindingsByRootAndName,\n      bindings = this._bindings;\n    let bindingByName = bindingsByRoot[rootUuid];\n    if (bindingByName === undefined) {\n      bindingByName = {};\n      bindingsByRoot[rootUuid] = bindingByName;\n    }\n    bindingByName[trackName] = binding;\n    binding._cacheIndex = bindings.length;\n    bindings.push(binding);\n  },\n  _removeInactiveBinding: function (binding) {\n    const bindings = this._bindings,\n      propBinding = binding.binding,\n      rootUuid = propBinding.rootNode.uuid,\n      trackName = propBinding.path,\n      bindingsByRoot = this._bindingsByRootAndName,\n      bindingByName = bindingsByRoot[rootUuid],\n      lastInactiveBinding = bindings[bindings.length - 1],\n      cacheIndex = binding._cacheIndex;\n    lastInactiveBinding._cacheIndex = cacheIndex;\n    bindings[cacheIndex] = lastInactiveBinding;\n    bindings.pop();\n    delete bindingByName[trackName];\n    if (Object.keys(bindingByName).length === 0) {\n      delete bindingsByRoot[rootUuid];\n    }\n  },\n  _lendBinding: function (binding) {\n    const bindings = this._bindings,\n      prevIndex = binding._cacheIndex,\n      lastActiveIndex = this._nActiveBindings++,\n      firstInactiveBinding = bindings[lastActiveIndex];\n    binding._cacheIndex = lastActiveIndex;\n    bindings[lastActiveIndex] = binding;\n    firstInactiveBinding._cacheIndex = prevIndex;\n    bindings[prevIndex] = firstInactiveBinding;\n  },\n  _takeBackBinding: function (binding) {\n    const bindings = this._bindings,\n      prevIndex = binding._cacheIndex,\n      firstInactiveIndex = --this._nActiveBindings,\n      lastActiveBinding = bindings[firstInactiveIndex];\n    binding._cacheIndex = firstInactiveIndex;\n    bindings[firstInactiveIndex] = binding;\n    lastActiveBinding._cacheIndex = prevIndex;\n    bindings[prevIndex] = lastActiveBinding;\n  },\n  // Memory management of Interpolants for weight and time scale\n\n  _lendControlInterpolant: function () {\n    const interpolants = this._controlInterpolants,\n      lastActiveIndex = this._nActiveControlInterpolants++;\n    let interpolant = interpolants[lastActiveIndex];\n    if (interpolant === undefined) {\n      interpolant = new LinearInterpolant(new Float32Array(2), new Float32Array(2), 1, this._controlInterpolantsResultBuffer);\n      interpolant.__cacheIndex = lastActiveIndex;\n      interpolants[lastActiveIndex] = interpolant;\n    }\n    return interpolant;\n  },\n  _takeBackControlInterpolant: function (interpolant) {\n    const interpolants = this._controlInterpolants,\n      prevIndex = interpolant.__cacheIndex,\n      firstInactiveIndex = --this._nActiveControlInterpolants,\n      lastActiveInterpolant = interpolants[firstInactiveIndex];\n    interpolant.__cacheIndex = firstInactiveIndex;\n    interpolants[firstInactiveIndex] = interpolant;\n    lastActiveInterpolant.__cacheIndex = prevIndex;\n    interpolants[prevIndex] = lastActiveInterpolant;\n  },\n  _controlInterpolantsResultBuffer: new Float32Array(1),\n  // return an action for a clip optionally using a custom root target\n  // object (this method allocates a lot of dynamic memory in case a\n  // previously unknown clip/root combination is specified)\n  clipAction: function (clip, optionalRoot, blendMode) {\n    const root = optionalRoot || this._root,\n      rootUuid = root.uuid;\n    let clipObject = typeof clip === 'string' ? AnimationClip.findByName(root, clip) : clip;\n    const clipUuid = clipObject !== null ? clipObject.uuid : clip;\n    const actionsForClip = this._actionsByClip[clipUuid];\n    let prototypeAction = null;\n    if (blendMode === undefined) {\n      if (clipObject !== null) {\n        blendMode = clipObject.blendMode;\n      } else {\n        blendMode = NormalAnimationBlendMode;\n      }\n    }\n    if (actionsForClip !== undefined) {\n      const existingAction = actionsForClip.actionByRoot[rootUuid];\n      if (existingAction !== undefined && existingAction.blendMode === blendMode) {\n        return existingAction;\n      }\n\n      // we know the clip, so we don't have to parse all\n      // the bindings again but can just copy\n      prototypeAction = actionsForClip.knownActions[0];\n\n      // also, take the clip from the prototype action\n      if (clipObject === null) clipObject = prototypeAction._clip;\n    }\n\n    // clip must be known when specified via string\n    if (clipObject === null) return null;\n\n    // allocate all resources required to run it\n    const newAction = new AnimationAction(this, clipObject, optionalRoot, blendMode);\n    this._bindAction(newAction, prototypeAction);\n\n    // and make the action known to the memory manager\n    this._addInactiveAction(newAction, clipUuid, rootUuid);\n    return newAction;\n  },\n  // get an existing action\n  existingAction: function (clip, optionalRoot) {\n    const root = optionalRoot || this._root,\n      rootUuid = root.uuid,\n      clipObject = typeof clip === 'string' ? AnimationClip.findByName(root, clip) : clip,\n      clipUuid = clipObject ? clipObject.uuid : clip,\n      actionsForClip = this._actionsByClip[clipUuid];\n    if (actionsForClip !== undefined) {\n      return actionsForClip.actionByRoot[rootUuid] || null;\n    }\n    return null;\n  },\n  // deactivates all previously scheduled actions\n  stopAllAction: function () {\n    const actions = this._actions,\n      nActions = this._nActiveActions;\n    for (let i = nActions - 1; i >= 0; --i) {\n      actions[i].stop();\n    }\n    return this;\n  },\n  // advance the time and update apply the animation\n  update: function (deltaTime) {\n    deltaTime *= this.timeScale;\n    const actions = this._actions,\n      nActions = this._nActiveActions,\n      time = this.time += deltaTime,\n      timeDirection = Math.sign(deltaTime),\n      accuIndex = this._accuIndex ^= 1;\n\n    // run active actions\n\n    for (let i = 0; i !== nActions; ++i) {\n      const action = actions[i];\n      action._update(time, deltaTime, timeDirection, accuIndex);\n    }\n\n    // update scene graph\n\n    const bindings = this._bindings,\n      nBindings = this._nActiveBindings;\n    for (let i = 0; i !== nBindings; ++i) {\n      bindings[i].apply(accuIndex);\n    }\n    return this;\n  },\n  // Allows you to seek to a specific time in an animation.\n  setTime: function (timeInSeconds) {\n    this.time = 0; // Zero out time attribute for AnimationMixer object;\n    for (let i = 0; i < this._actions.length; i++) {\n      this._actions[i].time = 0; // Zero out time attribute for all associated AnimationAction objects.\n    }\n\n    return this.update(timeInSeconds); // Update used to set exact time. Returns \"this\" AnimationMixer object.\n  },\n\n  // return this mixer's root target object\n  getRoot: function () {\n    return this._root;\n  },\n  // free all resources specific to a particular clip\n  uncacheClip: function (clip) {\n    const actions = this._actions,\n      clipUuid = clip.uuid,\n      actionsByClip = this._actionsByClip,\n      actionsForClip = actionsByClip[clipUuid];\n    if (actionsForClip !== undefined) {\n      // note: just calling _removeInactiveAction would mess up the\n      // iteration state and also require updating the state we can\n      // just throw away\n\n      const actionsToRemove = actionsForClip.knownActions;\n      for (let i = 0, n = actionsToRemove.length; i !== n; ++i) {\n        const action = actionsToRemove[i];\n        this._deactivateAction(action);\n        const cacheIndex = action._cacheIndex,\n          lastInactiveAction = actions[actions.length - 1];\n        action._cacheIndex = null;\n        action._byClipCacheIndex = null;\n        lastInactiveAction._cacheIndex = cacheIndex;\n        actions[cacheIndex] = lastInactiveAction;\n        actions.pop();\n        this._removeInactiveBindingsForAction(action);\n      }\n      delete actionsByClip[clipUuid];\n    }\n  },\n  // free all resources specific to a particular root target object\n  uncacheRoot: function (root) {\n    const rootUuid = root.uuid,\n      actionsByClip = this._actionsByClip;\n    for (const clipUuid in actionsByClip) {\n      const actionByRoot = actionsByClip[clipUuid].actionByRoot,\n        action = actionByRoot[rootUuid];\n      if (action !== undefined) {\n        this._deactivateAction(action);\n        this._removeInactiveAction(action);\n      }\n    }\n    const bindingsByRoot = this._bindingsByRootAndName,\n      bindingByName = bindingsByRoot[rootUuid];\n    if (bindingByName !== undefined) {\n      for (const trackName in bindingByName) {\n        const binding = bindingByName[trackName];\n        binding.restoreOriginalState();\n        this._removeInactiveBinding(binding);\n      }\n    }\n  },\n  // remove a targeted clip from the cache\n  uncacheAction: function (clip, optionalRoot) {\n    const action = this.existingAction(clip, optionalRoot);\n    if (action !== null) {\n      this._deactivateAction(action);\n      this._removeInactiveAction(action);\n    }\n  }\n});\nclass Uniform {\n  constructor(value) {\n    if (typeof value === 'string') {\n      console.warn('THREE.Uniform: Type parameter is no longer needed.');\n      value = arguments[1];\n    }\n    this.value = value;\n  }\n  clone() {\n    return new Uniform(this.value.clone === undefined ? this.value : this.value.clone());\n  }\n}\nfunction InstancedInterleavedBuffer(array, stride, meshPerAttribute) {\n  InterleavedBuffer.call(this, array, stride);\n  this.meshPerAttribute = meshPerAttribute || 1;\n}\nInstancedInterleavedBuffer.prototype = _extends__default['default'](Object.create(InterleavedBuffer.prototype), {\n  constructor: InstancedInterleavedBuffer,\n  isInstancedInterleavedBuffer: true,\n  copy: function (source) {\n    InterleavedBuffer.prototype.copy.call(this, source);\n    this.meshPerAttribute = source.meshPerAttribute;\n    return this;\n  },\n  clone: function (data) {\n    const ib = InterleavedBuffer.prototype.clone.call(this, data);\n    ib.meshPerAttribute = this.meshPerAttribute;\n    return ib;\n  },\n  toJSON: function (data) {\n    const json = InterleavedBuffer.prototype.toJSON.call(this, data);\n    json.isInstancedInterleavedBuffer = true;\n    json.meshPerAttribute = this.meshPerAttribute;\n    return json;\n  }\n});\nfunction GLBufferAttribute(buffer, type, itemSize, elementSize, count) {\n  this.buffer = buffer;\n  this.type = type;\n  this.itemSize = itemSize;\n  this.elementSize = elementSize;\n  this.count = count;\n  this.version = 0;\n}\nObject.defineProperty(GLBufferAttribute.prototype, 'needsUpdate', {\n  set: function (value) {\n    if (value === true) this.version++;\n  }\n});\n_extends__default['default'](GLBufferAttribute.prototype, {\n  isGLBufferAttribute: true,\n  setBuffer: function (buffer) {\n    this.buffer = buffer;\n    return this;\n  },\n  setType: function (type, elementSize) {\n    this.type = type;\n    this.elementSize = elementSize;\n    return this;\n  },\n  setItemSize: function (itemSize) {\n    this.itemSize = itemSize;\n    return this;\n  },\n  setCount: function (count) {\n    this.count = count;\n    return this;\n  }\n});\nfunction Raycaster(origin, direction, near, far) {\n  this.ray = new Ray(origin, direction);\n  // direction is assumed to be normalized (for accurate distance calculations)\n\n  this.near = near || 0;\n  this.far = far || Infinity;\n  this.camera = null;\n  this.layers = new Layers();\n  this.params = {\n    Mesh: {},\n    Line: {\n      threshold: 1\n    },\n    LOD: {},\n    Points: {\n      threshold: 1\n    },\n    Sprite: {}\n  };\n  Object.defineProperties(this.params, {\n    PointCloud: {\n      get: function () {\n        console.warn('THREE.Raycaster: params.PointCloud has been renamed to params.Points.');\n        return this.Points;\n      }\n    }\n  });\n}\nfunction ascSort(a, b) {\n  return a.distance - b.distance;\n}\nfunction intersectObject(object, raycaster, intersects, recursive) {\n  if (object.layers.test(raycaster.layers)) {\n    object.raycast(raycaster, intersects);\n  }\n  if (recursive === true) {\n    const children = object.children;\n    for (let i = 0, l = children.length; i < l; i++) {\n      intersectObject(children[i], raycaster, intersects, true);\n    }\n  }\n}\n_extends__default['default'](Raycaster.prototype, {\n  set: function (origin, direction) {\n    // direction is assumed to be normalized (for accurate distance calculations)\n\n    this.ray.set(origin, direction);\n  },\n  setFromCamera: function (coords, camera) {\n    if (camera && camera.isPerspectiveCamera) {\n      this.ray.origin.setFromMatrixPosition(camera.matrixWorld);\n      this.ray.direction.set(coords.x, coords.y, 0.5).unproject(camera).sub(this.ray.origin).normalize();\n      this.camera = camera;\n    } else if (camera && camera.isOrthographicCamera) {\n      this.ray.origin.set(coords.x, coords.y, (camera.near + camera.far) / (camera.near - camera.far)).unproject(camera); // set origin in plane of camera\n      this.ray.direction.set(0, 0, -1).transformDirection(camera.matrixWorld);\n      this.camera = camera;\n    } else {\n      console.error('THREE.Raycaster: Unsupported camera type: ' + camera.type);\n    }\n  },\n  intersectObject: function (object, recursive, optionalTarget) {\n    const intersects = optionalTarget || [];\n    intersectObject(object, this, intersects, recursive);\n    intersects.sort(ascSort);\n    return intersects;\n  },\n  intersectObjects: function (objects, recursive, optionalTarget) {\n    const intersects = optionalTarget || [];\n    if (Array.isArray(objects) === false) {\n      console.warn('THREE.Raycaster.intersectObjects: objects is not an Array.');\n      return intersects;\n    }\n    for (let i = 0, l = objects.length; i < l; i++) {\n      intersectObject(objects[i], this, intersects, recursive);\n    }\n    intersects.sort(ascSort);\n    return intersects;\n  }\n});\n\n/**\n * Ref: https://en.wikipedia.org/wiki/Spherical_coordinate_system\n *\n * The polar angle (phi) is measured from the positive y-axis. The positive y-axis is up.\n * The azimuthal angle (theta) is measured from the positive z-axis.\n */\n\nclass Spherical {\n  constructor(radius = 1, phi = 0, theta = 0) {\n    this.radius = radius;\n    this.phi = phi; // polar angle\n    this.theta = theta; // azimuthal angle\n\n    return this;\n  }\n  set(radius, phi, theta) {\n    this.radius = radius;\n    this.phi = phi;\n    this.theta = theta;\n    return this;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(other) {\n    this.radius = other.radius;\n    this.phi = other.phi;\n    this.theta = other.theta;\n    return this;\n  }\n\n  // restrict phi to be betwee EPS and PI-EPS\n  makeSafe() {\n    const EPS = 0.000001;\n    this.phi = Math.max(EPS, Math.min(Math.PI - EPS, this.phi));\n    return this;\n  }\n  setFromVector3(v) {\n    return this.setFromCartesianCoords(v.x, v.y, v.z);\n  }\n  setFromCartesianCoords(x, y, z) {\n    this.radius = Math.sqrt(x * x + y * y + z * z);\n    if (this.radius === 0) {\n      this.theta = 0;\n      this.phi = 0;\n    } else {\n      this.theta = Math.atan2(x, z);\n      this.phi = Math.acos(MathUtils.clamp(y / this.radius, -1, 1));\n    }\n    return this;\n  }\n}\nconst _vector$8 = /*@__PURE__*/new Vector2();\nclass Box2 {\n  constructor(min, max) {\n    Object.defineProperty(this, 'isBox2', {\n      value: true\n    });\n    this.min = min !== undefined ? min : new Vector2(+Infinity, +Infinity);\n    this.max = max !== undefined ? max : new Vector2(-Infinity, -Infinity);\n  }\n  set(min, max) {\n    this.min.copy(min);\n    this.max.copy(max);\n    return this;\n  }\n  setFromPoints(points) {\n    this.makeEmpty();\n    for (let i = 0, il = points.length; i < il; i++) {\n      this.expandByPoint(points[i]);\n    }\n    return this;\n  }\n  setFromCenterAndSize(center, size) {\n    const halfSize = _vector$8.copy(size).multiplyScalar(0.5);\n    this.min.copy(center).sub(halfSize);\n    this.max.copy(center).add(halfSize);\n    return this;\n  }\n  clone() {\n    return new this.constructor().copy(this);\n  }\n  copy(box) {\n    this.min.copy(box.min);\n    this.max.copy(box.max);\n    return this;\n  }\n  makeEmpty() {\n    this.min.x = this.min.y = +Infinity;\n    this.max.x = this.max.y = -Infinity;\n    return this;\n  }\n  isEmpty() {\n    // this is a more robust check for empty than ( volume <= 0 ) because volume can get positive with two negative axes\n\n    return this.max.x < this.min.x || this.max.y < this.min.y;\n  }\n  getCenter(target) {\n    if (target === undefined) {\n      console.warn('THREE.Box2: .getCenter() target is now required');\n      target = new Vector2();\n    }\n    return this.isEmpty() ? target.set(0, 0) : target.addVectors(this.min, this.max).multiplyScalar(0.5);\n  }\n  getSize(target) {\n    if (target === undefined) {\n      console.warn('THREE.Box2: .getSize() target is now required');\n      target = new Vector2();\n    }\n    return this.isEmpty() ? target.set(0, 0) : target.subVectors(this.max, this.min);\n  }\n  expandByPoint(point) {\n    this.min.min(point);\n    this.max.max(point);\n    return this;\n  }\n  expandByVector(vector) {\n    this.min.sub(vector);\n    this.max.add(vector);\n    return this;\n  }\n  expandByScalar(scalar) {\n    this.min.addScalar(-scalar);\n    this.max.addScalar(scalar);\n    return this;\n  }\n  containsPoint(point) {\n    return point.x < this.min.x || point.x > this.max.x || point.y < this.min.y || point.y > this.max.y ? false : true;\n  }\n  containsBox(box) {\n    return this.min.x <= box.min.x && box.max.x <= this.max.x && this.min.y <= box.min.y && box.max.y <= this.max.y;\n  }\n  getParameter(point, target) {\n    // This can potentially have a divide by zero if the box\n    // has a size dimension of 0.\n\n    if (target === undefined) {\n      console.warn('THREE.Box2: .getParameter() target is now required');\n      target = new Vector2();\n    }\n    return target.set((point.x - this.min.x) / (this.max.x - this.min.x), (point.y - this.min.y) / (this.max.y - this.min.y));\n  }\n  intersectsBox(box) {\n    // using 4 splitting planes to rule out intersections\n\n    return box.max.x < this.min.x || box.min.x > this.max.x || box.max.y < this.min.y || box.min.y > this.max.y ? false : true;\n  }\n  clampPoint(point, target) {\n    if (target === undefined) {\n      console.warn('THREE.Box2: .clampPoint() target is now required');\n      target = new Vector2();\n    }\n    return target.copy(point).clamp(this.min, this.max);\n  }\n  distanceToPoint(point) {\n    const clampedPoint = _vector$8.copy(point).clamp(this.min, this.max);\n    return clampedPoint.sub(point).length();\n  }\n  intersect(box) {\n    this.min.max(box.min);\n    this.max.min(box.max);\n    return this;\n  }\n  union(box) {\n    this.min.min(box.min);\n    this.max.max(box.max);\n    return this;\n  }\n  translate(offset) {\n    this.min.add(offset);\n    this.max.add(offset);\n    return this;\n  }\n  equals(box) {\n    return box.min.equals(this.min) && box.max.equals(this.max);\n  }\n}\nfunction ImmediateRenderObject(material) {\n  Object3D.call(this);\n  this.material = material;\n  this.render = function /* renderCallback */ () {};\n  this.hasPositions = false;\n  this.hasNormals = false;\n  this.hasColors = false;\n  this.hasUvs = false;\n  this.positionArray = null;\n  this.normalArray = null;\n  this.colorArray = null;\n  this.uvArray = null;\n  this.count = 0;\n}\nImmediateRenderObject.prototype = Object.create(Object3D.prototype);\nImmediateRenderObject.prototype.constructor = ImmediateRenderObject;\nImmediateRenderObject.prototype.isImmediateRenderObject = true;\nconst backgroundMaterial = new MeshBasicMaterial({\n  side: BackSide,\n  depthWrite: false,\n  depthTest: false\n});\nnew Mesh(new BoxGeometry(), backgroundMaterial);\n\n//\n\nCurve.create = function (construct, getPoint) {\n  console.log('THREE.Curve.create() has been deprecated');\n  construct.prototype = Object.create(Curve.prototype);\n  construct.prototype.constructor = construct;\n  construct.prototype.getPoint = getPoint;\n  return construct;\n};\n\n//\n\n_extends__default['default'](Path.prototype, {\n  fromPoints: function (points) {\n    console.warn('THREE.Path: .fromPoints() has been renamed to .setFromPoints().');\n    return this.setFromPoints(points);\n  }\n});\n\n//\n\nfunction Spline(points) {\n  console.warn('THREE.Spline has been removed. Use THREE.CatmullRomCurve3 instead.');\n  CatmullRomCurve3.call(this, points);\n  this.type = 'catmullrom';\n}\nSpline.prototype = Object.create(CatmullRomCurve3.prototype);\n_extends__default['default'](Spline.prototype, {\n  initFromArray: function /* a */\n  () {\n    console.error('THREE.Spline: .initFromArray() has been removed.');\n  },\n  getControlPointsArray: function /* optionalTarget */\n  () {\n    console.error('THREE.Spline: .getControlPointsArray() has been removed.');\n  },\n  reparametrizeByArcLength: function /* samplingCoef */\n  () {\n    console.error('THREE.Spline: .reparametrizeByArcLength() has been removed.');\n  }\n});\n\n//\n\n_extends__default['default'](Loader.prototype, {\n  extractUrlBase: function (url) {\n    console.warn('THREE.Loader: .extractUrlBase() has been deprecated. Use THREE.LoaderUtils.extractUrlBase() instead.');\n    return LoaderUtils.extractUrlBase(url);\n  }\n});\nLoader.Handlers = {\n  add: function /* regex, loader */\n  () {\n    console.error('THREE.Loader: Handlers.add() has been removed. Use LoadingManager.addHandler() instead.');\n  },\n  get: function /* file */\n  () {\n    console.error('THREE.Loader: Handlers.get() has been removed. Use LoadingManager.getHandler() instead.');\n  }\n};\n\n//\n\n_extends__default['default'](Box2.prototype, {\n  center: function (optionalTarget) {\n    console.warn('THREE.Box2: .center() has been renamed to .getCenter().');\n    return this.getCenter(optionalTarget);\n  },\n  empty: function () {\n    console.warn('THREE.Box2: .empty() has been renamed to .isEmpty().');\n    return this.isEmpty();\n  },\n  isIntersectionBox: function (box) {\n    console.warn('THREE.Box2: .isIntersectionBox() has been renamed to .intersectsBox().');\n    return this.intersectsBox(box);\n  },\n  size: function (optionalTarget) {\n    console.warn('THREE.Box2: .size() has been renamed to .getSize().');\n    return this.getSize(optionalTarget);\n  }\n});\n_extends__default['default'](Box3.prototype, {\n  center: function (optionalTarget) {\n    console.warn('THREE.Box3: .center() has been renamed to .getCenter().');\n    return this.getCenter(optionalTarget);\n  },\n  empty: function () {\n    console.warn('THREE.Box3: .empty() has been renamed to .isEmpty().');\n    return this.isEmpty();\n  },\n  isIntersectionBox: function (box) {\n    console.warn('THREE.Box3: .isIntersectionBox() has been renamed to .intersectsBox().');\n    return this.intersectsBox(box);\n  },\n  isIntersectionSphere: function (sphere) {\n    console.warn('THREE.Box3: .isIntersectionSphere() has been renamed to .intersectsSphere().');\n    return this.intersectsSphere(sphere);\n  },\n  size: function (optionalTarget) {\n    console.warn('THREE.Box3: .size() has been renamed to .getSize().');\n    return this.getSize(optionalTarget);\n  }\n});\n_extends__default['default'](Sphere.prototype, {\n  empty: function () {\n    console.warn('THREE.Sphere: .empty() has been renamed to .isEmpty().');\n    return this.isEmpty();\n  }\n});\nFrustum.prototype.setFromMatrix = function (m) {\n  console.warn('THREE.Frustum: .setFromMatrix() has been renamed to .setFromProjectionMatrix().');\n  return this.setFromProjectionMatrix(m);\n};\n_extends__default['default'](MathUtils, {\n  random16: function () {\n    console.warn('THREE.Math: .random16() has been deprecated. Use Math.random() instead.');\n    return Math.random();\n  },\n  nearestPowerOfTwo: function (value) {\n    console.warn('THREE.Math: .nearestPowerOfTwo() has been renamed to .floorPowerOfTwo().');\n    return MathUtils.floorPowerOfTwo(value);\n  },\n  nextPowerOfTwo: function (value) {\n    console.warn('THREE.Math: .nextPowerOfTwo() has been renamed to .ceilPowerOfTwo().');\n    return MathUtils.ceilPowerOfTwo(value);\n  }\n});\n_extends__default['default'](Matrix3.prototype, {\n  flattenToArrayOffset: function (array, offset) {\n    console.warn('THREE.Matrix3: .flattenToArrayOffset() has been deprecated. Use .toArray() instead.');\n    return this.toArray(array, offset);\n  },\n  multiplyVector3: function (vector) {\n    console.warn('THREE.Matrix3: .multiplyVector3() has been removed. Use vector.applyMatrix3( matrix ) instead.');\n    return vector.applyMatrix3(this);\n  },\n  multiplyVector3Array: function /* a */\n  () {\n    console.error('THREE.Matrix3: .multiplyVector3Array() has been removed.');\n  },\n  applyToBufferAttribute: function (attribute) {\n    console.warn('THREE.Matrix3: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix3( matrix ) instead.');\n    return attribute.applyMatrix3(this);\n  },\n  applyToVector3Array: function /* array, offset, length */\n  () {\n    console.error('THREE.Matrix3: .applyToVector3Array() has been removed.');\n  },\n  getInverse: function (matrix) {\n    console.warn('THREE.Matrix3: .getInverse() has been removed. Use matrixInv.copy( matrix ).invert(); instead.');\n    return this.copy(matrix).invert();\n  }\n});\n_extends__default['default'](Matrix4.prototype, {\n  extractPosition: function (m) {\n    console.warn('THREE.Matrix4: .extractPosition() has been renamed to .copyPosition().');\n    return this.copyPosition(m);\n  },\n  flattenToArrayOffset: function (array, offset) {\n    console.warn('THREE.Matrix4: .flattenToArrayOffset() has been deprecated. Use .toArray() instead.');\n    return this.toArray(array, offset);\n  },\n  getPosition: function () {\n    console.warn('THREE.Matrix4: .getPosition() has been removed. Use Vector3.setFromMatrixPosition( matrix ) instead.');\n    return new Vector3().setFromMatrixColumn(this, 3);\n  },\n  setRotationFromQuaternion: function (q) {\n    console.warn('THREE.Matrix4: .setRotationFromQuaternion() has been renamed to .makeRotationFromQuaternion().');\n    return this.makeRotationFromQuaternion(q);\n  },\n  multiplyToArray: function () {\n    console.warn('THREE.Matrix4: .multiplyToArray() has been removed.');\n  },\n  multiplyVector3: function (vector) {\n    console.warn('THREE.Matrix4: .multiplyVector3() has been removed. Use vector.applyMatrix4( matrix ) instead.');\n    return vector.applyMatrix4(this);\n  },\n  multiplyVector4: function (vector) {\n    console.warn('THREE.Matrix4: .multiplyVector4() has been removed. Use vector.applyMatrix4( matrix ) instead.');\n    return vector.applyMatrix4(this);\n  },\n  multiplyVector3Array: function /* a */\n  () {\n    console.error('THREE.Matrix4: .multiplyVector3Array() has been removed.');\n  },\n  rotateAxis: function (v) {\n    console.warn('THREE.Matrix4: .rotateAxis() has been removed. Use Vector3.transformDirection( matrix ) instead.');\n    v.transformDirection(this);\n  },\n  crossVector: function (vector) {\n    console.warn('THREE.Matrix4: .crossVector() has been removed. Use vector.applyMatrix4( matrix ) instead.');\n    return vector.applyMatrix4(this);\n  },\n  translate: function () {\n    console.error('THREE.Matrix4: .translate() has been removed.');\n  },\n  rotateX: function () {\n    console.error('THREE.Matrix4: .rotateX() has been removed.');\n  },\n  rotateY: function () {\n    console.error('THREE.Matrix4: .rotateY() has been removed.');\n  },\n  rotateZ: function () {\n    console.error('THREE.Matrix4: .rotateZ() has been removed.');\n  },\n  rotateByAxis: function () {\n    console.error('THREE.Matrix4: .rotateByAxis() has been removed.');\n  },\n  applyToBufferAttribute: function (attribute) {\n    console.warn('THREE.Matrix4: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix4( matrix ) instead.');\n    return attribute.applyMatrix4(this);\n  },\n  applyToVector3Array: function /* array, offset, length */\n  () {\n    console.error('THREE.Matrix4: .applyToVector3Array() has been removed.');\n  },\n  makeFrustum: function (left, right, bottom, top, near, far) {\n    console.warn('THREE.Matrix4: .makeFrustum() has been removed. Use .makePerspective( left, right, top, bottom, near, far ) instead.');\n    return this.makePerspective(left, right, top, bottom, near, far);\n  },\n  getInverse: function (matrix) {\n    console.warn('THREE.Matrix4: .getInverse() has been removed. Use matrixInv.copy( matrix ).invert(); instead.');\n    return this.copy(matrix).invert();\n  }\n});\nPlane.prototype.isIntersectionLine = function (line) {\n  console.warn('THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine().');\n  return this.intersectsLine(line);\n};\n_extends__default['default'](Quaternion.prototype, {\n  multiplyVector3: function (vector) {\n    console.warn('THREE.Quaternion: .multiplyVector3() has been removed. Use is now vector.applyQuaternion( quaternion ) instead.');\n    return vector.applyQuaternion(this);\n  },\n  inverse: function () {\n    console.warn('THREE.Quaternion: .inverse() has been renamed to invert().');\n    return this.invert();\n  }\n});\n_extends__default['default'](Ray.prototype, {\n  isIntersectionBox: function (box) {\n    console.warn('THREE.Ray: .isIntersectionBox() has been renamed to .intersectsBox().');\n    return this.intersectsBox(box);\n  },\n  isIntersectionPlane: function (plane) {\n    console.warn('THREE.Ray: .isIntersectionPlane() has been renamed to .intersectsPlane().');\n    return this.intersectsPlane(plane);\n  },\n  isIntersectionSphere: function (sphere) {\n    console.warn('THREE.Ray: .isIntersectionSphere() has been renamed to .intersectsSphere().');\n    return this.intersectsSphere(sphere);\n  }\n});\n_extends__default['default'](Triangle.prototype, {\n  area: function () {\n    console.warn('THREE.Triangle: .area() has been renamed to .getArea().');\n    return this.getArea();\n  },\n  barycoordFromPoint: function (point, target) {\n    console.warn('THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord().');\n    return this.getBarycoord(point, target);\n  },\n  midpoint: function (target) {\n    console.warn('THREE.Triangle: .midpoint() has been renamed to .getMidpoint().');\n    return this.getMidpoint(target);\n  },\n  normal: function (target) {\n    console.warn('THREE.Triangle: .normal() has been renamed to .getNormal().');\n    return this.getNormal(target);\n  },\n  plane: function (target) {\n    console.warn('THREE.Triangle: .plane() has been renamed to .getPlane().');\n    return this.getPlane(target);\n  }\n});\n_extends__default['default'](Triangle, {\n  barycoordFromPoint: function (point, a, b, c, target) {\n    console.warn('THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord().');\n    return Triangle.getBarycoord(point, a, b, c, target);\n  },\n  normal: function (a, b, c, target) {\n    console.warn('THREE.Triangle: .normal() has been renamed to .getNormal().');\n    return Triangle.getNormal(a, b, c, target);\n  }\n});\n_extends__default['default'](Shape.prototype, {\n  extractAllPoints: function (divisions) {\n    console.warn('THREE.Shape: .extractAllPoints() has been removed. Use .extractPoints() instead.');\n    return this.extractPoints(divisions);\n  },\n  extrude: function (options) {\n    console.warn('THREE.Shape: .extrude() has been removed. Use ExtrudeGeometry() instead.');\n    return new ExtrudeGeometry(this, options);\n  },\n  makeGeometry: function (options) {\n    console.warn('THREE.Shape: .makeGeometry() has been removed. Use ShapeGeometry() instead.');\n    return new ShapeGeometry(this, options);\n  }\n});\n_extends__default['default'](Vector2.prototype, {\n  fromAttribute: function (attribute, index, offset) {\n    console.warn('THREE.Vector2: .fromAttribute() has been renamed to .fromBufferAttribute().');\n    return this.fromBufferAttribute(attribute, index, offset);\n  },\n  distanceToManhattan: function (v) {\n    console.warn('THREE.Vector2: .distanceToManhattan() has been renamed to .manhattanDistanceTo().');\n    return this.manhattanDistanceTo(v);\n  },\n  lengthManhattan: function () {\n    console.warn('THREE.Vector2: .lengthManhattan() has been renamed to .manhattanLength().');\n    return this.manhattanLength();\n  }\n});\n_extends__default['default'](Vector3.prototype, {\n  setEulerFromRotationMatrix: function () {\n    console.error('THREE.Vector3: .setEulerFromRotationMatrix() has been removed. Use Euler.setFromRotationMatrix() instead.');\n  },\n  setEulerFromQuaternion: function () {\n    console.error('THREE.Vector3: .setEulerFromQuaternion() has been removed. Use Euler.setFromQuaternion() instead.');\n  },\n  getPositionFromMatrix: function (m) {\n    console.warn('THREE.Vector3: .getPositionFromMatrix() has been renamed to .setFromMatrixPosition().');\n    return this.setFromMatrixPosition(m);\n  },\n  getScaleFromMatrix: function (m) {\n    console.warn('THREE.Vector3: .getScaleFromMatrix() has been renamed to .setFromMatrixScale().');\n    return this.setFromMatrixScale(m);\n  },\n  getColumnFromMatrix: function (index, matrix) {\n    console.warn('THREE.Vector3: .getColumnFromMatrix() has been renamed to .setFromMatrixColumn().');\n    return this.setFromMatrixColumn(matrix, index);\n  },\n  applyProjection: function (m) {\n    console.warn('THREE.Vector3: .applyProjection() has been removed. Use .applyMatrix4( m ) instead.');\n    return this.applyMatrix4(m);\n  },\n  fromAttribute: function (attribute, index, offset) {\n    console.warn('THREE.Vector3: .fromAttribute() has been renamed to .fromBufferAttribute().');\n    return this.fromBufferAttribute(attribute, index, offset);\n  },\n  distanceToManhattan: function (v) {\n    console.warn('THREE.Vector3: .distanceToManhattan() has been renamed to .manhattanDistanceTo().');\n    return this.manhattanDistanceTo(v);\n  },\n  lengthManhattan: function () {\n    console.warn('THREE.Vector3: .lengthManhattan() has been renamed to .manhattanLength().');\n    return this.manhattanLength();\n  }\n});\n_extends__default['default'](Vector4.prototype, {\n  fromAttribute: function (attribute, index, offset) {\n    console.warn('THREE.Vector4: .fromAttribute() has been renamed to .fromBufferAttribute().');\n    return this.fromBufferAttribute(attribute, index, offset);\n  },\n  lengthManhattan: function () {\n    console.warn('THREE.Vector4: .lengthManhattan() has been renamed to .manhattanLength().');\n    return this.manhattanLength();\n  }\n});\n\n//\n\n_extends__default['default'](Object3D.prototype, {\n  getChildByName: function (name) {\n    console.warn('THREE.Object3D: .getChildByName() has been renamed to .getObjectByName().');\n    return this.getObjectByName(name);\n  },\n  renderDepth: function () {\n    console.warn('THREE.Object3D: .renderDepth has been removed. Use .renderOrder, instead.');\n  },\n  translate: function (distance, axis) {\n    console.warn('THREE.Object3D: .translate() has been removed. Use .translateOnAxis( axis, distance ) instead.');\n    return this.translateOnAxis(axis, distance);\n  },\n  getWorldRotation: function () {\n    console.error('THREE.Object3D: .getWorldRotation() has been removed. Use THREE.Object3D.getWorldQuaternion( target ) instead.');\n  },\n  applyMatrix: function (matrix) {\n    console.warn('THREE.Object3D: .applyMatrix() has been renamed to .applyMatrix4().');\n    return this.applyMatrix4(matrix);\n  }\n});\nObject.defineProperties(Object3D.prototype, {\n  eulerOrder: {\n    get: function () {\n      console.warn('THREE.Object3D: .eulerOrder is now .rotation.order.');\n      return this.rotation.order;\n    },\n    set: function (value) {\n      console.warn('THREE.Object3D: .eulerOrder is now .rotation.order.');\n      this.rotation.order = value;\n    }\n  },\n  useQuaternion: {\n    get: function () {\n      console.warn('THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.');\n    },\n    set: function () {\n      console.warn('THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.');\n    }\n  }\n});\n_extends__default['default'](Mesh.prototype, {\n  setDrawMode: function () {\n    console.error('THREE.Mesh: .setDrawMode() has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.');\n  }\n});\nObject.defineProperties(Mesh.prototype, {\n  drawMode: {\n    get: function () {\n      console.error('THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode.');\n      return TrianglesDrawMode;\n    },\n    set: function () {\n      console.error('THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.');\n    }\n  }\n});\nObject.defineProperties(LOD.prototype, {\n  objects: {\n    get: function () {\n      console.warn('THREE.LOD: .objects has been renamed to .levels.');\n      return this.levels;\n    }\n  }\n});\nObject.defineProperty(Skeleton.prototype, 'useVertexTexture', {\n  get: function () {\n    console.warn('THREE.Skeleton: useVertexTexture has been removed.');\n  },\n  set: function () {\n    console.warn('THREE.Skeleton: useVertexTexture has been removed.');\n  }\n});\nSkinnedMesh.prototype.initBones = function () {\n  console.error('THREE.SkinnedMesh: initBones() has been removed.');\n};\nObject.defineProperty(Curve.prototype, '__arcLengthDivisions', {\n  get: function () {\n    console.warn('THREE.Curve: .__arcLengthDivisions is now .arcLengthDivisions.');\n    return this.arcLengthDivisions;\n  },\n  set: function (value) {\n    console.warn('THREE.Curve: .__arcLengthDivisions is now .arcLengthDivisions.');\n    this.arcLengthDivisions = value;\n  }\n});\n\n//\n\nPerspectiveCamera.prototype.setLens = function (focalLength, filmGauge) {\n  console.warn('THREE.PerspectiveCamera.setLens is deprecated. ' + 'Use .setFocalLength and .filmGauge for a photographic setup.');\n  if (filmGauge !== undefined) this.filmGauge = filmGauge;\n  this.setFocalLength(focalLength);\n};\n\n//\n\nObject.defineProperties(Light.prototype, {\n  onlyShadow: {\n    set: function () {\n      console.warn('THREE.Light: .onlyShadow has been removed.');\n    }\n  },\n  shadowCameraFov: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowCameraFov is now .shadow.camera.fov.');\n      this.shadow.camera.fov = value;\n    }\n  },\n  shadowCameraLeft: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowCameraLeft is now .shadow.camera.left.');\n      this.shadow.camera.left = value;\n    }\n  },\n  shadowCameraRight: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowCameraRight is now .shadow.camera.right.');\n      this.shadow.camera.right = value;\n    }\n  },\n  shadowCameraTop: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowCameraTop is now .shadow.camera.top.');\n      this.shadow.camera.top = value;\n    }\n  },\n  shadowCameraBottom: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowCameraBottom is now .shadow.camera.bottom.');\n      this.shadow.camera.bottom = value;\n    }\n  },\n  shadowCameraNear: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowCameraNear is now .shadow.camera.near.');\n      this.shadow.camera.near = value;\n    }\n  },\n  shadowCameraFar: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowCameraFar is now .shadow.camera.far.');\n      this.shadow.camera.far = value;\n    }\n  },\n  shadowCameraVisible: {\n    set: function () {\n      console.warn('THREE.Light: .shadowCameraVisible has been removed. Use new THREE.CameraHelper( light.shadow.camera ) instead.');\n    }\n  },\n  shadowBias: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowBias is now .shadow.bias.');\n      this.shadow.bias = value;\n    }\n  },\n  shadowDarkness: {\n    set: function () {\n      console.warn('THREE.Light: .shadowDarkness has been removed.');\n    }\n  },\n  shadowMapWidth: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowMapWidth is now .shadow.mapSize.width.');\n      this.shadow.mapSize.width = value;\n    }\n  },\n  shadowMapHeight: {\n    set: function (value) {\n      console.warn('THREE.Light: .shadowMapHeight is now .shadow.mapSize.height.');\n      this.shadow.mapSize.height = value;\n    }\n  }\n});\n\n//\n\nObject.defineProperties(BufferAttribute.prototype, {\n  length: {\n    get: function () {\n      console.warn('THREE.BufferAttribute: .length has been deprecated. Use .count instead.');\n      return this.array.length;\n    }\n  },\n  dynamic: {\n    get: function () {\n      console.warn('THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead.');\n      return this.usage === DynamicDrawUsage;\n    },\n    set: function /* value */\n    () {\n      console.warn('THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead.');\n      this.setUsage(DynamicDrawUsage);\n    }\n  }\n});\n_extends__default['default'](BufferAttribute.prototype, {\n  setDynamic: function (value) {\n    console.warn('THREE.BufferAttribute: .setDynamic() has been deprecated. Use .setUsage() instead.');\n    this.setUsage(value === true ? DynamicDrawUsage : StaticDrawUsage);\n    return this;\n  },\n  copyIndicesArray: function /* indices */\n  () {\n    console.error('THREE.BufferAttribute: .copyIndicesArray() has been removed.');\n  },\n  setArray: function /* array */\n  () {\n    console.error('THREE.BufferAttribute: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers');\n  }\n});\n_extends__default['default'](BufferGeometry.prototype, {\n  addIndex: function (index) {\n    console.warn('THREE.BufferGeometry: .addIndex() has been renamed to .setIndex().');\n    this.setIndex(index);\n  },\n  addAttribute: function (name, attribute) {\n    console.warn('THREE.BufferGeometry: .addAttribute() has been renamed to .setAttribute().');\n    if (!(attribute && attribute.isBufferAttribute) && !(attribute && attribute.isInterleavedBufferAttribute)) {\n      console.warn('THREE.BufferGeometry: .addAttribute() now expects ( name, attribute ).');\n      return this.setAttribute(name, new BufferAttribute(arguments[1], arguments[2]));\n    }\n    if (name === 'index') {\n      console.warn('THREE.BufferGeometry.addAttribute: Use .setIndex() for index attribute.');\n      this.setIndex(attribute);\n      return this;\n    }\n    return this.setAttribute(name, attribute);\n  },\n  addDrawCall: function (start, count, indexOffset) {\n    if (indexOffset !== undefined) {\n      console.warn('THREE.BufferGeometry: .addDrawCall() no longer supports indexOffset.');\n    }\n    console.warn('THREE.BufferGeometry: .addDrawCall() is now .addGroup().');\n    this.addGroup(start, count);\n  },\n  clearDrawCalls: function () {\n    console.warn('THREE.BufferGeometry: .clearDrawCalls() is now .clearGroups().');\n    this.clearGroups();\n  },\n  computeOffsets: function () {\n    console.warn('THREE.BufferGeometry: .computeOffsets() has been removed.');\n  },\n  removeAttribute: function (name) {\n    console.warn('THREE.BufferGeometry: .removeAttribute() has been renamed to .deleteAttribute().');\n    return this.deleteAttribute(name);\n  },\n  applyMatrix: function (matrix) {\n    console.warn('THREE.BufferGeometry: .applyMatrix() has been renamed to .applyMatrix4().');\n    return this.applyMatrix4(matrix);\n  }\n});\nObject.defineProperties(BufferGeometry.prototype, {\n  drawcalls: {\n    get: function () {\n      console.error('THREE.BufferGeometry: .drawcalls has been renamed to .groups.');\n      return this.groups;\n    }\n  },\n  offsets: {\n    get: function () {\n      console.warn('THREE.BufferGeometry: .offsets has been renamed to .groups.');\n      return this.groups;\n    }\n  }\n});\nObject.defineProperties(InstancedBufferGeometry.prototype, {\n  maxInstancedCount: {\n    get: function () {\n      console.warn('THREE.InstancedBufferGeometry: .maxInstancedCount has been renamed to .instanceCount.');\n      return this.instanceCount;\n    },\n    set: function (value) {\n      console.warn('THREE.InstancedBufferGeometry: .maxInstancedCount has been renamed to .instanceCount.');\n      this.instanceCount = value;\n    }\n  }\n});\nObject.defineProperties(Raycaster.prototype, {\n  linePrecision: {\n    get: function () {\n      console.warn('THREE.Raycaster: .linePrecision has been deprecated. Use .params.Line.threshold instead.');\n      return this.params.Line.threshold;\n    },\n    set: function (value) {\n      console.warn('THREE.Raycaster: .linePrecision has been deprecated. Use .params.Line.threshold instead.');\n      this.params.Line.threshold = value;\n    }\n  }\n});\nObject.defineProperties(InterleavedBuffer.prototype, {\n  dynamic: {\n    get: function () {\n      console.warn('THREE.InterleavedBuffer: .length has been deprecated. Use .usage instead.');\n      return this.usage === DynamicDrawUsage;\n    },\n    set: function (value) {\n      console.warn('THREE.InterleavedBuffer: .length has been deprecated. Use .usage instead.');\n      this.setUsage(value);\n    }\n  }\n});\n_extends__default['default'](InterleavedBuffer.prototype, {\n  setDynamic: function (value) {\n    console.warn('THREE.InterleavedBuffer: .setDynamic() has been deprecated. Use .setUsage() instead.');\n    this.setUsage(value === true ? DynamicDrawUsage : StaticDrawUsage);\n    return this;\n  },\n  setArray: function /* array */\n  () {\n    console.error('THREE.InterleavedBuffer: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers');\n  }\n});\n\n//\n\n_extends__default['default'](ExtrudeGeometry.prototype, {\n  getArrays: function () {\n    console.error('THREE.ExtrudeGeometry: .getArrays() has been removed.');\n  },\n  addShapeList: function () {\n    console.error('THREE.ExtrudeGeometry: .addShapeList() has been removed.');\n  },\n  addShape: function () {\n    console.error('THREE.ExtrudeGeometry: .addShape() has been removed.');\n  }\n});\n\n//\n\n_extends__default['default'](Scene.prototype, {\n  dispose: function () {\n    console.error('THREE.Scene: .dispose() has been removed.');\n  }\n});\n\n//\n\nObject.defineProperties(Uniform.prototype, {\n  dynamic: {\n    set: function () {\n      console.warn('THREE.Uniform: .dynamic has been removed. Use object.onBeforeRender() instead.');\n    }\n  },\n  onUpdate: {\n    value: function () {\n      console.warn('THREE.Uniform: .onUpdate() has been removed. Use object.onBeforeRender() instead.');\n      return this;\n    }\n  }\n});\n\n//\n\nObject.defineProperties(Material.prototype, {\n  wrapAround: {\n    get: function () {\n      console.warn('THREE.Material: .wrapAround has been removed.');\n    },\n    set: function () {\n      console.warn('THREE.Material: .wrapAround has been removed.');\n    }\n  },\n  overdraw: {\n    get: function () {\n      console.warn('THREE.Material: .overdraw has been removed.');\n    },\n    set: function () {\n      console.warn('THREE.Material: .overdraw has been removed.');\n    }\n  },\n  wrapRGB: {\n    get: function () {\n      console.warn('THREE.Material: .wrapRGB has been removed.');\n      return new Color();\n    }\n  },\n  shading: {\n    get: function () {\n      console.error('THREE.' + this.type + ': .shading has been removed. Use the boolean .flatShading instead.');\n    },\n    set: function (value) {\n      console.warn('THREE.' + this.type + ': .shading has been removed. Use the boolean .flatShading instead.');\n      this.flatShading = value === FlatShading;\n    }\n  },\n  stencilMask: {\n    get: function () {\n      console.warn('THREE.' + this.type + ': .stencilMask has been removed. Use .stencilFuncMask instead.');\n      return this.stencilFuncMask;\n    },\n    set: function (value) {\n      console.warn('THREE.' + this.type + ': .stencilMask has been removed. Use .stencilFuncMask instead.');\n      this.stencilFuncMask = value;\n    }\n  }\n});\nObject.defineProperties(MeshPhongMaterial.prototype, {\n  metal: {\n    get: function () {\n      console.warn('THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead.');\n      return false;\n    },\n    set: function () {\n      console.warn('THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead');\n    }\n  }\n});\nObject.defineProperties(MeshPhysicalMaterial.prototype, {\n  transparency: {\n    get: function () {\n      console.warn('THREE.MeshPhysicalMaterial: .transparency has been renamed to .transmission.');\n      return this.transmission;\n    },\n    set: function (value) {\n      console.warn('THREE.MeshPhysicalMaterial: .transparency has been renamed to .transmission.');\n      this.transmission = value;\n    }\n  }\n});\nObject.defineProperties(ShaderMaterial.prototype, {\n  derivatives: {\n    get: function () {\n      console.warn('THREE.ShaderMaterial: .derivatives has been moved to .extensions.derivatives.');\n      return this.extensions.derivatives;\n    },\n    set: function (value) {\n      console.warn('THREE. ShaderMaterial: .derivatives has been moved to .extensions.derivatives.');\n      this.extensions.derivatives = value;\n    }\n  }\n});\n\n//\n\n_extends__default['default'](WebGLRenderer.prototype, {\n  clearTarget: function (renderTarget, color, depth, stencil) {\n    console.warn('THREE.WebGLRenderer: .clearTarget() has been deprecated. Use .setRenderTarget() and .clear() instead.');\n    this.setRenderTarget(renderTarget);\n    this.clear(color, depth, stencil);\n  },\n  animate: function (callback) {\n    console.warn('THREE.WebGLRenderer: .animate() is now .setAnimationLoop().');\n    this.setAnimationLoop(callback);\n  },\n  getCurrentRenderTarget: function () {\n    console.warn('THREE.WebGLRenderer: .getCurrentRenderTarget() is now .getRenderTarget().');\n    return this.getRenderTarget();\n  },\n  getMaxAnisotropy: function () {\n    console.warn('THREE.WebGLRenderer: .getMaxAnisotropy() is now .capabilities.getMaxAnisotropy().');\n    return this.capabilities.getMaxAnisotropy();\n  },\n  getPrecision: function () {\n    console.warn('THREE.WebGLRenderer: .getPrecision() is now .capabilities.precision.');\n    return this.capabilities.precision;\n  },\n  resetGLState: function () {\n    console.warn('THREE.WebGLRenderer: .resetGLState() is now .state.reset().');\n    return this.state.reset();\n  },\n  supportsFloatTextures: function () {\n    console.warn('THREE.WebGLRenderer: .supportsFloatTextures() is now .extensions.get( \\'OES_texture_float\\' ).');\n    return this.extensions.get('OES_texture_float');\n  },\n  supportsHalfFloatTextures: function () {\n    console.warn('THREE.WebGLRenderer: .supportsHalfFloatTextures() is now .extensions.get( \\'OES_texture_half_float\\' ).');\n    return this.extensions.get('OES_texture_half_float');\n  },\n  supportsStandardDerivatives: function () {\n    console.warn('THREE.WebGLRenderer: .supportsStandardDerivatives() is now .extensions.get( \\'OES_standard_derivatives\\' ).');\n    return this.extensions.get('OES_standard_derivatives');\n  },\n  supportsCompressedTextureS3TC: function () {\n    console.warn('THREE.WebGLRenderer: .supportsCompressedTextureS3TC() is now .extensions.get( \\'WEBGL_compressed_texture_s3tc\\' ).');\n    return this.extensions.get('WEBGL_compressed_texture_s3tc');\n  },\n  supportsCompressedTexturePVRTC: function () {\n    console.warn('THREE.WebGLRenderer: .supportsCompressedTexturePVRTC() is now .extensions.get( \\'WEBGL_compressed_texture_pvrtc\\' ).');\n    return this.extensions.get('WEBGL_compressed_texture_pvrtc');\n  },\n  supportsBlendMinMax: function () {\n    console.warn('THREE.WebGLRenderer: .supportsBlendMinMax() is now .extensions.get( \\'EXT_blend_minmax\\' ).');\n    return this.extensions.get('EXT_blend_minmax');\n  },\n  supportsVertexTextures: function () {\n    console.warn('THREE.WebGLRenderer: .supportsVertexTextures() is now .capabilities.vertexTextures.');\n    return this.capabilities.vertexTextures;\n  },\n  supportsInstancedArrays: function () {\n    console.warn('THREE.WebGLRenderer: .supportsInstancedArrays() is now .extensions.get( \\'ANGLE_instanced_arrays\\' ).');\n    return this.extensions.get('ANGLE_instanced_arrays');\n  },\n  enableScissorTest: function (boolean) {\n    console.warn('THREE.WebGLRenderer: .enableScissorTest() is now .setScissorTest().');\n    this.setScissorTest(boolean);\n  },\n  initMaterial: function () {\n    console.warn('THREE.WebGLRenderer: .initMaterial() has been removed.');\n  },\n  addPrePlugin: function () {\n    console.warn('THREE.WebGLRenderer: .addPrePlugin() has been removed.');\n  },\n  addPostPlugin: function () {\n    console.warn('THREE.WebGLRenderer: .addPostPlugin() has been removed.');\n  },\n  updateShadowMap: function () {\n    console.warn('THREE.WebGLRenderer: .updateShadowMap() has been removed.');\n  },\n  setFaceCulling: function () {\n    console.warn('THREE.WebGLRenderer: .setFaceCulling() has been removed.');\n  },\n  allocTextureUnit: function () {\n    console.warn('THREE.WebGLRenderer: .allocTextureUnit() has been removed.');\n  },\n  setTexture: function () {\n    console.warn('THREE.WebGLRenderer: .setTexture() has been removed.');\n  },\n  setTexture2D: function () {\n    console.warn('THREE.WebGLRenderer: .setTexture2D() has been removed.');\n  },\n  setTextureCube: function () {\n    console.warn('THREE.WebGLRenderer: .setTextureCube() has been removed.');\n  },\n  getActiveMipMapLevel: function () {\n    console.warn('THREE.WebGLRenderer: .getActiveMipMapLevel() is now .getActiveMipmapLevel().');\n    return this.getActiveMipmapLevel();\n  }\n});\nObject.defineProperties(WebGLRenderer.prototype, {\n  shadowMapEnabled: {\n    get: function () {\n      return this.shadowMap.enabled;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderer: .shadowMapEnabled is now .shadowMap.enabled.');\n      this.shadowMap.enabled = value;\n    }\n  },\n  shadowMapType: {\n    get: function () {\n      return this.shadowMap.type;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderer: .shadowMapType is now .shadowMap.type.');\n      this.shadowMap.type = value;\n    }\n  },\n  shadowMapCullFace: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.');\n      return undefined;\n    },\n    set: function /* value */\n    () {\n      console.warn('THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.');\n    }\n  },\n  context: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .context has been removed. Use .getContext() instead.');\n      return this.getContext();\n    }\n  },\n  vr: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .vr has been renamed to .xr');\n      return this.xr;\n    }\n  },\n  gammaInput: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead.');\n      return false;\n    },\n    set: function () {\n      console.warn('THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead.');\n    }\n  },\n  gammaOutput: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead.');\n      return false;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead.');\n      this.outputEncoding = value === true ? sRGBEncoding : LinearEncoding;\n    }\n  },\n  toneMappingWhitePoint: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .toneMappingWhitePoint has been removed.');\n      return 1.0;\n    },\n    set: function () {\n      console.warn('THREE.WebGLRenderer: .toneMappingWhitePoint has been removed.');\n    }\n  }\n});\nObject.defineProperties(WebGLShadowMap.prototype, {\n  cullFace: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.');\n      return undefined;\n    },\n    set: function /* cullFace */\n    () {\n      console.warn('THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.');\n    }\n  },\n  renderReverseSided: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.');\n      return undefined;\n    },\n    set: function () {\n      console.warn('THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.');\n    }\n  },\n  renderSingleSided: {\n    get: function () {\n      console.warn('THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.');\n      return undefined;\n    },\n    set: function () {\n      console.warn('THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.');\n    }\n  }\n});\n\n//\n\nObject.defineProperties(WebGLRenderTarget.prototype, {\n  wrapS: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS.');\n      return this.texture.wrapS;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS.');\n      this.texture.wrapS = value;\n    }\n  },\n  wrapT: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT.');\n      return this.texture.wrapT;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT.');\n      this.texture.wrapT = value;\n    }\n  },\n  magFilter: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter.');\n      return this.texture.magFilter;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter.');\n      this.texture.magFilter = value;\n    }\n  },\n  minFilter: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter.');\n      return this.texture.minFilter;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter.');\n      this.texture.minFilter = value;\n    }\n  },\n  anisotropy: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy.');\n      return this.texture.anisotropy;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy.');\n      this.texture.anisotropy = value;\n    }\n  },\n  offset: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .offset is now .texture.offset.');\n      return this.texture.offset;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .offset is now .texture.offset.');\n      this.texture.offset = value;\n    }\n  },\n  repeat: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .repeat is now .texture.repeat.');\n      return this.texture.repeat;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .repeat is now .texture.repeat.');\n      this.texture.repeat = value;\n    }\n  },\n  format: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .format is now .texture.format.');\n      return this.texture.format;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .format is now .texture.format.');\n      this.texture.format = value;\n    }\n  },\n  type: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .type is now .texture.type.');\n      return this.texture.type;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .type is now .texture.type.');\n      this.texture.type = value;\n    }\n  },\n  generateMipmaps: {\n    get: function () {\n      console.warn('THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps.');\n      return this.texture.generateMipmaps;\n    },\n    set: function (value) {\n      console.warn('THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps.');\n      this.texture.generateMipmaps = value;\n    }\n  }\n});\n\n//\n\nObject.defineProperties(Audio.prototype, {\n  load: {\n    value: function (file) {\n      console.warn('THREE.Audio: .load has been deprecated. Use THREE.AudioLoader instead.');\n      const scope = this;\n      const audioLoader = new AudioLoader();\n      audioLoader.load(file, function (buffer) {\n        scope.setBuffer(buffer);\n      });\n      return this;\n    }\n  },\n  startTime: {\n    set: function () {\n      console.warn('THREE.Audio: .startTime is now .play( delay ).');\n    }\n  }\n});\n\n//\n\nCubeCamera.prototype.updateCubeMap = function (renderer, scene) {\n  console.warn('THREE.CubeCamera: .updateCubeMap() is now .update().');\n  return this.update(renderer, scene);\n};\nCubeCamera.prototype.clear = function (renderer, color, depth, stencil) {\n  console.warn('THREE.CubeCamera: .clear() is now .renderTarget.clear().');\n  return this.renderTarget.clear(renderer, color, depth, stencil);\n};\nImageUtils.crossOrigin = undefined;\nImageUtils.loadTexture = function (url, mapping, onLoad, onError) {\n  console.warn('THREE.ImageUtils.loadTexture has been deprecated. Use THREE.TextureLoader() instead.');\n  const loader = new TextureLoader();\n  loader.setCrossOrigin(this.crossOrigin);\n  const texture = loader.load(url, onLoad, undefined, onError);\n  if (mapping) texture.mapping = mapping;\n  return texture;\n};\nImageUtils.loadTextureCube = function (urls, mapping, onLoad, onError) {\n  console.warn('THREE.ImageUtils.loadTextureCube has been deprecated. Use THREE.CubeTextureLoader() instead.');\n  const loader = new CubeTextureLoader();\n  loader.setCrossOrigin(this.crossOrigin);\n  const texture = loader.load(urls, onLoad, undefined, onError);\n  if (mapping) texture.mapping = mapping;\n  return texture;\n};\nImageUtils.loadCompressedTexture = function () {\n  console.error('THREE.ImageUtils.loadCompressedTexture has been removed. Use THREE.DDSLoader instead.');\n};\nImageUtils.loadCompressedTextureCube = function () {\n  console.error('THREE.ImageUtils.loadCompressedTextureCube has been removed. Use THREE.DDSLoader instead.');\n};\nif (typeof __THREE_DEVTOOLS__ !== 'undefined') {\n  /* eslint-disable no-undef */\n  __THREE_DEVTOOLS__.dispatchEvent(new CustomEvent('register', {\n    detail: {\n      revision: REVISION\n    }\n  }));\n  /* eslint-enable no-undef */\n}\n\nif (typeof window !== 'undefined') {\n  if (window.__THREE__) {\n    console.warn('WARNING: Multiple instances of Three.js being imported.');\n  } else {\n    window.__THREE__ = REVISION;\n  }\n}\n\n/**\n * @author dmarcos / https://github.com/dmarcos\n * @author mrdoob / http://mrdoob.com\n *\n * originally from https://github.com/mrdoob/three.js/blob/r93/examples/js/controls/VRControls.js\n */\nconst VRControls = function (object, onError) {\n  var scope = this;\n  var vrDisplay, vrDisplays;\n  var standingMatrix = new Matrix4();\n  var frameData = null;\n  if ('VRFrameData' in window) {\n    frameData = new VRFrameData();\n  }\n  function gotVRDisplays(displays) {\n    vrDisplays = displays;\n    if (displays.length > 0) {\n      vrDisplay = displays[0];\n    } else {\n      if (onError) onError('VR input not available.');\n    }\n  }\n  if (navigator.getVRDisplays) {\n    navigator.getVRDisplays().then(gotVRDisplays).catch(function () {\n      console.warn('THREE.VRControls: Unable to get VR Displays');\n    });\n  }\n\n  // the Rift SDK returns the position in meters\n  // this scale factor allows the user to define how meters\n  // are converted to scene units.\n\n  this.scale = 1;\n\n  // If true will use \"standing space\" coordinate system where y=0 is the\n  // floor and x=0, z=0 is the center of the room.\n  this.standing = false;\n\n  // Distance from the users eyes to the floor in meters. Used when\n  // standing=true but the VRDisplay doesn't provide stageParameters.\n  this.userHeight = 1.6;\n  this.getVRDisplay = function () {\n    return vrDisplay;\n  };\n  this.setVRDisplay = function (value) {\n    vrDisplay = value;\n  };\n  this.getVRDisplays = function () {\n    console.warn('THREE.VRControls: getVRDisplays() is being deprecated.');\n    return vrDisplays;\n  };\n  this.getStandingMatrix = function () {\n    return standingMatrix;\n  };\n  this.update = function () {\n    if (vrDisplay) {\n      var pose;\n      if (vrDisplay.getFrameData) {\n        vrDisplay.getFrameData(frameData);\n        pose = frameData.pose;\n      } else if (vrDisplay.getPose) {\n        pose = vrDisplay.getPose();\n      }\n      if (pose.orientation !== null) {\n        object.quaternion.fromArray(pose.orientation);\n      }\n      if (pose.position !== null) {\n        object.position.fromArray(pose.position);\n      } else {\n        object.position.set(0, 0, 0);\n      }\n      if (this.standing) {\n        if (vrDisplay.stageParameters) {\n          object.updateMatrix();\n          standingMatrix.fromArray(vrDisplay.stageParameters.sittingToStandingTransform);\n          object.applyMatrix(standingMatrix);\n        } else {\n          object.position.setY(object.position.y + this.userHeight);\n        }\n      }\n      object.position.multiplyScalar(scope.scale);\n    }\n  };\n  this.dispose = function () {\n    vrDisplay = null;\n  };\n};\n\n/**\n * @author dmarcos / https://github.com/dmarcos\n * @author mrdoob / http://mrdoob.com\n *\n * WebVR Spec: http://mozvr.github.io/webvr-spec/webvr.html\n *\n * Firefox: http://mozvr.com/downloads/\n * Chromium: https://webvr.info/get-chrome\n *\n * originally from https://github.com/mrdoob/three.js/blob/r93/examples/js/effects/VREffect.js\n */\nconst VREffect = function (renderer, onError) {\n  var vrDisplay, vrDisplays;\n  var eyeTranslationL = new Vector3();\n  var eyeTranslationR = new Vector3();\n  var renderRectL, renderRectR;\n  var headMatrix = new Matrix4();\n  var eyeMatrixL = new Matrix4();\n  var eyeMatrixR = new Matrix4();\n  var frameData = null;\n  if ('VRFrameData' in window) {\n    frameData = new window.VRFrameData();\n  }\n  function gotVRDisplays(displays) {\n    vrDisplays = displays;\n    if (displays.length > 0) {\n      vrDisplay = displays[0];\n    } else {\n      if (onError) onError('HMD not available');\n    }\n  }\n  if (navigator.getVRDisplays) {\n    navigator.getVRDisplays().then(gotVRDisplays).catch(function () {\n      console.warn('THREE.VREffect: Unable to get VR Displays');\n    });\n  }\n\n  //\n\n  this.isPresenting = false;\n  var scope = this;\n  var rendererSize = renderer.getSize();\n  var rendererUpdateStyle = false;\n  var rendererPixelRatio = renderer.getPixelRatio();\n  this.getVRDisplay = function () {\n    return vrDisplay;\n  };\n  this.setVRDisplay = function (value) {\n    vrDisplay = value;\n  };\n  this.getVRDisplays = function () {\n    console.warn('THREE.VREffect: getVRDisplays() is being deprecated.');\n    return vrDisplays;\n  };\n  this.setSize = function (width, height, updateStyle) {\n    rendererSize = {\n      width: width,\n      height: height\n    };\n    rendererUpdateStyle = updateStyle;\n    if (scope.isPresenting) {\n      var eyeParamsL = vrDisplay.getEyeParameters('left');\n      renderer.setPixelRatio(1);\n      renderer.setSize(eyeParamsL.renderWidth * 2, eyeParamsL.renderHeight, false);\n    } else {\n      renderer.setPixelRatio(rendererPixelRatio);\n      renderer.setSize(width, height, updateStyle);\n    }\n  };\n\n  // VR presentation\n\n  var canvas = renderer.domElement;\n  var defaultLeftBounds = [0.0, 0.0, 0.5, 1.0];\n  var defaultRightBounds = [0.5, 0.0, 0.5, 1.0];\n  function onVRDisplayPresentChange() {\n    var wasPresenting = scope.isPresenting;\n    scope.isPresenting = vrDisplay !== undefined && vrDisplay.isPresenting;\n    if (scope.isPresenting) {\n      var eyeParamsL = vrDisplay.getEyeParameters('left');\n      var eyeWidth = eyeParamsL.renderWidth;\n      var eyeHeight = eyeParamsL.renderHeight;\n      if (!wasPresenting) {\n        rendererPixelRatio = renderer.getPixelRatio();\n        rendererSize = renderer.getSize();\n        renderer.setPixelRatio(1);\n        renderer.setSize(eyeWidth * 2, eyeHeight, false);\n      }\n    } else if (wasPresenting) {\n      renderer.setPixelRatio(rendererPixelRatio);\n      renderer.setSize(rendererSize.width, rendererSize.height, rendererUpdateStyle);\n    }\n  }\n  window.addEventListener('vrdisplaypresentchange', onVRDisplayPresentChange, false);\n  this.setFullScreen = function (boolean) {\n    return new Promise(function (resolve, reject) {\n      if (vrDisplay === undefined) {\n        reject(new Error('No VR hardware found.'));\n        return;\n      }\n      if (scope.isPresenting === boolean) {\n        resolve();\n        return;\n      }\n      if (boolean) {\n        resolve(vrDisplay.requestPresent([{\n          source: canvas\n        }]));\n      } else {\n        resolve(vrDisplay.exitPresent());\n      }\n    });\n  };\n  this.requestPresent = function () {\n    return this.setFullScreen(true);\n  };\n  this.exitPresent = function () {\n    return this.setFullScreen(false);\n  };\n  this.requestAnimationFrame = function (f) {\n    if (vrDisplay !== undefined) {\n      return vrDisplay.requestAnimationFrame(f);\n    } else {\n      return window.requestAnimationFrame(f);\n    }\n  };\n  this.cancelAnimationFrame = function (h) {\n    if (vrDisplay !== undefined) {\n      vrDisplay.cancelAnimationFrame(h);\n    } else {\n      window.cancelAnimationFrame(h);\n    }\n  };\n  this.submitFrame = function () {\n    if (vrDisplay !== undefined && scope.isPresenting) {\n      vrDisplay.submitFrame();\n    }\n  };\n  this.autoSubmitFrame = true;\n\n  // render\n\n  var cameraL = new PerspectiveCamera();\n  cameraL.layers.enable(1);\n  var cameraR = new PerspectiveCamera();\n  cameraR.layers.enable(2);\n  this.render = function (scene, camera, renderTarget, forceClear) {\n    if (vrDisplay && scope.isPresenting) {\n      var autoUpdate = scene.autoUpdate;\n      if (autoUpdate) {\n        scene.updateMatrixWorld();\n        scene.autoUpdate = false;\n      }\n      if (Array.isArray(scene)) {\n        console.warn('THREE.VREffect.render() no longer supports arrays. Use object.layers instead.');\n        scene = scene[0];\n      }\n\n      // When rendering we don't care what the recommended size is, only what the actual size\n      // of the backbuffer is.\n      var size = renderer.getSize();\n      var layers = vrDisplay.getLayers();\n      var leftBounds;\n      var rightBounds;\n      if (layers.length) {\n        var layer = layers[0];\n        leftBounds = layer.leftBounds !== null && layer.leftBounds.length === 4 ? layer.leftBounds : defaultLeftBounds;\n        rightBounds = layer.rightBounds !== null && layer.rightBounds.length === 4 ? layer.rightBounds : defaultRightBounds;\n      } else {\n        leftBounds = defaultLeftBounds;\n        rightBounds = defaultRightBounds;\n      }\n      renderRectL = {\n        x: Math.round(size.width * leftBounds[0]),\n        y: Math.round(size.height * leftBounds[1]),\n        width: Math.round(size.width * leftBounds[2]),\n        height: Math.round(size.height * leftBounds[3])\n      };\n      renderRectR = {\n        x: Math.round(size.width * rightBounds[0]),\n        y: Math.round(size.height * rightBounds[1]),\n        width: Math.round(size.width * rightBounds[2]),\n        height: Math.round(size.height * rightBounds[3])\n      };\n      if (renderTarget) {\n        renderer.setRenderTarget(renderTarget);\n        renderTarget.scissorTest = true;\n      } else {\n        renderer.setRenderTarget(null);\n        renderer.setScissorTest(true);\n      }\n      if (renderer.autoClear || forceClear) renderer.clear();\n      if (camera.parent === null) camera.updateMatrixWorld();\n      camera.matrixWorld.decompose(cameraL.position, cameraL.quaternion, cameraL.scale);\n      cameraR.position.copy(cameraL.position);\n      cameraR.quaternion.copy(cameraL.quaternion);\n      cameraR.scale.copy(cameraL.scale);\n      if (vrDisplay.getFrameData) {\n        vrDisplay.depthNear = camera.near;\n        vrDisplay.depthFar = camera.far;\n        vrDisplay.getFrameData(frameData);\n        cameraL.projectionMatrix.elements = frameData.leftProjectionMatrix;\n        cameraR.projectionMatrix.elements = frameData.rightProjectionMatrix;\n        getEyeMatrices(frameData);\n        cameraL.updateMatrix();\n        cameraL.matrix.multiply(eyeMatrixL);\n        cameraL.matrix.decompose(cameraL.position, cameraL.quaternion, cameraL.scale);\n        cameraR.updateMatrix();\n        cameraR.matrix.multiply(eyeMatrixR);\n        cameraR.matrix.decompose(cameraR.position, cameraR.quaternion, cameraR.scale);\n      } else {\n        var eyeParamsL = vrDisplay.getEyeParameters('left');\n        var eyeParamsR = vrDisplay.getEyeParameters('right');\n        cameraL.projectionMatrix = fovToProjection(eyeParamsL.fieldOfView, true, camera.near, camera.far);\n        cameraR.projectionMatrix = fovToProjection(eyeParamsR.fieldOfView, true, camera.near, camera.far);\n        eyeTranslationL.fromArray(eyeParamsL.offset);\n        eyeTranslationR.fromArray(eyeParamsR.offset);\n        cameraL.translateOnAxis(eyeTranslationL, cameraL.scale.x);\n        cameraR.translateOnAxis(eyeTranslationR, cameraR.scale.x);\n      }\n\n      // render left eye\n      if (renderTarget) {\n        renderTarget.viewport.set(renderRectL.x, renderRectL.y, renderRectL.width, renderRectL.height);\n        renderTarget.scissor.set(renderRectL.x, renderRectL.y, renderRectL.width, renderRectL.height);\n      } else {\n        renderer.setViewport(renderRectL.x, renderRectL.y, renderRectL.width, renderRectL.height);\n        renderer.setScissor(renderRectL.x, renderRectL.y, renderRectL.width, renderRectL.height);\n      }\n      renderer.render(scene, cameraL, renderTarget, forceClear);\n\n      // render right eye\n      if (renderTarget) {\n        renderTarget.viewport.set(renderRectR.x, renderRectR.y, renderRectR.width, renderRectR.height);\n        renderTarget.scissor.set(renderRectR.x, renderRectR.y, renderRectR.width, renderRectR.height);\n      } else {\n        renderer.setViewport(renderRectR.x, renderRectR.y, renderRectR.width, renderRectR.height);\n        renderer.setScissor(renderRectR.x, renderRectR.y, renderRectR.width, renderRectR.height);\n      }\n      renderer.render(scene, cameraR, renderTarget, forceClear);\n      if (renderTarget) {\n        renderTarget.viewport.set(0, 0, size.width, size.height);\n        renderTarget.scissor.set(0, 0, size.width, size.height);\n        renderTarget.scissorTest = false;\n        renderer.setRenderTarget(null);\n      } else {\n        renderer.setViewport(0, 0, size.width, size.height);\n        renderer.setScissorTest(false);\n      }\n      if (autoUpdate) {\n        scene.autoUpdate = true;\n      }\n      if (scope.autoSubmitFrame) {\n        scope.submitFrame();\n      }\n      return;\n    }\n\n    // Regular render mode if not HMD\n\n    renderer.render(scene, camera, renderTarget, forceClear);\n  };\n  this.dispose = function () {\n    window.removeEventListener('vrdisplaypresentchange', onVRDisplayPresentChange, false);\n  };\n\n  //\n\n  var poseOrientation = new Quaternion();\n  var posePosition = new Vector3();\n\n  // Compute model matrices of the eyes with respect to the head.\n  function getEyeMatrices(frameData) {\n    // Compute the matrix for the position of the head based on the pose\n    if (frameData.pose.orientation) {\n      poseOrientation.fromArray(frameData.pose.orientation);\n      headMatrix.makeRotationFromQuaternion(poseOrientation);\n    } else {\n      headMatrix.identity();\n    }\n    if (frameData.pose.position) {\n      posePosition.fromArray(frameData.pose.position);\n      headMatrix.setPosition(posePosition);\n    }\n\n    // The view matrix transforms vertices from sitting space to eye space. As such, the view matrix can be thought of as a product of two matrices:\n    // headToEyeMatrix * sittingToHeadMatrix\n\n    // The headMatrix that we've calculated above is the model matrix of the head in sitting space, which is the inverse of sittingToHeadMatrix.\n    // So when we multiply the view matrix with headMatrix, we're left with headToEyeMatrix:\n    // viewMatrix * headMatrix = headToEyeMatrix * sittingToHeadMatrix * headMatrix = headToEyeMatrix\n\n    eyeMatrixL.fromArray(frameData.leftViewMatrix);\n    eyeMatrixL.multiply(headMatrix);\n    eyeMatrixR.fromArray(frameData.rightViewMatrix);\n    eyeMatrixR.multiply(headMatrix);\n\n    // The eye's model matrix in head space is the inverse of headToEyeMatrix we calculated above.\n\n    eyeMatrixL.getInverse(eyeMatrixL);\n    eyeMatrixR.getInverse(eyeMatrixR);\n  }\n  function fovToNDCScaleOffset(fov) {\n    var pxscale = 2.0 / (fov.leftTan + fov.rightTan);\n    var pxoffset = (fov.leftTan - fov.rightTan) * pxscale * 0.5;\n    var pyscale = 2.0 / (fov.upTan + fov.downTan);\n    var pyoffset = (fov.upTan - fov.downTan) * pyscale * 0.5;\n    return {\n      scale: [pxscale, pyscale],\n      offset: [pxoffset, pyoffset]\n    };\n  }\n  function fovPortToProjection(fov, rightHanded, zNear, zFar) {\n    rightHanded = rightHanded === undefined ? true : rightHanded;\n    zNear = zNear === undefined ? 0.01 : zNear;\n    zFar = zFar === undefined ? 10000.0 : zFar;\n    var handednessScale = rightHanded ? -1.0 : 1.0;\n\n    // start with an identity matrix\n    var mobj = new Matrix4();\n    var m = mobj.elements;\n\n    // and with scale/offset info for normalized device coords\n    var scaleAndOffset = fovToNDCScaleOffset(fov);\n\n    // X result, map clip edges to [-w,+w]\n    m[0 * 4 + 0] = scaleAndOffset.scale[0];\n    m[0 * 4 + 1] = 0.0;\n    m[0 * 4 + 2] = scaleAndOffset.offset[0] * handednessScale;\n    m[0 * 4 + 3] = 0.0;\n\n    // Y result, map clip edges to [-w,+w]\n    // Y offset is negated because this proj matrix transforms from world coords with Y=up,\n    // but the NDC scaling has Y=down (thanks D3D?)\n    m[1 * 4 + 0] = 0.0;\n    m[1 * 4 + 1] = scaleAndOffset.scale[1];\n    m[1 * 4 + 2] = -scaleAndOffset.offset[1] * handednessScale;\n    m[1 * 4 + 3] = 0.0;\n\n    // Z result (up to the app)\n    m[2 * 4 + 0] = 0.0;\n    m[2 * 4 + 1] = 0.0;\n    m[2 * 4 + 2] = zFar / (zNear - zFar) * -handednessScale;\n    m[2 * 4 + 3] = zFar * zNear / (zNear - zFar);\n\n    // W result (= Z in)\n    m[3 * 4 + 0] = 0.0;\n    m[3 * 4 + 1] = 0.0;\n    m[3 * 4 + 2] = handednessScale;\n    m[3 * 4 + 3] = 0.0;\n    mobj.transpose();\n    return mobj;\n  }\n  function fovToProjection(fov, rightHanded, zNear, zFar) {\n    var DEG2RAD = Math.PI / 180.0;\n    var fovPort = {\n      upTan: Math.tan(fov.upDegrees * DEG2RAD),\n      downTan: Math.tan(fov.downDegrees * DEG2RAD),\n      leftTan: Math.tan(fov.leftDegrees * DEG2RAD),\n      rightTan: Math.tan(fov.rightDegrees * DEG2RAD)\n    };\n    return fovPortToProjection(fovPort, rightHanded, zNear, zFar);\n  }\n};\n\n/**\n * @author qiao / https://github.com/qiao\n * @author mrdoob / http://mrdoob.com\n * @author alteredq / http://alteredqualia.com/\n * @author WestLangley / http://github.com/WestLangley\n * @author erich666 / http://erichaines.com\n *\n * originally from https://github.com/mrdoob/three.js/blob/r93/examples/js/controls/OrbitControls.js\n */\n\n// This set of controls performs orbiting, dollying (zooming), and panning.\n// Unlike TrackballControls, it maintains the \"up\" direction object.up (+Y by default).\n//\n//    Orbit - left mouse / touch: one-finger move\n//    Zoom - middle mouse, or mousewheel / touch: two-finger spread or squish\n//    Pan - right mouse, or arrow keys / touch: two-finger move\n\nconst OrbitControls = function (object, domElement) {\n  this.object = object;\n  this.domElement = domElement !== undefined ? domElement : document;\n\n  // Set to false to disable this control\n  this.enabled = true;\n\n  // \"target\" sets the location of focus, where the object orbits around\n  this.target = new Vector3();\n\n  // How far you can dolly in and out ( PerspectiveCamera only )\n  this.minDistance = 0;\n  this.maxDistance = Infinity;\n\n  // How far you can zoom in and out ( OrthographicCamera only )\n  this.minZoom = 0;\n  this.maxZoom = Infinity;\n\n  // How far you can orbit vertically, upper and lower limits.\n  // Range is 0 to Math.PI radians.\n  this.minPolarAngle = 0; // radians\n  this.maxPolarAngle = Math.PI; // radians\n\n  // How far you can orbit horizontally, upper and lower limits.\n  // If set, must be a sub-interval of the interval [ - Math.PI, Math.PI ].\n  this.minAzimuthAngle = -Infinity; // radians\n  this.maxAzimuthAngle = Infinity; // radians\n\n  // Set to true to enable damping (inertia)\n  // If damping is enabled, you must call controls.update() in your animation loop\n  this.enableDamping = false;\n  this.dampingFactor = 0.25;\n\n  // This option actually enables dollying in and out; left as \"zoom\" for backwards compatibility.\n  // Set to false to disable zooming\n  this.enableZoom = true;\n  this.zoomSpeed = 1.0;\n\n  // Set to false to disable rotating\n  this.enableRotate = true;\n  this.rotateSpeed = 1.0;\n\n  // Set to false to disable panning\n  this.enablePan = true;\n  this.panSpeed = 1.0;\n  this.screenSpacePanning = false; // if true, pan in screen-space\n  this.keyPanSpeed = 7.0; // pixels moved per arrow key push\n\n  // Set to true to automatically rotate around the target\n  // If auto-rotate is enabled, you must call controls.update() in your animation loop\n  this.autoRotate = false;\n  this.autoRotateSpeed = 2.0; // 30 seconds per round when fps is 60\n\n  // Set to false to disable use of the keys\n  this.enableKeys = true;\n\n  // The four arrow keys\n  this.keys = {\n    LEFT: 37,\n    UP: 38,\n    RIGHT: 39,\n    BOTTOM: 40\n  };\n\n  // Mouse buttons\n  this.mouseButtons = {\n    ORBIT: MOUSE.LEFT,\n    ZOOM: MOUSE.MIDDLE,\n    PAN: MOUSE.RIGHT\n  };\n\n  // for reset\n  this.target0 = this.target.clone();\n  this.position0 = this.object.position.clone();\n  this.zoom0 = this.object.zoom;\n\n  //\n  // public methods\n  //\n\n  this.getPolarAngle = function () {\n    return spherical.phi;\n  };\n  this.getAzimuthalAngle = function () {\n    return spherical.theta;\n  };\n  this.saveState = function () {\n    scope.target0.copy(scope.target);\n    scope.position0.copy(scope.object.position);\n    scope.zoom0 = scope.object.zoom;\n  };\n  this.reset = function () {\n    scope.target.copy(scope.target0);\n    scope.object.position.copy(scope.position0);\n    scope.object.zoom = scope.zoom0;\n    scope.object.updateProjectionMatrix();\n    scope.dispatchEvent(changeEvent);\n    scope.update();\n    state = STATE.NONE;\n  };\n\n  // this method is exposed, but perhaps it would be better if we can make it private...\n  this.update = function () {\n    var offset = new Vector3();\n\n    // so camera.up is the orbit axis\n    var quat = new Quaternion().setFromUnitVectors(object.up, new Vector3(0, 1, 0));\n    var quatInverse = quat.clone().inverse();\n    var lastPosition = new Vector3();\n    var lastQuaternion = new Quaternion();\n    return function update() {\n      var position = scope.object.position;\n      offset.copy(position).sub(scope.target);\n\n      // rotate offset to \"y-axis-is-up\" space\n      offset.applyQuaternion(quat);\n\n      // angle from z-axis around y-axis\n      spherical.setFromVector3(offset);\n      if (scope.autoRotate && state === STATE.NONE) {\n        scope.rotateLeft(getAutoRotationAngle());\n      }\n      spherical.theta += sphericalDelta.theta;\n      spherical.phi += sphericalDelta.phi;\n\n      // restrict theta to be between desired limits\n      spherical.theta = Math.max(scope.minAzimuthAngle, Math.min(scope.maxAzimuthAngle, spherical.theta));\n\n      // restrict phi to be between desired limits\n      spherical.phi = Math.max(scope.minPolarAngle, Math.min(scope.maxPolarAngle, spherical.phi));\n      spherical.makeSafe();\n      spherical.radius *= scale;\n\n      // restrict radius to be between desired limits\n      spherical.radius = Math.max(scope.minDistance, Math.min(scope.maxDistance, spherical.radius));\n\n      // move target to panned location\n      scope.target.add(panOffset);\n      offset.setFromSpherical(spherical);\n\n      // rotate offset back to \"camera-up-vector-is-up\" space\n      offset.applyQuaternion(quatInverse);\n      position.copy(scope.target).add(offset);\n      scope.object.lookAt(scope.target);\n      if (scope.enableDamping === true) {\n        sphericalDelta.theta *= 1 - scope.dampingFactor;\n        sphericalDelta.phi *= 1 - scope.dampingFactor;\n        panOffset.multiplyScalar(1 - scope.dampingFactor);\n      } else {\n        sphericalDelta.set(0, 0, 0);\n        panOffset.set(0, 0, 0);\n      }\n      scale = 1;\n\n      // update condition is:\n      // min(camera displacement, camera rotation in radians)^2 > EPS\n      // using small-angle approximation cos(x/2) = 1 - x^2 / 8\n\n      if (zoomChanged || lastPosition.distanceToSquared(scope.object.position) > EPS || 8 * (1 - lastQuaternion.dot(scope.object.quaternion)) > EPS) {\n        scope.dispatchEvent(changeEvent);\n        lastPosition.copy(scope.object.position);\n        lastQuaternion.copy(scope.object.quaternion);\n        zoomChanged = false;\n        return true;\n      }\n      return false;\n    };\n  }();\n  this.dispose = function () {\n    scope.domElement.removeEventListener('contextmenu', onContextMenu, false);\n    scope.domElement.removeEventListener('mousedown', onMouseDown, false);\n    scope.domElement.removeEventListener('wheel', onMouseWheel, false);\n    scope.domElement.removeEventListener('touchstart', onTouchStart, false);\n    scope.domElement.removeEventListener('touchend', onTouchEnd, false);\n    scope.domElement.removeEventListener('touchmove', onTouchMove, false);\n    document.removeEventListener('mousemove', onMouseMove, false);\n    document.removeEventListener('mouseup', onMouseUp, false);\n    window.removeEventListener('keydown', onKeyDown, false);\n\n    //scope.dispatchEvent( { type: 'dispose' } ); // should this be added here?\n  };\n\n  //\n  // internals\n  //\n\n  var scope = this;\n  var changeEvent = {\n    type: 'change'\n  };\n  var startEvent = {\n    type: 'start'\n  };\n  var endEvent = {\n    type: 'end'\n  };\n  var STATE = {\n    NONE: -1,\n    ROTATE: 0,\n    DOLLY: 1,\n    PAN: 2,\n    TOUCH_ROTATE: 3,\n    TOUCH_DOLLY_PAN: 4\n  };\n  var state = STATE.NONE;\n  var EPS = 0.000001;\n\n  // current position in spherical coordinates\n  var spherical = new Spherical();\n  var sphericalDelta = new Spherical();\n  var scale = 1;\n  var panOffset = new Vector3();\n  var zoomChanged = false;\n  var rotateStart = new Vector2();\n  var rotateEnd = new Vector2();\n  var rotateDelta = new Vector2();\n  var panStart = new Vector2();\n  var panEnd = new Vector2();\n  var panDelta = new Vector2();\n  var dollyStart = new Vector2();\n  var dollyEnd = new Vector2();\n  var dollyDelta = new Vector2();\n  function getAutoRotationAngle() {\n    return 2 * Math.PI / 60 / 60 * scope.autoRotateSpeed;\n  }\n  function getZoomScale() {\n    return Math.pow(0.95, scope.zoomSpeed);\n  }\n  scope.rotateLeft = function rotateLeft(angle) {\n    sphericalDelta.theta -= angle;\n  };\n  scope.rotateUp = function rotateUp(angle) {\n    sphericalDelta.phi -= angle;\n  };\n  var panLeft = function () {\n    var v = new Vector3();\n    return function panLeft(distance, objectMatrix) {\n      v.setFromMatrixColumn(objectMatrix, 0); // get X column of objectMatrix\n      v.multiplyScalar(-distance);\n      panOffset.add(v);\n    };\n  }();\n  var panUp = function () {\n    var v = new Vector3();\n    return function panUp(distance, objectMatrix) {\n      if (scope.screenSpacePanning === true) {\n        v.setFromMatrixColumn(objectMatrix, 1);\n      } else {\n        v.setFromMatrixColumn(objectMatrix, 0);\n        v.crossVectors(scope.object.up, v);\n      }\n      v.multiplyScalar(distance);\n      panOffset.add(v);\n    };\n  }();\n\n  // deltaX and deltaY are in pixels; right and down are positive\n  var pan = function () {\n    var offset = new Vector3();\n    return function pan(deltaX, deltaY) {\n      var element = scope.domElement === document ? scope.domElement.body : scope.domElement;\n      if (scope.object.isPerspectiveCamera) {\n        // perspective\n        var position = scope.object.position;\n        offset.copy(position).sub(scope.target);\n        var targetDistance = offset.length();\n\n        // half of the fov is center to top of screen\n        targetDistance *= Math.tan(scope.object.fov / 2 * Math.PI / 180.0);\n\n        // we use only clientHeight here so aspect ratio does not distort speed\n        panLeft(2 * deltaX * targetDistance / element.clientHeight, scope.object.matrix);\n        panUp(2 * deltaY * targetDistance / element.clientHeight, scope.object.matrix);\n      } else if (scope.object.isOrthographicCamera) {\n        // orthographic\n        panLeft(deltaX * (scope.object.right - scope.object.left) / scope.object.zoom / element.clientWidth, scope.object.matrix);\n        panUp(deltaY * (scope.object.top - scope.object.bottom) / scope.object.zoom / element.clientHeight, scope.object.matrix);\n      } else {\n        // camera neither orthographic nor perspective\n        console.warn('WARNING: OrbitControls.js encountered an unknown camera type - pan disabled.');\n        scope.enablePan = false;\n      }\n    };\n  }();\n  function dollyIn(dollyScale) {\n    if (scope.object.isPerspectiveCamera) {\n      scale /= dollyScale;\n    } else if (scope.object.isOrthographicCamera) {\n      scope.object.zoom = Math.max(scope.minZoom, Math.min(scope.maxZoom, scope.object.zoom * dollyScale));\n      scope.object.updateProjectionMatrix();\n      zoomChanged = true;\n    } else {\n      console.warn('WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled.');\n      scope.enableZoom = false;\n    }\n  }\n  function dollyOut(dollyScale) {\n    if (scope.object.isPerspectiveCamera) {\n      scale *= dollyScale;\n    } else if (scope.object.isOrthographicCamera) {\n      scope.object.zoom = Math.max(scope.minZoom, Math.min(scope.maxZoom, scope.object.zoom / dollyScale));\n      scope.object.updateProjectionMatrix();\n      zoomChanged = true;\n    } else {\n      console.warn('WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled.');\n      scope.enableZoom = false;\n    }\n  }\n\n  //\n  // event callbacks - update the object state\n  //\n\n  function handleMouseDownRotate(event) {\n    //console.log( 'handleMouseDownRotate' );\n\n    rotateStart.set(event.clientX, event.clientY);\n  }\n  function handleMouseDownDolly(event) {\n    //console.log( 'handleMouseDownDolly' );\n\n    dollyStart.set(event.clientX, event.clientY);\n  }\n  function handleMouseDownPan(event) {\n    //console.log( 'handleMouseDownPan' );\n\n    panStart.set(event.clientX, event.clientY);\n  }\n  function handleMouseMoveRotate(event) {\n    //console.log( 'handleMouseMoveRotate' );\n\n    rotateEnd.set(event.clientX, event.clientY);\n    rotateDelta.subVectors(rotateEnd, rotateStart).multiplyScalar(scope.rotateSpeed);\n    var element = scope.domElement === document ? scope.domElement.body : scope.domElement;\n    scope.rotateLeft(2 * Math.PI * rotateDelta.x / element.clientHeight); // yes, height\n\n    scope.rotateUp(2 * Math.PI * rotateDelta.y / element.clientHeight);\n    rotateStart.copy(rotateEnd);\n    scope.update();\n  }\n  function handleMouseMoveDolly(event) {\n    //console.log( 'handleMouseMoveDolly' );\n\n    dollyEnd.set(event.clientX, event.clientY);\n    dollyDelta.subVectors(dollyEnd, dollyStart);\n    if (dollyDelta.y > 0) {\n      dollyIn(getZoomScale());\n    } else if (dollyDelta.y < 0) {\n      dollyOut(getZoomScale());\n    }\n    dollyStart.copy(dollyEnd);\n    scope.update();\n  }\n  function handleMouseMovePan(event) {\n    //console.log( 'handleMouseMovePan' );\n\n    panEnd.set(event.clientX, event.clientY);\n    panDelta.subVectors(panEnd, panStart).multiplyScalar(scope.panSpeed);\n    pan(panDelta.x, panDelta.y);\n    panStart.copy(panEnd);\n    scope.update();\n  }\n  function handleMouseWheel(event) {\n    // console.log( 'handleMouseWheel' );\n\n    if (event.deltaY < 0) {\n      dollyOut(getZoomScale());\n    } else if (event.deltaY > 0) {\n      dollyIn(getZoomScale());\n    }\n    scope.update();\n  }\n  function handleKeyDown(event) {\n    //console.log( 'handleKeyDown' );\n\n    switch (event.keyCode) {\n      case scope.keys.UP:\n        pan(0, scope.keyPanSpeed);\n        scope.update();\n        break;\n      case scope.keys.BOTTOM:\n        pan(0, -scope.keyPanSpeed);\n        scope.update();\n        break;\n      case scope.keys.LEFT:\n        pan(scope.keyPanSpeed, 0);\n        scope.update();\n        break;\n      case scope.keys.RIGHT:\n        pan(-scope.keyPanSpeed, 0);\n        scope.update();\n        break;\n    }\n  }\n  function handleTouchStartRotate(event) {\n    //console.log( 'handleTouchStartRotate' );\n\n    rotateStart.set(event.touches[0].pageX, event.touches[0].pageY);\n  }\n  function handleTouchStartDollyPan(event) {\n    //console.log( 'handleTouchStartDollyPan' );\n\n    if (scope.enableZoom) {\n      var dx = event.touches[0].pageX - event.touches[1].pageX;\n      var dy = event.touches[0].pageY - event.touches[1].pageY;\n      var distance = Math.sqrt(dx * dx + dy * dy);\n      dollyStart.set(0, distance);\n    }\n    if (scope.enablePan) {\n      var x = 0.5 * (event.touches[0].pageX + event.touches[1].pageX);\n      var y = 0.5 * (event.touches[0].pageY + event.touches[1].pageY);\n      panStart.set(x, y);\n    }\n  }\n  function handleTouchMoveRotate(event) {\n    //console.log( 'handleTouchMoveRotate' );\n\n    rotateEnd.set(event.touches[0].pageX, event.touches[0].pageY);\n    rotateDelta.subVectors(rotateEnd, rotateStart).multiplyScalar(scope.rotateSpeed);\n    var element = scope.domElement === document ? scope.domElement.body : scope.domElement;\n    scope.rotateLeft(2 * Math.PI * rotateDelta.x / element.clientHeight); // yes, height\n\n    scope.rotateUp(2 * Math.PI * rotateDelta.y / element.clientHeight);\n    rotateStart.copy(rotateEnd);\n    scope.update();\n  }\n  function handleTouchMoveDollyPan(event) {\n    //console.log( 'handleTouchMoveDollyPan' );\n\n    if (scope.enableZoom) {\n      var dx = event.touches[0].pageX - event.touches[1].pageX;\n      var dy = event.touches[0].pageY - event.touches[1].pageY;\n      var distance = Math.sqrt(dx * dx + dy * dy);\n      dollyEnd.set(0, distance);\n      dollyDelta.set(0, Math.pow(dollyEnd.y / dollyStart.y, scope.zoomSpeed));\n      dollyIn(dollyDelta.y);\n      dollyStart.copy(dollyEnd);\n    }\n    if (scope.enablePan) {\n      var x = 0.5 * (event.touches[0].pageX + event.touches[1].pageX);\n      var y = 0.5 * (event.touches[0].pageY + event.touches[1].pageY);\n      panEnd.set(x, y);\n      panDelta.subVectors(panEnd, panStart).multiplyScalar(scope.panSpeed);\n      pan(panDelta.x, panDelta.y);\n      panStart.copy(panEnd);\n    }\n    scope.update();\n  }\n\n  //\n  // event handlers - FSM: listen for events and reset state\n  //\n\n  function onMouseDown(event) {\n    if (scope.enabled === false) return;\n    event.preventDefault();\n    switch (event.button) {\n      case scope.mouseButtons.ORBIT:\n        if (scope.enableRotate === false) return;\n        handleMouseDownRotate(event);\n        state = STATE.ROTATE;\n        break;\n      case scope.mouseButtons.ZOOM:\n        if (scope.enableZoom === false) return;\n        handleMouseDownDolly(event);\n        state = STATE.DOLLY;\n        break;\n      case scope.mouseButtons.PAN:\n        if (scope.enablePan === false) return;\n        handleMouseDownPan(event);\n        state = STATE.PAN;\n        break;\n    }\n    if (state !== STATE.NONE) {\n      document.addEventListener('mousemove', onMouseMove, false);\n      document.addEventListener('mouseup', onMouseUp, false);\n      scope.dispatchEvent(startEvent);\n    }\n  }\n  function onMouseMove(event) {\n    if (scope.enabled === false) return;\n    event.preventDefault();\n    switch (state) {\n      case STATE.ROTATE:\n        if (scope.enableRotate === false) return;\n        handleMouseMoveRotate(event);\n        break;\n      case STATE.DOLLY:\n        if (scope.enableZoom === false) return;\n        handleMouseMoveDolly(event);\n        break;\n      case STATE.PAN:\n        if (scope.enablePan === false) return;\n        handleMouseMovePan(event);\n        break;\n    }\n  }\n  function onMouseUp(event) {\n    if (scope.enabled === false) return;\n    document.removeEventListener('mousemove', onMouseMove, false);\n    document.removeEventListener('mouseup', onMouseUp, false);\n    scope.dispatchEvent(endEvent);\n    state = STATE.NONE;\n  }\n  function onMouseWheel(event) {\n    if (scope.enabled === false || scope.enableZoom === false || state !== STATE.NONE && state !== STATE.ROTATE) return;\n    event.preventDefault();\n    event.stopPropagation();\n    scope.dispatchEvent(startEvent);\n    handleMouseWheel(event);\n    scope.dispatchEvent(endEvent);\n  }\n  function onKeyDown(event) {\n    if (scope.enabled === false || scope.enableKeys === false || scope.enablePan === false) return;\n    handleKeyDown(event);\n  }\n  function onTouchStart(event) {\n    if (scope.enabled === false) return;\n    event.preventDefault();\n    switch (event.touches.length) {\n      case 1:\n        // one-fingered touch: rotate\n\n        if (scope.enableRotate === false) return;\n        handleTouchStartRotate(event);\n        state = STATE.TOUCH_ROTATE;\n        break;\n      case 2:\n        // two-fingered touch: dolly-pan\n\n        if (scope.enableZoom === false && scope.enablePan === false) return;\n        handleTouchStartDollyPan(event);\n        state = STATE.TOUCH_DOLLY_PAN;\n        break;\n      default:\n        state = STATE.NONE;\n    }\n    if (state !== STATE.NONE) {\n      scope.dispatchEvent(startEvent);\n    }\n  }\n  function onTouchMove(event) {\n    if (scope.enabled === false) return;\n    event.preventDefault();\n    event.stopPropagation();\n    switch (event.touches.length) {\n      case 1:\n        // one-fingered touch: rotate\n\n        if (scope.enableRotate === false) return;\n        if (state !== STATE.TOUCH_ROTATE) return; // is this needed?\n\n        handleTouchMoveRotate(event);\n        break;\n      case 2:\n        // two-fingered touch: dolly-pan\n\n        if (scope.enableZoom === false && scope.enablePan === false) return;\n        if (state !== STATE.TOUCH_DOLLY_PAN) return; // is this needed?\n\n        handleTouchMoveDollyPan(event);\n        break;\n      default:\n        state = STATE.NONE;\n    }\n  }\n  function onTouchEnd(event) {\n    if (scope.enabled === false) return;\n    scope.dispatchEvent(endEvent);\n    state = STATE.NONE;\n  }\n  function onContextMenu(event) {\n    if (scope.enabled === false) return;\n    event.preventDefault();\n  }\n\n  //\n\n  // scope.domElement.addEventListener( 'contextmenu', onContextMenu, false );\n\n  scope.domElement.addEventListener('mousedown', onMouseDown, false);\n  scope.domElement.addEventListener('wheel', onMouseWheel, false);\n  scope.domElement.addEventListener('touchstart', onTouchStart, false);\n  scope.domElement.addEventListener('touchend', onTouchEnd, false);\n  scope.domElement.addEventListener('touchmove', onTouchMove, false);\n  window.addEventListener('keydown', onKeyDown, false);\n\n  // force an update at start\n\n  this.update();\n};\nOrbitControls.prototype = Object.create(EventDispatcher.prototype);\nOrbitControls.prototype.constructor = OrbitControls;\nObject.defineProperties(OrbitControls.prototype, {\n  center: {\n    get: function () {\n      console.warn('THREE.OrbitControls: .center has been renamed to .target');\n      return this.target;\n    }\n  },\n  // backward compatibility\n\n  noZoom: {\n    get: function () {\n      console.warn('THREE.OrbitControls: .noZoom has been deprecated. Use .enableZoom instead.');\n      return !this.enableZoom;\n    },\n    set: function (value) {\n      console.warn('THREE.OrbitControls: .noZoom has been deprecated. Use .enableZoom instead.');\n      this.enableZoom = !value;\n    }\n  },\n  noRotate: {\n    get: function () {\n      console.warn('THREE.OrbitControls: .noRotate has been deprecated. Use .enableRotate instead.');\n      return !this.enableRotate;\n    },\n    set: function (value) {\n      console.warn('THREE.OrbitControls: .noRotate has been deprecated. Use .enableRotate instead.');\n      this.enableRotate = !value;\n    }\n  },\n  noPan: {\n    get: function () {\n      console.warn('THREE.OrbitControls: .noPan has been deprecated. Use .enablePan instead.');\n      return !this.enablePan;\n    },\n    set: function (value) {\n      console.warn('THREE.OrbitControls: .noPan has been deprecated. Use .enablePan instead.');\n      this.enablePan = !value;\n    }\n  },\n  noKeys: {\n    get: function () {\n      console.warn('THREE.OrbitControls: .noKeys has been deprecated. Use .enableKeys instead.');\n      return !this.enableKeys;\n    },\n    set: function (value) {\n      console.warn('THREE.OrbitControls: .noKeys has been deprecated. Use .enableKeys instead.');\n      this.enableKeys = !value;\n    }\n  },\n  staticMoving: {\n    get: function () {\n      console.warn('THREE.OrbitControls: .staticMoving has been deprecated. Use .enableDamping instead.');\n      return !this.enableDamping;\n    },\n    set: function (value) {\n      console.warn('THREE.OrbitControls: .staticMoving has been deprecated. Use .enableDamping instead.');\n      this.enableDamping = !value;\n    }\n  },\n  dynamicDampingFactor: {\n    get: function () {\n      console.warn('THREE.OrbitControls: .dynamicDampingFactor has been renamed. Use .dampingFactor instead.');\n      return this.dampingFactor;\n    },\n    set: function (value) {\n      console.warn('THREE.OrbitControls: .dynamicDampingFactor has been renamed. Use .dampingFactor instead.');\n      this.dampingFactor = value;\n    }\n  }\n});\n\n/**\n * @author richt / http://richt.me\n * @author WestLangley / http://github.com/WestLangley\n *\n * W3C Device Orientation control (http://w3c.github.io/deviceorientation/spec-source-orientation.html)\n *\n * originally from https://github.com/mrdoob/three.js/blob/r93/examples/js/controls/DeviceOrientationControls.js\n */\nconst DeviceOrientationControls = function (object) {\n  var scope = this;\n  this.object = object;\n  this.object.rotation.reorder('YXZ');\n  this.enabled = true;\n  this.deviceOrientation = {};\n  this.screenOrientation = 0;\n  this.alphaOffset = 0; // radians\n\n  var onDeviceOrientationChangeEvent = function (event) {\n    scope.deviceOrientation = event;\n  };\n  var onScreenOrientationChangeEvent = function () {\n    scope.screenOrientation = window.orientation || 0;\n  };\n\n  // The angles alpha, beta and gamma form a set of intrinsic Tait-Bryan angles of type Z-X'-Y''\n\n  var setObjectQuaternion = function () {\n    var zee = new Vector3(0, 0, 1);\n    var euler = new Euler();\n    var q0 = new Quaternion();\n    var q1 = new Quaternion(-Math.sqrt(0.5), 0, 0, Math.sqrt(0.5)); // - PI/2 around the x-axis\n\n    return function (quaternion, alpha, beta, gamma, orient) {\n      euler.set(beta, alpha, -gamma, 'YXZ'); // 'ZXY' for the device, but 'YXZ' for us\n\n      quaternion.setFromEuler(euler); // orient the device\n\n      quaternion.multiply(q1); // camera looks out the back of the device, not the top\n\n      quaternion.multiply(q0.setFromAxisAngle(zee, -orient)); // adjust for screen orientation\n    };\n  }();\n\n  this.connect = function () {\n    onScreenOrientationChangeEvent(); // run once on load\n\n    window.addEventListener('orientationchange', onScreenOrientationChangeEvent, false);\n    window.addEventListener('deviceorientation', onDeviceOrientationChangeEvent, false);\n    scope.enabled = true;\n  };\n  this.disconnect = function () {\n    window.removeEventListener('orientationchange', onScreenOrientationChangeEvent, false);\n    window.removeEventListener('deviceorientation', onDeviceOrientationChangeEvent, false);\n    scope.enabled = false;\n  };\n  this.update = function () {\n    if (scope.enabled === false) return;\n    var device = scope.deviceOrientation;\n    if (device) {\n      var alpha = device.alpha ? MathUtils.degToRad(device.alpha) + scope.alphaOffset : 0; // Z\n\n      var beta = device.beta ? MathUtils.degToRad(device.beta) : 0; // X'\n\n      var gamma = device.gamma ? MathUtils.degToRad(device.gamma) : 0; // Y''\n\n      var orient = scope.screenOrientation ? MathUtils.degToRad(scope.screenOrientation) : 0; // O\n\n      setObjectQuaternion(scope.object.quaternion, alpha, beta, gamma, orient);\n    }\n  };\n  this.dispose = function () {\n    scope.disconnect();\n  };\n  this.connect();\n};\n\n/**\n * Convert a quaternion to an angle\n *\n * Taken from https://stackoverflow.com/a/35448946\n * Thanks P. Ellul\n */\nfunction Quat2Angle(x, y, z, w) {\n  const test = x * y + z * w;\n\n  // singularity at north pole\n  if (test > 0.499) {\n    const yaw = 2 * Math.atan2(x, w);\n    const pitch = Math.PI / 2;\n    const roll = 0;\n    return new Vector3(pitch, roll, yaw);\n  }\n\n  // singularity at south pole\n  if (test < -0.499) {\n    const yaw = -2 * Math.atan2(x, w);\n    const pitch = -Math.PI / 2;\n    const roll = 0;\n    return new Vector3(pitch, roll, yaw);\n  }\n  const sqx = x * x;\n  const sqy = y * y;\n  const sqz = z * z;\n  const yaw = Math.atan2(2 * y * w - 2 * x * z, 1 - 2 * sqy - 2 * sqz);\n  const pitch = Math.asin(2 * test);\n  const roll = Math.atan2(2 * x * w - 2 * y * z, 1 - 2 * sqx - 2 * sqz);\n  return new Vector3(pitch, roll, yaw);\n}\nclass OrbitOrientationControls {\n  constructor(options) {\n    this.object = options.camera;\n    this.domElement = options.canvas;\n    this.orbit = new OrbitControls(this.object, this.domElement);\n    this.speed = 0.5;\n    this.orbit.target.set(0, 0, -1);\n    this.orbit.enableZoom = false;\n    this.orbit.enablePan = false;\n    this.orbit.rotateSpeed = -this.speed;\n\n    // if orientation is supported\n    if (options.orientation) {\n      this.orientation = new DeviceOrientationControls(this.object);\n    }\n\n    // if projection is not full view\n    // limit the rotation angle in order to not display back half view\n    if (options.halfView) {\n      this.orbit.minAzimuthAngle = -Math.PI / 4;\n      this.orbit.maxAzimuthAngle = Math.PI / 4;\n    }\n  }\n  update() {\n    // orientation updates the camera using quaternions and\n    // orbit updates the camera using angles. They are incompatible\n    // and one update overrides the other. So before\n    // orbit overrides orientation we convert our quaternion changes to\n    // an angle change. Then save the angle into orbit so that\n    // it will take those into account when it updates the camera and overrides\n    // our changes\n    if (this.orientation) {\n      this.orientation.update();\n      const quat = this.orientation.object.quaternion;\n      const currentAngle = Quat2Angle(quat.x, quat.y, quat.z, quat.w);\n\n      // we also have to store the last angle since quaternions are b\n      if (typeof this.lastAngle_ === 'undefined') {\n        this.lastAngle_ = currentAngle;\n      }\n      this.orbit.rotateLeft((this.lastAngle_.z - currentAngle.z) * (1 + this.speed));\n      this.orbit.rotateUp((this.lastAngle_.y - currentAngle.y) * (1 + this.speed));\n      this.lastAngle_ = currentAngle;\n    }\n    this.orbit.update();\n  }\n  dispose() {\n    this.orbit.dispose();\n    if (this.orientation) {\n      this.orientation.dispose();\n    }\n  }\n}\n\n// check if the browser supports cors\nconst corsSupport = function () {\n  const video = document__default['default'].createElement('video');\n  video.crossOrigin = 'anonymous';\n  return video.hasAttribute('crossorigin');\n}();\nconst validProjections = ['360', '360_LR', '360_TB', '360_CUBE', 'EAC', 'EAC_LR', 'NONE', 'AUTO', 'Sphere', 'Cube', 'equirectangular', '180', '180_LR', '180_MONO'];\nconst getInternalProjectionName = function (projection) {\n  if (!projection) {\n    return;\n  }\n  projection = projection.toString().trim();\n  if (/sphere/i.test(projection)) {\n    return '360';\n  }\n  if (/cube/i.test(projection)) {\n    return '360_CUBE';\n  }\n  if (/equirectangular/i.test(projection)) {\n    return '360';\n  }\n  for (let i = 0; i < validProjections.length; i++) {\n    if (new RegExp('^' + validProjections[i] + '$', 'i').test(projection)) {\n      return validProjections[i];\n    }\n  }\n};\n\n/**\n * This class reacts to interactions with the canvas and\n * triggers appropriate functionality on the player. Right now\n * it does two things:\n *\n * 1. A `mousedown`/`touchstart` followed by `touchend`/`mouseup` without any\n *    `touchmove` or `mousemove` toggles play/pause on the player\n * 2. Only moving on/clicking the control bar or toggling play/pause should\n *    show the control bar. Moving around the scene in the canvas should not.\n */\nclass CanvasPlayerControls extends videojs__default['default'].EventTarget {\n  constructor(player, canvas, options) {\n    super();\n    this.player = player;\n    this.canvas = canvas;\n    this.options = options;\n    this.onMoveEnd = videojs__default['default'].bind(this, this.onMoveEnd);\n    this.onMoveStart = videojs__default['default'].bind(this, this.onMoveStart);\n    this.onMove = videojs__default['default'].bind(this, this.onMove);\n    this.onControlBarMove = videojs__default['default'].bind(this, this.onControlBarMove);\n    this.player.controlBar.on(['mousedown', 'mousemove', 'mouseup', 'touchstart', 'touchmove', 'touchend'], this.onControlBarMove);\n\n    // we have to override these here because\n    // video.js listens for user activity on the video element\n    // and makes the user active when the mouse moves.\n    // We don't want that for 3d videos\n    this.oldReportUserActivity = this.player.reportUserActivity;\n    this.player.reportUserActivity = () => {};\n\n    // canvas movements\n    this.canvas.addEventListener('mousedown', this.onMoveStart);\n    this.canvas.addEventListener('touchstart', this.onMoveStart);\n    this.canvas.addEventListener('mousemove', this.onMove);\n    this.canvas.addEventListener('touchmove', this.onMove);\n    this.canvas.addEventListener('mouseup', this.onMoveEnd);\n    this.canvas.addEventListener('touchend', this.onMoveEnd);\n    this.shouldTogglePlay = false;\n  }\n  togglePlay() {\n    if (this.player.paused()) {\n      this.player.play();\n    } else {\n      this.player.pause();\n    }\n  }\n  onMoveStart(e) {\n    // if the player does not have a controlbar or\n    // the move was a mouse click but not left click do not\n    // toggle play.\n    if (this.options.disableTogglePlay || !this.player.controls() || e.type === 'mousedown' && !videojs__default['default'].dom.isSingleLeftClick(e)) {\n      this.shouldTogglePlay = false;\n      return;\n    }\n    this.shouldTogglePlay = true;\n    this.touchMoveCount_ = 0;\n  }\n  onMoveEnd(e) {\n    // We want to have the same behavior in VR360 Player and standard player.\n    // in touchend we want to know if was a touch click, for a click we show the bar,\n    // otherwise continue with the mouse logic.\n    //\n    // Maximum movement allowed during a touch event to still be considered a tap\n    // Other popular libs use anywhere from 2 (hammer.js) to 15,\n    // so 10 seems like a nice, round number.\n    if (e.type === 'touchend' && this.touchMoveCount_ < 10) {\n      if (this.player.userActive() === false) {\n        this.player.userActive(true);\n        return;\n      }\n      this.player.userActive(false);\n      return;\n    }\n    if (!this.shouldTogglePlay) {\n      return;\n    }\n\n    // We want the same behavior in Desktop for VR360  and standard player\n    if (e.type === 'mouseup') {\n      this.togglePlay();\n    }\n  }\n  onMove(e) {\n    // Increase touchMoveCount_ since Android detects 1 - 6 touches when user click normally\n    this.touchMoveCount_++;\n    this.shouldTogglePlay = false;\n  }\n  onControlBarMove(e) {\n    this.player.userActive(true);\n  }\n  dispose() {\n    this.canvas.removeEventListener('mousedown', this.onMoveStart);\n    this.canvas.removeEventListener('touchstart', this.onMoveStart);\n    this.canvas.removeEventListener('mousemove', this.onMove);\n    this.canvas.removeEventListener('touchmove', this.onMove);\n    this.canvas.removeEventListener('mouseup', this.onMoveEnd);\n    this.canvas.removeEventListener('touchend', this.onMoveEnd);\n    this.player.controlBar.off(['mousedown', 'mousemove', 'mouseup', 'touchstart', 'touchmove', 'touchend'], this.onControlBarMove);\n    this.player.reportUserActivity = this.oldReportUserActivity;\n  }\n}\n\n/**\n * This class manages ambisonic decoding and binaural rendering via Omnitone library.\n */\nclass OmnitoneController extends videojs__default['default'].EventTarget {\n  /**\n   * Omnitone controller class.\n   *\n   * @class\n   * @param {AudioContext} audioContext - associated AudioContext.\n   * @param {Omnitone library} omnitone - Omnitone library element.\n   * @param {HTMLVideoElement} video - vidoe tag element.\n   * @param {Object} options - omnitone options.\n   */\n  constructor(audioContext, omnitone, video, options) {\n    super();\n    const settings = videojs__default['default'].mergeOptions({\n      // Safari uses the different AAC decoder than FFMPEG. The channel order is\n      // The default 4ch AAC channel layout for FFMPEG AAC channel ordering.\n      channelMap: videojs__default['default'].browser.IS_SAFARI ? [2, 0, 1, 3] : [0, 1, 2, 3],\n      ambisonicOrder: 1\n    }, options);\n    this.videoElementSource = audioContext.createMediaElementSource(video);\n    this.foaRenderer = omnitone.createFOARenderer(audioContext, settings);\n    this.foaRenderer.initialize().then(() => {\n      if (audioContext.state === 'suspended') {\n        this.trigger({\n          type: 'audiocontext-suspended'\n        });\n      }\n      this.videoElementSource.connect(this.foaRenderer.input);\n      this.foaRenderer.output.connect(audioContext.destination);\n      this.initialized = true;\n      this.trigger({\n        type: 'omnitone-ready'\n      });\n    }, error => {\n      videojs__default['default'].log.warn(`videojs-vr: Omnitone initializes failed with the following error: ${error})`);\n    });\n  }\n\n  /**\n   * Updates the rotation of the Omnitone decoder based on three.js camera matrix.\n   *\n   * @param {Camera} camera Three.js camera object\n   */\n  update(camera) {\n    if (!this.initialized) {\n      return;\n    }\n    this.foaRenderer.setRotationMatrixFromCamera(camera.matrix);\n  }\n\n  /**\n   * Destroys the controller and does any necessary cleanup.\n   */\n  dispose() {\n    this.initialized = false;\n    this.foaRenderer.setRenderingMode('bypass');\n    this.foaRenderer = null;\n  }\n}\n\n// Add Cardboard button\nconst Button = videojs__default['default'].getComponent('Button');\nclass CardboardButton extends Button {\n  constructor(player, options) {\n    super(player, options);\n    this.handleVrDisplayActivate_ = videojs__default['default'].bind(this, this.handleVrDisplayActivate_);\n    this.handleVrDisplayDeactivate_ = videojs__default['default'].bind(this, this.handleVrDisplayDeactivate_);\n    this.handleVrDisplayPresentChange_ = videojs__default['default'].bind(this, this.handleVrDisplayPresentChange_);\n    this.handleOrientationChange_ = videojs__default['default'].bind(this, this.handleOrientationChange_);\n    window__default['default'].addEventListener('orientationchange', this.handleOrientationChange_);\n    window__default['default'].addEventListener('vrdisplayactivate', this.handleVrDisplayActivate_);\n    window__default['default'].addEventListener('vrdisplaydeactivate', this.handleVrDisplayDeactivate_);\n\n    // vrdisplaypresentchange does not fire activate or deactivate\n    // and happens when hitting the back button during cardboard mode\n    // so we need to make sure we stay in the correct state by\n    // listening to it and checking if we are presenting it or not\n    window__default['default'].addEventListener('vrdisplaypresentchange', this.handleVrDisplayPresentChange_);\n\n    // we cannot show the cardboard button in fullscreen on\n    // android as it breaks the controls, and makes it impossible\n    // to exit cardboard mode\n    if (videojs__default['default'].browser.IS_ANDROID) {\n      this.on(player, 'fullscreenchange', () => {\n        if (player.isFullscreen()) {\n          this.hide();\n        } else {\n          this.show();\n        }\n      });\n    }\n  }\n  buildCSSClass() {\n    return `vjs-button-vr ${super.buildCSSClass()}`;\n  }\n  handleVrDisplayPresentChange_() {\n    if (!this.player_.vr().vrDisplay.isPresenting && this.active_) {\n      this.handleVrDisplayDeactivate_();\n    }\n    if (this.player_.vr().vrDisplay.isPresenting && !this.active_) {\n      this.handleVrDisplayActivate_();\n    }\n  }\n  handleOrientationChange_() {\n    if (this.active_ && videojs__default['default'].browser.IS_IOS) {\n      this.changeSize_();\n    }\n  }\n  changeSize_() {\n    this.player_.width(window__default['default'].innerWidth);\n    this.player_.height(window__default['default'].innerHeight);\n    window__default['default'].dispatchEvent(new window__default['default'].Event('resize'));\n  }\n  handleVrDisplayActivate_() {\n    // we mimic fullscreen on IOS\n    if (videojs__default['default'].browser.IS_IOS) {\n      this.oldWidth_ = this.player_.currentWidth();\n      this.oldHeight_ = this.player_.currentHeight();\n      this.player_.enterFullWindow();\n      this.changeSize_();\n    }\n    this.active_ = true;\n  }\n  handleVrDisplayDeactivate_() {\n    // un-mimic fullscreen on iOS\n    if (videojs__default['default'].browser.IS_IOS) {\n      if (this.oldWidth_) {\n        this.player_.width(this.oldWidth_);\n      }\n      if (this.oldHeight_) {\n        this.player_.height(this.oldHeight_);\n      }\n      this.player_.exitFullWindow();\n    }\n    this.active_ = false;\n  }\n  handleClick(event) {\n    // if cardboard mode display is not active, activate it\n    // otherwise deactivate it\n    if (!this.active_) {\n      // This starts playback mode when the cardboard button\n      // is clicked on Android. We need to do this as the controls\n      // disappear\n      if (!this.player_.hasStarted() && videojs__default['default'].browser.IS_ANDROID) {\n        this.player_.play();\n      }\n      window__default['default'].dispatchEvent(new window__default['default'].Event('vrdisplayactivate'));\n    } else {\n      window__default['default'].dispatchEvent(new window__default['default'].Event('vrdisplaydeactivate'));\n    }\n  }\n  dispose() {\n    super.dispose();\n    window__default['default'].removeEventListener('vrdisplayactivate', this.handleVrDisplayActivate_);\n    window__default['default'].removeEventListener('vrdisplaydeactivate', this.handleVrDisplayDeactivate_);\n    window__default['default'].removeEventListener('vrdisplaypresentchange', this.handleVrDisplayPresentChange_);\n  }\n}\nvideojs__default['default'].registerComponent('CardboardButton', CardboardButton);\n\nconst BigPlayButton = videojs__default['default'].getComponent('BigPlayButton');\nclass BigVrPlayButton extends BigPlayButton {\n  buildCSSClass() {\n    return `vjs-big-vr-play-button ${super.buildCSSClass()}`;\n  }\n}\nvideojs__default['default'].registerComponent('BigVrPlayButton', BigVrPlayButton);\n\n// Default options for the plugin.\nconst defaults = {\n  debug: false,\n  omnitone: false,\n  forceCardboard: false,\n  omnitoneOptions: {},\n  projection: 'AUTO',\n  sphereDetail: 32,\n  disableTogglePlay: false\n};\nconst errors = {\n  'web-vr-out-of-date': {\n    headline: '360 is out of date',\n    type: '360_OUT_OF_DATE',\n    message: \"Your browser supports 360 but not the latest version. See <a href='http://webvr.info'>http://webvr.info</a> for more info.\"\n  },\n  'web-vr-not-supported': {\n    headline: '360 not supported on this device',\n    type: '360_NOT_SUPPORTED',\n    message: \"Your browser does not support 360. See <a href='http://webvr.info'>http://webvr.info</a> for assistance.\"\n  },\n  'web-vr-hls-cors-not-supported': {\n    headline: '360 HLS video not supported on this device',\n    type: '360_NOT_SUPPORTED',\n    message: \"Your browser/device does not support HLS 360 video. See <a href='http://webvr.info'>http://webvr.info</a> for assistance.\"\n  }\n};\nconst Plugin = videojs__default['default'].getPlugin('plugin');\nconst Component = videojs__default['default'].getComponent('Component');\nclass VR extends Plugin {\n  constructor(player, options) {\n    const settings = videojs__default['default'].mergeOptions(defaults, options);\n    super(player, settings);\n    this.options_ = settings;\n    this.player_ = player;\n    this.bigPlayButtonIndex_ = player.children().indexOf(player.getChild('BigPlayButton')) || 0;\n\n    // custom videojs-errors integration boolean\n    this.videojsErrorsSupport_ = !!videojs__default['default'].errors;\n    if (this.videojsErrorsSupport_) {\n      player.errors({\n        errors\n      });\n    }\n\n    // IE 11 does not support enough webgl to be supported\n    // older safari does not support cors, so it wont work\n    if (videojs__default['default'].browser.IE_VERSION || !corsSupport) {\n      // if a player triggers error before 'loadstart' is fired\n      // video.js will reset the error overlay\n      this.player_.on('loadstart', () => {\n        this.triggerError_({\n          code: 'web-vr-not-supported',\n          dismiss: false\n        });\n      });\n      return;\n    }\n    this.polyfill_ = new WebVRPolyfill__default['default']({\n      // do not show rotate instructions\n      ROTATE_INSTRUCTIONS_DISABLED: true\n    });\n    this.polyfill_ = new WebVRPolyfill__default['default']();\n    this.handleVrDisplayActivate_ = videojs__default['default'].bind(this, this.handleVrDisplayActivate_);\n    this.handleVrDisplayDeactivate_ = videojs__default['default'].bind(this, this.handleVrDisplayDeactivate_);\n    this.handleResize_ = videojs__default['default'].bind(this, this.handleResize_);\n    this.animate_ = videojs__default['default'].bind(this, this.animate_);\n    this.setProjection(this.options_.projection);\n\n    // any time the video element is recycled for ads\n    // we have to reset the vr state and re-init after ad\n    this.on(player, 'adstart', () => player.setTimeout(() => {\n      // if the video element was recycled for this ad\n      if (!player.ads || !player.ads.videoElementRecycled()) {\n        this.log('video element not recycled for this ad, no need to reset');\n        return;\n      }\n      this.log('video element recycled for this ad, reseting');\n      this.reset();\n      this.one(player, 'playing', this.init);\n    }), 1);\n    this.on(player, 'loadedmetadata', this.init);\n  }\n  changeProjection_(projection) {\n    projection = getInternalProjectionName(projection);\n    // don't change to an invalid projection\n    if (!projection) {\n      projection = 'NONE';\n    }\n    const position = {\n      x: 0,\n      y: 0,\n      z: 0\n    };\n    if (this.scene) {\n      this.scene.remove(this.movieScreen);\n    }\n    if (projection === 'AUTO') {\n      // mediainfo cannot be set to auto or we would infinite loop here\n      // each source should know whatever they are 360 or not, if using AUTO\n      if (this.player_.mediainfo && this.player_.mediainfo.projection && this.player_.mediainfo.projection !== 'AUTO') {\n        const autoProjection = getInternalProjectionName(this.player_.mediainfo.projection);\n        return this.changeProjection_(autoProjection);\n      }\n      return this.changeProjection_('NONE');\n    } else if (projection === '360') {\n      this.movieGeometry = new SphereGeometry(256, this.options_.sphereDetail, this.options_.sphereDetail);\n      this.movieMaterial = new MeshBasicMaterial({\n        map: this.videoTexture,\n        overdraw: true,\n        side: BackSide\n      });\n      this.movieScreen = new Mesh(this.movieGeometry, this.movieMaterial);\n      this.movieScreen.position.set(position.x, position.y, position.z);\n      this.movieScreen.scale.x = -1;\n      this.movieScreen.quaternion.setFromAxisAngle({\n        x: 0,\n        y: 1,\n        z: 0\n      }, -Math.PI / 2);\n      this.scene.add(this.movieScreen);\n    } else if (projection === '360_LR' || projection === '360_TB') {\n      // Left eye view\n      let geometry = new SphereGeometry(256, this.options_.sphereDetail, this.options_.sphereDetail);\n      let uvs = geometry.faceVertexUvs[0];\n      for (let i = 0; i < uvs.length; i++) {\n        for (let j = 0; j < 3; j++) {\n          if (projection === '360_LR') {\n            uvs[i][j].x *= 0.5;\n          } else {\n            uvs[i][j].y *= 0.5;\n            uvs[i][j].y += 0.5;\n          }\n        }\n      }\n      this.movieGeometry = new BufferGeometry().fromGeometry(geometry);\n      this.movieMaterial = new MeshBasicMaterial({\n        map: this.videoTexture,\n        overdraw: true,\n        side: BackSide\n      });\n      this.movieScreen = new Mesh(this.movieGeometry, this.movieMaterial);\n      this.movieScreen.scale.x = -1;\n      this.movieScreen.quaternion.setFromAxisAngle({\n        x: 0,\n        y: 1,\n        z: 0\n      }, -Math.PI / 2);\n      // display in left eye only\n      this.movieScreen.layers.set(1);\n      this.scene.add(this.movieScreen);\n\n      // Right eye view\n      geometry = new SphereGeometry(256, this.options_.sphereDetail, this.options_.sphereDetail);\n      uvs = geometry.faceVertexUvs[0];\n      for (let i = 0; i < uvs.length; i++) {\n        for (let j = 0; j < 3; j++) {\n          if (projection === '360_LR') {\n            uvs[i][j].x *= 0.5;\n            uvs[i][j].x += 0.5;\n          } else {\n            uvs[i][j].y *= 0.5;\n          }\n        }\n      }\n      this.movieGeometry = new BufferGeometry().fromGeometry(geometry);\n      this.movieMaterial = new MeshBasicMaterial({\n        map: this.videoTexture,\n        overdraw: true,\n        side: BackSide\n      });\n      this.movieScreen = new Mesh(this.movieGeometry, this.movieMaterial);\n      this.movieScreen.scale.x = -1;\n      this.movieScreen.quaternion.setFromAxisAngle({\n        x: 0,\n        y: 1,\n        z: 0\n      }, -Math.PI / 2);\n      // display in right eye only\n      this.movieScreen.layers.set(2);\n      this.scene.add(this.movieScreen);\n    } else if (projection === '360_CUBE') {\n      this.movieGeometry = new BoxGeometry(256, 256, 256);\n      this.movieMaterial = new MeshBasicMaterial({\n        map: this.videoTexture,\n        overdraw: true,\n        side: BackSide\n      });\n      const left = [new Vector2(0, 0.5), new Vector2(0.333, 0.5), new Vector2(0.333, 1), new Vector2(0, 1)];\n      const right = [new Vector2(0.333, 0.5), new Vector2(0.666, 0.5), new Vector2(0.666, 1), new Vector2(0.333, 1)];\n      const top = [new Vector2(0.666, 0.5), new Vector2(1, 0.5), new Vector2(1, 1), new Vector2(0.666, 1)];\n      const bottom = [new Vector2(0, 0), new Vector2(0.333, 0), new Vector2(0.333, 0.5), new Vector2(0, 0.5)];\n      const front = [new Vector2(0.333, 0), new Vector2(0.666, 0), new Vector2(0.666, 0.5), new Vector2(0.333, 0.5)];\n      const back = [new Vector2(0.666, 0), new Vector2(1, 0), new Vector2(1, 0.5), new Vector2(0.666, 0.5)];\n      this.movieGeometry.faceVertexUvs[0] = [];\n      this.movieGeometry.faceVertexUvs[0][0] = [right[2], right[1], right[3]];\n      this.movieGeometry.faceVertexUvs[0][1] = [right[1], right[0], right[3]];\n      this.movieGeometry.faceVertexUvs[0][2] = [left[2], left[1], left[3]];\n      this.movieGeometry.faceVertexUvs[0][3] = [left[1], left[0], left[3]];\n      this.movieGeometry.faceVertexUvs[0][4] = [top[2], top[1], top[3]];\n      this.movieGeometry.faceVertexUvs[0][5] = [top[1], top[0], top[3]];\n      this.movieGeometry.faceVertexUvs[0][6] = [bottom[2], bottom[1], bottom[3]];\n      this.movieGeometry.faceVertexUvs[0][7] = [bottom[1], bottom[0], bottom[3]];\n      this.movieGeometry.faceVertexUvs[0][8] = [front[2], front[1], front[3]];\n      this.movieGeometry.faceVertexUvs[0][9] = [front[1], front[0], front[3]];\n      this.movieGeometry.faceVertexUvs[0][10] = [back[2], back[1], back[3]];\n      this.movieGeometry.faceVertexUvs[0][11] = [back[1], back[0], back[3]];\n      this.movieScreen = new Mesh(this.movieGeometry, this.movieMaterial);\n      this.movieScreen.position.set(position.x, position.y, position.z);\n      this.movieScreen.rotation.y = -Math.PI;\n      this.scene.add(this.movieScreen);\n    } else if (projection === '180' || projection === '180_LR' || projection === '180_MONO') {\n      let geometry = new SphereGeometry(256, this.options_.sphereDetail, this.options_.sphereDetail, Math.PI, Math.PI);\n\n      // Left eye view\n      geometry.scale(-1, 1, 1);\n      let uvs = geometry.faceVertexUvs[0];\n      if (projection !== '180_MONO') {\n        for (let i = 0; i < uvs.length; i++) {\n          for (let j = 0; j < 3; j++) {\n            uvs[i][j].x *= 0.5;\n          }\n        }\n      }\n      this.movieGeometry = new BufferGeometry().fromGeometry(geometry);\n      this.movieMaterial = new MeshBasicMaterial({\n        map: this.videoTexture,\n        overdraw: true\n      });\n      this.movieScreen = new Mesh(this.movieGeometry, this.movieMaterial);\n      // display in left eye only\n      this.movieScreen.layers.set(1);\n      this.scene.add(this.movieScreen);\n\n      // Right eye view\n      geometry = new SphereGeometry(256, this.options_.sphereDetail, this.options_.sphereDetail, Math.PI, Math.PI);\n      geometry.scale(-1, 1, 1);\n      uvs = geometry.faceVertexUvs[0];\n      for (let i = 0; i < uvs.length; i++) {\n        for (let j = 0; j < 3; j++) {\n          uvs[i][j].x *= 0.5;\n          uvs[i][j].x += 0.5;\n        }\n      }\n      this.movieGeometry = new BufferGeometry().fromGeometry(geometry);\n      this.movieMaterial = new MeshBasicMaterial({\n        map: this.videoTexture,\n        overdraw: true\n      });\n      this.movieScreen = new Mesh(this.movieGeometry, this.movieMaterial);\n      // display in right eye only\n      this.movieScreen.layers.set(2);\n      this.scene.add(this.movieScreen);\n    } else if (projection === 'EAC' || projection === 'EAC_LR') {\n      const makeScreen = (mapMatrix, scaleMatrix) => {\n        // \"Continuity correction?\": because of discontinuous faces and aliasing,\n        // we truncate the 2-pixel-wide strips on all discontinuous edges,\n        const contCorrect = 2;\n        this.movieGeometry = new BoxGeometry(256, 256, 256);\n        this.movieMaterial = new ShaderMaterial({\n          overdraw: true,\n          side: BackSide,\n          uniforms: {\n            mapped: {\n              value: this.videoTexture\n            },\n            mapMatrix: {\n              value: mapMatrix\n            },\n            contCorrect: {\n              value: contCorrect\n            },\n            faceWH: {\n              value: new Vector2(1 / 3, 1 / 2).applyMatrix3(scaleMatrix)\n            },\n            vidWH: {\n              value: new Vector2(this.videoTexture.image.videoWidth, this.videoTexture.image.videoHeight).applyMatrix3(scaleMatrix)\n            }\n          },\n          vertexShader: `\nvarying vec2 vUv;\nuniform mat3 mapMatrix;\n\nvoid main() {\n  vUv = (mapMatrix * vec3(uv, 1.)).xy;\n  gl_Position = projectionMatrix * modelViewMatrix * vec4(position, 1.);\n}`,\n          fragmentShader: `\nvarying vec2 vUv;\nuniform sampler2D mapped;\nuniform vec2 faceWH;\nuniform vec2 vidWH;\nuniform float contCorrect;\n\nconst float PI = 3.1415926535897932384626433832795;\n\nvoid main() {\n  vec2 corner = vUv - mod(vUv, faceWH) + vec2(0, contCorrect / vidWH.y);\n\n  vec2 faceWHadj = faceWH - vec2(0, contCorrect * 2. / vidWH.y);\n\n  vec2 p = (vUv - corner) / faceWHadj - .5;\n  vec2 q = 2. / PI * atan(2. * p) + .5;\n\n  vec2 eUv = corner + q * faceWHadj;\n\n  gl_FragColor = texture2D(mapped, eUv);\n}`\n        });\n        const right = [new Vector2(0, 1 / 2), new Vector2(1 / 3, 1 / 2), new Vector2(1 / 3, 1), new Vector2(0, 1)];\n        const front = [new Vector2(1 / 3, 1 / 2), new Vector2(2 / 3, 1 / 2), new Vector2(2 / 3, 1), new Vector2(1 / 3, 1)];\n        const left = [new Vector2(2 / 3, 1 / 2), new Vector2(1, 1 / 2), new Vector2(1, 1), new Vector2(2 / 3, 1)];\n        const bottom = [new Vector2(1 / 3, 0), new Vector2(1 / 3, 1 / 2), new Vector2(0, 1 / 2), new Vector2(0, 0)];\n        const back = [new Vector2(1 / 3, 1 / 2), new Vector2(1 / 3, 0), new Vector2(2 / 3, 0), new Vector2(2 / 3, 1 / 2)];\n        const top = [new Vector2(1, 0), new Vector2(1, 1 / 2), new Vector2(2 / 3, 1 / 2), new Vector2(2 / 3, 0)];\n        for (const face of [right, front, left, bottom, back, top]) {\n          const height = this.videoTexture.image.videoHeight;\n          let lowY = 1;\n          let highY = 0;\n          for (const vector of face) {\n            if (vector.y < lowY) {\n              lowY = vector.y;\n            }\n            if (vector.y > highY) {\n              highY = vector.y;\n            }\n          }\n          for (const vector of face) {\n            if (Math.abs(vector.y - lowY) < Number.EPSILON) {\n              vector.y += contCorrect / height;\n            }\n            if (Math.abs(vector.y - highY) < Number.EPSILON) {\n              vector.y -= contCorrect / height;\n            }\n            vector.x = vector.x / height * (height - contCorrect * 2) + contCorrect / height;\n          }\n        }\n        this.movieGeometry.faceVertexUvs[0] = [];\n        this.movieGeometry.faceVertexUvs[0][0] = [right[2], right[1], right[3]];\n        this.movieGeometry.faceVertexUvs[0][1] = [right[1], right[0], right[3]];\n        this.movieGeometry.faceVertexUvs[0][2] = [left[2], left[1], left[3]];\n        this.movieGeometry.faceVertexUvs[0][3] = [left[1], left[0], left[3]];\n        this.movieGeometry.faceVertexUvs[0][4] = [top[2], top[1], top[3]];\n        this.movieGeometry.faceVertexUvs[0][5] = [top[1], top[0], top[3]];\n        this.movieGeometry.faceVertexUvs[0][6] = [bottom[2], bottom[1], bottom[3]];\n        this.movieGeometry.faceVertexUvs[0][7] = [bottom[1], bottom[0], bottom[3]];\n        this.movieGeometry.faceVertexUvs[0][8] = [front[2], front[1], front[3]];\n        this.movieGeometry.faceVertexUvs[0][9] = [front[1], front[0], front[3]];\n        this.movieGeometry.faceVertexUvs[0][10] = [back[2], back[1], back[3]];\n        this.movieGeometry.faceVertexUvs[0][11] = [back[1], back[0], back[3]];\n        this.movieScreen = new Mesh(this.movieGeometry, this.movieMaterial);\n        this.movieScreen.position.set(position.x, position.y, position.z);\n        this.movieScreen.rotation.y = -Math.PI;\n        return this.movieScreen;\n      };\n      if (projection === 'EAC') {\n        this.scene.add(makeScreen(new Matrix3(), new Matrix3()));\n      } else {\n        const scaleMatrix = new Matrix3().set(0, 0.5, 0, 1, 0, 0, 0, 0, 1);\n        makeScreen(new Matrix3().set(0, -0.5, 0.5, 1, 0, 0, 0, 0, 1), scaleMatrix);\n        // display in left eye only\n        this.movieScreen.layers.set(1);\n        this.scene.add(this.movieScreen);\n        makeScreen(new Matrix3().set(0, -0.5, 1, 1, 0, 0, 0, 0, 1), scaleMatrix);\n        // display in right eye only\n        this.movieScreen.layers.set(2);\n        this.scene.add(this.movieScreen);\n      }\n    }\n    this.currentProjection_ = projection;\n  }\n  triggerError_(errorObj) {\n    // if we have videojs-errors use it\n    if (this.videojsErrorsSupport_) {\n      this.player_.error(errorObj);\n      // if we don't have videojs-errors just use a normal player error\n    } else {\n      // strip any html content from the error message\n      // as it is not supported outside of videojs-errors\n      const div = document__default['default'].createElement('div');\n      div.innerHTML = errors[errorObj.code].message;\n      const message = div.textContent || div.innerText || '';\n      this.player_.error({\n        code: errorObj.code,\n        message\n      });\n    }\n  }\n  log(...msgs) {\n    if (!this.options_.debug) {\n      return;\n    }\n    msgs.forEach(msg => {\n      videojs__default['default'].log('VR: ', msg);\n    });\n  }\n  handleVrDisplayActivate_() {\n    if (!this.vrDisplay) {\n      return;\n    }\n    this.vrDisplay.requestPresent([{\n      source: this.renderedCanvas\n    }]).then(() => {\n      if (!this.vrDisplay.cardboardUI_ || !videojs__default['default'].browser.IS_IOS) {\n        return;\n      }\n\n      // webvr-polyfill/cardboard ui only watches for click events\n      // to tell that the back arrow button is pressed during cardboard vr.\n      // but somewhere along the line these events are silenced with preventDefault\n      // but only on iOS, so we translate them ourselves here\n      let touches = [];\n      const iosCardboardTouchStart_ = e => {\n        for (let i = 0; i < e.touches.length; i++) {\n          touches.push(e.touches[i]);\n        }\n      };\n      const iosCardboardTouchEnd_ = e => {\n        if (!touches.length) {\n          return;\n        }\n        touches.forEach(t => {\n          const simulatedClick = new window__default['default'].MouseEvent('click', {\n            screenX: t.screenX,\n            screenY: t.screenY,\n            clientX: t.clientX,\n            clientY: t.clientY\n          });\n          this.renderedCanvas.dispatchEvent(simulatedClick);\n        });\n        touches = [];\n      };\n      this.renderedCanvas.addEventListener('touchstart', iosCardboardTouchStart_);\n      this.renderedCanvas.addEventListener('touchend', iosCardboardTouchEnd_);\n      this.iosRevertTouchToClick_ = () => {\n        this.renderedCanvas.removeEventListener('touchstart', iosCardboardTouchStart_);\n        this.renderedCanvas.removeEventListener('touchend', iosCardboardTouchEnd_);\n        this.iosRevertTouchToClick_ = null;\n      };\n    });\n  }\n  handleVrDisplayDeactivate_() {\n    if (!this.vrDisplay || !this.vrDisplay.isPresenting) {\n      return;\n    }\n    if (this.iosRevertTouchToClick_) {\n      this.iosRevertTouchToClick_();\n    }\n    this.vrDisplay.exitPresent();\n  }\n  requestAnimationFrame(fn) {\n    if (this.vrDisplay) {\n      return this.vrDisplay.requestAnimationFrame(fn);\n    }\n    return this.player_.requestAnimationFrame(fn);\n  }\n  cancelAnimationFrame(id) {\n    if (this.vrDisplay) {\n      return this.vrDisplay.cancelAnimationFrame(id);\n    }\n    return this.player_.cancelAnimationFrame(id);\n  }\n  togglePlay_() {\n    if (this.player_.paused()) {\n      this.player_.play();\n    } else {\n      this.player_.pause();\n    }\n  }\n  animate_() {\n    if (!this.initialized_) {\n      return;\n    }\n    if (this.getVideoEl_().readyState === this.getVideoEl_().HAVE_ENOUGH_DATA) {\n      if (this.videoTexture) {\n        this.videoTexture.needsUpdate = true;\n      }\n    }\n    this.controls3d.update();\n    if (this.omniController) {\n      this.omniController.update(this.camera);\n    }\n    this.effect.render(this.scene, this.camera);\n    if (window__default['default'].navigator.getGamepads) {\n      // Grab all gamepads\n      const gamepads = window__default['default'].navigator.getGamepads();\n      for (let i = 0; i < gamepads.length; ++i) {\n        const gamepad = gamepads[i];\n\n        // Make sure gamepad is defined\n        // Only take input if state has changed since we checked last\n        if (!gamepad || !gamepad.timestamp || gamepad.timestamp === this.prevTimestamps_[i]) {\n          continue;\n        }\n        for (let j = 0; j < gamepad.buttons.length; ++j) {\n          if (gamepad.buttons[j].pressed) {\n            this.togglePlay_();\n            this.prevTimestamps_[i] = gamepad.timestamp;\n            break;\n          }\n        }\n      }\n    }\n    this.camera.getWorldDirection(this.cameraVector);\n    this.animationFrameId_ = this.requestAnimationFrame(this.animate_);\n  }\n  handleResize_() {\n    const width = this.player_.currentWidth();\n    const height = this.player_.currentHeight();\n    this.effect.setSize(width, height, false);\n    this.camera.aspect = width / height;\n    this.camera.updateProjectionMatrix();\n  }\n  setProjection(projection) {\n    if (!getInternalProjectionName(projection)) {\n      videojs__default['default'].log.error('videojs-vr: please pass a valid projection ' + validProjections.join(', '));\n      return;\n    }\n    this.currentProjection_ = projection;\n    this.defaultProjection_ = projection;\n  }\n  init() {\n    this.reset();\n    this.camera = new PerspectiveCamera(75, this.player_.currentWidth() / this.player_.currentHeight(), 1, 1000);\n    // Store vector representing the direction in which the camera is looking, in world space.\n    this.cameraVector = new Vector3();\n    if (this.currentProjection_ === '360_LR' || this.currentProjection_ === '360_TB' || this.currentProjection_ === '180' || this.currentProjection_ === '180_LR' || this.currentProjection_ === '180_MONO' || this.currentProjection_ === 'EAC_LR') {\n      // Render left eye when not in VR mode\n      this.camera.layers.enable(1);\n    }\n    this.scene = new Scene();\n    this.videoTexture = new VideoTexture(this.getVideoEl_());\n\n    // shared regardless of wether VideoTexture is used or\n    // an image canvas is used\n    this.videoTexture.generateMipmaps = false;\n    this.videoTexture.minFilter = LinearFilter;\n    this.videoTexture.magFilter = LinearFilter;\n    this.videoTexture.format = RGBFormat;\n    this.changeProjection_(this.currentProjection_);\n    if (this.currentProjection_ === 'NONE') {\n      this.log('Projection is NONE, dont init');\n      this.reset();\n      return;\n    }\n    this.player_.removeChild('BigPlayButton');\n    this.player_.addChild('BigVrPlayButton', {}, this.bigPlayButtonIndex_);\n    this.player_.bigPlayButton = this.player_.getChild('BigVrPlayButton');\n\n    // mobile devices, or cardboard forced to on\n    if (this.options_.forceCardboard || videojs__default['default'].browser.IS_ANDROID || videojs__default['default'].browser.IS_IOS) {\n      this.addCardboardButton_();\n    }\n\n    // if ios remove full screen toggle\n    if (videojs__default['default'].browser.IS_IOS && this.player_.controlBar && this.player_.controlBar.fullscreenToggle) {\n      this.player_.controlBar.fullscreenToggle.hide();\n    }\n    this.camera.position.set(0, 0, 0);\n    this.renderer = new WebGLRenderer({\n      devicePixelRatio: window__default['default'].devicePixelRatio,\n      alpha: false,\n      clearColor: 0xffffff,\n      antialias: true\n    });\n    const webglContext = this.renderer.getContext('webgl');\n    const oldTexImage2D = webglContext.texImage2D;\n\n    /* this is a workaround since threejs uses try catch */\n    webglContext.texImage2D = (...args) => {\n      try {\n        return oldTexImage2D.apply(webglContext, args);\n      } catch (e) {\n        this.reset();\n        this.player_.pause();\n        this.triggerError_({\n          code: 'web-vr-hls-cors-not-supported',\n          dismiss: false\n        });\n        throw new Error(e);\n      }\n    };\n    this.renderer.setSize(this.player_.currentWidth(), this.player_.currentHeight(), false);\n    this.effect = new VREffect(this.renderer);\n    this.effect.setSize(this.player_.currentWidth(), this.player_.currentHeight(), false);\n    this.vrDisplay = null;\n\n    // Previous timestamps for gamepad updates\n    this.prevTimestamps_ = [];\n    this.renderedCanvas = this.renderer.domElement;\n    this.renderedCanvas.setAttribute('style', 'width: 100%; height: 100%; position: absolute; top:0;');\n    const videoElStyle = this.getVideoEl_().style;\n    this.player_.el().insertBefore(this.renderedCanvas, this.player_.el().firstChild);\n    videoElStyle.zIndex = '-1';\n    videoElStyle.opacity = '0';\n    if (window__default['default'].navigator.getVRDisplays) {\n      this.log('is supported, getting vr displays');\n      window__default['default'].navigator.getVRDisplays().then(displays => {\n        if (displays.length > 0) {\n          this.log('Displays found', displays);\n          this.vrDisplay = displays[0];\n\n          // Native WebVR Head Mounted Displays (HMDs) like the HTC Vive\n          // also need the cardboard button to enter fully immersive mode\n          // so, we want to add the button if we're not polyfilled.\n          if (!this.vrDisplay.isPolyfilled) {\n            this.log('Real HMD found using VRControls', this.vrDisplay);\n            this.addCardboardButton_();\n\n            // We use VRControls here since we are working with an HMD\n            // and we only want orientation controls.\n            this.controls3d = new VRControls(this.camera);\n          }\n        }\n        if (!this.controls3d) {\n          this.log('no HMD found Using Orbit & Orientation Controls');\n          const options = {\n            camera: this.camera,\n            canvas: this.renderedCanvas,\n            // check if its a half sphere view projection\n            halfView: this.currentProjection_.indexOf('180') === 0,\n            orientation: videojs__default['default'].browser.IS_IOS || videojs__default['default'].browser.IS_ANDROID || false\n          };\n          if (this.options_.motionControls === false) {\n            options.orientation = false;\n          }\n          this.controls3d = new OrbitOrientationControls(options);\n          this.canvasPlayerControls = new CanvasPlayerControls(this.player_, this.renderedCanvas, this.options_);\n        }\n        this.animationFrameId_ = this.requestAnimationFrame(this.animate_);\n      });\n    } else if (window__default['default'].navigator.getVRDevices) {\n      this.triggerError_({\n        code: 'web-vr-out-of-date',\n        dismiss: false\n      });\n    } else {\n      this.triggerError_({\n        code: 'web-vr-not-supported',\n        dismiss: false\n      });\n    }\n    if (this.options_.omnitone) {\n      const audiocontext = AudioContext.getContext();\n      this.omniController = new OmnitoneController(audiocontext, this.options_.omnitone, this.getVideoEl_(), this.options_.omnitoneOptions);\n      this.omniController.one('audiocontext-suspended', () => {\n        this.player.pause();\n        this.player.one('playing', () => {\n          audiocontext.resume();\n        });\n      });\n    }\n    this.on(this.player_, 'fullscreenchange', this.handleResize_);\n    window__default['default'].addEventListener('vrdisplaypresentchange', this.handleResize_, true);\n    window__default['default'].addEventListener('resize', this.handleResize_, true);\n    window__default['default'].addEventListener('vrdisplayactivate', this.handleVrDisplayActivate_, true);\n    window__default['default'].addEventListener('vrdisplaydeactivate', this.handleVrDisplayDeactivate_, true);\n    this.initialized_ = true;\n    this.trigger('initialized');\n  }\n  addCardboardButton_() {\n    if (!this.player_.controlBar.getChild('CardboardButton')) {\n      this.player_.controlBar.addChild('CardboardButton', {});\n    }\n  }\n  getVideoEl_() {\n    return this.player_.el().getElementsByTagName('video')[0];\n  }\n  reset() {\n    if (!this.initialized_) {\n      return;\n    }\n    if (this.omniController) {\n      this.omniController.off('audiocontext-suspended');\n      this.omniController.dispose();\n      this.omniController = undefined;\n    }\n    if (this.controls3d) {\n      this.controls3d.dispose();\n      this.controls3d = null;\n    }\n    if (this.canvasPlayerControls) {\n      this.canvasPlayerControls.dispose();\n      this.canvasPlayerControls = null;\n    }\n    if (this.effect) {\n      this.effect.dispose();\n      this.effect = null;\n    }\n    window__default['default'].removeEventListener('resize', this.handleResize_, true);\n    window__default['default'].removeEventListener('vrdisplaypresentchange', this.handleResize_, true);\n    window__default['default'].removeEventListener('vrdisplayactivate', this.handleVrDisplayActivate_, true);\n    window__default['default'].removeEventListener('vrdisplaydeactivate', this.handleVrDisplayDeactivate_, true);\n\n    // re-add the big play button to player\n    if (!this.player_.getChild('BigPlayButton')) {\n      this.player_.addChild('BigPlayButton', {}, this.bigPlayButtonIndex_);\n    }\n    if (this.player_.getChild('BigVrPlayButton')) {\n      this.player_.removeChild('BigVrPlayButton');\n    }\n\n    // remove the cardboard button\n    if (this.player_.getChild('CardboardButton')) {\n      this.player_.controlBar.removeChild('CardboardButton');\n    }\n\n    // show the fullscreen again\n    if (videojs__default['default'].browser.IS_IOS && this.player_.controlBar && this.player_.controlBar.fullscreenToggle) {\n      this.player_.controlBar.fullscreenToggle.show();\n    }\n\n    // reset the video element style so that it will be displayed\n    const videoElStyle = this.getVideoEl_().style;\n    videoElStyle.zIndex = '';\n    videoElStyle.opacity = '';\n\n    // set the current projection to the default\n    this.currentProjection_ = this.defaultProjection_;\n\n    // reset the ios touch to click workaround\n    if (this.iosRevertTouchToClick_) {\n      this.iosRevertTouchToClick_();\n    }\n\n    // remove the old canvas\n    if (this.renderedCanvas) {\n      this.renderedCanvas.parentNode.removeChild(this.renderedCanvas);\n    }\n    if (this.animationFrameId_) {\n      this.cancelAnimationFrame(this.animationFrameId_);\n    }\n    this.initialized_ = false;\n  }\n  dispose() {\n    super.dispose();\n    this.reset();\n  }\n  polyfillVersion() {\n    return WebVRPolyfill__default['default'].version;\n  }\n}\nVR.prototype.setTimeout = Component.prototype.setTimeout;\nVR.prototype.clearTimeout = Component.prototype.clearTimeout;\nVR.VERSION = version;\nvideojs__default['default'].registerPlugin('vr', VR);\n\nmodule.exports = VR;\n"]}