glamor: Add 8bpp to get/setspans.

This commit is contained in:
Eric Anholt 2009-08-21 10:05:32 -07:00 committed by Zhigang Gong
parent 93ad091442
commit f66e5c4145
2 changed files with 6 additions and 0 deletions

View File

@ -218,6 +218,9 @@ glamor_set_spans(DrawablePtr drawable, GCPtr gc, char *src,
int i;
switch (drawable->depth) {
case 8:
format = GL_ALPHA;
type = GL_UNSIGNED_BYTE;
case 24:
case 32:
format = GL_BGRA;

View File

@ -63,6 +63,9 @@ glamor_get_spans(DrawablePtr drawable,
type = GL_UNSIGNED_BYTE;
readpixels_dst = temp_dst;
break;
case 8:
format = GL_ALPHA;
type = GL_UNSIGNED_BYTE;
case 24:
format = GL_RGB;
type = GL_UNSIGNED_BYTE;