thephpleague / color-extractor

Extract colors from an image like a human would do.

Home Page:thephpleague.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to filter balck color ?

farazirfan47 opened this issue · comments

I am detecting most representative color from an image but I also want to detect if detected color is white or black. Is there any way we can do that ?

Black is 0 and white is 16777215, so you could compare the colors to see if they match those (or are within a small distance away).