diff options
author | Mans Rullgard <mans@mansr.com> | 2011-09-28 14:33:21 +0100 |
---|---|---|
committer | Mans Rullgard <mans@mansr.com> | 2011-09-28 15:56:08 +0100 |
commit | fcca826a63c79168f82a48c2620312630a83080a (patch) | |
tree | 97e7acfeebd6769a4e75d7c2cf3d0239f4a1acd6 /libavcodec/dsputil.c | |
parent | 32dfd8ca65e67b18bd22f83cf967f8216818e1fe (diff) | |
download | ffmpeg-fcca826a63c79168f82a48c2620312630a83080a.tar.gz |
dsputil: add vector_fmac_scalar()
Signed-off-by: Mans Rullgard <mans@mansr.com>
Diffstat (limited to 'libavcodec/dsputil.c')
-rw-r--r-- | libavcodec/dsputil.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/libavcodec/dsputil.c b/libavcodec/dsputil.c index 039cf0b213..967406eedf 100644 --- a/libavcodec/dsputil.c +++ b/libavcodec/dsputil.c @@ -2455,6 +2455,14 @@ static void vector_fmul_scalar_c(float *dst, const float *src, float mul, dst[i] = src[i] * mul; } +static void vector_fmac_scalar_c(float *dst, const float *src, float mul, + int len) +{ + int i; + for (i = 0; i < len; i++) + dst[i] += src[i] * mul; +} + static void butterflies_float_c(float *restrict v1, float *restrict v2, int len) { @@ -2994,6 +3002,7 @@ av_cold void dsputil_init(DSPContext* c, AVCodecContext *avctx) c->scalarproduct_float = scalarproduct_float_c; c->butterflies_float = butterflies_float_c; c->vector_fmul_scalar = vector_fmul_scalar_c; + c->vector_fmac_scalar = vector_fmac_scalar_c; c->shrink[0]= av_image_copy_plane; c->shrink[1]= ff_shrink22; |