1. Field of the Invention
The present invention generally relates to stereo imaging, and more particularly to a stereo image correction system and method.
2. Description of Related Art
Three-dimension (3D) imaging is a technique for displaying an image by presenting two images (i.e., a left image and a right image) respectively to the left and right eyes of a viewer. The viewer can perceive 3D depth, with or without wearing 3D glasses, according to disparity between the two images.
However, the two images captured by a 3D imaging system may probably possess a vertical shift between them as exemplified in
For the reason that conventional 3D imaging system could incur depth disturbance due to vertical shift between the left image and the right image, a need has arisen to propose a novel scheme to correct or compensate the disturbance.
In view of the foregoing, it is an object of the embodiment of the present invention to provide a stereo image correction system and method for compensating a vertical shift between a left image and a right image in a 3D imaging system.
According to one embodiment, a stereo image correction system includes a shift unit, a depth generator, a high-pass filter, an analysis unit and a compensation unit. The shift unit is configured to vertically shift one image to be shifted of a stereo image pair with a shifted amount, while another one image of the stereo image pair is maintained still, thereby resulting in a shifted image pair containing a shifted image and a maintained image. The depth generator is configured to generate a depth map containing depth values on pixels or blocks of the shifted image pair. The high-pass filter is configured to pass frequencies of the depth map above a predetermined, cutoff frequency but attenuate frequencies below the predetermined cutoff frequency, thereby resulting in a filtered output containing high-frequency component of the depth map. The analysis unit is configured to determine a matching point according to a number of the filtered outputs and a number of the corresponding shifted amounts, wherein the shifted amount at the matching point is determined as a matched shifted amount. The compensation unit is configured to vertically shift the image to be shifted of the stereo image pair with the matched shifted amount, thereby resulting in a compensated image pair.
In the embodiment, a stereo image pair comprised of a left image (L) and a right image (R) is received by a stereo image corrector 10. The stereo image pair may be provided, for example, by a 3D image recorder or a 3D image generator. The stereo image pair is subjected to a shift unit 101 that may vertically shift one (e.g., the left image) of the stereo image pair with a shifted amount, while keep the other one (e.g., the right image) of the stereo image pair still. For example, the shift unit 101 shifts (up or down) one or more lines of the left image for every frame or frames. The shifted amount is fed to an analysis unit 103, and is recorded in a memory 1031, which may be internal or external to the analysis unit 103.
The shifted image pair (i.e., the shifted image and the maintained image) from the shift unit 101 is then fed to a depth generator 105 that generates a depth map containing depth values on pixels or blocks of the shifted image pair. For example, an object near a viewer has a greater depth value than an object far from the viewer. It is noted that the image areas overlapped between the shifted image and the maintained image may be scaled before feeding to the depth generator 105.
Subsequently, the depth map is processed by a high-pass filter (HPF) 107 that passes high frequencies of the depth map but attenuates frequencies below a predetermined cutoff frequency. The filtered output containing the high-frequency component of the depth map from the HPF 107 may be utilized to indicate the shifting between the images of the shifted image pair. For example, low filtered output (i.e., low high-frequency noise) indicates that shifted image and the maintained, image of the shifted image pair are better matched. On the other hand, high filtered output (i.e., high high-frequency noise) indicates that shifted image and the maintained image of the shifted image pair are worse matched. The high-frequency component may be generated by counting the amount of frequencies above the predetermined cutoff frequency. Alternatively, the high-frequency component may be generated by accumulating (or integrating) the magnitudes of frequencies above the predetermined cutoff frequency.
The filtered output is then fed to the analysis unit 103 and recorded in the memory 1031.
Afterwards, the matched shifted amount is fed to a compensation unit 109 that receives the stereo image pair and then vertically shifts one (e.g., the left image) of the stereo image pair with the matched shifted amount, while keeps the other one (e.g., the right image) of the stereo image pair still. After shifting the image with the matched shifted amount, the shifted image may contain a blank portion. In consideration of this, a technique similar to that as exemplified in
The stereo format of the compensated image pair (i.e., the compensated image and the maintained image) may be converted, when required, by a stereo format converter 12. The required stereo format depends on display type of a display device 14, for example, a display device operated with shutter glasses, polarized, glasses or diopter glasses e.g., red-cyan glasses).
Although specific embodiments have been illustrated and described, it will be appreciated by those skilled in the art that various modifications may be made without departing from the scope of the present invention, which is intended to be limited solely by the appended claims.