The QAudioEncoderSettingsControl class provides access to the settings of a media service that performs audio encoding. 更多...
头: | #include <QAudioEncoderSettingsControl> |
qmake: | QT += multimedia |
继承: | QMediaControl |
virtual | ~QAudioEncoderSettingsControl () |
virtual QAudioEncoderSettings | audioSettings () const = 0 |
virtual QString | codecDescription (const QString & codecName ) const = 0 |
virtual void | setAudioSettings (const QAudioEncoderSettings & settings ) = 0 |
virtual QStringList | supportedAudioCodecs () const = 0 |
virtual QList<int> | supportedSampleRates (const QAudioEncoderSettings & settings , bool * continuous = nullptr) const = 0 |
const QMetaObject | staticMetaObject |
QAudioEncoderSettingsControl (QObject * parent = nullptr) |
QAudioEncoderSettingsControl_iid |
The QAudioEncoderSettingsControl class provides access to the settings of a media service that performs audio encoding.
若 QMediaService supports encoding audio data it will implement QAudioEncoderSettingsControl . This control provides information about the limits of restricted audio encoder options and allows the selection of a set of audio encoder settings as specified in a QAudioEncoderSettings 对象。
The functionality provided by this control is exposed to application code through the QMediaRecorder 类。
接口名称对于
QAudioEncoderSettingsControl
is
org.qt-project.qt.audioencodersettingscontrol/5.0
作为定义在
QAudioEncoderSettingsControl_iid
.
另请参阅 QMediaService::requestControl () 和 QMediaRecorder .
[protected]
QAudioEncoderSettingsControl::
QAudioEncoderSettingsControl
(
QObject
*
parent
= nullptr)
Create a new audio encoder settings control object with the given parent .
[虚拟]
QAudioEncoderSettingsControl::
~QAudioEncoderSettingsControl
()
Destroys the audio encoder settings control.
[pure virtual]
QAudioEncoderSettings
QAudioEncoderSettingsControl::
audioSettings
() const
Returns the audio encoder settings.
返回值可能异于传递给 QAudioEncoderSettingsControl::setAudioSettings () 若设定包含默认 (或未定义) 参数。在此情况下,若已解析未定义参数,应返回它们。
另请参阅 setAudioSettings ().
[pure virtual]
QString
QAudioEncoderSettingsControl::
codecDescription
(const
QString
&
codecName
) const
Returns the description of audio codec codecName .
[pure virtual]
void
QAudioEncoderSettingsControl::
setAudioSettings
(const
QAudioEncoderSettings
&
settings
)
Sets the selected audio settings .
另请参阅 audioSettings ().
[pure virtual]
QStringList
QAudioEncoderSettingsControl::
supportedAudioCodecs
() const
Returns the list of supported audio codec names.
[pure virtual]
QList
<
int
> QAudioEncoderSettingsControl::
supportedSampleRates
(const
QAudioEncoderSettings
&
settings
,
bool
*
continuous
= nullptr) const
Returns the list of supported audio sample rates, if known.
If non null audio settings parameter is passed, the returned list is reduced to sample rates supported with partial settings applied.
It can be used for example to query the list of sample rates, supported by specific audio codec.
If the encoder supports arbitrary sample rates within the supported rates range, * continuous 被设为 true,否则 * continuous 被设为 false。
org.qt-project.qt.audioencodersettingscontrol/5.0
定义接口名为 QAudioEncoderSettingsControl 类。