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 101 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 111 of file mythuiimage.cpp.

Referenced by LoadImage().

◆ PostLoad()

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

Definition at line 137 of file mythuiimage.cpp.

Referenced by LoadImage().

◆ SupportsAnimation()

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

Definition at line 145 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 158 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 203 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 385 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 107 of file mythuiimage.cpp.

Referenced by PostLoad(), and PreLoad().

◆ m_loadingImagesLock

QMutex ImageLoader::m_loadingImagesLock
static

Definition at line 108 of file mythuiimage.cpp.

Referenced by PostLoad(), and PreLoad().

◆ m_loadingImagesCond

QWaitCondition ImageLoader::m_loadingImagesCond
static

Definition at line 109 of file mythuiimage.cpp.

Referenced by PostLoad(), and PreLoad().


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