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. QMediaPlayer does not play videos with .yuv and .y4m extension

QMediaPlayer does not play videos with .yuv and .y4m extension

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 1.0k Views
  • 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.
  • G Offline
    G Offline
    gopi
    wrote on last edited by gopi
    #1

    Hello,
    I want to play videos with .y4m or .yuv extension inside my Qt Application. I am using QT 5.4 on windows 8. I had written the following lines of code.

         QMediaPlayer *player = new QMediaPlayer;
         QVideoWidget *videoWidget = new QVideoWidget;
         QFile *file = new QFile(path to local file);
         if(!file->open(QIODevice::ReadOnly))
             qDebug() << "Could not open file";
         QUrl url = QUrl::fromLocalFile(path to local file);
         player->setMedia(url, file);
         player->setVideoOutput(videoWidget);
         videoWidget->show();
         player->play();
    

    The video files play well with the windows media player. QMediaPlayer is able to play videos with .avi extension but not y4m or yuv videos. can anyone help me?

    R 1 Reply Last reply
    0
    • G gopi

      Hello,
      I want to play videos with .y4m or .yuv extension inside my Qt Application. I am using QT 5.4 on windows 8. I had written the following lines of code.

           QMediaPlayer *player = new QMediaPlayer;
           QVideoWidget *videoWidget = new QVideoWidget;
           QFile *file = new QFile(path to local file);
           if(!file->open(QIODevice::ReadOnly))
               qDebug() << "Could not open file";
           QUrl url = QUrl::fromLocalFile(path to local file);
           player->setMedia(url, file);
           player->setVideoOutput(videoWidget);
           videoWidget->show();
           player->play();
      

      The video files play well with the windows media player. QMediaPlayer is able to play videos with .avi extension but not y4m or yuv videos. can anyone help me?

      R Offline
      R Offline
      raf924
      wrote on last edited by raf924
      #2

      @gopi Use libVLC

      1 Reply Last reply
      0

      • Login

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