From 56a26fb514bcb6cf32b4c68dc2617453af5931a3 Mon Sep 17 00:00:00 2001 From: WestLangley Date: Tue, 21 Apr 2026 12:11:33 -0400 Subject: [PATCH] Prevent setting non-uniform scale --- src/cameras/Camera.js | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/src/cameras/Camera.js b/src/cameras/Camera.js index 2c2569639c4476..fa3872ede012d6 100644 --- a/src/cameras/Camera.js +++ b/src/cameras/Camera.js @@ -109,6 +109,25 @@ class Camera extends Object3D { } + /** + * Updates the local transformation matrix. + * Non-uniform scale is not supported on cameras. Only uniform scale is supported. + */ + updateMatrix() { + + const sx = this.scale.x; + + if ( this.scale.y !== sx || this.scale.z !== sx ) { + + this.scale.setScalar( sx ); + + } + + super.updateMatrix(); + + } + + updateMatrixWorld( force ) { super.updateMatrixWorld( force );