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)
–
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.
extension
(GstAudio.AudioSinkClassExtension)
–
class extension structure. Since: 1.18
GstAudio.AudioSinkClass
Attributes
parent_class
(GstAudio.AudioBaseSinkClass)
–
the parent class structure.
extension
(GstAudio.AudioSinkClassExtension)
–
class extension structure. Since: 1.18
GstAudio.AudioSink
GObject.Object ╰──GObject.InitiallyUnowned ╰──Gst.Object ╰──Gst.Element ╰──GstBase.BaseSink ╰──GstAudio.AudioBaseSink ╰──GstAudio.AudioSink
Opaque GstAudio.AudioSink.
Members
element
(GstAudio.AudioBaseSink)
–
GstAudio.AudioSink
GObject.Object ╰──GObject.InitiallyUnowned ╰──Gst.Object ╰──Gst.Element ╰──GstBase.BaseSink ╰──GstAudio.AudioBaseSink ╰──GstAudio.AudioSink
Opaque GstAudio.AudioSink.
Members
element
(GstAudio.AudioBaseSink)
–
Virtual Methods
close
gboolean close (GstAudioSink * sink)
Close the device.
Parameters:
sink
–
vfunc_close
function vfunc_close(sink: GstAudio.AudioSink): {
// javascript implementation of the 'close' virtual method
}
Close the device.
Parameters:
do_close
def do_close (sink):
#python implementation of the 'close' virtual method
Close the device.
Parameters:
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
–
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:
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:
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
–
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:
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:
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
–
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:
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:
prepare
gboolean prepare (GstAudioSink * sink, GstAudioRingBufferSpec * spec)
Prepare the device to operate with the specified parameters.
Parameters:
sink
–
spec
–
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:
do_prepare
def do_prepare (sink, spec):
#python implementation of the 'prepare' virtual method
Prepare the device to operate with the specified parameters.
Parameters:
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
–
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:
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:
resume
resume (GstAudioSink * sink)
Resume the device. Since: 1.18
Parameters:
sink
–
vfunc_resume
function vfunc_resume(sink: GstAudio.AudioSink): {
// javascript implementation of the 'resume' virtual method
}
Resume the device. Since: 1.18
Parameters:
do_resume
def do_resume (sink):
#python implementation of the 'resume' virtual method
Resume the device. Since: 1.18
Parameters:
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
–
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:
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:
unprepare
gboolean unprepare (GstAudioSink * sink)
Undo operations done in prepare.
Parameters:
sink
–
vfunc_unprepare
function vfunc_unprepare(sink: GstAudio.AudioSink): {
// javascript implementation of the 'unprepare' virtual method
}
Undo operations done in prepare.
Parameters:
do_unprepare
def do_unprepare (sink):
#python implementation of the 'unprepare' virtual method
Undo operations done in prepare.
Parameters:
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
–
data
–
length
–
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:
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:
GstAudioSinkClassExtension
GstAudio.AudioSinkClassExtension
GstAudio.AudioSinkClassExtension
The results of the search are