MCPcopy Create free account
hub / github.com/TheRealMJP/MSAAFilter / Initialize

Method Initialize

MSAAFilter/PostProcessor.cpp:23–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21static const uint32 LumMapSize = 1024;
22
23void PostProcessor::Initialize(ID3D11Device* device)
24{
25 PostProcessorBase::Initialize(device);
26
27 constantBuffer.Initialize(device);
28
29 // Load the shaders
30 toneMap = CompilePSFromFile(device, L"PostProcessing.hlsl", "ToneMap");
31 scale = CompilePSFromFile(device, L"PostProcessing.hlsl", "Scale");
32 blurH = CompilePSFromFile(device, L"PostProcessing.hlsl", "BlurH");
33 blurV = CompilePSFromFile(device, L"PostProcessing.hlsl", "BlurV");
34 bloom = CompilePSFromFile(device, L"PostProcessing.hlsl", "Bloom");
35 sharpen = CompilePSFromFile(device, L"PostProcessing.hlsl", "Sharpen");
36
37 reduceLuminanceInitial = CompileCSFromFile(device, L"LuminanceReduction.hlsl",
38 "LuminanceReductionInitialCS", "cs_5_0");
39 reduceLuminance = CompileCSFromFile(device, L"LuminanceReduction.hlsl", "LuminanceReductionCS");
40
41 CompileOptions opts;
42 opts.Add("FinalPass_", 1);
43 reduceLuminanceFinal = CompileCSFromFile(device, L"LuminanceReduction.hlsl", "LuminanceReductionCS",
44 "cs_5_0", opts);
45}
46
47void PostProcessor::AfterReset(uint32 width, uint32 height)
48{

Callers 1

AfterResetMethod · 0.45

Calls 4

InitializeFunction · 0.85
CompilePSFromFileFunction · 0.85
CompileCSFromFileFunction · 0.85
AddMethod · 0.80

Tested by

no test coverage detected