Commit ee7072fe authored by Wim Taymans's avatar Wim Taymans
Browse files

rename GstBaseAudio* ->GstAudioBase*

parent 3d0ac3de
......@@ -288,57 +288,57 @@ GST_AUDIO_SRC_GET_CLASS
<SECTION>
<FILE>gstbaseaudiosink</FILE>
<INCLUDE>gst/audio/gstbaseaudiosink.h</INCLUDE>
GstBaseAudioSink
GstBaseAudioSinkClass
GstBaseAudioSinkSlaveMethod
GST_BASE_AUDIO_SINK_CLOCK
GST_BASE_AUDIO_SINK_PAD
gst_base_audio_sink_create_ringbuffer
gst_base_audio_sink_set_provide_clock
gst_base_audio_sink_get_provide_clock
gst_base_audio_sink_set_slave_method
gst_base_audio_sink_get_slave_method
gst_base_audio_sink_get_drift_tolerance
gst_base_audio_sink_set_drift_tolerance
GstAudioBaseSink
GstAudioBaseSinkClass
GstAudioBaseSinkSlaveMethod
GST_AUDIO_BASE_SINK_CLOCK
GST_AUDIO_BASE_SINK_PAD
gst_audio_base_sink_create_ringbuffer
gst_audio_base_sink_set_provide_clock
gst_audio_base_sink_get_provide_clock
gst_audio_base_sink_set_slave_method
gst_audio_base_sink_get_slave_method
gst_audio_base_sink_get_drift_tolerance
gst_audio_base_sink_set_drift_tolerance
<SUBSECTION Standard>
GST_BASE_AUDIO_SINK
GST_IS_BASE_AUDIO_SINK
GST_TYPE_BASE_AUDIO_SINK
gst_base_audio_sink_get_type
GST_BASE_AUDIO_SINK_CLASS
GST_IS_BASE_AUDIO_SINK_CLASS
GST_BASE_AUDIO_SINK_GET_CLASS
GstBaseAudioSinkPrivate
gst_base_audio_sink_slave_method_get_type
GST_TYPE_BASE_AUDIO_SINK_SLAVE_METHOD
GST_AUDIO_BASE_SINK
GST_IS_AUDIO_BASE_SINK
GST_TYPE_AUDIO_BASE_SINK
gst_audio_base_sink_get_type
GST_AUDIO_BASE_SINK_CLASS
GST_IS_AUDIO_BASE_SINK_CLASS
GST_AUDIO_BASE_SINK_GET_CLASS
GstAudioBaseSinkPrivate
gst_audio_base_sink_slave_method_get_type
GST_TYPE_AUDIO_BASE_SINK_SLAVE_METHOD
</SECTION>
<SECTION>
<FILE>gstbaseaudiosrc</FILE>
<INCLUDE>gst/audio/gstbaseaudiosrc.h</INCLUDE>
GstBaseAudioSrc
GstBaseAudioSrcClass
GstBaseAudioSrcSlaveMethod
GST_BASE_AUDIO_SRC_CLOCK
GST_BASE_AUDIO_SRC_PAD
gst_base_audio_src_create_ringbuffer
gst_base_audio_src_set_provide_clock
gst_base_audio_src_get_provide_clock
gst_base_audio_src_get_slave_method
gst_base_audio_src_set_slave_method
GstAudioBaseSrc
GstAudioBaseSrcClass
GstAudioBaseSrcSlaveMethod
GST_AUDIO_BASE_SRC_CLOCK
GST_AUDIO_BASE_SRC_PAD
gst_audio_base_src_create_ringbuffer
gst_audio_base_src_set_provide_clock
gst_audio_base_src_get_provide_clock
gst_audio_base_src_get_slave_method
gst_audio_base_src_set_slave_method
<SUBSECTION Standard>
GstBaseAudioSrcPrivate
GST_BASE_AUDIO_SRC
GST_IS_BASE_AUDIO_SRC
GST_TYPE_BASE_AUDIO_SRC
gst_base_audio_src_get_type
GST_BASE_AUDIO_SRC_CLASS
GST_IS_BASE_AUDIO_SRC_CLASS
GST_BASE_AUDIO_SRC_GET_CLASS
gst_base_audio_src_slave_method_get_type
GST_TYPE_BASE_AUDIO_SRC_SLAVE_METHOD
GstAudioBaseSrcPrivate
GST_AUDIO_BASE_SRC
GST_IS_AUDIO_BASE_SRC
GST_TYPE_AUDIO_BASE_SRC
gst_audio_base_src_get_type
GST_AUDIO_BASE_SRC_CLASS
GST_IS_AUDIO_BASE_SRC_CLASS
GST_AUDIO_BASE_SRC_GET_CLASS
gst_audio_base_src_slave_method_get_type
GST_TYPE_AUDIO_BASE_SRC_SLAVE_METHOD
</SECTION>
<SECTION>
......
......@@ -14,9 +14,9 @@ gst_audio_sink_get_type
#include <gst/audio/gstaudiosrc.h>
gst_audio_src_get_type
#include <gst/audio/gstbaseaudiosink.h>
gst_base_audio_sink_get_type
gst_audio_base_sink_get_type
#include <gst/audio/gstbaseaudiosrc.h>
gst_base_audio_src_get_type
gst_audio_base_src_get_type
#include <gst/audio/gstaudioringbuffer.h>
gst_audio_ring_buffer_get_type
......
......@@ -316,7 +316,7 @@ static GstStateChangeReturn
gst_alsasrc_change_state (GstElement * element, GstStateChange transition)
{
GstStateChangeReturn ret = GST_STATE_CHANGE_SUCCESS;
GstBaseAudioSrc *src = GST_BASE_AUDIO_SRC (element);
GstAudioBaseSrc *src = GST_AUDIO_BASE_SRC (element);
GstAlsaSrc *asrc = GST_ALSA_SRC (element);
GstClock *clk;
......
......@@ -23,12 +23,12 @@
/**
* SECTION:gstaudioclock
* @short_description: Helper object for implementing audio clocks
* @see_also: #GstBaseAudioSink, #GstSystemClock
* @see_also: #GstAudioBaseSink, #GstSystemClock
*
* #GstAudioClock makes it easy for elements to implement a #GstClock, they
* simply need to provide a function that returns the current clock time.
*
* This object is internally used to implement the clock in #GstBaseAudioSink.
* This object is internally used to implement the clock in #GstAudioBaseSink.
*
* Last reviewed on 2006-09-27 (0.10.12)
*/
......
......@@ -20,7 +20,7 @@
/**
* SECTION:gstaudioringbuffer
* @short_description: Base class for audio ringbuffer implementations
* @see_also: #GstBaseAudioSink, #GstAudioSink
* @see_also: #GstAudioBaseSink, #GstAudioSink
*
* <refsect2>
* <para>
......
......@@ -23,7 +23,7 @@
/**
* SECTION:gstaudiosink
* @short_description: Simple base class for audio sinks
* @see_also: #GstBaseAudioSink, #GstAudioRingBuffer, #GstAudioSink.
* @see_also: #GstAudioBaseSink, #GstAudioRingBuffer, #GstAudioSink.
*
* This is the most simple base class for audio sinks that only requires
* subclasses to implement a set of simple functions:
......@@ -61,7 +61,7 @@
* </variablelist>
*
* All scheduling of samples and timestamps is done in this base class
* together with #GstBaseAudioSink using a default implementation of a
* together with #GstAudioBaseSink using a default implementation of a
* #GstAudioRingBuffer that uses threads.
*
* Last reviewed on 2006-09-27 (0.10.12)
......@@ -592,17 +592,17 @@ enum
GST_DEBUG_CATEGORY_INIT (gst_audio_sink_debug, "audiosink", 0, "audiosink element");
#define gst_audio_sink_parent_class parent_class
G_DEFINE_TYPE_WITH_CODE (GstAudioSink, gst_audio_sink,
GST_TYPE_BASE_AUDIO_SINK, _do_init);
GST_TYPE_AUDIO_BASE_SINK, _do_init);
static GstAudioRingBuffer *gst_audio_sink_create_ringbuffer (GstBaseAudioSink *
static GstAudioRingBuffer *gst_audio_sink_create_ringbuffer (GstAudioBaseSink *
sink);
static void
gst_audio_sink_class_init (GstAudioSinkClass * klass)
{
GstBaseAudioSinkClass *gstbaseaudiosink_class;
GstAudioBaseSinkClass *gstbaseaudiosink_class;
gstbaseaudiosink_class = (GstBaseAudioSinkClass *) klass;
gstbaseaudiosink_class = (GstAudioBaseSinkClass *) klass;
gstbaseaudiosink_class->create_ringbuffer =
GST_DEBUG_FUNCPTR (gst_audio_sink_create_ringbuffer);
......@@ -616,7 +616,7 @@ gst_audio_sink_init (GstAudioSink * audiosink)
}
static GstAudioRingBuffer *
gst_audio_sink_create_ringbuffer (GstBaseAudioSink * sink)
gst_audio_sink_create_ringbuffer (GstAudioBaseSink * sink)
{
GstAudioRingBuffer *buffer;
......
......@@ -44,7 +44,7 @@ typedef struct _GstAudioSinkClass GstAudioSinkClass;
* Opaque #GstAudioSink.
*/
struct _GstAudioSink {
GstBaseAudioSink element;
GstAudioBaseSink element;
/*< private >*/ /* with LOCK */
GThread *thread;
......@@ -70,7 +70,7 @@ struct _GstAudioSink {
* #GstAudioSink class. Override the vmethods to implement functionality.
*/
struct _GstAudioSinkClass {
GstBaseAudioSinkClass parent_class;
GstAudioBaseSinkClass parent_class;
/* vtable */
......
......@@ -23,7 +23,7 @@
/**
* SECTION:gstaudiosrc
* @short_description: Simple base class for audio sources
* @see_also: #GstBaseAudioSrc, #GstAudioRingBuffer, #GstAudioSrc.
* @see_also: #GstAudioBaseSrc, #GstAudioRingBuffer, #GstAudioSrc.
*
* This is the most simple base class for audio sources that only requires
* subclasses to implement a set of simple functions:
......@@ -61,7 +61,7 @@
* </variablelist>
*
* All scheduling of samples and timestamps is done in this base class
* together with #GstBaseAudioSrc using a default implementation of a
* together with #GstAudioBaseSrc using a default implementation of a
* #GstAudioRingBuffer that uses threads.
*
* Last reviewed on 2006-09-27 (0.10.12)
......@@ -505,17 +505,17 @@ enum
GST_DEBUG_CATEGORY_INIT (gst_audio_src_debug, "audiosrc", 0, "audiosrc element");
#define gst_audio_src_parent_class parent_class
G_DEFINE_TYPE_WITH_CODE (GstAudioSrc, gst_audio_src,
GST_TYPE_BASE_AUDIO_SRC, _do_init);
GST_TYPE_AUDIO_BASE_SRC, _do_init);
static GstAudioRingBuffer *gst_audio_src_create_ringbuffer (GstBaseAudioSrc *
static GstAudioRingBuffer *gst_audio_src_create_ringbuffer (GstAudioBaseSrc *
src);
static void
gst_audio_src_class_init (GstAudioSrcClass * klass)
{
GstBaseAudioSrcClass *gstbaseaudiosrc_class;
GstAudioBaseSrcClass *gstbaseaudiosrc_class;
gstbaseaudiosrc_class = (GstBaseAudioSrcClass *) klass;
gstbaseaudiosrc_class = (GstAudioBaseSrcClass *) klass;
gstbaseaudiosrc_class->create_ringbuffer =
GST_DEBUG_FUNCPTR (gst_audio_src_create_ringbuffer);
......@@ -529,7 +529,7 @@ gst_audio_src_init (GstAudioSrc * audiosrc)
}
static GstAudioRingBuffer *
gst_audio_src_create_ringbuffer (GstBaseAudioSrc * src)
gst_audio_src_create_ringbuffer (GstAudioBaseSrc * src)
{
GstAudioRingBuffer *buffer;
......
......@@ -44,7 +44,7 @@ typedef struct _GstAudioSrcClass GstAudioSrcClass;
* Base class for simple audio sources.
*/
struct _GstAudioSrc {
GstBaseAudioSrc element;
GstAudioBaseSrc element;
/*< private >*/ /* with LOCK */
GThread *thread;
......@@ -68,7 +68,7 @@ struct _GstAudioSrc {
* functionality.
*/
struct _GstAudioSrcClass {
GstBaseAudioSrcClass parent_class;
GstAudioBaseSrcClass parent_class;
/* vtable */
......
This diff is collapsed.
......@@ -46,8 +46,8 @@
* the methods in GstBaseSink and this class.
*/
#ifndef __GST_BASE_AUDIO_SINK_H__
#define __GST_BASE_AUDIO_SINK_H__
#ifndef __GST_AUDIO_BASE_SINK_H__
#define __GST_AUDIO_BASE_SINK_H__
#include <gst/gst.h>
#include <gst/base/gstbasesink.h>
......@@ -56,57 +56,57 @@
G_BEGIN_DECLS
#define GST_TYPE_BASE_AUDIO_SINK (gst_base_audio_sink_get_type())
#define GST_BASE_AUDIO_SINK(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_BASE_AUDIO_SINK,GstBaseAudioSink))
#define GST_BASE_AUDIO_SINK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_BASE_AUDIO_SINK,GstBaseAudioSinkClass))
#define GST_BASE_AUDIO_SINK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_BASE_AUDIO_SINK, GstBaseAudioSinkClass))
#define GST_IS_BASE_AUDIO_SINK(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_BASE_AUDIO_SINK))
#define GST_IS_BASE_AUDIO_SINK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_BASE_AUDIO_SINK))
#define GST_TYPE_AUDIO_BASE_SINK (gst_audio_base_sink_get_type())
#define GST_AUDIO_BASE_SINK(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_BASE_SINK,GstAudioBaseSink))
#define GST_AUDIO_BASE_SINK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_AUDIO_BASE_SINK,GstAudioBaseSinkClass))
#define GST_AUDIO_BASE_SINK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_AUDIO_BASE_SINK, GstAudioBaseSinkClass))
#define GST_IS_AUDIO_BASE_SINK(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_BASE_SINK))
#define GST_IS_AUDIO_BASE_SINK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AUDIO_BASE_SINK))
/**
* GST_BASE_AUDIO_SINK_CLOCK:
* @obj: a #GstBaseAudioSink
* GST_AUDIO_BASE_SINK_CLOCK:
* @obj: a #GstAudioBaseSink
*
* Get the #GstClock of @obj.
*/
#define GST_BASE_AUDIO_SINK_CLOCK(obj) (GST_BASE_AUDIO_SINK (obj)->clock)
#define GST_AUDIO_BASE_SINK_CLOCK(obj) (GST_AUDIO_BASE_SINK (obj)->clock)
/**
* GST_BASE_AUDIO_SINK_PAD:
* @obj: a #GstBaseAudioSink
* GST_AUDIO_BASE_SINK_PAD:
* @obj: a #GstAudioBaseSink
*
* Get the sink #GstPad of @obj.
*/
#define GST_BASE_AUDIO_SINK_PAD(obj) (GST_BASE_SINK (obj)->sinkpad)
#define GST_AUDIO_BASE_SINK_PAD(obj) (GST_BASE_SINK (obj)->sinkpad)
/**
* GstBaseAudioSinkSlaveMethod:
* @GST_BASE_AUDIO_SINK_SLAVE_RESAMPLE: Resample to match the master clock
* @GST_BASE_AUDIO_SINK_SLAVE_SKEW: Adjust playout pointer when master clock
* GstAudioBaseSinkSlaveMethod:
* @GST_AUDIO_BASE_SINK_SLAVE_RESAMPLE: Resample to match the master clock
* @GST_AUDIO_BASE_SINK_SLAVE_SKEW: Adjust playout pointer when master clock
* drifts too much.
* @GST_BASE_AUDIO_SINK_SLAVE_NONE: No adjustment is done.
* @GST_AUDIO_BASE_SINK_SLAVE_NONE: No adjustment is done.
*
* Different possible clock slaving algorithms used when the internal audio
* clock is not selected as the pipeline master clock.
*/
typedef enum
{
GST_BASE_AUDIO_SINK_SLAVE_RESAMPLE,
GST_BASE_AUDIO_SINK_SLAVE_SKEW,
GST_BASE_AUDIO_SINK_SLAVE_NONE
} GstBaseAudioSinkSlaveMethod;
GST_AUDIO_BASE_SINK_SLAVE_RESAMPLE,
GST_AUDIO_BASE_SINK_SLAVE_SKEW,
GST_AUDIO_BASE_SINK_SLAVE_NONE
} GstAudioBaseSinkSlaveMethod;
#define GST_TYPE_BASE_AUDIO_SINK_SLAVE_METHOD (gst_base_audio_sink_slave_method_get_type ())
#define GST_TYPE_AUDIO_BASE_SINK_SLAVE_METHOD (gst_audio_base_sink_slave_method_get_type ())
typedef struct _GstBaseAudioSink GstBaseAudioSink;
typedef struct _GstBaseAudioSinkClass GstBaseAudioSinkClass;
typedef struct _GstBaseAudioSinkPrivate GstBaseAudioSinkPrivate;
typedef struct _GstAudioBaseSink GstAudioBaseSink;
typedef struct _GstAudioBaseSinkClass GstAudioBaseSinkClass;
typedef struct _GstAudioBaseSinkPrivate GstAudioBaseSinkPrivate;
/**
* GstBaseAudioSink:
* GstAudioBaseSink:
*
* Opaque #GstBaseAudioSink.
* Opaque #GstAudioBaseSink.
*/
struct _GstBaseAudioSink {
struct _GstAudioBaseSink {
GstBaseSink element;
/*< protected >*/ /* with LOCK */
......@@ -128,13 +128,13 @@ struct _GstBaseAudioSink {
gboolean eos_rendering;
/*< private >*/
GstBaseAudioSinkPrivate *priv;
GstAudioBaseSinkPrivate *priv;
gpointer _gst_reserved[GST_PADDING];
};
/**
* GstBaseAudioSinkClass:
* GstAudioBaseSinkClass:
* @parent_class: the parent class.
* @create_ringbuffer: create and return a #GstAudioRingBuffer to write to.
* @payload: payload data in a format suitable to write to the sink. If no
......@@ -142,50 +142,50 @@ struct _GstBaseAudioSink {
* buffer, else returns the payloaded buffer with all other metadata
* copied. (Since: 0.10.36)
*
* #GstBaseAudioSink class. Override the vmethod to implement
* #GstAudioBaseSink class. Override the vmethod to implement
* functionality.
*/
struct _GstBaseAudioSinkClass {
struct _GstAudioBaseSinkClass {
GstBaseSinkClass parent_class;
/* subclass ringbuffer allocation */
GstAudioRingBuffer* (*create_ringbuffer) (GstBaseAudioSink *sink);
GstAudioRingBuffer* (*create_ringbuffer) (GstAudioBaseSink *sink);
/* subclass payloader */
GstBuffer* (*payload) (GstBaseAudioSink *sink,
GstBuffer* (*payload) (GstAudioBaseSink *sink,
GstBuffer *buffer);
/*< private >*/
gpointer _gst_reserved[GST_PADDING];
};
GType gst_base_audio_sink_get_type(void);
GType gst_base_audio_sink_slave_method_get_type (void);
GType gst_audio_base_sink_get_type(void);
GType gst_audio_base_sink_slave_method_get_type (void);
GstAudioRingBuffer *
gst_base_audio_sink_create_ringbuffer (GstBaseAudioSink *sink);
gst_audio_base_sink_create_ringbuffer (GstAudioBaseSink *sink);
void gst_base_audio_sink_set_provide_clock (GstBaseAudioSink *sink, gboolean provide);
gboolean gst_base_audio_sink_get_provide_clock (GstBaseAudioSink *sink);
void gst_audio_base_sink_set_provide_clock (GstAudioBaseSink *sink, gboolean provide);
gboolean gst_audio_base_sink_get_provide_clock (GstAudioBaseSink *sink);
void gst_base_audio_sink_set_slave_method (GstBaseAudioSink *sink,
GstBaseAudioSinkSlaveMethod method);
GstBaseAudioSinkSlaveMethod
gst_base_audio_sink_get_slave_method (GstBaseAudioSink *sink);
void gst_audio_base_sink_set_slave_method (GstAudioBaseSink *sink,
GstAudioBaseSinkSlaveMethod method);
GstAudioBaseSinkSlaveMethod
gst_audio_base_sink_get_slave_method (GstAudioBaseSink *sink);
void gst_base_audio_sink_set_drift_tolerance (GstBaseAudioSink *sink,
void gst_audio_base_sink_set_drift_tolerance (GstAudioBaseSink *sink,
gint64 drift_tolerance);
gint64 gst_base_audio_sink_get_drift_tolerance (GstBaseAudioSink *sink);
gint64 gst_audio_base_sink_get_drift_tolerance (GstAudioBaseSink *sink);
void gst_base_audio_sink_set_alignment_threshold (GstBaseAudioSink * sink,
void gst_audio_base_sink_set_alignment_threshold (GstAudioBaseSink * sink,
GstClockTime alignment_threshold);
GstClockTime
gst_base_audio_sink_get_alignment_threshold (GstBaseAudioSink * sink);
gst_audio_base_sink_get_alignment_threshold (GstAudioBaseSink * sink);
void gst_base_audio_sink_set_discont_wait (GstBaseAudioSink * sink,
void gst_audio_base_sink_set_discont_wait (GstAudioBaseSink * sink,
GstClockTime discont_wait);
GstClockTime
gst_base_audio_sink_get_discont_wait (GstBaseAudioSink * sink);
gst_audio_base_sink_get_discont_wait (GstAudioBaseSink * sink);
G_END_DECLS
#endif /* __GST_BASE_AUDIO_SINK_H__ */
#endif /* __GST_AUDIO_BASE_SINK_H__ */
This diff is collapsed.
......@@ -23,8 +23,8 @@
/* a base class for audio sources.
*/
#ifndef __GST_BASE_AUDIO_SRC_H__
#define __GST_BASE_AUDIO_SRC_H__
#ifndef __GST_AUDIO_BASE_SRC_H__
#define __GST_AUDIO_BASE_SRC_H__
#include <gst/gst.h>
#include <gst/base/gstpushsrc.h>
......@@ -33,60 +33,60 @@
G_BEGIN_DECLS
#define GST_TYPE_BASE_AUDIO_SRC (gst_base_audio_src_get_type())
#define GST_BASE_AUDIO_SRC(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_BASE_AUDIO_SRC,GstBaseAudioSrc))
#define GST_BASE_AUDIO_SRC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_BASE_AUDIO_SRC,GstBaseAudioSrcClass))
#define GST_BASE_AUDIO_SRC_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_BASE_AUDIO_SRC, GstBaseAudioSrcClass))
#define GST_IS_BASE_AUDIO_SRC(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_BASE_AUDIO_SRC))
#define GST_IS_BASE_AUDIO_SRC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_BASE_AUDIO_SRC))
#define GST_TYPE_AUDIO_BASE_SRC (gst_audio_base_src_get_type())
#define GST_AUDIO_BASE_SRC(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_BASE_SRC,GstAudioBaseSrc))
#define GST_AUDIO_BASE_SRC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_AUDIO_BASE_SRC,GstAudioBaseSrcClass))
#define GST_AUDIO_BASE_SRC_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_AUDIO_BASE_SRC, GstAudioBaseSrcClass))
#define GST_IS_AUDIO_BASE_SRC(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_BASE_SRC))
#define GST_IS_AUDIO_BASE_SRC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AUDIO_BASE_SRC))
/**
* GST_BASE_AUDIO_SRC_CLOCK:
* @obj: a #GstBaseAudioSrc
* GST_AUDIO_BASE_SRC_CLOCK:
* @obj: a #GstAudioBaseSrc
*
* Get the #GstClock of @obj.
*/
#define GST_BASE_AUDIO_SRC_CLOCK(obj) (GST_BASE_AUDIO_SRC (obj)->clock)
#define GST_AUDIO_BASE_SRC_CLOCK(obj) (GST_AUDIO_BASE_SRC (obj)->clock)
/**
* GST_BASE_AUDIO_SRC_PAD:
* @obj: a #GstBaseAudioSrc
* GST_AUDIO_BASE_SRC_PAD:
* @obj: a #GstAudioBaseSrc
*
* Get the source #GstPad of @obj.
*/
#define GST_BASE_AUDIO_SRC_PAD(obj) (GST_BASE_SRC (obj)->srcpad)
#define GST_AUDIO_BASE_SRC_PAD(obj) (GST_BASE_SRC (obj)->srcpad)
typedef struct _GstBaseAudioSrc GstBaseAudioSrc;
typedef struct _GstBaseAudioSrcClass GstBaseAudioSrcClass;
typedef struct _GstBaseAudioSrcPrivate GstBaseAudioSrcPrivate;
typedef struct _GstAudioBaseSrc GstAudioBaseSrc;
typedef struct _GstAudioBaseSrcClass GstAudioBaseSrcClass;
typedef struct _GstAudioBaseSrcPrivate GstAudioBaseSrcPrivate;
/**
* GstBaseAudioSrcSlaveMethod:
* @GST_BASE_AUDIO_SRC_SLAVE_RESAMPLE: Resample to match the master clock.
* @GST_BASE_AUDIO_SRC_SLAVE_RETIMESTAMP: Retimestamp output buffers with master
* GstAudioBaseSrcSlaveMethod:
* @GST_AUDIO_BASE_SRC_SLAVE_RESAMPLE: Resample to match the master clock.
* @GST_AUDIO_BASE_SRC_SLAVE_RETIMESTAMP: Retimestamp output buffers with master
* clock time.
* @GST_BASE_AUDIO_SRC_SLAVE_SKEW: Adjust capture pointer when master clock
* @GST_AUDIO_BASE_SRC_SLAVE_SKEW: Adjust capture pointer when master clock
* drifts too much.
* @GST_BASE_AUDIO_SRC_SLAVE_NONE: No adjustment is done.
* @GST_AUDIO_BASE_SRC_SLAVE_NONE: No adjustment is done.
*
* Different possible clock slaving algorithms when the internal audio clock was
* not selected as the pipeline clock.
*/
typedef enum
{
GST_BASE_AUDIO_SRC_SLAVE_RESAMPLE,
GST_BASE_AUDIO_SRC_SLAVE_RETIMESTAMP,
GST_BASE_AUDIO_SRC_SLAVE_SKEW,
GST_BASE_AUDIO_SRC_SLAVE_NONE
} GstBaseAudioSrcSlaveMethod;
GST_AUDIO_BASE_SRC_SLAVE_RESAMPLE,
GST_AUDIO_BASE_SRC_SLAVE_RETIMESTAMP,
GST_AUDIO_BASE_SRC_SLAVE_SKEW,
GST_AUDIO_BASE_SRC_SLAVE_NONE
} GstAudioBaseSrcSlaveMethod;
#define GST_TYPE_BASE_AUDIO_SRC_SLAVE_METHOD (gst_base_audio_src_slave_method_get_type ())
#define GST_TYPE_AUDIO_BASE_SRC_SLAVE_METHOD (gst_audio_base_src_slave_method_get_type ())
/**
* GstBaseAudioSrc:
* GstAudioBaseSrc:
*
* Opaque #GstBaseAudioSrc.
* Opaque #GstAudioBaseSrc.
*/
struct _GstBaseAudioSrc {
struct _GstAudioBaseSrc {
GstPushSrc element;
/*< protected >*/ /* with LOCK */
......@@ -104,44 +104,44 @@ struct _GstBaseAudioSrc {
GstClock *clock;
/*< private >*/
GstBaseAudioSrcPrivate *priv;
GstAudioBaseSrcPrivate *priv;
gpointer _gst_reserved[GST_PADDING - 1];
};
/**
* GstBaseAudioSrcClass:
* GstAudioBaseSrcClass:
* @parent_class: the parent class.
* @create_ringbuffer: create and return a #GstAudioRingBuffer to read from.
*
* #GstBaseAudioSrc class. Override the vmethod to implement
* #GstAudioBaseSrc class. Override the vmethod to implement
* functionality.
*/
struct _GstBaseAudioSrcClass {
struct _GstAudioBaseSrcClass {
GstPushSrcClass parent_class;
/* subclass ringbuffer allocation */
GstAudioRingBuffer* (*create_ringbuffer) (GstBaseAudioSrc *src);
GstAudioRingBuffer* (*create_ringbuffer) (GstAudioBaseSrc *src);
/*< private >*/
gpointer _gst_reserved[GST_PADDING];
};
GType gst_base_audio_src_get_type(void);
GType gst_base_audio_src_slave_method_get_type (void);
GType gst_audio_base_src_get_type(void);
GType gst_audio_base_src_slave_method_get_type (void);
GstAudioRingBuffer *
gst_base_audio_src_create_ringbuffer (GstBaseAudioSrc *src);
gst_audio_base_src_create_ringbuffer (GstAudioBaseSrc *src);
void gst_base_audio_src_set_provide_clock (GstBaseAudioSrc *src, gboolean provide);
gboolean gst_base_audio_src_get_provide_clock (GstBaseAudioSrc *src);
void gst_audio_base_src_set_provide_clock (GstAudioBaseSrc *src, gboolean provide);
gboolean gst_audio_base_src_get_provide_clock (GstAudioBaseSrc *src);
void gst_base_audio_src_set_slave_method (GstBaseAudioSrc *src,
GstBaseAudioSrcSlaveMethod method);
GstBaseAudioSrcSlaveMethod
gst_base_audio_src_get_slave_method (GstBaseAudioSrc *src);
void gst_audio_base_src_set_slave_method (GstAudioBaseSrc *src,
GstAudioBaseSrcSlaveMethod method);
GstAudioBaseSrcSlaveMethod
gst_audio_base_src_get_slave_method (GstAudioBaseSrc *src);