emacs-diffs
[Top][All Lists]
Advanced

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

master 15781beda8: Enable TrueColor allocation optimizations on all visu


From: Po Lu
Subject: master 15781beda8: Enable TrueColor allocation optimizations on all visuals
Date: Thu, 10 Feb 2022 07:01:49 -0500 (EST)

branch: master
commit 15781beda80fffa6c2dca1b5b32da8f0b4b3b306
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>

    Enable TrueColor allocation optimizations on all visuals
    
    * src/xterm.c (x_alloc_nearest_color): Enable optimizations on
    32-bit TrueColor visuals that legitimately don't have an alpha
    mask.
---
 src/xterm.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/xterm.c b/src/xterm.c
index 469077c897..095ed316cf 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -3292,9 +3292,7 @@ x_alloc_nearest_color (struct frame *f, Colormap cmap, 
XColor *color)
 
   gamma_correct (f, color);
 
-  if (dpyinfo->red_bits > 0
-      && (dpyinfo->n_planes != 32
-         || dpyinfo->alpha_bits > 0))
+  if (dpyinfo->red_bits > 0)
     {
       color->pixel = x_make_truecolor_pixel (dpyinfo,
                                             color->red,



reply via email to

[Prev in Thread] Current Thread [Next in Thread]