Colors are evaluated and a color in the middle is selected as threshold. WIP