Vision & Sensors | Lighting
The Critical Role of Wavelength and Filters in Machine Vision Illumination
Harnessing light’s hidden powers for precision inspection goes beyond the spectrum of visible light

Image Source: Advanced Illumination
Proper illumination is essential for machine vision systems to capture high-quality images for inspection and analysis. Achieving optimum image contrast and overcoming challenging inspection conditions require careful consideration of not only the geometry, pattern, structure, and intensity of the lighting but also the wavelength of the light and the use of optical filters. Machine vision engineers can address challenging imaging problems and develop more robust and reliable inspection systems with a solid understanding of wavelengths and filtering techniques.
Leveraging Wavelength for Enhanced Contrast
Multidisciplinary applications, such as machine vision, spectroscopy, and imaging, require a comprehensive understanding of how different materials interact with light at various wavelengths. A material’s chemical composition and structure determine the characteristics of interactions such as reflection, absorption, transmission, and fluorescence.

Figure 1: An illustration of the electromagnetic spectrum, highlighting wavelength boundaries and showing the UV, visible, and infrared portions. (Image Source: Advanced Illumination)
It is fundamental to machine vision lighting that materials reflect and absorb various wavelengths of light differently. This phenomenon occurs in both monochrome and color imaging. By using specific wavelengths of illumination, it is possible to enhance the contrast between a part or feature of interest and its background.

Figure 2: (a) Light interaction on surfaces. (b) Specular surfaces; angle of reflection equals angle of incidence (phi1 = phi2). (c) Non-specular (diffuse) surfaces. (Image Source: Advanced Illumination)
When an object appears red under white light, it’s because it preferentially reflects red wavelengths while absorbing other wavelengths of light more strongly. By exploiting this selective reflectivity with colored lighting, one can enhance or suppress the visibility of certain features.
When dealing with colored objects or backgrounds, using colors opposite one another on the color wheel generates the greatest contrast. For example, green light suppresses red reflection more than blue or violet does. With a limited palette of known colors, the technique can even be used to differentiate colored parts using a monochrome camera.

Figure 3: With a limited palette of colors and a color wheel of warm versus cool colors, a monochrome camera can generate differential image contrast and even differentiate colors. (Image Source: Advanced Illumination)
Neutralizing Visible Color Difference
Near-infrared (NIR) illumination offers unique advantages in some applications. NIR reflectivity is more dependent on material texture and composition than pigmentation. So NIR light effectively neutralizes contrast differences based on visible color.
This property can be useful when less contrast is desired, such as when inspecting multicolored objects like crayons, where color reflectance from white light can make it difficult to read print due to contrast differences. NIR lighting can help even out these contrast differences and allow black text to be read consistently on variously colored backgrounds

Figure 4: The evening out of contrast differences among the color papers on crayons, under white light (a) and under NIR light (b), allows the blue crayon print to be more easily read and verified. (Image Source: Advanced Illumination)
Some transmissive lighting applications can benefit from the longer wavelengths of NIR light since they can penetrate polymer materials better than visible wavelengths.
Interaction of Shorter Wavelengths
Conversely, shorter wavelengths such as ultraviolet (UV) and blue light interact with surfaces differently. For shorter wavelengths, surface scattering is proportional to the fourth power of the frequency. So blue light is more effective for imaging shallow surface features on materials such as black rubber or enhancing laser etching visibility.

Figure 5: Laser etch on gear face, limited to high angle of incidence. (a) No response to red light, 660 nm. (b) Significant scattering from blue light, 470 nm. (Image Source: Advanced Illumination)
Fluorescence Applications
In some materials, fluorescence is naturally occurring. Alternatively, applying fluorescent dyes can produce longer wavelength light with exposure to short wavelength illumination (usually UV). Machine vision applications in printing, security, and pharmaceuticals often use this phenomenon.
Fluorescent techniques reveal otherwise invisible features. UV-excitable security inks make it possible to print covert markings that are visible only under UV illumination. Some materials, such as nylon fibers, exhibit natural fluorescent properties under UV light.
One challenge associated with fluorescence-based imaging is that the emitted light tends to be much weaker than the excitation light. Careful filtering and ambient light control help isolate the fluorescent emission from background illumination.
The Power of Optical Filtering
Ambient light may have a detrimental impact on the quality and consistency of inspections, especially with the use of a full-spectrum source, such as white light. Common ambient light contributors that can have an impact include overhead factory lights, sunlight, neighboring workstation task lighting, or even machine vision lighting from adjacent work cells, known as friendly fire.
Glare from the machine vision system light source itself is not considered ambient. This reflection must be treated differently, typically with polarization or system/lighting geometry changes. There are three practical methods for dealing with ambient light: high-power strobing with short-duration pulses, physical enclosures, and pass filters. (See Figure 6 for pass filter varieties.)
The ambient light mitigation method applied depends on many factors. High-power strobing overwhelms and washes out the ambient contribution. However, this approach has disadvantages in ergonomics, cost, and implementation effort. Not all sources can be strobed; examples are fluorescent and quartz-halogen lights. If strobing is impossible or if the application requires a color camera, then full-spectrum white light is necessary to provide accurate color reproduction and balance. In such a circumstance, a narrow wavelength pass filter would be ineffective because it would block a major portion of the spectral white light contribution. Consequently, the only choice would be an enclosure shielding the inspection.
Because optical filters selectively transmit or block specific wavelengths of light, they are useful tools for mitigating the effects of ambient light. Filters can dramatically improve image contrast. When properly applied, filters also enable the use of specialized imaging techniques, such as fluorescence imaging. Common optical filters used in machine vision include:
- Band Pass Filters: These filters transmit a specific range of wavelengths while blocking others and are useful for isolating particular spectral features or working with monochromatic light sources.
- Long Pass Filters: Transmitting wavelengths longer than a specific cutoff point, long pass filters are often used with NIR imaging to block visible light.
- Short Pass Filters: Transmitting wavelengths shorter than a specific cutoff point, short pass filters can be used to block NIR when only visible light response is desired.

