diff options
author | Tim-Philipp Müller <tim@centricular.net> | 2005-10-18 18:12:31 +0000 |
---|---|---|
committer | Tim-Philipp Müller <tim@centricular.net> | 2005-10-18 18:12:31 +0000 |
commit | 66413b5f00cdac64f6b7de66e085e2523b5a36c0 (patch) | |
tree | 222fdecdaed3741145cc4fad1fcab30dd87a5841 /gst/matroska/ebml-read.h | |
parent | 2b6838d77c8fa4efbd24f8545449667c7aae65bd (diff) |
gst/matroska/: Ported matroska demuxer to 0.9.
Original commit message from CVS:
* gst/matroska/Makefile.am:
* gst/matroska/ebml-read.c:
* gst/matroska/ebml-read.h:
* gst/matroska/matroska-demux.c:
* gst/matroska/matroska-demux.h:
* gst/matroska/matroska.c: (plugin_init):
Ported matroska demuxer to 0.9.
Diffstat (limited to 'gst/matroska/ebml-read.h')
-rw-r--r-- | gst/matroska/ebml-read.h | 103 |
1 files changed, 57 insertions, 46 deletions
diff --git a/gst/matroska/ebml-read.h b/gst/matroska/ebml-read.h index e9528955..2bd74712 100644 --- a/gst/matroska/ebml-read.h +++ b/gst/matroska/ebml-read.h @@ -22,9 +22,7 @@ #ifndef __GST_EBML_READ_H__ #define __GST_EBML_READ_H__ -#include <glib.h> #include <gst/gst.h> -#include <gst/bytestream/bytestream.h> G_BEGIN_DECLS @@ -42,64 +40,77 @@ G_BEGIN_DECLS (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_EBML_READ, GstEbmlReadClass)) typedef struct _GstEbmlLevel { - guint64 start, - length; + guint64 start; + guint64 length; } GstEbmlLevel; typedef struct _GstEbmlRead { GstElement parent; + GstBuffer *cached_buffer; + GstPad *sinkpad; - GstByteStream *bs; + guint64 offset; GList *level; - - /* cache of ID (peeking) */ - guint32 id_cache; } GstEbmlRead; typedef struct _GstEbmlReadClass { GstElementClass parent; } GstEbmlReadClass; -GType gst_ebml_read_get_type (void); - -guint32 gst_ebml_peek_id (GstEbmlRead *ebml, - guint *level_up); -GstEvent *gst_ebml_read_seek (GstEbmlRead *ebml, - guint64 offset); -gboolean gst_ebml_read_skip (GstEbmlRead *ebml); -gboolean gst_ebml_read_reserve (GstEbmlRead *ebml); -gboolean gst_ebml_read_buffer (GstEbmlRead *ebml, - guint32 *id, - GstBuffer **buf); -gboolean gst_ebml_read_uint (GstEbmlRead *ebml, - guint32 *id, - guint64 *num); -gboolean gst_ebml_read_sint (GstEbmlRead *ebml, - guint32 *id, - gint64 *num); -gboolean gst_ebml_read_float (GstEbmlRead *ebml, - guint32 *id, - gdouble *num); -gboolean gst_ebml_read_ascii (GstEbmlRead *ebml, - guint32 *id, - gchar **str); -gboolean gst_ebml_read_utf8 (GstEbmlRead *ebml, - guint32 *id, - gchar **str); -gboolean gst_ebml_read_date (GstEbmlRead *ebml, - guint32 *id, - gint64 *date); -gboolean gst_ebml_read_master (GstEbmlRead *ebml, - guint32 *id); -gboolean gst_ebml_read_binary (GstEbmlRead *ebml, - guint32 *id, - guint8 **binary, - guint64 *length); -gboolean gst_ebml_read_header (GstEbmlRead *read, - gchar **doctype, - guint *version); +GType gst_ebml_read_get_type (void); + +gboolean gst_ebml_peek_id (GstEbmlRead *ebml, + guint *level_up, + guint32 *id); + +gboolean gst_ebml_read_seek (GstEbmlRead *ebml, + guint64 offset); + +gint64 gst_ebml_read_get_length (GstEbmlRead *ebml); + +gboolean gst_ebml_read_skip (GstEbmlRead *ebml); + +gboolean gst_ebml_read_buffer (GstEbmlRead *ebml, + guint32 *id, + GstBuffer **buf); + +gboolean gst_ebml_read_uint (GstEbmlRead *ebml, + guint32 *id, + guint64 *num); + +gboolean gst_ebml_read_sint (GstEbmlRead *ebml, + guint32 *id, + gint64 *num); + +gboolean gst_ebml_read_float (GstEbmlRead *ebml, + guint32 *id, + gdouble *num); + +gboolean gst_ebml_read_ascii (GstEbmlRead *ebml, + guint32 *id, + gchar **str); + +gboolean gst_ebml_read_utf8 (GstEbmlRead *ebml, + guint32 *id, + gchar **str); + +gboolean gst_ebml_read_date (GstEbmlRead *ebml, + guint32 *id, + gint64 *date); + +gboolean gst_ebml_read_master (GstEbmlRead *ebml, + guint32 *id); + +gboolean gst_ebml_read_binary (GstEbmlRead *ebml, + guint32 *id, + guint8 **binary, + guint64 *length); + +gboolean gst_ebml_read_header (GstEbmlRead *read, + gchar **doctype, + guint *version); G_END_DECLS |