Camera As the Color Sensor ?

Hi,

I'm doing a project that requires changing LED colour according to the surroundings. I know everything I need about LEDs, but the problem is getting colour information from outside. It has to pick just a few pixel colours from the camera. I tried to find something but there is nothing useful :confused: Is there any solution for that ? Like using a few colour sensors instead and adding lens so it would focus light on sensors ?

Waiting for the answer :wink: