Various supported line-drawing algorithms.
public enum Algorithm
Bresenham line algorithm.
Bresenham line algorithm, with the points guaranteed to be in start to finish order. This may be significantly slower than Bresenham, so if you really need ordering, considerDDA instead, as it is both faster than Bresenham and implicitly ordered.
DDA line algorithm -- effectively an optimized algorithm for producing Bresenham-like lines. There may be slight differences in appearance when compared to lines created with Bresenham, however this algorithm may also be measurably faster. Based on the algorithm here, as well as the Java library SquidLib's implementation. Points are guaranteed to be in order from start to finish.
Line algorithm that takes only orthogonal steps (each grid location on the line returned is within one cardinal direction of the previous one). Potentially useful for LOS in games that use MANHATTAN distance. Based on the algorithm here.