I have a function rotate(). This will check if the user has set axisUp to ‘Y’ or ‘Z’. if the user has set the axis to Y then we dont do anything because in both left and right handed y is up. but if they choose the z axis for up then i need to rotate the scene. I am not sure if the following code is correct.
Some feeedback would be great. Is the code correct? will it be enough to rotate to z? will i need to do anything else after rotating the scene object?
thank you in advance.
my code:
//if axisUp === y then do nothing as already y up in right handed
if (axis.axisUp === "z_positive") {
scene.rotation.x = -90 * Math.PI/180;
} else {
console.warn( 'WARNING: Not supported');
}