Hello Guest

What is this

  • 1 Replies
  • 4475 Views
What is this
« on: February 08, 2007, 07:48:46 »
Looak at this picture and looak at the cubes which are on right.
Why are they so weird?
Btw obviously they are  3D model and I'am using perspective projecton to render it. Here is code:
Code: [Select]
GL11.glLoadIdentity();
GL11.glColor3f(1.0f,1.0f,1.0f);
GL11.glTranslatef(-34f,-24f,-70);
cubeRender();
CubeRender method:
Code: [Select]
GL11.glPushMatrix();
                float positionX = indexX*2.2f; [i]// Index are position of cube in txt file(Iam using tilemap)[/i]
           float positionY = indexY*2.2f;
GL11.glTranslatef(positionX,positionY,0f);
GL11.glRotatef(90,1,0,0);
GL11.glScalef(0.01f,0.01f,0.01f);
     
cubeTexture.bind();
           cubeModel.render();
GL11.glPopMatrix();

Re: What is this
« Reply #1 on: February 08, 2007, 13:59:27 »
They look like they are overlapping eachother. Did you enable the depth buffer via glEnable(GL_DEPTH_TEST)?