mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-10-20 08:05:55 +02:00
Ordering them before the imports in the same file was not enough: a project header on line 1 can import a module several levels down whose global module fragment already pulled in the same standard header, and that include guard does not cross the module boundary. Putting them first means the guard is set before anything can import. Skips vendored single-header libraries and anything inside an #if.
62 lines
1.6 KiB
C++
62 lines
1.6 KiB
C++
#pragma once
|
|
|
|
#include <array>
|
|
#include <cstddef>
|
|
#include <memory>
|
|
#include <nvrhi/nvrhi.h>
|
|
|
|
|
|
#include "XeGTAO.h"
|
|
|
|
import eu07.glm;
|
|
struct NvSsao {
|
|
NvSsao(class NvRenderer* renderer);
|
|
void Init();
|
|
|
|
XeGTAO::GTAOSettings settings{};
|
|
|
|
class NvRendererBackend* m_backend;
|
|
struct NvGbuffer* m_gbuffer;
|
|
|
|
nvrhi::ShaderHandle m_CSPrefilterDepths16x16;
|
|
nvrhi::ComputePipelineHandle m_PSOPrefilterDepths;
|
|
nvrhi::BindingSetHandle m_BSPrefilterDepths;
|
|
|
|
nvrhi::SamplerHandle m_SamplerPoint;
|
|
|
|
nvrhi::ShaderHandle m_CSGTAOLow;
|
|
nvrhi::ShaderHandle m_CSGTAOMedium;
|
|
nvrhi::ShaderHandle m_CSGTAOHigh;
|
|
nvrhi::ShaderHandle m_CSGTAOUltra;
|
|
std::array<nvrhi::ComputePipelineHandle, 4> m_PSOGTAO;
|
|
nvrhi::BindingSetHandle m_BSGTAO;
|
|
|
|
nvrhi::ShaderHandle m_CSDenoisePass;
|
|
nvrhi::ShaderHandle m_CSDenoiseLastPass;
|
|
nvrhi::ComputePipelineHandle m_PSODenoise;
|
|
nvrhi::ComputePipelineHandle m_PSODenoiseLastPass;
|
|
nvrhi::BindingLayoutHandle m_BLDenoise;
|
|
nvrhi::BindingSetHandle m_BSDenoise;
|
|
|
|
nvrhi::ShaderHandle m_CSGenerateNormals;
|
|
nvrhi::ComputePipelineHandle m_PSOGenerateNormals;
|
|
nvrhi::BindingSetHandle m_BSGenerateNormals;
|
|
|
|
nvrhi::TextureHandle m_workingDepths;
|
|
nvrhi::TextureHandle m_workingEdges;
|
|
nvrhi::TextureHandle m_workingAOTerm;
|
|
nvrhi::TextureHandle m_workingAOTermPong;
|
|
nvrhi::TextureHandle m_workingNormals;
|
|
nvrhi::TextureHandle m_debugImage;
|
|
nvrhi::TextureHandle m_outputAO;
|
|
nvrhi::BufferHandle m_constantBuffer;
|
|
|
|
|
|
int m_width;
|
|
int m_height;
|
|
|
|
void Render(nvrhi::ICommandList* command_list, const glm::mat4& projection,
|
|
size_t frame_index);
|
|
|
|
void OnGui(bool open_now);
|
|
}; |