GainAlphaMode

const Bitmap &alphaFrom, float anchorX = 0.0,
float anchorY = 0.0 );

The Bitmap will be rendered with an additional alpha channel from an another Bitmap.

The values of the alpha channels are multiplied together to get the final value.

The results are clipped to the areas of both of the Bitmaps. This effectively means that the parts outside the alphaFrom Bitmap are considered to be transparent.

Note that only one GainAlphaMode can take effect at a time!

Examples

Bitmap myBmp( ... ), alphaBmp( ... );

// Render myBmp with an extra alpha channel from alphaBmp //
// The alpha channel is positioned inside myBmp at x = 20.0, y = 10.0  //
myBmp.Blit200.0100.0GainAlphaMode( alphaBmp, 20.010.0 );


Parent Class


Questions about GainAlphaMode? Click here.