[FFmpeg-cvslog] r14574 - trunk/libavformat/matroskadec.c

aurel subversion
Tue Aug 5 02:41:08 CEST 2008


Author: aurel
Date: Tue Aug  5 02:41:07 2008
New Revision: 14574

Log:
matroskadec: remove some unused ebml funcs

Modified:
   trunk/libavformat/matroskadec.c

Modified: trunk/libavformat/matroskadec.c
==============================================================================
--- trunk/libavformat/matroskadec.c	(original)
+++ trunk/libavformat/matroskadec.c	Tue Aug  5 02:41:07 2008
@@ -689,45 +689,6 @@ ebml_read_uint (MatroskaDemuxContext *ma
 }
 
 /*
- * Read the next element as a signed int.
- * 0 is success, < 0 is failure.
- */
-
-static int
-ebml_read_sint (MatroskaDemuxContext *matroska,
-                uint32_t             *id,
-                int64_t              *num)
-{
-    ByteIOContext *pb = matroska->ctx->pb;
-    int size, n = 1, negative = 0, res;
-    uint64_t rlength;
-
-    if ((res = ebml_read_element_id(matroska, id, NULL)) < 0 ||
-        (res = ebml_read_element_length(matroska, &rlength)) < 0)
-        return res;
-    size = rlength;
-    if (size < 1 || size > 8) {
-        offset_t pos = url_ftell(pb);
-        av_log(matroska->ctx, AV_LOG_ERROR,
-               "Invalid sint element size %d at position %"PRId64" (0x%"PRIx64")\n",
-                size, pos, pos);
-        return AVERROR_INVALIDDATA;
-    }
-    if ((*num = get_byte(pb)) & 0x80) {
-        negative = 1;
-        *num &= ~0x80;
-    }
-    while (n++ < size)
-        *num = (*num << 8) | get_byte(pb);
-
-    /* make signed */
-    if (negative)
-        *num = *num - (1LL << ((8 * size) - 1));
-
-    return 0;
-}
-
-/*
  * Read the next element as a float.
  * 0 is success, < 0 is failure.
  */
@@ -799,19 +760,6 @@ ebml_read_ascii (MatroskaDemuxContext *m
 }
 
 /*
- * Read the next element as a UTF-8 string.
- * 0 is success, < 0 is failure.
- */
-
-static int
-ebml_read_utf8 (MatroskaDemuxContext *matroska,
-                uint32_t             *id,
-                char                **str)
-{
-  return ebml_read_ascii(matroska, id, str);
-}
-
-/*
  * Read the next element, but only the header. The contents
  * are supposed to be sub-elements which can be read separately.
  * 0 is success, < 0 is failure.




More information about the ffmpeg-cvslog mailing list