Destination pixel is calculated using four source pixels. When source
pixel is got from last line or row next rigth or bottom pixel could
be not existent since we reached the end of src->pixels.
Signed-off-by: Evgeny Voevodin <e.voevodin@samsung.com>
for (x = 0; x < dst->w; x++) {
dx = (sdx >> 16);
dy = (sdy >> 16);
- if ((dx > -1) && (dy > -1) && (dx < src->w) && (dy < src->h)) {
+ if ((dx > -1) && (dy > -1) && (dx < src->w - 1) && (dy < src->h - 1)) {
if (flipx) dx = sw - dx;
if (flipy) dy = sh - dy;
sp = (tColorRGBA *) ((Uint8 *) src->pixels + src->pitch * dy);