[gst-cvs] gst-plugins-good: avi: lower max file size

Wim Taymans wtay at kemper.freedesktop.org
Tue Oct 13 04:10:07 PDT 2009


Module: gst-plugins-good
Branch: master
Commit: 50110d022d8ad2c17255446c143672ed261efd2f
URL:    http://cgit.freedesktop.org/gstreamer/gst-plugins-good/commit/?id=50110d022d8ad2c17255446c143672ed261efd2f

Author: Wim Taymans <wim.taymans at collabora.co.uk>
Date:   Tue Oct 13 13:08:33 2009 +0200

avi: lower max file size

Make a constant of the max file size and lower the value to what ffmpeg does,
hopefully improving compatibility with windows media player.

See #597847

---

 gst/avi/gstavimux.c |    2 +-
 gst/avi/gstavimux.h |    3 +++
 2 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/gst/avi/gstavimux.c b/gst/avi/gstavimux.c
index 3b945ca..59319ce 100644
--- a/gst/avi/gstavimux.c
+++ b/gst/avi/gstavimux.c
@@ -1773,7 +1773,7 @@ gst_avi_mux_do_buffer (GstAviMux * avimux, GstAviPad * avipad)
 
   /* need to restart or start a next avix chunk ? */
   if ((avimux->is_bigfile ? avimux->datax_size : avimux->data_size) +
-      GST_BUFFER_SIZE (data) > 1024 * 1024 * 2000) {
+      GST_BUFFER_SIZE (data) > GST_AVI_MAX_SIZE) {
     if (avimux->enable_large_avi) {
       if ((res = gst_avi_mux_bigfile (avimux, FALSE)) != GST_FLOW_OK)
         return res;
diff --git a/gst/avi/gstavimux.h b/gst/avi/gstavimux.h
index 3b39285..0cc6908 100644
--- a/gst/avi/gstavimux.h
+++ b/gst/avi/gstavimux.h
@@ -46,6 +46,9 @@ G_BEGIN_DECLS
 /* this allows indexing up to 64GB avi file */
 #define GST_AVI_SUPERINDEX_COUNT    32
 
+/* max size */
+#define GST_AVI_MAX_SIZE    0x40000000
+
 typedef struct _gst_avi_superindex_entry {
   guint64 offset;
   guint32 size;





More information about the Gstreamer-commits mailing list