The present invention generally relates to an image capturing apparatus, or more particularly, to an image capturing apparatus and a method for obtaining distance between different points on an imaged object.
In e-commerce, commodities are often photographed and such photos or images are then posted on websites. Customers often expect to have real sizes of the commodities displayed with such images. Currently, in order to do this, retailers in e-commerce have to do extra effort to measure the commodity size themselves and add another paragraph in the commodity description for the sizes. Retailers can also edit the images of the commodities and drawing the commodities sizes on the images after measuring the commodities sizes. It seems rather inconvenient for the retailers.
There can be other scenarios. For example, when a consumer is buying some commodities such as furniture, real estate, etc., some photos need be taken to provide more references for further considerations. Such consumers always want to know real sizes of these commodities as well. When a retailer surveys a commercial site, it is likely that the retailer would also take some pictures and gather information about site sizes of potential candidates at the same time. When a policeman takes pictures at crime scenes, he may need to obtain distances between some particular points, or sizes of some material evidences.
Under those circumstances, it is very inconvenient to measure the sizes manually. Conventionally, the size of an object to be measured can be extracted by putting a scale bar on the displaying system in an image capturing apparatus such as digital camera, digital camcorder. In this way, real size of the object is calculated using such scale bar. Nevertheless, this method requires that distances from each of two respective points for distance measurement to the photographer are the same; otherwise the distance between any two points can not be measured precisely. Furthermore, the scale bar on the displaying system might not be accurate, and it often requires users to use their naked eyes to determine the measured length relative to the scale bar, which leads to unsatisfied results such as inaccurate data or inconveniences. In addition, there is another conventional method by reconstructing a 3-dimensional model of an object by taking pictures of an object from different angles using two professional image capturing apparatus, or by taking two pictures respectively from two different angles by moving a single professional image capturing apparatus. Although such image capturing apparatus does not provide a function of measuring the object size directly, the method may obtain the object size by image capturing; however, such professional image capturing apparatus are too expensive to be affordable for normal end users.
In view of the above, when using a normal image capturing device to take pictures, there is a great need to measure size of an imaged object simultaneously and store the size information and the picture of the object together in datum of the commodity.
According to one aspect of embodiment of the present invention, a method of obtaining distances between different points on an imaged object during image capturing of the object is disclosed. The method comprises: determining a pair of specified points on the object for distance measurement; focusing on each specified point respectively, and obtaining a focal length for obtaining a clear image of the specified point on the imaging device of the image capturing apparatus, a distance between the clear image point of the specified point and a longitudinal axis of the convex lens, and a distance between the convex lens and the imaging device of the image capturing apparatus during said focusing; and calculating a distance between the specified points in the pair on the object.
According to anther aspect of embodiment of the present invention, an image capturing apparatus is disclosed. The apparatus comprises: a basic device configured to take picture, the basic device comprising a lens unit including a lens set represented by a convex lens, a camera body including an imaging device and a preview display; a receiving device configured to determine a pair of specified points on an imaged object for distance measurement; a focusing control device configured to focus on each specified point in the pair respectively, wherein the focusing control device is further configured to obtain a focal length for obtaining a clear image of the specified point on the imaging device, a distance between a clear image point of the specified point and a longitudinal axis of the convex lens, and a distance between the convex lens and the imaging device during said focusing; and a calculating device configured to calculate a distance between the specified points in the pair on the object.
The aforementioned and other objects, features and advantages of the embodiments of the present invention will become more apparent by further detailed descriptions of embodiments with reference to accompanying drawings, in which like reference numbers usually represent like parts in the embodiments according to the present invention.
The preferred embodiments according to the embodiments of the present invention will be further described in details with reference to the drawings illustrating the preferred embodiments. However, the technical solution of the present invention can be embodied in various forms, and it should not be limited by the embodiments set forth herein. On contrary, those embodiments are provided to make the present invention more thorough and complete and fully convey scope of the present invention to those skilled in the art.
Imaging Theory of an Image Capturing Apparatus:
The image capturing apparatus herein refers to various image capturing apparatus which images objects in accordance with an imaging theory of a convex lens, including cameras, image pickup device with a focusing function, video recording apparatus or the like.
The imaging theory of an image capturing apparatus is actually an imaging theory of a convex lens.
1/f=1/u+1/v (1)
Theoretical basis for obtaining a distance between two points on an imaged object during image capturing by the image capturing apparatus will be described as below.
Currently, most of the image capturing apparatuses have auto-focusing function, in other words, they can automatically focus on a certain point of the image. Auto-focusing may select a foci band upon imaging and an image pickup device with focusing function can adjust the foci band). Since the foci band of the image capturing apparatus and the focal length of the convex lens have a one-to-one correspondence, the focal length of the convex lens can be determined by obtaining the foci band during image capturing by the image capturing apparatus.
1/D(P4,F1)=1/D(P1,P4)+1/D(P4,P5) (2)
D(P1,P4)=1/[1/D(P4,F1)−1/D(P4,P5)] (3)
According to principle of similar triangles, the distance D(A, P1) between the point A and the longitudinal axis of the convex lens can be calculated as following:
D(A,P1)/D(A′,P5)=D(P1,P4)/D(P4,P5) (4)
D(A,P1)=D(P1,P4)*D(A′,P5)/D(P4,P5) (5)
1/D(P3,F2)=1/D(P2,P3)+1/D(P3,P5) (6)
D(P2,P3)=1/[1/D(P3,F2)−1/D(P3,P5)] (7)
D(B,P2)/D(B′,P5)=D(P2,P3)/D(P3,P5) (8)
D(B,P2)=D(P2,P3)*D(B′,P5)/D(P3,P5) (9)
A distance between the projections points of the point A and B on the longitudinal axis of the convex lens, namely a distance D (P1, P2) between P1 and P2, can also be obtained as following:
D(P1,P2)=[D(P1,P4)+D(P4,P5)]−[D(P2,P3)+D(P3,P5)] (10)
The length D(A, B) of the object AB can then be obtained as following:
D(A,B)2=D(P1,P2)2+[D(A,P1)+D(B,P2)]2 (11)
In accordance of
At step S402, a pair of the specified points on the imaged object for distance measurement is determined. If only two specified points are received, it is by default to measure a distance between the two specified points. If there are more than two specified points, it is necessary to specify which pair of points for distance measurement. The method to specify the pair of points for distance measurement is similar to the way for specifying the points. The user can directly draw a line between the two points on the touch screen to specify the pair of points for distance measurement when selecting points on the touch screen of the viewfinder. When selecting the points by a mouse, the user can link the two points using the mouse on the screen of the viewfinder in order to specify the pair of points for distance measurement. When selecting points by inputting coordinates on the screen of the viewfinder, the user can input a pair of coordinates of two respective points to specify the pair of points for distance measurement. In one embodiment, step S401 for receiving the specified points and step S402 for determining a pair of specified points for distance measurement can be completed in a single reception process. For example, a user may directly draw a line segment on a touch screen of the viewfinder, so that both ends of line segment can be identified as the specified points, and the physical distance corresponding to the line segment can be identified as the distance between the specified points on the imaged object.
At step S403, the image capturing apparatus focus on each specified point respectively during each image capturing. During focusing on each specified point, a focal length for obtaining a clear image of the specified point on the imaging device of the image capturing apparatus, a distance between the clear image point of the specified point and the longitudinal axis of the convex lens of the image capturing apparatus, and a distance between the convex lens of the image capturing apparatus and the imaging device of the image capturing apparatus are obtained. The process of focusing on each specified point by the image capturing apparatus is carried out during a formal image capturing process, i.e., after a shot button is pressed by the user. The user may press the button once to trigger a sequential auto-focusing on each specified point controlled by a focusing control device within the image capturing apparatus. Therefore, such image capturing process might last longer than a normal image capturing process after the shot button is pressed. In another embodiment, a particular measuring mode can be set for the image capturing apparatus. In such mode, it is allowed to press the shot button for a plurality of times. Each time the shot button is pressed, the image capturing apparatus focus on one of the specified points. Alternatively, the correspondence between number of times for the pressing the shot button and the process of focusing on the specified points can be specified. The hands of the user holding the image capturing apparatus should not move under any circumstances, in order to avoid a position change of the image capturing apparatus, which might in turn changes the imaging position. Preferably, a tripod can be used to keep a constant position of the image capturing apparatus in order to keep the imaging position stable. The image capturing apparatus typically comprises a plurality of sets of lenses, yet they can be optically converted to a single convex lens eventually. With parameters of focusing determined, relative positions of the respective lenses within the image capturing apparatus are set, which determines the focal length of the convex lens. Currently many types of image capturing apparatus are capable of recording the focal length automatically. In addition, if the number of the specified points is more than two, for example, in case that there are three specified points A, B and C, and the distances between AB and BC need to be measured, it is only necessary to focus on point B once instead of twice, although point B is specified twice when determining which two points for distance measurement.
There are various ways to obtain the distance between the clear image point on the imaging device of the image capturing apparatus and the longitudinal axis of the convex lens of the image capturing apparatus.
H=L*d/D (12)
In a further embodiment of obtaining the distance between the clear image point on the imaging device of the image capturing apparatus and the longitudinal axis of the convex lens of the image capturing apparatus, the image device, such as CMOS/CCD is an array of sensing points with each sensing point assuming a square shape. The image capturing apparatus can record side length of each sensing points within the array. A processor of the image capturing apparatus can obtain the above distance by multiplying number of the sensing points between the clear image point of the specified point on the imaging device and the center of the imaging device with the side length of the square representing a sensing point.
The distance between the convex lens and the imaging device of the image capturing apparatus, i.e. D (P4, P5) shown in
Referring back to
In a preferred embodiment, if the image capturing apparatus is a digital device, the method can further comprise a step S405, in which the specified points and the distances between the specified points on the object are stored in a file associated with the picture. Conventionally only pixel information is included in the stored file of a picture taken by the image capturing apparatus. In comparison, in the embodiment of the present invention, the specified points and the distances between the specified points on the object can also be saved together with the pixel information in the picture file. For example, the specified points and the distance between the specified points on the object can be stored in a file as shown in Table 1, and then link the file as shown in Table 1 to the original picture file containing pixel information. One method for establishing the link of two files is by using the same file name but different extension name. Other methods are also possible, for example, by creating a dedicated link table and looking up the link table upon displaying the information. If an agreement could be reached across industry, the original pixel file can also be expanded in order to embed the information as shown in Table 1 directly into the pixel file via a standard interface. Herein, Table 1 is only one exemplary embodiment of recording the specified points and the distances between the specified points on the object. Those skilled in the art can use various recording methods, such as using arrays, linked list or the like.
In another preferred embodiment, at step S406, a request for displaying the picture is received so that the picture, the specified points recorded in the picture, and the distances between the specified points on the object are displayed. The specified points recorded in the picture, and the distance between the specified points on the object, that is, any two specified points and the line segment between these two points can be assigned a specified color, such as red or black, with the length value of the line segment displayed at the proximity of the line segment. Sometimes, the color of the picture and the specified color are relatively close, which might lead to a poor display quality. In this case, it is prefer to identify primary colors of a portion of picture on which the two specified points and the line segment therebetween are shown first, and then assign a color with relatively high contrast with respect to the primary colors in chromatics to the specified color, in order to make the displayed information more clear.
The embodiment of the present invention may comprise an image capturing apparatus. As shown in
In
In an embodiment, the focusing control device obtains the distance between the clear image point on the imaging device of the image capturing apparatus and the longitudinal axis of the convex lens of the image capturing apparatus by one of the following ways: (1) obtaining a distance between the displayed point on the preview display of the image capturing apparatus and the center of the preview display, and multiplying the distance with length ratio of the image on the image device to the image on the preview display for the same object; (2) obtaining number of sensing points between the clear image point of the specified point on the imaging device of the image capturing apparatus and the center of the imaging device, and multiplying the number with side length of a square representing the sensing point of the imaging device. In another embodiment, the distance between the convex lens of the image capturing apparatus and the imaging device of the image capturing apparatus can be obtained by summing an initial distance from a rear position of the convex lens representing the lens set of the lens unit to back of the lens unit, a distance from the back of the lens unit to the imaging device, and a displacement distance of the lens set for obtaining a clear image on an object plane during auto-focusing.
In an embodiment, the image capturing apparatus further comprises a storage device (not shown in
In another embodiment, the image capturing apparatus further comprises a display device (not shown in
In an embodiment, the receiving device receives at least two specified points of the object displayed on the preview display of the image capturing apparatus by one of following ways: (1) receiving the specified points from a touch screen of the preview display of the image capturing apparatus; (2) receiving the specified points from mouse inputs provided on the screen of the preview display of the image capturing apparatus; (3) receiving the specified points from the user interface provided on the screen of the preview display of the image capturing apparatus.
In another embodiment, the receiving device determines a pair of specified points on the object for distance measurement by one of the following ways: (1) drawing a line between the two specified points on a touch screen of the preview display of the image capturing apparatus; (2) linking the two specified points on a screen of the preview display of the image capturing apparatus using a mouse; (3) inputting coordinates of the specified points on a screen of the preview display of the image capturing apparatus.
While the exemplary embodiments in accordance to the present invention have been described with reference to the drawings, it should be appreciated that the present invention should not be limited to the exact embodiments. Those skilled in the art can modify the embodiments in various modifications to the embodiments without departing the scope and the spirit of the embodiment of the present invention. All such variations and modifications are intended to fall within the scope of the present invention defined in the attached claims.
Number | Date | Country | Kind |
---|---|---|---|
201110110185.8 | Apr 2011 | CN | national |