@table @option
@item inputs
Set number of input streams. Default is 2.
+
+@item shortest
+If set to 1, force the output to terminate when the shortest input
+terminates. Default value is 0.
@end table
@section hue
@table @option
@item inputs
Set number of input streams. Default is 2.
+
+@item shortest
+If set to 1, force the output to terminate when the shortest input
+terminates. Default value is 0.
@end table
@section w3fdif
const AVClass *class;
const AVPixFmtDescriptor *desc;
int nb_inputs;
+ int shortest;
int is_vertical;
int nb_planes;
in[i].time_base = inlink->time_base;
in[i].sync = 1;
in[i].before = EXT_STOP;
- in[i].after = EXT_INFINITY;
+ in[i].after = s->shortest ? EXT_STOP : EXT_INFINITY;
}
return ff_framesync_configure(&s->fs);
#define FLAGS AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_FILTERING_PARAM
static const AVOption stack_options[] = {
{ "inputs", "set number of inputs", OFFSET(nb_inputs), AV_OPT_TYPE_INT, {.i64=2}, 2, INT_MAX, .flags = FLAGS },
+ { "shortest", "force termination when the shortest input terminates", OFFSET(shortest), AV_OPT_TYPE_BOOL, {.i64=0}, 0, 1, .flags = FLAGS },
{ NULL },
};