Go to the documentation of this file. 1 #ifndef MYTHUI_IMAGE_H_
2 #define MYTHUI_IMAGE_H_
7 #include <QWaitCondition>
53 QImage img(imageArea.size(), QImage::Format_ARGB32);
102 MythUIImage(
const QString &filepattern,
int low,
int high, std::chrono::milliseconds delay,
111 void SetFilename(
const QString &
filename);
114 void SetFilepattern(
const QString &filepattern,
int low,
int high);
116 void SetImageCount(
int low,
int high);
126 void SetImages(QVector<MythImage *> *images);
128 void SetDelay(std::chrono::milliseconds delayms);
129 void SetDelays(
const QVector<std::chrono::milliseconds>& delays);
131 void Reset(
void)
override;
132 bool Load(
bool allowLoadInBackground =
true,
bool forceStat =
false);
134 void Pulse(
void)
override;
138 void SetOrientation(
int orientation);
145 int alphaMod, QRect clipRect)
override;
153 bool showWarnings)
override;
158 void SetSize(
int width,
int height);
159 void SetSize(QSize size)
override;
160 void ForceSize(QSize size);
162 void SetCropRect(
int x,
int y,
int width,
int height);
163 void SetCropRect(
const MythRect &rect);
165 void FindRandomImage(
void);
174 std::chrono::milliseconds m_delay { -1ms };
178 unsigned int m_curPos {0};
179 QTime m_lastDisplay {QTime::currentTime()};
181 bool m_needLoad {
false};
185 int m_runningThreads {0};
187 bool m_showingRandomImage {
false};
190 int m_imageListIndex {0};
196 bool m_animationReverse {
false};
197 bool m_animatedImage {
false};
void SetMaskImage(MythImage *image)
Image widget, displays a single image or multiple images in sequence.
QHash< int, MythImage * > m_images
A narrow purpose widget used to represent cut positions and regions when editing a video.
QHash< int, std::chrono::milliseconds > m_delays
ReflectAxis m_reflectAxis
void customEvent(QEvent *event) override
A text entry and edit widget.
QImage GetMaskImageSubset(QRect imageArea)
Screen in which all other widgets are contained and rendered.
A narrow purpose widget used to show television programs and the timeslots they occupy on channels....
Wrapper around QRect allowing us to handle percentage and other relative values for areas in mythui.
virtual void Pulse(void)
Pulse is called 70 times a second to trigger a single frame of an animation.
virtual void CreateCopy(MythUIType *parent)
Copy the state of this widget to the one given, it must be of the same type.
virtual void DrawSelf(MythPainter *p, int xoffset, int yoffset, int alphaMod, QRect clipRect)
QVector< AnimationFrame > AnimationFrames
QString m_maskImageFilename
ImageProperties & operator=(const ImageProperties &other)
virtual void CopyFrom(MythUIType *base)
Copy this widgets state from another.
void Copy(const ImageProperties &other)
void SetMaskImageFilename(const QString &filename)
virtual void Reset(void)
Reset the widget to it's original state, should not reset changes made by the theme.
The base class on which all widgets and screens are based.
QRect GetMaskImageRect(void)
virtual void LoadNow(void)
Cause images in this and child widgets to be loaded.
ImageProperties()=default
virtual void SetSize(QSize size)
QString GetMaskImageFilename()
QString GetFilename(void)
static const iso6937table * d
ImageProperties m_imageProperties
virtual bool ParseElement(const QString &filename, QDomElement &element, bool showWarnings)
Parse the xml definition of this widget setting the state of the object accordingly.
virtual void Finalize(void)
Perform any post-xml parsing initialisation tasks.
QPair< MythImage *, std::chrono::milliseconds > AnimationFrame