QVideoWidget Class ReferenceThe QVideoWidget class provides a widget which presents video produced by a media object. More... #include <QVideoWidget> This class is under development and is subject to change. Inherits QWidget. Public Types
Properties
Public Functions
Reimplemented Public Functions
Public Slots
Signals
Reimplemented Protected Functions
Additional Inherited Members
Detailed DescriptionThe QVideoWidget class provides a widget which presents video produced by a media object. Attaching a QVideoWidget to a QMediaObject allows it to display the video or image output of that media object. A QVideoWidget is attached to media object by passing a pointer to the QMediaObject in its constructor, and detached by destroying the QVideoWidget. player = new QMediaPlayer;
widget = new QVideoWidget(player);
widget->show();
player->setMedia(QUrl("http://example.com/movie.mp4"));
player->play();
Note: Only a single display output can be attached to a media object at one time. See also QMediaObject, QMediaPlayer, and QGraphicsVideoItem. Member Type Documentation
|
Constant | Value | Description |
---|---|---|
QVideoWidget::IgnoreAspectRatio | 0 | The video is scaled to fill the widget ignoring its aspect ratio. |
QVideoWidget::KeepAspectRatio | 1 | The video is scaled to the largest rectangle that will fit within the widget's dimensions while still retaining its original aspect ratio. |
This property holds how video is scaled with respect to its aspect ratio.
Access functions:
AspectRatioMode | aspectRatioMode () const |
void | setAspectRatioMode ( QVideoWidget::AspectRatioMode mode ) |
This property holds an adjustment to the brightness of displayed video.
Valid brightness values range between -100 and 100, the default is 0.
Access functions:
int | brightness () const |
void | setBrightness ( int brightness ) |
Notifier signal:
void | brightnessChanged ( int brightness ) |
This property holds an adjustment to the contrast of displayed video.
Valid contrast values range between -100 and 100, the default is 0.
Access functions:
int | contrast () const |
void | setContrast ( int contrast ) |
Notifier signal:
void | contrastChanged ( int contrast ) |
This property holds whether video display is confined to a window or is fullScreen.
Access functions:
bool | isFullScreen () const |
void | setFullScreen ( bool fullScreen ) |
Notifier signal:
void | fullScreenChanged ( bool fullScreen ) |
This property holds an adjustment to the hue of displayed video.
Valid hue values range between -100 and 100, the default is 0.
Access functions:
int | hue () const |
void | setHue ( int hue ) |
Notifier signal:
void | hueChanged ( int hue ) |
This property holds an adjustment to the saturation of displayed video.
Valid saturation values range between -100 and 100, the default is 0.
Access functions:
int | saturation () const |
void | setSaturation ( int saturation ) |
Notifier signal:
void | saturationChanged ( int saturation ) |
Constructs a new widget which displays video produced by a media object.
The parent is passed to QWidget.
Destroys a video widget.
Signals that a video widgets's brightness adjustment has changed.
See also brightness.
Signals that a video widgets's contrast adjustment has changed.
See also contrast.
Signals that the fullScreen mode of a video widget has changed.
See also fullScreen.
Reimplemented from QWidget::hideEvent().
Handles the hide event.
Signals that a video widgets's hue has changed.
See also hue.
Reimplemented from QWidget::moveEvent().
Handles the move event.
Reimplemented from QWidget::paintEvent().
Handles the paint event.
Reimplemented from QWidget::resizeEvent().
Handles the resize event.
Signals that a video widgets's saturation has changed.
See also saturation.
Reimplemented from QWidget::showEvent().
Handles the show event.
Reimplemented from QWidget::sizeHint().
Returns the size hint for the current back end, if there is one, or else the size hint from QWidget.
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. | Qt qtmobility-1.0-tp | |
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD. | ||
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com