Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QQuickPixmapData Class Reference
+ Collaboration diagram for QQuickPixmapData:

Public Member Functions

 QQuickPixmapData (const QUrl &u, const QRect &r, const QSize &rs, const QQuickImageProviderOptions &po, const QString &e)
 
 QQuickPixmapData (const QUrl &u, const QRect &r, const QSize &s, const QQuickImageProviderOptions &po, QQuickImageProviderOptions::AutoTransform aTransform, int frame=0, int frameCount=1)
 
 QQuickPixmapData (const QUrl &u, QQuickTextureFactory *texture, const QSize &s, const QRect &r, const QSize &rs, const QQuickImageProviderOptions &po, QQuickImageProviderOptions::AutoTransform aTransform, int frame=0, int frameCount=1)
 
 QQuickPixmapData (QQuickTextureFactory *texture)
 
 ~QQuickPixmapData ()
 
int cost () const
 
void addref ()
 
void release (QQuickPixmapCache *store=nullptr)
 
void addToCache ()
 
void removeFromCache (QQuickPixmapCache *store=nullptr)
 

Public Attributes

uint refCount
 
int frameCount
 
int frame
 
bool inCache:1
 
QQuickPixmap::Status pixmapStatus
 
QUrl url
 
QString errorString
 
QSize implicitSize
 
QRect requestRegion
 
QSize requestSize
 
QQuickImageProviderOptions providerOptions
 
QQuickImageProviderOptions::AutoTransform appliedTransform
 
QColorSpace targetColorSpace
 
QIODevicespecialDevice = nullptr
 
QQuickTextureFactorytextureFactory
 
QQuickPixmapReplyreply
 
QQuickPixmapDataprevUnreferenced
 
QQuickPixmapData ** prevUnreferencedPtr
 
QQuickPixmapDatanextUnreferenced
 

Detailed Description

The private storage for QQuickPixmap.

Definition at line 301 of file qquickpixmapcache.cpp.

Constructor & Destructor Documentation

◆ QQuickPixmapData() [1/4]

QQuickPixmapData::QQuickPixmapData ( const QUrl & u,
const QRect & r,
const QSize & rs,
const QQuickImageProviderOptions & po,
const QString & e )
inline

Definition at line 304 of file qquickpixmapcache.cpp.

◆ QQuickPixmapData() [2/4]

QQuickPixmapData::QQuickPixmapData ( const QUrl & u,
const QRect & r,
const QSize & s,
const QQuickImageProviderOptions & po,
QQuickImageProviderOptions::AutoTransform aTransform,
int frame = 0,
int frameCount = 1 )
inline

Definition at line 317 of file qquickpixmapcache.cpp.

◆ QQuickPixmapData() [3/4]

QQuickPixmapData::QQuickPixmapData ( const QUrl & u,
QQuickTextureFactory * texture,
const QSize & s,
const QRect & r,
const QSize & rs,
const QQuickImageProviderOptions & po,
QQuickImageProviderOptions::AutoTransform aTransform,
int frame = 0,
int frameCount = 1 )
inline

Definition at line 330 of file qquickpixmapcache.cpp.

◆ QQuickPixmapData() [4/4]

QQuickPixmapData::QQuickPixmapData ( QQuickTextureFactory * texture)
inline

Definition at line 344 of file qquickpixmapcache.cpp.

References implicitSize, and requestSize.

◆ ~QQuickPixmapData()

QQuickPixmapData::~QQuickPixmapData ( )
inline

Definition at line 357 of file qquickpixmapcache.cpp.

References textureFactory.

Member Function Documentation

◆ addref()

void QQuickPixmapData::addref ( )

Definition at line 1436 of file qquickpixmapcache.cpp.

References QQuickPixmapCache::instance(), PIXMAP_PROFILE, prevUnreferencedPtr, refCount, and url.

Referenced by QQuickPixmap::load(), QQuickPixmap::loadImageFromDevice(), and QQuickPixmap::setPixmap().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addToCache()

void QQuickPixmapData::addToCache ( )

Add this to the QQuickPixmapCache singleton.

Note
The actual image will end up in QQuickPixmapData::textureFactory. At the time addToCache() is called, it's generally not yet loaded; so the qCDebug() below cannot say how much data we're committing to storing. (On the other hand, removeFromCache() can tell.) QQuickTextureFactory is an abstraction for image data. See QQuickDefaultTextureFactory for example: it stores a QImage directly. Other QQuickTextureFactory subclasses store data in other ways.

