69 if (!qt_vg_image_pool)
76 if (qt_vg_image_pool != pool)
78 qt_vg_image_pool = pool;
82 VGint width, VGint height,
83 VGbitfield allowedQuality,
88 image = vgCreateImage(format, width, height, allowedQuality);
89 if (image != VG_INVALID_HANDLE)
92 qWarning(
"QVGImagePool: cannot reclaim sufficient space for a %dx%d temporary image",
94 return VG_INVALID_HANDLE;
98 VGint width, VGint height,
99 VGbitfield allowedQuality,
104 image = vgCreateImage(format, width, height, allowedQuality);
105 if (image != VG_INVALID_HANDLE) {
111 qWarning(
"QVGImagePool: cannot reclaim sufficient space for a %dx%d pixmap",
113 return VG_INVALID_HANDLE;
117 VGint width, VGint height,
118 VGbitfield allowedQuality)
122 image = vgCreateImage(format, width, height, allowedQuality);
123 if (image != VG_INVALID_HANDLE)
126 qWarning(
"QVGImagePool: cannot reclaim sufficient space for a %dx%d image",
128 return VG_INVALID_HANDLE;
136 vgDestroyImage(image);
150 VGint width, VGint height,
157 bool succeeded =
false;
158 bool wasInLRU =
false;
160 wasInLRU = data->
inLRU;
165 if (lrudata && lrudata != data) {
170 if (data && !wasInLRU)
205 d->lruFirst->prevLRU =
data;
virtual void useImage(QVGPixmapData *data)
#define QT_END_NAMESPACE
This macro expands to.
virtual VGImage createPermanentImage(VGImageFormat format, VGint width, VGint height, VGbitfield allowedQuality)
virtual VGImage createImageForPixmap(VGImageFormat format, VGint width, VGint height, VGbitfield allowedQuality, QVGPixmapData *data)
void moveToHeadOfLRU(QVGPixmapData *data)
virtual VGImage createTemporaryImage(VGImageFormat format, VGint width, VGint height, VGbitfield allowedQuality, QVGPixmapData *keepData=0)
#define QT_BEGIN_NAMESPACE
This macro expands to.
Q_CORE_EXPORT void qWarning(const char *,...)
static const char * data(const QByteArray &arr)
static void setImagePool(QVGImagePool *pool)
static QVGImagePool * qt_vg_image_pool
void removeFromLRU(QVGPixmapData *data)
static QVGImagePool * instance()
QVGPixmapData * pixmapLRU()
virtual bool reclaimSpace(VGImageFormat format, VGint width, VGint height, QVGPixmapData *data)
virtual void detachImage(QVGPixmapData *data)
#define Q_UNUSED(x)
Indicates to the compiler that the parameter with the specified name is not used in the body of a fun...
virtual void releaseImage(QVGPixmapData *data, VGImage image)
virtual void reclaimImages()