bitbank2 / AnimatedGIF

An optimized GIF decoder suitable for microcontrollers and PCs
Apache License 2.0
367 stars 51 forks source link

In ESP32_LEDMatrix_I2S.ino iWidth is not intialized. #65

Closed gkiranps closed 8 months ago

gkiranps commented 1 year ago

Amazing Project, Thanks for sharing. Found a tiny bug.

In ESP32_LEDMatrix_I2S.ino iWidth is not initialized.

int x, y, iWidth;

usPalette = pDraw->pPalette; y = pDraw->iY + pDraw->y; // current line

s = pDraw->pPixels; if (pDraw->ucDisposalMethod == 2) // restore to background color { for (x = 0; x < iWidth; x++)

Can be fixed by adding on line 69 iWidth = pDraw->iWidth;

Thanx

bitbank2 commented 1 year ago

I didn't write that example sketch. Can you make the correction and submit a PR?