99designs / colorific

Automatic color palette detection
ISC License
700 stars 55 forks source link

Include black and white color ? #15

Closed jaumard closed 11 years ago

jaumard commented 11 years ago

Hi,

It's possible to include white and black colors ? Or can you add an option to add them ?

Thanks Jim

larsyencken commented 11 years ago

Hi Jim, you can tune this with the --min-saturation command-line option. If you use --min-saturation=0, it won't exclude grayscale shades.

deronsizemore commented 9 years ago

Hello. Was hoping someone was still monitoring this.

I'm attempting to use this with a django application have it working except that it seems to still be excluding black colors even though I've passed min_saturation=0. Here's my code:

extracted_palette = palette.extract_colors(image, max_colors=10, min_saturation=0)

Can you help me out here with including black? Why isn't this working?

Thanks

EDIT: I ended up stumbling on the answer for my particular issue. min_saturation: None seems to work