[cairo-commit] libglc/src glc.c,1.13,1.14 glc_agl_format.c,1.3,1.4 glc_agl_pbuffer.c,1.2,1.3 glc_agl_surface.c,1.3,1.4 glc_glx_extension.c,1.5,1.6 glc_glx_format.c,1.10,1.11 glc_rect.c,1.7,1.8 glc_surface.c,1.11,1.12 glc_trap.c,1.8,1.9 glc_tri.c,1.8,1.9

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-serv8251/src

Modified Files:
	glc.c glc_agl_format.c glc_agl_pbuffer.c glc_agl_surface.c 
	glc_glx_extension.c glc_glx_format.c glc_rect.c glc_surface.c 
	glc_trap.c glc_tri.c 
Log Message:
Removed component masking and added offscreen mulisample support for geforce fx cards

Index: glc.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** glc.c	5 Feb 2004 22:22:28 -0000	1.13
--- glc.c	6 Feb 2004 14:03:39 -0000	1.14
***************
*** 174,182 ****
               width, height);
    
-   glColorMask (dst->red? 1: 0,
-                dst->green? 1: 0,
-                dst->blue? 1: 0,
-                dst->alpha? 1: 0);
- 
    glc_set_operator (op);
    
--- 174,177 ----
***************
*** 332,337 ****
    }
  
-   glColorMask (1, 1, 1, 1);
- 
    glc_texture_unbind (texture);
  
--- 327,330 ----

Index: glc_agl_format.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_agl_format.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** glc_agl_format.c	5 Feb 2004 22:22:28 -0000	1.3
--- glc_agl_format.c	6 Feb 2004 14:03:39 -0000	1.4
***************
*** 284,287 ****
--- 284,292 ----
      format.id = 0;
      _glc_add_format (thread_info, &format);
+     format.alpha = 0;
+     _glc_add_format (thread_info, &format);
+     format.alpha  = 8;
+     format.red = format.green = format.blue = 0;
+     _glc_add_format (thread_info, &format);
    }
    

Index: glc_agl_pbuffer.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_agl_pbuffer.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** glc_agl_pbuffer.c	5 Feb 2004 22:22:28 -0000	1.2
--- glc_agl_pbuffer.c	6 Feb 2004 14:03:39 -0000	1.3
***************
*** 33,38 ****
  
  AGLPbuffer
! glc_agl_pbuffer_create (glc_texture_t *texture,
!                         glc_format_t *format)
  {
    AGLPbuffer pbuffer;
--- 33,37 ----
  
  AGLPbuffer
! glc_agl_pbuffer_create (glc_texture_t *texture)
  {
    AGLPbuffer pbuffer;

Index: glc_agl_surface.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_agl_surface.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** glc_agl_surface.c	5 Feb 2004 22:22:28 -0000	1.3
--- glc_agl_surface.c	6 Feb 2004 14:03:39 -0000	1.4
***************
*** 176,181 ****
    
    if (thread_info->feature_mask & GLC_FEATURE_OFFSCREEN_MASK)
!     surface->pbuffer =
!       glc_agl_pbuffer_create (surface->texture, surface->format);
  
    if (!surface->pbuffer) {
--- 176,180 ----
    
    if (thread_info->feature_mask & GLC_FEATURE_OFFSCREEN_MASK)
!     surface->pbuffer = glc_agl_pbuffer_create (surface->texture);
  
    if (!surface->pbuffer) {

Index: glc_glx_extension.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_glx_extension.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** glc_glx_extension.c	5 Feb 2004 22:22:28 -0000	1.5
--- glc_glx_extension.c	6 Feb 2004 14:03:39 -0000	1.6
***************
*** 113,122 ****
        GLC_GLX_FEATURE_CLIENT_MULTISAMPLE_MASK) {
      screen_info->feature_mask |= GLC_FEATURE_MULTISAMPLE_MASK;
!     
!     /*
!       if (strcmp ("Card supporting pbuffer multisampling",
!       glGetString (GL_RENDERER)))
        screen_info->feature_mask |= GLC_FEATURE_OFFSCREEN_MULTISAMPLE_MASK;
-     */ 
    }
  
--- 113,120 ----
        GLC_GLX_FEATURE_CLIENT_MULTISAMPLE_MASK) {
      screen_info->feature_mask |= GLC_FEATURE_MULTISAMPLE_MASK;
! 
!     /* All geforce fx cards seems to support multisample with pbuffers */
!     if (strncmp ("GeForce FX", glGetString (GL_RENDERER), 10))
        screen_info->feature_mask |= GLC_FEATURE_OFFSCREEN_MULTISAMPLE_MASK;
    }
  

Index: glc_glx_format.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_glx_format.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** glc_glx_format.c	5 Feb 2004 23:28:01 -0000	1.10
--- glc_glx_format.c	6 Feb 2004 14:03:39 -0000	1.11
***************
*** 175,179 ****
           sizeof (glc_format_t), _glc_glx_format_compare);
  
!   /* Adding fake offscreen format as no real offscreen formats exists.
       Surfaces created with this format can only be used with draw/read
       pixel functions and as source in composite functions. */
--- 175,179 ----
           sizeof (glc_format_t), _glc_glx_format_compare);
  
