
Originally Posted by
petersen
If the following still cannot convince you to recognise that there are flaws in existence in Alpha Image Control, then I don't know what else to say.
I am not convinced. I have to repeat again, that if you don't use the backcolor options (saving transparency to format that doesn't support transparency), you will not get what you want. You tell the control what you want, it does not tell you what you want. Here is the same image rendered from png to pcx and to emf with the RenderingStyle parameter's BackColor & BackColorUsed properties set.
Code:
' Example saving to another format and loading it at afterwards
Dim c As New GDIpImage
Dim rs As RENDERSTYLESTRUCT
rs.BackColor = vbWhite: rs.BackColorUsed = True
SavePictureGDIplus AlphaImgCtl1.Picture, c, lvicSaveAsEMF, , rs
AlphaImgCtl2.Picture = c
' Example saving to file
Dim rs As RENDERSTYLESTRUCT
rs.BackColor = vbWhite: rs.BackColorUsed = True
SavePictureGDIplus AlphaImgCtl1.Picture, "C:\MyImage.pcx", lvicSaveAsPCX, True, rs


Originally Posted by
petersen
Readers who want to try save PCX using Alpha Image Control for yourselves can refer ...
Readers who want to try to use the control, read the comments, especially those in the AICGlobal class, and play with the control !
Your previous post does not mention how the EMF was saved. Is it transparent? Probably not & if it is, please post the emf here so I can see. But using the control properties provided to you, you can reproduce the same images as your previous post. I have mentioned in post #1, at the very top, that I am working on revamping the SaveAs routines. If you do find an error, I'd be happy to address it. But you are not posting errors, you are posting examples of 'how not to use the control the way you want'. And to be clear about the PNG over backcolor... The backcolor is not part of the PNG, the control's backstyle is set to opaque
Edited: Just so one doesn't question my integrity, attached are examples of the saved images. And if someone still questions it, just do it yourself. The source image provided in previous post by Petersen, sample code provided by me above.