The QVideoEncoderSettings class provides a set of video encoder settings. 更多...
| 頭: | #include <QVideoEncoderSettings> |
| qmake: | QT += multimedia |
| QVideoEncoderSettings () | |
| QVideoEncoderSettings (const QVideoEncoderSettings & other ) | |
| ~QVideoEncoderSettings () | |
| int | bitRate () const |
| QString | codec () const |
| QMultimedia::EncodingMode | encodingMode () const |
| QVariant | encodingOption (const QString & option ) const |
| QVariantMap | encodingOptions () const |
| qreal | frameRate () const |
| bool | isNull () const |
| QMultimedia::EncodingQuality | quality () const |
| QSize | resolution () const |
| void | setBitRate (int value ) |
| void | setCodec (const QString & codec ) |
| void | setEncodingMode (QMultimedia::EncodingMode mode ) |
| void | setEncodingOption (const QString & option , const QVariant & value ) |
| void | setEncodingOptions (const QVariantMap & options ) |
| void | setFrameRate (qreal rate ) |
| void | setQuality (QMultimedia::EncodingQuality quality ) |
| void | setResolution (const QSize & resolution ) |
| void | setResolution (int width , int height ) |
| bool | operator!= (const QVideoEncoderSettings & other ) const |
| QVideoEncoderSettings & | operator= (const QVideoEncoderSettings & other ) |
| bool | operator== (const QVideoEncoderSettings & other ) const |
The QVideoEncoderSettings class provides a set of video encoder settings.
視頻編碼器設置對象用於指定視頻編碼器設置使用通過 QMediaRecorder . Video encoder settings are selected by constructing a QVideoEncoderSettings object, setting the desired properties and then passing it to a QMediaRecorder instance using the QMediaRecorder::setEncodingSettings () 函數。
QVideoEncoderSettings videoSettings; videoSettings.setCodec("video/mpeg2"); videoSettings.setResolution(640, 480); recorder->setVideoSettings(videoSettings);
另請參閱 QMediaRecorder and QVideoEncoderSettingsControl .
Constructs a null video encoder settings object.
Constructs a copy of the video encoder settings object other .
Destroys a video encoder settings object.
Returns bit rate of the encoded video stream in bits per second.
另請參閱 setBitRate ().
Returns the video codec.
另請參閱 setCodec ().
返迴視頻編碼模式。
另請參閱 setEncodingMode () 和 QMultimedia::EncodingMode .
返迴值為編碼 option .
另請參閱 setEncodingOption () 和 encodingOptions ().
返迴所有編碼選項按 QVariantMap .
另請參閱 encodingOption () 和 setEncodingOptions ().
返迴視頻幀速率。
另請參閱 setFrameRate ().
Identifies if a video encoder settings object is uninitalized.
Returns true if the settings are null, and false if they are not.
返迴視頻編碼品質。
另請參閱 setQuality ().
Returns the resolution of the encoded video.
另請參閱 setResolution ().
Sets the bit rate of the encoded video stream to value .
另請參閱 bitRate ().
設置視頻 codec .
另請參閱 codec ().
Sets the video encoding mode .
若 QMultimedia::ConstantQualityEncoding is set, the quality encoding parameter is used and bit rate is ignored, otherwise the bitrate is used.
The rest of encoding settings are respected regardless of encoding mode.
另請參閱 encodingMode () 和 QMultimedia::EncodingMode .
設置編碼 option value .
The supported set and meaning of encoding options are system and selected codec specific.
另請參閱 encodingOption () 和 setEncodingOptions ().
Replace all the encoding options with options .
The supported set and meaning of encoding options are system and selected codec specific.
另請參閱 encodingOptions (), encodingOption (),和 setEncodingOption ().
Sets the video frame rate .
A value of 0 indicates the encoder should make an optimal choice based on what is available from the video source and the limitations of the codec.
另請參閱 frameRate ().
Sets the video encoding quality .
Setting the video quality parameter allows backend to choose the balanced set of encoding parameters to achieve the desired quality level.
The quality settings parameter is only used in the constant quality encoding mode 。 quality settings parameter is only used in the constant quality encoding mode .
另請參閱 quality ().
設置 resolution of the encoded video.
空 QSize indicates the encoder should make an optimal choice based on what is available from the video source and the limitations of the codec.
另請參閱 resolution ().
設置 width and height of the resolution of the encoded video.
這是重載函數。
Determines if other is of equal value to a video encoder settings object.
Returns true if the settings objects are not of equal value, and false if they are of equal value.
賦值值 other to a video encoder settings object.
Determines if other is of equal value to a video encoder settings object.
Returns true if the settings objects are of equal value, and false if they are not of equal value.