ModelView/Projection Matrices

Started by
2 comments, last by NeXius 21 years, 7 months ago
Hi. I''m trying to implement frustum culling in a project I''m currently working on, and this involves extracting the frustum from the modelview and projection matrices, which I don''t understand. They are two 4*4 arrays, but of what? I understand that every object is multiplied by the modelview matrix, which allows for rotation, translation and scaling, but if each of these consist of four modifications (x, y, z, w) shouldn''t there be a fourth? To make it 16? Or am I missing something? I''ve read the red book (OpenGL programming guide) and I still don''t understand it. And I think it''s important that I should understand something as fundamental as these... Any help would be appreciated.
MSN: stupidbackup@hotmail.com (not actual e-mail)ICQ: 26469254(my site)
Advertisement
quote:
They are two 4*4 arrays, but of what?

Of floating point numbers.

quote:
I understand that every object is multiplied by the modelview matrix, which allows for rotation, translation and scaling, but if each of these consist of four modifications (x, y, z, w) shouldn't there be a fourth? To make it 16? Or am I missing something?

rotation, scaling, translation, projection, etc, are all encoded in all 16 values of the matrix. You can represent as few or as much operations as you like in a single matrix. The columns/rows of the matrix aren't directly related to fundamental geometry operations (except translation). The whole 4*4 matrix represents those operations simultaneously.

To be a bit more precise: The upper left 3*3 part can represent rotation, scaling and shearing (or any combination of them). Each (x,y,z) column represents an axis of the matrices coordinate frame. Translation is represented by the last column, right of the 3*3 area. The last row multiplies the homogeneous coordinate, and is used for non-linear projection operations.

You should learn about fundamental matrix theory before going any further. There are lots of good resource sites about that topic, just browse the resource section of gamedev.net.

As a start, have a look at the matrix FAQ.

/ Yann

[edited by - Yann L on September 13, 2002 11:21:26 PM]
i think this page will answer all if not most of your questions, its very good

http://www.gamedev.net/reference/articles/article417.asp

"We are what we repeatedly do. Excellence, then, is not an act, but a habit." - Aristotle
http://fusi.basscut.net"We are what we repeatedly do. Excellence, then, is not an act, but a habit." - Aristotle
Yea that helps a lot.

Thx.
MSN: stupidbackup@hotmail.com (not actual e-mail)ICQ: 26469254(my site)

This topic is closed to new replies.

Advertisement