Results 1 to 2 of 2

Thread: Qt 4.6.2 and QMediaPlyer

  1. #1
    Join Date
    Oct 2014
    Posts
    3
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Unhappy Qt 4.6.2 and QMediaPlyer

    Hi,
    My setup is this for the development machine:
    - Ubuntu 10.04 LTS
    - QT 4.6.2
    - QMake: Qt-arm-X11
    and for the embedded computer:
    - Anders DX4 with CM-T3730 (ARMv7a based)
    - Linux distro: Angstrom

    I've been struggling to put a simple window playing an mp4 video. As simple as this: just playing a video!
    After a few months trying everything, from simple to complex solutions, I just don't know where to turn to. I need help!
    I don't have neither qmediaplayer libraries nor phonon ones installed.
    Is there out there a kind soul that can help me install, for instance, qmediaplayer which I find to be easier to play with so I can play the video?
    If there is a quick solution please can you guide me on how to achieve it?
    Thanks in advance.

  2. #2
    Join Date
    Oct 2014
    Posts
    3
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Qt 4.6.2 and QMediaPlyer

    Hi,
    I've manage to use mplayer calling it from the main app using this slot:

    void MainWindow:n_pushbutton_video_clicked()
    {
    FILE* pipe;
    int i;
    QMainWindow::showMinimized();
    pipe=popen("mplayer -fs 'teste_video.mp4'", "w");
    pclose(pipe);
    QMainWindow::showFullScreen();
    }

    This sorts out the problem, however, I add to use that 'showMinimized' function otherwise the video was played behind the main window.
    Now this is the problem: after the video finishes, the video window closes and it stays like that! I tried the last line of code to put the main app back but nothing happens...
    Any ideas?
    Thanks

Tags for this Thread

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.