View Full Version : Avoid Gimbal Lock, How?
10-24-2000, 09:27 AM
What causes gimbal lock and how do you avoid it?
Avoiding it is best, but if you've already got it, I think that Johnson and Johnson make a cream that will clear it up....
Sorry about that.
Seriously. Gimbal lock is caused when you get your rotational axis into a configuration where you don't really have three independent degrees of freedom anymore. The rotational axis are only independent as long as they stay orthogonal to each other. The typical solution is to use quaternions, which I won't attempt to explain, but you should be able to do a search and come up with some explanations.
10-26-2000, 10:10 AM
to help w/ the search.
the former is a technical description, while the latter is an actual implemenation by jeff lander
i recommend the latter, as jeff lander is the man
10-27-2000, 08:48 AM
I understand Bob's definition of Gimbal Lock, however how can you achive that in OpenGL? Is it possible to get a gimbal lock only with translations, rotation and scales?
Gimbal lock is an issue when messing with Euler angles ONLY, and has nothing to do with matrices or OpenGL. One solution is indeed quaternions, but why use quaternions? They don't give you anything you can't do with matrices. And remember, when using quaternions, you have to convert them to matrices to use them in OpenGL, so why not stick to matrices in the first place, and skip this conversion?
Gimbal lock occurs when you are using rotations in the wrong (or a not-so-smart) way.
gimbal lock is basically applying rotation/translation etc, in the wrong order (remember, order IS important), and you get undesired results.
Powered by vBulletin® Version 4.2.2 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.