|
@@ -66514,6 +66514,30 @@ var BABYLON;
|
|
this._zmesh.color = new BABYLON.Color3(0, 0, 1);
|
|
this._zmesh.color = new BABYLON.Color3(0, 0, 1);
|
|
this.scene = scene;
|
|
this.scene = scene;
|
|
}
|
|
}
|
|
|
|
+ Object.defineProperty(AxesViewer.prototype, "xAxisMesh", {
|
|
|
|
+ /** Gets the mesh used to render x-axis */
|
|
|
|
+ get: function () {
|
|
|
|
+ return this._xmesh;
|
|
|
|
+ },
|
|
|
|
+ enumerable: true,
|
|
|
|
+ configurable: true
|
|
|
|
+ });
|
|
|
|
+ Object.defineProperty(AxesViewer.prototype, "yAxisMesh", {
|
|
|
|
+ /** Gets the mesh used to render x-axis */
|
|
|
|
+ get: function () {
|
|
|
|
+ return this._ymesh;
|
|
|
|
+ },
|
|
|
|
+ enumerable: true,
|
|
|
|
+ configurable: true
|
|
|
|
+ });
|
|
|
|
+ Object.defineProperty(AxesViewer.prototype, "zAxisMesh", {
|
|
|
|
+ /** Gets the mesh used to render x-axis */
|
|
|
|
+ get: function () {
|
|
|
|
+ return this._zmesh;
|
|
|
|
+ },
|
|
|
|
+ enumerable: true,
|
|
|
|
+ configurable: true
|
|
|
|
+ });
|
|
/**
|
|
/**
|
|
* Force the viewer to update
|
|
* Force the viewer to update
|
|
* @param position defines the position of the viewer
|
|
* @param position defines the position of the viewer
|
|
@@ -104614,6 +104638,16 @@ var BABYLON;
|
|
mesh.position.copyFrom(oldPos);
|
|
mesh.position.copyFrom(oldPos);
|
|
// Reverse parenting
|
|
// Reverse parenting
|
|
mesh.removeChild(box);
|
|
mesh.removeChild(box);
|
|
|
|
+ // Adjust scale to avoid undefined behavior when adding child
|
|
|
|
+ if (box.scaling.y === 0) {
|
|
|
|
+ box.scaling.y = BABYLON.Epsilon;
|
|
|
|
+ }
|
|
|
|
+ if (box.scaling.x === 0) {
|
|
|
|
+ box.scaling.x = BABYLON.Epsilon;
|
|
|
|
+ }
|
|
|
|
+ if (box.scaling.z === 0) {
|
|
|
|
+ box.scaling.z = BABYLON.Epsilon;
|
|
|
|
+ }
|
|
box.addChild(mesh);
|
|
box.addChild(mesh);
|
|
box.visibility = 0;
|
|
box.visibility = 0;
|
|
return box;
|
|
return box;
|