Resources not accessible when running outside of qtcreator [SOLVED / Problem related to unsopported image file formats]
-
Qt 4.7.0 / Win32 / mingw
Hello, I have this application opening several images files that are stored inside a resouce file, through the simple QImage::load method.
When executing this from within qtcreator IDE, this application works smoothly. The files are accessed with ":/somedir1/filename.ext"
But, when I start the application outside of qtcreator, by double clicking on the .exe file, it reports that some of my resources files can not be accessed. The WEIRD thing is that it depends on the PC I try to run the application on, it's working smoothly on two PC, but not on the third I tested. Do you see any reasons why?
Thank you,
Bill -
Do you have resources embedded into your binary? Or you have them as external files that you load on run-time?
-
I guess they are embedded in the binary, I have done nothing specific. The qrc files are listed in the .pro file.
-
Then they are embedded. Now, what could happen, is that the image format plug-ins are not available. They are needed. see "this thread.":http://developer.qt.nokia.com/forums/viewthread/4440/
-
Thank you, I am having a look now!
-
Yep, I'm agreed with Gerolf. Looks like plugins are not available.
-
Thank you both, gonna try this afternoon or maybe in one week, and will let you know,
Bill
-
We can lock this thread, the whole thing it working when copying the image decoding dll in the output directory. Thank you for the hint. I guess it is possible to simply link this library statically then? If you know how, I am interested!
Thanks,
Bill -
Thank you both,
Bill