- Qt 5.5
- Qt Multimedia
- C++ Classes
- QAudioEncoderSettingsControl
- Qt 5.5.1 Reference Documentation

# QAudioEncoderSettingsControl Class

The QAudioEncoderSettingsControl class provides access to the settings of a media service that performs audio encoding. More...

Header: | #include <QAudioEncoderSettingsControl>
qmake: | QT += multimedia
Inherits: | QMediaControl

- List of all members, including inherited members

## Public Functions

virtual | ~QAudioEncoderSettingsControl()
virtual QAudioEncoderSettings | audioSettings() const = 0
virtual QString | codecDescription(const QString & codec) const = 0
virtual void | setAudioSettings(const QAudioEncoderSettings & settings) = 0
virtual QStringList | supportedAudioCodecs() const = 0
virtual QList<int> | supportedSampleRates(const QAudioEncoderSettings & settings, bool * continuous = 0) const = 0

## Protected Functions

| QAudioEncoderSettingsControl(QObject * parent = 0)

## Macros

| QAudioEncoderSettingsControl_iid

## Detailed Description

The QAudioEncoderSettingsControl class provides access to the settings of a media service that performs audio encoding.

If a 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 object.

The functionality provided by this control is exposed to application code through the QMediaRecorder class.

The interface name of QAudioEncoderSettingsControl is `org.qt-project.qt.audioencodersettingscontrol/5.0` as defined in QAudioEncoderSettingsControl_iid.

See also QMediaService::requestControl() and QMediaRecorder.

## Member Function Documentation

### `[protected]` QAudioEncoderSettingsControl::QAudioEncoderSettingsControl(QObject * parent = 0)

Create a new audio encoder settings control object with the given parent.

### `[virtual]` QAudioEncoderSettingsControl::~QAudioEncoderSettingsControl()

Destroys the audio encoder settings control.

### `[pure virtual]` QAudioEncoderSettings QAudioEncoderSettingsControl::audioSettings() const

Returns the audio encoder settings.

The returned value may be different tha passed to QAudioEncoderSettingsControl::setAudioSettings() if the settings contains the default or undefined parameters. In this case if the undefined parameters are already resolved, they should be returned.

See also setAudioSettings().

### `[pure virtual]` QString QAudioEncoderSettingsControl::codecDescription(const QString & codec) const

Returns description of audio codec.

### `[pure virtual]` void QAudioEncoderSettingsControl::setAudioSettings(const QAudioEncoderSettings & settings)

Sets the selected audio settings.

See also 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 = 0) 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 is set to true, otherwise *continuous is set to false.

## Macro Documentation

### QAudioEncoderSettingsControl_iid

`org.qt-project.qt.audioencodersettingscontrol/5.0`

Defines the interface name of the QAudioEncoderSettingsControl class.