Well, like Ross says images don't have alpha, only 3d textures have alpha. Images ignore the alpha byte, they only have a mask color and any pixel of that color value will be transparent/invisible.
If it's a simple fade to background color then you want to code a function to fade an image. Something like this:
FadeImage(sourceimage,targetimage,fade,time)
Then you could just call that in your main loop until it's done.
If you don't need the image after the fade then you could do something like this:
FadeImage(image,fade,time)
The first is better because you can fade/unfade an image and you also don't loose the image after the fade.
You need to know about Read/WritePixelFast, etc. and know how to separate the 32-bit color into bytes using And, etc. so you can then reduce each component by the fade amount and then add them back together.
If it's a simple fade to background color then you want to code a function to fade an image. Something like this:
FadeImage(sourceimage,targetimage,fade,time)
Then you could just call that in your main loop until it's done.
If you don't need the image after the fade then you could do something like this:
FadeImage(image,fade,time)
The first is better because you can fade/unfade an image and you also don't loose the image after the fade.
You need to know about Read/WritePixelFast, etc. and know how to separate the 32-bit color into bytes using And, etc. so you can then reduce each component by the fade amount and then add them back together.