Table of Contents

Method GetPixel

Namespace
Alternet.Drawing
Assembly
Alternet.UI.Common.dll

GetPixel(int, int, bool)

Gets Color at given pixel location.

public Color GetPixel(int x, int y, bool withAlpha = false)

Parameters

x int

X coordinate of the pixel.

y int

Y coordinate of the pixel.

withAlpha bool

If true alpha channel is also returned in result (A); if false it is set to 255.

Returns

Color

Remarks

Some images can have mask color, this method doesn't use this info. You need to add additional code in order to determine transparency if your image is with mask color.