qt/LedOK/player/elevideo.h

21 lines
464 B
C
Raw Normal View History

2022-01-20 10:08:17 +08:00
#ifndef ELEVIDEO_H
#define ELEVIDEO_H
2022-08-25 18:37:24 +08:00
#include "ffplayer.h"
#include <QWidget>
class EleVideo : public QWidget {
2022-01-20 10:08:17 +08:00
Q_OBJECT
public:
explicit EleVideo(QString path, QWidget *parent = nullptr);
2022-08-25 18:37:24 +08:00
~EleVideo() {if(player!=0) player->quit(); }
FFPlayer *player = nullptr;
QImage img;
2022-01-20 10:08:17 +08:00
protected:
2022-08-25 18:37:24 +08:00
void paintEvent(QPaintEvent *) override;
void showEvent(QShowEvent *) override;
void hideEvent(QHideEvent *) override;
2022-01-20 10:08:17 +08:00
};
#endif // ELEVIDEO_H