[FFmpeg-devel] [PATCH 2/4] lavd: add device capabilities API

Lukasz Marek lukasz.m.luki at gmail.com
Fri Feb 7 14:38:49 CET 2014

>> maybe somehting like that:
>> struct FlatConfigutation
>> {
>>      ....
>> //will return lists of parameter ranges that are always valid.
>> }
>> typedef struct AVDeviceInfo {
>>      char *device_name;
>>      char *device_description;
>>      struct *FlastConfiguration;
>> } AVDeviceInfo;
>> typedef struct AVDeviceInfoList {
>>      AVDeviceInfo *devices;
>>      int nb_devices;
>>      int default_device;
>> } AVDeviceInfoList;
>> int avdevice_list_devices(
>> 	AVFormatContext *s,
>> 	AVDeviceInfoList **device_list
>> 	int *have_complex_configuration)
>> have_complex_configuration would inform user that returned flat
>> configuration doesnt cover all posibilities.
>> In cases where have_complex_configuration is not set, AVOption API
>> could be not implemented.
>> I just wonder if it is worth the effort. Making few calls with
>> AVOption API is not really complex. Solid app should always consider
>> the case when have_complex_configuration is set and the AVOption
>> code should be added anyway.
> i agree, its up to you, we have 1 user who wants it
> could be he is the only one, could be there are millions like him
> i dont know it
> also i dont insist on any API, if you want to implement another
> i just would like to have something that can handle the actual
> limitations of real world hardware.

I pushed AVOption version updated according to Nicolas' comments.
I think the second approach may be useful in some cases, but this one 
covers all raised issues and I personally prefer to focus on this one.
Someone else may add the second option or I can get back to it, but not 
in near future.

Best Regards,
Lukasz Marek

A question that sometimes drives me hazy: am I or are the others crazy? 
- Albert Einstein

More information about the ffmpeg-devel mailing list