qt_rtmp_demo/media/screen_capture.h

25 lines
493 B
C
Raw Normal View History

2023-11-12 16:13:24 +00:00
#ifndef SCREEN_CAPTURE
#define SCREEN_CAPTURE
#include <Windows.h>
#include <Wincodec.h> // we use WIC for saving images
#include <d3d9.h> // DirectX 9 header
#include <d3d9helper.h>
HRESULT Direct3D9TakeScreenshots(UINT adapter, UINT count);
class ScreenCapture
{
public:
ScreenCapture();
void EnumScreen();
void PrintDisplayModeInfo(IDirect3D9 *pD3D, D3DFORMAT fmt);
private:
IDirect3D9* m_d3d9_dev = nullptr;
};
#endif // SCREEN_CAPTURE_H