mesa: Fix glGetVertexAttribi(GL_VERTEX_ATTRIB_ARRAY_SIZE)
authorAnuj Phogat <anuj.phogat@gmail.com>
Thu, 13 Mar 2014 01:16:21 +0000 (18:16 -0700)
committerAnuj Phogat <anuj.phogat@gmail.com>
Thu, 17 Apr 2014 01:37:06 +0000 (18:37 -0700)
commitfdd8bebc22f167f19d9cafbe2e7c189cb3720bcb
treea375f43515ca36f65ed820519ebc5da19dd02b39
parent80b4a36fed0712fd77b8cc5dbf5b970e0425b299
mesa: Fix glGetVertexAttribi(GL_VERTEX_ATTRIB_ARRAY_SIZE)

mesa currently returns 4 when GL_VERTEX_ATTRIB_ARRAY_SIZE is queried
for a vertex array initially set up with size=GL_BGRA. This patch
makes changes to return size=GL_BGRA as required by the spec.

Fixes Khronos OpenGL CTS test: vertex_array_bgra_basic.test

V2: Use array->Format instead of adding a new variable

Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Cc: <mesa-stable@lists.freedesktop.org>
src/mesa/main/varray.c