My approach:
Create a visual memory set of small icons ( this can have many "definitions" and occupies little memory ) and cross check subject picture using an XOR comparison. ( The lowest sum score value should be the closest match. )
This is a starting point.
One can combine other help methods like increased contrast ( ie. pixel != 0 it is 255 ) with mentioned xor and color amounts score comparison.