diff options
author | Aleksey Vasenev <margtu-fivt@ya.ru> | 2014-11-13 01:39:45 +0300 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-11-13 22:35:15 +0100 |
commit | 8349001638fb2b6c54eafdb90418eb9f2d042077 (patch) | |
tree | 9878d07eefded138dbd21972d5334f2d3b3e2834 | |
parent | df8248f66e362c3015d95ac86d1917dde8dc0a0c (diff) | |
download | ffmpeg-8349001638fb2b6c54eafdb90418eb9f2d042077.tar.gz |
avfilter/vf_tinterlace: fix frame rate
Signed-off-by: Aleksey Vasenev <margtu-fivt@ya.ru>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavfilter/vf_tinterlace.c | 2 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-kerndeint | 20 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-tinterlace_merge | 28 |
3 files changed, 26 insertions, 24 deletions
diff --git a/libavfilter/vf_tinterlace.c b/libavfilter/vf_tinterlace.c index 6bc55b5960..7397bebafd 100644 --- a/libavfilter/vf_tinterlace.c +++ b/libavfilter/vf_tinterlace.c @@ -149,6 +149,8 @@ static int config_out_props(AVFilterLink *outlink) outlink->time_base.num = inlink->time_base.num; outlink->time_base.den = inlink->time_base.den * 2; outlink->frame_rate = av_mul_q(inlink->frame_rate, (AVRational){2,1}); + } else if (tinterlace->mode != MODE_PAD) { + outlink->frame_rate = av_mul_q(inlink->frame_rate, (AVRational){1,2}); } av_log(ctx, AV_LOG_VERBOSE, "mode:%d filter:%s h:%d -> h:%d\n", diff --git a/tests/ref/fate/filter-pixfmts-kerndeint b/tests/ref/fate/filter-pixfmts-kerndeint index 6fefda3832..376d8f4081 100644 --- a/tests/ref/fate/filter-pixfmts-kerndeint +++ b/tests/ref/fate/filter-pixfmts-kerndeint @@ -1,10 +1,10 @@ -0bgr e179e118e6dc0a5b6f9e80955fedc776 -0rgb 95fa448040fa3f86d23418b857123259 -abgr 1a24de822f91557546c8e9c8236f7814 -argb adc0120d95192942f5c39de1b602b883 -bgr0 33ee8c3df7c05bff51c742fe6beacad1 -bgra 6e8b840001a5f50c0b277fe3d7cafd26 -rgb0 8d63004296dc6db7868aa7163780f5b5 -rgba ebf7aaa65634dcee4289e80d4fb31e50 -yuv420p 8edaf2d52dc7fba910784076b2dbdcfc -yuyv422 07198d8a9f7989bd75d1da94800c69d5 +0bgr bdff73f3a0b22f29d2fcae461db92efc +0rgb 6d19d706cc405fc7e0d0e941d34ddc5f +abgr 6eb205786c9eb1419334f7725fc799ee +argb 180b920be1f3b03234e327725a00abed +bgr0 661a99840c4cb6d9bb755ab6fec9548b +bgra c5e9622e15ad7ad276f50d8ebb7e994f +rgb0 58d8a93cf254c8a7affef326a2e88367 +rgba 403329386173553df13d94c7230ec734 +yuv420p c1d71b5c7f1f65d7e27070355fc7c74a +yuyv422 ce701473de3deefd9a8a1184e505ffe5 diff --git a/tests/ref/fate/filter-pixfmts-tinterlace_merge b/tests/ref/fate/filter-pixfmts-tinterlace_merge index 526b77f40b..4f1f75e154 100644 --- a/tests/ref/fate/filter-pixfmts-tinterlace_merge +++ b/tests/ref/fate/filter-pixfmts-tinterlace_merge @@ -1,14 +1,14 @@ -gray 330feb7cbe8ede999b93ac802012058a -yuv410p c5dac1d3f5a7a51310795daf1ac57992 -yuv411p 2fe635d25d77d7d107ddd9ad2ae1a863 -yuv420p aea7ee5c4dc21d17c833c5390d9f22ba -yuv422p 5820321e6a49c72677003163a8fd5ebb -yuv440p 1011e599e6f2c8095d46ed28d74ae74d -yuv444p 4602f8acdea686aee4c281d7305831c9 -yuva420p b7258aaa6de3492642008fff075ecb2c -yuva422p b4691c4c3b1bfc9adb5b1d855aadec81 -yuva444p a83646df12b4674d732e17b93b538be2 -yuvj420p 40b23e9f290aa5fc536337bda1e55118 -yuvj422p 036400f7fdafc1964582811b11677330 -yuvj440p 572bd7e96fe7fc6df118bb213e168f80 -yuvj444p 867f5851eb22ad7d3032333219e8133b +gray 5bfdd4a77ce5bef266f2e0ce9f4f971b +yuv410p 2327b4c01e6a16acf18229f3faa4f29f +yuv411p 486a0448fd543b54eefd599eee613ba4 +yuv420p 36c640c73bdbc62d047a923d2abbc559 +yuv422p 2434b401a62eb3799e441d8b1c2e18f2 +yuv440p 6951eb4455ea2979f65ece3b1132eb5c +yuv444p d36e193a9bfc1b21ca16b563d3802d9c +yuva420p 54139ae3544a9c2695ade817342bd1d6 +yuva422p 0ec7ea9e289365c357ba0a0926d684f3 +yuva444p bb9cfc136d4a5a2e8c25b5885ff51a38 +yuvj420p ead0073708f677df3ea594d326954415 +yuvj422p b76079bba6818dac80d71795403585d8 +yuvj440p e3d34f02bf946af9d7973701097b3391 +yuvj444p c1757fcbb3f04d78cf082afe6537a540 |