OpenGL ES rotate the world
How i can rotate the all world by 15 degrees on 开发者_如何学编程the Z axis?
glRotatef(15, 0, 0, 1);
http://www.khronos.org/opengles/documentation/opengles1_0/html/glRotate.html
The solution is:
gl.glMatrixMode(GL10.GL_PROJECTION);
gl.glLoadIdentity();
GLU.gluPerspective(gl, 45.0f, (float) width / (float) height, 0.1f, 100.0f);
GLU.gluLookAt(gl, 0, -5, 0, 0.0f, 0.0f, -15.0f, 0.0f, 1.0f, 0.0f);
精彩评论