title: how to interpolate color of an line drew using midpoint algorithm
body: <p>I'm currently trying to implement a graphics pipeline on software level. Now I have implemented the midpoint algorithm to draw a line, but how should I interpolate color of pixels between two end points. I mean, I know the linear interpolation, but my problem is that the (x, y) coordinate of a pixel generated via midpoint algorithm is not accurately lying on the actual line defined by two end points. And I want to know how OpenGL deal with it.</p>