GstAudioRingBuffer

This object is the base class for audio ringbuffers used by the base audio source and sink classes.

The ringbuffer abstracts a circular buffer of data. One reader and one writer can operate on the data from different threads in a lockfree manner. The base class is sufficiently flexible to be used as an abstraction for DMA based ringbuffers as well as a pure software implementations.

GstAudioRingBuffer

GObject
    ╰──GInitiallyUnowned
        ╰──GstObject
            ╰──GstAudioRingBuffer

The ringbuffer base class structure.

Members

object (GstObject) –
No description available
cond (GCond) –

used to signal start/stop/pause/resume actions

open (gboolean) –

boolean indicating that the ringbuffer is open

acquired (gboolean) –

boolean indicating that the ringbuffer is acquired

memory (guint8 *) –

data in the ringbuffer

size (gsize) –

size of data in the ringbuffer

format and layout of the ringbuffer data

samples_per_seg (gint) –

number of samples in one segment

empty_seg (guint8 *) –

pointer to memory holding one segment of silence samples

state (gint) –

state of the buffer

segdone (gint) –

readpointer in the ringbuffer

segbase (gint) –

segment corresponding to segment 0 (unused)

waiting (gint) –

is a reader or writer waiting for a free segment


Class structure

GstAudioRingBufferClass

The vmethods that subclasses can override to implement the ringbuffer.

Fields
parent_class (GstObjectClass) –

parent class


GstAudio.AudioRingBufferClass

The vmethods that subclasses can override to implement the ringbuffer.

Attributes
parent_class (Gst.ObjectClass) –

parent class


GstAudio.AudioRingBufferClass

The vmethods that subclasses can override to implement the ringbuffer.

Attributes
parent_class (Gst.ObjectClass) –

parent class


GstAudioRingBuffer

GObject
    ╰──GInitiallyUnowned
        ╰──GstObject
            ╰──GstAudioRingBuffer

The ringbuffer base class structure.

Members

object (GstObject) –
No description available
cond (GCond) –

used to signal start/stop/pause/resume actions

open (bool) –

boolean indicating that the ringbuffer is open

acquired (bool) –

boolean indicating that the ringbuffer is acquired

memory (int) –

data in the ringbuffer

size (int) –

size of data in the ringbuffer

format and layout of the ringbuffer data

samples_per_seg (int) –

number of samples in one segment

empty_seg (int) –

pointer to memory holding one segment of silence samples

state (int) –

state of the buffer

segdone (int) –

readpointer in the ringbuffer

segbase (int) –

segment corresponding to segment 0 (unused)

waiting (int) –

is a reader or writer waiting for a free segment


GstAudioRingBuffer

GObject
    ╰──GInitiallyUnowned
        ╰──GstObject
            ╰──GstAudioRingBuffer

The ringbuffer base class structure.

Members

object (GstObject) –
No description available
cond (GCond) –

used to signal start/stop/pause/resume actions

open (Number) –

boolean indicating that the ringbuffer is open

acquired (Number) –

boolean indicating that the ringbuffer is acquired

memory (Number) –

data in the ringbuffer

size (Number) –

size of data in the ringbuffer

format and layout of the ringbuffer data

samples_per_seg (Number) –

number of samples in one segment

empty_seg (Number) –

pointer to memory holding one segment of silence samples

state (Number) –

state of the buffer

segdone (Number) –

readpointer in the ringbuffer

segbase (Number) –

segment corresponding to segment 0 (unused)

waiting (Number) –

is a reader or writer waiting for a free segment


Methods

gst_audio_ring_buffer_acquire

gboolean
gst_audio_ring_buffer_acquire (GstAudioRingBuffer * buf,
                               GstAudioRingBufferSpec * spec)

Allocate the resources for the ringbuffer. This function fills in the data pointer of the ring buffer with a valid GstBuffer to which samples can be written.

Parameters:

buf

the GstAudioRingBuffer to acquire

spec

the specs of the buffer

Returns

TRUE if the device could be acquired, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.acquire

def GstAudio.AudioRingBuffer.acquire (self, spec):
    #python wrapper for 'gst_audio_ring_buffer_acquire'

Allocate the resources for the ringbuffer. This function fills in the data pointer of the ring buffer with a valid Gst.Buffer to which samples can be written.

Parameters:

the specs of the buffer

Returns ( bool ) –

TRUE if the device could be acquired, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.acquire

function GstAudio.AudioRingBuffer.prototype.acquire(spec: GstAudio.AudioRingBufferSpec): {
    // javascript wrapper for 'gst_audio_ring_buffer_acquire'
}

Allocate the resources for the ringbuffer. This function fills in the data pointer of the ring buffer with a valid Gst.Buffer to which samples can be written.

Parameters:

the specs of the buffer

Returns ( Number ) –

TRUE if the device could be acquired, FALSE on error.

MT safe.


gst_audio_ring_buffer_activate

gboolean
gst_audio_ring_buffer_activate (GstAudioRingBuffer * buf,
                                gboolean active)

Activate buf to start or stop pulling data.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to activate

active

the new mode

Returns

TRUE if the device could be activated in the requested mode, FALSE on error.


GstAudio.AudioRingBuffer.activate

def GstAudio.AudioRingBuffer.activate (self, active):
    #python wrapper for 'gst_audio_ring_buffer_activate'

Activate buf to start or stop pulling data.

MT safe.

Parameters:

active ( bool ) –

the new mode

Returns ( bool ) –

TRUE if the device could be activated in the requested mode, FALSE on error.


GstAudio.AudioRingBuffer.prototype.activate

function GstAudio.AudioRingBuffer.prototype.activate(active: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_activate'
}

Activate buf to start or stop pulling data.

MT safe.

Parameters:

active ( Number ) –

the new mode

Returns ( Number ) –

TRUE if the device could be activated in the requested mode, FALSE on error.


gst_audio_ring_buffer_advance

gst_audio_ring_buffer_advance (GstAudioRingBuffer * buf,
                               guint advance)

Subclasses should call this function to notify the fact that advance segments are now processed by the device.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to advance

advance

the number of segments written


GstAudio.AudioRingBuffer.advance

def GstAudio.AudioRingBuffer.advance (self, advance):
    #python wrapper for 'gst_audio_ring_buffer_advance'

Subclasses should call this function to notify the fact that advance segments are now processed by the device.

MT safe.

Parameters:

advance ( int ) –

the number of segments written


GstAudio.AudioRingBuffer.prototype.advance

function GstAudio.AudioRingBuffer.prototype.advance(advance: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_advance'
}

Subclasses should call this function to notify the fact that advance segments are now processed by the device.

MT safe.

Parameters:

advance ( Number ) –

the number of segments written


gst_audio_ring_buffer_clear

gst_audio_ring_buffer_clear (GstAudioRingBuffer * buf,
                             gint segment)

Clear the given segment of the buffer with silence samples. This function is used by subclasses.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to clear

segment

the segment to clear


GstAudio.AudioRingBuffer.clear

def GstAudio.AudioRingBuffer.clear (self, segment):
    #python wrapper for 'gst_audio_ring_buffer_clear'

Clear the given segment of the buffer with silence samples. This function is used by subclasses.

MT safe.

Parameters:

segment ( int ) –

the segment to clear


GstAudio.AudioRingBuffer.prototype.clear

function GstAudio.AudioRingBuffer.prototype.clear(segment: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_clear'
}

