Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2016-01-05 01:22:25 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2016-01-15 14:30:40 +0300
commit14c63dc9b0d8ca0f99e4b73b8b9329012917da46 (patch)
treeec91f1ca1cae4b2f556771bd832327b9f6100101 /libswscale/utils.c
parent709abc74f5ef5459e93faec227ec9c4a0b5ff954 (diff)
swscale/utils: Use normal bilinear scaler if fast cannot be used due to tiny dimensions
Fixes Ticket4960 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 1edf129cbc897447a289ca8b045853df5df1bab3) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libswscale/utils.c')
-rw-r--r--libswscale/utils.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libswscale/utils.c b/libswscale/utils.c
index 5610701136..a108d99b8f 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -1193,6 +1193,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;