Advertisement
5_2007-2008 Graphics #182385

FYI: 32bpp pARGB, ARGB Detection

Now that we are getting into the age of alphablending, PNGs, etc, wouldn't it be nice to offer ability to display 32bpp alpha bitmaps without having to know in advance if it indeed uses the alpha channel or whether or not the bitmap has its RGB bytes pre-multiplied? Try this out. It is a simple project wrapped around a routine that attempts to let you know those things a runtime. The project has some tips, shows a simple way to use AlphaBlend with non-premultiplied bitmaps and an pretty effective way to use GDI+ with 32bpp alpha bitmaps. Two test images are included in the RES file, but other than that, happing hunting for 32bpp alpha bitmaps, unless you care to create your own like I did for this test project.

AI

AI Summary: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.

Source Code
original-source
Upload
Original Comments (3)
Recovered from Wayback Machine