videosurface.h 737 B

123456789101112131415161718192021222324252627
  1. #ifndef VIDEOSURFACE_H
  2. #define VIDEOSURFACE_H
  3. #include <QAbstractVideoSurface>
  4. #include <QVideoSurfaceFormat>
  5. #include "qdll_global.h"
  6. class FrameObserver;
  7. class QDLLSHARED_EXPORT VideoSurface : public QAbstractVideoSurface
  8. {
  9. Q_OBJECT
  10. public:
  11. explicit VideoSurface(FrameObserver *frameObserver, QObject *parent = 0);
  12. virtual ~VideoSurface();
  13. virtual QList<QVideoFrame::PixelFormat> supportedPixelFormats(QAbstractVideoBuffer::HandleType handleType = QAbstractVideoBuffer::NoHandle) const;
  14. virtual bool present(const QVideoFrame &frame);
  15. virtual bool start(const QVideoSurfaceFormat &format);
  16. protected:
  17. FrameObserver *m_frameObserver; // Not owned
  18. };
  19. #endif // VIDEOSURFACE_H