Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. is it possible streaming video via network?
Forum Updated to NodeBB v4.3 + New Features

is it possible streaming video via network?

Scheduled Pinned Locked Moved Solved General and Desktop
2 Posts 2 Posters 974 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • liewjlsL Offline
    liewjlsL Offline
    liewjls
    wrote on last edited by liewjls
    #1

    Hi,

    I know there's some example how to shows how to the play a video using a local video file and the samples codes works fine. But as soon as i replace the local video file with my url of video server, it doesn't work.

    and i got a warning msg "Warning: "No decoder available for type 'video/x-asf-unknown, fourcc=(uint)1986490477'."".

    I used the same url on vlc player or mpv, these player is able to stream the live video feed from my video server properly. Is it possible to use QMediaPlayer to stream live video feed via network?

    Some forum said need to libvlc to this. Anyone can point me to right and easier way to do this?

        QMediaPlayer *player = new QMediaPlayer();
        QVideoWidget *videoWidge = new QVideoWidget();
    
        videoWidge->show();
    
       //load the mp4 video file directly works ok.
        //player->setMedia(QUrl::fromLocalFile("/home/test/testVide.mp4"));
    
        //try to to connect to my video server
        QUrl url = QUrl("http://192.168.0.1:1234");
        const QNetworkRequest requete(url);
        player->setMedia(requete);
    
        player->setVideoOutput(videoWidge);
        player->play();
    
    

    Thanks in advance.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      If you want more advanced multimedia capability then the VLC-Qt project is likely what you want use.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      1

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved