[FFmpeg-cvslog] libdc1394: fix compilation.

Anton Khirnov git at videolan.org
Fri May 27 02:53:52 CEST 2011


ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Thu May 26 07:25:41 2011 +0200| [2341c97e8d737876693fc1e0ecfe7f9f6d2b7c57] | committer: Anton Khirnov

libdc1394: fix compilation.

Add a forgotten comma and move options/class definition outside of
HAVE_LIBDC1394_1.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=2341c97e8d737876693fc1e0ecfe7f9f6d2b7c57
---

 libavdevice/libdc1394.c |   31 ++++++++++++++++---------------
 1 files changed, 16 insertions(+), 15 deletions(-)

diff --git a/libavdevice/libdc1394.c b/libavdevice/libdc1394.c
index 96e9e9b..336c465 100644
--- a/libavdevice/libdc1394.c
+++ b/libavdevice/libdc1394.c
@@ -90,6 +90,21 @@ struct dc1394_frame_rate {
     { 0, 0 } /* gotta be the last one */
 };
 
+static const AVOption options[] = {
+#if HAVE_LIBDC1394_1
+    { "channel", "", offsetof(dc1394_data, channel), FF_OPT_TYPE_INT, {.dbl = 0}, 0, INT_MAX, AV_OPT_FLAG_DECODING_PARAM },
+#endif
+    { NULL },
+};
+
+static const AVClass libdc1394_class = {
+    .class_name = "libdc1394 indev",
+    .item_name  = av_default_item_name,
+    .option     = options,
+    .version    = LIBAVUTIL_VERSION_INT,
+};
+
+
 static inline int dc1394_read_common(AVFormatContext *c, AVFormatParameters *ap,
                                      struct dc1394_frame_format **select_fmt, struct dc1394_frame_rate **select_fps)
 {
@@ -245,20 +260,6 @@ static int dc1394_v1_close(AVFormatContext * context)
     return 0;
 }
 
-static const AVOption options[] = {
-#if HAVE_LIBDC1394_1
-    { "channel", "", offsetof(dc1394_data, channel), FF_OPT_TYPE_INT, {.dbl = 0}, 0, INT_MAX, AV_OPT_FLAG_DECODING_PARAM },
-#endif
-    { NULL },
-};
-
-static const AVClass libdc1394_class = {
-    .class_name = "libdc1394 indev",
-    .item_name  = av_default_item_name,
-    .option     = options,
-    .version    = LIBAVUTIL_VERSION_INT,
-};
-
 #elif HAVE_LIBDC1394_2
 static int dc1394_v2_read_header(AVFormatContext *c, AVFormatParameters * ap)
 {
@@ -378,7 +379,7 @@ AVInputFormat ff_libdc1394_demuxer = {
     .read_header    = dc1394_v2_read_header,
     .read_packet    = dc1394_v2_read_packet,
     .read_close     = dc1394_v2_close,
-    .flags          = AVFMT_NOFILE
+    .flags          = AVFMT_NOFILE,
     .priv_class     = &libdc1394_class,
 };
 



More information about the ffmpeg-cvslog mailing list