Hi all,
does anybody know how to create a semi-transparent filled rectangle on a object? I can draw filled, gradient filled rectangles without any problem. But i now have something in which they need to be semi transparent.
Regards,
per-i
Printable View
Hi all,
does anybody know how to create a semi-transparent filled rectangle on a object? I can draw filled, gradient filled rectangles without any problem. But i now have something in which they need to be semi transparent.
Regards,
per-i
You will ahve to do alpha blending.
There is a sample @vbaccelerator.com:
http://www.vbaccelerator.com/home/VB...on/article.asp
There is also very nice sample by Karl E. Peterson but it only works in Win2K but take a look at it.
Go to http://www.mvps.org/vb/index2.html?samples.htm and download Translucent.zip
We also have some good stuff here in the Forums too!
Alpha + Blend
:D
Hi all,
RobDog888 the link you gave if for alphablending a form. It requires a Hwnd. I need to alpha blend a rectangle over a control. The control has got a userdrawn event which allows you to do this. It provides you with the measurements of the rectangle and gives you a Hdc for the rectangle. I use alpha blending with form already in my program though.
The sample from vbaccelerator seems to use a Hdc and standard GDI.
The second link doesn't seem to work though
Regards,,
per-i