Go to the documentation of this file.
13 #include <QWaitCondition>
26 #include "libmythbase/mythconfig.h"
57 unsigned carouselId,
int dataBroadcastId);
61 void Restart(
int chanid,
int sourceid,
bool isLive);
68 void Reinit(QRect videoRect, QRect dispRect,
float aspect);
84 bool GetCarouselData(
const QString& objectPath, QByteArray &result)
override;
102 bool isBoxed,
MHRgba lineColour,
MHRgba fillColour)
override;
106 void DrawRect(
int xPos,
int yPos,
int width,
int height,
109 void DrawVideo(
const QRect &videoRect,
const QRect &dispRect)
override;
111 void DrawImage(
int x,
int y, QRect rect,
const QImage &image,
112 bool bScaled =
false,
bool bUnder =
false);
117 int &transportId,
int &serviceId)
override;
118 bool TuneTo(
int channel,
int tuneinfo)
override;
138 std::chrono::milliseconds
SetStreamPos(std::chrono::milliseconds pos)
override;
145 {
return "MYT001001"; }
147 {
return "DSMMYT001"; }
155 void AddToDisplay(
const QImage &image, QRect rect,
bool bUnder =
false);
156 int ScaleX(
int n,
bool roundup =
false)
const;
157 int ScaleY(
int n,
bool roundup =
false)
const;
158 QRect
Scale(QRect r)
const;
159 int ScaleVideoX(
int n,
bool roundup =
false)
const;
160 int ScaleVideoY(
int n,
bool roundup =
false)
const;
172 void run(
void)
override;
178 bool GetDSMCCObject(
const QString &objectPath, QByteArray &result);
179 bool CheckAccess(
const QString &objectPath, QByteArray &cert);
231 static int Tid(ChannelCache_t::const_iterator it) {
return it->first; }
232 static int Cid(ChannelCache_t::const_iterator it) {
return it->second; }
233 static int Nid(ChannelCache_t::const_iterator it) {
return it.key().first; }
234 static int Sid(ChannelCache_t::const_iterator it) {
return it.key().second; }
245 void Draw(
int x,
int y)
override;
246 void Clear(
void)
override;
247 void AddText(
int x,
int y,
const QString &str,
MHRgba colour)
override;
249 void SetSize(
int width,
int height)
override;
250 void SetFont(
int size,
bool isBold,
bool isItalic)
override;
252 QRect
GetBounds(
const QString &str,
int &strLen,
int maxSize = -1)
override;
278 void CreateFromPNG(
const unsigned char *data,
int length)
override;
281 void CreateFromMPEG(
const unsigned char *data,
int length)
override;
284 void CreateFromJPEG(
const unsigned char *data,
int length)
override;
295 void Draw(
int x,
int y, QRect rect,
bool tiled,
bool bUnder)
override;
298 void ScaleImage(
int newWidth,
int newHeight)
override;
323 void Draw(
int x,
int y)
override;
339 void Clear(
void)
override;
344 void DrawOval(
int x,
int y,
int width,
int height)
override;
346 int start,
int arc,
bool isSector)
override;
350 void DrawRect(
int x,
int y,
int width,
int height,
MHRgba colour);
373 unsigned car,
int dbid)
MHTextDisplay * CreateText(void) override
void Draw(int x, int y) override
FT_Face GetFontFace(void)
bool IsFaceLoaded(void) const
MHInteractionChannel m_ic
void Restart(int chanid, int sourceid, bool isLive)
Restart the MHEG engine.
void DrawOval(int x, int y, int width, int height) override
static constexpr uint16_t NBI_VERSION_UNSET
void EndStream() override
bool BeginVideo(int tag) override
Begin displaying video.
std::list< MHIImageData * > m_display
std::chrono::milliseconds GetStreamMaxPos() override
void AddText(int x, int y, const QString &str, MHRgba colour) override
int ScaleVideoY(int n, bool roundup=false) const
MHIContext(InteractiveTV *parent)
int m_height
Height of the drawing.
void Clear(void) override
void DrawRect(int x, int y, int width, int height, MHRgba colour)
int m_lineWidth
Current line width.
int GetChannelIndex(const QString &str) override
bool CheckCarouselObject(const QString &objectPath) override
static int Nid(ChannelCache_t::const_iterator it)
void DrawArcSector(int x, int y, int width, int height, int start, int arc, bool isSector) override
QSize GetSize(void) override
std::chrono::milliseconds SetStreamPos(std::chrono::milliseconds pos) override
void CreateFromPNG(const unsigned char *data, int length) override
Create bitmap from PNG.
void Reinit(QRect videoRect, QRect dispRect, float aspect)
The display area has changed.
MHIText(MHIContext *parent)
static const int kStdDisplayHeight
QRect Scale(QRect r) const
bool GetDSMCCObject(const QString &objectPath, QByteArray &result)
void NetworkBootRequested(void)
void QueueDSMCCPacket(unsigned char *data, int length, int componentTag, unsigned carouselId, int dataBroadcastId)
bool CheckAccess(const QString &objectPath, QByteArray &cert)
QWaitCondition m_engineWait
void SetLineColour(MHRgba colour) override
bool BeginStream(const QString &str, MHStream *notify) override
Begin playing the specified stream.
bool GetServiceInfo(int channelId, int &netId, int &origNetId, int &transportId, int &serviceId) override
Get netId etc from the channel index.
MHRgba m_boxFillColour
Fill colour for the background.
bool OfferKey(const QString &key)
bool BeginAudio(int tag) override
Begin playing audio.
void SetFillColour(MHRgba colour) override
void DrawRect(int xPos, int yPos, int width, int height, MHRgba colour) override
Additional drawing functions.
static int Sid(ChannelCache_t::const_iterator it)
int ScaleY(int n, bool roundup=false) const
MHBitmapDisplay * CreateBitmap(bool tiled) override
MythDeque< int > m_keyQueue
void SetInputRegister(int num) override
void SetLineSize(int width) override
MHRgba m_lineColour
Current line colour.
void StopVideo() override
Stop displaying video.
MHIBitmap & operator=(const MHIBitmap &)=delete
void Draw(int x, int y, QRect rect, bool tiled, bool bUnder) override
Draw the completed drawing onto the display.
const char * GetReceiverId(void) override
void DrawLineSub(int x1, int y1, int x2, int y2, bool swapped)
void GetInitialStreams(int &audioTag, int &videoTag) const
Get the initial component tags.
DSMCCPacket(unsigned char *data, int length, int tag, unsigned car, int dbid)
int ScaleVideoX(int n, bool roundup=false) const
QRect GetBounds(const QString &str, int &strLen, int maxSize=-1) override
MHRgba m_fillColour
Current fill colour.
void ScaleImage(int newWidth, int newHeight) override
Scale the bitmap. Only used for image derived from MPEG I-frames.
void DrawLine(int x1, int y1, int x2, int y2) override
MHIDLA(MHIContext *parent, bool isBoxed, MHRgba lineColour, MHRgba fillColour)
MythDeque< DSMCCPacket * > m_dsmccQueue
MHIBitmap(MHIContext *parent, bool tiled)
void StreamPlay(bool play) override
QRect ScaleVideo(QRect r) const
bool m_boxed
Does it have a border?
void SetSize(int width, int height) override
void StopEngine(void)
Stop the MHEG engine if it's running and waits until it has.
void CreateFromMPEG(const unsigned char *data, int length) override
Create bitmap from single I frame MPEG.
Object for drawing bitmaps.
void SetFont(int size, bool isBold, bool isItalic) override
~MHIText() override=default
static int Cid(ChannelCache_t::const_iterator it)
bool StreamStarted(bool bStarted=true)
Data for the queued DSMCC tables.
void UpdateOSD(InteractiveScreen *osdWindow, MythPainter *osdPainter)
Update the display.
MHDLADisplay * CreateDynamicLineArt(bool isBoxed, MHRgba lineColour, MHRgba fillColour) override
Creation functions for various visibles.
bool LoadFont(const QString &name)
bool CheckStop(void) override
Check whether we have requested a stop.
void CreateFromJPEG(const unsigned char *data, int length) override
Create bitmap from JPEG.
void Clear(void) override
Clear the drawing.
bool IsOpaque(void) override
ChannelCache_t m_channelCache
This is a wrapper around QThread that does several additional things.
void Draw(int x, int y) override
Draw the completed drawing onto the display.
int ScaleX(int n, bool roundup=false) const
std::vector< unsigned char > m_nbiData
void SetSize(int width, int height) override
Set the box size. Also clears the drawing.
void RequireRedraw(const QRegion ®ion) override
An area of the screen/image needs to be redrawn.
bool GetCarouselData(const QString &objectPath, QByteArray &result) override
const char * GetDSMCCId(void) override
Contains various utility functions for interactive television.
void DrawPoly(bool isFilled, const MHPointVec &xArray, const MHPointVec &yArray) override
void ProcessDSMCCQueue(void)
void DrawImage(int x, int y, QRect rect, const QImage &image, bool bScaled=false, bool bUnder=false)
void StopAudio() override
Stop playing audio.
void AddToDisplay(const QImage &image, QRect rect, bool bUnder=false)
Data for items in the interactive television display stack.
This is the interface between an MHEG engine and a MythTV TV object.
void SetNetBootInfo(const unsigned char *data, uint length)
Object for displaying Dynamic Line Art.
std::chrono::milliseconds GetStreamPos() override
static int Tid(ChannelCache_t::const_iterator it)
void DrawVideo(const QRect &videoRect, const QRect &dispRect) override
int m_width
Width of the drawing.
MHRgba m_boxLineColour
Line colour for the background.
bool TuneTo(int channel, int tuneinfo) override
QMultiMap< Key_t, Val_t > ChannelCache_t
void DrawBorderedRectangle(int x, int y, int width, int height) override
void DrawBackground(const QRegion ®) override
std::vector< int > MHPointVec
bool ImageUpdated(void) const
int GetICStatus() override
static const int kStdDisplayWidth