Browse Source

lavdev/lavfi: correctly set the inout pad index when linking a filter to the output sink

In lavfi_read_header(), use the pad index designated in the inout for
linking an output to a sink, rather than always 0. Fix link creation
for filters with more than one output (e.g. the split filter).
tags/n0.9
Stefano Sabatini 14 years ago
parent
commit
a9d1878abe
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavdevice/lavfi.c

+ 1
- 1
libavdevice/lavfi.c View File

@@ -178,7 +178,7 @@ av_cold static int lavfi_read_header(AVFormatContext *avctx,
pix_fmts, lavfi->graph)) < 0)
FAIL(ret);
lavfi->sinks[i] = sink;
if ((ret = avfilter_link(inout->filter_ctx, 0, sink, 0)) < 0)
if ((ret = avfilter_link(inout->filter_ctx, inout->pad_idx, sink, 0)) < 0)
FAIL(ret);
}



Loading…
Cancel
Save