Results 1 to 3 of 3

Thread: Bitblt transparent without black bg

  1. #1

    Thread Starter
    Good Ol' Platypus Sastraxi's Avatar
    Join Date
    Jan 2000
    Location
    Ontario, Canada
    Posts
    5,134
    How would u bitblt tranparently without the use of a black bg and Bitblt or Transparent? I have some pics with green backgrounds, but can't be bothered to change all of the bgs to black, for there are some black parts in the pic.

    Can I do this?
    All contents of the above post that aren't somebody elses are mine, not the property of some media corporation.
    (Just a heads-up)

  2. #2
    Guest
    Use a Mask. Take your image. Create a new image
    that is the same size as your image. Every part of the
    image that you want to show up, make that part of the
    mask black. everything else, white. Use BitBlt, in this
    order:

    Blt the background that you want your sprite to show
    up on (eg, your map thing)

    Blt the mask on top of the map thing, using MergePaint

    Blt the sprite on top of the mask with SrcAnd.

    That should work, im taking the code from VB Graphics
    Programming. Great book, by the way.

    Z.

  3. #3

    Thread Starter
    Good Ol' Platypus Sastraxi's Avatar
    Join Date
    Jan 2000
    Location
    Ontario, Canada
    Posts
    5,134
    *SASTRAXI STOMPS HIS FEET MADLY*
    I HAVE THAT BOOK, TOO!!!!
    I am sooooo annoyed with myself.

    BTW, thanks for the code, Zaei!
    All contents of the above post that aren't somebody elses are mine, not the property of some media corporation.
    (Just a heads-up)

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