galaxy 1.0.0
Real-Time C++23 Game Programming Framework. Built on data-driven design principles and agile software engineering.
Loading...
Searching...
No Matches
GaussianBlur.hpp
Go to the documentation of this file.
1
7
8#ifndef GALAXY_GRAPHICS_POST_GAUSSIANBLUR_HPP_
9#define GALAXY_GRAPHICS_POST_GAUSSIANBLUR_HPP_
10
14
15namespace galaxy
16{
17 namespace graphics
18 {
24 class GaussianBlur final : public PostEffect
25 {
26 public:
30 enum class Strength : int
31 {
35 LOW = 0,
36
40 NORMAL = 1,
41
45 STRONG = 2
46 };
47
54 GaussianBlur(const int width, const int height);
55
59 virtual ~GaussianBlur() = default;
60
67 void resize(const int width, const int height) override;
68
76 [[nodiscard]]
77 unsigned int render(const unsigned int input) override;
78
84 void set_strength(const Strength strength);
85
91 [[nodiscard]]
92 bool is_enabled() override;
93
94 private:
98 GaussianBlur() = delete;
99
100 private:
105
110
115
120 };
121 } // namespace graphics
122} // namespace galaxy
123
124#endif
bool is_enabled() override
Is this effect enabled?
GaussianBlur()=delete
Constructor.
virtual ~GaussianBlur()=default
Destructor.
void resize(const int width, const int height) override
Resize framebuffers.
RenderTexture m_horizontal
Framebuffer to render horizontal blur to.
unsigned int render(const unsigned int input) override
Render effect to input texture.
RenderTexture m_vertical
Framebuffer to render vertical blur to.
Strength
Pixel sample strength.
Strength m_strength
Which pixel sample strength to use.
void set_strength(const Strength strength)
Set gaussian blur strength.
Shader m_shader
Shader for post processing effect.
Manages post processing effects to apply to combined scene.
Draw to an opengl texture instead of the screen.
OpenGL Shader Program.
Definition Shader.hpp:29
Animated.cpp galaxy.
Definition Animated.cpp:16