An image processing apparatus comprising: a light source configured to emit light onto a glass; an image-capturing unit on the same side of the glass as the light source and configured to capture light from an image-capturing region (213, 214) including light from distant objects on the opposite side of the glass and reflection light emitted from the light source and reflected by the glass; an optical filter configured to filter light transmitted onto the image-capturing region and comprising an object detection filter configured to detect an object attached to the glass using light falling onto a portion of the image-capturing region entering through the object detection filter; an exposure control unit configured to determine a first exposure amount with which an image of the distant objects is captured in a first region of the image-capturing region detecting light which does not enter through the object detection filter, and a second exposure amount with which an image of the object attached to the glass is captured in a second region of the image-capturing region detecting light which enters through the object detection filter, the second exposure amount being different from the first exposure amount; and an image analysis unit configured to analyze a captured image obtained by the image-capturing unit; wherein the image-capturing unit is configured to switch an exposure amount used in an image-capturing process for the image-capturing region between the first exposure amount and the second exposure amount; wherein the image-capturing unit is configured to perform the image-capturing process continuously with the first exposure amount a predetermined first number of times, and then to perform continuously the image-capturing process with the second exposure amount a predetermined second number of times; and wherein the image analysis unit is configured further to detect the object attached to the glass by analyzing the captured image, and the image-capturing unit is configured to increase a ratio of the second number of times with respect to the first number of times when the object is detected. a light source configured to emit light onto a glass; an image-capturing unit on the same side of the glass as the light source and configured to capture light from an image-capturing region (213, 214) including light from distant objects on the opposite side of the glass and reflection light emitted from the light source and reflected by the glass; an optical filter configured to filter light transmitted onto the image-capturing region and comprising an object detection filter configured to detect an object attached to the glass using light falling onto a portion of the image-capturing region entering through the object detection filter; an exposure control unit configured to determine a first exposure amount with which an image of the distant objects is captured in a first region of the image-capturing region detecting light which does not enter through the object detection filter, and a second exposure amount with which an image of the object attached to the glass is captured in a second region of the image-capturing region detecting light which enters through the object detection filter, the second exposure amount being different from the first exposure amount; and an image analysis unit configured to analyze a captured image obtained by the image-capturing unit; wherein the image-capturing unit is configured to switch an exposure amount used in an image-capturing process for the image-capturing region between the first exposure amount and the second exposure amount; wherein the image-capturing unit is configured to perform the image-capturing process continuously with the first exposure amount a predetermined first number of times, and then to perform continuously the image-capturing process with the second exposure amount a predetermined second number of times; the image analysis unit is configured further to detect the object attached to the glass by analyzing the captured image, and the image-capturing unit is configured to increase a ratio of the second number of times with respect to the first number of times when the object is detected.