[gtk/wip/chergert/glproto: 304/526] fix alpha when only drawing cross-fade end node




commit 4e5207642ede7d6c0d4916ddc10261c9339ebf01
Author: Christian Hergert <chergert redhat com>
Date:   Tue Jan 26 11:50:54 2021 -0800

    fix alpha when only drawing cross-fade end node
    
    we saved the alpha, but never applyed the modified alpha

 gsk/next/gskglrenderjob.c | 3 +++
 1 file changed, 3 insertions(+)
---
diff --git a/gsk/next/gskglrenderjob.c b/gsk/next/gskglrenderjob.c
index fc8f4afd5f..a35e0568d0 100644
--- a/gsk/next/gskglrenderjob.c
+++ b/gsk/next/gskglrenderjob.c
@@ -2454,8 +2454,11 @@ gsk_gl_render_job_visit_cross_fade_node (GskGLRenderJob *job,
   if (!gsk_gl_render_job_visit_node_with_offscreen (job, end_node, &offscreen_end))
     {
       float prev_alpha = job->alpha;
+
+      job->alpha = job->alpha * progress;
       gsk_gl_render_job_visit_node (job, start_node);
       job->alpha = prev_alpha;
+
       return;
     }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]