0
votes

In my scenario, each SCNNode has 3 values associated with it for the roll, pitch, and yaw.

When I load the SCNNode, I want to apply these 3 rotations sequentially. However, these 3 values assume the axes of the node is always constant and I'm running into issues because the axes of the node change after each rotation.

For example, if the z-axis initially points towards the user (out of the screen) and the y-axis initially points up and I apply a 90 degree roll rotation then the z-axis will still point out of the screen but the y-axis will now point towards the left. Which will make the subsequent yaw rotation incorrect.

Is there some way to rotate the node relative to a constant set of axes?

1
What matters is the end result you want. Best is if you can change the sequence of operations i.e. yaw first and then roll or pitch. Another thing is perform an operation e.g. roll and save the value and then perform another operation from axes you want and save the value. your requirement is to superimpose one value on another I'm right and to me doesn't make sense to return back to starting axes I'd rather say change the operation. - Sourav Sachdeva

1 Answers

0
votes