Euler vs Quaternion - What's the difference?

preview_player
Показать описание
3D software describes orientation and interprets rotation using math, and the most common way to do this is with Euler and Quaternion Values. Euler is the common X, Y, and Z, 3 dimensional, ordered, series of values that suffers from gimbal lock. Quaternion represents the W, X, Y, and Z 4 dimensional, spherically interpolating (SLERP), series of values that do not suffer from gimbal lock; Though, may be harder to visualize.

Resources:

Media Used:
- Ferris Bueller Clip: TM & © Paramount (1986)
Рекомендации по теме
Комментарии
Автор

Quarternions allow you to specify the axis of rotation. This is very advantageous for some situations. Like rotating a virtual camera to a point at a specific vector, cross product of camera direction and specific vector is axis of rotation, dot product will give you the rotation angle. Euler rotations are good for specifying an objects orientation. I learned about Euler rotations in college and did not learn about quarternions until I was deep into my career. I think quarternions are useful enough that they should be taught in schools, they fit nicely with dot and cross product.

endlesswick
Автор

This was the video that finally makes me "get it" for gimbal locks. Maybe its just the fact that I have been watching several videos of gimbal lock but walking away with a half-ass understanding of it. I think the way you put it - the gimbals have to make a wierd detour to get to an angle which requires rotation in that "lost" degree of freedom and the fact that when the gimbal lock occurs any rotation applied to that axis goes to the "stable platform" hence losing the priced orientation it contained is what made me add it up.

jibran
Автор

Euler angles are _compositions_ of 3 basis rotations. Quaternions are _mixtures_ (technically "linear combinations") of the same 3 basis rotations, but specifically 180° rotations around each axis, plus a fourth "0°" rotation term. Also important to mention: Quaternions are _rotations_ *not* *_orientations._* For every _orientation, _ there are two different _rotations_ that bring you to that orientation. These are often called "clockwise" and "counterclockwise, " and in quaternions, the two different rotations have two different quaternions, which are also the negatives of each other. Interpolating quaternions only takes the shortest path with _one_ of these rotations, but not the other, which instead does take the long way around. Interpolating a 360° rotation is still hard because every possible axis will eventually get you to the right place.
"It represents something called 'the scalar value'" Which is a really fancy way of saying "doing absolutely nothing." It is the 0° rotation I mentioned earlier.

Regarding the world axis, that's exactly what quaternions do best. The world axis is a line which, when interpreted as a quaternion directly, is a 180° rotation. Mix in some "do nothing" in different quantities and you can get any rotation from -360° to 360° around said axis. (Be careful, vanilla quaternions can only rotate around the origin of the space you're using... or at least, _vanilla_ quaternions can.)

angeldude
Автор

Having known quite a bit on that subject, math and Blender wise, I saw "Class Outside" under the most human thumbnail I've looked at in days; Surprised this was a Blender/Graphics tutory, but the overall atmosphere of the video was entraping and calming.
You sir, have a great mind; stay focused!

xyhilwastaken
Автор

There _is_ a way to visualize quaternions much like Euler angles. With Euler angles, the three values form a vector which points along the axis of rotation. The length of this vector is the amount of rotation.

It's much the same with quaternions: the XYZ components form a vector which points along the axis of rotation, but now it's the _ratio_ of the length of this vector to the W component which determines the amount of rotation.

APaleDot
Автор

Quaternions not caring about order is just wrong. pq =/= qp in that skew field. Just take (0, 1, 0, 0) and (0, 0, 1, 0) with the respective i, j and k values. It is not the same. You also did not touch upon the double cover properties of Quaternions. Thats why you have Angle/2 in the formulars concerning them.

friedrichfreigeist
Автор

This deserves so much more attention thank you so much!

matchu
Автор

That was a really good explanation, thanks!

ryanmckenna
Автор

damn, had to do a project in graphics programming and did not hear about anything said here, i even went (probably too quickly) trough books and did my project and only got here because of being curious about gimbal lock. This is making me afraid of all the things I miss trying to keep up with everybody instead of properly learning. Great video anyway

mozartmemelord
Автор

I wouldn't be surprised if there was a dozen theses on Euler angles with Quaternions.

thomasolson
Автор

Thanks I think both gimbal lock and quaternions finally clicked for me

johnsolod
Автор

Great video and explanation of gimbal lock. Though I think you could have spent more time on at least giving a brief explanation of what the four quaternion numbers represent / relate to (i.e. rotation axis and angle), even if you avoid the math or attempts at 4D visualization.

tedsheridan
Автор

Tooo good! Thanks for the informational video!

TheStrokeForge
Автор

I wrote code for a 6DOF platform. Not only does the order make a difference but the direction of rotation must be defined. You can use the left hand or right hand rule. So there are many ways of moving the 6DOF platform. Rarely would two people get the order and directions the same. This was a problem because a flight simulator would down load x, y, z, yaw, pitch and roll but often the 6DOF would move as the customer thought it should. I finally decided to use the NASA's Glen Research centers standard and told people to use that. I need to figure out quaternions but the 6DOF platform doesn't make big angle changes.

pnachtwey
Автор

Thank u i need to write a thesis dealing with the basics of 3d and this is helpful (no stem baxkground..)😅

ypanso
Автор

Orientation and direction are not the same thing. The fact that 3D orientations are representable with 3 Euler angles is just a coincidence. In 2D you only need one angle, and in 4D, you need six.
In general, you need N coordinates to represent an N dimensional point, and (N^2+N)/2 angles (or bivectors) to represent an arbitrary rotation.

KilgoreTroutAsf
Автор

Euler: paltry three dimensions...
Quaternions: FOUR DIMENSIONS!!!!

ramuk
Автор

2:36 perfect describe of me after heard that, I has to track back and still can't stand that sentence😂
.
Anyway great video is solve lot of question in my head.

Zucth
Автор

for almost all rotations, euler rotation will not return the smallest possible angle.
for small angles, quaternions suffer a too big precision-loss.
matrix of axis angle rotation is identical to quaternions, but axis-angle-forms needs more memory and multiplications, usually not worth the gained precision, unless you do less than 2 rotations in a chain-sequence and precision really matters.

the second life wiki has a function, that reasonably efficiently first calculates the angle, and then only does euler-rotation if the angle is small enough so that precision of the result matters more than rotating around a single axis.

ollllj
Автор

doge had me cracked up, thanks for that lol

ericcidade