This code works perfectly on the pc, as well as on the mac but only for .png files. I've seen other threads on this, but none that address QImage loading on windows but not the macOS. I put the imageformats folder in the package too. It doesn't even work on the development machine. Any help is greatly appreciated!
Sean
if(tempImage.load(tempImageFileName))
{
/*
/users/images/test.JPG does not work
but
/users/images/test.PNG does work
*/
}
else
{
QMessageBox::information(NULL,
"Test QImage Load",
"Unable to load image: " + tempImageFileName
);
}
QImage tempImage;
if(tempImage.load(tempImageFileName))
{
/*
/users/images/test.JPG does not work
but
/users/images/test.PNG does work
*/
}
else
{
QMessageBox::information(NULL, "Test QImage Load", "Unable to load image: " + tempImageFileName);
}
To copy to clipboard, switch view to plain text mode
Bookmarks