vf_split: fix various nits

This commit is contained in:
Stefano Sabatini 2011-05-22 01:18:59 +02:00
parent eb97d4d611
commit 7d5297b343
1 changed files with 17 additions and 15 deletions

View File

@ -1,6 +1,5 @@
/* /*
* Video splitter * Copyright (c) 2007 Bobby Bingham
* copyright (c) 2007 Bobby Bingham
* *
* This file is part of FFmpeg. * This file is part of FFmpeg.
* *
@ -19,32 +18,36 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/ */
/**
* @file
* Video splitter
*/
#include "avfilter.h" #include "avfilter.h"
static void start_frame(AVFilterLink *link, AVFilterBufferRef *picref) static void start_frame(AVFilterLink *inlink, AVFilterBufferRef *picref)
{ {
avfilter_start_frame(link->dst->outputs[0], avfilter_start_frame(inlink->dst->outputs[0],
avfilter_ref_buffer(picref, ~AV_PERM_WRITE)); avfilter_ref_buffer(picref, ~AV_PERM_WRITE));
avfilter_start_frame(link->dst->outputs[1], avfilter_start_frame(inlink->dst->outputs[1],
avfilter_ref_buffer(picref, ~AV_PERM_WRITE)); avfilter_ref_buffer(picref, ~AV_PERM_WRITE));
} }
static void end_frame(AVFilterLink *link) static void end_frame(AVFilterLink *inlink)
{ {
avfilter_end_frame(link->dst->outputs[0]); avfilter_end_frame(inlink->dst->outputs[0]);
avfilter_end_frame(link->dst->outputs[1]); avfilter_end_frame(inlink->dst->outputs[1]);
avfilter_unref_buffer(link->cur_buf); avfilter_unref_buffer(inlink->cur_buf);
} }
static void draw_slice(AVFilterLink *link, int y, int h, int slice_dir) static void draw_slice(AVFilterLink *inlink, int y, int h, int slice_dir)
{ {
avfilter_draw_slice(link->dst->outputs[0], y, h, slice_dir); avfilter_draw_slice(inlink->dst->outputs[0], y, h, slice_dir);
avfilter_draw_slice(link->dst->outputs[1], y, h, slice_dir); avfilter_draw_slice(inlink->dst->outputs[1], y, h, slice_dir);
} }
AVFilter avfilter_vf_split = AVFilter avfilter_vf_split = {
{
.name = "split", .name = "split",
.inputs = (AVFilterPad[]) {{ .name = "default", .inputs = (AVFilterPad[]) {{ .name = "default",
@ -60,4 +63,3 @@ AVFilter avfilter_vf_split =
.type = AVMEDIA_TYPE_VIDEO, }, .type = AVMEDIA_TYPE_VIDEO, },
{ .name = NULL}}, { .name = NULL}},
}; };