Clear the given segment of the buffer with silence samples. This function is used by subclasses.

MT safe.

Parameters:

segment ( Number ) –

the segment to clear


gst_audio_ring_buffer_clear_all

gst_audio_ring_buffer_clear_all (GstAudioRingBuffer * buf)

Clear all samples from the ringbuffer.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to clear


GstAudio.AudioRingBuffer.clear_all

def GstAudio.AudioRingBuffer.clear_all (self):
    #python wrapper for 'gst_audio_ring_buffer_clear_all'

Clear all samples from the ringbuffer.

MT safe.

Parameters:


GstAudio.AudioRingBuffer.prototype.clear_all

function GstAudio.AudioRingBuffer.prototype.clear_all(): {
    // javascript wrapper for 'gst_audio_ring_buffer_clear_all'
}

Clear all samples from the ringbuffer.

MT safe.

Parameters:


gst_audio_ring_buffer_close_device

gboolean
gst_audio_ring_buffer_close_device (GstAudioRingBuffer * buf)

Close the audio device associated with the ring buffer. The ring buffer should already have been released via gst_audio_ring_buffer_release.

Parameters:

buf

the GstAudioRingBuffer

Returns

TRUE if the device could be closed, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.close_device

def GstAudio.AudioRingBuffer.close_device (self):
    #python wrapper for 'gst_audio_ring_buffer_close_device'

Close the audio device associated with the ring buffer. The ring buffer should already have been released via GstAudio.AudioRingBuffer.release.

Returns ( bool ) –

TRUE if the device could be closed, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.close_device

function GstAudio.AudioRingBuffer.prototype.close_device(): {
    // javascript wrapper for 'gst_audio_ring_buffer_close_device'
}

Close the audio device associated with the ring buffer. The ring buffer should already have been released via GstAudio.AudioRingBuffer.prototype.release.

Returns ( Number ) –

TRUE if the device could be closed, FALSE on error.

MT safe.


gst_audio_ring_buffer_commit

guint
gst_audio_ring_buffer_commit (GstAudioRingBuffer * buf,
                              guint64 * sample,
                              guint8 * data,
                              gint in_samples,
                              gint out_samples,
                              gint * accum)

Commit in_samples samples pointed to by data to the ringbuffer buf.

in_samples and out_samples define the rate conversion to perform on the samples in data. For negative rates, out_samples must be negative and in_samples positive.

When out_samples is positive, the first sample will be written at position sample in the ringbuffer. When out_samples is negative, the last sample will be written to sample in reverse order.

out_samples does not need to be a multiple of the segment size of the ringbuffer although it is recommended for optimal performance.

accum will hold a temporary accumulator used in rate conversion and should be set to 0 when this function is first called. In case the commit operation is interrupted, one can resume the processing by passing the previously returned accum value back to this function.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to commit

sample

the sample position of the data

data ( [array length=in_samples] ) –

the data to commit

in_samples

the number of samples in the data to commit

out_samples

the number of samples to write to the ringbuffer

accum ( [inout] ) –

accumulator for rate conversion.

Returns

The number of samples written to the ringbuffer or -1 on error. The number of samples written can be less than out_samples when buf was interrupted with a flush or stop.


GstAudio.AudioRingBuffer.commit

def GstAudio.AudioRingBuffer.commit (self, sample, data, in_samples, out_samples, accum):
    #python wrapper for 'gst_audio_ring_buffer_commit'

Commit in_samples samples pointed to by data to the ringbuffer buf.

in_samples and out_samples define the rate conversion to perform on the samples in data. For negative rates, out_samples must be negative and in_samples positive.

When out_samples is positive, the first sample will be written at position sample in the ringbuffer. When out_samples is negative, the last sample will be written to sample in reverse order.

out_samples does not need to be a multiple of the segment size of the ringbuffer although it is recommended for optimal performance.

accum will hold a temporary accumulator used in rate conversion and should be set to 0 when this function is first called. In case the commit operation is interrupted, one can resume the processing by passing the previously returned accum value back to this function.

MT safe.

Parameters:

sample ( int ) –

the sample position of the data

data ( [ int ] ) –

the data to commit

in_samples ( int ) –

the number of samples in the data to commit

out_samples ( int ) –

the number of samples to write to the ringbuffer

accum ( int ) –

accumulator for rate conversion.

Returns a tuple made of:

( int ) –

The number of samples written to the ringbuffer or -1 on error. The number of samples written can be less than out_samples when buf was interrupted with a flush or stop.

accum ( int ) –

The number of samples written to the ringbuffer or -1 on error. The number of samples written can be less than out_samples when buf was interrupted with a flush or stop.


GstAudio.AudioRingBuffer.prototype.commit

function GstAudio.AudioRingBuffer.prototype.commit(sample: Number, data: [ Number ], in_samples: Number, out_samples: Number, accum: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_commit'
}

Commit in_samples samples pointed to by data to the ringbuffer buf.

in_samples and out_samples define the rate conversion to perform on the samples in data. For negative rates, out_samples must be negative and in_samples positive.

When out_samples is positive, the first sample will be written at position sample in the ringbuffer. When out_samples is negative, the last sample will be written to sample in reverse order.

out_samples does not need to be a multiple of the segment size of the ringbuffer although it is recommended for optimal performance.

accum will hold a temporary accumulator used in rate conversion and should be set to 0 when this function is first called. In case the commit operation is interrupted, one can resume the processing by passing the previously returned accum value back to this function.

MT safe.

Parameters:

sample ( Number ) –

the sample position of the data

data ( [ Number ] ) –

the data to commit

in_samples ( Number ) –

the number of samples in the data to commit

out_samples ( Number ) –

the number of samples to write to the ringbuffer

accum ( Number ) –

accumulator for rate conversion.

Returns a tuple made of:

( Number ) –

The number of samples written to the ringbuffer or -1 on error. The number of samples written can be less than out_samples when buf was interrupted with a flush or stop.

accum ( Number ) –

The number of samples written to the ringbuffer or -1 on error. The number of samples written can be less than out_samples when buf was interrupted with a flush or stop.


gst_audio_ring_buffer_convert

gboolean
gst_audio_ring_buffer_convert (GstAudioRingBuffer * buf,
                               GstFormat src_fmt,
                               gint64 src_val,
                               GstFormat dest_fmt,
                               gint64 * dest_val)

Convert src_val in src_fmt to the equivalent value in dest_fmt. The result will be put in dest_val.

Parameters:

buf

the GstAudioRingBuffer

src_fmt

the source format

src_val

the source value

dest_fmt

the destination format

dest_val ( [out] ) –

a location to store the converted value

Returns

TRUE if the conversion succeeded.


GstAudio.AudioRingBuffer.convert

def GstAudio.AudioRingBuffer.convert (self, src_fmt, src_val, dest_fmt):
    #python wrapper for 'gst_audio_ring_buffer_convert'

Convert src_val in src_fmt to the equivalent value in dest_fmt. The result will be put in dest_val.

Parameters:

src_fmt ( Gst.Format ) –

the source format

src_val ( int ) –

the source value

dest_fmt ( Gst.Format ) –

the destination format

Returns a tuple made of:

( bool ) –

TRUE if the conversion succeeded.

dest_val ( int ) –

TRUE if the conversion succeeded.


GstAudio.AudioRingBuffer.prototype.convert

