mesa/es: Improve support for GL_OES_compressed_paletted_texture.
authorChia-I Wu <olvaffe@gmail.com>
Tue, 24 Nov 2009 04:21:03 +0000 (12:21 +0800)
committerBrian Paul <brianp@vmware.com>
Mon, 4 Jan 2010 21:15:16 +0000 (14:15 -0700)
commita316b700effd615fcc895d0a2e015356854c6f44
tree6eb9e69876ef9a8744009c8253289caf104dd2ad
parentc4b9e1aa1a2f1fda9e5764e3f7dd1a268216df09
mesa/es: Improve support for GL_OES_compressed_paletted_texture.

Add error checking and fix handling of level (it should be negative).
Besides, always use the palette entry format/type when calling
_mesa_TexImage2D.  It respects the base internal formats of the cpal
formats, and is simpler and faster, except for cases where the unpack
alignment needs to be changed.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
src/mesa/es/main/es_cpaltex.c