Qt World Summit: Register Today!

[SOLVED][VLC]Fullscreen video

  • Hello,
    There's no method to show a VlcWidgetVideo in fullscreen ?
    #ifndef PRINCIPAL_H
    #define PRINCIPAL_H

    #include <QMainWindow>
    #include <QLibrary>
    #include <QMainWindow>
    #include <QtWidgets>
    #include <vlc/VLCQtCore/Instance.h>
    #include <vlc/VLCQtCore/MediaPlayer.h>
    #include <vlc/VLCQtCore/Media.h>
    #include <vlc/VLCQtCore/Common.h>

    namespace Ui {
    class Principal;

    class Principal : public QMainWindow

    explicit Principal(QWidget *parent = 0);
    public slots:
    void player();

    private :
    VlcMedia * _media;
    VlcInstance* _instance;
    VlcMediaPlayer* _player;

    Ui::Principal *ui;

    void keyPressEvent(QKeyEvent *event);
    void mouseDoubleClickEvent(QMouseEvent *event);

    #endif // PRINCIPAL_H

    thanks !

  • Lifetime Qt Champion


    That will partly depend on your widgets setup. Note that showFullScreen might be what you are looking for.

    Hope it helps

  • #include "principal.h"
    #include "ui_principal.h"

    Principal::Principal(QWidget *parent) :
    QMainWindow(parent), ui(new Ui::Principal)
    _instance = new VlcInstance(VlcCommon::args(), this);
    _player = new VlcMediaPlayer(_instance);
    connect(ui->actionAjouter_video, SIGNAL(triggered()), this, SLOT(player()));

    The program contains QVlcWidgetVideo, QPushButton(play, equalizer, pause, reset) and menu bar, all in layouts.

    ui->widget->showFullScreen() doesn't work.

  • Lifetime Qt Champion

    It's a widget in a layout, you can't just show it fullscreen

Log in to reply