2020-09-12 15:19:57 +00:00
|
|
|
#pragma once
|
|
|
|
#include "core/shadergen.h"
|
|
|
|
#include "postprocessing_shader.h"
|
|
|
|
#include <sstream>
|
|
|
|
|
|
|
|
namespace FrontendCommon {
|
|
|
|
|
|
|
|
class PostProcessingShaderGen : public ShaderGen
|
|
|
|
{
|
|
|
|
public:
|
2022-08-26 11:59:45 +00:00
|
|
|
PostProcessingShaderGen(RenderAPI render_api, bool supports_dual_source_blend);
|
2020-09-12 15:19:57 +00:00
|
|
|
~PostProcessingShaderGen();
|
|
|
|
|
|
|
|
std::string GeneratePostProcessingVertexShader(const PostProcessingShader& shader);
|
|
|
|
std::string GeneratePostProcessingFragmentShader(const PostProcessingShader& shader);
|
|
|
|
|
|
|
|
private:
|
|
|
|
void WriteUniformBuffer(std::stringstream& ss, const PostProcessingShader& shader, bool use_push_constants);
|
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace FrontendCommon
|