-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainFrm.h
More file actions
71 lines (61 loc) · 1.75 KB
/
Copy pathMainFrm.h
File metadata and controls
71 lines (61 loc) · 1.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
// MainFrm.h : interface of the CMainFrame class
//
#pragma once
#include <string>
class CMFCDirectX11View;
class CMainFrame : public CFrameWnd
{
protected: // create from serialization only
CMainFrame() noexcept;
DECLARE_DYNCREATE(CMainFrame)
//dxgi
//IDXGIDevice* m_pDXGIDevice = 0;
//IDXGIAdapter* m_pDXGIAdapter = 0;
IDXGIFactory* m_pDXGIFactory = 0;
//IDXGISwapChain* m_pSwapChain = 0;
//d3d
ID3D11Device* m_pD3DDevice = 0;
ID3D11DeviceContext* m_pD3DImmediateContext = 0;
ID3D11Texture2D* m_pDepthStencilBuffer = 0;
ID3D11RenderTargetView* m_pRenderTargetView = 0;
ID3D11DepthStencilView* m_pDepthStencilView = 0;
//d2d
ID2D1Factory* m_pD2DFactory = 0;
IDWriteFactory* m_pWriteFactory = 0;
IDWriteTextFormat* m_pTextFormat = 0;
D3D11_VIEWPORT m_ScreenViewport;
UINT m_4xMsaaQuality = 0;
void Render();
// Derived class should set these in derived constructor to customize starting values.
std::wstring m_MainWndCaption;
bool m_Enable4xMsaa = false;
void OnSize(UINT nType, int cx, int cy);
D3D_DRIVER_TYPE m_D3DDriverType = D3D_DRIVER_TYPE_HARDWARE;
CMFCDirectX11View* m_pView[4];
bool InitD2D();
bool InitD3D();
// Attributes
public:
CSplitterWnd m_wndSplitter;
bool m_bSplitterCreated = false;
// Operations
public:
bool Initialize();
// Overrides
public:
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
// Implementation
public:
virtual ~CMainFrame();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
protected: // control bar embedded members
CStatusBar m_wndStatusBar;
// Generated message map functions
protected:
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
DECLARE_MESSAGE_MAP()
virtual BOOL OnCreateClient(LPCREATESTRUCT lpcs, CCreateContext* pContext);
};