Please imagine a scene that shows a cube. Both the camera and the cube can be randomly positioned and rotated. How can you tell which side of the cube is facing up/down or left/right?
Or in other words: What's the math to find a cube's orientation in relation of the camera?
Your advise is very much appreciated. Thank you.
Edit: Here's a screenshot:
The camera is "locked" onto the cube. I.e. one of it's sides is facing directly into the camera. Both cube and camera are rotated in 90 degree steps, so that each face of the cube is always in parallel to the camera's axis's. How can you tell which face (or color in the screenshot above) is pointing left/right/up/down?
Thank you!