5 ms·
AFAICT the proponents of GA claim it explains lots of things that don't make a whole lot of sense without it. One example is why you multiply normals by the wo
by greggman3 6y ago
AFAICT the proponents of GA claim it explains lots of things that don't make a whole lot of sense without it.
One example is why you multiply normals by the world_inverse_tranpose. Apparently the reason is because normals are actually bivectors, not directional vectors as they are usually explained.
another is that at least in code, they apparently solve lots of issues that other methods don't
See: https://marctenbosch.com/quaternions/ https://marctenbosch.com/quaternions/
https://marctenbosch.com/quaternions/code.htm https://marctenbosch.com/quaternions/code.htm
and: https://bivector.net/ https://bivector.net/
and https://www.youtube.com/watch?v=tX4H_ctggYo https://www.youtube.com/watch?v=tX4H_ctggYo
- MiroF 6y ago> One example is why you multiply normals by the world_inverse_tranpose I know linear algebra but I have no idea what the heck this means. Is this a gaming thing?
- sixo 6y agoComputer graphics. When transforming a coordinate system by a linear transformation represented by a matrix, normal vectors to surfaces transform differently than regular vectors. GA/exterior algebra explains this: the useful thing we call normals is represented by the same data (a 3d vector) but actually has to have a a different "type" to make sense. In higher dimensions they are not interchangeable with vectors.
- MiroF 6y agoAh gotcha, why don't bivectors transform normally e: I'm restating the question in a form I understand, not asking it.
- ogogmad 6y agoIf T:V->V is a linear transformation and "^" is the exterior product then T(u^v)=T(u)^T(v). For example, let T be a reflection about the plane spanned by e1 and e2. Then T(e1^e2)=e1^e2, but T(e1 x e2) = -e1 x e2, where "x" denotes the cross product.
- MiroF 6y agoI should have been clear, I was restating their question, not asking it again.
- deleted 6y ago[deleted]
- aap_ 6y agoIn LA you calculate the normal of a plane by taking the cross product of two vectors lying in that plane. If you transform all three with the same matrix the normal will in the general case no longer be the cross product of the transformed vectors, you have to transform it with the inverse transpose matrix instead.
- MiroF 6y agoThanks, I think I was more confused by what `world_inverse_tranpose` is.
- francasso 6y agoI understand that for gamedev it's more natural to think in terms of the exterior product of two vectors rather than the normal, because you have to deal with transformations a lot. But the normal is a vector, it's a definition that has been there for hundreds of years. There is no need to rename stuff, just use the thing that better fits your use case. In fact there are other things that are easier to understand in terms of normals, like the shape operator of a surface.
- Jaxan 6y ago“Hundreds of years” is an exaggeration. The term vector originated in 1837 (according to Dutch Wikipedia). So I’m not so sure that “normal vector” is a term which is, say, a hundred years old.
- Jasper_ 6y agoIt makes perfect sense without GA -- a precalculated normal vector is effectively a stored cross product (this is what the "bivector" terminology is attempting to explain, but is unclear). While the cross product is invariant under rotation and translation, scaling the inputs of the cross product is not the same as scaling the output -- you need to apply the inverse scaling to the output (you can derive this from basic identities). The "inverse transpose" is a symbolic manipulation to derive a transformation matrix that inverts the scale, but not the rotation, though it's actually a bit overzealous, you can actually just use the cofactor matrix. https://github.com/graphitemaster/normals_revisited https://github.com/graphitemaster/normals_revisited
- fizixer 6y agoYeah right, it explains a lot of things, assuming you don't ask how to make sense of this alien thing called a 'bivector' in the first place. That's when they start telling you, that you're supposed to be an elite mathematician, well versed in the higher forms of sophistry, and if that were the case you wouldn't need to understand bivector and wedge product and what not at an intuitive level. I'm sold.