The present disclosure relates to alignment of an image projected by a projection apparatus.
In recent years, a projection display system using a single or a plurality of projection display apparatuses (hereinafter referred to as “projection apparatus”) has been known, for example, in amusement facilities and museum displays. The projection apparatus needs to generate a projection image according to the position and the distortion of the projection area so that the image is projected on a desired position of the projection plane.
US Patent Application Publication No. 2017/0180689 discloses a method for projecting a calibration pattern image from a projection apparatus, imaging the projection area with a camera, and correcting the distortion and aligning the projected image based on the result of analysis of the captured image.
The method disclosed in US Patent Application Publication No. 2017/0180689 assumes that the projection area of the captured image is rectangular in the analysis of the captured image. If the projection display apparatus or the image capturing apparatus is disposed at an angle to the projection plane, the projection area of the captured image is not always rectangular. This can lead to low-accuracy analysis of the captured image.
The present disclosure provides an image processing apparatus that estimates the distortion of a projected area in a captured image obtained by capturing an area projected by a projection apparatus and that transforms the projected area to a rectangle based on the estimated distortion. In one aspect of the present disclosure, an image processing apparatus that transforms distortion of an image projected by a projection apparatus includes an obtaining unit and a transformation unit. The obtaining unit is configured to obtain a captured image acquired by capturing, with an image capturing apparatus, a projected image including a pattern image projected by the projection apparatus. The pattern image contains at least three objects having different appearances from one area to another. The transformation unit is configured to specify a local area in the captured image and transform the local area based on a positional relationship among the at least three objects in the local area. The transformation unit transforms the local area by using a positional relationship between an object of a first appearance and an object of a second appearance in the local area and a positional relationship between the object of the first appearance and an object of a third appearance in the local area.
Further features of the present disclosure will become apparent from the following description of exemplary embodiments with reference to the attached drawings.
Embodiments of the present disclosure will be described hereinbelow with reference to the attached drawings. The configurations of the embodiments are given for mere illustrative purposes, and the present disclosure is not limited to the illustrated configurations.
In the present embodiment, a method of image processing for alignment of a single projection display apparatus (hereinafter referred to as “projection apparatus”). The projection apparatus is disposed to project an image to a desired position on a screen. However, it is practically difficult to dispose the projection apparatus at a correct position so as to be opposed to the screen. If the projection apparatus is not opposed to the screen, the image (hereinafter referred to as “projected image”) projected on the screen from the projection apparatus is distorted. For this reason, a pattern image for alignment is projected from the projection apparatus, and the captured image obtained by capturing the pattern image projected on the screen is analyzed. By analyzing the captured image, the positional relationship between the projection apparatus and the screen can be detected, and an image to be projected by the projection apparatus can be transformed in consideration of the detected positional relationship. For the analysis of the captured image, the projection area of the captured image (hereinafter referred to as “imaging projection area”) has to be rectangular. Accordingly, in the present embodiment, processing for specifying the imaging projection area and transforming the imaging projection area to a rectangle is performed. The term “rectangle” herein refers to a quadrangle whose four corners have a right angle, such as a rectangle.
Processing performed by the image processing apparatus 100 will be described in detail. The image processing apparatus 100 includes a pattern generation unit 101, a color-based superposition unit 102, a color-based separation unit 103, and a transformation unit 104. Although
The pattern generation unit 101 generates a pattern image including a pattern serving as a reference (reference pattern image). The pattern includes a plurality of predetermined objects.
The color-based superposition unit 102 generates a pattern image to be projected by the projection apparatus 120 based on the reference pattern image. The color-based superposition unit 102 executes processing for shifting the positions of the dots in a predetermined direction and processing for changing the color of the shifted dots on the pattern image a plurality of times to thereby generate a plurality of pattern images (shift pattern images) in which the positions and the color of the dots differ. The color-based superposition unit 102 superposes a plurality of shift pattern images on the reference pattern image.
The color-based superposition unit 102 selects colors for the dots 301 in the reference pattern image, the dots 302 in the upper right shift pattern image, and the dots 303 in the lower right shift pattern image and changes the color of each dot to the selected color. In this case, the color-based superposition unit 102 selects green (G) as the color of the dots 301 in the reference pattern image, blue (B) as the color of the dots 302 in the upper right shift pattern image, and red (R) as the color of the dots 303 in the lower right shift pattern image. After changing the colors of the dots in the reference pattern image, the upper right shift pattern image, and the lower right shift pattern image, the color-based superposition unit 102 superposes the three pattern images with different dot colors.
Next, a processing unit to be executed before alignment using the generated projection pattern image will be described. The color-based separation unit 103 obtains a captured image obtained by the image capturing apparatus 130 capturing an image of the projection plane on which the projection pattern image is projected and separates the captured image into color-by-color pattern images. First, the color-based separation unit 103 specifies an imaging projection area and clips a partial rectangular area of the imaging projection area. For example, the color-based separation unit 103 specifies the imaging projection area using the following method. First, the projection apparatus 120 projects a solid white image before projecting the projection pattern image. The image capturing apparatus 130 captures an image of the projection plane on which the solid white image is projected and binarizes the captured image using a threshold for separating the solid white image from the background area. The color-based separation unit 103 specifies the imaging projection area by detecting the outline of the binarized white area. Then, the color-based separation unit clips the imaging projection area from the captured image obtained by the image capturing apparatus 130 imaging the projection plane on which the projection pattern image is projected.
Furthermore, the color-based separation unit 103 derives the positional relationship among different dots in the captured image. Specifically, the color-based separation unit 103 calculates a shift amount indicating the distance between the reference dot and the upper right dot and a shift amount indicating the distance between the reference dot and the lower right dot. As illustrated in
The transformation unit 104 estimate the distortion of the projected image based on the shift amounts in the different directions in the pattern images output from the color-based superposition unit 102 and the shift amounts in the different directions in the captured images of the pattern images projected by the projection apparatus 120. The transformation unit 104 calculates the shift amount indicating the distance (positional relationship) between the reference dot and the upper right dot in the captured image and the amount of change in the distance (positional relationship) between the reference dot and the upper right dot in the captured image. Furthermore, the transformation unit 104 calculates the shift amount indicating the distance (positional relationship) between the reference dot and the lower right dot in the captured image and the amount of change in the distance (positional relationship) between the reference dot and the lower right dot in the captured image. The transformation unit 104 calculates transformation parameters for transforming the distortion of the projected image from the amounts of change. A specific method for estimating the distortion of the projected image will be described. First, the transformation unit 104 calculates the ratio of shift to the upper right, Scale1(x, y), and the ratio of shift to the lower right, Scale2(x, y), using Eqs. (1) and (2).
Scale1(x,y)=(β(x)/α(x),β(y)/α(y)) Eq. (1)
Scale2(x,y)=(γ(x)/α(x),γ(y)/α(y)) Eq. (2)
where α is a shift amount in the projection pattern image and β and γ are shift amounts in the captured image.
As illustrated in
TL(x,y)=(Center(x)−Patch_Size/2,Center(y)−Patch_Size/2) Eq. (3)
BR(x,y)=(Center(x)+Patch_Size/2,Center(y)+Patch_Size/2) Eq. (4)
TR(x,y)=(Center(x)+Patch_Size/2,Center(y)−Patch_Size/2) Eq. (5)
BL(x,y)=(Center(x)−Patch_Size/2,Center(y)+Patch_Size/2) Eq. (6)
where Center(x, y) is the central coordinates of the rectangular area, and Patch_Size is the length of each side.
The clipped rectangular area is distorted due to the influence of the positional relationship between the projection apparatus 120 and the projection plane and the positional relationship between the image capturing apparatus and the projection plane. Therefore, the shift amounts in the rectangular area clipped from the imaging projection area are β and γ, although the original shift amount of the pattern image is α. Thus, transforming the rectangular area clipped so that the shift amount α becomes the shift amounts β and γ forms an image of the shape as illustrated in
TL′(x,y)=(Center(x)−Patch_Size/2×Scale2(x),Center(y)−Patch_Size/2×Scale2(y)) Eq. (7)
BR′(x,y)=(Center(x)+Patch_Size/2×Scale2(x),Center(y)+Patch_Size/2×Scale2(y)) Eq. (8)
TR′(x,y)=(Center(x)+Patch_Size/2×Scale1(x),Center(y)−Patch_Size/2×Scale1(y)) Eq. (9)
BL′(x,y)=(Center(x)−Patch_Size/2×Scale1(x),Center(y)+Patch_Size/2×Scale1(y)) Eq. (10)
The transformation unit 104 estimates a homography based on the rectangular image and the distorted image. The transformation unit 104 generates a rectangular image in which the distortion of the captured image is transformed by executing projective transformation using inverse transformation of the estimated homography.
At S1101, the pattern generation unit 101 generates a reference pattern image. At S1102, the color-based superposition unit 102 generates a pattern image in which the positions of the objects (dots) in the reference pattern image are shifted to the upper right and a pattern image in which the positions of the objects (dots) in the reference pattern image are shifted to the lower right. At S1103, the color-based superposition unit 102 changes the color of the dots in each pattern image. At S1104, the color-based superposition unit 102 superposes the pattern images to generate a projection pattern image.
Thus, in the present embodiment, the distortion of the captured image of an image projected by the projection apparatus is detected using a pattern image in which reference objects, objects obtained by shifting the reference objects to a first position, and objects obtained by shifting the reference objects to a second direction are superposed in different colors.
If the individual objects cannot be distinguished, for example, it is necessary to capture an image obtained by projecting the reference pattern image with the projection apparatus 120 and then capture an image obtained by projecting the shift pattern image in which the objects are shifted with the projection apparatus 120. Shifting the objects in two different directions as in the present embodiment requires a total of three times of projection and image capturing. In the present embodiment, however, superposing the objects in different colors allows distinguishing the reference objects, the objects shifted in the first position, and the objects shifted in the second direction in the captured image obtained by capturing the image projected by the projection apparatus 120. This reduces the number of times of image capturing for alignment.
Furthermore, superposing the pattern images shifted in different directions and the reference pattern image to form a single projection pattern image, as in the present embodiment, needs only one time of projection and image capturing. For this reason, even if misalignment occurs in the positional relationship among the installed devices due to, for example, screen shaking, during the multiple times of projection and image capturing, the amount of shift between the objects can be accurately calculated, allowing high-accuracy transformation of the captured image.
In the first embodiment, the captured image is separated by color without change. In a second embodiment, a technique for assisting detection of objects in the captured image by multiplying the image by a gain on a saturation axis in analyzing an image obtained by capturing a projected image will be described. In the present embodiment, the same components as those of the first embodiment are given the same reference signs and detailed descriptions thereof will be omitted.
In the first embodiment, a projection pattern image in which pattern images with different dot colors are superposed is projected and the projected image is captured. The pixel values of pixels corresponding to the dots in the captured image differ for each color. In general, the values of red and blue pixels are smaller than the value of green pixels. For this reason, the red dots and blue dots may have insufficient contrast in the captured image. Accordingly, in the present embodiment, the difference between the captured image of an image obtained by projecting a projection pattern image and the captured image of an image obtained by projecting a solid black image in which all the pixels are black (hereinafter referred to as “solid black image) is calculated. By further applying a gain to the difference image by color, the contrast among the color dots in the captured image is enhanced.
The processing for calculating the difference between the projection pattern image and the solid black image will be described with reference to
The background subtracting unit 110 generates a difference image by subtracting the pixel value of each pixel in the captured image illustrated in
The color enhancement processing for correcting the color of the captured image using a gain will be described with reference to
First, the color enhancing unit 111 converts the pixel values corresponding to the dots in the difference image to values Y, Cb, and Cr according to ITU-BT.601 as expressed as Eqs. (11) to (13). The conversion standard is however not limited to the above.
Y=0.299×R+0.587×G+0.114×B Eq. (11)
Cb=−0.168736×R−0.331264×G+0.5×B Eq. (12)
Cr=0.5×R−0.418688×G−0.081312×B Eq. (13)
Next, the color enhancing unit 111 calculates the maximum saturation values Mb and Mr of the absolute values of Cb and Cr using Eq. (14) and Eq. (15).
Mb=max(|Cb|) Eq. (14)
Mr=max(|Cr|) Eq. (15)
Next, the color enhancing unit 111 respectively multiplies Cb and Cr by values corresponding to the reciprocal of the maximum saturation values Mb and Mr as a gain, as expressed as Eq. (16) and Eq. (17). The numerator 0.5 of the gains in Eq. (16) and Eq. (17) is the maximum value of the range of the saturation values.
Cb=Cb×0.5/Mb Eq. (16)
Cr=Cr×0.5/Mr Eq. (17)
If outside light, such as sun light or illumination light, is incident on part of the projection plane, the saturation value of the area where the outside light is incident becomes low. If the saturation value of some part is low, the determination of the gain based on the maximum saturation value decreases the gain of the area where the outside light is incident, resulting in an insufficient gain for the area that needs an increased gain. To prevent this insufficient gain, the gain may be applied based on a value that is slightly smaller than the maximum saturation value.
Next, the color enhancing unit 111 converts the values Y, Cb, and Cr to values R, G, and B according to ITU-BT.601 to obtain values R′, G′, and B′ in which the saturation is increased.
R′=Y+1.402×Cr Eq. (8)
G′=Y−0.344136×Cb−0.714136×Cr Eq. (9)
B′=Y+1.772×Cb Eq. (10)
The color-based separation unit 103 separates the captured image in which the contrast is enhanced into patterns by color, and the transformation unit 104 transforms the captured image and outputs the transformed image.
The above processing procedure will be described in outline, with reference to the flowcharts in
Thus, the present embodiment improves the accuracy of correction of the transformation unit by enhancing the contrast by taking the difference between the captured image of the superposed pattern image and the captured image of the solid black image and applying a gain to the color of the captured image.
In the above embodiments, pattern images in which the colors of the shifted objects are changed are superposed to form a single pattern image. In a third embodiment, a technique for changing the shapes of the shifted objects and superposing the pattern images to form a single pattern image will be described.
In the first and second embodiments, patterns in which the colors of the objects are changed are superposed for projection and imaging. The R, G, and B patterns are, however, lower in brightness than a white pattern.
In the present embodiment, the patterns in which the shapes of the objects are changed are superposed so as to be projected and imaged without decreasing in brightness, and the objects are separated by shape to correct the distortion.
A sequence of processing for changing the shape and superposing and separating the patterns will be described with reference to
First, the pattern generation unit 101 generates a pattern containing dots each formed of one pixel. Although the dots are black, and the background is white, the colors may be inverted, that is, the dots may be white, and the background may be black.
Next, the shape-based superposition unit 112 performs processing for shifting the positions of the dots in the pattern and processing for changing the shapes of the dots and superposing the patterns. The shifting process is the same as the process in the first embodiment.
The projection apparatus 120 alternately projects the superposed pattern and a solid black image on a projection plane, the image capturing apparatus 130 captures the projected image, and the background subtracting unit 110 subtracts the solid black image from the pattern image.
Next, the shape-based separation unit 113 separates patterns containing the objects by shape from the subtracted image.
Lastly, the transformation unit 104 corrects the distortion of the captured image using the ratio of the amount of shift performed by the shape-based superposition unit 112 to the shift amount calculated by the shape-based separation unit 113.
The above processing procedure will be described, in outline, with reference to flowcharts in
At S311, the background subtracting unit 110 subtracts the solid black image from the captured pattern image. At S312, the shape-based separation unit 113 separates pattern images by shape from the captured image. At S313, the shape-based separation unit 113 obtains the amount of shift between the objects. At S314, the transformation unit 104 corrects the distortion of the captured image from the amount of shift between the objects.
Thus, the present embodiment provides higher contrast by separating the colors of the objects even if sufficient light is not reflected from the projection plane, preventing a decrease in the accuracy of transformation.
In the first embodiment, pattern images in which the colors of the shifted objects are changed are superposed to form a single pattern image. In the third embodiment, pattern images in which the shapes of the shifted objects are changed are superposed to form a single pattern image. In a fourth embodiment, a technique for changing the colors of the shapes of the shifted objects and superposing the pattern images to form a single pattern image will be described.
In the third embodiment, patterns in which the shapes of the objects are changed are superposed for projection and image capturing. However, shape recognition of the objects requires that the objects have a certain size. For this reason, if the surface of the projection plane has minute irregularities, such as roughness, an error occurs in separation by shape and calculation of the center of gravity, resulting in a decrease in the accuracy of correction performed by the transformation unit.
Accordingly, by changing the color or shape of the objects depending on the color or the state of the surface of the projection plane, optimum objects are projected on the projection plane. A sequence of processes will be described with reference to
Next, a color-based pattern or a shape-based pattern is selected based on the selection result.
The projection apparatus 120 alternately projects the selected pattern and the solid black image on the projection plane. The image capturing apparatus 130 captures the projected image, and the background subtracting unit 110 subtracts the solid black image from the pattern image. Next, the pattern separated from the subtracted pattern image is switched between separation by color or separation by shape.
Lastly, the transformation unit 104 corrects the distortion of the captured image from the difference between the amount of shift performed by the color-based superposition unit 102 or the shape-based superposition unit 112 and the shift amount calculated by the color-based separation unit 103 or the shape-based separation unit 113.
The above processing procedure will be described, in outline, with reference to the flowcharts in
Thus, the present embodiment allows projecting optimum objects on the projection plane by changing the color or shape of the objects according to the color or the state of the projection plane, preventing a decrease in the transformation accuracy.
Embodiment(s) of the present disclosure can also be realized by a computer of a system or apparatus that reads out and executes computer executable instructions (e.g., one or more programs) recorded on a storage medium (which may also be referred to more fully as a ‘non-transitory computer-readable storage medium’) to perform the functions of one or more of the above-described embodiment(s) and/or that includes one or more circuits (e.g., application specific integrated circuit (ASIC)) for performing the functions of one or more of the above-described embodiment(s), and by a method performed by the computer of the system or apparatus by, for example, reading out and executing the computer executable instructions from the storage medium to perform the functions of one or more of the above-described embodiment(s) and/or controlling the one or more circuits to perform the functions of one or more of the above-described embodiment(s). The computer may comprise one or more processors (e.g., central processing unit (CPU), micro processing unit (MPU)) and may include a network of separate computers or separate processors to read out and execute the computer executable instructions. The computer executable instructions may be provided to the computer, for example, from a network or the storage medium. The storage medium may include, for example, one or more of a hard disk, a random-access memory (RAM), a read only memory (ROM), a storage of distributed computing systems, an optical disk (such as a compact disc (CD), digital versatile disc (DVD), or Blu-ray Disc (BD)™), a flash memory device, a memory card, and the like.
While the present disclosure has been described with reference to exemplary embodiments, the scope of the following claims are to be accorded the broadest interpretation so as to encompass all such modifications and equivalent structures and functions.
This application claims the benefit of Japanese Patent Application No. 2018-118123, filed Jun. 21, 2018, which is hereby incorporated by reference herein in its entirety.
Number | Date | Country | Kind |
---|---|---|---|
JP2018-118123 | Jun 2018 | JP | national |
Number | Name | Date | Kind |
---|---|---|---|
7278746 | Matthys | Oct 2007 | B2 |
7364310 | Yamazaki | Apr 2008 | B2 |
7936361 | Aufranc | May 2011 | B2 |
8885964 | Tamura | Nov 2014 | B2 |
8944610 | Nakata | Feb 2015 | B2 |
8976080 | Richards | Mar 2015 | B2 |
9791933 | Igarashi | Oct 2017 | B2 |
10218949 | Naganuma | Feb 2019 | B2 |
20030227599 | Weissman | Dec 2003 | A1 |
20080062164 | Bassi | Mar 2008 | A1 |
20080174704 | Tan | Jul 2008 | A1 |
20100253861 | Tomaru | Oct 2010 | A1 |
20110007172 | Miceli | Jan 2011 | A1 |
20120062855 | Todoroki | Mar 2012 | A1 |
20140071409 | Nakashin | Mar 2014 | A1 |
20140139751 | Narikawa | May 2014 | A1 |
20150156467 | Ouchi | Jun 2015 | A1 |
20150302560 | Sumiyoshi | Oct 2015 | A1 |
20160182873 | Sumiyoshi | Jun 2016 | A1 |
20170180689 | Morrison | Jun 2017 | A1 |
Number | Date | Country | |
---|---|---|---|
20190394435 A1 | Dec 2019 | US |