On 4/23/22 20:53, Jinoh Kang wrote:
+ [v1_enum] enum _SIIGBF { + SIIGBF_RESIZETOFIT = 0x00000000, + SIIGBF_BIGGERSIZEOK = 0x00000001, + SIIGBF_MEMORYONLY = 0x00000002, + SIIGBF_ICONONLY = 0x00000004, + SIIGBF_THUMBNAILONLY = 0x00000008, + SIIGBF_INCACHEONLY = 0x00000010, + SIIGBF_CROPTOSQUARE = 0x00000020, + SIIGBF_WIDETHUMBNAILS = 0x00000040, + SIIGBF_ICONBACKGROUND = 0x00000080, + SIIGBF_SCALEUP = 0x00000100, + }; + typedef DWORD SIIGBF; I see this using int instead of DWORD in 10.0.22000.0, did it change?
Because you have to convert potentially-transparent HICON to HBITMAP with alpha channel, which is quite a complicated feat.
1. HICON can take many pixel formats, ranging from 32-bit ARGB and monochrome with mask. 2. hbmColor and hbmMask combinations aren't exactly simple to handle. 3. Windows always seems to output a 32-bit ARGB bitmap. GDI routines alone aren't particularly suited for the task (GdiAlphaBlend works with PARGB, not ARGB).
Only WIC and GDI+ has functions to handle most of these. Same SDK claims output could be RGB24, RGB32, or PARGB32, but it can't be trusted of course.