The present invention relates generally to methods and apparatus for generating a perspective corrected view of a portion of a wide angle image acquired, for example, by utilizing a fish-eye lens. More particularly, the invention provides methods and apparatus for linking the wide angle image and a perspective-corrected view of a portion of that image.
Imaging systems that utilize fish-eye lenses are known in the art. A fish-eye lens captures an image corresponding to a hemispherical, or a partially hemispherical, field of view. That is, fish-eye lenses allow imaging much-enhanced angular views relative to views obtainable by ordinary camera lenses. An image obtained by a fish-eye lens, however, contains radial distortions that need to be rectified to allow convenient viewing.
Methods and devices for selecting and undistorting a portion of a fish-eye image are also known. Such conventional methods and devices, however, suffer from a number of limitations. For example, although such conventional devices present an undistorted view of a portion of a fish-eye image, they do not allow a viewer to observe simultaneously the relation of the undistorted view to the entire image using a single imaging device. In other words, such conventional devices do not allow a viewer to observe simultaneously an undistorted view of a portion of a fish-eye image, and the remainder of that image, albeit with distortions introduced by the fish-eye lens present.
Moreover, conventional methods for undistorting a portion of a fish-eye image have a number of shortcomings. Such conventional methods can only be utilized for removing distortions from image portions corresponding to a small field of view. For example, these methods break down completely when applied to image portions corresponding to fields of view of tens of degrees, resulting in smeared images. Such limited viewing angles provided by conventional methods diminish considerably the benefits of panoramic observation of a scene.
Accordingly, there is a need for methods and apparatus for acquiring and viewing a fish-eye image that provide canonical undistortion capability, and afford enhanced flexibility for viewing portions of the fish-eye image throughout the full 180-degree field of view while compensating for distortions introduced by the fish-eye lens.
Further, there is a need for methods and apparatus which allow readily selecting a portion of a fish-eye image, generating a perspective-corrected view of the selected portion at a desired magnification without losing the benefits of panoramic aspects of viewing a scene provided by the fish-eye lens.
The present invention provides, in one aspect, a device for generating a perspective corrected view of at least a portion of a wide-angle image. More particularly, the present invention provides a device that utilizes a fish-eye lens coupled to an imager, such as, a CCD or CMOS array, a thermal imaging array or any other suitable optical imaging device, to obtain an image of a scene, for example, an image of a scene corresponding to 180-degree field of view, and displays the acquired image on a primary display. The device further allows selecting a portion of the displayed image for further viewing, at a desired magnification and with distortions introduced by the fish-eye lens substantially removed, on the primary display, or alternatively, on a secondary display.
In another aspect, a device of the invention includes an image-capturing device that generates an image, for example, in the form of a two-dimensional digital map of luminance, of a field of view. The image-capturing device can include a fish-eye lens that collects optical photons emanating from the field of view, and an imager that converts the collected optical photons to electrical signals representing an image of the field of view. This image is herein referred to for brevity as “fish-eye image”. The term “fish-eye image”, as used herein, refers to a hemispherical, partially hemispherical, or more broadly, to a wide-angle image of a field of view. The device of the invention can further include a processor that communicates with the image-capturing device to access the acquired image for processing, such as, removal of distortions introduced by the fish-eye lens.
In a related aspect, the processor includes a first display module that displays the fish-eye image, and further includes a second display module that displays a perspective corrected view of a portion of the image. Moreover, the processor can include a correlation module that effects the display of a graphical object on the displayed wide angle image to identify the selected portion of the image displayed in the perspective corrected view. The processor can effect the display of the fish-eye image on any suitable display, such as, in a window on a computer screen or on a television monitor. The graphical object can be, for example, in the form of a window or a magnifier glass or any other suitable visual icon, that is overlayed on, or otherwise linked to, a portion of the displayed fish-eye image that corresponds to the perspective-corrected view.
In another aspect, the processor effects the display of the fish-eye image and the graphical object associated therewith on a primary display, and presents the perspective-corrected view of a portion of the fish-eye image designated by the graphical object on the primary display, or alternatively, on a separate secondary display.
In further aspects, the processor provides a perspective-corrected view of a portion of a fish-eye image by transforming that portion according to a selected magnification and an angle for viewing a section of a hemisphere corresponding to that image portion from a vantage point offset from the center of the hemisphere by a defined distance.
For example, the processor can effect the correction of a portion of a fish-eye image by mapping a point (u,v) on an undistorted image plane representing a perspective-corrected portion of a distorted image to a point (x,y) on an image plane representing the distorted image by utilizing the following mathematical formulas according to the teachings of the invention:
In related aspects, a device of the invention as described above, further includes a user interface module coupled to the processor that allows associating the graphical object with a portion of the displayed fish-eye image, for example, by moving the graphical object to overlie that portion, in order to select that portion of the fish-eye image to be corrected for perspective distortions and to be presented, at a selected magnification, on the same or a separate display for further viewing.
In other aspects, the invention allows selecting a portion of a fish-eye image to be corrected for perspective distortions based on a pre-defined set of rules. For example, in a device of the invention as described above, the processor can be programmed, or can have access to instructions stored in a buffer, to automatically select a portion of an acquired fish-eye image for perspective correction and further viewing. Any instructions suitable for a particular application can be utilized in a device of the invention. For example, the processor may select a rectangular or a circular portion of the fish-eye image centered at a defined region of interest for perspective correction and presentation. Alternatively, the processor can periodically choose a different portion of the fish-eye image, e.g., randomly or based on a pre-defined algorithm, for viewing.
In another aspect, the processor effects the image-capturing device to acquire periodically a fish-eye image of a scene, and compares two or more images, e.g., two successive images, to detect motion, if any, of one or more objects in the field of view. The processor further effects the display of perspective-corrected views of one or more portions of the fish-eye image containing the moving objects, for example, on a secondary display area.
The following embodiments, described with reference to the drawings identified below, provide further understanding of the invention.
The present invention provides systems and methods for obtaining a fish-eye image, and for generating and displaying a perspective-corrected view of a portion of the fish-eye image at a selected magnification while preserving information regarding the context of the magnified portion within the entire image. As discussed in more detail below, a system of the invention advantageously allows a user to view simultaneously a fish-eye image, and a portion of the image, corresponding to any desired section of the fish-eye image, that has been corrected for distortions introduced by the fish-eye lens.
With reference to
The illustrative camera 12 includes a fish-eye lens 16, and an image-capturing device 18. A fish-eye lens, as used herein, refers to a lens that linearly maps light rays incident thereon at azimuth angles ranging from 0 to 90 degrees to points on an image plane whose distances from an origin on the image plane span a range of 0 to 90 degrees for all polar angles. The image-capturing device 18 includes a mega-pixel imager 20, such as a CCD or CMOS array or other imagers known in the art and suitable for use in the present invention, and an image buffer 22. The illustrative camera 12 further includes a communication interface 24 for transmitting electrical signals signifying an image from the image-capturing device 18 to the control/processing unit 14. The communication interface 24 can utilize any suitable communication protocol, such as, Ethernet, wireless, or optical protocols, to transmit data to and receive control signal from a corresponding communication interface 26 of the control/processing unit 14 via a communication link 28.
In some embodiments of the invention, the image-capturing device 18 and the image buffer 22 are implemented as an integrated circuit device. Such devices can be obtained, for example, from Kodak Corporation of Rochester, N.Y., U.S.A. under trade designation KAC-1310 CMOS image sensor.
With continued reference to
The control/processing unit 14 further includes a user-interface 30, such as, a keyboard, a mouse, coupled to a processor 32, which is in turn in communication with a display 34. A user, e.g., an operator of the system 10, can utilize the user interface 30 to communicate with the processor 32 to request acquisition of an image by the camera 12 and its display on the display 34 in a manner described in more detail below. In addition, the exemplary control/processor unit 14 optionally includes a buffer 38 for storage of image date received from the camera 12.
The processor 32 responds to a request received from the user interface 14 by forwarding one or more commands to the camera 12, via the exemplary communication interfaces 26 and 24 and the communication link 28, for acquisition of an image. The request from the user interface 14 can include values of one or more parameters for acquiring an image, such as, the shutter speed and/or frame rate of the imager 20.
The camera 12 responds to the commands received from the processor 32 by acquiring an image, as described above, or retrieving a previously obtained image from the image buffer 22, and transmitting the image to the processor 32. The processor 32 optionally stores the received image in the buffer 38. Further, it effects the display of the image on the display 34. The term “display”, as used herein, can refer to a device, such as, a computer monitor or a television monitor, that allows visual presentation of data, e.g., images, and it can also refer to at least a portion of a screen provided by such a device for viewing images. For example, a display can refer a computer monitor or a window provided on a computer screen.
In this embodiment, the display 34 is a graphical object, such as, a window provided on a computer screen, which presents the fish-eye image in a circular area 34a, although other forms of presentation of the image can also be utilized. In addition, the display 34 presents a graphical object 40, for example, in the form of a window or a magnifier, overlayed on a portion of the image presented in the circular area 34a. A user can utilize the user interface 30 to move the graphical object 40 to different portions of the image displayed in the area 34a in order to select a portion of the image to be corrected for distortions introduced by the fish-eye lens and to be presented for viewing in the display area confined by the graphical object 40.
More particularly, the user can select a portion of the area 34a by overlaying the graphical object 40 over that portion, and by doing so, can request perspective correction of that portion and its display within the display area circumscribed by the graphical object 40. In addition, the system of the invention permits the user to select a magnification for the display of the selected portion of the image. The selection of a desired magnification can be accomplished, for example, by rotating a knob associated with the user interface, e.g., a thumb wheel located on a computer mouse. For example, the rotation of the knob in one direction can effect a progressive increase of the magnification while rotation in the opposite direction can cause a decrease of the magnification. Alternatively, the user interface can be utilized to effect the display of a dialogue box on the display 34, in which one or more available values of magnification are listed. The user can select one of the values for viewing a perspective-corrected portion of the fish-eye image. Those skilled in the art will readily appreciate that other techniques can be utilized in a system of the invention to allow a user select a desired magnification.
In another embodiment shown in
In another embodiment, the graphical object 40 can be in the form a cross-hair that can be selected, for example, by clicking on it, to effect the display of a perspective-corrected view of a pre-defined portion of the fish-eye image, for example, a circular portion with a pre-defined radius surrounding the cross-hair. This perspective-corrected view can be displayed, for example, on a secondary display, such as, the above display 36.
The size of the graphical object 40 can be optionally modified, via the user interface 30, to encompass larger or smaller portions of the display area 34a associated with the fish-eye image. For example, the graphical object 40 can be enlarged to encompass the entire fish-eye image.
The control/processor unit 14 can be implemented, for example, on various computer platforms, for example, platforms having windowing environments, such as, Microsoft Windows, Unix X Windows, and any other suitable environment.
Referring again to
In particular,
The distance of the observation point P from a center 44 of the image plane 40 is defined by a parameter d. Moving the observation point P away from the image plane 40, that is, increasing the magnitude of d, results in increasing the magnification of the undistorted image on the image plane 40. Conversely, moving the point P towards the image plane 40 results in a decrease in the magnification of the undistorted image. Given a fixed size uv-plane image (e.g. 640×480 pixels) increasing d decreases the angular view of the surface of the sphere subtended by the uv-plane, effectively zooming in on the point centered at the DOV. Further, increasing the distance of the observation point P from the center of the hemisphere, i.e., the origin of the XYZ coordinate system, results in a decrease in the level of un-distortion. Setting D to zero results in the conventional fisheye undistortion equations, as it places the center of view used in the perspective projections in the same place as the fisheye lens. Unfortunately, utilizing such a conventional approach would require an infinitely large uv-plane to map the entire fisheye image, resulting in an enormous loss of resolution relative to that of the original fisheye image when attempting to undistort even modest portions of the fisheye image. Setting D to infinity results in a parallel projection from the sphere to the uv-plane, easily capturing the whole fisheye image with a small uv-plane, but leaving the image highly distorted. Utilizing values between 0 and infinity, as taught by the present invention, provides intermediate results.
The mathematical formulations in accord with the teachings of the invention, which follow, provide a mapping between a point (u,v) on the image plane onto a point (xv,yv,zv) on the hemisphere. The point (xv,yv,zv) corresponds to the intersection of a vector V, which originates at the center of view, i.e., point P, and passes through the point (u,v), with the hemisphere.
y=−D sin(β)sin(δ)
ti z=−Dcos(β)
where (δ, β, D) represents the spherical coordinates of the point P. These Cartesian coordinates can be also be represented by the following vector notation:
[−D sin(β) cos(δ), −D sin(δ) sin(6), βDcos(β)].
Because of the presence of rotational symmetry about the z-axis, without any loss of generality, the remainder of the mathematical derivation can be readily described by initially rotating the center point P and its associated image plane 40 and the ancillary vectors DOV and V about the z-axis by “−δ” degrees such that point P lies on the x-axis and has the following coordinates:
[0, −D sin(β), −D cos(β)].
The above rotation causes the u-axis to align with the x-axis. Further, the rotated v-axis has a component along the y-axis and another component along the z-axis.
The coordinates of the vector V (V[xv,yv,zv]) can be calculated by reference to
V=P+tS Eq. (1).
S is define as:
S=T+u+v Eq. (2).
Where T is a directional vector of length d pointing in the direction of DOV. Thus,
T=[0, d sin(β), d cos(β)], Eq. (3)
and
S=T+u+v Eq. (4a)
S=[u, d sin(β)+v cos(β), d cos(β)−v sin(β)] Eq. (4b)
By utilizing Eq(1), Eq(2), Eq. (3), Eq. (4a) and Eq. (4b), the coordinates of V[xv,yv,zv] are obtained as follows:
V=[u t, −D sin(β)+d t sin(β)+vt cos(β), −D cos(β)+d t cos(β)−v tsin(β)] Eq. (5).
Accordingly, the [xv,yv,zv] coordinates of the vector V are given as follows:
xv=u t Eq. (6a)
yv=−D sin(β)+d t sin(β)+vt cos(β) Eq. (6b)
zv=−D cos(β)+d t cos(β)−v t sin(β) Eq. (6c)
The coordinate [xv,yv,zv] at the intersection of the vector V with the hemisphere satisfies the following relation:
xv2+yv2+zv2=1, Eq. (7).
By substituting xv, yv, and zv from Eqs. (6a)-6(c) into Eq. (7), the following relation is obtained:
[u t]2+[−D sin(β)+d t sin(β)+vt cos(β)]2+[−D cos(β)+d t cos(β)−v tsin(β)]2=1 Eq. (8).
Simple algebraic manipulations can be employed to obtain the following relation for the scalar t from the above Eq. (8):
t=[−B+/−sqrt(B−4AC)]]/(2A) Eq. (9).
where A=u2+v2+d2; B=−2 D d and C=D2−1.
The larger value of t is chosen because the other value corresponds to the intersection of the vector V with the portion of the sphere below the x-y plane, which is not captured by the fisheye image. Hence, the scalar parameter t is given by the following relation:
t=[−B+sqrt(B−4AC)]]/(2A) Eq. (10).
Accordingly, the above equation (10), in combination with Equations 6(a)-6(c), provide the coordinates of the point of intersection of the vector V, herein referred to as [xv, yv, zv], with the hemisphere as follows:
xv=u [−B+sqrt(B−4AC)]]/(2A)
yv=−D sin(β)+d sin(β)[−B+sqrt(B−4AC)]]/(2A)+v cos(bβ)[−B+sqrt(B−4AC)]]/(2A)
zv=−D cos(β)+d cos(β)[−B+sqrt(B−4AC)]]/(2A)−v sin(β)[−B+sqrt(B−4AC)]]/(2A)
The zenith angle β0 and azimuth angle δ0 of this point can be obtained as follows
β0=arctan(zv, 1) Eq. (11a).
δ0=arctan(yv, xv) Eq. (11b).
To undo a rotation by an angle “−δ” introduced above, a rotation angle δ can be added to δ0 to obtain the zenith and azimuth angles of the intersection of the vector V with the hemisphere prior to introducing the rotation, as follows:
β0=arctan(zv, 1) Eq. (12a).
δ0=arctan(yv, xv)+δ Eq. (12b).
The above equations (12a) and (12b) provide the zenith angle (δ0) and the azimuth angle (δ0) of a ray of light striking the point (u,v) on the uv-plane given a direction of view represented by the zenith angle (β) and the azimuth angle (δ).
The above angles can be utilized to calculate the location of the point (x,y) on the distorted fish-eye image plane by employing the properties of a fish-eye lens. In particular, with reference to
r=R(βP0/(PI/2)) Eq. (13),
where R is the radius of the distorted fish-eye image. The second property of the ideal fisheye lens is rotational symmetry, which signifies that r and δ are independent from one another. Accordingly, a conversion from polar to Cartesian coordinates provides the coordinate (x,y) in the distorted fish-eye image plane as follows:
x=r cos(δ0)=R(β0/(PI/2))cos(δ0) Eq. (14a)
y=r sin(δ0)=R(β0/(PI/2))sin(δ0) Eq. (14b)
With reference to
t=[D d+sqrt(D2d2−(u2+v2+d2)(D2−1))]/(u2+v2+d2) Eq. (15)
β0=arctan(−D cos(β)+d t cos(β)−v t sin(β), 1) Eq. (16)
δ0=arctan(−D sin(β)+d t sin(β)+vt cos(β), u t)+δ Eq. (17)
x=R(β0/(PI/2))cos(δ0) Eq. (18)
y=R(β0/(PI/2))sin(δ0) Eq. (19)
In many embodiments of the invention, including the exemplary embodiment described above, the distorted fish-eye image is obtained, via the imager 20 (
As shown in
Pi=CCDi[floor(y)][floor(x)](1−(y−floor(y)))(1−(x−floor(x)))+CCDi[floor(y)][floor(x)+1](1−(y−floor(y)))(x−floor(x))+CCDi[floor(y)+1][floor(x)](y−floor(y))(1−(x-floor(x)))+CCDi[floor(y)+1][floor(x)+1] (y−floor(y))(x−floor(x)) Eq. (20)
where floor(y) and floor(x) are functions that round-off values of x and y. That is (floor(x), floor(y)) corresponds to the coordinates of one of the four closest pixels, e.g., pixel 60, and (floor(y), floor(x)+1), (floor(y)+1, floor(x)), and (floor(y)+1, floor(x)+1) correspond to the coordinates of the other three pixels, e.g., pixels 54, 56, and 58. The function floor(x) can be defined as the greatest integer that is less than or equal to x, e.g. floor(3.14159)=3, and floor (−3.14159)=−4. The subscript (i) in Pi indicates that the above equation (20) can be applied separately to red, green, and blue pixels for a color image.
Further, CCD[IMAGE_HEIGHT][IMAGE_WIDTH] is an array that provides luminance values of the distorted image pixels. Thus, the above Equation (20) provides a weighted average of the luminance values of the pixels surrounding the point (x,y), where the weight of each pixel relates an area of a portion of a box A surrounding the point (x,y) which lies within an area spanned by that pixel.
A method of the invention for transforming at least a portion of a distorted image of a scene obtained by a fish-eye lens to compensate for distortions introduced by the lens provides a number of advantages over conventional transformations. In particular, one such conventional transformation transforms the image in accordance with a defined magnification and angles for viewing a portion of hemispherical field of view from the center of the hemisphere. An undistorted image obtained by utilizing such a conventional method exhibits progressively less resolution at points farther away from the center of the image. In fact, application of such conventional methods for undistorting even modest portions of a fish-eye image results in severe loss of resolution at points of the corrected image corresponding to edges of the undistorted image. In other words, such a conventional undistorted image is increasingly stretched out as the viewing point moves towards the edges of a fish-eye image.
To further illustrate the advantages of the undistortion method of the invention,
As discussed above, the present invention presents a perspective-corrected view of a portion of an image obtained by a fish-eye lens while providing information regarding the context of the corrected portion relative to the entire image. For example, a system of the invention can be utilized to view in real-time an entire fish-eye image, and one or more portions thereof that have been corrected for perspective distortions introduced by the fish-eye lens.
These teachings of the invention can be implemented in a variety of different embodiments, such as the exemplary embodiments described above. To further illustrate the wide applicability of the invention and the wide range of choices for implementation thereof,
A buffer 72 stores the array of pixels representing the image, and a user interface 76, coupled to a processor 74, allows a user to request acquisition of an image and/or viewing of a portion of a previously acquired image at a defined magnification and with correction for distortions. For example, the processor 74 responds to a request for acquisition of an image of a scene by effecting the image acquisition module 70 to obtain an image of the scene, and further effects the storage of this image, which corresponds to a distorted image of the scene, in the buffer 72.
With continued reference to
The user can move the graphical object 84, via commands entered through the user interface 76, to various portions of the underlying image to select a portion of the image for viewing. In one embodiment, once the graphical object 84 is placed over a portion of the fish-eye image, the user transmits a command via the user interface 76, e.g., via a click of a mouse, to select that portion. In another embodiment, the placement of the graphical object 84 over a portion of the fish-eye image automatically effects the selection of that portion for further viewing. Upon selection of a portion of the fish-eye image for further viewing, the display processor 78 utilizes the mathematical methods of the invention described above to correct the selected portion for distortions introduced by the fish-eye lens. In addition, the display processor 78 effects the display of the perspective-corrected portion on a secondary display 82. Similar to the previous embodiment, a user can modify the magnification of the image portion presented on the secondary display 82 by providing commands via the user interface 76.
Accordingly, a user can view at a glance not only a perspective-corrected portion of interest in the distorted image but also the relationship of this portion relative to the remainder of the distorted image. In other words, the exemplary system 68, similar to the previous embodiment, provides a perspective corrected view of at least a portion of the image obtained by a fish-eye lens while preserving the information regarding the context of that portion relative to the entire image.
As discussed above, a variety of display devices can be utilized in a system of the invention. Such display devices can include, but are not limited to, computer monitors, liquid crystal displays (LCD), and television monitors. By way of example,
In the embodiments described above, a user selects a portion of a displayed fish-eye image, e.g., via a user interface, for viewing at a selected magnification and with corrections for distortions introduced by the fish-eye lens. It should be understood that the selection of a portion of a fish-eye image for further viewing in a device of the invention can also be accomplished automatically, for example, based on a pre-programmed set of rules or based on detecting motion of an object in the field of view, as described in more detail below.
By way of example,
In this exemplary embodiment, the processor 96 utilizes a set of pre-defined rules, stored, for example, in the buffer 98 as a set of instructions, to select a portion of the image to be corrected for perspective distortions and to be displayed on the secondary display 102 at a selected magnification. The processor 96 effects the application of the above mathematical operations according to the invention to the selected portion to correct that portion for perspective distortions introduced by the fish-eye lens. Moreover, the processor 96 effects the display of the selected portion, with distortions removed, on the secondary display 102.
The processor 96 can automatically select a portion of the distorted fish-eye image, displayed on the primary display 100, based on any desired pre-defined criteria. For example, in one embodiment, the processor 96 selects a square central portion of the distorted image, such as, a portion 104, for display on the secondary display 102. In another embodiment, the processor 96 periodically, for example, once every few minutes, effects the acquisition of a fish-eye image of a scene and its display on the primary display 100. In addition, the processor 96 compares a newly acquired fish-eye image with a previous one to determine whether the position of one or more objects in the field of view has changed during the time elapsed between the acquisition of the two images. If the motion of an object is detected, the processor 96 selects a portion of the newly acquired image, or the previous image, that contains the moving object for viewing on the secondary display 102. That is, the processor 96 corrects that portion for perspective distortions, as described above, and displays the corrected image with a pre-defined magnification on the secondary display 102.
Those skilled in the art will appreciate that various modification can be made to the embodiments described above without departing from the scope of the present invention. For example, a variety of image capture devices can be utilized in different embodiments of the invention. In fact, in many embodiments of the invention, any image capture device that produces a digital image of a scene at a desired resolution can be employed.
This application is a continuation of U.S. patent application Ser. No. 10/005,824, filed Dec. 3, 2001, which is herein incorporated by reference.
Number | Date | Country | |
---|---|---|---|
Parent | 10005824 | Dec 2001 | US |
Child | 11017628 | Dec 2004 | US |