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. [QMultiMedia] How do I stop the program flow while a video is being played?
Forum Updated to NodeBB v4.3 + New Features

[QMultiMedia] How do I stop the program flow while a video is being played?

Scheduled Pinned Locked Moved Unsolved General and Desktop
6 Posts 3 Posters 813 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hello,
    I'm currently working on a video player where the user can affect the story via eye tracking.
    The problem is that the QMediaPlayer only plays the last video file because it does not stop the flow before the current video is finished.

    How can I solve this problem?
    thanks

    jsulmJ 1 Reply Last reply
    0
    • ? A Former User

      Hello,
      I'm currently working on a video player where the user can affect the story via eye tracking.
      The problem is that the QMediaPlayer only plays the last video file because it does not stop the flow before the current video is finished.

      How can I solve this problem?
      thanks

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @SnuggleKat What flow do you mean? How do you play the videos?

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      2
      • ? Offline
        ? Offline
        A Former User
        wrote on last edited by
        #3

        By flow I mean the procedure with all the branching of the program.
        The first video is being played this way:

         QMediaPlayer* player = new QMediaPlayer;
            QVideoWidget* vw = new QVideoWidget;
            QRect rec = QApplication::desktop()->screenGeometry();
        
            player->setVideoOutput(vw);
            player->setMedia(QUrl::fromLocalFile(link));
            vw->setGeometry(0, 0, rec.width(), rec.height());
            vw->show();
        player->play();
        
        jsulmJ 1 Reply Last reply
        0
        • ? A Former User

          By flow I mean the procedure with all the branching of the program.
          The first video is being played this way:

           QMediaPlayer* player = new QMediaPlayer;
              QVideoWidget* vw = new QVideoWidget;
              QRect rec = QApplication::desktop()->screenGeometry();
          
              player->setVideoOutput(vw);
              player->setMedia(QUrl::fromLocalFile(link));
              vw->setGeometry(0, 0, rec.width(), rec.height());
              vw->show();
          player->play();
          
          jsulmJ Offline
          jsulmJ Offline
          jsulm
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @SnuggleKat And how do you play the next one?

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • ? Offline
            ? Offline
            A Former User
            wrote on last edited by A Former User
            #5

            This is dependent by what position the user is looking at.
            There are 3 sectors the user can look at. E.g.If the eye tracking device detects a range of 0 - 0.48 video 1.1 will be played.
            But this did not work. Now I just thought about creating a playlist which will be changed

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

              Hi,

              And what code are you using to handle the next video that should be played ?

              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