!   /* Adding fake offscreen formats as no real offscreen formats exists.
       Surfaces created with this format can only be used with draw/read
       pixel functions and as source in composite functions. */
***************
*** 183,186 ****
--- 183,191 ----
    format.id = 0;
    _glc_add_format (screen_info, &format);
+   format.alpha = 0;
+   _glc_add_format (screen_info, &format);
+   format.alpha  = 8;
+   format.red = format.green = format.blue = 0;
+   _glc_add_format (screen_info, &format);
    
    if (visuals)
***************
*** 271,275 ****
           sizeof (glc_format_t), _glc_glx_format_compare);
  
!   /* Adding fake offscreen format if no real offscreen formats exists.
       Surfaces created with this format can only be used with draw/read
       pixel functions and as source in composite functions. */
--- 276,280 ----
           sizeof (glc_format_t), _glc_glx_format_compare);
  
!   /* Adding fake offscreen formats if no real offscreen formats exists.
       Surfaces created with this format can only be used with draw/read
       pixel functions and as source in composite functions. */
***************
*** 282,285 ****
--- 287,295 ----
      format.id = 0;
      _glc_add_format (screen_info, &format);
+     format.alpha = 0;
+     _glc_add_format (screen_info, &format);
+     format.alpha  = 8;
+     format.red = format.green = format.blue = 0;
+     _glc_add_format (screen_info, &format);
    }
    

Index: glc_rect.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_rect.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** glc_rect.c	5 Feb 2004 22:22:28 -0000	1.7
--- glc_rect.c	6 Feb 2004 14:03:39 -0000	1.8
***************
*** 85,93 ****
    glColor4us (color->red, color->green, color->blue, color->alpha);
  
-   glColorMask (dst->red? 1: 0,
-                dst->green? 1: 0,
-                dst->blue? 1: 0,
-                dst->alpha? 1: 0);
-   
    glc_set_operator (op);
                     
--- 85,88 ----
***************
*** 101,106 ****
    glEnd ();
  
-   glColorMask (1, 1, 1, 1);
- 
    glc_surface_dirty (dst, &bounds);
    glc_surface_pop_current (dst);
--- 96,99 ----
***************
*** 131,139 ****
    glColor4us (color->red, color->green, color->blue, color->alpha);
  
-   glColorMask (dst->red? 1: 0,
-                dst->green? 1: 0,
-                dst->blue? 1: 0,
-                dst->alpha? 1: 0);
-     
    glc_set_operator (op);
      
