fftools/ffmpeg_filter: factor out binding an output stream to OutputFilter

While the new function is trivial for now, it will become more useful in
future commits.
This commit is contained in:
Anton Khirnov
2023-05-21 22:33:13 +02:00
parent dc5864a00c
commit 87b576135e
3 changed files with 11 additions and 4 deletions

View File

@@ -1259,8 +1259,7 @@ static OutputStream *ost_add(Muxer *mux, const OptionsContext *o,
(type == AVMEDIA_TYPE_VIDEO || type == AVMEDIA_TYPE_AUDIO)) {
if (ofilter) {
ost->filter = ofilter;
ofilter->ost = ost;
av_freep(&ofilter->linklabel);
ofilter_bind_ost(ofilter, ost);
} else {
ret = init_simple_filtergraph(ost->ist, ost, filters);
if (ret < 0) {