[FFmpeg-devel] [PATCH 02/13] lavf: update auto-bsf to new BSF API

Marton Balint cus at passwd.hu
Sat Jun 25 14:44:26 CEST 2016


On Sun, 12 Jun 2016, Nicolas George wrote:

> Le quintidi 25 prairial, an CCXXIV, Marton Balint a écrit :
>> 					      So you probably don't have to
>> support multiple filters, it is enough if you support a single one.
>
> This is not settled. I still think a specific API is better than a container
> filter.

I thought your primary concern was the overhead which was discussed.

As far as I know the only thing left is the "cleanness". A totally 
separate list API would involve a lot of code duplication (provide the N:M 
API for lists, and provide the same fields to a BSF list which are already 
available as part of a BSF context. (time_base, codec parameters)

And we only need the list API for the configuration anyway. So what if we 
destroy the list after the configuration is done, and use it as a simple 
BSF afterwards?

Is it OK if the following is implemented?

AVBSFList *list = av_bsf_list_alloc()

// Append as many filters as you want...
av_bsf_list_append(AVBSFList *, AVBSFContext *)

// Destroy the list structure and return the BSF context which is the 
// container list filter we discussed, and which can be used as any other 
// freshly allocated BSF context
av_bsf_list_finalize(AVBSFList **list, AVBSFContext **ctx)

Thanks
Marton


More information about the ffmpeg-devel mailing list