--- 124,127 ----
***************
*** 149,154 ****
    glEnd ();
  
-   glColorMask (1, 1, 1, 1);
-   
    glc_surface_dirty (dst, &bounds);  
    glc_surface_pop_current (dst);
--- 137,140 ----

Index: glc_surface.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_surface.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** glc_surface.c	6 Feb 2004 00:50:28 -0000	1.11
--- glc_surface.c	6 Feb 2004 14:03:39 -0000	1.12
***************
*** 282,285 ****
--- 282,286 ----
    glDisable (GL_POLYGON_SMOOTH);
    glShadeModel (GL_FLAT);
+   glColorMask (1, 1, 1, 1);
  }
  
***************
*** 488,492 ****
    glc_texture_bind (texture);
    glc_texture_ensure_filter (texture, surface->filter);
!   glc_texture_ensure_repeat (texture, (surface->repeat && texture->repeatable));
    glc_texture_unbind (texture);
  
--- 489,494 ----
    glc_texture_bind (texture);
    glc_texture_ensure_filter (texture, surface->filter);
!   glc_texture_ensure_repeat (texture,
!                              (surface->repeat && texture->repeatable));
    glc_texture_unbind (texture);
  

Index: glc_trap.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_trap.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** glc_trap.c	5 Feb 2004 22:22:28 -0000	1.8
--- glc_trap.c	6 Feb 2004 14:03:39 -0000	1.9
***************
*** 199,203 ****
    glClear (GL_COLOR_BUFFER_BIT);
    glColor4f (1.0, 1.0, 1.0, 1.0);
-   glColorMask (1, 1, 1, 1);
  
    glc_set_operator (GLC_OPERATOR_SRC);
--- 199,202 ----
***************
*** 319,327 ****
    }
  
-   glColorMask (dst->red? 1: 0,
-                dst->green? 1: 0,
-                dst->blue? 1: 0,
-                dst->alpha? 1: 0);
-   
    glc_set_operator (op);
  
--- 318,321 ----
***************
*** 387,391 ****
    
    glShadeModel (GL_FLAT);
-   glColorMask (1, 1, 1, 1);
  
    glc_surface_dirty (dst, &bounds);
--- 381,384 ----

Index: glc_tri.c
===================================================================
RCS file: /cvs/cairo/libglc/src/glc_tri.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** glc_tri.c	5 Feb 2004 22:22:28 -0000	1.8
--- glc_tri.c	6 Feb 2004 14:03:39 -0000	1.9
***************
*** 127,131 ****
    glClear (GL_COLOR_BUFFER_BIT);
    glColor4f (1.0, 1.0, 1.0, 1.0);
-   glColorMask (1, 1, 1, 1);
  
    glc_set_operator (GLC_OPERATOR_SRC);
--- 127,130 ----
***************
*** 244,248 ****
    glClear (GL_COLOR_BUFFER_BIT);
    glColor4f (1.0, 1.0, 1.0, 1.0);
-   glColorMask (1, 1, 1, 1);
  
    glc_set_operator (GLC_OPERATOR_SRC);
--- 243,246 ----
***************
*** 356,360 ****
    glClear (GL_COLOR_BUFFER_BIT);
    glColor4f (1.0, 1.0, 1.0, 1.0);
-   glColorMask (1, 1, 1, 1);
  
    glc_set_operator (GLC_OPERATOR_SRC);
--- 354,357 ----
***************
*** 477,485 ****
    }
  
-   glColorMask (dst->red? 1: 0,
-                dst->green? 1: 0,
-                dst->blue? 1: 0,
-                dst->alpha? 1: 0);
- 
    glc_set_operator (op);
  
--- 474,477 ----
***************
*** 526,530 ****
  
    glShadeModel (GL_FLAT);
-   glColorMask (1, 1, 1, 1);
  
    glc_surface_dirty (dst, &bounds);
--- 518,521 ----





More information about the cairo-commit mailing list