Figure 6: A typical spectral transmission curve for a long pass filter (a), a short pass filter (b), and a band pass filter (c) and a typical threaded band pass filter for red 660 nm light (d). (Graphics Courtesy of Midwest Optical, Palatine, IL.)
Role of Optical Filters in Machine Vision
Ambient light input from overhead lighting or sunlight can significantly impact the quality and consistency of machine vision inspection. This is especially true with the use of a full-spectrum light source, such as white light.
One main application for optical filters is ambient light mitigation to prevent uncontrolled ambient illumination from ruining the consistency and reliability of machine vision inspections. A band pass filter matched to the wavelength of the primary illumination source can block most ambient light while still allowing the camera to receive the desired signal.
A camera lens fitted with a red band pass filter will transmit red light from a red LED light source while blocking most ambient light from fluorescent lights or mercury vapor lamps. Pulsed LED lighting makes this technique particularly effective.
Polarization for Glare Reduction
Machine vision applications often suffer from glare and reflections, which obscure critical features. Polarizing filters offer a powerful tool for reducing these problems. Light becomes partially polarized when it reflects off a nonmetallic surface. It is possible to eliminate much of the glare by using a polarizing filter oriented perpendicular to the reflected polarization.

Figure 7: An arrangement of relative optical paths between a polarizer and an analyzer. (a) Front lighting arrangement. (b) Single-wave oscillation through a linear polarizer. (Image Source: Advanced Illumination)
It is usually best to use polarizing filters in pairs — one on the light source and one on the camera lens — for maximum effectiveness. Glare reduction can be finetuned by rotating these filters relative to each other. Materials with high reflection or transparency can be examined using this technique.
Although polarization can significantly improve image quality in many situations, it does come at the cost of overall light transmission. It is common for polarizing filters to reduce light intensity by 50% or more, which may necessitate longer exposure times or more intense illumination.
Enhancing Edge Detection With Collimation
Although light collimation is not strictly a filtering technique, it does share some similarities in its application and benefits. In collimation, light rays are made parallel with the help of specialized films or lenses. Machine vision applications that require high-precision measurements and edge detection benefit greatly from collimated backlighting.

Figure 8: (a) Light ray tracing with collimation on the left side versus the more random ray exit angles of the non-collimated backlight. (b) A curved part in front of a non-collimated backlight with better edge definition. (c) The same part in front of a film-collimated backlight showing greater edge definition on the true maximum projection of the part. (Image Source: Advanced Illumination)
Compared to diffuse illumination, collimated light produces sharper shadows and more defined edges. For gaging and measuring tasks, this leads to more accurate edge locations in captured images. Moreover, collimation reduces uncertainty in measurements caused by light diffraction around object edges.
Practical Considerations and Challenges
One of the most important factors when designing a machine vision system is obtaining the highest image contrast. When designing the optimal machine vision illumination system, contrast enhancement via proper wavelength selection and optical filtering is key. However, certain tradeoffs must be considered.
Filters always reduce the amount of light that reaches the imaging sensor in a camera. To compensate for this decrease in light intensity, the exposure time or aperture of the lens may need to be increased or a more powerful illumination source may be required.
High-intensity light sources can generate a significant amount of heat, especially in the IR and UV wavelengths. It’s critical in such instances to incorporate additional cooling measures for proper thermal management to ensure consistent performance and illumination system longevity.
Monochromatic light sources or narrowband filters with color cameras tend to interfere with accurate color reproduction. In cases where true color imaging is required, filtering should be minimized and broadband white light sources should be used.
The cost of the machine vision system increases with the addition of specialized light sources and optical filters. So it’s important to compare performance gains against budget constraints.
Some advanced applications may require capturing images under multiple wavelengths of light. In addition to the richer data provided, multispectral imaging applications tend to increase the complexity of image acquisition.
Seeing Is Achieving
In the arsenal of machine vision engineers, wavelength selection and optical filtering are indispensable tools. The interaction of light with different materials and the selective transmission properties of optical filters make it possible to solve challenging inspection problems and build more robust vision systems.
For vision system designers, mastering wavelength and filtering techniques will remain a critical skill into the future as machine vision applications continue to push the limits of speed, precision, and reliability. Selecting the right color light enhances features of interest, UV fluorescence reveals hidden features, filters mitigate ambient light contamination, and polarization reduces glare. By combining these techniques, image acquisition can be optimized.
The key is fully analyzing the requirements of each application. When system designers understand the optical properties of the material being inspected and select the best combination of wavelengths and filtering, machine vision systems can achieve levels of performance and consistency that simple white light illumination alone would not be able to achieve.
Looking for a reprint of this article?
From high-res PDFs to custom plaques, order your copy today!