[MPlayer-cvslog] r19332 - in trunk/libmpdemux: demux_mov.c demux_ogg.c

diego subversion at mplayerhq.hu
Fri Aug 4 23:19:07 CEST 2006


Author: diego
Date: Fri Aug  4 23:19:06 2006
New Revision: 19332

Modified:
   trunk/libmpdemux/demux_mov.c
   trunk/libmpdemux/demux_ogg.c

Log:
Move store_ughvlc to demux_mov as demux_ogg is not always compiled in.
inspired by a patch from Emanuele Giaquinta, emanuele.giaquinta %@% gmail.com


Modified: trunk/libmpdemux/demux_mov.c
==============================================================================
--- trunk/libmpdemux/demux_mov.c	(original)
+++ trunk/libmpdemux/demux_mov.c	Fri Aug  4 23:19:06 2006
@@ -540,10 +540,23 @@
   free(priv);
 }
 
+unsigned int store_ughvlc(unsigned char *s, unsigned int v){
+  unsigned int n = 0;
+
+  while(v >= 0xff) {
+    *s++ = 0xff;
+    v -= 0xff;
+    n++;
+  }
+  *s = v;
+  n++;
+
+  return n;
+}
+
 static int lschunks_intrak(demuxer_t* demuxer, int level, unsigned int id,
                            off_t pos, off_t len, mov_track_t* trak);
 
-extern unsigned int store_ughvlc(unsigned char *s, unsigned int v);
 static void lschunks(demuxer_t* demuxer,int level,off_t endpos,mov_track_t* trak){
     mov_priv_t* priv=demuxer->priv;
 //    printf("lschunks (level=%d,endpos=%x)\n", level, endpos);

Modified: trunk/libmpdemux/demux_ogg.c
==============================================================================
--- trunk/libmpdemux/demux_ogg.c	(original)
+++ trunk/libmpdemux/demux_ogg.c	Fri Aug  4 23:19:06 2006
@@ -1,22 +1,6 @@
 
 #include "config.h"
 
-unsigned int store_ughvlc(unsigned char *s, unsigned int v)
-{
-  unsigned int n = 0;
-
-  while(v >= 0xff)
-  {
-    *s++ = 0xff;
-    v -= 0xff;
-    n++;
-  }
-  *s = v;
-  n++;
-
-  return n;
-}
-
 #include <stdlib.h>
 #include <stdio.h>
 #include <string.h>
@@ -730,6 +714,9 @@
 extern void print_wave_header(WAVEFORMATEX *h, int verbose_level);
 extern void print_video_header(BITMAPINFOHEADER *h, int verbose_level);
 
+/* defined in demux_mov.c */
+extern unsigned int store_ughvlc(unsigned char *s, unsigned int v);
+
 /** \brief Return the number of subtitle tracks in the file.
 
   \param demuxer The demuxer for which the number of subtitle tracks



More information about the MPlayer-cvslog mailing list