Hi,

It has been a long time since I last developed on cinelerra due to time
constraints, therefore I also don't longer have a development account,
so I am sending this patch to the list instead of using git. I also
decided to include modify aboutprefs.C and add my name as I also have
contributed various patches to cinelerra.

In  order to use dnxhd, a recent ffmpeg should be intalled and cinelerra
must be compiled with ./configure --with-external-ffmpeg (cinelerra can
also be compiled with builtin ffmpeg only dnxhd can't be decoded)

Only decoding is handled by this patch. Encoding dnxhd can be done using
YUV4MPEG Stream and using the following pipe: ffmpeg -f yuv4mpegpipe -i
- -vcodec dnxhd -b 115Mbps %. Remember that dnxhd can not handle every
resolution. All tests have been done with 1080p50.

The patch is against latest git from j6t.

So if there is any interest you can include it, as in my opinion it is
always good to include support for industry standard formats.

Also if there should be any need for webspace in relation with cinelerra
development, I have currently a server with a 100mbit/s internet
connection and plenty of space, and could donate some webspace to you.

Bye,
David Arendt
diff -Naur cinelerra.old/cinelerra/aboutprefs.C 
cinelerra.new/cinelerra/aboutprefs.C
--- cinelerra.old/cinelerra/aboutprefs.C        2008-12-26 16:34:48.000000000 
+0100
+++ cinelerra.new/cinelerra/aboutprefs.C        2008-12-27 10:34:08.000000000 
+0100
@@ -101,6 +101,7 @@
 "Mark Taraba\n"
 "Andraz Tori\n"
 "Jonas Wulff\n"
+"David Arendt\n"
 
 );
        draw_text(x, y, credits);
diff -Naur cinelerra.old/quicktime/mpeg4.c cinelerra.new/quicktime/mpeg4.c
--- cinelerra.old/quicktime/mpeg4.c     2008-12-26 16:34:50.000000000 +0100
+++ cinelerra.new/quicktime/mpeg4.c     2008-12-27 10:35:28.000000000 +0100
@@ -1272,6 +1272,15 @@
     result->ffmpeg_id = CODEC_ID_MPEG4;
 }
 
+void quicktime_init_codec_dnxhd(quicktime_video_map_t *vtrack)
+{
+    quicktime_mpeg4_codec_t *result = init_common(vtrack,
+        QUICKTIME_DNXHD,
+        "DNXHD",
+        "DNXHD");
+    result->ffmpeg_id = CODEC_ID_DNXHD;
+}
+
 // field based MPEG-4
 void quicktime_init_codec_hv60(quicktime_video_map_t *vtrack)
 {
diff -Naur cinelerra.old/quicktime/mpeg4.h cinelerra.new/quicktime/mpeg4.h
--- cinelerra.old/quicktime/mpeg4.h     2008-12-26 16:34:50.000000000 +0100
+++ cinelerra.new/quicktime/mpeg4.h     2008-12-27 10:35:12.000000000 +0100
@@ -15,6 +15,7 @@
 extern void quicktime_init_codec_svq3(quicktime_video_map_t *);
 extern void quicktime_init_codec_h263(quicktime_video_map_t *);
 extern void quicktime_init_codec_xvid(quicktime_video_map_t *);
+extern void quicktime_init_codec_dnxhd(quicktime_video_map_t *);
 extern void quicktime_init_codec_div5(quicktime_video_map_t *vtrack);
 
 
diff -Naur cinelerra.old/quicktime/plugin.c cinelerra.new/quicktime/plugin.c
--- cinelerra.old/quicktime/plugin.c    2008-12-26 16:34:50.000000000 +0100
+++ cinelerra.new/quicktime/plugin.c    2008-12-27 10:35:34.000000000 +0100
@@ -93,6 +93,7 @@
        register_vcodec(quicktime_init_codec_div3lower);
        register_vcodec(quicktime_init_codec_mp4v);
        register_vcodec(quicktime_init_codec_xvid);
+        register_vcodec(quicktime_init_codec_dnxhd);
        register_vcodec(quicktime_init_codec_svq1);
        register_vcodec(quicktime_init_codec_svq3);
        register_vcodec(quicktime_init_codec_h263);
diff -Naur cinelerra.old/quicktime/quicktime.h 
cinelerra.new/quicktime/quicktime.h
--- cinelerra.old/quicktime/quicktime.h 2008-12-26 16:34:50.000000000 +0100
+++ cinelerra.new/quicktime/quicktime.h 2008-12-27 10:35:05.000000000 +0100
@@ -23,6 +23,7 @@
 #define QUICKTIME_MP42 "MP42"
 #define QUICKTIME_DIVX "DIVX"
 #define QUICKTIME_XVID "XVID"
+#define QUICKTIME_DNXHD "AVdn"
 #define QUICKTIME_MP4V "mp4v"
 
 #define QUICKTIME_H264 "avc1"

Reply via email to