Closed armel closed 8 years ago
ππππππ
The only thing that is holding me back from merging this, is that there should be a better way to restrict the colors on the image. I found this but in my testing it always gave white in the palette and other grayscale. It just seems better to use the built-in method of Pillow, but it is really annoying
Agree with you. There should be a better way. But it could be improved in a future release :)
Juan, I take a look at your link on stackoverflow. Note that Iβm precisely using the Image.quantize method (Do not reinvent the wheel). Check my make_lego_palette(image, palette) function. Itβs the same approach :)
oh no this is awkward, I haven't had time to go through all your additions, so I assumed it was like the other merges. I'll merge this very soon ;)
Travis CI is green now (my bad...)
It seems that there are 3 palettes: solid (33 colors), transparent (14 colors) and effects (4 colors). You can use one of them or all the 3.
$ legofy --palette solid image.jpg $ legofy --palette transparent image.jpg $ legofy --palette effects image.jpg $ legofy --palette all image.jpg
There is another one palette, mono, with only 2 colors (black and white...). It's just for test and fun...