LWJGL Forum

Programming => OpenGL => Topic started by: palody on May 17, 2007, 19:20:18

Title: drawing objects
Post by: palody on May 17, 2007, 19:20:18
i drew a table using 5 cubes that i just scaled.. i also used devil to bind textures to it.

however, when i move the camera up, i could see the table legs through the table. does anybody know how to undo that? :)
Title: Re: drawing objects
Post by: bobjob on May 18, 2007, 00:28:35
do this when setting up opengl

        GL11.glEnable(GL11.GL_DEPTH_TEST);                       // Enables Depth Testing
        GL11.glDepthFunc(GL11.GL_LEQUAL);