QtGStreamer
1.2.0
Loading...
Searching...
No Matches
QGst
Ui
graphicsvideowidget.h
1
/*
2
Copyright (C) 2012 Collabora Ltd. <info@collabora.com>
3
@author George Kiagiadakis <george.kiagiadakis@collabora.com>
4
5
This library is free software; you can redistribute it and/or modify
6
it under the terms of the GNU Lesser General Public License as published
7
by the Free Software Foundation; either version 2.1 of the License, or
8
(at your option) any later version.
9
10
This program is distributed in the hope that it will be useful,
11
but WITHOUT ANY WARRANTY; without even the implied warranty of
12
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
GNU Lesser General Public License for more details.
14
15
You should have received a copy of the GNU Lesser General Public License
16
along with this program. If not, see <http://www.gnu.org/licenses/>.
17
*/
18
#ifndef QGST_UI_GRAPHICSVIDEOWIDGET_H
19
#define QGST_UI_GRAPHICSVIDEOWIDGET_H
20
21
#include "graphicsvideosurface.h"
22
#include <QtCore/QPointer>
23
24
#if (QT_VERSION >= QT_VERSION_CHECK(5, 0, 0))
25
# include <QtWidgets/QGraphicsWidget>
26
#else
27
# include <QtGui/QGraphicsWidget>
28
#endif
29
30
namespace
QGst
{
31
namespace
Ui {
32
43
class
QTGSTREAMERUI_EXPORT
GraphicsVideoWidget
:
public
QGraphicsWidget
44
{
45
Q_OBJECT
46
Q_DISABLE_COPY(
GraphicsVideoWidget
)
47
Q_PROPERTY(
QGst::Ui::GraphicsVideoSurface
* surface READ surface WRITE setSurface)
48
public
:
49
explicit
GraphicsVideoWidget
(QGraphicsItem *parent = 0, Qt::WindowFlags wFlags = 0);
50
virtual
~GraphicsVideoWidget
();
51
53
virtual
void
paint(QPainter *painter,
const
QStyleOptionGraphicsItem *option, QWidget *widget = 0);
54
55
GraphicsVideoSurface
*surface()
const
;
56
void
setSurface(
GraphicsVideoSurface
*surface);
57
58
private
:
59
QPointer<GraphicsVideoSurface> m_surface;
60
};
61
62
}
// namespace Ui
63
}
// namespace QGst
64
65
#endif
// QGST_UI_GRAPHICSVIDEOWIDGET_H
QGst::Ui::GraphicsVideoSurface
Helper class for painting video on a QGraphicsView.
Definition
graphicsvideosurface.h:92
QGst::Ui::GraphicsVideoWidget
A QGraphicsWidget for displaying video on a QGraphicsScene.
Definition
graphicsvideowidget.h:44
QGst
Wrappers for GStreamer classes.
Generated by
1.9.8