Sign in to follow this  

Relative roll pitch and yaw

This topic is 3148 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

So I am working with a crappy engine (that I cannot change!) that utilizes roll pitch and yaw as the sole way to specify an entity's orientation in the world. I want to know how to convert relative roll pitch and yaw to world roll pitch and yaw. Here is an example: I have an aircraft at rpy(45,0,45) and I want a camera pointing off this aircraft's nose at a depression of 45 degrees (pitching negative 45 degrees of the nose relative to the aircraft (so the camera should have some roll in it). I thought the obvious answer was that if the relative orientation is to be rpy(0,-45,0). That the desired world orientation would be rpy(Aircraft) + rpy(cam relative) = rpy(cam world). This is obviously not the case so does anyone know how to do the conversion without converting to matrix and back etc?

Share this post


Link to post
Share on other sites
I don't think you can save yourself the trouble of converting back and forth between RP&Y representation and some representation where composition is easy, like matrices or quaternions. Sorry. :(

I would try to use quaternions or matrices everywhere except where you have to interface with the existing engine that you can't modify. I understand this might not be possible if your code is not cleanly separated from the engine's code, but it's something I would aim for.

Share this post


Link to post
Share on other sites

This topic is 3148 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this