* SECTION:gstbaseaudiodecoder
* @short_description: Base class for audio decoders
* @see_also: #GstBaseTransform
+ * @since: 0.10.36
*
* This base class is for audio decoders turning encoded data into
* raw audio samples.
* @dec: a #GstBaseAudioDecoder
*
* Returns: a #GstAudioInfo describing the input audio format
+ *
+ * Since: 0.10.36
*/
GstAudioInfo *
gst_base_audio_decoder_get_audio_info (GstBaseAudioDecoder * dec)
* @plc: new plc state
*
* Indicates whether or not subclass handles packet loss concealment (plc).
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_set_plc_aware (GstBaseAudioDecoder * dec, gboolean plc)
* @dec: a #GstBaseAudioDecoder
*
* Returns: currently configured plc handling
+ *
+ * Since: 0.10.36
*/
gint
gst_base_audio_decoder_get_plc_aware (GstBaseAudioDecoder * dec)
* @enabled: whether to enable byte to time conversion
*
* Allows baseclass to perform byte to time estimated conversion.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_set_byte_time (GstBaseAudioDecoder * dec,
* @dec: a #GstBaseAudioDecoder
*
* Returns: currently configured byte to time conversion setting
+ *
+ * Since: 0.10.36
*/
gint
gst_base_audio_decoder_get_byte_time (GstBaseAudioDecoder * dec)
* @dec: a #GstBaseAudioDecoder
*
* Returns: currently configured decoder delay
+ *
+ * Since: 0.10.36
*/
gint
gst_base_audio_decoder_get_delay (GstBaseAudioDecoder * dec)
*
* Sets numbers of tolerated decoder errors, where a tolerated one is then only
* warned about, but more than tolerated will lead to fatal error.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_set_max_errors (GstBaseAudioDecoder * enc, gint num)
* @dec: a #GstBaseAudioDecoder
*
* Returns: currently configured decoder tolerated error count.
+ *
+ * Since: 0.10.36
*/
gint
gst_base_audio_decoder_get_max_errors (GstBaseAudioDecoder * dec)
* @max: maximum latency
*
* Sets decoder latency.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_set_latency (GstBaseAudioDecoder * dec,
* @max: a pointer to storage to hold maximum latency
*
* Returns currently configured latency.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_get_latency (GstBaseAudioDecoder * dec,
* @max: a pointer to storage to hold current eos state
*
* Return current parsing (sync and eos) state.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_get_parse_state (GstBaseAudioDecoder * dec,
*
* MT safe.
*
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_set_plc (GstBaseAudioDecoder * dec, gboolean enabled)
* Returns: TRUE if packet loss concealment is enabled.
*
* MT safe.
+ *
+ * Since: 0.10.36
*/
gboolean
gst_base_audio_decoder_get_plc (GstBaseAudioDecoder * dec)
*
* MT safe.
*
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_set_min_latency (GstBaseAudioDecoder * dec, gint64 num)
* Returns: aggregation latency.
*
* MT safe.
+ *
+ * Since: 0.10.36
*/
gint64
gst_base_audio_decoder_get_min_latency (GstBaseAudioDecoder * dec)
*
* MT safe.
*
+ * Since: 0.10.36
*/
void
gst_base_audio_decoder_set_tolerance (GstBaseAudioDecoder * dec,
* Returns: decoder audio jitter tolerance threshold.
*
* MT safe.
+ *
+ * Since: 0.10.36
*/
gint64
gst_base_audio_decoder_get_tolerance (GstBaseAudioDecoder * dec)
* GST_BASE_AUDIO_DECODER_SINK_NAME:
*
* The name of the templates for the sink pad.
+ *
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_DECODER_SINK_NAME "sink"
/**
* GST_BASE_AUDIO_DECODER_SRC_NAME:
*
* The name of the templates for the source pad.
+ *
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_DECODER_SRC_NAME "src"
* @obj: base audio codec instance
*
* Gives the pointer to the source #GstPad object of the element.
+ *
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_DECODER_SRC_PAD(obj) (((GstBaseAudioDecoder *) (obj))->srcpad)
* @obj: base audio codec instance
*
* Gives the pointer to the sink #GstPad object of the element.
+ *
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_DECODER_SINK_PAD(obj) (((GstBaseAudioDecoder *) (obj))->sinkpad)
* media processing. Otherwise, it is considered a "glitch" and only a warning
* is logged. In either case, @ret is set to the proper value to
* return to upstream/caller (indicating either GST_FLOW_ERROR or GST_FLOW_OK).
+ *
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_DECODER_ERROR(el, w, domain, code, text, debug, ret) \
G_STMT_START { \
* GstBaseAudioDecoder:
*
* The opaque #GstBaseAudioDecoder data structure.
+ *
+ * Since: 0.10.36
*/
struct _GstBaseAudioDecoder
{
* Subclasses can override any of the available virtual methods or not, as
* needed. At minimum @handle_frame (and likely @set_format) needs to be
* overridden.
+ *
+ * Since: 0.10.36
*/
struct _GstBaseAudioDecoderClass
{
* SECTION:gstbaseaudioencoder
* @short_description: Base class for audio encoders
* @see_also: #GstBaseTransform
+ * @since: 0.10.36
*
* This base class is for audio encoders turning raw audio samples into
* encoded audio data.
* and a discontinuity is marked (note that @buf == NULL => push == TRUE).
*
* Returns: a #GstFlowReturn that should be escalated to caller (of caller)
+ *
+ * Since: 0.10.36
*/
GstFlowReturn
gst_base_audio_encoder_finish_frame (GstBaseAudioEncoder * enc, GstBuffer * buf,
* (e.g. muxers).
*
* Returns: a #GstCaps owned by caller
+ *
+ * Since: 0.10.36
*/
GstCaps *
gst_base_audio_encoder_proxy_getcaps (GstBaseAudioEncoder * enc, GstCaps * caps)
* @dest_format for encoded audio data. Conversion is possible between
* BYTE and TIME format by using estimated bitrate based on
* @samples and @bytes (and @fmt).
+ *
+ * Since: 0.10.36
*/
/* FIXME: make gst_base_audio_encoded_audio_convert() public? */
static gboolean
* @enc: a #GstBaseAudioEncoder
*
* Returns: a #GstAudioInfo describing the input audio format
+ *
+ * Since: 0.10.36
*/
GstAudioInfo *
gst_base_audio_encoder_get_audio_info (GstBaseAudioEncoder * enc)
*
* Sets number of samples (per channel) subclass needs to be handed,
* or will be handed all available if 0.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_frame_samples (GstBaseAudioEncoder * enc, gint num)
* @enc: a #GstBaseAudioEncoder
*
* Returns: currently requested samples per frame
+ *
+ * Since: 0.10.36
*/
gint
gst_base_audio_encoder_get_frame_samples (GstBaseAudioEncoder * enc)
* @num: number of frames
*
* Sets max number of frames accepted at once (assumed minimally 1)
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_frame_max (GstBaseAudioEncoder * enc, gint num)
* @enc: a #GstBaseAudioEncoder
*
* Returns: currently configured maximum handled frames
+ *
+ * Since: 0.10.36
*/
gint
gst_base_audio_encoder_get_frame_max (GstBaseAudioEncoder * enc)
* @num: lookahead
*
* Sets encoder lookahead (in units of input rate samples)
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_lookahead (GstBaseAudioEncoder * enc, gint num)
* @max: maximum latency
*
* Sets encoder latency.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_latency (GstBaseAudioEncoder * enc,
* @max: a pointer to storage to hold maximum latency
*
* Returns currently configured latency.
+ *
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_get_latency (GstBaseAudioEncoder * enc,
*
* MT safe.
*
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_mark_granule (GstBaseAudioEncoder * enc,
* Returns: TRUE if granule marking is enabled.
*
* MT safe.
+ *
+ * Since: 0.10.36
*/
gboolean
gst_base_audio_encoder_get_mark_granule (GstBaseAudioEncoder * enc)
*
* MT safe.
*
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_perfect_timestamp (GstBaseAudioEncoder * enc,
* Returns: TRUE if pefect timestamp setting enabled.
*
* MT safe.
+ *
+ * Since: 0.10.36
*/
gboolean
gst_base_audio_encoder_get_perfect_timestamp (GstBaseAudioEncoder * enc)
*
* MT safe.
*
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_hard_resync (GstBaseAudioEncoder * enc,
* Returns: TRUE if hard resync is enabled.
*
* MT safe.
+ *
+ * Since: 0.10.36
*/
gboolean
gst_base_audio_encoder_get_hard_resync (GstBaseAudioEncoder * enc)
*
* MT safe.
*
+ * Since: 0.10.36
*/
void
gst_base_audio_encoder_set_tolerance (GstBaseAudioEncoder * enc,
* Returns: encoder audio jitter tolerance threshold.
*
* MT safe.
+ *
+ * Since: 0.10.36
*/
gint64
gst_base_audio_encoder_get_tolerance (GstBaseAudioEncoder * enc)
* GST_BASE_AUDIO_ENCODER_SINK_NAME:
*
* the name of the templates for the sink pad
+ *
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_ENCODER_SINK_NAME "sink"
/**
* GST_BASE_AUDIO_ENCODER_SRC_NAME:
*
* the name of the templates for the source pad
+ *
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_ENCODER_SRC_NAME "src"
*
* Gives the pointer to the source #GstPad object of the element.
*
- * Since: 0.10.x
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_ENCODER_SRC_PAD(obj) (GST_BASE_AUDIO_ENCODER_CAST (obj)->srcpad)
*
* Gives the pointer to the sink #GstPad object of the element.
*
- * Since: 0.10.x
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_ENCODER_SINK_PAD(obj) (GST_BASE_AUDIO_ENCODER_CAST (obj)->sinkpad)
*
* Gives the segment of the element.
*
- * Since: 0.10.x
+ * Since: 0.10.36
*/
#define GST_BASE_AUDIO_ENCODER_SEGMENT(obj) (GST_BASE_AUDIO_ENCODER_CAST (obj)->segment)
* @element: the parent element.
*
* The opaque #GstBaseAudioEncoder data structure.
+ *
+ * Since: 0.10.36
*/
struct _GstBaseAudioEncoder {
GstElement element;
* Called when the element stops processing.
* Allows closing external resources.
* @set_format: Notifies subclass of incoming data format.
- * GstBaseAudioEncoderContext fields have already been
- * set according to provided caps.
+ * GstAudioInfo contains the format according to provided caps.
* @handle_frame: Provides input samples (or NULL to clear any remaining data)
* according to directions as provided by subclass in the
* #GstBaseAudioEncoderContext. Input data ref management
*
* Subclasses can override any of the available virtual methods or not, as
* needed. At minimum @set_format and @handle_frame needs to be overridden.
+ *
+ * Since: 0.10.36
*/
struct _GstBaseAudioEncoderClass {
GstElementClass parent_class;