CGTalk What's a matrix?
 06-23-2006, 07:38 AM #1 bandini Frequenter portfolio Adam Swaab Designer/Animator Los Angeles, USA   Join Date: Jan 2006 Posts: 223 What's a matrix? I know this is a basic question, but I really hope someone will take a few moments to explain it to me, since I am new to Xpresso. I'm sure there are many others who would benefit a brief explanation as well. What is a matrix and why are they used in xpresso? I know I'm supposed to use them for certain functions, but I really have no idea why I am doing that. For example, connecting an emitter to a null requires the null's global matrix to be wired to the emitter's alignment. I would expect that I would wire the null's global rotation to the emitter, but this obviously is not possible. I can see on the tags that alignment is a matrix value, but rotation is a vector value. I'm pretty sure I remember vectors from my high school physics days. Unless I'm mistaken, a vector is a collection of an objects' direction and magnitude in that direction. So, I can easily understand why something like velocity would be a vector quantity. But, how does a vector relate to a matrix? share quote
 06-23-2006, 07:47 AM #2 Per-Anders helper bunny   portfolio Per-Anders Edwards Developer The Third Party USA   Join Date: Sep 2002 Posts: 12,708 A Matrix is an array of numebrs in a grid (think like excel, a grid of x * y cells). The matrices in cinema are used to store the transformation data about an object and to apply transformations to other objects and matrices quickly (matrix math is a very convenient method of doing transforms without so much messy trig). In cinema the transform matrix is position, orientation and scale, they are made up of four vectors (each vector being a 3 component vector x,y,z), and when you use a matrix to vectors node you can see this. The first vector (V0 or something "off") is the position of the matrix, the next three vectors are the directions of the axis of the object (the direction that x, y and z face in 3d space) and the objects scale (the length of these vectors. Because the vectors are seperate for each axis this allows you to skew an object using it's matrix. If you want to learn more then you would do best to do a google search on matrices and 3d matrix math which might help you understand a little more about what they are and their uses (for instance to convert a position from local to global space and back again, or to rotate an object by an even ammount constantly). __________________ The Third Party | Homepage | My Reel "You need to know what you're doing before you start, and to start because you need what you're doing." share quote
 06-23-2006, 08:14 AM #3 Srek Some guy   portfolio Björn Dirk Marl Technical Design Maxon Computer GmbH Friedrichsdorf, Germany   Join Date: Sep 2002 Posts: 11,249 The COFFEE SDK that is available form plugin cafe includes a nice description on what matrices are and how they are used in CINEMA. Some tidbits of information regarding Matrices and Xpresso can be found here http://www.bonkers.de/xpa/coordinates.html Cheers Björn __________________ - www.bonkers.de - The views expressed on this post are my personal opinions and do not represent the views of my employer. share quote
 06-23-2006, 08:14 AM #4 CGTalk Moderation Lord of the posts   Join Date: Sep 2003 Posts: 1,066,481 Thread automatically closed This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum. __________________ CGTalk Policy/Legalities Note that as CGTalk Members, you agree to the terms and conditions of using this website. share quote