mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-28 04:31:06 +00:00
textoverlay: Do shading as first operation
This commit is contained in:
parent
eccd28d7b0
commit
21ad7547a0
1 changed files with 3 additions and 4 deletions
|
@ -1239,6 +1239,9 @@ gst_text_overlay_render_pangocairo (GstTextOverlay * overlay,
|
||||||
|
|
||||||
cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
|
cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
|
||||||
|
|
||||||
|
if (overlay->want_shading)
|
||||||
|
cairo_paint_with_alpha (cr, overlay->shading_value);
|
||||||
|
|
||||||
/* apply transformations */
|
/* apply transformations */
|
||||||
cairo_set_matrix (cr, &cairo_matrix);
|
cairo_set_matrix (cr, &cairo_matrix);
|
||||||
|
|
||||||
|
@ -1259,10 +1262,6 @@ gst_text_overlay_render_pangocairo (GstTextOverlay * overlay,
|
||||||
cairo_stroke_preserve (cr);
|
cairo_stroke_preserve (cr);
|
||||||
cairo_restore (cr);
|
cairo_restore (cr);
|
||||||
|
|
||||||
if (overlay->want_shading) {
|
|
||||||
cairo_paint_with_alpha (cr, overlay->shading_value);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* draw text */
|
/* draw text */
|
||||||
cairo_save (cr);
|
cairo_save (cr);
|
||||||
cairo_set_source_rgb (cr, 1.0, 1.0, 1.0);
|
cairo_set_source_rgb (cr, 1.0, 1.0, 1.0);
|
||||||
|
|
Loading…
Reference in a new issue