1// qvideowidget.sip generated by MetaSIP
2//
3// This file is part of the QtMultimediaWidgets Python extension module.
4//
5// Copyright (c) 2021 Riverbank Computing Limited <info@riverbankcomputing.com>
6//
7// This file is part of PyQt5.
8//
9// This file may be used under the terms of the GNU General Public License
10// version 3.0 as published by the Free Software Foundation and appearing in
11// the file LICENSE included in the packaging of this file.  Please review the
12// following information to ensure the GNU General Public License version 3.0
13// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
14//
15// If you do not wish to use this file under the terms of the GPL version 3.0
16// then you may purchase a commercial license.  For more information contact
17// info@riverbankcomputing.com.
18//
19// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
20// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
21
22
23class QVideoWidget : QWidget, QMediaBindableInterface
24{
25%TypeHeaderCode
26#include <qvideowidget.h>
27%End
28
29%ConvertToSubClassCode
30    static struct class_graph {
31        const char *name;
32        sipTypeDef **type;
33        int yes, no;
34    } graph[] = {
35        {sipName_QVideoWidget, &sipType_QVideoWidget, 3, 1},
36        {sipName_QGraphicsVideoItem, &sipType_QGraphicsVideoItem, -1, 2},
37        {sipName_QVideoWidgetControl, &sipType_QVideoWidgetControl, -1, -1},
38        {sipName_QCameraViewfinder, &sipType_QCameraViewfinder, -1, -1},
39    };
40
41    int i = 0;
42
43    sipType = NULL;
44
45    do
46    {
47        struct class_graph *cg = &graph[i];
48
49        if (cg->name != NULL && sipCpp->inherits(cg->name))
50        {
51            sipType = *cg->type;
52            i = cg->yes;
53        }
54        else
55            i = cg->no;
56    }
57    while (i >= 0);
58%End
59
60public:
61%If (Qt_5_6_1 -)
62    explicit QVideoWidget(QWidget *parent /TransferThis/ = 0);
63%End
64%If (- Qt_5_6_1)
65    QVideoWidget(QWidget *parent /TransferThis/ = 0);
66%End
67    virtual ~QVideoWidget();
68    virtual QMediaObject *mediaObject() const;
69    Qt::AspectRatioMode aspectRatioMode() const;
70    int brightness() const;
71    int contrast() const;
72    int hue() const;
73    int saturation() const;
74    virtual QSize sizeHint() const;
75
76public slots:
77    void setFullScreen(bool fullScreen);
78    void setAspectRatioMode(Qt::AspectRatioMode mode);
79    void setBrightness(int brightness);
80    void setContrast(int contrast);
81    void setHue(int hue);
82    void setSaturation(int saturation);
83
84signals:
85    void fullScreenChanged(bool fullScreen);
86    void brightnessChanged(int brightness);
87    void contrastChanged(int contrast);
88    void hueChanged(int hue);
89    void saturationChanged(int saturation);
90
91protected:
92    virtual bool event(QEvent *event);
93    virtual void showEvent(QShowEvent *event);
94    virtual void hideEvent(QHideEvent *event);
95    virtual void resizeEvent(QResizeEvent *event);
96    virtual void moveEvent(QMoveEvent *event);
97    virtual void paintEvent(QPaintEvent *event);
98    virtual bool setMediaObject(QMediaObject *object);
99
100public:
101%If (Qt_5_15_0 -)
102    QAbstractVideoSurface *videoSurface() const;
103%End
104};
105