function GstAudio.AudioRingBuffer.prototype.convert(src_fmt: Gst.Format, src_val: Number, dest_fmt: Gst.Format): {
    // javascript wrapper for 'gst_audio_ring_buffer_convert'
}

Convert src_val in src_fmt to the equivalent value in dest_fmt. The result will be put in dest_val.

Parameters:

src_fmt ( Gst.Format ) –

the source format

src_val ( Number ) –

the source value

dest_fmt ( Gst.Format ) –

the destination format

Returns a tuple made of:

( Number ) –

TRUE if the conversion succeeded.

dest_val ( Number ) –

TRUE if the conversion succeeded.


gst_audio_ring_buffer_delay

guint
gst_audio_ring_buffer_delay (GstAudioRingBuffer * buf)

Get the number of samples queued in the audio device. This is usually less than the segment size but can be bigger when the implementation uses another internal buffer between the audio device.

For playback ringbuffers this is the amount of samples transferred from the ringbuffer to the device but still not played.

For capture ringbuffers this is the amount of samples in the device that are not yet transferred to the ringbuffer.

Parameters:

buf

the GstAudioRingBuffer to query

Returns

The number of samples queued in the audio device.

MT safe.


GstAudio.AudioRingBuffer.delay

def GstAudio.AudioRingBuffer.delay (self):
    #python wrapper for 'gst_audio_ring_buffer_delay'

Get the number of samples queued in the audio device. This is usually less than the segment size but can be bigger when the implementation uses another internal buffer between the audio device.

For playback ringbuffers this is the amount of samples transferred from the ringbuffer to the device but still not played.

For capture ringbuffers this is the amount of samples in the device that are not yet transferred to the ringbuffer.

Parameters:

Returns ( int ) –

The number of samples queued in the audio device.

MT safe.


GstAudio.AudioRingBuffer.prototype.delay

function GstAudio.AudioRingBuffer.prototype.delay(): {
    // javascript wrapper for 'gst_audio_ring_buffer_delay'
}

Get the number of samples queued in the audio device. This is usually less than the segment size but can be bigger when the implementation uses another internal buffer between the audio device.

For playback ringbuffers this is the amount of samples transferred from the ringbuffer to the device but still not played.

For capture ringbuffers this is the amount of samples in the device that are not yet transferred to the ringbuffer.

Parameters:

Returns ( Number ) –

The number of samples queued in the audio device.

MT safe.


gst_audio_ring_buffer_device_is_open

gboolean
gst_audio_ring_buffer_device_is_open (GstAudioRingBuffer * buf)

Checks the status of the device associated with the ring buffer.

Parameters:

buf

the GstAudioRingBuffer

Returns

TRUE if the device was open, FALSE if it was closed.

MT safe.


GstAudio.AudioRingBuffer.device_is_open

def GstAudio.AudioRingBuffer.device_is_open (self):
    #python wrapper for 'gst_audio_ring_buffer_device_is_open'

Checks the status of the device associated with the ring buffer.

Returns ( bool ) –

TRUE if the device was open, FALSE if it was closed.

MT safe.


GstAudio.AudioRingBuffer.prototype.device_is_open

function GstAudio.AudioRingBuffer.prototype.device_is_open(): {
    // javascript wrapper for 'gst_audio_ring_buffer_device_is_open'
}

Checks the status of the device associated with the ring buffer.

Returns ( Number ) –

TRUE if the device was open, FALSE if it was closed.

MT safe.


gst_audio_ring_buffer_is_acquired

gboolean
gst_audio_ring_buffer_is_acquired (GstAudioRingBuffer * buf)

Check if the ringbuffer is acquired and ready to use.

Parameters:

buf

the GstAudioRingBuffer to check

Returns

TRUE if the ringbuffer is acquired, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.is_acquired

def GstAudio.AudioRingBuffer.is_acquired (self):
    #python wrapper for 'gst_audio_ring_buffer_is_acquired'

Check if the ringbuffer is acquired and ready to use.

Parameters:

Returns ( bool ) –

TRUE if the ringbuffer is acquired, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.is_acquired

function GstAudio.AudioRingBuffer.prototype.is_acquired(): {
    // javascript wrapper for 'gst_audio_ring_buffer_is_acquired'
}

Check if the ringbuffer is acquired and ready to use.

Parameters:

Returns ( Number ) –

TRUE if the ringbuffer is acquired, FALSE on error.

MT safe.


gst_audio_ring_buffer_is_active

gboolean
gst_audio_ring_buffer_is_active (GstAudioRingBuffer * buf)

Check if buf is activated.

MT safe.

Parameters:

buf

the GstAudioRingBuffer

Returns

TRUE if the device is active.


GstAudio.AudioRingBuffer.is_active

def GstAudio.AudioRingBuffer.is_active (self):
    #python wrapper for 'gst_audio_ring_buffer_is_active'

Check if buf is activated.

MT safe.

Returns ( bool ) –

TRUE if the device is active.


GstAudio.AudioRingBuffer.prototype.is_active

function GstAudio.AudioRingBuffer.prototype.is_active(): {
    // javascript wrapper for 'gst_audio_ring_buffer_is_active'
}

Check if buf is activated.

MT safe.

Returns ( Number ) –

TRUE if the device is active.


gst_audio_ring_buffer_is_flushing

gboolean
gst_audio_ring_buffer_is_flushing (GstAudioRingBuffer * buf)

Check if buf is flushing.

MT safe.

Parameters:

buf

the GstAudioRingBuffer

Returns

TRUE if the device is flushing.


GstAudio.AudioRingBuffer.is_flushing

def GstAudio.AudioRingBuffer.is_flushing (self):
    #python wrapper for 'gst_audio_ring_buffer_is_flushing'

Check if buf is flushing.

MT safe.

Returns ( bool ) –

TRUE if the device is flushing.


GstAudio.AudioRingBuffer.prototype.is_flushing

function GstAudio.AudioRingBuffer.prototype.is_flushing(): {
    // javascript wrapper for 'gst_audio_ring_buffer_is_flushing'
}

Check if buf is flushing.

MT safe.

Returns ( Number ) –

TRUE if the device is flushing.


gst_audio_ring_buffer_may_start

gst_audio_ring_buffer_may_start (GstAudioRingBuffer * buf,
                                 gboolean allowed)

Tell the ringbuffer that it is allowed to start playback when the ringbuffer is filled with samples.

MT safe.

Parameters:

buf

the GstAudioRingBuffer

allowed

the new value


GstAudio.AudioRingBuffer.may_start

def GstAudio.AudioRingBuffer.may_start (self, allowed):
    #python wrapper for 'gst_audio_ring_buffer_may_start'

Tell the ringbuffer that it is allowed to start playback when the ringbuffer is filled with samples.

MT safe.

Parameters:

allowed ( bool ) –

the new value


GstAudio.AudioRingBuffer.prototype.may_start

function GstAudio.AudioRingBuffer.prototype.may_start(allowed: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_may_start'
}

Tell the ringbuffer that it is allowed to start playback when the ringbuffer is filled with samples.

MT safe.

Parameters:

allowed ( Number ) –

the new value


gst_audio_ring_buffer_open_device

gboolean
gst_audio_ring_buffer_open_device (GstAudioRingBuffer * buf)

Open the audio device associated with the ring buffer. Does not perform any setup on the device. You must open the device before acquiring the ring buffer.

Parameters:

buf

