1 /* GStreamer RealAudio demuxer
2 * Copyright (C) 2006 Tim-Philipp Müller <tim centricular net>
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Library General Public License for more details.
14 * You should have received a copy of the GNU Library General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
17 * Boston, MA 02110-1301, USA.
20 #ifndef __GST_REAL_AUDIO_DEMUX_H__
21 #define __GST_REAL_AUDIO_DEMUX_H__
24 #include <gst/base/gstadapter.h>
28 #define GST_TYPE_REAL_AUDIO_DEMUX \
29 (gst_real_audio_demux_get_type())
30 #define GST_REAL_AUDIO_DEMUX(obj) \
31 (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_REAL_AUDIO_DEMUX,GstRealAudioDemux))
32 #define GST_REAL_AUDIO_DEMUX_CLASS(klass) \
33 (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_REAL_AUDIO_DEMUX,GstRealAudioDemuxClass))
34 #define GST_IS_REAL_AUDIO_DEMUX(obj) \
35 (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_REAL_AUDIO_DEMUX))
36 #define GST_IS_REAL_AUDIO_DEMUX_CLASS(klass) \
37 (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_REAL_AUDIO_DEMUX))
41 REAL_AUDIO_DEMUX_STATE_MARKER,
42 REAL_AUDIO_DEMUX_STATE_HEADER,
43 REAL_AUDIO_DEMUX_STATE_DATA
44 } GstRealAudioDemuxState;
46 typedef struct _GstRealAudioDemux GstRealAudioDemux;
47 typedef struct _GstRealAudioDemuxClass GstRealAudioDemuxClass;
49 struct _GstRealAudioDemux {
55 gboolean have_group_id;
59 GstRealAudioDemuxState state;
74 gboolean segment_running;
76 gboolean need_newsegment;
77 GstTagList *pending_tags;
79 guint byterate_num; /* bytes per second */
85 guint64 offset; /* current read byte offset for
86 * pull_range-based mode */
88 /* playback start/stop positions */
94 struct _GstRealAudioDemuxClass {
95 GstElementClass element_class;
98 GType gst_real_audio_demux_get_type (void);
100 GST_ELEMENT_REGISTER_DECLARE (rademux);
104 #endif /* __GST_REAL_AUDIO_DEMUX_H__ */