QT4.8.4 : QtQuick 1.1 : images ressource management
-
Hello,
I am devlopping a QML application.
I would like to know if there is a difference between :- 2 instances loading and rendering the same image file
- 2instances loading and rendering 2 duplicated files
in other words:
if img2.svg is a copy of img1.svg, are the 2 following code equivalent in term of performances and ressource consumption:@Image {
id:iImg1
source: "Images/img1.svg"
}
Image {
id:iImg2
source: "Images/img2.svg"
}
@
and
@Image {
id:iImg1
source: "Images/img1.svg"
}
Image {
id:iImg2
source: "Images/img1.svg"
}
@ -
I think the second option (both Images loading img1.svg) will use less memory because of internal engine optimizations, but you would need to check that yourself to be sure.
-
OK, I just tested, and YES it is slower and memory consuming to load 2 duplicated images.
-
Nice, so now we know for sure :-)