the GstAudioRingBuffer

Returns

TRUE if the device could be opened, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.open_device

def GstAudio.AudioRingBuffer.open_device (self):
    #python wrapper for 'gst_audio_ring_buffer_open_device'

Open the audio device associated with the ring buffer. Does not perform any setup on the device. You must open the device before acquiring the ring buffer.

Returns ( bool ) –

TRUE if the device could be opened, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.open_device

function GstAudio.AudioRingBuffer.prototype.open_device(): {
    // javascript wrapper for 'gst_audio_ring_buffer_open_device'
}

Open the audio device associated with the ring buffer. Does not perform any setup on the device. You must open the device before acquiring the ring buffer.

Returns ( Number ) –

TRUE if the device could be opened, FALSE on error.

MT safe.


gst_audio_ring_buffer_pause

gboolean
gst_audio_ring_buffer_pause (GstAudioRingBuffer * buf)

Pause processing samples from the ringbuffer.

Parameters:

buf

the GstAudioRingBuffer to pause

Returns

TRUE if the device could be paused, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.pause

def GstAudio.AudioRingBuffer.pause (self):
    #python wrapper for 'gst_audio_ring_buffer_pause'

Pause processing samples from the ringbuffer.

Parameters:

Returns ( bool ) –

TRUE if the device could be paused, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.pause

function GstAudio.AudioRingBuffer.prototype.pause(): {
    // javascript wrapper for 'gst_audio_ring_buffer_pause'
}

Pause processing samples from the ringbuffer.

Parameters:

Returns ( Number ) –

TRUE if the device could be paused, FALSE on error.

MT safe.


gst_audio_ring_buffer_prepare_read

gboolean
gst_audio_ring_buffer_prepare_read (GstAudioRingBuffer * buf,
                                    gint * segment,
                                    guint8 ** readptr,
                                    gint * len)

Returns a pointer to memory where the data from segment segment can be found. This function is mostly used by subclasses.

Parameters:

buf

the GstAudioRingBuffer to read from

segment ( [out] ) –

the segment to read

readptr

(out) (array length=len): the pointer to the memory where samples can be read

len ( [out] ) –

the number of bytes to read

Returns

FALSE if the buffer is not started.

MT safe.


GstAudio.AudioRingBuffer.prepare_read

def GstAudio.AudioRingBuffer.prepare_read (self):
    #python wrapper for 'gst_audio_ring_buffer_prepare_read'

Returns a pointer to memory where the data from segment segment can be found. This function is mostly used by subclasses.

Parameters:

the GstAudio.AudioRingBuffer to read from

Returns a tuple made of:

( bool ) –

FALSE if the buffer is not started.

MT safe.

segment ( int ) –

FALSE if the buffer is not started.

MT safe.

readptr ( [ int ] ) –

FALSE if the buffer is not started.

MT safe.

len ( int ) –

FALSE if the buffer is not started.

MT safe.


GstAudio.AudioRingBuffer.prototype.prepare_read

function GstAudio.AudioRingBuffer.prototype.prepare_read(): {
    // javascript wrapper for 'gst_audio_ring_buffer_prepare_read'
}

Returns a pointer to memory where the data from segment segment can be found. This function is mostly used by subclasses.

Parameters:

the GstAudio.AudioRingBuffer to read from

Returns a tuple made of:

( Number ) –

FALSE if the buffer is not started.

MT safe.

segment ( Number ) –

FALSE if the buffer is not started.

MT safe.

readptr ( [ Number ] ) –

FALSE if the buffer is not started.

MT safe.

len ( Number ) –

FALSE if the buffer is not started.

MT safe.


gst_audio_ring_buffer_read

guint
gst_audio_ring_buffer_read (GstAudioRingBuffer * buf,
                            guint64 sample,
                            guint8 * data,
                            guint len,
                            GstClockTime * timestamp)

Read len samples from the ringbuffer into the memory pointed to by data. The first sample should be read from position sample in the ringbuffer.

len should not be a multiple of the segment size of the ringbuffer although it is recommended.

timestamp will return the timestamp associated with the data returned.

Parameters:

buf

the GstAudioRingBuffer to read from

sample

the sample position of the data

data ( [array length=len] ) –

where the data should be read

len

the number of samples in data to read

timestamp ( [out] ) –

where the timestamp is returned

Returns

The number of samples read from the ringbuffer or -1 on error.

MT safe.


GstAudio.AudioRingBuffer.read

def GstAudio.AudioRingBuffer.read (self, sample, data, len):
    #python wrapper for 'gst_audio_ring_buffer_read'

Read len samples from the ringbuffer into the memory pointed to by data. The first sample should be read from position sample in the ringbuffer.

len should not be a multiple of the segment size of the ringbuffer although it is recommended.

timestamp will return the timestamp associated with the data returned.

Parameters:

the GstAudio.AudioRingBuffer to read from

sample ( int ) –

the sample position of the data

data ( [ int ] ) –

where the data should be read

len ( int ) –

the number of samples in data to read

Returns a tuple made of:

( int ) –

The number of samples read from the ringbuffer or -1 on error.

MT safe.

timestamp ( int ) –

The number of samples read from the ringbuffer or -1 on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.read

function GstAudio.AudioRingBuffer.prototype.read(sample: Number, data: [ Number ], len: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_read'
}

Read len samples from the ringbuffer into the memory pointed to by data. The first sample should be read from position sample in the ringbuffer.

len should not be a multiple of the segment size of the ringbuffer although it is recommended.

timestamp will return the timestamp associated with the data returned.

Parameters:

the GstAudio.AudioRingBuffer to read from

sample ( Number ) –

the sample position of the data

data ( [ Number ] ) –

where the data should be read

len ( Number ) –

the number of samples in data to read

Returns a tuple made of:

( Number ) –

The number of samples read from the ringbuffer or -1 on error.

MT safe.

timestamp ( Number ) –

The number of samples read from the ringbuffer or -1 on error.

MT safe.


gst_audio_ring_buffer_release

gboolean
gst_audio_ring_buffer_release (GstAudioRingBuffer * buf)

Free the resources of the ringbuffer.

Parameters:

buf

the GstAudioRingBuffer to release

Returns

TRUE if the device could be released, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.release

def GstAudio.AudioRingBuffer.release (self):
    #python wrapper for 'gst_audio_ring_buffer_release'

Free the resources of the ringbuffer.

Parameters:

Returns ( bool ) –

TRUE if the device could be released, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.release

function GstAudio.AudioRingBuffer.prototype.release(): {
    // javascript wrapper for 'gst_audio_ring_buffer_release'
}

Free the resources of the ringbuffer.

Parameters:

Returns ( Number ) –

TRUE if the device could be released, FALSE on error.

MT safe.


gst_audio_ring_buffer_samples_done

guint64
gst_audio_ring_buffer_samples_done (GstAudioRingBuffer * buf)

Get the number of samples that were processed by the ringbuffer since it was last started. This does not include the number of samples not yet processed (see gst_audio_ring_buffer_delay).

Parameters:

buf

the GstAudioRingBuffer to query

Returns

The number of samples processed by the ringbuffer.

MT safe.


GstAudio.AudioRingBuffer.samples_done

def GstAudio.AudioRingBuffer.samples_done (self):
    #python wrapper for 'gst_audio_ring_buffer_samples_done'

