Use proper luminosity difference to determine correct color.

Signed-off-by: retep998 <retep998@verizon.net>