OpenGL (ES) Android -- Why does this glcolorpointer only color black?
I'm trying to draw a gradient, but first I just want to get the glcolorpointer working. If I use glColor4f(...) it draw colors correctly, but the glcolorpointer just draws black. Help please

<pre><code>
gl11.glPushMatrix();
//gl11.glColor4f(RGBBorder[0], RGBBorder[1], RGBBorder[2], alpha);
gl11.glBindBuffer(GL11.GL_ARRAY_BUFFER, vertexPointerCube);
gl11.glBindBuffer(GL11.GL_ELEMENT_ARRAY_BUFFER, indexPointerCube);
			
gl.glEnableClientState(GL10.GL_COLOR_ARRAY);	
float colors[] = {.7f,.7f,.7f,.5f};
ByteBuffer vbb = ByteBuffer.allocateDirect(colors.length * 4);
vbb.order(ByteOrder.nativeOrder());
FloatBuffer buff = vbb.asFloatBuffer();
buff.put(colors);
buff.position(0);				

gl.glColorPointer(4, GL10.GL_FLOAT, 0, buff);
gl11.glVertexPointer(3, GL10.GL_FLOAT, 0, 0);
gl11.glDrawElements(GL11.GL_TRIANGLES, indicesCube, GL11.GL_UNSIGNED_SHORT, 0);

gl.glDisableClientState(GL10.GL_COLOR_ARRAY);
gl11.glPopMatrix();
</code></pre>
OpenGL (ES) Android -- Why does this glcolorpointer only color black?
===

I'm trying to draw a gradient, but first I just want to get the glcolorpointer working. If I use glColor4f(...) it draw colors correctly, but the glcolorpointer just draws black. Help please

<pre><code>
gl11.glPushMatrix();
//gl11.glColor4f(RGBBorder[0], RGBBorder[1], RGBBorder[2], alpha);
gl11.glBindBuffer(GL11.GL_ARRAY_BUFFER, vertexPointerCube);
gl11.glBindBuffer(GL11.GL_ELEMENT_ARRAY_BUFFER, indexPointerCube);
			
gl.glEnableClientState(GL10.GL_COLOR_ARRAY);	
float colors[] = {.7f,.7f,.7f,.5f};
ByteBuffer vbb = ByteBuffer.allocateDirect(colors.length * 4);
vbb.order(ByteOrder.nativeOrder());
FloatBuffer buff = vbb.asFloatBuffer();
buff.put(colors);
buff.position(0);				

gl.glColorPointer(4, GL10.GL_FLOAT, 0, buff);
gl11.glVertexPointer(3, GL10.GL_FLOAT, 0, 0);
gl11.glDrawElements(GL11.GL_TRIANGLES, indicesCube, GL11.GL_UNSIGNED_SHORT, 0);

gl.glDisableClientState(GL10.GL_COLOR_ARRAY);
gl11.glPopMatrix();
</code></pre>