mutter/clutter/cogl
Neil Roberts 502446ed8d cogl-blend-string: Don't split combined blend statements into two
When a single statement is used to specify the factors for both the
RGB and alpha parts it previously split up the statement into
two. This works but it ends up unnecessarily using glBlendFuncSeparate
when glBlendFunc would suffice.

For example, the blend statement

 RGBA = ADD(SRC_COLOR*(SRC_COLOR), DST_COLOR*(1-SRC_COLOR))

would get split into the two statements

 RGBA = ADD(SRC_COLOR*(SRC_COLOR[RGB]), DST_COLOR*(1-SRC_COLOR[RGB]))
 A    = ADD(SRC_COLOR*(SRC_COLOR[A]), DST_COLOR*(1-SRC_COLOR[A]))

That translates to:

 glBlendFuncSeparate (GL_SRC_COLOR, GL_ONE_MINUS_SRC_COLOR,
                      GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);

This patch makes it so that arg_to_gl_blend_factor can handle the
combined RGBA mask instead. That way the single statement gets
translated to the equivalent call:

 glBlendFunc (GL_SRC_COLOR, GL_ONE_MINUS_SRC_COLOR);
2010-05-17 16:31:28 +01:00
..
cogl cogl-blend-string: Don't split combined blend statements into two 2010-05-17 16:31:28 +01:00
doc cogl: improves header and coding style consistency 2010-02-12 14:05:00 +00:00
pango analysis: CoglPangoRenderer 2010-02-12 14:57:55 +00:00
Makefile.am [cogl] move clutter/pango to clutter/cogl/pango 2009-10-16 18:58:51 +01:00