[Libav-user] hot-swapping filtergraph?

Nicolas George george at nsup.org
Mon Jun 20 17:25:47 EEST 2022

Cameron Jacobson (12022-06-20):
> So, the idea is I'd like to create a project that could hot-swap filters
> (or an entire filtergraph).  I have a few ideas for the actual
> implementation.  One obviously could be a media editor.  The other idea is
> with real-time streams.  My C isn't the strongest, so I may have missed
> something obvious that would tell me it's either possible and easy or maybe
> impossible.  So far my digging through the source code hasn't convinced me
> it's not possible.

Hot-swapping an entire filter graph is easy: libavfilter does not know
what you do with your graphs. Just close and finish the first one and
start using the new one instead.

Hot-swapping a filter inside a filter graph is not supported. You can
hot-swap the whole graph keeping all the other filters unchanged. Or you
can put the filter that needs changing alone in its own filter graph and
feed manually from/to other filter graphs. This last solution is tricky
if you have more than one input and output.


  Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/libav-user/attachments/20220620/ba4d4b02/attachment.sig>

More information about the Libav-user mailing list