basetextoverlay: remove unneeded cairo transparence setting

he code here:

http://cgit.freedesktop.org/gstreamer/gst-plugins-base/tree/ext/pango/gstbasetextoverlay.c#n1554

should make transparent the box that contains the text, I think this code is
not correct, it should be:

if (overlay->want_shading) {
    double alpha = overlay->shading_value / 255.0;
    cairo_paint_with_alpha (cr, alpha);
  }

however I think this code could be removed, we already do a shaded background,
why shade the box behind the text with cairo too? only one shading is needed so
we must shade with cairo or with methods like these:

http://cgit.freedesktop.org/gstreamer/gst-plugins-base/tree/ext/pango/gstbasetextoverlay.c#n1642

not both

https://bugzilla.gnome.org/show_bug.cgi?id=736028
This commit is contained in:
Nicola Murino 2014-09-04 12:13:45 +02:00 committed by Sebastian Dröge
parent ad16f15ee4
commit 501a295fa1

View file

@ -1559,9 +1559,6 @@ gst_base_text_overlay_render_pangocairo (GstBaseTextOverlay * overlay,
cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
if (overlay->want_shading)
cairo_paint_with_alpha (cr, -overlay->shading_value);
/* apply transformations */
cairo_set_matrix (cr, &cairo_matrix);