Tech Note
TN-0902 Date: 02/06/09
USING A 2CCD CAMERA TO CREATE HIGH-DYNAMIC RANGE IMAGES
Some imaging scenarios push dynamic range beyond the capabilities of the typical sensor. This is especially
true where incident light is present (e.g., imaging a light source and the surrounding area). This can also
occur in situations with bright reections or in high contrast indoor/outdoor scenes where one needs to capture details in both bright sunlight and dark shadows. One technique for dealing with these situations is to
combine or “fuse” two images with different exposures so that the dynamic range is signicantly increased.
An illustration of this technique can be seen in the following images captured by JAI’s AD-081 camera. Here,
the incident light coming from the light bulb makes it impossible to examine both the bright and the dark
areas of this scene in a single exposure. Instead, two exposures are used as shown in Figure 1. The left half
of the image shows what the image looks like when captured with a slow shutter speed. This is able to
capture details in the surrounding areas while letting the brightest parts of the scene over saturate. The
right half of the image shows the result of a much faster shutter speed, enabling details to be seen in the
brightest portions of the image while rendering much of the surrounding area as nearly black. When “fused,”
as shown in Figure 2, the composite image is able to span the full dynamic range of the scene.
FIGURE 1 – Bracketing the exposure FIGURE 2 – Fused HDR image
In landscape or architectural photography, this effect be achieved with a single CCD camera taking two
consecutive images. However, in “live action” settings – such as industrial inspections, surveillance, vehicle
applications, and the like – the presence of motion requires simultaneous capture of the two images that are
to be fused. This can be done with two cameras, looking at the same scene. However, to avoid alignment issues, it is best if the CCDs are in a single camera with a prism-based 2CCD arrangement. The AD-081 camera
from JAI uses this 2CCD prism-based approach to increase dynamic range while ensuring precise registration
of the two image streams.
Note: in some industrial settings, it may be possible to use a one-camera scenario if the object being in-
spected stops briey and the camera being used has the ability to automatically take two closely-spaced images with dramatically different gain and/or shutter settings. JAI’s “sequence trigger” function supports this
approach, where feasible. It is available in many of the company’s C3 Camera Suite models with GigE Vision
interfaces.
Calibrating sensor response and output
In a 2CCD scenario such as the AD-081CL, establishing a high dynamic range image comes from fusing the
output of the two sensors to effectively increase the bit depth of the nal image. The mathematical equation for the display then becomes a function of the calibration of the 2 sensors. There are several strategies
that can be used.
Tech Note
Example 1 - Maximum Dynamic Range (no overlap)
To create an image that spans the maximum range of light intensities, use shutter settings to calibrate the 2
sensors so that Sensor B = Sensor A * 1024. In other words, the light needed to generate 100 counts from Sensor B is 1024 times the light needed to create 100 counts from Sensor A.
For example, if Sensor A is operating with the shutter off (1/30 sec.), Sensor B would need to be set as close
as possible to 1/30720 sec. using the camera’s pre-set shutter or programmable exposure control. This would
result in 1 count of output from Sensor B being roughly equivalent to what would be 1024 counts from Sensor
A, had it not saturated at 1023 counts.
Now, create a fused image by applying a post processing routine that uses output from Sensor A when it is
below saturation and from Sensor B when Sensor A is saturated. A simplied representation of this routine
could be the Boolean expression:
if (pixel B < 1){
pixel_out = pixel A
}else{
pixel_out = pixel B * 1024
}
This approach uses Sensor B to add 10 more bits of dynamic range to the image, albeit at a lower precision
than the lower 10-bits due to the calibration factor (see Figure 3). Creating the actual algorithm for fusing
the two images will depend on the type of post processing software being used. It could involve writing programming code, or could be done in a more visual fashion using a graphical user interface.
FIGURE 3 – Maximum dynamic range calibration
One issue with any high dynamic range approach is that it is hard to display or print such an image. Besides
the challenge of handling the data in a Microsoft OS, most displays and/or printers do not have this much
dynamic range and will diminish your good work. Typical computer monitors today feature contrast ratios
on the order of 1,000 to 1, enabling them to approximate 10-bit dynamic range (~60 dB). A growing number
of monitors today offer contrast ratios in the 2,000:1 to 5,000:1 range enabling them to support 12 bits of
dynamic range (~72 dB).
NO. TN-0902 pg 2
2