The QMediaStreamsControl class provides a media stream selection control. 更多...
头: | #include <QMediaStreamsControl> |
qmake: | QT += multimedia |
继承: | QMediaControl |
该类已过时。 提供它是为使旧源代码能继续工作。强烈建议不要在新代码中使用它。
enum | StreamType { AudioStream, VideoStream, SubPictureStream, UnknownStream, DataStream } |
virtual | ~QMediaStreamsControl () |
virtual bool | isActive (int streamNumber ) = 0 |
virtual QVariant | metaData (int streamNumber , const QString & key ) = 0 |
virtual void | setActive (int streamNumber , bool state ) = 0 |
virtual int | streamCount () = 0 |
virtual QMediaStreamsControl::StreamType | streamType (int streamNumber ) = 0 |
void | activeStreamsChanged () |
void | streamsChanged () |
QMediaStreamsControl (QObject * parent = nullptr) |
QMediaStreamsControl_iid |
The QMediaStreamsControl class provides descriptions of the available media streams and allows individual streams to be activated and deactivated.
The interface name of QMediaStreamsControl is
org.qt-project.qt.mediastreamscontrol/5.0
作为定义在
QMediaStreamsControl_iid
.
另请参阅 QMediaService::requestControl ().
Media stream type.
常量 | 值 | 描述 |
---|---|---|
QMediaStreamsControl::AudioStream
|
2
|
Audio stream. |
QMediaStreamsControl::VideoStream
|
1
|
Video stream. |
QMediaStreamsControl::SubPictureStream
|
3
|
Subpicture or teletext stream. |
QMediaStreamsControl::UnknownStream
|
0
|
The stream type is unknown. |
QMediaStreamsControl::DataStream
|
4
|
[protected]
QMediaStreamsControl::
QMediaStreamsControl
(
QObject
*
parent
= nullptr)
Constructs a new media streams control with the given parent .
[signal]
void
QMediaStreamsControl::
activeStreamsChanged
()
The signal is emitted when the active streams list is changed.
[signal]
void
QMediaStreamsControl::
streamsChanged
()
The signal is emitted when the available streams list is changed.
[虚拟]
QMediaStreamsControl::
~QMediaStreamsControl
()
Destroys a media streams control.
[pure virtual]
bool
QMediaStreamsControl::
isActive
(
int
streamNumber
)
Returns true if the media stream streamNumber is active.
[pure virtual]
QVariant
QMediaStreamsControl::
metaData
(
int
streamNumber
, const
QString
&
key
)
Returns the meta-data value of key 为给定 streamNumber .
Useful metadata keys are QMediaMetaData::Title, QMediaMetaData::Description and QMediaMetaData::Language.
[pure virtual]
void
QMediaStreamsControl::
setActive
(
int
streamNumber
,
bool
state
)
Sets the active state of media stream streamNumber .
Setting the active state of a media stream to true will activate it. If any other stream of the same type was previously active it will be deactivated. Setting the active state fo a media stream to false will deactivate it.
另请参阅 isActive ().
[pure virtual]
int
QMediaStreamsControl::
streamCount
()
Returns the number of media streams.
[pure virtual]
QMediaStreamsControl::StreamType
QMediaStreamsControl::
streamType
(
int
streamNumber
)
Return the type of media stream streamNumber .
org.qt-project.qt.mediastreamscontrol/5.0
定义接口名为 QMediaStreamsControl 类。