gl: Get rid of _cairo_gl_composite_set_mask_texture()

Now that the glyph cache contains real surfaces, there's no longer a
need to have a special function for it.
This commit is contained in:
Benjamin Otte 2010-05-18 13:00:34 +02:00
parent 208d9f2a7e
commit 0222cc7d76
3 changed files with 7 additions and 28 deletions

View file

@ -530,22 +530,6 @@ _cairo_gl_composite_set_mask_spans (cairo_gl_context_t *ctx,
setup->has_component_alpha = FALSE;
}
void
_cairo_gl_composite_set_mask_texture (cairo_gl_context_t *ctx,
cairo_gl_composite_t *setup,
GLuint tex,
cairo_bool_t has_component_alpha)
{
_cairo_gl_operand_destroy (&setup->mask);
setup->has_component_alpha = has_component_alpha;
setup->mask.type = CAIRO_GL_OPERAND_TEXTURE;
setup->mask.texture.tex = tex;
setup->mask.texture.surface = NULL;
cairo_matrix_init_identity (&setup->mask.texture.attributes.matrix);
}
void
_cairo_gl_composite_set_clip_region (cairo_gl_context_t *ctx,
cairo_gl_composite_t *setup,

View file

@ -333,13 +333,14 @@ _render_glyphs (cairo_gl_surface_t *dst,
last_format = scaled_glyph->surface->format;
_cairo_gl_composite_set_mask_texture (ctx,
&setup,
((cairo_gl_surface_t *) cache->pattern.surface)->tex,
last_format == CAIRO_FORMAT_ARGB32);
status = _cairo_gl_composite_set_mask (ctx,
&setup,
&cache->pattern.base,
0, 0, 0, 0, 0, 0);
if (unlikely (status))
goto FINISH;
if (last_format == CAIRO_FORMAT_ARGB32)
*has_component_alpha = TRUE;
*has_component_alpha |= cache->pattern.base.has_component_alpha;
status = _cairo_gl_composite_begin (ctx, &setup);
}

View file

@ -308,12 +308,6 @@ cairo_private void
_cairo_gl_composite_set_mask_spans (cairo_gl_context_t *ctx,
cairo_gl_composite_t *setup);
cairo_private void
_cairo_gl_composite_set_mask_texture (cairo_gl_context_t *ctx,
cairo_gl_composite_t *setup,
GLuint tex,
cairo_bool_t has_component_alpha);
cairo_private cairo_status_t
_cairo_gl_composite_begin (cairo_gl_context_t *ctx,
cairo_gl_composite_t *setup);