Opened 11 years ago

Closed 11 years ago

#224 closed enhancement (fixed)

Improving support for IIDC cameras (libavdevice/libdc1394.c)

Reported by: Martin Lambers Owned by:
Priority: wish Component: avdevice
Version: git Keywords: libdc1394
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no


[This is the following post from ffmpeg-devel:
<>. Since there was no reply, I add this ticket so that the patch does not get lost.]

Hello all,

currently, the libdc1394 format only supports very few video modes:
320x240 or 640x480, and only two pixel formats. Furthermore, these modes
have to be selected via AVFormatParameters, there is no autodetection.

I'd like to change that so that the camera is queried for the modes it
supports, and a suitable mode is selected with regard to
AVFormatParameters. If no parameters are given, the best mode should be
chosen automatically. Furthermore, I'd like to add support for more
pixel formats.

The attached patches do this in two steps:

1) Remove support for the libdc1394 v1 API. V2 has been available for
ages (it even is in Debian oldstable), and V1 is not shipped with
current distributions anymore (it does not work with current kernels).

2) Replace the mode selection code in dc1394.c (but leave the rest of
the code untouched). Use the libdc1394 v2 API to query available video
modes, remove those that we currently do not support, and sort the rest
according to preference. Then pick a mode according to
AVFormatParameters, or use a fallback based on the preferences list. At
the same time, support all dc1394 color codings for which there is a
corresponding FFmpeg pixel format.

Please comment.


Attachments (2)

0001-Remove-support-for-libdc1394-2.0.patch (8.5 KB ) - added by Martin Lambers 11 years ago.
0002-Improve-libdc1394-mode-and-rate-selection.patch (14.3 KB ) - added by Martin Lambers 11 years ago.

Download all attachments as: .zip

Change History (3)

by Martin Lambers, 11 years ago

comment:1 by Michael Niedermayer, 11 years ago

Resolution: fixed
Status: newclosed

These patches have been applied some time ago

Note: See TracTickets for help on using tickets.