Khaotic Engine Reborn
Loading...
Searching...
No Matches
render_texture_class.h
1
2// Filename: rendertextureclass.h
4#ifndef _RENDERTEXTURECLASS_H_
5#define _RENDERTEXTURECLASS_H_
6
7
9// INCLUDES //
11#include "Logger.h"
12#include <d3d11.h>
13#include <directxmath.h>
14using namespace DirectX;
15
16
18// Class name: render_texture_class
21{
22public:
26
27 bool Initialize(ID3D11Device*, int, int, float, float, int);
28 void Shutdown();
29
30 void SetRenderTarget(ID3D11DeviceContext*);
31 void ClearRenderTarget(ID3D11DeviceContext*, float, float, float, float);
32 ID3D11ShaderResourceView* GetShaderResourceView();
33
34 void GetProjectionMatrix(XMMATRIX&);
35 void GetOrthoMatrix(XMMATRIX&);
36
37 int GetTextureWidth();
38 int GetTextureHeight();
39
40private:
41 int m_textureWidth, m_textureHeight;
42 ID3D11Texture2D* m_renderTargetTexture;
43 ID3D11RenderTargetView* m_renderTargetView;
44 ID3D11ShaderResourceView* m_shaderResourceView;
45 ID3D11Texture2D* m_depthStencilBuffer;
46 ID3D11DepthStencilView* m_depthStencilView;
47 D3D11_VIEWPORT m_viewport;
48 XMMATRIX m_projectionMatrix;
49 XMMATRIX m_orthoMatrix;
50
51};
52
53#endif