AlphaImgCtrl | Save Icon | Transparency | LaVolpe
Using AlphaImgCtrl to try to do a quick and dirty icon save with transparency.
I have a bitmap loaded in a VB picturebox and the mask color I'm using is vbCyan. It seems like I should be able to call some function and pass it the mask color and then save as icon with tranparency but I can't find it.
Can anyone fill in the code below?
Code:
If .Picture Then
Set objGDIpImage = LoadPictureGDIplus(.Picture.Handle)
If Not (objGDIpImage Is Nothing) Then
With frm_test.AlphaImgPic
.Picture = objGDIpImage
'************************************************
' What goes here to save icon with transparency?
'************************************************
SavePictureGDIplus .Picture, sFileIco, lvicSaveAs_HICON
End With
End If
End If
Re: AlphaImgCtrl | Save Icon | Transparency | LaVolpe
It's a 64bit bitmap and 256 colors in case that matters.
Re: AlphaImgCtrl | Save Icon | Transparency | LaVolpe
I also have FreeImage installed and would be happy to use that instead but so far I've not been able to coax it into performing the task. FreeImage has a number of functions with Transparency parameters but I think I have to build a transparency table first and that I can't figure out how to do.