Re: Why are transforms 4 x 4? [message #37387] |
Mon, 15 December 2003 10:18 |
profxtjb
Messages: 22 Registered: October 2003
|
Junior Member |
|
|
"Karl Schultz" <kschultz_no_spam@rsinc.com> wrote in message news:<vtrldcr3j1gl7d@corp.supernews.com>...
> "Thomas Brueckner" <profxtjb@earthlink.net> wrote in message
> news:52e94d00.0312141710.2a29c8f2@posting.google.com...
>> My geometry knowledge is limited, so I am unsure why IDL uses 4 x 4
> Affine transformations are made up of a linear transformation followed by a
> translation.
> point. So, if you add an additional 4th coordinate to the 3D vector with
> value 1, you can put the translation factors in the 4th row or column of the
Well, shucky darn, Karl, that sounds like a nice, sneaky trick. I can
see how it works.
It must've been invented by a really LAZY programmer! I approve! :)
-Thomas
|
|
|
Re: Why are transforms 4 x 4? [message #37390 is a reply to message #37387] |
Mon, 15 December 2003 07:41  |
Karl Schultz
Messages: 341 Registered: October 1999
|
Senior Member |
|
|
"Thomas Brueckner" <profxtjb@earthlink.net> wrote in message
news:52e94d00.0312141710.2a29c8f2@posting.google.com...
> My geometry knowledge is limited, so I am unsure why IDL uses 4 x 4
> transform matrices to rotate, translate and otherwise mess with
> three-dimensional vectors. Can someone please render an explanation?
> There must be a reason. Is it just that they like to be able to
> handle four-vectors and the ever-popular Lorentz xfm? :)
Affine transformations are made up of a linear transformation followed by a
translation. The linear part can be composed of scaling, shear and rotation
operations and can be applied to a 3D point with a 3x3 matrix. The
translation step can be added on later as a simple addition, but it would be
nice if it can be performed at the same time the matrix is applied to the
point. So, if you add an additional 4th coordinate to the 3D vector with
value 1, you can put the translation factors in the 4th row or column of the
matrix and perform the entire transformation with one matrix operation.
These vectors with the extra value are called homogeneous coordinates, if
you need a term to use to google for more information.
Karl
|
|
|