summaryrefslogtreecommitdiff
path: root/libavcodec/imgresample.c
diff options
context:
space:
mode:
authorLuca Abeni <lucabe72@email.it>2006-07-25 15:23:44 +0000
committerLuca Abeni <lucabe72@email.it>2006-07-25 15:23:44 +0000
commit2793096fe3e19b806f79c1abd8533b5733dcd505 (patch)
tree5d72ccfccdcab9fd4782a0356210a82b9142185b /libavcodec/imgresample.c
parent07bf2af864790e8d0930f66361ec91d95ff12800 (diff)
Fix a corner case in sws emulation
Originally committed as revision 5827 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/imgresample.c')
-rw-r--r--libavcodec/imgresample.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/imgresample.c b/libavcodec/imgresample.c
index 26de52d857..8ffcd7960e 100644
--- a/libavcodec/imgresample.c
+++ b/libavcodec/imgresample.c
@@ -756,6 +756,9 @@ int sws_scale(struct SwsContext *ctx, uint8_t* src[], int srcStride[],
res = -1;
goto the_end;
}
+ } else if (resampled_picture != &dst_pict) {
+ img_copy(&dst_pict, resampled_picture, current_pix_fmt,
+ ctx->resampling_ctx->owidth, ctx->resampling_ctx->oheight);
}
the_end: