aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2013-05-02 23:52:44 +0200
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2013-05-05 10:01:22 +0200
commit3bb1c58e953256ca614c79a511cd0a94e4673e79 (patch)
tree91e113d4a7c633d5cb0b1194a9f4410abaa11d91
parent1ef82cc60d3bc050ea4cbdabe530499da8dce3bf (diff)
downloadffmpeg-3bb1c58e953256ca614c79a511cd0a94e4673e79.tar.gz
Avoid incorrect deprecated pixel format warning.
Should only be printed if a "JPEG" format was used, not for e.g. XYZ. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
-rw-r--r--libswscale/utils.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libswscale/utils.c b/libswscale/utils.c
index 28fd2e1b73..9badd0b085 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -1064,13 +1064,14 @@ av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter,
handle_jpeg(&srcFormat);
handle_jpeg(&dstFormat);
+ if(srcFormat!=c->srcFormat || dstFormat!=c->dstFormat)
+ av_log(c, AV_LOG_WARNING, "deprecated pixel format used, make sure you did set range correctly\n");
handle_0alpha(&srcFormat);
handle_0alpha(&dstFormat);
handle_xyz(&srcFormat);
handle_xyz(&dstFormat);
if(srcFormat!=c->srcFormat || dstFormat!=c->dstFormat){
- av_log(c, AV_LOG_WARNING, "deprecated pixel format used, make sure you did set range correctly\n");
c->srcFormat= srcFormat;
c->dstFormat= dstFormat;
}