inverse matrices?
ok, i asked this on the beginner forums, cause thats what i consider myself, but no one had any helpful ideas for me outside of openGL functions. since i want a real math answer (i''m doing all my rendering in software and writing it myself), maybe its best to turn to you guys. here was my post:
-------------------
so, so far in my tiny little engine i''ve used a simple world matrix to transform any geometry i have all together. i now want to add in a camera matrix, so i can change the viewpoint with that...but i dont quite understand how to do it, and no one seems to cover it that well in the articles.
i understand that you are basically moving the camera so its looking straight down the z axis, so do you need to move the rest of the world the reverse of how you moved the camera?
----------------------
sooo, i get that i need to move the whole world...so does that mean i multiply the object matrix by the inverse of the camera matrix?
thanks for the help,
justo
July 23, 2003 03:41 PM
Usually the camera matrix is just built differently than the object matrix, such that the function that builds the camera matrix sort of creates the matrix that you are calling the inverse. Rather than inverting a matrix, you just build the inverse in the first place, and just think of the camera matrix as moving the world around the camera. So if the camera is moved back 2 units on the z axis, just think of it as moving the world two units forward on the z axis. If the camera is rotated 30 degrees on the x-y plane, think of it as rotating the world -30 degrees.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement