Details
-
Suggestion
-
Resolution: Unresolved
-
Not Evaluated
-
None
-
None
-
None
Description
A sample is attached. Default setup (call it scenario 1) is a camera being positioned at positive z-axis and facing toward origin, i.e. looking at XY plane. Y-axis up. Change position of PerspectiveCamera and uncomment lookAt() function call as comments describe for the other setup, i.e. camera is positioned at negative y-axis and facing toward origin, i.e. looking at XZ plane. Z-axis up. Call it scenario 2.
Problem is that when you drag inside scene horizontally, camera rotates. But this rotation is always w.r.t y-direction. Under scenario 1, camera sweeps across XY plane, i.e. rotation is w.r.t y-direction (camera's up-vector). Under scenario 2, camera does not sweep but just rotates w.r.t its forward-vector, i.e. still y-direction.
In short, WasdController seems to always assume y-axis pointing upward. But it makes sense in some cases to have other conventions.