Get the number of samples that were processed by the ringbuffer since it was last started. This does not include the number of samples not yet processed (see GstAudio.AudioRingBuffer.delay).

Parameters:

Returns ( int ) –

The number of samples processed by the ringbuffer.

MT safe.


GstAudio.AudioRingBuffer.prototype.samples_done

function GstAudio.AudioRingBuffer.prototype.samples_done(): {
    // javascript wrapper for 'gst_audio_ring_buffer_samples_done'
}

Get the number of samples that were processed by the ringbuffer since it was last started. This does not include the number of samples not yet processed (see GstAudio.AudioRingBuffer.prototype.delay).

Parameters:

Returns ( Number ) –

The number of samples processed by the ringbuffer.

MT safe.


gst_audio_ring_buffer_set_callback

gst_audio_ring_buffer_set_callback (GstAudioRingBuffer * buf,
                                    GstAudioRingBufferCallback cb,
                                    gpointer user_data)

Sets the given callback function on the buffer. This function will be called every time a segment has been written to a device.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to set the callback on

cb ( [allow-none] ) –

the callback to set

user_data

user data passed to the callback


gst_audio_ring_buffer_set_callback_full

gst_audio_ring_buffer_set_callback_full (GstAudioRingBuffer * buf,
                                         GstAudioRingBufferCallback cb,
                                         gpointer user_data,
                                         GDestroyNotify notify)

Sets the given callback function on the buffer. This function will be called every time a segment has been written to a device.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to set the callback on

cb ( [allow-none] ) –

the callback to set

user_data

user data passed to the callback

notify

function to be called when user_data is no longer needed

Since : 1.12


GstAudio.AudioRingBuffer.set_callback_full

def GstAudio.AudioRingBuffer.set_callback_full (self, cb, *user_data):
    #python wrapper for 'gst_audio_ring_buffer_set_callback_full'

Sets the given callback function on the buffer. This function will be called every time a segment has been written to a device.

MT safe.

Parameters:

the GstAudio.AudioRingBuffer to set the callback on

the callback to set

user_data ( variadic ) –

user data passed to the callback

Since : 1.12


GstAudio.AudioRingBuffer.prototype.set_callback_full

function GstAudio.AudioRingBuffer.prototype.set_callback_full(cb: GstAudio.AudioRingBufferCallback, user_data: Object): {
    // javascript wrapper for 'gst_audio_ring_buffer_set_callback_full'
}

Sets the given callback function on the buffer. This function will be called every time a segment has been written to a device.

MT safe.

Parameters:

the GstAudio.AudioRingBuffer to set the callback on

the callback to set

user_data ( Object ) –

user data passed to the callback

Since : 1.12


gst_audio_ring_buffer_set_channel_positions

gst_audio_ring_buffer_set_channel_positions (GstAudioRingBuffer * buf,
                                             const GstAudioChannelPosition * position)

Tell the ringbuffer about the device's channel positions. This must be called in when the ringbuffer is acquired.

Parameters:

buf

the GstAudioRingBuffer

position ( [array] ) –

the device channel positions


GstAudio.AudioRingBuffer.set_channel_positions

def GstAudio.AudioRingBuffer.set_channel_positions (self, position):
    #python wrapper for 'gst_audio_ring_buffer_set_channel_positions'

Tell the ringbuffer about the device's channel positions. This must be called in when the ringbuffer is acquired.

Parameters:

position ( [ GstAudio.AudioChannelPosition ] ) –

the device channel positions


GstAudio.AudioRingBuffer.prototype.set_channel_positions

function GstAudio.AudioRingBuffer.prototype.set_channel_positions(position: [ GstAudio.AudioChannelPosition ]): {
    // javascript wrapper for 'gst_audio_ring_buffer_set_channel_positions'
}

Tell the ringbuffer about the device's channel positions. This must be called in when the ringbuffer is acquired.

Parameters:

position ( [ GstAudio.AudioChannelPosition ] ) –

the device channel positions


gst_audio_ring_buffer_set_flushing

gst_audio_ring_buffer_set_flushing (GstAudioRingBuffer * buf,
                                    gboolean flushing)

Set the ringbuffer to flushing mode or normal mode.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to flush

flushing

the new mode


GstAudio.AudioRingBuffer.set_flushing

def GstAudio.AudioRingBuffer.set_flushing (self, flushing):
    #python wrapper for 'gst_audio_ring_buffer_set_flushing'

Set the ringbuffer to flushing mode or normal mode.

MT safe.

Parameters:

flushing ( bool ) –

the new mode


GstAudio.AudioRingBuffer.prototype.set_flushing

function GstAudio.AudioRingBuffer.prototype.set_flushing(flushing: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_set_flushing'
}

Set the ringbuffer to flushing mode or normal mode.

MT safe.

Parameters:

flushing ( Number ) –

the new mode


gst_audio_ring_buffer_set_sample

gst_audio_ring_buffer_set_sample (GstAudioRingBuffer * buf,
                                  guint64 sample)

Make sure that the next sample written to the device is accounted for as being the sample sample written to the device. This value will be used in reporting the current sample position of the ringbuffer.

This function will also clear the buffer with silence.

MT safe.

Parameters:

buf

the GstAudioRingBuffer to use

sample

the sample number to set


GstAudio.AudioRingBuffer.set_sample

def GstAudio.AudioRingBuffer.set_sample (self, sample):
    #python wrapper for 'gst_audio_ring_buffer_set_sample'

Make sure that the next sample written to the device is accounted for as being the sample sample written to the device. This value will be used in reporting the current sample position of the ringbuffer.

This function will also clear the buffer with silence.

MT safe.

Parameters:

sample ( int ) –

the sample number to set


GstAudio.AudioRingBuffer.prototype.set_sample

function GstAudio.AudioRingBuffer.prototype.set_sample(sample: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_set_sample'
}

Make sure that the next sample written to the device is accounted for as being the sample sample written to the device. This value will be used in reporting the current sample position of the ringbuffer.

This function will also clear the buffer with silence.

MT safe.

Parameters:

sample ( Number ) –

the sample number to set


gst_audio_ring_buffer_set_timestamp

gst_audio_ring_buffer_set_timestamp (GstAudioRingBuffer * buf,
                                     gint readseg,
                                     GstClockTime timestamp)

Parameters:

buf
No description available
readseg
No description available
timestamp
No description available

GstAudio.AudioRingBuffer.set_timestamp

def GstAudio.AudioRingBuffer.set_timestamp (self, readseg, timestamp):
    #python wrapper for 'gst_audio_ring_buffer_set_timestamp'

Parameters:

No description available
readseg ( int ) –
No description available
timestamp ( int ) –
No description available

GstAudio.AudioRingBuffer.prototype.set_timestamp

function GstAudio.AudioRingBuffer.prototype.set_timestamp(readseg: Number, timestamp: Number): {
    // javascript wrapper for 'gst_audio_ring_buffer_set_timestamp'
}

Parameters:

No description available
readseg ( Number ) –
No description available
timestamp ( Number ) –
No description available

gst_audio_ring_buffer_start

gboolean
gst_audio_ring_buffer_start (GstAudioRingBuffer * buf)

Start processing samples from the ringbuffer.

Parameters:

buf

the GstAudioRingBuffer to start

Returns

TRUE if the device could be started, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.start

def GstAudio.AudioRingBuffer.start (self):
    #python wrapper for 'gst_audio_ring_buffer_start'

