[gtk/wip/baedert/for-master: 40/46] gl renderer: Use premultiply() in inset shadow shader`
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/baedert/for-master: 40/46] gl renderer: Use premultiply() in inset shadow shader`
- Date: Thu, 1 Oct 2020 06:40:44 +0000 (UTC)
commit 1dcce8c3b7ebd6ef6d8279e3e9fe7de841ad8aba
Author: Timm Bäder <mail baedert org>
Date: Wed Sep 30 06:00:50 2020 +0200
gl renderer: Use premultiply() in inset shadow shader`
gsk/resources/glsl/inset_shadow.glsl | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
---
diff --git a/gsk/resources/glsl/inset_shadow.glsl b/gsk/resources/glsl/inset_shadow.glsl
index 6047946784..9a21cdef09 100644
--- a/gsk/resources/glsl/inset_shadow.glsl
+++ b/gsk/resources/glsl/inset_shadow.glsl
@@ -11,9 +11,7 @@ _OUT_ _GSK_ROUNDED_RECT_UNIFORM_ transformed_inside_outline;
void main() {
gl_Position = u_projection * u_modelview * vec4(aPosition, 0.0, 1.0);
- final_color = u_color;
- final_color.rgb *= final_color.a;
- final_color *= u_alpha;
+ final_color = gsk_premultiply(u_color) * u_alpha;
GskRoundedRect outside = gsk_create_rect(u_outline_rect);
GskRoundedRect inside = gsk_rounded_rect_shrink(outside, vec4(u_spread));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]