I cant handle with the Pics



  • Its really strange after I moved my qt dir to a usb disk, and now i cant use pixmap or image properly.

    At first, i moved my qt-dir to usb disk and put a qt.conf into it to make it work.
    everything seemed to be good until i write:

    @...
    QPixmap pic("d:/i.jpg");//the jpg exists and i also tried QImage,all the same
    if(pic.isNull()) qDebug()<<"what the hell?";
    ....@

    and it seems the pic is NULL and can not be initialized....

    but the pixmap shows just fine when i take the qt dir back to my hard dist, the original place.

    Now i cant handle with the pics.
    its wired. How to fix it?


  • Moderators

    Image plugins are missing. Add plugins directory and copy relevant libraries (qjpeg, qgif etc.) into it.



  • [quote author="sierdzio" date="1352721973"]Image plugins are missing. Add plugins directory and copy relevant libraries (qjpeg, qgif etc.) into it.[/quote]

    Thank u so much!

    its solved now


  • Moderators

    Perfect :D Please add [Solved] to the beginning of this topic's subject if you have no further questions related to this problem.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.