TintMode

Renders the bitmap tinted to a color.

Rgba color );

The bitmap will be tinted to the given color.The alpha value of the color tells the intensity of the tinting.

Like any other RenderMode the instance of TintMode is deleted after it's passed to a rendering function. This is to allow for passing a new object to the rendering function without having to worry about destroying it. See the examples of how this works.

If you don't wish the TintMode to be deleted after using it you can call the NoAutoDestroy() -method.

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

Examples

// Load a bitmap //
Bitmap myBmp( ... );

// Render the bitmap to the screen such as the top-left corner is at x = 200.0, y = 100.0 //
// and the bitmap is tinted 35% to red //
myBmp.Blit200.0100.0TintModeRgba1.00.00.00.35 )));


Parent Class


Questions about TintMode? Click here.