I am following the OpenGL es rotation examples from google to rotate a simple square (not a cube) on my Android App, for example this code:
gl.glRotatef(xro
I know next-to-nothing about openGL, but I imagine translating to 0, rotating and then translating back should work...
gl.glTranslatef(-x, -y, -z); gl.glRotatef(xrot, 1.0f, 0.0f, 0.0f); //X gl.glRotatef(yrot, 0.0f, 1.0f, 0.0f); //Y gl.glRotatef(zrot, 0.0f, 0.0f, 1.0f); //Z gl.glTranslatef(x, y, z);