[]
Blends only the pixels matching the given targetColor against a specified
background color, preserving all other pixels.
public Bitmap BlendOverBackground(Bitmap srcImage, Color targetColor, Color background)
| Type | Name | Description |
|---|---|---|
| Bitmap | srcImage | The source bitmap with alpha channel (must be Format32bppPArgb). |
| Color | targetColor | The color to match. |
| Color | background | The background color to blend the transparent pixels against |
| Type | Description |
|---|---|
| Bitmap | A 32bpp image |
| Type | Condition |
|---|---|
| ArgumentException | Thrown if the source bitmap is not in a supported 32bpp PARGB format. |