diff options
author | Wim Taymans <wim.taymans@gmail.com> | 2007-01-23 17:27:39 +0000 |
---|---|---|
committer | Wim Taymans <wim.taymans@gmail.com> | 2007-01-23 17:27:39 +0000 |
commit | 168db53bf471394ca9381b903d3e32d79664d8e5 (patch) | |
tree | 2206543d07359badefc9dc7ad8be972c6167088c /gst/smpte/gstsmpte.c | |
parent | a10f2478bbd1d04db5ceec6b0dc9eba6a6597bf8 (diff) |
gst/smpte/: constify some static structs.
Original commit message from CVS:
* gst/smpte/barboxwipes.c: (gst_wipe_boxes_draw),
(gst_wipe_triangles_clock_draw), (gst_wipe_triangles_draw):
* gst/smpte/gstmask.c: (_gst_mask_register):
* gst/smpte/gstmask.h:
* gst/smpte/gstsmpte.c: (gst_smpte_update_mask):
* gst/smpte/paint.c: (gst_smpte_paint_hbox), (draw_bresenham_line),
(gst_smpte_paint_triangle_clock):
constify some static structs.
Don't update the mask if nothing changed to the params.
Make sure we never draw outside of the picture. Fixes #398325.
Diffstat (limited to 'gst/smpte/gstsmpte.c')
-rw-r--r-- | gst/smpte/gstsmpte.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gst/smpte/gstsmpte.c b/gst/smpte/gstsmpte.c index 471495b4..95fd31e2 100644 --- a/gst/smpte/gstsmpte.c +++ b/gst/smpte/gstsmpte.c @@ -280,6 +280,13 @@ gst_smpte_update_mask (GstSMPTE * smpte, gint type, gint depth, gint width, { GstMask *newmask; + if (smpte->mask) { + if (smpte->type == type && + smpte->depth == depth && + smpte->width == width && smpte->height == height) + return TRUE; + } + newmask = gst_mask_factory_new (type, depth, width, height); if (newmask) { if (smpte->mask) { |