Hey guys. Just last Friday I started really working on P3D for a simple FPS RPG that I want to make. The first thing I'm starting with is a free-looking, free-moving camera controlled by the mouse and WASD keys(like you see in many games). I'm using the Robot Java class to keep the mouse in the center and record its movements, but I'm having issues with grasping the concepts of the camera class. I get what eye, center, and up do, but I cannot figure out how to manipulate center and eye well. I have studied the camera manipulations of Chrisr/polar's first person program extensively:
http://www.openprocessing.org/sketch/25255
and another first person dungeon generator by RyanD:
http://www.openprocessing.org/sketch/23227
http://www.openprocessing.org/sketch/25255
and another first person dungeon generator by RyanD:
http://www.openprocessing.org/sketch/23227
I can kind of paste their code and patch it to work with mine, but I don't want to do that because it feels like I haven't earned the end result. I have also looked all around on Wikipedia, tried to study matrices, and looked around on this forum a lot but cannot find a thorough, easy to understand explanation. The Peasy Cam library isn't really meant for first person camera rotation, and I want to avoid libraries if I can for the sake of learning. I've been trying to figure this out for days and I don't know if I'm just impatient, or inexpirenced. So my question is: are there any solid references to documentation, or books, regarding the trigonometry and processes behind 3D rotation? Any replies are appreciated.
1