Start processing samples from the ringbuffer.

Parameters:

Returns ( bool ) –

TRUE if the device could be started, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.start

function GstAudio.AudioRingBuffer.prototype.start(): {
    // javascript wrapper for 'gst_audio_ring_buffer_start'
}

Start processing samples from the ringbuffer.

Parameters:

Returns ( Number ) –

TRUE if the device could be started, FALSE on error.

MT safe.


gst_audio_ring_buffer_stop

gboolean
gst_audio_ring_buffer_stop (GstAudioRingBuffer * buf)

Stop processing samples from the ringbuffer.

Parameters:

buf

the GstAudioRingBuffer to stop

Returns

TRUE if the device could be stopped, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.stop

def GstAudio.AudioRingBuffer.stop (self):
    #python wrapper for 'gst_audio_ring_buffer_stop'

Stop processing samples from the ringbuffer.

Parameters:

Returns ( bool ) –

TRUE if the device could be stopped, FALSE on error.

MT safe.


GstAudio.AudioRingBuffer.prototype.stop

function GstAudio.AudioRingBuffer.prototype.stop(): {
    // javascript wrapper for 'gst_audio_ring_buffer_stop'
}

Stop processing samples from the ringbuffer.

Parameters:

Returns ( Number ) –

TRUE if the device could be stopped, FALSE on error.

MT safe.


Functions

gst_audio_ring_buffer_debug_spec_buff

gst_audio_ring_buffer_debug_spec_buff (GstAudioRingBufferSpec * spec)

Print debug info about the buffer sized in spec to the debug log.

Parameters:

spec

the spec to debug


GstAudio.AudioRingBuffer.debug_spec_buff

def GstAudio.AudioRingBuffer.debug_spec_buff (spec):
    #python wrapper for 'gst_audio_ring_buffer_debug_spec_buff'

Print debug info about the buffer sized in spec to the debug log.

Parameters:

the spec to debug


GstAudio.AudioRingBuffer.prototype.debug_spec_buff

function GstAudio.AudioRingBuffer.prototype.debug_spec_buff(spec: GstAudio.AudioRingBufferSpec): {
    // javascript wrapper for 'gst_audio_ring_buffer_debug_spec_buff'
}

Print debug info about the buffer sized in spec to the debug log.

Parameters:

the spec to debug


gst_audio_ring_buffer_debug_spec_caps

gst_audio_ring_buffer_debug_spec_caps (GstAudioRingBufferSpec * spec)

Print debug info about the parsed caps in spec to the debug log.

Parameters:

spec

the spec to debug


GstAudio.AudioRingBuffer.debug_spec_caps

def GstAudio.AudioRingBuffer.debug_spec_caps (spec):
    #python wrapper for 'gst_audio_ring_buffer_debug_spec_caps'

Print debug info about the parsed caps in spec to the debug log.

Parameters:

the spec to debug


GstAudio.AudioRingBuffer.prototype.debug_spec_caps

function GstAudio.AudioRingBuffer.prototype.debug_spec_caps(spec: GstAudio.AudioRingBufferSpec): {
    // javascript wrapper for 'gst_audio_ring_buffer_debug_spec_caps'
}

Print debug info about the parsed caps in spec to the debug log.

Parameters:

the spec to debug


gst_audio_ring_buffer_parse_caps

gboolean
gst_audio_ring_buffer_parse_caps (GstAudioRingBufferSpec * spec,
                                  GstCaps * caps)

Parse caps into spec.

Parameters:

spec

a spec

caps

a GstCaps

Returns

TRUE if the caps could be parsed.


GstAudio.AudioRingBuffer.parse_caps

def GstAudio.AudioRingBuffer.parse_caps (spec, caps):
    #python wrapper for 'gst_audio_ring_buffer_parse_caps'

Parse caps into spec.

Parameters:

a spec

caps ( Gst.Caps ) –

a Gst.Caps

Returns ( bool ) –

TRUE if the caps could be parsed.


GstAudio.AudioRingBuffer.prototype.parse_caps

function GstAudio.AudioRingBuffer.prototype.parse_caps(spec: GstAudio.AudioRingBufferSpec, caps: Gst.Caps): {
    // javascript wrapper for 'gst_audio_ring_buffer_parse_caps'
}

Parse caps into spec.

Parameters:

a spec

caps ( Gst.Caps ) –

a Gst.Caps

Returns ( Number ) –

TRUE if the caps could be parsed.


Virtual Methods

acquire

gboolean
acquire (GstAudioRingBuffer * buf,
         GstAudioRingBufferSpec * spec)

allocate the resources for the ringbuffer using the given spec

Parameters:

buf
No description available
spec
No description available
Returns
No description available

do_acquire

def do_acquire (buf, spec):
    #python implementation of the 'acquire' virtual method

allocate the resources for the ringbuffer using the given spec

Parameters:

No description available
No description available
Returns ( bool ) –
No description available

vfunc_acquire

function vfunc_acquire(buf: GstAudio.AudioRingBuffer, spec: GstAudio.AudioRingBufferSpec): {
    // javascript implementation of the 'acquire' virtual method
}

allocate the resources for the ringbuffer using the given spec

Parameters:

No description available
No description available
Returns ( Number ) –
No description available

activate

gboolean
activate (GstAudioRingBuffer * buf,
          gboolean active)

activate the thread that starts pulling and monitoring the consumed segments in the device.

Parameters:

buf
No description available
active
No description available
Returns
No description available

do_activate

def do_activate (buf, active):
    #python implementation of the 'activate' virtual method

activate the thread that starts pulling and monitoring the consumed segments in the device.

Parameters:

No description available
active ( bool ) –
No description available
Returns ( bool ) –
No description available

vfunc_activate

function vfunc_activate(buf: GstAudio.AudioRingBuffer, active: Number): {
    // javascript implementation of the 'activate' virtual method
}

activate the thread that starts pulling and monitoring the consumed segments in the device.

Parameters:

No description available
active ( Number ) –
No description available
Returns ( Number ) –
No description available

clear_all

clear_all (GstAudioRingBuffer * buf)

Optional. Clear the entire ringbuffer. Subclasses should chain up to the parent implementation to invoke the default handler.

Parameters:

buf
No description available

do_clear_all

def do_clear_all (buf):
    #python implementation of the 'clear_all' virtual method

Optional. Clear the entire ringbuffer. Subclasses should chain up to the parent implementation to invoke the default handler.

Parameters:

No description available

vfunc_clear_all

function vfunc_clear_all(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'clear_all' virtual method
}

Optional. Clear the entire ringbuffer. Subclasses should chain up to the parent implementation to invoke the default handler.

Parameters:

No description available

close_device

gboolean
close_device (GstAudioRingBuffer * buf)

close the device

Parameters:

buf
No description available
Returns
No description available

do_close_device

def do_close_device (buf):
    #python implementation of the 'close_device' virtual method

close the device

Parameters:

No description available
Returns ( bool ) –
No description available

vfunc_close_device

function vfunc_close_device(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'close_device' virtual method
}

close the device

Parameters:

No description available
Returns ( Number ) –
No description available

commit

guint
commit (GstAudioRingBuffer * buf,
        guint64 * sample,
        guint8 * data,
        gint in_samples,
        gint out_samples,
        gint * accum)

write samples into the ringbuffer

Parameters:

