summaryrefslogtreecommitdiff
path: root/libavfilter
diff options
context:
space:
mode:
authorNicolas George <george@nsup.org>2015-10-25 11:27:15 +0100
committerNicolas George <george@nsup.org>2015-10-25 20:58:21 +0100
commit559603dae1f67b851cea52cbfc0525bf8fa6b8c2 (patch)
tree47a0a6076015c9680e21c17bac21a441f141442e /libavfilter
parentbbd6bc6bd0889627a3bd70e14005664e06d466bc (diff)
downloadffmpeg-559603dae1f67b851cea52cbfc0525bf8fa6b8c2.tar.gz
lavfi/drawutils: add const to blending mask.
Diffstat (limited to 'libavfilter')
-rw-r--r--libavfilter/drawutils.c9
-rw-r--r--libavfilter/drawutils.h2
2 files changed, 6 insertions, 5 deletions
diff --git a/libavfilter/drawutils.c b/libavfilter/drawutils.c
index 91fffd5e06..1724a82221 100644
--- a/libavfilter/drawutils.c
+++ b/libavfilter/drawutils.c
@@ -408,7 +408,7 @@ void ff_blend_rectangle(FFDrawContext *draw, FFDrawColor *color,
}
static void blend_pixel(uint8_t *dst, unsigned src, unsigned alpha,
- uint8_t *mask, int mask_linesize, int l2depth,
+ const uint8_t *mask, int mask_linesize, int l2depth,
unsigned w, unsigned h, unsigned shift, unsigned xm0)
{
unsigned xm, x, y, t = 0;
@@ -432,7 +432,7 @@ static void blend_pixel(uint8_t *dst, unsigned src, unsigned alpha,
static void blend_line_hv(uint8_t *dst, int dst_delta,
unsigned src, unsigned alpha,
- uint8_t *mask, int mask_linesize, int l2depth, int w,
+ const uint8_t *mask, int mask_linesize, int l2depth, int w,
unsigned hsub, unsigned vsub,
int xm, int left, int right, int hband)
{
@@ -457,12 +457,13 @@ static void blend_line_hv(uint8_t *dst, int dst_delta,
void ff_blend_mask(FFDrawContext *draw, FFDrawColor *color,
uint8_t *dst[], int dst_linesize[], int dst_w, int dst_h,
- uint8_t *mask, int mask_linesize, int mask_w, int mask_h,
+ const uint8_t *mask, int mask_linesize, int mask_w, int mask_h,
int l2depth, unsigned endianness, int x0, int y0)
{
unsigned alpha, nb_planes, nb_comp, plane, comp;
int xm0, ym0, w_sub, h_sub, x_sub, y_sub, left, right, top, bottom, y;
- uint8_t *p0, *p, *m;
+ uint8_t *p0, *p;
+ const uint8_t *m;
clip_interval(dst_w, &x0, &mask_w, &xm0);
clip_interval(dst_h, &y0, &mask_h, &ym0);
diff --git a/libavfilter/drawutils.h b/libavfilter/drawutils.h
index 5ffffe77c1..e247dd6440 100644
--- a/libavfilter/drawutils.h
+++ b/libavfilter/drawutils.h
@@ -130,7 +130,7 @@ void ff_blend_rectangle(FFDrawContext *draw, FFDrawColor *color,
*/
void ff_blend_mask(FFDrawContext *draw, FFDrawColor *color,
uint8_t *dst[], int dst_linesize[], int dst_w, int dst_h,
- uint8_t *mask, int mask_linesize, int mask_w, int mask_h,
+ const uint8_t *mask, int mask_linesize, int mask_w, int mask_h,
int l2depth, unsigned endianness, int x0, int y0);
/**