comparison src/video/SDL_draw.h @ 3063:9f2482d6662c

Fixed off by one error in line drawing code
author Sam Lantinga <slouken@libsdl.org>
date Thu, 12 Feb 2009 06:01:54 +0000
parents bd518fc76f28
children 0267b8b1595c
comparison
equal deleted inserted replaced
3062:e2bb8ab7b43f 3063:9f2482d6662c
323 } \ 323 } \
324 \ 324 \
325 x = x1; \ 325 x = x1; \
326 y = y1; \ 326 y = y1; \
327 \ 327 \
328 for (i = 1; i < numpixels; ++i) { \ 328 for (i = 0; i < numpixels; ++i) { \
329 op(x, y); \ 329 op(x, y); \
330 if (d < 0) { \ 330 if (d < 0) { \
331 d += dinc1; \ 331 d += dinc1; \
332 x += xinc1; \ 332 x += xinc1; \
333 y += yinc1; \ 333 y += yinc1; \