buf
No description available
sample
No description available
data
No description available
in_samples
No description available
out_samples
No description available
accum
No description available
Returns
No description available

do_commit

def do_commit (buf, sample, data, in_samples, out_samples, accum):
    #python implementation of the 'commit' virtual method

write samples into the ringbuffer

Parameters:

No description available
sample ( int ) –
No description available
data ( [ int ] ) –
No description available
in_samples ( int ) –
No description available
out_samples ( int ) –
No description available
accum ( int ) –
No description available

Returns a tuple made of:

( int ) –
No description available
accum ( int ) –
No description available

vfunc_commit

function vfunc_commit(buf: GstAudio.AudioRingBuffer, sample: Number, data: [ Number ], in_samples: Number, out_samples: Number, accum: Number): {
    // javascript implementation of the 'commit' virtual method
}

write samples into the ringbuffer

Parameters:

No description available
sample ( Number ) –
No description available
data ( [ Number ] ) –
No description available
in_samples ( Number ) –
No description available
out_samples ( Number ) –
No description available
accum ( Number ) –
No description available

Returns a tuple made of:

( Number ) –
No description available
accum ( Number ) –
No description available

delay

guint
delay (GstAudioRingBuffer * buf)

get number of frames queued in device

Parameters:

buf
No description available
Returns
No description available

do_delay

def do_delay (buf):
    #python implementation of the 'delay' virtual method

get number of frames queued in device

Parameters:

No description available
Returns ( int ) –
No description available

vfunc_delay

function vfunc_delay(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'delay' virtual method
}

get number of frames queued in device

Parameters:

No description available
Returns ( Number ) –
No description available

open_device

gboolean
open_device (GstAudioRingBuffer * buf)

open the device, don't set any params or allocate anything

Parameters:

buf
No description available
Returns
No description available

do_open_device

def do_open_device (buf):
    #python implementation of the 'open_device' virtual method

open the device, don't set any params or allocate anything

Parameters:

No description available
Returns ( bool ) –
No description available

vfunc_open_device

function vfunc_open_device(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'open_device' virtual method
}

open the device, don't set any params or allocate anything

Parameters:

No description available
Returns ( Number ) –
No description available

pause

gboolean
pause (GstAudioRingBuffer * buf)

pause processing of samples

Parameters:

buf
No description available
Returns
No description available

do_pause

def do_pause (buf):
    #python implementation of the 'pause' virtual method

pause processing of samples

Parameters:

No description available
Returns ( bool ) –
No description available

vfunc_pause

function vfunc_pause(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'pause' virtual method
}

pause processing of samples

Parameters:

No description available
Returns ( Number ) –
No description available

release

gboolean
release (GstAudioRingBuffer * buf)

free resources of the ringbuffer

Parameters:

buf
No description available
Returns
No description available

do_release

def do_release (buf):
    #python implementation of the 'release' virtual method

free resources of the ringbuffer

Parameters:

No description available
Returns ( bool ) –
No description available

vfunc_release

function vfunc_release(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'release' virtual method
}

free resources of the ringbuffer

Parameters:

No description available
Returns ( Number ) –
No description available

resume

gboolean
resume (GstAudioRingBuffer * buf)

resume processing of samples after pause

Parameters:

buf
No description available
Returns
No description available

do_resume

def do_resume (buf):
    #python implementation of the 'resume' virtual method

resume processing of samples after pause

Parameters:

No description available
Returns ( bool ) –
No description available

vfunc_resume

function vfunc_resume(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'resume' virtual method
}

resume processing of samples after pause

Parameters:

No description available
Returns ( Number ) –
No description available

start

gboolean
start (GstAudioRingBuffer * buf)

start processing of samples

Parameters:

buf
No description available
Returns
No description available

do_start

def do_start (buf):
    #python implementation of the 'start' virtual method

start processing of samples

Parameters:

No description available
Returns ( bool ) –
No description available

vfunc_start

function vfunc_start(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'start' virtual method
}

start processing of samples

Parameters:

No description available
Returns ( Number ) –
No description available

stop

gboolean
stop (GstAudioRingBuffer * buf)

stop processing of samples

Parameters:

buf
No description available
Returns
No description available

do_stop

def do_stop (buf):
    #python implementation of the 'stop' virtual method

stop processing of samples

Parameters:

No description available
Returns ( bool ) –
No description available

vfunc_stop

function vfunc_stop(buf: GstAudio.AudioRingBuffer): {
    // javascript implementation of the 'stop' virtual method
}

stop processing of samples

Parameters:

No description available
Returns ( Number ) –
No description available

GstAudioRingBufferSpec

The structure containing the format specification of the ringbuffer.

Members

caps (GstCaps *) –

The caps that generated the Spec.

the sample type

info (GstAudioInfo) –

the GstAudioInfo

latency_time (guint64) –

the latency in microseconds

buffer_time (guint64) –

the total buffer size in microseconds

segsize (gint) –

the size of one segment in bytes

segtotal (gint) –

the total number of segments

seglatency (gint) –

number of segments queued in the lower level device, defaults to segtotal


GstAudio.AudioRingBufferSpec

The structure containing the format specification of the ringbuffer.

Members

caps (Gst.Caps) –

The caps that generated the Spec.

the sample type

latency_time (int) –

the latency in microseconds

buffer_time (int) –

the total buffer size in microseconds

segsize (int) –

the size of one segment in bytes

segtotal (int) –

the total number of segments

seglatency (int) –

number of segments queued in the lower level device, defaults to segtotal


GstAudio.AudioRingBufferSpec

The structure containing the format specification of the ringbuffer.

Members

caps (Gst.Caps) –

The caps that generated the Spec.

the sample type

latency_time (Number) –

the latency in microseconds

buffer_time (Number) –

the total buffer size in microseconds

segsize (Number) –

the size of one segment in bytes

segtotal (Number) –

the total number of segments

seglatency (Number) –

number of segments queued in the lower level device, defaults to segtotal


Function Macros

GST_AUDIO_RING_BUFFER_BROADCAST

#define GST_AUDIO_RING_BUFFER_BROADCAST(buf)(g_cond_broadcast (GST_AUDIO_RING_BUFFER_GET_COND (buf)))

GST_AUDIO_RING_BUFFER_CAST

#define GST_AUDIO_RING_BUFFER_CAST(obj)        ((GstAudioRingBuffer *)obj)

GST_AUDIO_RING_BUFFER_GET_COND

#define GST_AUDIO_RING_BUFFER_GET_COND(buf) (&(((GstAudioRingBuffer *)buf)->cond))

GST_AUDIO_RING_BUFFER_SIGNAL

#define GST_AUDIO_RING_BUFFER_SIGNAL(buf)   (g_cond_signal (GST_AUDIO_RING_BUFFER_GET_COND (buf)))

GST_AUDIO_RING_BUFFER_WAIT

#define GST_AUDIO_RING_BUFFER_WAIT(buf)     (g_cond_wait (GST_AUDIO_RING_BUFFER_GET_COND (buf), GST_OBJECT_GET_LOCK (buf)))

Enumerations

GstAudioRingBufferFormatType

The format of the samples in the ringbuffer.

Members

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_RAW (0) –

samples in linear or float

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MU_LAW (1) –

samples in mulaw

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_A_LAW (2) –

samples in alaw

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_IMA_ADPCM (3) –

samples in ima adpcm

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MPEG (4) –

samples in mpeg audio (but not AAC) format

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_GSM (5) –

