Linear Bresenham algorithm
no vote
The principle of Bresenham algorithm for the midpoint of straight line: one step in the direction of main displacement each time, and whether one step in the other direction depends on the value of the midpoint deviation discriminant.