[cairo-commit] libglc/src glc_format.c,1.1,1.2 glc_surface.c,1.10,1.11
David Reveman
commit at pdx.freedesktop.org
Mon Aug 15 11:12:59 PDT 2005
Committed by: davidr
Update of /cvs/cairo/libglc/src
In directory pdx:/tmp/cvs-serv20789/src
Modified Files:
glc_format.c glc_surface.c
Log Message:
Surface format fixes
Index: glc_format.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_format.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** glc_format.c 5 Feb 2004 22:22:28 -0000 1.1
--- glc_format.c 6 Feb 2004 00:50:28 -0000 1.2
***************
*** 137,163 ****
{
glc_format_t templ;
! unsigned long mask;
switch (format_name) {
case GLC_STANDARD_ARGB32:
- mask = GLC_FORMAT_ALPHA_MASK | GLC_FORMAT_RED_MASK | GLC_FORMAT_GREEN_MASK |
- GLC_FORMAT_BLUE_MASK;
- templ.alpha = 8;
templ.red = 8;
templ.green = 8;
templ.blue = 8;
break;
case GLC_STANDARD_RGB24:
- mask = GLC_FORMAT_RED_MASK | GLC_FORMAT_GREEN_MASK | GLC_FORMAT_BLUE_MASK;
templ.red = 8;
templ.green = 8;
templ.blue = 8;
break;
case GLC_STANDARD_A8:
! mask = GLC_FORMAT_ALPHA_MASK;
templ.alpha = 8;
break;
case GLC_STANDARD_A1:
! mask = GLC_FORMAT_ALPHA_MASK;
templ.alpha = 1;
break;
--- 137,166 ----
{
glc_format_t templ;
! unsigned long mask = GLC_FORMAT_RED_MASK | GLC_FORMAT_GREEN_MASK |
! GLC_FORMAT_BLUE_MASK | GLC_FORMAT_ALPHA_MASK;
switch (format_name) {
case GLC_STANDARD_ARGB32:
templ.red = 8;
templ.green = 8;
templ.blue = 8;
+ templ.alpha = 8;
break;
case GLC_STANDARD_RGB24:
templ.red = 8;
templ.green = 8;
templ.blue = 8;
+ templ.alpha = 0;
break;
case GLC_STANDARD_A8:
! templ.red = 0;
! templ.green = 0;
! templ.blue = 0;
templ.alpha = 8;
break;
case GLC_STANDARD_A1:
! templ.red = 0;
! templ.green = 0;
! templ.blue = 0;
templ.alpha = 1;
break;
Index: glc_surface.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_surface.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** glc_surface.c 5 Feb 2004 22:22:28 -0000 1.10
--- glc_surface.c 6 Feb 2004 00:50:28 -0000 1.11
***************
*** 70,73 ****
--- 70,76 ----
surface->polyedge = templ->polyedge;
+ /* All channels should always be rendered to intermediate */
+ surface->red = surface->green = surface->blue = surface->alpha = 8;
+
return surface;
}
More information about the cairo-commit
mailing list