PySide6.QtMultimedia.QAudioBufferOutput¶
- class QAudioBufferOutput¶
The
QAudioBufferOutput
class is used for capturing audio data provided byQMediaPlayer
. More…Added in version 6.8.
Synopsis¶
Methods¶
def
__init__()
def
format()
Signals¶
Note
This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE
Detailed Description¶
QAudioBufferOutput
can be set toQMediaPlayer
in order to receive audio buffers decoded by the media player. The received audio data can be used for any processing or visualization.QAudioBufferOutput
is only supported with the FFmpeg backend.See also
Constructs a new
QAudioBufferOutput
object withparent
.The audio format of output audio buffers will depend on the source media file and the inner audio decoder in
QMediaPlayer
.- __init__(format[, parent=None])
- Parameters:
format –
QAudioFormat
parent –
QObject
Constructs a new
QAudioBufferOutput
object with audioformat
andparent
.If the specified
format
is valid, it will be the format of output audio buffers. Otherwise, the format of output audio buffers will depend on the source media file and the inner audio decoder inQMediaPlayer
.- audioBufferReceived(buffer)¶
- Parameters:
buffer –
QAudioBuffer
Signals that a new audio
buffer
has been received fromQMediaPlayer
.- format()¶
- Return type:
Gets the audio format specified in the constructor.
If the format is valid, it specifies the format of output oudio buffers.