This was part of a second year project looking into different aspects of light. Visual information about a space comes from the interaction between a light source and the structures in that space. Light emanates from a source and is reflected from these structures to reach someone’s eye. The light may be reflected from a surface either specularly, meaning in one direction, or diffusely, meaning in a multitude of directions. Still water can give a good example of a specular reflection and matte paper a good example of a diffuse one. Light being reflected from a material may have both specular and diffuse components, the specular part often occurring in a small bright area at a suitable angle relative to a light source. For this reason, specular reflections in these materials are sometimes called ‘specular highlights’. These highlights give additional visual cues about the material and they also change as someone moves around the object, giving cues relating to its structure. The reflections from the lights in the photo below give a good example of specular highlights.

Graphics researcher Paul Debevec devised a method for isolating specular light in his Digital Emily project. The method takes advantage of interesting property of light which is specularly reflected from certain materials. If the material is dielectric (eg glass or water) then this light will have a uniform polarisation. Polarisation refers to the orientation of the light when represented as a wave, and it’s possible to filter out this light with a polarising filter.

The method uses two photographs of the same scene, the first one is a regular photograph and the second is one with specular highlights removed by a polarising filter. The second image is then subtracted from the first to leave largely specular light. This project looked at replicating this technique and seeing how practical it is when taken outside a lab or studio environment and into ‘the wild’.

Starting off with something simple, a teeshirt was soaked in water so that it would reflect specular light well. A regular photograph was taken, followed by another which used a polarising filter to largely remove the specular light.

The filtered photo was then subtracted from the unfiltered one, yielding the following image.

The process generated some noise, but fortunately this is easy to clean up. The digital image here is stored as a series of pixels, each pixel having values for the red, green and blue colours. These values range from 0 to 255 and values outside this range wrap around, meaning arithmetic is done modulo 256. For example, 10 – 5 = 5, which is in range but 10 – 15 = -5 which is out of range and will wrap around to 250. This means that a pixel with a red value of 0 in the unfiltered exposure and 1 when filtered will have a value of 254 (bright red) after the subtraction between the images, rather than -1 (black). Setting values above a threshold to zero resulted in the following image.

Moving outdoors brought mixed results. There’s a good specular reflection on this fence which was easy to isolate.

However the scene below proved more difficult. The leaves are obviously reflecting specular light, and there’s possibly a good deal more of it elsewhere in the scene that isn’t so easy to spot. However, the difference between the filtered and unfiltered images looks a lot like a negative and does little if anything to reveal any specular light.

So what’s going on? Inverting the difference image lends weight to the possibility that the process is producing something similar to a negative.

This isn’t all that surprising, since the parts of the trees which are reflecting specular light are white in the unfiltered image and green in the filtered one. Using additive light, white – green = purple. The problem is being caused by having a limited range of possible values for a pixel. Ideally, the unfiltered image will capture both the specular and diffuse light and the filtered image will capture only the diffuse light. But information is lost by exposing to white — once a pixel reaches a value of 255 it can’t go any further. This means that specular light is lost which results in colour distortions like above. To work around this problem, the below images were exposed such that the specular highlights are in the mid to high range and avoiding exposing them to white. The difference image was then brightened to compensate for this.

Specular highlights are much clearer in the resulting image and the visual detail they add to a scene starts to become apparent. However, there’s still some colour distortion. Moving back indoors and using the structure below allowed more control of light sources to examine this problem in more detail.

Applying the lessons learned so far on a variety of objects and light configurations yielded images like the following and did little to sort out the colour distortions.

The grazing angle is something that was overlooked. According to Fresnel’s equations, the ratio of light reflected to that refracted is dependent on this angle. The lower the grazing angle, the more light will be reflected.

Keeping this angle low yields more specular light relative to diffuse light, making it easier to isolate and reducing colour distortion. This worked well in the image below, which also makes it obvious why specular might be avoided in certain scenarios, particularly in areas like fashion photography.

With constraints around lighting, exposure and materials, catching specular light ‘in the wild’ becomes something of a trade off. However, it is possible to reveal details that would otherwise be difficult to spot. This can be seen in the below image, which reveals specular light that would ordinarily be obscured by daylight.

The software developed in this project is available as a plugin for the GIMP image editing program. More details can be found here.