fblend fade with magic pink
Neil Walker

Is there a way to use fblend_fade_to_color while keeping the magic pink colour?

In standard allegro you can simply do something like this for a fade, e.g.

  set_trans_blender(0,0,0, somevalue);
  draw_trans_sprite(bmp1,bmp2, 0,0);

and the magic pink is preserved. However if you do

  fblend_fade_to_color(bmp2, bmp1, 0,0, colour1, somevalue);

It does a complete fade, ignoring the magic pink. What you have to do (unless I'm completely wrong) is you have to do is check the original untouched bitmap for mask colour pixels and put them back into the faded bitmap (repeating/checking each bitmap depth):

    for(int i=0;i<w;i++)
      for(int j=0;j<w;j++)
        FadeColour=_getpixel32(bmp1, i, j);

Thread #563590. Printed from Allegro.cc