From 301ad352372449191ee33b34392380f7282733c1 Mon Sep 17 00:00:00 2001 From: RjY Date: Fri, 20 Dec 2013 16:06:55 +0000 Subject: [PATCH] graphics/text: set -colorize alpha channel blend percentage to zero Give a fourth channel blend percentage of zero so that the alpha channel of the default fill colour (fully opaque black) is ignored. This fixes the blue menu titles (skill, episode etc.) having black backgrounds. The use of -colorize here blends 100% of the default fill colour (black) into one or more channels of a greyscale image. Mixing in 100% black is equivalent to nullifying the channel by setting it to zero, e.g. red text is achieved by mixing 100% black into the green and blue channels. It turns out, when passed more than one value (to affect all channels by that percentage equally), -colorize looks for _four_ separate channel values (RGB and alpha). If fewer are given, the missing ones inherit the blend percentage of the first channel (red). For red and white there is no effect, as the red channel is left alone. But blue blends 100% of the red channel (thus, unwittingly, the alpha channel) of fully opaque black into the image, making it fully opaque... --- graphics/text/textgen | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/graphics/text/textgen b/graphics/text/textgen index 0fa1109e..1b69b897 100755 --- a/graphics/text/textgen +++ b/graphics/text/textgen @@ -190,7 +190,7 @@ class Font(object): ]) command_line.extend([ - '-colorize', '%i,%i,%i' % color, + '-colorize', '%i,%i,%i,0' % color, ]) return command_line