GstAudioSink

This is the most simple base class for audio sinks that only requires subclasses to implement a set of simple functions:

  • open() :Open the device.

  • prepare() :Configure the device with the specified format.

  • write() :Write samples to the device.

  • reset() :Unblock writes and flush the device.

  • delay() :Get the number of samples written but not yet played by the device.

  • unprepare() :Undo operations done by prepare.

  • close() :Close the device.

All scheduling of samples and timestamps is done in this base class together with GstAudioBaseSink using a default implementation of a GstAudioRingBuffer that uses threads.

GstAudioSink

GObject
    ╰──GInitiallyUnowned
        ╰──GstObject
            ╰──GstElement
                ╰──GstBaseSink
                    ╰──GstAudioBaseSink
                        ╰──GstAudioSink

Opaque GstAudioSink.

Members

element (GstAudioBaseSink) –
No description available

Class structure

GstAudioSinkClass

Fields
parent_class (GstAudioBaseSinkClass) –

the parent class structure.

extension (GstAudioSinkClassExtension *) –

class extension structure. Since: 1.18


GstAudio.AudioSinkClass

Attributes
parent_class (GstAudio.AudioBaseSinkClass) –

the parent class structure.

class extension structure. Since: 1.18


GstAudio.AudioSinkClass

Attributes
parent_class (GstAudio.AudioBaseSinkClass) –

the parent class structure.

class extension structure. Since: 1.18


GstAudio.AudioSink

GObject.Object
    ╰──GObject.InitiallyUnowned
        ╰──Gst.Object
            ╰──Gst.Element
                ╰──GstBase.BaseSink
                    ╰──GstAudio.AudioBaseSink
                        ╰──GstAudio.AudioSink

Members

element (GstAudio.AudioBaseSink) –
No description available

GstAudio.AudioSink

GObject.Object
    ╰──GObject.InitiallyUnowned
        ╰──Gst.Object
            ╰──Gst.Element
                ╰──GstBase.BaseSink
                    ╰──GstAudio.AudioBaseSink
                        ╰──GstAudio.AudioSink

Members

element (GstAudio.AudioBaseSink) –
No description available

Virtual Methods

close

gboolean
close (GstAudioSink * sink)

Close the device.

Parameters:

sink
No description available
Returns
No description available

vfunc_close

function vfunc_close(sink: GstAudio.AudioSink): {
    // javascript implementation of the 'close' virtual method
}

Close the device.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (Number)
No description available

do_close

def do_close (sink):
    #python implementation of the 'close' virtual method

Close the device.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (bool)
No description available

delay

guint
delay (GstAudioSink * sink)

Return how many frames are still in the device. Participates in computing the time for audio clocks and drives the synchronisation.

Parameters:

sink
No description available
Returns
No description available

vfunc_delay

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

Return how many frames are still in the device. Participates in computing the time for audio clocks and drives the synchronisation.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (Number)
No description available

do_delay

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

Return how many frames are still in the device. Participates in computing the time for audio clocks and drives the synchronisation.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (int)
No description available

open

gboolean
open (GstAudioSink * sink)

Open the device. No configuration needs to be done at this point. This function is also used to check if the device is available.

Parameters:

sink
No description available
Returns
No description available

vfunc_open

function vfunc_open(sink: GstAudio.AudioSink): {
    // javascript implementation of the 'open' virtual method
}

Open the device. No configuration needs to be done at this point. This function is also used to check if the device is available.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (Number)
No description available

do_open

def do_open (sink):
    #python implementation of the 'open' virtual method

Open the device. No configuration needs to be done at this point. This function is also used to check if the device is available.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (bool)
No description available

pause

pause (GstAudioSink * sink)

Pause the device and unblock write as fast as possible. For retro compatibility, the audio sink will fallback to calling reset if this vmethod is not provided. Since: 1.18

Parameters:

sink
No description available

vfunc_pause

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

Pause the device and unblock write as fast as possible. For retro compatibility, the audio sink will fallback to calling reset if this vmethod is not provided. Since: 1.18

Parameters:

sink (GstAudio.AudioSink)
No description available

do_pause

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

Pause the device and unblock write as fast as possible. For retro compatibility, the audio sink will fallback to calling reset if this vmethod is not provided. Since: 1.18

Parameters:

sink (GstAudio.AudioSink)
No description available

prepare

gboolean
prepare (GstAudioSink * sink,
         GstAudioRingBufferSpec * spec)

Prepare the device to operate with the specified parameters.

