Results 1 to 5 of 5

Thread: A question for all you whizz-kids...

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Apr 2000
    Location
    Whats a location?
    Posts
    516

    Question

    I want to BitBlt a picture on top of another picture. If I
    use the most useful one (vbSrcInvert) The picture comes all
    funny because the background is made of different colours.

    Should I use MaskBlt or something else.

    I know you know the answer.

    Well, why not tell me, and add 1 to your 'posts'.

    You know you want to.

    Don't hold back.

    Oh, well, BYE!
    Courgettes.

  2. #2
    PowerPoster Fox's Avatar
    Join Date
    Jan 2000
    Location
    *afk*
    Posts
    2,088
    I don't really know what you mean... if you want to draw the picture with transparency - this question has already been answered. I don't understand why you use srcInvert... So please explain a bit more...

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Apr 2000
    Location
    Whats a location?
    Posts
    516

    Arrow Sort of transparancy

    Well, I've since found what I wanted (it was a sort of
    sprite.) It used BitBlt SrcAnd, SrcCopy and SrcInvert to
    transform a masked and picture + mask, into a picture on
    any background (ie transparent, ish).

    Just to explain what I wanted to do:

    It is a person walking all over the place. I had the person
    in all of his 8 positions on pictureboxes, but because the
    terrain was multi-coloured, using BitBlt SrcInvert meant
    that the guy's colour scheme became all screwed up.

    So I wanted a guy who wasn't shaped like a box and who
    didn't go all funny-coloured when he went across colours.

    I thought of making my own stuff, but I could never get
    all the SrcCopy, SrcAnd, SrcInvert etc in the right order.

    I found the answer after a bit of searching in About.com

    (MSDN had nothing relevant to say on the matter...as always)

    Sorry if the q was unclear.

    PS Would MaskBlt have done this for me?

    Adios, amigos
    Courgettes.

  4. #4
    PowerPoster Fox's Avatar
    Join Date
    Jan 2000
    Location
    *afk*
    Posts
    2,088
    I never used MaskBlt but I think so...

    well, If you had a look at my demo project you'd see that you can draw sprites with SrcPaint + SrcAnd only.

  5. #5
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221

    Talking

    Bitblt was the first API I learned, and still it's the most used one. =) In Vb3 there was an example of how to draw a transparent bouncy (+) from which I developed my first tilebased game
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width