tjvr / kurt

Python library for reading/writing MIT's Scratch file format.
https://kurt.tjvr.org
GNU General Public License v3.0
86 stars 24 forks source link

Colormap fix #5

Closed bboe closed 12 years ago

bboe commented 12 years ago

Integrated my colormap changes into your existing changes. Verified the thumbnails are correct with a number that I tested.

tjvr commented 12 years ago

Are you sure (on line 41) that it shouldn't be full = 255 rather than full = 2**depth - 1? The returned color values have to be in the range 0-255, you see. (I can't seem to get any suitable images to test this with...)

bboe commented 12 years ago

Oh maybe you are right. I was thinking the depth of each color was lessened with smaller depths not just the number of colors. I will update tomorrow.

Edit: I'll also hard code in all the values in the tuples since it it seems they are constant.

bboe commented 12 years ago

Added #6 to address the issue you mentioned.