Results 1 to 5 of 5

Thread: Playing audio file at different pitches. Phonon? Qt Multimedia?

  1. #1
    Join Date
    Jun 2011
    Posts
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default Playing audio file at different pitches. Phonon? Qt Multimedia?

    Hi

    I'm working on an app that play sounds (from audio files, let's say wav) at different pitches than the original pitch of the audio file. I did my test app on Mathematica and now that the concept is alright I want to make a stand alone app with Qt.
    For the GUIO etc Qt covers everything I need but I have been seeking for a good solution to play files at different pitches and I don't seem to find it. Phonon seems a good and easy solution but I would have to find an effect for pitch shifting, which doesn't seem to be easy. I checked my windows 7 laptop with the phonon capabilities app and no pitch shifting effect appears. Besides, I need this app to be portable so I'm not sure if I depend on the backend of the computer where I install my software. If no pitch shifting effect, no app working fine.
    On the other hand Qt offers QT Multimedia with QSound etc. I haven't found a way of changing the pitch of the audio file neither. Any advice on Phonon vs QTMultimedia as well as on where to find pitch shifting effect for windows would be much appreciated.
    Thank you very much in advance.
    Best reagds
    Juan

  2. #2
    Join Date
    Jun 2011
    Posts
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Playing audio file at different pitches. Phonon? Qt Multimedia?

    No replies? Is that weird my question? Or doesn't it have any interest?
    Juan

  3. #3
    Join Date
    Apr 2010
    Posts
    769
    Thanks
    1
    Thanked 94 Times in 86 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Playing audio file at different pitches. Phonon? Qt Multimedia?

    Your question isn't clear. If you want to raise or lower pitch and are content to let the playback time drift, simply change the sampling rate. If you want to keep the playback time constant while changing pitch, that's a much harder trick to pull off and requires Fourier transforms or similar techniques.

    Since you seem to have encountered this elsewhere, use that library. Qt is just C++, and can link with and use any existing C/C++ software toolkits.

  4. #4
    Join Date
    Jun 2011
    Posts
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Playing audio file at different pitches. Phonon? Qt Multimedia?

    Hi
    Thank yo so much for your reply.
    I would say that if I'm looking for an specific effect on Phonon or a way to change pitch in Qt Multimadia, it is clear that the old trick of changing the sample rate is not valid for me in this particular project, althought I could have said so in my first post specifically, so the question is more clear. So yes, maybe the question is not totally clear.
    I didn't say that I have found any library or whatever elsewhere (quote: "Since you seem to have encountered this elsewhere, use that library"), I don't know where you find that info. In any case, I thank you again ofr your reply, and now it seems clera to me that there's no direct way to do what I need with either Phonon or Qt Multimedia. I'll have to look for this somewhere else.

    Juan

  5. #5
    Join Date
    Jun 2011
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Playing audio file at different pitches. Phonon? Qt Multimedia?

    In gstreamer-backend on linux you got the speed effect "pitch" ;-)

Similar Threads

  1. Playing file with Phonon while stil downloading it.
    By alexandernst in forum Qt Programming
    Replies: 3
    Last Post: 10th April 2011, 11:25
  2. can't get o/p by playing mp3 file in Phonon
    By dibyendu in forum Qt Programming
    Replies: 1
    Last Post: 16th February 2011, 13:09
  3. Replies: 4
    Last Post: 28th December 2010, 04:13
  4. Playing multiple audio files with Phonon
    By MartinWalter in forum Qt Programming
    Replies: 0
    Last Post: 23rd December 2010, 11:19
  5. Phonon won't play audio file
    By kar in forum Qt Programming
    Replies: 5
    Last Post: 29th October 2010, 01:41

Tags for this Thread

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.