diff options
author | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2010-11-24 01:32:49 +0000 |
---|---|---|
committer | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2010-11-24 01:32:49 +0000 |
commit | 3ff9995350b7914c056bbc8440f44bf725dbb1d3 (patch) | |
tree | c2d635b0967b5f823eb4461d6eb9e184151a7269 | |
parent | 16d14d641c7b11638ce10562243caeaf8bfcadb2 (diff) | |
download | ffmpeg-3ff9995350b7914c056bbc8440f44bf725dbb1d3.tar.gz |
In crop filter, reference picref after updating w/h, fix issue #2377
Originally committed as revision 25818 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavfilter/vf_crop.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libavfilter/vf_crop.c b/libavfilter/vf_crop.c index 61019ef80e..88356c6da3 100644 --- a/libavfilter/vf_crop.c +++ b/libavfilter/vf_crop.c @@ -237,12 +237,14 @@ static void start_frame(AVFilterLink *link, AVFilterBufferRef *picref) { AVFilterContext *ctx = link->dst; CropContext *crop = ctx->priv; - AVFilterBufferRef *ref2 = avfilter_ref_buffer(picref, ~0); + AVFilterBufferRef *ref2; int i; picref->video->w = crop->w; picref->video->h = crop->h; + ref2 = avfilter_ref_buffer(picref, ~0); + crop->var_values[VAR_T] = picref->pts == AV_NOPTS_VALUE ? NAN : picref->pts * av_q2d(link->time_base); crop->var_values[VAR_POS] = picref->pos == -1 ? NAN : picref->pos; |