[FFmpeg-cvslog] swscale/utils: Use normal bilinear scaler if fast cannot be used due to tiny dimensions
Michael Niedermayer
git at videolan.org
Fri Jan 15 17:39:18 CET 2016
ffmpeg | branch: release/2.6 | Michael Niedermayer <michael at niedermayer.cc> | Mon Jan 4 23:22:25 2016 +0100| [dbe194002a798b0866eeabd21c9f788d96b42d78] | committer: Michael Niedermayer
swscale/utils: Use normal bilinear scaler if fast cannot be used due to tiny dimensions
Fixes Ticket4960
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
(cherry picked from commit 1edf129cbc897447a289ca8b045853df5df1bab3)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=dbe194002a798b0866eeabd21c9f788d96b42d78
---
libswscale/utils.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/libswscale/utils.c b/libswscale/utils.c
index cb78c59..5380f3f 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -1052,6 +1052,12 @@ av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter,
srcW, srcH, dstW, dstH);
return AVERROR(EINVAL);
}
+ if (flags & SWS_FAST_BILINEAR) {
+ if (srcW < 8 || dstW < 8) {
+ flags ^= SWS_FAST_BILINEAR | SWS_BILINEAR;
+ c->flags = flags;
+ }
+ }
if (!dstFilter)
dstFilter = &dummyFilter;
More information about the ffmpeg-cvslog
mailing list