[AD] makecol and 32 bit mode

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


I noticed that makecol always returns a colour with zero alpha in 32
bit mode. This seems a bit useless; is there a good reason for it?

makecol just delegates to makecol32, which would be trivial to fix
(see below). However I'm not quite sure where the bitmap mask colour
comes from - should this be magic pink with zero alpha or magic pink
with 255 alpha?

Pete

Index: include/allegro/inline/color.inl
===================================================================
--- include/allegro/inline/color.inl    (revision 7378)
+++ include/allegro/inline/color.inl    (working copy)
@@ -51,7 +51,8 @@
{
   return ((r << _rgb_r_shift_32) |
           (g << _rgb_g_shift_32) |
-           (b << _rgb_b_shift_32));
+           (b << _rgb_b_shift_32) |
+           (0xff << _rgb_a_shift_32));
})




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/