Definition at line 1489 of file qquickpixmapcache.cpp.

References frame, inCache, QQuickPixmapCache::instance(), it, PIXMAP_PROFILE, providerOptions, qCDebug, qDebug, requestRegion, requestSize, and url.

Referenced by QQuickPixmap::QQuickPixmap(), QQuickPixmap::load(), and QQuickPixmap::loadImageFromDevice().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ cost()

int QQuickPixmapData::cost ( ) const

Definition at line 1429 of file qquickpixmapcache.cpp.

References QQuickTextureFactory::textureByteCount(), and textureFactory.

+ Here is the call graph for this function:

◆ release()

void QQuickPixmapData::release ( QQuickPixmapCache * store = nullptr)

Definition at line 1444 of file qquickpixmapcache.cpp.

References QQuickPixmapReply::data, QQuickPixmapReader::existingInstance(), inCache, QQuickPixmapCache::instance(), PIXMAP_PROFILE, pixmapStatus, Q_ASSERT, QQuickPixmapReader::readerMutex, QQuickPixmap::Ready, refCount, removeFromCache(), reply, QQuickPixmapCache::unreferencePixmap(), and url.

Referenced by QQuickPixmap::~QQuickPixmap(), QQuickPixmap::clear(), QQuickPixmap::clear(), QQuickPixmap::load(), QQuickPixmap::setImage(), and QQuickPixmap::setPixmap().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ removeFromCache()

void QQuickPixmapData::removeFromCache ( QQuickPixmapCache * store = nullptr)

Definition at line 1508 of file qquickpixmapcache.cpp.

References frame, implicitSize, inCache, QQuickPixmapCache::instance(), PIXMAP_PROFILE, providerOptions, qCDebug, QHash< Key, T >::remove(), requestRegion, requestSize, QHash< Key, T >::size(), and url.

Referenced by release().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ appliedTransform

QQuickImageProviderOptions::AutoTransform QQuickPixmapData::appliedTransform

Definition at line 381 of file qquickpixmapcache.cpp.

Referenced by QQuickPixmap::autoTransform().

◆ errorString

QString QQuickPixmapData::errorString

Definition at line 376 of file qquickpixmapcache.cpp.

Referenced by QQuickPixmap::error().

◆ frame

int QQuickPixmapData::frame

Definition at line 370 of file qquickpixmapcache.cpp.

Referenced by addToCache(), and removeFromCache().

◆ frameCount

int QQuickPixmapData::frameCount

Definition at line 369 of file qquickpixmapcache.cpp.

Referenced by QQuickPixmap::frameCount().

◆ implicitSize

QSize QQuickPixmapData::implicitSize

◆ inCache

bool QQuickPixmapData::inCache

Definition at line 372 of file qquickpixmapcache.cpp.

Referenced by addToCache(), release(), and removeFromCache().

◆ nextUnreferenced

QQuickPixmapData* QQuickPixmapData::nextUnreferenced

◆ pixmapStatus

QQuickPixmap::Status QQuickPixmapData::pixmapStatus

Definition at line 374 of file qquickpixmapcache.cpp.

Referenced by release(), and QQuickPixmap::status().

◆ prevUnreferenced

QQuickPixmapData* QQuickPixmapData::prevUnreferenced

◆ prevUnreferencedPtr

QQuickPixmapData** QQuickPixmapData::prevUnreferencedPtr

◆ providerOptions

QQuickImageProviderOptions QQuickPixmapData::providerOptions

Definition at line 380 of file qquickpixmapcache.cpp.

Referenced by addToCache(), and removeFromCache().

◆ refCount

uint QQuickPixmapData::refCount

Definition at line 368 of file qquickpixmapcache.cpp.

Referenced by addref(), QQuickPixmap::loadImageFromDevice(), and release().

◆ reply

◆ requestRegion

QRect QQuickPixmapData::requestRegion

Definition at line 378 of file qquickpixmapcache.cpp.

Referenced by addToCache(), removeFromCache(), and QQuickPixmap::requestRegion().

◆ requestSize

QSize QQuickPixmapData::requestSize

◆ specialDevice

QIODevice* QQuickPixmapData::specialDevice = nullptr

Definition at line 384 of file qquickpixmapcache.cpp.

Referenced by QQuickPixmap::loadImageFromDevice().

◆ targetColorSpace

QColorSpace QQuickPixmapData::targetColorSpace

Definition at line 382 of file qquickpixmapcache.cpp.

◆ textureFactory

◆ url

QUrl QQuickPixmapData::url

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