You are on page 1of 1

START

(x0,y0,x1,y1) xinc,yinc

dy=y1-y0 dx=x1-x0 x=x0 y=y0

if Abs(dx)>Abs(dy)

step#=Abs(dx)

N
step#=Abs(dy)

xinc=dx/step# yinc=dy/step#

for i = 0 to step# i=i+1

x=x+xinc y=y+yinc

glVertex3f(Abs(x), Abs(y),0)

end

You might also like