PDA

Click to See Complete Forum and Search --> : MaskBlt


Chris
May 22nd, 2001, 06:57 AM
dopes anyone know how to use the MaskBlt API function?

Chris
May 22nd, 2001, 07:35 PM
I go through the document already and just have some problem in some parameter :(


Public Declare Function MaskBlt Lib "gdi32" Alias "MaskBlt" (ByVal hdcDest As Long, ByVal nXDest As Long, ByVal nYDest As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hdcSrc As Long, ByVal nXSrc As Long, ByVal nYSrc As Long, ByVal hbmMask As Long, ByVal xMask As Long, ByVal yMask As Long, ByVal dwRop As Long) As Long


What should I pass in for the hbmMask, xMask and yMask?
Is the hbmmask is the handle for the Mask bitmap? If yes, how do i create this?

regards,
Chris.C

Sastraxi
May 22nd, 2001, 08:07 PM
You create a B&W representation of the real img, white being not drawn, black being drawn.

Mad Compie
May 23rd, 2001, 12:54 PM
hbmMask is probably a bitmap reference.

You could use the Image property of a picturebox control as this parameter.

PsychoMark
May 24th, 2001, 01:57 AM
You could also just use BitBlt to do the same, in both cases you'll need 2 images (or at least 2 sections in an image) anyways...

If you want to know how to do it, just type 'BitBlt' and 'Masks' in the same reply, and you'll get blown away by URL's ;)