Skip to content

Commit

Permalink
Merge pull request #1787 from xeokit/XEOK-198-update-SceneModel-rotat…
Browse files Browse the repository at this point in the history
…ion-on-matrix

XEOK-198 Update SceneModel::rotation on SceneModel::matrix change
  • Loading branch information
xeolabs authored Jan 23, 2025
2 parents 7e6cfc9 + 8c4fa50 commit 52f7b1f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/viewer/scene/model/SceneModel.js
Original file line number Diff line number Diff line change
Expand Up @@ -1563,6 +1563,7 @@ export class SceneModel extends Component {
set matrix(value) {
this._matrix.set(value || DEFAULT_MATRIX);
math.decomposeMat4(this._matrix, this._position, this._quaternion, this._scale);
math.quaternionToEuler(this._quaternion, "XYZ", this._rotation);
this._matrixDirty = false;
this._setWorldMatrixDirty();
this._sceneModelDirty();
Expand Down

0 comments on commit 52f7b1f

Please sign in to comment.