three-stdlib 2.32.0 → 2.32.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,5 +1,6 @@
1
1
  import { Loader, LoaderUtils, FileLoader, Vector3, Quaternion, Matrix4, MeshBasicMaterial, Scene, TextureLoader, Euler, MathUtils, AnimationClip, VectorKeyframeTrack, QuaternionKeyframeTrack, MeshLambertMaterial, MeshPhongMaterial, Vector2, DoubleSide, FrontSide, PerspectiveCamera, OrthographicCamera, Color, AmbientLight, SpotLight, PointLight, DirectionalLight, BufferGeometry, Float32BufferAttribute, Group, Bone, LineBasicMaterial, SkinnedMesh, Mesh, Line, LineSegments, RepeatWrapping, ClampToEdgeWrapping, Skeleton } from "three";
2
2
  import { TGALoader } from "./TGALoader.js";
3
+ import { UV1 } from "../_polyfill/uv1.js";
3
4
  class ColladaLoader extends Loader {
4
5
  constructor(manager) {
5
6
  super(manager);
@@ -1363,7 +1364,7 @@ class ColladaLoader extends Loader {
1363
1364
  const position2 = { array: [], stride: 0 };
1364
1365
  const normal = { array: [], stride: 0 };
1365
1366
  const uv = { array: [], stride: 0 };
1366
- const uv2 = { array: [], stride: 0 };
1367
+ const uv1 = { array: [], stride: 0 };
1367
1368
  const color = { array: [], stride: 0 };
1368
1369
  const skinIndex = { array: [], stride: 4 };
1369
1370
  const skinWeight = { array: [], stride: 4 };
@@ -1441,7 +1442,7 @@ class ColladaLoader extends Loader {
1441
1442
  uv.stride = sources[id].stride;
1442
1443
  break;
1443
1444
  case "TEXCOORD1":
1444
- buildGeometryData(primitive, sources[id], input.offset, uv2.array);
1445
+ buildGeometryData(primitive, sources[id], input.offset, uv1.array);
1445
1446
  uv.stride = sources[id].stride;
1446
1447
  break;
1447
1448
  default:
@@ -1462,8 +1463,8 @@ class ColladaLoader extends Loader {
1462
1463
  uv.stride = sources[input.id].stride;
1463
1464
  break;
1464
1465
  case "TEXCOORD1":
1465
- buildGeometryData(primitive, sources[input.id], input.offset, uv2.array);
1466
- uv2.stride = sources[input.id].stride;
1466
+ buildGeometryData(primitive, sources[input.id], input.offset, uv1.array);
1467
+ uv1.stride = sources[input.id].stride;
1467
1468
  break;
1468
1469
  }
1469
1470
  }
@@ -1478,8 +1479,8 @@ class ColladaLoader extends Loader {
1478
1479
  geometry.setAttribute("color", new Float32BufferAttribute(color.array, color.stride));
1479
1480
  if (uv.array.length > 0)
1480
1481
  geometry.setAttribute("uv", new Float32BufferAttribute(uv.array, uv.stride));
1481
- if (uv2.array.length > 0)
1482
- geometry.setAttribute("uv2", new Float32BufferAttribute(uv2.array, uv2.stride));
1482
+ if (uv1.array.length > 0)
1483
+ geometry.setAttribute(UV1, new Float32BufferAttribute(uv1.array, uv1.stride));
1483
1484
  if (skinIndex.array.length > 0) {
1484
1485
  geometry.setAttribute("skinIndex", new Float32BufferAttribute(skinIndex.array, skinIndex.stride));
1485
1486
  }