Lets say, i have ground-plane equation = $ax + by + cz + d$ . Then, i rotate camera and i know new yaw ( $\theta$ ), pitch ( $\alpha$) and roll( $\gamma$) angle of camera. How can i calculate new ground equation using previous equation and these angles?

I created rotation matrix $R_x$, $R_y$, and $R_z$ . Then multipy plane equation with these rotation matrices as follows:

Plane equation : [[a,b,c]] -> 1x3 matrix

Final rotation matrix : $Rz$ * $Ry$ * $Rx$ -> 3x3 matrix

New plane : Plane equation * Final rotation matrix -> 1x3 matrix.

However, results is very noisy, and i think, i made some mistake on using matrices multiplication? Is my way correct or not? If not, what is the correct way to get new plane equation?

  • $\begingroup$ How do you multiply an equation by a matrix? Shouldn't you multiply vectors (that correspond to coordinate points in 3-dimensional space) by matrices? Also, notice that rotation matrices are normally multiplied from left (not right, as you wrote in "New plane"). $\endgroup$ – Matti P. May 23 at 6:55
  • $\begingroup$ thanks for feedback. If i don't multiply matrices with equation, how can i get new equation? $\endgroup$ – Bedrick Kiq May 23 at 7:00
  • $\begingroup$ If I were you, I would consider a point on the plane, with coordinates $(x_0, y_0, z_0)$. Then consider the three rotations in order. Start with the simple rotation (around the $x$-axis, for example). What is the new coordinate of the point? This is how I would approach the problem. $\endgroup$ – Matti P. May 23 at 7:03
  • $\begingroup$ You want to say that take 3 points on old plane, then rotate this points and calculate new equation from these 3 points, am i right? $\endgroup$ – Bedrick Kiq May 23 at 7:04
  • $\begingroup$ stackoverflow.com/questions/14607640/… $\endgroup$ – Matti P. May 23 at 7:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.