Khaotic Engine Reborn
Loading...
Searching...
No Matches
shadow_map.h
1#pragma once
2#include <d3d11.h>
3#include <directxmath.h>
4
5class shadow_map {
6public:
9
10 bool initialize(ID3D11Device* device, int width, int height);
11 void shutdown();
12
13 void set_render_target(ID3D11DeviceContext* context);
14 void clear_render_target(ID3D11DeviceContext* context, float depth = 1.0f);
15
16
17 ID3D11ShaderResourceView* get_shader_resource_view();
18
19
20private:
21 ID3D11Texture2D* depth_texture_;
22 ID3D11DepthStencilView* depth_stencil_view_;
23 ID3D11ShaderResourceView* shader_resource_view_;
24 int width_, height_;
25};