Pixel resolution phototransistor array
You can use an optical mouse sensor, basically a low resolution B&amp;W camera. The Agilent ADNS-3040 is one such sensor. You might need some optics for your application.