Code example for GL10

Methods: glBindTexture, glDrawElements, glFrontFace, glTexCoordPointer, glVertexPointer

0
    public void drawGLView(GL10 gl) {
	if (!visible) {
	    return; 
	} 
 
	gl.glFrontFace(gl.GL_CW);
	gl.glVertexPointer(VERTEX_DIMENSION, GL10.GL_FLOAT, 0, mVertexBuf);
	if (mTextureObj != null) {
	    gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureObj.getTextureId());
	} else { 
	    Log.i(TAG, "Oooops, texture object is null");
	} 
	gl.glTexCoordPointer(TEXTURE_DIMENSION, GL10.GL_FLOAT, 0, mTextureBuf);
	gl.glDrawElements(gl.GL_TRIANGLES, 6, gl.GL_UNSIGNED_BYTE, mIndexBuf);
    } 
 
    //FIXME: should we have to perform any clear to ByteBuffer? I am not sure 
    public void clear() { 
    } 
 
    public void hide() {