Code example for GL10

Methods: glTexImage2D

0
			break; 
		case GL10.GL_LUMINANCE:
			frame = new byte[textureSize*textureSize];
			break; 
		} 
		gl.glTexImage2D(GL10.GL_TEXTURE_2D, 0, mode, textureSize,
				textureSize, 0, mode, GL10.GL_UNSIGNED_BYTE ,
				ByteBuffer.wrap(frame));
		isTextureInitialized = true;		
	} 
	 
	/** 
	 * sets the mode(either GL10.GL_RGB or GL10.GL_LUMINANCE) 
	 * @param pMode 
	 */ 
	public void setMode(int pMode) {
		switch(pMode) {		
		case GL10.GL_RGB:
		case GL10.GL_LUMINANCE:
			this.mode = pMode;
			break;