20 lines
583 B
JavaScript
20 lines
583 B
JavaScript
![]() |
"use strict";
|
||
|
Object.defineProperty(exports, "__esModule", { value: true });
|
||
|
const Matrix2_1 = require("./Matrix2");
|
||
|
const THREE = require("three");
|
||
|
function RotateUVs(geo) {
|
||
|
let roMat = new Matrix2_1.Matrix2();
|
||
|
roMat.set(0, -1, 1, 0);
|
||
|
let addV = new THREE.Vector2(1, 0);
|
||
|
for (let uvs of geo.faceVertexUvs) {
|
||
|
for (let uv of uvs) {
|
||
|
for (let v of uv) {
|
||
|
roMat.applyVector(v);
|
||
|
v.add(addV);
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
geo.uvsNeedUpdate = true;
|
||
|
}
|
||
|
exports.RotateUVs = RotateUVs;
|
||
|
//# sourceMappingURL=RotateUV.js.map
|