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:
authorStefano Sabatini <stefasab@gmail.com>2012-12-15 16:09:26 +0400
committerStefano Sabatini <stefasab@gmail.com>2012-12-15 17:08:42 +0400
commit54b0c04ae3a4073b9764358b925b0b73da3a9e09 (patch)
tree7e53bd475f2e84e40e9dd579e17d18af71ff4069 /libavfilter/vf_overlay.c
parent3d1e2ada2574f89d8475ea9b0249ec861a888edf (diff)
lavfi/overlay: clarify/fix comment, add a few empty lines to ease readability
Diffstat (limited to 'libavfilter/vf_overlay.c')
-rw-r--r--libavfilter/vf_overlay.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavfilter/vf_overlay.c b/libavfilter/vf_overlay.c
index 01a829c828..33db9ef180 100644
--- a/libavfilter/vf_overlay.c
+++ b/libavfilter/vf_overlay.c
@@ -475,7 +475,7 @@ static int try_start_frame(AVFilterContext *ctx, AVFilterBufferRef *mainpic)
AVFilterBufferRef *next_overpic, *outpicref;
int ret;
- /* Discard obsolete overlay frames: if there is a next frame with pts is
+ /* Discard obsolete overlay frames: if there is a next overlay frame with pts
* before the main frame, we can drop the current overlay. */
while (1) {
next_overpic = ff_bufqueue_peek(&over->queue_over, 0);
@@ -486,12 +486,14 @@ static int try_start_frame(AVFilterContext *ctx, AVFilterBufferRef *mainpic)
avfilter_unref_buffer(over->overpicref);
over->overpicref = next_overpic;
}
+
/* If there is no next frame and no EOF and the overlay frame is before
* the main frame, we can not know yet if it will be superseded. */
if (!over->queue_over.available && !over->overlay_eof &&
(!over->overpicref || av_compare_ts(over->overpicref->pts, ctx->inputs[OVERLAY]->time_base,
mainpic->pts , ctx->inputs[MAIN]->time_base) < 0))
return AVERROR(EAGAIN);
+
/* At this point, we know that the current overlay frame extends to the
* time of the main frame. */
outlink->out_buf = outpicref = avfilter_ref_buffer(mainpic, ~0);