MythTV  master
mythuivideo.h
Go to the documentation of this file.
1 #ifndef MYTHUI_VIDEO_H_
2 #define MYTHUI_VIDEO_H_
3 
4 #include <QString>
5 #include <QColor>
6 
7 #include "mythuitype.h"
8 
15 {
16  public:
17  MythUIVideo(MythUIType *parent, const QString &name);
18  ~MythUIVideo();
19 
20  void UpdateFrame(MythImage *image);
21  void UpdateFrame(QPixmap *pixmap);
22 
23  QColor GetBackgroundColor(void) { return m_backgroundColor; }
24 
25  void Reset(void) override; // MythUIType
26  void Pulse(void) override; // MythUIType
27 
28  protected:
29  void DrawSelf(MythPainter *p, int xoffset, int yoffset,
30  int alphaMod, QRect clipRect) override; // MythUIType
31 
32  bool ParseElement(const QString &filename, QDomElement &element,
33  bool showWarnings) override; // MythUIType
34  void CopyFrom(MythUIType *base) override; // MythUIType
35  void CreateCopy(MythUIType *parent) override; // MythUIType
36 
37  MythImage *m_image {nullptr};
38  QColor m_backgroundColor {Qt::black};
39 };
40 
41 #endif
The base class on which all widgets and screens are based.
Definition: mythuitype.h:63
virtual void CreateCopy(MythUIType *parent)
Copy the state of this widget to the one given, it must be of the same type.
virtual void Pulse(void)
Pulse is called 70 times a second to trigger a single frame of an animation.
Definition: mythuitype.cpp:442
Video widget, displays raw image data.
Definition: mythuivideo.h:14
virtual void DrawSelf(MythPainter *p, int xoffset, int yoffset, int alphaMod, QRect clipRect)
Definition: mythuitype.cpp:465
const char * name
Definition: ParseText.cpp:328
virtual void Reset(void)
Reset the widget to it's original state, should not reset changes made by the theme.
Definition: mythuitype.cpp:69
#define MUI_PUBLIC
Definition: mythuiexp.h:9
virtual void CopyFrom(MythUIType *base)
Copy this widgets state from another.
virtual bool ParseElement(const QString &filename, QDomElement &element, bool showWarnings)
Parse the xml definition of this widget setting the state of the object accordingly.
QColor GetBackgroundColor(void)
Definition: mythuivideo.h:23