[Mplayer-cvslog] CVS: main/libmpdemux demux_matroska.c, NONE, 1.1 Makefile, 1.74, 1.75 demux_mkv.c, 1.5, NONE

Moritz Bunkus CVS mosu at mplayerhq.hu
Fri Jan 23 16:36:06 CET 2004


Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/tmp/cvs-serv19276

Modified Files:
	Makefile 
Added Files:
	demux_matroska.c 
Removed Files:
	demux_mkv.c 
Log Message:
Renamed demux_mkv.c to demux_matroska.c because otherwise demux_mkv.cpp would never get compiled regardless of the settings of MATROSKA_INTERNAL and MATROSKA_EXTERNAL.

--- NEW FILE ---
/*
 * native Matroska demuxer
 * Written by Aurelien Jacobs <aurel at gnuage.org>
 * Based on the one written by Ronald Bultje for gstreamer
 *   and on demux_mkv.cpp from Moritz Bunkus.
 * Licence: GPL
 */

#include "config.h"
#ifdef HAVE_MATROSKA

#include <stdlib.h>
#include <stdio.h>
#include <ctype.h>

#include "stream.h"
#include "demuxer.h"
#include "stheader.h"
#include "ebml.h"
[...2838 lines suppressed...]
    case DEMUXER_CTRL_GET_PERCENT_POS:
      if (mkv_d->duration == 0)
        {
          if (demuxer->movi_start == demuxer->movi_end)
            return DEMUXER_CTRL_DONTKNOW;

          *((int *)arg) = (int)((demuxer->filepos - demuxer->movi_start) /
                                ((demuxer->movi_end-demuxer->movi_start)/100));
          return DEMUXER_CTRL_OK;
        }

      *((int *) arg) = (int) (100 * mkv_d->last_pts / mkv_d->duration);
      return DEMUXER_CTRL_OK; 

    default:
      return DEMUXER_CTRL_NOTIMPL;
    }
}

#endif /* HAVE_MATROSKA */

Index: Makefile
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/Makefile,v
retrieving revision 1.74
retrieving revision 1.75
diff -u -r1.74 -r1.75
--- Makefile	19 Jan 2004 19:16:10 -0000	1.74
+++ Makefile	23 Jan 2004 15:36:04 -0000	1.75
@@ -27,7 +27,7 @@
 endif
 
 ifeq ($(MATROSKA_INTERNAL),yes)
-SRCS += demux_mkv.c ebml.c
+SRCS += demux_matroska.c ebml.c
 endif
 ifeq ($(MATROSKA_EXTERNAL),yes)
 CPLUSPLUSSRCS += demux_mkv.cpp

--- demux_mkv.c DELETED ---




More information about the MPlayer-cvslog mailing list