diff options
| author | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2023-03-17 23:16:13 +0000 |
|---|---|---|
| committer | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2023-03-17 23:16:13 +0000 |
| commit | e5870d47c74150aa744ed55f9b7e58713d968209 (patch) | |
| tree | 227fda73f787873bc97b64be333d0e0f7d596ec7 /src/render/OpenGL.hpp | |
| parent | 91a565c7b0957968d686fccf8f3a5166b9c3fec9 (diff) | |
LS: add blur and ignorezero rules
Diffstat (limited to 'src/render/OpenGL.hpp')
| -rw-r--r-- | src/render/OpenGL.hpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/render/OpenGL.hpp b/src/render/OpenGL.hpp index 171efb35..028be4df 100644 --- a/src/render/OpenGL.hpp +++ b/src/render/OpenGL.hpp @@ -23,6 +23,12 @@ inline const float fullVerts[] = { }; inline const float fanVertsFull[] = {-1.0f, -1.0f, 1.0f, -1.0f, 1.0f, 1.0f, -1.0f, 1.0f}; +enum eDiscardMode +{ + DISCARD_OPAQUE = 1, + DISCARD_ALPHAZERO = 1 << 1 +}; + struct SMonitorRenderData { CFramebuffer primaryFB; CFramebuffer mirrorFB; // these are used for some effects, @@ -64,6 +70,8 @@ struct SCurrentRenderData { Vector2D primarySurfaceUVBottomRight = Vector2D(-1, -1); wlr_box clipBox = {}; + + uint32_t discardMode = DISCARD_OPAQUE; }; class CGradientValueData; @@ -78,7 +86,7 @@ class CHyprOpenGLImpl { void renderRect(wlr_box*, const CColor&, int round = 0); void renderRectWithDamage(wlr_box*, const CColor&, pixman_region32_t* damage, int round = 0); void renderTexture(wlr_texture*, wlr_box*, float a, int round = 0, bool allowCustomUV = false); - void renderTexture(const CTexture&, wlr_box*, float a, int round = 0, bool discardOpaque = false, bool allowCustomUV = false); + void renderTexture(const CTexture&, wlr_box*, float a, int round = 0, bool discardActive = false, bool allowCustomUV = false); void renderTextureWithBlur(const CTexture&, wlr_box*, float a, wlr_surface* pSurface, int round = 0, bool blockBlurOptimization = false); void renderRoundedShadow(wlr_box*, int round, int range, float a = 1.0); void renderBorder(wlr_box*, const CGradientValueData&, int round, float a = 1.0); |
