Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


interpolation mechanism problem

This topic is 5800 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

Hi, the problem I have is slightly difficult to explain, but I hope someone knows what I''m talking about here. I''m writing a 3d interpolator - a thing which that takes a bunch of waypoints and then moves an object (the camera) along those waypoints. So far everything is crystal clear, but I''m a little stumped with the roll element (banking sideways). To implement roll, I have to change the up-vector''s x, y and z values (in OpenGL). I''m calculating these as follows: a waypoint consists of the position, orientation and the roll factor (a simple angle), and time. Depending on the axes the interpolation point is moving on, I have to change either the x and y or the z and y elements of the up-vector (I''m not 100% clear as to why yet...), otherwise I get very jerky roll on one of the axis. Furthermore, waypoints can have any valid coordinates, so the vector along which I''m moving can be in any direction. I hope that''s enough info to actually present the question in a clear form now: how do I calculate the x and z factors for the up-vector to get rid of the jery movement? Or, is there an alternative, easier way? If necessary, I can post some code. Any help would be appreciated, Crispy

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!