I was very proud to get lesson 10 working in LWJGL and its now working as presented. I'm now trying to learn how to place objects in the world and rotate them individually and independently from the world.
Based on what I've read with openGL. That is what the distinction between MODELVIEW and PROJECTION matrix modes is for.
Lesson 10 seems to rotate the entire world as one big model with MODELVIEW. So what i'm confused about is if I was to attempt to add a quad to the middle of the level and then rotate it with glRotatef that would rotate not only the quad but all of the walls, floors and everything else that is part of the scene. Not just the quad like I would like to try and do.
Since the heading and looking angle appear to be taken care of only by the below two lines:
Also, after looking at lesson 10, it looks like you rotate everything to move around...that isn't going to be very good once you have a lot of things... I learned to use gluLookAt(), which sets up a camera pretty much..
The vertices of your all your quads are defined in a zig-zag order, like a Z, and not clockwise or counter-clockwise around the quad. The order of your vertices are very important. It should be enough to swap the order of the last two vertices of all quads to at least have the vertices define a proper quad. There may be other problems, such as inconsistent winding order and backface culling, that will break your cube.
Thanks man...didn't know the vertices had to be in order...
All polygons are broken down into triangles before rasterization on the graphics card. So when you switch to wireframe rendering (which I am guessing is how you saw the triangles) you will see the edges of the finally rendered triangles. I believe there is a method to stop these from being rendered by flagging edges on your model for display.
No it isn't in wireframe mode...it's in fill mode...