Jump to content

Xiaolin Wu's line algorithm: Difference between revisions

m
m (→‎{{header|REXX}}: added/changed comments and whitespace.)
Line 240:
 
int x;
for(x=xpxl1+1; x <= (xpxl2-1); x++) {
plot_(x, ipart_(intery), rfpart_(intery));
plot_(x, ipart_(intery) + 1, fpart_(intery));
Line 257:
int xpxl1 = ipart_(xend);
plot_(xpxl1, ypxl1, rfpart_(xend)*ygap);
plot_(xpxl1, ypxl1+ 1, ypxl1, fpart_(xend)*ygap);
double interx = xend + gradient;
 
Line 266:
int xpxl2 = ipart_(xend);
plot_(xpxl2, ypxl2, rfpart_(xend) * ygap);
plot_(xpxl2, ypxl2 + 1, ypxl2, fpart_(xend) * ygap);
 
int y;
for(y=ypxl1+1; y <= (ypxl2-1); y++) {
plot_(ipart_(interx), y, rfpart_(interx));
plot_(ipart_(interx) + 1, y, fpart_(interx));
Cookies help us deliver our services. By using our services, you agree to our use of cookies.