I'm trying to draw a curve between two points, specifically I leave a picture of what I want:
This image was taken from this pdf on page 10.
I understand that applies the concept of Bresenham algorithm
but do not know how to implement the concept for draw the curve.
On page 11 of the pdf pseudocode algorithm
shown, but do not understand the concept of "error" to implement. Please if anyone can help me understand this. I work with C ++ and OpenGL.
Pseudocode:
set up x, y to x0, y0
set up error variable exy for P(x0+1,y0+1)
loop
set pixel x, y
if ex + exy > 0 then increment x, sub difference error
if ey + exy < 0 then increment y, add difference error
loop until end pixel
Thanks you all.