You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
PayloadAPP/ffmpegvideodlg.h

70 lines
1.1 KiB
C

#ifndef FFMPEGVIDEODLG_H
#define FFMPEGVIDEODLG_H
#include <QImage>
#include <QWidget>
#include <QPaintEvent>
#include <QThread>
#include <QPainter>
#include <QDebug>
#include <QDir>
#include "cffmpeg_decode.h"
extern "C"{
#include <libavcodec/avcodec.h>
#include <libavutil/channel_layout.h>
#include <libavutil/common.h>
#include <libavutil/frame.h>
#include <libavutil/samplefmt.h>
#include <libavutil/opt.h>
#include <libavutil/imgutils.h>
#include <libavutil/parseutils.h>
#include <libavutil/mem.h>
#include <libswscale/swscale.h>
#include <libavformat/avformat.h>
}
namespace Ui {
class ffmpegvideoDlg;
}
class ffmpegvideoDlg : public QWidget
{
Q_OBJECT
public:
explicit ffmpegvideoDlg(QWidget *parent = nullptr);
~ffmpegvideoDlg();
private:
Ui::ffmpegvideoDlg *ui;
public:
void iniWindow();
void setUrl(QString url);
void play();
void stop();
bool Isplay(bool IsstopPlay);
bool m_PlayStatus =false;
protected:
void paintEvent(QPaintEvent *);
private slots:
void receiveQImage(const QImage &rImg);
private:
Cffmpeg_decode *ffmpeg;
QImage img;
};
#endif // FFMPEGVIDEODLG_H