public void multiPoint(List <Model.Pixel> Pixels, Model.Canvas Canvas, bool relativePositions = false) { for (int i = 0; i < Pixels.Count; i++) { Model.Pixel pixel = (relativePositions)?getAbsolutePixel(Pixels[i], Canvas): Pixels[i]; point(pixel, Canvas); } }
private Model.Pixel getAbsolutePixel(Model.Pixel Pixel, Model.Canvas Canvas) { int x = Canvas.getPencil().getPosition().X + Pixel.getPosition().X; int y = Canvas.getPencil().getPosition().Y + Pixel.getPosition().Y; Pixel.setPosition(new Point(x, y)); return(Pixel); }
public void point(Model.Pixel Pixel, Model.Canvas Canvas) { Canvas.setPixel(Pixel); }