MythTV  master
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
ImageLoader Class Reference

#include <mythuiimage.h>

Public Member Functions

 ImageLoader ()=default
 
 ~ImageLoader ()=default
 

Static Public Member Functions

static bool PreLoad (const QString &cacheKey, const MythUIImage *uitype)
 
static void PostLoad (const QString &cacheKey)
 
static bool SupportsAnimation (const QString &filename)
 
static QString GenImageLabel (const ImageProperties &imProps)
 Generates a unique identifying string for this image which is used as a key in the image cache. More...
 
static MythImageLoadImage (MythPainter *painter, ImageProperties imProps, ImageCacheMode cacheMode, const MythUIImage *parent, bool &aborted, MythImageReader *imageReader=nullptr)
 
static AnimationFramesLoadAnimatedImage (MythPainter *painter, const ImageProperties &imProps, ImageCacheMode cacheMode, const MythUIImage *parent, bool &aborted)
 

Static Public Attributes

static QHash< QString, const MythUIImage * > m_loadingImages
 
static QMutex m_loadingImagesLock
 
static QWaitCondition m_loadingImagesCond
 

Detailed Description

Note
ImageProperties must only be used in the UI thread.

Definition at line 106 of file mythuiimage.cpp.

Constructor & Destructor Documentation

◆ ImageLoader()

ImageLoader::ImageLoader ( )
default

◆ ~ImageLoader()

ImageLoader::~ImageLoader ( )
default

Member Function Documentation

◆ PreLoad()

static bool ImageLoader::PreLoad ( const QString &  cacheKey,
const MythUIImage uitype 
)
inlinestatic

Definition at line 116 of file mythuiimage.cpp.

Referenced by LoadImage().

◆ PostLoad()

static void ImageLoader::PostLoad ( const QString &  cacheKey)
inlinestatic

Definition at line 142 of file mythuiimage.cpp.

Referenced by LoadImage().

◆ SupportsAnimation()

static bool ImageLoader::SupportsAnimation ( const QString &  filename)
inlinestatic

Definition at line 150 of file mythuiimage.cpp.

Referenced by MythUIImage::Load(), and ImageLoadThread::run().

◆ GenImageLabel()

static QString ImageLoader::GenImageLabel ( const ImageProperties imProps)
inlinestatic

Generates a unique identifying string for this image which is used as a key in the image cache.

Definition at line 163 of file mythuiimage.cpp.

Referenced by MythUIImage::Load(), and LoadImage().

◆ LoadImage()

static MythImage* ImageLoader::LoadImage ( MythPainter painter,
ImageProperties  imProps,
ImageCacheMode  cacheMode,
const MythUIImage parent,
bool aborted,
MythImageReader imageReader = nullptr 
)
inlinestatic

Definition at line 208 of file mythuiimage.cpp.

Referenced by MythUIImage::Load(), LoadAnimatedImage(), and ImageLoadThread::run().

◆ LoadAnimatedImage()

static AnimationFrames* ImageLoader::LoadAnimatedImage ( MythPainter painter,
const ImageProperties imProps,
ImageCacheMode  cacheMode,
const MythUIImage parent,
bool aborted 
)
inlinestatic

Definition at line 390 of file mythuiimage.cpp.

Referenced by MythUIImage::Load(), and ImageLoadThread::run().

Member Data Documentation

◆ m_loadingImages

QHash< QString, const MythUIImage * > ImageLoader::m_loadingImages
static

Definition at line 112 of file mythuiimage.cpp.

Referenced by PostLoad(), and PreLoad().

◆ m_loadingImagesLock

QMutex ImageLoader::m_loadingImagesLock
static

Definition at line 113 of file mythuiimage.cpp.

Referenced by PostLoad(), and PreLoad().

◆ m_loadingImagesCond

QWaitCondition ImageLoader::m_loadingImagesCond
static

Definition at line 114 of file mythuiimage.cpp.

Referenced by PostLoad(), and PreLoad().


The documentation for this class was generated from the following file: