Add a shader to blur shadow
This commit is contained in:
parent
687bb6e065
commit
7e3c2c4897
0
data/shaders/blurshadowH.comp
Normal file
0
data/shaders/blurshadowH.comp
Normal file
0
data/shaders/blurshadowV.comp
Normal file
0
data/shaders/blurshadowV.comp
Normal file
@ -1752,6 +1752,16 @@ namespace FullScreenShader
|
||||
AssignTextureUnit(Program, TexUnit(TU_dest, "dest"));
|
||||
}
|
||||
|
||||
ComputeShadowBlurHShader::ComputeShadowBlurHShader()
|
||||
{
|
||||
Program = LoadProgram(OBJECT,
|
||||
GL_COMPUTE_SHADER, file_manager->getAsset("shaders/blurshadowH.comp").c_str());
|
||||
TU_dest = 1;
|
||||
AssignUniforms("pixel", "sigma");
|
||||
AssignSamplerNames(Program, 0, "source");
|
||||
AssignTextureUnit(Program, TexUnit(TU_dest, "dest"));
|
||||
}
|
||||
|
||||
Gaussian6HBlurShader::Gaussian6HBlurShader()
|
||||
{
|
||||
Program = LoadProgram(OBJECT,
|
||||
@ -1812,6 +1822,16 @@ namespace FullScreenShader
|
||||
AssignTextureUnit(Program, TexUnit(TU_dest, "dest"));
|
||||
}
|
||||
|
||||
ComputeShadowBlurVShader::ComputeShadowBlurVShader()
|
||||
{
|
||||
Program = LoadProgram(OBJECT,
|
||||
GL_COMPUTE_SHADER, file_manager->getAsset("shaders/blurshadowV.comp").c_str());
|
||||
TU_dest = 1;
|
||||
AssignUniforms("pixel", "sigma");
|
||||
AssignSamplerNames(Program, 0, "source");
|
||||
AssignTextureUnit(Program, TexUnit(TU_dest, "dest"));
|
||||
}
|
||||
|
||||
Gaussian6VBlurShader::Gaussian6VBlurShader()
|
||||
{
|
||||
Program = LoadProgram(OBJECT,
|
||||
|
@ -471,6 +471,13 @@ public:
|
||||
ComputeGaussian6HBlurShader();
|
||||
};
|
||||
|
||||
class ComputeShadowBlurHShader : public ShaderHelperSingleton<ComputeShadowBlurHShader, core::vector2df, float>, public TextureRead<Bilinear_Clamped_Filtered>
|
||||
{
|
||||
public:
|
||||
GLuint TU_dest;
|
||||
ComputeShadowBlurHShader();
|
||||
};
|
||||
|
||||
class Gaussian6HBlurShader : public ShaderHelperSingleton<Gaussian6HBlurShader, core::vector2df, float>, public TextureRead<Bilinear_Clamped_Filtered>
|
||||
{
|
||||
public:
|
||||
@ -510,6 +517,13 @@ public:
|
||||
ComputeGaussian6VBlurShader();
|
||||
};
|
||||
|
||||
class ComputeShadowBlurVShader : public ShaderHelperSingleton<ComputeShadowBlurVShader, core::vector2df, float>, public TextureRead<Bilinear_Clamped_Filtered>
|
||||
{
|
||||
public:
|
||||
GLuint TU_dest;
|
||||
ComputeShadowBlurVShader();
|
||||
};
|
||||
|
||||
class Gaussian6VBlurShader : public ShaderHelperSingleton<Gaussian6VBlurShader, core::vector2df, float>, public TextureRead<Bilinear_Clamped_Filtered>
|
||||
{
|
||||
public:
|
||||
|
Loading…
Reference in New Issue
Block a user