Since 1.8Optionalconfig: StructureConvenience wrapper around gst_audio_converter_samples(), which will
perform allocation of the output buffer based on the result from
gst_audio_converter_get_out_frames().
input data
true is the conversion could be performed.
Free a previously allocated convert instance.
Get the current configuration of convert.
a Gst.Structure that remains valid for as long as convert is valid or until gst_audio_converter_update_config() is called.
Calculate how many input frames are currently needed by convert to produce
out_frames of output frames.
number of output frames
the number of input frames
Get the maximum number of input frames that the converter would need before producing output.
the latency of convert as expressed in the number of frames.
Calculate how many output frames can be produced when in_frames input
frames are given to convert.
number of input frames
the number of output frames
Returns whether the audio converter will operate in passthrough mode.
The return value would be typically input to gst_base_transform_set_passthrough()
true when no conversion will actually occur.
Reset convert to the state it was when it was first created, clearing
any history it might currently have.
Perform the conversion with in_frames in in to out_frames in out
using convert.
In case the samples are interleaved, in and out must point to an
array with a single element pointing to a block of interleaved samples.
If non-interleaved samples are used, in and out must point to an
array with pointers to memory blocks, one for each channel.
in may be null, in which case in_frames of silence samples are processed
by the converter.
This function always produces out_frames of output and consumes in_frames of
input. Use gst_audio_converter_get_out_frames() and
gst_audio_converter_get_in_frames() to make sure in_frames and out_frames
are matching and in and out point to enough memory.
input frames
number of input frames
output frames
number of output frames
true is the conversion could be performed.
Returns whether the audio converter can perform the conversion in-place.
The return value would be typically input to gst_base_transform_set_in_place()
true when the conversion can be done in place.
Set in_rate, out_rate and config as extra configuration for convert.
in_rate and out_rate specify the new sample rates of input and output
formats. A value of 0 leaves the sample rate unchanged.
config can be null, in which case, the current configuration is not
changed.
If the parameters in config can not be set exactly, this function returns
false and will try to update as much state as possible. The new state can
then be retrieved and refined with gst_audio_converter_get_config().
Look at the GST_AUDIO_CONVERTER_OPT_* fields to check valid configuration
option and values.
input rate
output rate
Optionalconfig: Structurea Gst.Structure or null
true when the new parameters could be set
StaticnewOptionalconfig: Structure
This object is used to convert audio samples from one format to another. The object can perform conversion of:
audio format with optional dithering and noise shaping
audio samplerate
audio channels and channel layout
Since
1.8