Results 1 to 2 of 2

Thread: seekslider with streming flv video

  1. #1
    Join Date
    Oct 2006
    Posts
    16
    Thanks
    1
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default seekslider with streming flv video

    hi,

    I'm in trouble understanding the behaviour of seekSlider giving me when playing a .flv video from the net.
    Here the code I use:

    Qt Code:
    1. mediaObject=videoPlayer->mediaObject();
    2. mediaObject->setCurrentSource(Phonon::MediaSource(url));
    3. mediaObject->setObjectName("Video_output");
    4.  
    5. videoPlayer->videoWidget()->setObjectName("Videowidget");
    6.  
    7. audioOutput = videoPlayer->audioOutput();
    8. audioOutput->setObjectName("Audio_output");
    9.  
    10. seekSlider->setMediaObject(mediaObject);
    11. seekSlider->setSingleStep(1000);
    12.  
    13. connect(mediaObject, SIGNAL(tick(qint64)), this, SLOT(tick(qint64)));
    14. connect(mediaObject, SIGNAL(seekableChanged(bool)), this, SLOT(seekableChanged(bool)));
    15. connect(mediaObject, SIGNAL(finished()), this, SLOT(onVideoPlayFinished()) );
    16.  
    17. mediaObject->play();
    To copy to clipboard, switch view to plain text mode 

    when I use videoPlayer->seek(n) or move it manually in the gui and the url (streming from internet) is a .mp4 the slider works, when its a .flv the video restarts. But when the .flv is stored on the hd it works as expected.
    The seekableChanged always return true.

    thanks for any suggestions
    regards
    Marco

  2. #2
    Join Date
    Oct 2006
    Posts
    16
    Thanks
    1
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: seekslider with streming flv video

    well, I didn't find a solution yet (if there is one). The player should stream from youtube, so, maybe this is the problem. I forgot to mention that I tried to stream a .flv from the other pc through http and it works.
    I have a gitorious repo for who like to view the code:
    git://gitorious.org/mediadownloader/mediadownloader.git
    that function is in mediaplayer.cpp at line 453

    thanks for all

Similar Threads

  1. how to set duration of a video in a video player in qt
    By qt_user in forum Qt Programming
    Replies: 1
    Last Post: 7th August 2010, 10:51
  2. Playing video using Phonon video widget
    By Leolander in forum Newbie
    Replies: 0
    Last Post: 26th February 2010, 06:15
  3. Phonon seekslider
    By yogourta in forum Installation and Deployment
    Replies: 0
    Last Post: 17th December 2009, 03:33
  4. Video freezes during mpeg video playback using Phonon
    By davejames in forum Qt Programming
    Replies: 2
    Last Post: 12th January 2009, 08:45

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.