babylonjs-loaders 5.45.2 → 5.46.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3479,8 +3479,8 @@ var KHR_animation_pointer = /** @class */ (function () {
3479
3479
  if (!extension) {
3480
3480
  return null;
3481
3481
  }
3482
- if (channel.target.path !== "pointer" /* POINTER */) {
3483
- core_Misc_logger__WEBPACK_IMPORTED_MODULE_1__.Logger.Warn("".concat(context, "/target/path: Value (").concat(channel.target.path, ") must be (").concat("pointer" /* POINTER */, ") when using the ").concat(this.name, " extension"));
3482
+ if (channel.target.path !== "pointer" /* AnimationChannelTargetPath.POINTER */) {
3483
+ core_Misc_logger__WEBPACK_IMPORTED_MODULE_1__.Logger.Warn("".concat(context, "/target/path: Value (").concat(channel.target.path, ") must be (").concat("pointer" /* AnimationChannelTargetPath.POINTER */, ") when using the ").concat(this.name, " extension"));
3484
3484
  }
3485
3485
  if (channel.target.node != undefined) {
3486
3486
  core_Misc_logger__WEBPACK_IMPORTED_MODULE_1__.Logger.Warn("".concat(context, "/target/node: Value (").concat(channel.target.node, ") must not be present when using the ").concat(this.name, " extension"));
@@ -3603,11 +3603,11 @@ var KHR_draco_mesh_compression = /** @class */ (function () {
3603
3603
  var _this = this;
3604
3604
  return _glTFLoader__WEBPACK_IMPORTED_MODULE_1__.GLTFLoader.LoadExtensionAsync(context, primitive, this.name, function (extensionContext, extension) {
3605
3605
  if (primitive.mode != undefined) {
3606
- if (primitive.mode !== 5 /* TRIANGLE_STRIP */ && primitive.mode !== 4 /* TRIANGLES */) {
3606
+ if (primitive.mode !== 5 /* MeshPrimitiveMode.TRIANGLE_STRIP */ && primitive.mode !== 4 /* MeshPrimitiveMode.TRIANGLES */) {
3607
3607
  throw new Error("".concat(context, ": Unsupported mode ").concat(primitive.mode));
3608
3608
  }
3609
3609
  // TODO: handle triangle strips
3610
- if (primitive.mode === 5 /* TRIANGLE_STRIP */) {
3610
+ if (primitive.mode === 5 /* MeshPrimitiveMode.TRIANGLE_STRIP */) {
3611
3611
  throw new Error("".concat(context, ": Mode ").concat(primitive.mode, " is not currently supported"));
3612
3612
  }
3613
3613
  }
@@ -3620,19 +3620,19 @@ var KHR_draco_mesh_compression = /** @class */ (function () {
3620
3620
  }
3621
3621
  attributes[kind] = uniqueId;
3622
3622
  var accessor = _glTFLoader__WEBPACK_IMPORTED_MODULE_1__.ArrayItem.Get("".concat(context, "/attributes/").concat(name), _this._loader.gltf.accessors, primitive.attributes[name]);
3623
- if (accessor.normalized && accessor.componentType !== 5126 /* FLOAT */) {
3623
+ if (accessor.normalized && accessor.componentType !== 5126 /* AccessorComponentType.FLOAT */) {
3624
3624
  var divider = 1;
3625
3625
  switch (accessor.componentType) {
3626
- case 5120 /* BYTE */:
3626
+ case 5120 /* AccessorComponentType.BYTE */:
3627
3627
  divider = 127.0;
3628
3628
  break;
3629
- case 5121 /* UNSIGNED_BYTE */:
3629
+ case 5121 /* AccessorComponentType.UNSIGNED_BYTE */:
3630
3630
  divider = 255.0;
3631
3631
  break;
3632
- case 5122 /* SHORT */:
3632
+ case 5122 /* AccessorComponentType.SHORT */:
3633
3633
  divider = 32767.0;
3634
3634
  break;
3635
- case 5123 /* UNSIGNED_SHORT */:
3635
+ case 5123 /* AccessorComponentType.UNSIGNED_SHORT */:
3636
3636
  divider = 65535.0;
3637
3637
  break;
3638
3638
  }
@@ -3745,15 +3745,15 @@ var KHR_lights = /** @class */ (function () {
3745
3745
  var name = light.name || babylonMesh.name;
3746
3746
  _this._loader.babylonScene._blockEntityCollection = !!_this._loader._assetContainer;
3747
3747
  switch (light.type) {
3748
- case "directional" /* DIRECTIONAL */: {
3748
+ case "directional" /* KHRLightsPunctual_LightType.DIRECTIONAL */: {
3749
3749
  babylonLight = new core_Maths_math_vector__WEBPACK_IMPORTED_MODULE_0__.DirectionalLight(name, core_Maths_math_vector__WEBPACK_IMPORTED_MODULE_0__.Vector3.Backward(), _this._loader.babylonScene);
3750
3750
  break;
3751
3751
  }
3752
- case "point" /* POINT */: {
3752
+ case "point" /* KHRLightsPunctual_LightType.POINT */: {
3753
3753
  babylonLight = new core_Maths_math_vector__WEBPACK_IMPORTED_MODULE_0__.PointLight(name, core_Maths_math_vector__WEBPACK_IMPORTED_MODULE_0__.Vector3.Zero(), _this._loader.babylonScene);
3754
3754
  break;
3755
3755
  }
3756
- case "spot" /* SPOT */: {
3756
+ case "spot" /* KHRLightsPunctual_LightType.SPOT */: {
3757
3757
  var babylonSpotLight = new core_Maths_math_vector__WEBPACK_IMPORTED_MODULE_0__.SpotLight(name, core_Maths_math_vector__WEBPACK_IMPORTED_MODULE_0__.Vector3.Zero(), core_Maths_math_vector__WEBPACK_IMPORTED_MODULE_0__.Vector3.Backward(), 0, 1, _this._loader.babylonScene);
3758
3758
  babylonSpotLight.angle = ((light.spot && light.spot.outerConeAngle) || Math.PI / 4) * 2;
3759
3759
  babylonSpotLight.innerAngle = ((light.spot && light.spot.innerConeAngle) || 0) * 2;
@@ -5684,18 +5684,18 @@ var MSFT_audio_emitter = /** @class */ (function () {
5684
5684
  };
5685
5685
  MSFT_audio_emitter.prototype._getEventAction = function (context, sound, action, time, startOffset) {
5686
5686
  switch (action) {
5687
- case "play" /* play */: {
5687
+ case "play" /* IMSFTAudioEmitter_AnimationEventAction.play */: {
5688
5688
  return function (currentFrame) {
5689
5689
  var frameOffset = (startOffset || 0) + (currentFrame - time);
5690
5690
  sound.play(frameOffset);
5691
5691
  };
5692
5692
  }
5693
- case "stop" /* stop */: {
5693
+ case "stop" /* IMSFTAudioEmitter_AnimationEventAction.stop */: {
5694
5694
  return function () {
5695
5695
  sound.stop();
5696
5696
  };
5697
5697
  }
5698
- case "pause" /* pause */: {
5698
+ case "pause" /* IMSFTAudioEmitter_AnimationEventAction.pause */: {
5699
5699
  return function () {
5700
5700
  sound.pause();
5701
5701
  };
@@ -7183,19 +7183,19 @@ var GLTFLoader = /** @class */ (function () {
7183
7183
  if (babylonVertexBuffer.getKind() === core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.VertexBuffer.PositionKind && !_this.parent.alwaysComputeBoundingBox && !babylonMesh.skeleton) {
7184
7184
  var mmin = accessor.min, mmax = accessor.max;
7185
7185
  if (mmin !== undefined && mmax !== undefined) {
7186
- if (accessor.normalized && accessor.componentType !== 5126 /* FLOAT */) {
7186
+ if (accessor.normalized && accessor.componentType !== 5126 /* AccessorComponentType.FLOAT */) {
7187
7187
  var divider = 1;
7188
7188
  switch (accessor.componentType) {
7189
- case 5120 /* BYTE */:
7189
+ case 5120 /* AccessorComponentType.BYTE */:
7190
7190
  divider = 127.0;
7191
7191
  break;
7192
- case 5121 /* UNSIGNED_BYTE */:
7192
+ case 5121 /* AccessorComponentType.UNSIGNED_BYTE */:
7193
7193
  divider = 255.0;
7194
7194
  break;
7195
- case 5122 /* SHORT */:
7195
+ case 5122 /* AccessorComponentType.SHORT */:
7196
7196
  divider = 32767.0;
7197
7197
  break;
7198
- case 5123 /* UNSIGNED_SHORT */:
7198
+ case 5123 /* AccessorComponentType.UNSIGNED_SHORT */:
7199
7199
  divider = 65535.0;
7200
7200
  break;
7201
7201
  }
@@ -7234,7 +7234,7 @@ var GLTFLoader = /** @class */ (function () {
7234
7234
  loadAttribute("JOINTS_1", core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.VertexBuffer.MatricesIndicesExtraKind);
7235
7235
  loadAttribute("WEIGHTS_1", core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.VertexBuffer.MatricesWeightsExtraKind);
7236
7236
  loadAttribute("COLOR_0", core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.VertexBuffer.ColorKind, function (accessor) {
7237
- if (accessor.type === "VEC4" /* VEC4 */) {
7237
+ if (accessor.type === "VEC4" /* AccessorType.VEC4 */) {
7238
7238
  babylonMesh.hasVertexAlpha = true;
7239
7239
  }
7240
7240
  });
@@ -7518,7 +7518,7 @@ var GLTFLoader = /** @class */ (function () {
7518
7518
  camera._babylonCamera = babylonCamera;
7519
7519
  babylonCamera.rotation = new core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Vector3(0, Math.PI, 0);
7520
7520
  switch (camera.type) {
7521
- case "perspective" /* PERSPECTIVE */: {
7521
+ case "perspective" /* CameraType.PERSPECTIVE */: {
7522
7522
  var perspective = camera.perspective;
7523
7523
  if (!perspective) {
7524
7524
  throw new Error("".concat(context, ": Camera perspective properties are missing"));
@@ -7528,7 +7528,7 @@ var GLTFLoader = /** @class */ (function () {
7528
7528
  babylonCamera.maxZ = perspective.zfar || 0;
7529
7529
  break;
7530
7530
  }
7531
- case "orthographic" /* ORTHOGRAPHIC */: {
7531
+ case "orthographic" /* CameraType.ORTHOGRAPHIC */: {
7532
7532
  if (!camera.orthographic) {
7533
7533
  throw new Error("".concat(context, ": Camera orthographic properties are missing"));
7534
7534
  }
@@ -7622,25 +7622,25 @@ var GLTFLoader = /** @class */ (function () {
7622
7622
  }
7623
7623
  var targetNode = ArrayItem.Get("".concat(context, "/target/node"), this._gltf.nodes, channel.target.node);
7624
7624
  // Ignore animations that have no animation targets.
7625
- if ((channel.target.path === "weights" /* WEIGHTS */ && !targetNode._numMorphTargets) ||
7626
- (channel.target.path !== "weights" /* WEIGHTS */ && !targetNode._babylonTransformNode)) {
7625
+ if ((channel.target.path === "weights" /* AnimationChannelTargetPath.WEIGHTS */ && !targetNode._numMorphTargets) ||
7626
+ (channel.target.path !== "weights" /* AnimationChannelTargetPath.WEIGHTS */ && !targetNode._babylonTransformNode)) {
7627
7627
  return Promise.resolve();
7628
7628
  }
7629
7629
  var properties;
7630
7630
  switch (channel.target.path) {
7631
- case "translation" /* TRANSLATION */: {
7631
+ case "translation" /* AnimationChannelTargetPath.TRANSLATION */: {
7632
7632
  properties = _glTFLoaderAnimation__WEBPACK_IMPORTED_MODULE_2__.nodeAnimationData.translation;
7633
7633
  break;
7634
7634
  }
7635
- case "rotation" /* ROTATION */: {
7635
+ case "rotation" /* AnimationChannelTargetPath.ROTATION */: {
7636
7636
  properties = _glTFLoaderAnimation__WEBPACK_IMPORTED_MODULE_2__.nodeAnimationData.rotation;
7637
7637
  break;
7638
7638
  }
7639
- case "scale" /* SCALE */: {
7639
+ case "scale" /* AnimationChannelTargetPath.SCALE */: {
7640
7640
  properties = _glTFLoaderAnimation__WEBPACK_IMPORTED_MODULE_2__.nodeAnimationData.scale;
7641
7641
  break;
7642
7642
  }
7643
- case "weights" /* WEIGHTS */: {
7643
+ case "weights" /* AnimationChannelTargetPath.WEIGHTS */: {
7644
7644
  properties = _glTFLoaderAnimation__WEBPACK_IMPORTED_MODULE_2__.nodeAnimationData.weights;
7645
7645
  break;
7646
7646
  }
@@ -7684,7 +7684,7 @@ var GLTFLoader = /** @class */ (function () {
7684
7684
  var keys = new Array(input.length);
7685
7685
  var outputOffset = 0;
7686
7686
  switch (data.interpolation) {
7687
- case "STEP" /* STEP */: {
7687
+ case "STEP" /* AnimationSamplerInterpolation.STEP */: {
7688
7688
  for (var index = 0; index < input.length; index++) {
7689
7689
  var value = property.getValue(targetInfo.target, output, outputOffset, 1);
7690
7690
  outputOffset += stride;
@@ -7696,7 +7696,7 @@ var GLTFLoader = /** @class */ (function () {
7696
7696
  }
7697
7697
  break;
7698
7698
  }
7699
- case "CUBICSPLINE" /* CUBICSPLINE */: {
7699
+ case "CUBICSPLINE" /* AnimationSamplerInterpolation.CUBICSPLINE */: {
7700
7700
  for (var index = 0; index < input.length; index++) {
7701
7701
  var inTangent = property.getValue(targetInfo.target, output, outputOffset, invfps);
7702
7702
  outputOffset += stride;
@@ -7713,7 +7713,7 @@ var GLTFLoader = /** @class */ (function () {
7713
7713
  }
7714
7714
  break;
7715
7715
  }
7716
- case "LINEAR" /* LINEAR */: {
7716
+ case "LINEAR" /* AnimationSamplerInterpolation.LINEAR */: {
7717
7717
  for (var index = 0; index < input.length; index++) {
7718
7718
  var value = property.getValue(targetInfo.target, output, outputOffset, 1);
7719
7719
  outputOffset += stride;
@@ -7739,11 +7739,11 @@ var GLTFLoader = /** @class */ (function () {
7739
7739
  if (sampler._data) {
7740
7740
  return sampler._data;
7741
7741
  }
7742
- var interpolation = sampler.interpolation || "LINEAR" /* LINEAR */;
7742
+ var interpolation = sampler.interpolation || "LINEAR" /* AnimationSamplerInterpolation.LINEAR */;
7743
7743
  switch (interpolation) {
7744
- case "STEP" /* STEP */:
7745
- case "LINEAR" /* LINEAR */:
7746
- case "CUBICSPLINE" /* CUBICSPLINE */: {
7744
+ case "STEP" /* AnimationSamplerInterpolation.STEP */:
7745
+ case "LINEAR" /* AnimationSamplerInterpolation.LINEAR */:
7746
+ case "CUBICSPLINE" /* AnimationSamplerInterpolation.CUBICSPLINE */: {
7747
7747
  break;
7748
7748
  }
7749
7749
  default: {
@@ -7830,7 +7830,7 @@ var GLTFLoader = /** @class */ (function () {
7830
7830
  else {
7831
7831
  var bufferView_1 = ArrayItem.Get("".concat(context, "/bufferView"), this._gltf.bufferViews, accessor.bufferView);
7832
7832
  accessor._data = this.loadBufferViewAsync("/bufferViews/".concat(bufferView_1.index), bufferView_1).then(function (data) {
7833
- if (accessor.componentType === 5126 /* FLOAT */ && !accessor.normalized && (!bufferView_1.byteStride || bufferView_1.byteStride === byteStride)) {
7833
+ if (accessor.componentType === 5126 /* AccessorComponentType.FLOAT */ && !accessor.normalized && (!bufferView_1.byteStride || bufferView_1.byteStride === byteStride)) {
7834
7834
  return GLTFLoader._GetTypedArray(context, accessor.componentType, data, accessor.byteOffset, length);
7835
7835
  }
7836
7836
  else {
@@ -7856,7 +7856,7 @@ var GLTFLoader = /** @class */ (function () {
7856
7856
  var indices = GLTFLoader._GetTypedArray("".concat(context, "/sparse/indices"), sparse_1.indices.componentType, indicesData, sparse_1.indices.byteOffset, sparse_1.count);
7857
7857
  var sparseLength = numComponents * sparse_1.count;
7858
7858
  var values;
7859
- if (accessor.componentType === 5126 /* FLOAT */ && !accessor.normalized) {
7859
+ if (accessor.componentType === 5126 /* AccessorComponentType.FLOAT */ && !accessor.normalized) {
7860
7860
  values = GLTFLoader._GetTypedArray("".concat(context, "/sparse/values"), accessor.componentType, valuesData, sparse_1.values.byteOffset, sparseLength);
7861
7861
  }
7862
7862
  else {
@@ -7886,12 +7886,12 @@ var GLTFLoader = /** @class */ (function () {
7886
7886
  return this._loadAccessorAsync(context, accessor, Float32Array);
7887
7887
  };
7888
7888
  GLTFLoader.prototype._loadIndicesAccessorAsync = function (context, accessor) {
7889
- if (accessor.type !== "SCALAR" /* SCALAR */) {
7889
+ if (accessor.type !== "SCALAR" /* AccessorType.SCALAR */) {
7890
7890
  throw new Error("".concat(context, "/type: Invalid value ").concat(accessor.type));
7891
7891
  }
7892
- if (accessor.componentType !== 5121 /* UNSIGNED_BYTE */ &&
7893
- accessor.componentType !== 5123 /* UNSIGNED_SHORT */ &&
7894
- accessor.componentType !== 5125 /* UNSIGNED_INT */) {
7892
+ if (accessor.componentType !== 5121 /* AccessorComponentType.UNSIGNED_BYTE */ &&
7893
+ accessor.componentType !== 5123 /* AccessorComponentType.UNSIGNED_SHORT */ &&
7894
+ accessor.componentType !== 5125 /* AccessorComponentType.UNSIGNED_INT */) {
7895
7895
  throw new Error("".concat(context, "/componentType: Invalid value ").concat(accessor.componentType));
7896
7896
  }
7897
7897
  if (accessor._data) {
@@ -8132,13 +8132,13 @@ var GLTFLoader = /** @class */ (function () {
8132
8132
  if (!(babylonMaterial instanceof core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.PBRMaterial)) {
8133
8133
  throw new Error("".concat(context, ": Material type not supported"));
8134
8134
  }
8135
- var alphaMode = material.alphaMode || "OPAQUE" /* OPAQUE */;
8135
+ var alphaMode = material.alphaMode || "OPAQUE" /* MaterialAlphaMode.OPAQUE */;
8136
8136
  switch (alphaMode) {
8137
- case "OPAQUE" /* OPAQUE */: {
8137
+ case "OPAQUE" /* MaterialAlphaMode.OPAQUE */: {
8138
8138
  babylonMaterial.transparencyMode = core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.PBRMaterial.PBRMATERIAL_OPAQUE;
8139
8139
  break;
8140
8140
  }
8141
- case "MASK" /* MASK */: {
8141
+ case "MASK" /* MaterialAlphaMode.MASK */: {
8142
8142
  babylonMaterial.transparencyMode = core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.PBRMaterial.PBRMATERIAL_ALPHATEST;
8143
8143
  babylonMaterial.alphaCutOff = material.alphaCutoff == undefined ? 0.5 : material.alphaCutoff;
8144
8144
  if (babylonMaterial.albedoTexture) {
@@ -8146,7 +8146,7 @@ var GLTFLoader = /** @class */ (function () {
8146
8146
  }
8147
8147
  break;
8148
8148
  }
8149
- case "BLEND" /* BLEND */: {
8149
+ case "BLEND" /* MaterialAlphaMode.BLEND */: {
8150
8150
  babylonMaterial.transparencyMode = core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.PBRMaterial.PBRMATERIAL_ALPHABLEND;
8151
8151
  if (babylonMaterial.albedoTexture) {
8152
8152
  babylonMaterial.albedoTexture.hasAlpha = true;
@@ -8251,7 +8251,7 @@ var GLTFLoader = /** @class */ (function () {
8251
8251
  GLTFLoader.prototype._loadSampler = function (context, sampler) {
8252
8252
  if (!sampler._data) {
8253
8253
  sampler._data = {
8254
- noMipMaps: sampler.minFilter === 9728 /* NEAREST */ || sampler.minFilter === 9729 /* LINEAR */,
8254
+ noMipMaps: sampler.minFilter === 9728 /* TextureMinFilter.NEAREST */ || sampler.minFilter === 9729 /* TextureMinFilter.LINEAR */,
8255
8255
  samplingMode: GLTFLoader._GetTextureSamplingMode(context, sampler),
8256
8256
  wrapU: GLTFLoader._GetTextureWrapMode("".concat(context, "/wrapS"), sampler.wrapS),
8257
8257
  wrapV: GLTFLoader._GetTextureWrapMode("".concat(context, "/wrapT"), sampler.wrapT),
@@ -8328,13 +8328,13 @@ var GLTFLoader = /** @class */ (function () {
8328
8328
  };
8329
8329
  GLTFLoader._GetTextureWrapMode = function (context, mode) {
8330
8330
  // Set defaults if undefined
8331
- mode = mode == undefined ? 10497 /* REPEAT */ : mode;
8331
+ mode = mode == undefined ? 10497 /* TextureWrapMode.REPEAT */ : mode;
8332
8332
  switch (mode) {
8333
- case 33071 /* CLAMP_TO_EDGE */:
8333
+ case 33071 /* TextureWrapMode.CLAMP_TO_EDGE */:
8334
8334
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.CLAMP_ADDRESSMODE;
8335
- case 33648 /* MIRRORED_REPEAT */:
8335
+ case 33648 /* TextureWrapMode.MIRRORED_REPEAT */:
8336
8336
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.MIRROR_ADDRESSMODE;
8337
- case 10497 /* REPEAT */:
8337
+ case 10497 /* TextureWrapMode.REPEAT */:
8338
8338
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.WRAP_ADDRESSMODE;
8339
8339
  default:
8340
8340
  core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Logger.Warn("".concat(context, ": Invalid value (").concat(mode, ")"));
@@ -8343,21 +8343,21 @@ var GLTFLoader = /** @class */ (function () {
8343
8343
  };
8344
8344
  GLTFLoader._GetTextureSamplingMode = function (context, sampler) {
8345
8345
  // Set defaults if undefined
8346
- var magFilter = sampler.magFilter == undefined ? 9729 /* LINEAR */ : sampler.magFilter;
8347
- var minFilter = sampler.minFilter == undefined ? 9987 /* LINEAR_MIPMAP_LINEAR */ : sampler.minFilter;
8348
- if (magFilter === 9729 /* LINEAR */) {
8346
+ var magFilter = sampler.magFilter == undefined ? 9729 /* TextureMagFilter.LINEAR */ : sampler.magFilter;
8347
+ var minFilter = sampler.minFilter == undefined ? 9987 /* TextureMinFilter.LINEAR_MIPMAP_LINEAR */ : sampler.minFilter;
8348
+ if (magFilter === 9729 /* TextureMagFilter.LINEAR */) {
8349
8349
  switch (minFilter) {
8350
- case 9728 /* NEAREST */:
8350
+ case 9728 /* TextureMinFilter.NEAREST */:
8351
8351
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.LINEAR_NEAREST;
8352
- case 9729 /* LINEAR */:
8352
+ case 9729 /* TextureMinFilter.LINEAR */:
8353
8353
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.LINEAR_LINEAR;
8354
- case 9984 /* NEAREST_MIPMAP_NEAREST */:
8354
+ case 9984 /* TextureMinFilter.NEAREST_MIPMAP_NEAREST */:
8355
8355
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.LINEAR_NEAREST_MIPNEAREST;
8356
- case 9985 /* LINEAR_MIPMAP_NEAREST */:
8356
+ case 9985 /* TextureMinFilter.LINEAR_MIPMAP_NEAREST */:
8357
8357
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.LINEAR_LINEAR_MIPNEAREST;
8358
- case 9986 /* NEAREST_MIPMAP_LINEAR */:
8358
+ case 9986 /* TextureMinFilter.NEAREST_MIPMAP_LINEAR */:
8359
8359
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.LINEAR_NEAREST_MIPLINEAR;
8360
- case 9987 /* LINEAR_MIPMAP_LINEAR */:
8360
+ case 9987 /* TextureMinFilter.LINEAR_MIPMAP_LINEAR */:
8361
8361
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.LINEAR_LINEAR_MIPLINEAR;
8362
8362
  default:
8363
8363
  core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Logger.Warn("".concat(context, "/minFilter: Invalid value (").concat(minFilter, ")"));
@@ -8365,21 +8365,21 @@ var GLTFLoader = /** @class */ (function () {
8365
8365
  }
8366
8366
  }
8367
8367
  else {
8368
- if (magFilter !== 9728 /* NEAREST */) {
8368
+ if (magFilter !== 9728 /* TextureMagFilter.NEAREST */) {
8369
8369
  core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Logger.Warn("".concat(context, "/magFilter: Invalid value (").concat(magFilter, ")"));
8370
8370
  }
8371
8371
  switch (minFilter) {
8372
- case 9728 /* NEAREST */:
8372
+ case 9728 /* TextureMinFilter.NEAREST */:
8373
8373
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.NEAREST_NEAREST;
8374
- case 9729 /* LINEAR */:
8374
+ case 9729 /* TextureMinFilter.LINEAR */:
8375
8375
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.NEAREST_LINEAR;
8376
- case 9984 /* NEAREST_MIPMAP_NEAREST */:
8376
+ case 9984 /* TextureMinFilter.NEAREST_MIPMAP_NEAREST */:
8377
8377
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.NEAREST_NEAREST_MIPNEAREST;
8378
- case 9985 /* LINEAR_MIPMAP_NEAREST */:
8378
+ case 9985 /* TextureMinFilter.LINEAR_MIPMAP_NEAREST */:
8379
8379
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.NEAREST_LINEAR_MIPNEAREST;
8380
- case 9986 /* NEAREST_MIPMAP_LINEAR */:
8380
+ case 9986 /* TextureMinFilter.NEAREST_MIPMAP_LINEAR */:
8381
8381
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.NEAREST_NEAREST_MIPLINEAR;
8382
- case 9987 /* LINEAR_MIPMAP_LINEAR */:
8382
+ case 9987 /* TextureMinFilter.LINEAR_MIPMAP_LINEAR */:
8383
8383
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Texture.NEAREST_LINEAR_MIPLINEAR;
8384
8384
  default:
8385
8385
  core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Logger.Warn("".concat(context, "/minFilter: Invalid value (").concat(minFilter, ")"));
@@ -8389,17 +8389,17 @@ var GLTFLoader = /** @class */ (function () {
8389
8389
  };
8390
8390
  GLTFLoader._GetTypedArrayConstructor = function (context, componentType) {
8391
8391
  switch (componentType) {
8392
- case 5120 /* BYTE */:
8392
+ case 5120 /* AccessorComponentType.BYTE */:
8393
8393
  return Int8Array;
8394
- case 5121 /* UNSIGNED_BYTE */:
8394
+ case 5121 /* AccessorComponentType.UNSIGNED_BYTE */:
8395
8395
  return Uint8Array;
8396
- case 5122 /* SHORT */:
8396
+ case 5122 /* AccessorComponentType.SHORT */:
8397
8397
  return Int16Array;
8398
- case 5123 /* UNSIGNED_SHORT */:
8398
+ case 5123 /* AccessorComponentType.UNSIGNED_SHORT */:
8399
8399
  return Uint16Array;
8400
- case 5125 /* UNSIGNED_INT */:
8400
+ case 5125 /* AccessorComponentType.UNSIGNED_INT */:
8401
8401
  return Uint32Array;
8402
- case 5126 /* FLOAT */:
8402
+ case 5126 /* AccessorComponentType.FLOAT */:
8403
8403
  return Float32Array;
8404
8404
  default:
8405
8405
  throw new Error("".concat(context, ": Invalid component type ").concat(componentType));
@@ -8444,22 +8444,22 @@ var GLTFLoader = /** @class */ (function () {
8444
8444
  */
8445
8445
  GLTFLoader._GetDrawMode = function (context, mode) {
8446
8446
  if (mode == undefined) {
8447
- mode = 4 /* TRIANGLES */;
8447
+ mode = 4 /* MeshPrimitiveMode.TRIANGLES */;
8448
8448
  }
8449
8449
  switch (mode) {
8450
- case 0 /* POINTS */:
8450
+ case 0 /* MeshPrimitiveMode.POINTS */:
8451
8451
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Material.PointListDrawMode;
8452
- case 1 /* LINES */:
8452
+ case 1 /* MeshPrimitiveMode.LINES */:
8453
8453
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Material.LineListDrawMode;
8454
- case 2 /* LINE_LOOP */:
8454
+ case 2 /* MeshPrimitiveMode.LINE_LOOP */:
8455
8455
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Material.LineLoopDrawMode;
8456
- case 3 /* LINE_STRIP */:
8456
+ case 3 /* MeshPrimitiveMode.LINE_STRIP */:
8457
8457
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Material.LineStripDrawMode;
8458
- case 4 /* TRIANGLES */:
8458
+ case 4 /* MeshPrimitiveMode.TRIANGLES */:
8459
8459
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Material.TriangleFillMode;
8460
- case 5 /* TRIANGLE_STRIP */:
8460
+ case 5 /* MeshPrimitiveMode.TRIANGLE_STRIP */:
8461
8461
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Material.TriangleStripDrawMode;
8462
- case 6 /* TRIANGLE_FAN */:
8462
+ case 6 /* MeshPrimitiveMode.TRIANGLE_FAN */:
8463
8463
  return core_Misc_deferred__WEBPACK_IMPORTED_MODULE_0__.Material.TriangleFanDrawMode;
8464
8464
  }
8465
8465
  throw new Error("".concat(context, ": Invalid mesh primitive mode (").concat(mode, ")"));