|
-
Nov 18th, 2002, 06:10 PM
#1
Thread Starter
Stuck in the 80s
[Resolved] Blit this foo! (Transparency Stuff)
I tried writing a TransBlt function, but it doesn't really work...
VB Code:
Private Sub TransBlt(hPicture As Long, iFromX As Integer, iFromY As Integer, _
hMask As Long, iFromMaskX As Integer, iFromMaskY As Integer, hTo As Long, _
x As Integer, y As Integer, iWidth As Integer, iHeight As Integer)
BitBlt hTo, x, y, iWidth, iHeight, hPicture, iFromX, iFromY, vbSrcPaint
BitBlt hTo, x, y, iWidth, iHeight, hMask, iFromX, iFromY, vbSrcAnd
End Sub
Where am I going wrong?
Last edited by The Hobo; Nov 18th, 2002 at 06:47 PM.
-
Nov 18th, 2002, 06:17 PM
#2
Thread Starter
Stuck in the 80s
Nevermind. I found the problem already. I was blitting the picture before the mask.
-
Nov 19th, 2002, 12:13 AM
#3
Frenzied Member
hey! i tried that code (fixed it first) but something was wrong...
were it was supposed to be transparent, it changed the color of the BG....why?
-
Nov 19th, 2002, 12:17 AM
#4
Frenzied Member
oh! nevermin this too...
i just changed the bg color of the pic to black, and it worked...
-
Nov 19th, 2002, 03:39 PM
#5
Addicted Member
theres a api function called transparantblt too
-
Nov 19th, 2002, 03:43 PM
#6
Thread Starter
Stuck in the 80s
Originally posted by jmiller
theres a api function called transparantblt too
However, it caused bad memory leaks on most operating systems and is only available in OS > 95.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|