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

Michael Niedermayer michaelni at gmx.at
Thu Feb 6 22:11:19 CET 2014

On Thu, Feb 06, 2014 at 05:40:52PM +0100, Lukasz Marek wrote:
> >>Solution you suggest is the same I proposed before and was rejected.
> >>So I give up any further work on it until you figure out what should
> >>it look like.
> >
> >Maybe a solution is to do both ?
> >have a very simple flat structure that lists limitations but
> >would not be able to repesent complex real hw so for example
> >like these:  http://gopro.com/product-comparison-hero3-cameras
> >
> >so it would then possibly list 30fps and 1080p as maximum
> >while the AVOption interface would list that it also can do
> >4K at 15fps and 960p at 100fps ans wvga at 240fps
> 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.

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

In fact, the RIAA has been known to suggest that students drop out
of college or go to community college in order to be able to afford
settlements. -- The RIAA
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140206/471ab0b0/attachment.asc>

More information about the ffmpeg-devel mailing list