More Image Fixes
GIF Interlaced offset Fixes and area reveal offset fixes
This commit is contained in:
parent
734ef12fdf
commit
88fd3ad62e
1 changed files with 7 additions and 7 deletions
|
@ -843,9 +843,9 @@ gdispImageError gdispImageDraw_GIF(gdispImage *img, coord_t x, coord_t y, coord_
|
||||||
// The spec says to restore the backgound color (priv->bgcolor) but in practice if there is transparency
|
// The spec says to restore the backgound color (priv->bgcolor) but in practice if there is transparency
|
||||||
// image decoders tend to assume that a restore to the transparent color is required instead
|
// image decoders tend to assume that a restore to the transparent color is required instead
|
||||||
if (((priv->dispose.flags & GIFL_TRANSPARENT) /*&& priv->dispose.paltrans == priv->bgcolor*/) || priv->bgcolor >= priv->palsize)
|
if (((priv->dispose.flags & GIFL_TRANSPARENT) /*&& priv->dispose.paltrans == priv->bgcolor*/) || priv->bgcolor >= priv->palsize)
|
||||||
gdispFillArea(x+mx, y+my, fx-mx, fy-my, img->bgcolor);
|
gdispFillArea(x+mx-sx, y+my-sy, fx-mx, fy-my, img->bgcolor);
|
||||||
else
|
else
|
||||||
gdispFillArea(x+mx, y+my, fx-mx, fy-my, priv->palette[priv->bgcolor]);
|
gdispFillArea(x+mx-sx, y+my-sy, fx-mx, fy-my, priv->palette[priv->bgcolor]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -885,7 +885,7 @@ gdispImageError gdispImageDraw_GIF(gdispImage *img, coord_t x, coord_t y, coord_
|
||||||
priv->buf[gcnt++] = cache->palette[col];
|
priv->buf[gcnt++] = cache->palette[col];
|
||||||
if (gcnt >= BLIT_BUFFER_SIZE) {
|
if (gcnt >= BLIT_BUFFER_SIZE) {
|
||||||
// We have run out of buffer - dump it to the display
|
// We have run out of buffer - dump it to the display
|
||||||
gdispBlitAreaEx(x+mx-gcnt+1, y+my, gcnt, 1, 0, 0, gcnt, priv->buf);
|
gdispBlitAreaEx(x+mx-sx-gcnt+1, y+my-sy, gcnt, 1, 0, 0, gcnt, priv->buf);
|
||||||
gcnt = 0;
|
gcnt = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -939,7 +939,7 @@ gdispImageError gdispImageDraw_GIF(gdispImage *img, coord_t x, coord_t y, coord_
|
||||||
priv->buf[gcnt++] = decode->palette[col];
|
priv->buf[gcnt++] = decode->palette[col];
|
||||||
if (gcnt >= BLIT_BUFFER_SIZE) {
|
if (gcnt >= BLIT_BUFFER_SIZE) {
|
||||||
// We have run out of buffer - dump it to the display
|
// We have run out of buffer - dump it to the display
|
||||||
gdispBlitAreaEx(x+mx-gcnt+1, y+my, gcnt, 1, 0, 0, gcnt, priv->buf);
|
gdispBlitAreaEx(x+mx-sx-gcnt+1, y+my-sy, gcnt, 1, 0, 0, gcnt, priv->buf);
|
||||||
gcnt = 0;
|
gcnt = 0;
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
|
@ -985,7 +985,7 @@ gdispImageError gdispImageDraw_GIF(gdispImage *img, coord_t x, coord_t y, coord_
|
||||||
priv->buf[gcnt++] = decode->palette[col];
|
priv->buf[gcnt++] = decode->palette[col];
|
||||||
if (gcnt >= BLIT_BUFFER_SIZE) {
|
if (gcnt >= BLIT_BUFFER_SIZE) {
|
||||||
// We have run out of buffer - dump it to the display
|
// We have run out of buffer - dump it to the display
|
||||||
gdispBlitAreaEx(x+mx-gcnt+1, y+my, gcnt, 1, 0, 0, gcnt, priv->buf);
|
gdispBlitAreaEx(x+mx-sx-gcnt+1, y+my-sy, gcnt, 1, 0, 0, gcnt, priv->buf);
|
||||||
gcnt = 0;
|
gcnt = 0;
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
|
@ -1031,7 +1031,7 @@ gdispImageError gdispImageDraw_GIF(gdispImage *img, coord_t x, coord_t y, coord_
|
||||||
priv->buf[gcnt++] = decode->palette[col];
|
priv->buf[gcnt++] = decode->palette[col];
|
||||||
if (gcnt >= BLIT_BUFFER_SIZE) {
|
if (gcnt >= BLIT_BUFFER_SIZE) {
|
||||||
// We have run out of buffer - dump it to the display
|
// We have run out of buffer - dump it to the display
|
||||||
gdispBlitAreaEx(x+mx-gcnt+1, y+my, gcnt, 1, 0, 0, gcnt, priv->buf);
|
gdispBlitAreaEx(x+mx-sx-gcnt+1, y+my-sy, gcnt, 1, 0, 0, gcnt, priv->buf);
|
||||||
gcnt = 0;
|
gcnt = 0;
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
|
@ -1077,7 +1077,7 @@ gdispImageError gdispImageDraw_GIF(gdispImage *img, coord_t x, coord_t y, coord_
|
||||||
priv->buf[gcnt++] = decode->palette[col];
|
priv->buf[gcnt++] = decode->palette[col];
|
||||||
if (gcnt >= BLIT_BUFFER_SIZE) {
|
if (gcnt >= BLIT_BUFFER_SIZE) {
|
||||||
// We have run out of buffer - dump it to the display
|
// We have run out of buffer - dump it to the display
|
||||||
gdispBlitAreaEx(x+mx-gcnt+1, y+my, gcnt, 1, 0, 0, gcnt, priv->buf);
|
gdispBlitAreaEx(x+mx-sx-gcnt+1, y+my-sy, gcnt, 1, 0, 0, gcnt, priv->buf);
|
||||||
gcnt = 0;
|
gcnt = 0;
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
|
|
Loading…
Add table
Reference in a new issue