Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Fade in an alpha-blended PNG form in Delphi

I asked a question about this some years back when Vista was first released, but never resolved the problem and shelved it as something to consider later.

I have a splash screen that I went to great effort to make look great. It's a 32bpp alpha-blended PNG. I have some code (which I can dig up if required!) that works great under Windows XP or under Vista+ when desktop composition is turned off. However, under Vista+ all the transparent parts are black, destroying everything that looks great about it!

So, my question is this: as anyone been able to display a 32bpp alpha-blended PNG as a splash screen in a way that works both with and without desktop composition activated? I'm not adverse to using third-party components if required, free or otherwise.

Ideally, this would work in Delphi 7.

Update: Besides the answers below, which work very well, I found that the TMS TAdvSmoothSplashScreen component also handles this task very well, if somewhat more complex.

like image 978
Tim Sullivan Avatar asked Dec 23 '22 10:12

Tim Sullivan


1 Answers

Tim, I just tried this on Vista/D2007 with 'Windows Classic' theme selected:

Alpha Blended Splash Screen in Delphi - Part 2 http://melander.dk/articles/alphasplash2/2/

no black background that I could see... it still looks great.

like image 136
Bob S Avatar answered Jan 06 '23 08:01

Bob S