QAudioRoleControl Class

The QAudioRoleControl class provides control over the audio role of a media object. 更多...

头: #include <QAudioRoleControl>
qmake: QT += multimedia
Since: Qt 5.6
继承: QMediaControl

公共函数

virtual ~QAudioRoleControl ()
virtual QAudio::Role audioRole () const = 0
virtual void setAudioRole (QAudio::Role role ) = 0
virtual QList<QAudio::Role> supportedAudioRoles () const = 0

信号

void audioRoleChanged (QAudio::Role role )

静态公共成员

const QMetaObject staticMetaObject

保护函数

QAudioRoleControl (QObject * parent = nullptr)

QAudioRoleControl_iid

额外继承成员

详细描述

The QAudioRoleControl class provides control over the audio role of a media object.

QMediaService supports audio roles it will implement QAudioRoleControl .

The functionality provided by this control is exposed to application code through the QMediaPlayer 类。

接口名称对于 QAudioRoleControl is org.qt-project.qt.audiorolecontrol/5.6 作为定义在 QAudioRoleControl_iid .

另请参阅 QMediaService::requestControl () 和 QMediaPlayer .

成员函数文档编制

[protected] QAudioRoleControl:: QAudioRoleControl ( QObject * parent = nullptr)

构造 QAudioRoleControl 采用给定 parent .

[虚拟] QAudioRoleControl:: ~QAudioRoleControl ()

Destroys the audio role control.

[pure virtual] QAudio::Role QAudioRoleControl:: audioRole () const

Returns the audio role of the media played by the media service.

另请参阅 setAudioRole ().

[signal] void QAudioRoleControl:: audioRoleChanged ( QAudio::Role role )

Signal emitted when the audio role 已改变。

[pure virtual] void QAudioRoleControl:: setAudioRole ( QAudio::Role role )

设置音频 role of the media played by the media service.

另请参阅 audioRole ().

[pure virtual] QList < QAudio::Role > QAudioRoleControl:: supportedAudioRoles () const

Returns a list of audio roles that the media service supports.

宏文档编制

QAudioRoleControl_iid

org.qt-project.qt.audiorolecontrol/5.6

定义接口名为 QAudioRoleControl 类。