Parameters:

sink
No description available
spec
No description available
Returns
No description available

vfunc_prepare

function vfunc_prepare(sink: GstAudio.AudioSink, spec: GstAudio.AudioRingBufferSpec): {
    // javascript implementation of the 'prepare' virtual method
}

Prepare the device to operate with the specified parameters.

Parameters:

sink (GstAudio.AudioSink)
No description available
No description available
Returns (Number)
No description available

do_prepare

def do_prepare (sink, spec):
    #python implementation of the 'prepare' virtual method

Prepare the device to operate with the specified parameters.

Parameters:

sink (GstAudio.AudioSink)
No description available
No description available
Returns (bool)
No description available

reset

reset (GstAudioSink * sink)

Returns as quickly as possible from a write and flush any pending samples from the device. This vmethod is deprecated. Please provide pause and stop instead.

Parameters:

sink
No description available

vfunc_reset

function vfunc_reset(sink: GstAudio.AudioSink): {
    // javascript implementation of the 'reset' virtual method
}

Returns as quickly as possible from a write and flush any pending samples from the device. This vmethod is deprecated. Please provide pause and stop instead.

Parameters:

sink (GstAudio.AudioSink)
No description available

do_reset

def do_reset (sink):
    #python implementation of the 'reset' virtual method

Returns as quickly as possible from a write and flush any pending samples from the device. This vmethod is deprecated. Please provide pause and stop instead.

Parameters:

sink (GstAudio.AudioSink)
No description available

resume

resume (GstAudioSink * sink)

Resume the device. Since: 1.18

Parameters:

sink
No description available

vfunc_resume

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

Resume the device. Since: 1.18

Parameters:

sink (GstAudio.AudioSink)
No description available

do_resume

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

Resume the device. Since: 1.18

Parameters:

sink (GstAudio.AudioSink)
No description available

stop

stop (GstAudioSink * sink)

Stop the device and unblock write as fast as possible. Pending samples are flushed from the device. For retro compatibility, the audio sink will fallback to calling reset if this vmethod is not provided. Since: 1.18

Parameters:

sink
No description available

vfunc_stop

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

Stop the device and unblock write as fast as possible. Pending samples are flushed from the device. For retro compatibility, the audio sink will fallback to calling reset if this vmethod is not provided. Since: 1.18

Parameters:

sink (GstAudio.AudioSink)
No description available

do_stop

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

Stop the device and unblock write as fast as possible. Pending samples are flushed from the device. For retro compatibility, the audio sink will fallback to calling reset if this vmethod is not provided. Since: 1.18

Parameters:

sink (GstAudio.AudioSink)
No description available

unprepare

gboolean
unprepare (GstAudioSink * sink)

Undo operations done in prepare.

Parameters:

sink
No description available
Returns
No description available

vfunc_unprepare

function vfunc_unprepare(sink: GstAudio.AudioSink): {
    // javascript implementation of the 'unprepare' virtual method
}

Undo operations done in prepare.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (Number)
No description available

do_unprepare

def do_unprepare (sink):
    #python implementation of the 'unprepare' virtual method

Undo operations done in prepare.

Parameters:

sink (GstAudio.AudioSink)
No description available
Returns (bool)
No description available

write

gint
write (GstAudioSink * sink,
       gpointer data,
       guint length)

Write data to the device. This vmethod is allowed to block until all the data is written. If such is the case then it is expected that pause, stop and reset will unblock the write when called.

Parameters:

sink
No description available
data
No description available
length
No description available
Returns
No description available

vfunc_write

function vfunc_write(sink: GstAudio.AudioSink, data: [ Number ], length: Number): {
    // javascript implementation of the 'write' virtual method
}

Write data to the device. This vmethod is allowed to block until all the data is written. If such is the case then it is expected that pause, stop and reset will unblock the write when called.

Parameters:

sink (GstAudio.AudioSink)
No description available
data ([ Number ])
No description available
length (Number)
No description available
Returns (Number)
No description available

do_write

def do_write (sink, data, length):
    #python implementation of the 'write' virtual method

Write data to the device. This vmethod is allowed to block until all the data is written. If such is the case then it is expected that pause, stop and reset will unblock the write when called.

Parameters:

sink (GstAudio.AudioSink)
No description available
data ([ int ])
No description available
length (int)
No description available
Returns (int)
No description available

GstAudioSinkClassExtension


GstAudio.AudioSinkClassExtension


GstAudio.AudioSinkClassExtension


The results of the search are