Results 1 to 2 of 2

Thread: A Question about Use QSound to Play Wav Files??

  1. #1
    Join Date
    May 2006
    Posts
    2
    Qt products
    Qt/Embedded
    Platforms
    Unix/X11

    Unhappy A Question about Use QSound to Play Wav Files??

    Referce to the doc of QSound class , I place the follow code into the example.

    I used relative and absolute path to load the wav file respective
    QSound:lay("./sound.wav");
    or
    QSound belles("./sound.wav");
    belles.play();

    and

    QSound:lay("/usr/qt4/sound.wav");
    or
    QSound belles("/usr/qt4/sound.wav");
    belles.play();

    but they meet error:QWSSocket::connectToLocalFile could not connect::No such file of directory .

    then , I remove all the macros QT_NO_SOUND and QT_NO_QWS_SOUNDSERVER in the qt src and recompile it ,but I fail again to use the QSound class.
    what 's wrong ?

    My os is linux -- Fedora --FC4 and qt ver is qtopia4.1.2. I implement the qt program under the linux text mode. and my login user is root.

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: A Question about Use QSound to Play Wav Files??

    Did you pass -system-nas-sound switch to the configure utility when you were building Qt?

Similar Threads

  1. Unable to play gif files
    By yellowmat in forum Newbie
    Replies: 2
    Last Post: 24th March 2006, 20:24
  2. [Win32/VC++ 8.0] Strange problems with qrc_*.cpp files
    By mloskot in forum Installation and Deployment
    Replies: 6
    Last Post: 6th March 2006, 11:28

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.