diff options
author | Martin Vignali <martin.vignali@gmail.com> | 2017-12-18 11:30:31 +0100 |
---|---|---|
committer | Martin Vignali <martin.vignali@gmail.com> | 2017-12-19 20:59:59 +0100 |
commit | 8fb1d63d919286971b8e6afad372730d6d6f25c8 (patch) | |
tree | 2b89c9ce70a0fd659e6fd0542baae6673c71925d /libavfilter/x86 | |
parent | 1a5865b6dcc97754a1d7eedc130fb58237d2a715 (diff) | |
download | ffmpeg-8fb1d63d919286971b8e6afad372730d6d6f25c8.tar.gz |
avfilter/vf_tinterlace : add AVX2 func for lowpass_line 8 and 16
Diffstat (limited to 'libavfilter/x86')
-rw-r--r-- | libavfilter/x86/vf_tinterlace_init.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/libavfilter/x86/vf_tinterlace_init.c b/libavfilter/x86/vf_tinterlace_init.c index 209812964d..2c9b1de581 100644 --- a/libavfilter/x86/vf_tinterlace_init.c +++ b/libavfilter/x86/vf_tinterlace_init.c @@ -33,6 +33,9 @@ void ff_lowpass_line_sse2(uint8_t *dstp, ptrdiff_t linesize, void ff_lowpass_line_avx (uint8_t *dstp, ptrdiff_t linesize, const uint8_t *srcp, ptrdiff_t mref, ptrdiff_t pref, int clip_max); +void ff_lowpass_line_avx2 (uint8_t *dstp, ptrdiff_t linesize, + const uint8_t *srcp, ptrdiff_t mref, + ptrdiff_t pref, int clip_max); void ff_lowpass_line_16_sse2(uint8_t *dstp, ptrdiff_t linesize, const uint8_t *srcp, ptrdiff_t mref, @@ -40,6 +43,9 @@ void ff_lowpass_line_16_sse2(uint8_t *dstp, ptrdiff_t linesize, void ff_lowpass_line_16_avx (uint8_t *dstp, ptrdiff_t linesize, const uint8_t *srcp, ptrdiff_t mref, ptrdiff_t pref, int clip_max); +void ff_lowpass_line_16_avx2 (uint8_t *dstp, ptrdiff_t linesize, + const uint8_t *srcp, ptrdiff_t mref, + ptrdiff_t pref, int clip_max); void ff_lowpass_line_complex_sse2(uint8_t *dstp, ptrdiff_t linesize, const uint8_t *srcp, ptrdiff_t mref, @@ -63,6 +69,11 @@ av_cold void ff_tinterlace_init_x86(TInterlaceContext *s) if (EXTERNAL_AVX(cpu_flags)) if (!(s->flags & TINTERLACE_FLAG_CVLPF)) s->lowpass_line = ff_lowpass_line_16_avx; + if (EXTERNAL_AVX2_FAST(cpu_flags)) { + if (!(s->flags & TINTERLACE_FLAG_CVLPF)) { + s->lowpass_line = ff_lowpass_line_16_avx2; + } + } } else { if (EXTERNAL_SSE2(cpu_flags)) { if (!(s->flags & TINTERLACE_FLAG_CVLPF)) @@ -73,5 +84,10 @@ av_cold void ff_tinterlace_init_x86(TInterlaceContext *s) if (EXTERNAL_AVX(cpu_flags)) if (!(s->flags & TINTERLACE_FLAG_CVLPF)) s->lowpass_line = ff_lowpass_line_avx; + if (EXTERNAL_AVX2_FAST(cpu_flags)) { + if (!(s->flags & TINTERLACE_FLAG_CVLPF)) { + s->lowpass_line = ff_lowpass_line_avx2; + } + } } } |