stil / gif-endec

PHP GIF encoder and decoder
63 stars 16 forks source link

Severe gif encoding bug #15

Open mjphaynes opened 4 years ago

mjphaynes commented 4 years ago

There is a bug here: https://github.com/stil/gif-endec/blob/9b9b7d4957a2283bdbd25d8a667a41c419c125f5/src/Encoder.php#L183

See here for correct logic: https://github.com/lunakid/AnimGif/blob/master/src/GifCreator/AnimGif.php#L361

This causes gifs to be corrupted in certain situations

marrone commented 4 years ago

I have an issue with corrupted gifs as well, but the linked code looks comparable. I think the issue is elsewhere, but I've not found it yet

mjphaynes commented 4 years ago

Yeah this could be your issue as well as this is a pretty major flaw in the logic.

I don't know if this package is still maintained? If it is I could submit a pull request?