Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Indexed png transparency increased to incorrrect length of 255 #16

Open
jamesbrobb opened this issue Feb 27, 2014 · 0 comments
Open

Indexed png transparency increased to incorrrect length of 255 #16

jamesbrobb opened this issue Feb 27, 2014 · 0 comments

Comments

@jamesbrobb
Copy link

Hi,

in png.js at line 135 you're incorrectly lengthening transparency.indexed to 255, if it's shorter.

The max length of that array should actually be the length of the palette divided by 3. And if it's parsed and is any longer there should be an error.

So it should read,

short = (this.palette.length/3) - this.transparency.indexed.length;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant