detect color patterns for the entire image