Code example for GL10

Methods: glBindTexture, glClear, glDisableClientState, glDrawElements, glEnableClientState, glFinish, glLoadIdentity, glMatrixMode, glRotatef, glTexCoordPointer

0
		} 
 
		public void onDrawFrame(GL10 gl)
		{ 
			// Çå³ýÆÁÄ»»º´æºÍÉî¶È»º´æ 
			gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
			// ÆôÓö¥µã×ù±êÊý¾Ý 
			gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
			// ÆôÓÃÌùͼ×ù±êÊý×éÊý¾Ý 
			gl.glEnableClientState(GL10.GL_TEXTURE_COORD_ARRAY);  //¢Ù
			// ÉèÖõ±Ç°¾ØÕóģʽΪģÐÍÊÓͼ¡£ 
			gl.glMatrixMode(GL10.GL_MODELVIEW);
			gl.glLoadIdentity();
			// °Ñ»æͼÖÐÐÄÒÆÈëÆÁÄ»2¸öµ¥Î» 
			gl.glTranslatef(0f, 0.0f, -2.0f);
			// ÐýתͼÐΠ
			gl.glRotatef(angley, 0, 1, 0);
			gl.glRotatef(anglex, 1, 0, 0);
			// ÉèÖö¥µãµÄλÖÃÊý¾Ý 
			gl.glVertexPointer(3, GL10.GL_FLOAT, 0, cubeVerticesBuffer);
			// ÉèÖÃÌùͼµÄ×ù±êÊý¾Ý 
			gl.glTexCoordPointer(2, GL10.GL_FLOAT, 0, cubeTexturesBuffer);//¢Ú
			// Ö´ÐÐÎÆÀíÌùͼ 
			gl.glBindTexture(GL10.GL_TEXTURE_2D, texture);  //¢Û
			// °´cubeFacetsBufferÖ¸¶¨µÄÃæ»æÖÆÈý½ÇÐΠ
			gl.glDrawElements(GL10.GL_TRIANGLES, cubeFacetsBuffer.remaining(),
				GL10.GL_UNSIGNED_BYTE, cubeFacetsBuffer);
			// »æÖƽáÊø 
			gl.glFinish();
			// ½ûÓö¥µã¡¢ÎÆÀí×ù±êÊý×é 
			gl.glDisableClientState(GL10.GL_VERTEX_ARRAY);
			gl.glDisableClientState(GL10.GL_TEXTURE_COORD_ARRAY);
			// µÝÔö½Ç¶ÈÖµÒÔ±ãÿ´ÎÒÔ²»Í¬½Ç¶È»æÖÆ 
		} 
 
		private void loadTexture(GL10 gl)
		{