Results 1 to 5 of 5

Thread: Playing a stream using phonon module

  1. #1
    Join Date
    Aug 2008
    Posts
    12
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11

    Default Playing a stream using phonon module

    Hi i want to play a strem in qtopia core ( built for n800 - phonon module ) but i am not able to play it ... Works fine if the source is a file ....

    The code goes as follows

    Qt Code:
    1. MainWindow::MainWindow()
    2. {
    3. Phonon::MediaObject *mediaObject = new Phonon::MediaObject(this);
    4.  
    5. Phonon::AudioOutput *audioOutput =
    6. new Phonon::AudioOutput(Phonon::MusicCategory, this);
    7.  
    8. Phonon::createPath(mediaObject, audioOutput);
    9.  
    10. const QUrl url("http://www.example.com/stream");
    11.  
    12. mediaObject->setCurrentSource(url);
    13.  
    14. mediaObject->play();
    15.  
    16. }
    To copy to clipboard, switch view to plain text mode 
    Last edited by jpn; 28th August 2008 at 08:57. Reason: missing [code] tags

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Playing a stream using phonon module

    Can you access the file over network at all? For instance by downloading it using QHttp?

  3. #3
    Join Date
    Aug 2008
    Posts
    12
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11

    Default Re: Playing a stream using phonon module

    Ya i am able to download a file using QHttp.
    Should we enable any mime types exclusively for playing a stream.

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Playing a stream using phonon module

    It could be that your Phonon backend doesn't support remote streams. Try querying it for its capabilities.

  5. #5
    Join Date
    Aug 2008
    Posts
    12
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11

    Default Re: Playing a stream using phonon module

    I am using the same program for x11-4.4.1 version where the phonon is able to play the stream. The same program with qtopia-core-4.4.1 is not playing the stream.

    Both the x11 and qtopia-core are configured with the same options

    I will query the further capabilities of Phonon ...

Similar Threads

  1. Replies: 0
    Last Post: 5th August 2008, 10:54
  2. Is it possible to stream data from device with phonon ?
    By Elder Orb in forum Qt-based Software
    Replies: 0
    Last Post: 24th July 2008, 19:58
  3. Phonon video not playing
    By SidGBF in forum Qt Programming
    Replies: 2
    Last Post: 11th July 2008, 15:30
  4. no phonon module :(
    By losiem in forum Installation and Deployment
    Replies: 2
    Last Post: 8th July 2008, 12:31

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.