DrawPoint() public method

public DrawPoint ( float x, float y, SKColor color ) : void
x float
y float
color SKColor
return void
Esempio n. 1
0
        public void SetPixel(int x, int y, SKColor color)
        {
            var info = Info;

            if (x < 0 || x >= info.Width)
            {
                throw new ArgumentOutOfRangeException(nameof(x));
            }
            if (y < 0 || y >= info.Height)
            {
                throw new ArgumentOutOfRangeException(nameof(y));
            }

            using var canvas = new SKCanvas(this);
            canvas.DrawPoint(x, y, color);
        }