diff options
author | Peter Ross <pross@xvid.org> | 2019-01-13 06:55:53 +0300 |
---|---|---|
committer | Peter Ross <pross@xvid.org> | 2019-01-26 15:48:34 +0300 |
commit | 1dfd7aecf26e2f4d3ee1ca893e6365f90c02b899 (patch) | |
tree | c642559c372acd443ecac2ccd7a29dd7b7b7008a /libavcodec/vp3.c | |
parent | 260f1960e7e2e2bff56957a216130623f8109d8f (diff) |
avcodec/vp3dsp: move vp3 init loop filter function to vp3dsp
This is also used by the VP6 decoder.
Signed-off-by: Peter Ross <pross@xvid.org>
Diffstat (limited to 'libavcodec/vp3.c')
-rw-r--r-- | libavcodec/vp3.c | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c index a5d8c2ed0b..b248c90413 100644 --- a/libavcodec/vp3.c +++ b/libavcodec/vp3.c @@ -416,27 +416,7 @@ static void init_dequantizer(Vp3DecodeContext *s, int qpi) */ static void init_loop_filter(Vp3DecodeContext *s) { - int *bounding_values = s->bounding_values_array + 127; - int filter_limit; - int x; - int value; - - filter_limit = s->filter_limit_values[s->qps[0]]; - av_assert0(filter_limit < 128U); - - /* set up the bounding values */ - memset(s->bounding_values_array, 0, 256 * sizeof(int)); - for (x = 0; x < filter_limit; x++) { - bounding_values[-x] = -x; - bounding_values[x] = x; - } - for (x = value = filter_limit; x < 128 && value; x++, value--) { - bounding_values[ x] = value; - bounding_values[-x] = -value; - } - if (value) - bounding_values[128] = value; - bounding_values[129] = bounding_values[130] = filter_limit * 0x02020202; + ff_vp3dsp_set_bounding_values(s->bounding_values_array, s->filter_limit_values[s->qps[0]]); } /* |