|
@@ -147,7 +147,7 @@ PERFORMANCE OF THIS SOFTWARE.
|
|
|
var extendStatics = function(d, b) {
|
|
|
extendStatics = Object.setPrototypeOf ||
|
|
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
|
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
|
|
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
|
return extendStatics(d, b);
|
|
|
};
|
|
|
|
|
@@ -241,8 +241,8 @@ var __createBinding = Object.create ? (function(o, m, k, k2) {
|
|
|
o[k2] = m[k];
|
|
|
});
|
|
|
|
|
|
-function __exportStar(m, exports) {
|
|
|
- for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p);
|
|
|
+function __exportStar(m, o) {
|
|
|
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);
|
|
|
}
|
|
|
|
|
|
function __values(o) {
|
|
@@ -332,7 +332,7 @@ var __setModuleDefault = Object.create ? (function(o, v) {
|
|
|
function __importStar(mod) {
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
var result = {};
|
|
|
- if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
__setModuleDefault(result, mod);
|
|
|
return result;
|
|
|
}
|
|
@@ -48678,11 +48678,13 @@ var Gizmo = /** @class */ (function () {
|
|
|
else {
|
|
|
this._attachedNode._worldMatrix.decompose(transform.scaling, this._tempQuaternion, transform.position);
|
|
|
}
|
|
|
- if (transform.rotationQuaternion) {
|
|
|
- transform.rotationQuaternion.copyFrom(this._tempQuaternion);
|
|
|
- }
|
|
|
- else {
|
|
|
- transform.rotation = this._tempQuaternion.toEulerAngles();
|
|
|
+ if (!transform.billboardMode) {
|
|
|
+ if (transform.rotationQuaternion) {
|
|
|
+ transform.rotationQuaternion.copyFrom(this._tempQuaternion);
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ transform.rotation = this._tempQuaternion.toEulerAngles();
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
else if (this._attachedNode.getClassName() === "Bone") {
|
|
@@ -50172,6 +50174,7 @@ var RotationGizmo = /** @class */ (function (_super) {
|
|
|
set: function (mesh) {
|
|
|
this._meshAttached = mesh;
|
|
|
this._nodeAttached = mesh;
|
|
|
+ this._checkBillboardTransform();
|
|
|
[this.xGizmo, this.yGizmo, this.zGizmo].forEach(function (gizmo) {
|
|
|
if (gizmo.isEnabled) {
|
|
|
gizmo.attachedMesh = mesh;
|
|
@@ -50191,6 +50194,7 @@ var RotationGizmo = /** @class */ (function (_super) {
|
|
|
set: function (node) {
|
|
|
this._meshAttached = null;
|
|
|
this._nodeAttached = node;
|
|
|
+ this._checkBillboardTransform();
|
|
|
[this.xGizmo, this.yGizmo, this.zGizmo].forEach(function (gizmo) {
|
|
|
if (gizmo.isEnabled) {
|
|
|
gizmo.attachedNode = node;
|
|
@@ -50203,6 +50207,11 @@ var RotationGizmo = /** @class */ (function (_super) {
|
|
|
enumerable: false,
|
|
|
configurable: true
|
|
|
});
|
|
|
+ RotationGizmo.prototype._checkBillboardTransform = function () {
|
|
|
+ if (this._nodeAttached && this._nodeAttached.billboardMode) {
|
|
|
+ console.log("Rotation Gizmo will not work with transforms in billboard mode.");
|
|
|
+ }
|
|
|
+ };
|
|
|
Object.defineProperty(RotationGizmo.prototype, "isHovered", {
|
|
|
/**
|
|
|
* True when the mouse pointer is hovering a gizmo mesh
|