Udo Klein wanted to squeeze something interesting out of his Blinkenlight Arduino shield. It has a 20 LEDs meant for output. But wait, simply speaking LEDs are nothing more than exposed diodes that can detect light also. With this thought he switched LED cathodes to +5V what makes them reverse biased. In this case diodes act as capacitors.
From physics we know that semiconductor junction exposed to light becomes more conductive. So when LED cathode is connected to +5V and anode to 0V it simply charges as capacitor. Then program switches anode pin to high Z input and read its state. Depending on time taken pin to go from high to low is directly related to light intensity on diode that causes bigger photo current. With 20 LEDs positioned in row he simply made a 20 pixel camera. Output is seen on serial monitor where pixels are sent in text mode via USART. You can clearly see effect on video.