Board index » delphi » Object onto background with anti-alias effects

Object onto background with anti-alias effects

I'm having difficulties with the following.  I hope some kind persons
can help.

I've 3 bitmaps:

  TargetBitmap  (final output, already contains a scenery)
  ObjectBitmap (an object that I want to paint to TargetBitmap
transparently, i.e. paint ObjectBitmap to scenery)  
  MaskBitmap (a black/white/GREY picture to mask Objectbitmap, size
height/width as ObjectBitmap, this file could be 16 bpp )

Objective: put object onto TargetBitmap without destroying any
*current* scenery existing on TargetBitmap


yet, enable the GREY areas to show an anti-alias colour
for the background to "shine" through (depending on
the "grey-ness" of the pixel).  Prob. the anti-alias pixel colour
will probably depend on the neighbourhood pixel on that object +
the grey-ness of the black/white/grey mask.

I think this should be a classical problem esp. in games programming
etc - so can someone please advise?



Re:Object onto background with anti-alias effects

btw, I forgot to mention that I do not mind using
external shareware or commercial libraries if
necessary. However, DIB support is necessary.


Other Threads