Add with_alpha() to shader and shadow element

This commit is contained in:
Ivan Molodetskikh
2025-04-17 11:31:01 +03:00
parent b20dd226c0
commit 5059cce886
2 changed files with 10 additions and 0 deletions
+5
View File
@@ -175,6 +175,11 @@ impl ShadowRenderElement {
self
}
pub fn with_alpha(mut self, alpha: f32) -> Self {
self.inner = self.inner.with_alpha(alpha);
self
}
pub fn has_shader(renderer: &mut impl NiriRenderer) -> bool {
Shaders::get(renderer)
.program(ProgramType::Shadow)