samples in gsm format

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_IEC958 (6) –

samples in IEC958 frames (e.g. AC3)

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_AC3 (7) –

samples in AC3 format

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_EAC3 (8) –

samples in EAC3 format

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_DTS (9) –

samples in DTS format

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MPEG2_AAC (10) –

samples in MPEG-2 AAC ADTS format

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MPEG4_AAC (11) –

samples in MPEG-4 AAC ADTS format

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MPEG2_AAC_RAW (12) –

samples in MPEG-2 AAC raw format (Since: 1.12)

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MPEG4_AAC_RAW (13) –

samples in MPEG-4 AAC raw format (Since: 1.12)

GST_AUDIO_RING_BUFFER_FORMAT_TYPE_FLAC (14) –

samples in FLAC format (Since: 1.12)


GstAudio.AudioRingBufferFormatType

The format of the samples in the ringbuffer.

Members

GstAudio.AudioRingBufferFormatType.RAW (0) –

samples in linear or float

GstAudio.AudioRingBufferFormatType.MU_LAW (1) –

samples in mulaw

GstAudio.AudioRingBufferFormatType.A_LAW (2) –

samples in alaw

GstAudio.AudioRingBufferFormatType.IMA_ADPCM (3) –

samples in ima adpcm

GstAudio.AudioRingBufferFormatType.MPEG (4) –

samples in mpeg audio (but not AAC) format

GstAudio.AudioRingBufferFormatType.GSM (5) –

samples in gsm format

GstAudio.AudioRingBufferFormatType.IEC958 (6) –

samples in IEC958 frames (e.g. AC3)

GstAudio.AudioRingBufferFormatType.AC3 (7) –

samples in AC3 format

GstAudio.AudioRingBufferFormatType.EAC3 (8) –

samples in EAC3 format

GstAudio.AudioRingBufferFormatType.DTS (9) –

samples in DTS format

GstAudio.AudioRingBufferFormatType.MPEG2_AAC (10) –

samples in MPEG-2 AAC ADTS format

GstAudio.AudioRingBufferFormatType.MPEG4_AAC (11) –

samples in MPEG-4 AAC ADTS format

GstAudio.AudioRingBufferFormatType.MPEG2_AAC_RAW (12) –

samples in MPEG-2 AAC raw format (Since: 1.12)

GstAudio.AudioRingBufferFormatType.MPEG4_AAC_RAW (13) –

samples in MPEG-4 AAC raw format (Since: 1.12)

GstAudio.AudioRingBufferFormatType.FLAC (14) –

samples in FLAC format (Since: 1.12)


GstAudio.AudioRingBufferFormatType

The format of the samples in the ringbuffer.

Members

GstAudio.AudioRingBufferFormatType.RAW (0) –

samples in linear or float

GstAudio.AudioRingBufferFormatType.MU_LAW (1) –

samples in mulaw

GstAudio.AudioRingBufferFormatType.A_LAW (2) –

samples in alaw

GstAudio.AudioRingBufferFormatType.IMA_ADPCM (3) –

samples in ima adpcm

GstAudio.AudioRingBufferFormatType.MPEG (4) –

samples in mpeg audio (but not AAC) format

GstAudio.AudioRingBufferFormatType.GSM (5) –

samples in gsm format

GstAudio.AudioRingBufferFormatType.IEC958 (6) –

samples in IEC958 frames (e.g. AC3)

GstAudio.AudioRingBufferFormatType.AC3 (7) –

samples in AC3 format

GstAudio.AudioRingBufferFormatType.EAC3 (8) –

samples in EAC3 format

GstAudio.AudioRingBufferFormatType.DTS (9) –

samples in DTS format

GstAudio.AudioRingBufferFormatType.MPEG2_AAC (10) –

samples in MPEG-2 AAC ADTS format

GstAudio.AudioRingBufferFormatType.MPEG4_AAC (11) –

samples in MPEG-4 AAC ADTS format

GstAudio.AudioRingBufferFormatType.MPEG2_AAC_RAW (12) –

samples in MPEG-2 AAC raw format (Since: 1.12)

GstAudio.AudioRingBufferFormatType.MPEG4_AAC_RAW (13) –

samples in MPEG-4 AAC raw format (Since: 1.12)

GstAudio.AudioRingBufferFormatType.FLAC (14) –

samples in FLAC format (Since: 1.12)


GstAudioRingBufferState

The state of the ringbuffer.

Members

GST_AUDIO_RING_BUFFER_STATE_STOPPED (0) –

The ringbuffer is stopped

GST_AUDIO_RING_BUFFER_STATE_PAUSED (1) –

The ringbuffer is paused

GST_AUDIO_RING_BUFFER_STATE_STARTED (2) –

The ringbuffer is started

GST_AUDIO_RING_BUFFER_STATE_ERROR (3) –

The ringbuffer has encountered an error after it has been started, e.g. because the device was disconnected (Since: 1.2)


GstAudio.AudioRingBufferState

The state of the ringbuffer.

Members

GstAudio.AudioRingBufferState.STOPPED (0) –

The ringbuffer is stopped

GstAudio.AudioRingBufferState.PAUSED (1) –

The ringbuffer is paused

GstAudio.AudioRingBufferState.STARTED (2) –

The ringbuffer is started

GstAudio.AudioRingBufferState.ERROR (3) –

The ringbuffer has encountered an error after it has been started, e.g. because the device was disconnected (Since: 1.2)


GstAudio.AudioRingBufferState

The state of the ringbuffer.

Members

GstAudio.AudioRingBufferState.STOPPED (0) –

The ringbuffer is stopped

GstAudio.AudioRingBufferState.PAUSED (1) –

The ringbuffer is paused

GstAudio.AudioRingBufferState.STARTED (2) –

The ringbuffer is started

GstAudio.AudioRingBufferState.ERROR (3) –

The ringbuffer has encountered an error after it has been started, e.g. because the device was disconnected (Since: 1.2)


Callbacks

GstAudioRingBufferCallback

(*GstAudioRingBufferCallback) (GstAudioRingBuffer * rbuf,
                               guint8 * data,
                               guint len,
                               gpointer user_data)

This function is set with gst_audio_ring_buffer_set_callback and is called to fill the memory at data with len bytes of samples.

Parameters:

rbuf

a GstAudioRingBuffer

data ( [array length=len] ) –

target to fill

len

amount to fill

user_data

user data


GstAudio.AudioRingBufferCallback

def GstAudio.AudioRingBufferCallback (rbuf, data, len, *user_data):
    #python wrapper for 'GstAudioRingBufferCallback'

This function is set with gst_audio_ring_buffer_set_callback (not introspectable) and is called to fill the memory at data with len bytes of samples.

Parameters:

data ( [ int ] ) –

target to fill

len ( int ) –

amount to fill

user_data ( variadic ) –

user data


GstAudio.AudioRingBufferCallback

function GstAudio.AudioRingBufferCallback(rbuf: GstAudio.AudioRingBuffer, data: [ Number ], len: Number, user_data: Object): {
    // javascript wrapper for 'GstAudioRingBufferCallback'
}

This function is set with gst_audio_ring_buffer_set_callback (not introspectable) and is called to fill the memory at data with len bytes of samples.

Parameters:

data ( [ Number ] ) –

target to fill

len ( Number ) –

amount to fill

user_data ( Object ) –

user data


The results of the search are