This happened when scrolling a view using an Image delegate (containing
QSGTexture). All textures were deleted at exit, but it is important to
immediately schedule the texture for deletion whenever the delegate is
destroyed to avoid unnecessary high memory consumption.
Task-number: QTBUG-19511
Reviewed-by: gunnar
int QDeclarativePixmapData::cost() const
{
+ if (texture) {
+ const QSize textureSize = texture->textureSize();
+ return textureSize.width() * textureSize.height();
+ }
return (pixmap.width() * pixmap.height() * pixmap.depth()) / 8;
}