videosurface.h 745 B

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