[FFmpeg-devel] Notes about avdevice

Don Moir donmoir at comcast.net
Sun Nov 25 13:51:29 CET 2012


> On Sun, 25 Nov 2012 07:20:00 -0500, Don Moir wrote:
>>> On Sun, Nov 25, 2012 at 03:38:20AM -0500, Don Moir wrote:
>>>> >Don Moir <donmoir <at> comcast.net> writes:
>>>> >
>>>> >>1) avdevice has dependencies on avfilter and swresample.
>>>> >>I have no need for either of these and this is
>>>> >>unfortunate. It doesn't appear that these dependencies
>>>> >>can be turned off.
>>>> >
>>>> >Unreproducible.
>>>> >
>>>> >Carl Eugen
>>>>
>>>> If I try to use avdevice without avfilter-3.dll and swresample-0.dll
>>>> in place it complains. This is possibly due to lavfi.c in avdevice.
>>>
>>> The swresample dependency is because you have e.g. scale filter enabled
>>> in avfilter.
>>> The avfilter dependency is because you have the avfilter indev
>>> activated.
>>
>>How do you build avdevice with no dependency on avfilter ?

I got it to build without dependency on avfilter and thats a good thing.

>>> Also the device lists do _not_ go to stdout, they go to av_log.
>>> While hardly convenient, intercepting them certainly is feasible.
>>
>>Yes correct and basically means the same thing to me and not useable. You never know what will come thru av_log and in my case I
>>might have several videos playing along with camera support. Cameras get plugged in and unplugged and would need to update list
>>periodically. I am not going to do something like try to read the av_log just so I can use avdevice. But getting the list in a
>>modern way is easy along with the device resolutions and should be implemented in a modern way instead of something that goes back
>>30 years.
>>
>
> do you want json output like ffmpeg has now?

I am not sure what would be the best implementation for you would be. Internally I build a structure that contains the camera device 
names and each item in this structure contains a list of supported resolutions for that device. This works best for me but it would 
be good if I could ask avdevice to do this for me.

Like: av_get_capture_devices or whatever that returns a structure as mentioned above. But whatever form you decide is best is ok as 
long as you can do it. Keep in mind its not just the device names, but also equally important is the resolution values. There could 
be other things that are useful as well. 



More information about the ffmpeg-devel mailing list