| 12345678910111213141516171819202122232425262728 |
- #ifndef DXGICAPTURER_H
- #define DXGICAPTURER_H
- #include "IVideoCapturer.h"
- #include <d3d11.h>
- #include <dxgi1_2.h>
- namespace avrecorder {
- namespace video {
- class DxgiCapturer : public IVideoCapturer {
- public:
- DxgiCapturer();
- ~DxgiCapturer() override;
- bool open(const CaptureTarget& target, int width, int height) override;
- void close() override;
- AVFrame* getFrame() override;
- void setDrawCursor(bool enable) override { m_drawCursor = enable; }
- private:
- class DxgiCapturerPrivate* d;
- bool m_drawCursor = true;
- int m_left = 0, m_top = 0, m_width = 0, m_height = 0;
- };
- } // namespace video
- } // namespace avrecorder
- #endif // DXGICAPTURER_H
|