a rain detection apparatus includes a camera that views a surface and a processor that captures an image from the camera . the processor generates a signal indicative of rain on the surface from information contained in the captured image and optionally drives a surface cleaning apparatus in response thereto . the apparatus captures images focused at a plurality of distances . the processor includes an edge detector that detects edges visible in the captured image and a difference structure that calculates the difference between the number of edges visible between differing images . the edge detector disregards edges close to areas of light larger than the largest raindrop that is desired or expected to be detected . the apparatus optionally includes a backlight , and the difference in numbers of edges between frames with and without the backlight illuminated are used to distinguish between background features and rain on the surface .