Results 1 to 1 of 1

Thread: SDL - Audio and QT Creator Sound

  1. #1
    Join Date
    Jul 2010
    Location
    /home/hakermania/
    Posts
    233
    Thanks
    129
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Question SDL - Audio and QT Creator Sound

    I am trying to load and play once a .ogg file with SDL. This is the code:
    Qt Code:
    1. #include <SDL/SDL.h>
    2. #include <SDL/SDL_mixer.h>
    3. int main()
    4. {
    5. Mix_Music *music = NULL;
    6. music = Mix_LoadMUS("music.ogg");
    7. Mix_PlayMusic(music, 0);
    8. }
    To copy to clipboard, switch view to plain text mode 
    It doesn't work, it says collect2:ld returned 1 exit status
    I would very happy ig somebody could fix it for me becauz i've searched the whole web for finding a simple example of opening a playing a file with SDL, but I would always ask if there is any Qt library for playing audio files...
    Last edited by hakermania; 30th August 2010 at 22:44. Reason: title fixed

Similar Threads

  1. Sound Volume
    By anafor2004 in forum Qt for Embedded and Mobile
    Replies: 7
    Last Post: 2nd February 2011, 06:03
  2. Multiple sound files in Phonon Audio
    By brent99 in forum Qt Programming
    Replies: 0
    Last Post: 8th March 2010, 21:26
  3. Sound Recorder
    By davejh in forum Qt Programming
    Replies: 3
    Last Post: 20th March 2009, 13:00
  4. MP3 Sound / OGG Sound Play on GUI
    By patrik08 in forum Newbie
    Replies: 3
    Last Post: 1st September 2006, 19:01
  5. Sound on KDE 3.5
    By jaynewpeng in forum KDE Forum
    Replies: 6
    Last Post: 2nd February 2006, 13:06

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.