Image processing apparatus and method

Abstract: A virtual space using a geometric model for forming a virtual environment is input, nongeometric model object expression data based on a multi-viewpoint image is acquired, geometric information is added to the acquired nongeometric model object expression data, and the nongeometric model object expression data is used as an object arranged or operated in the virtual space using the added geometric information or automatically moving in the space. The same effect as that obtained when the shape data of an object having a very complex shape is generated or reproduced can be easily obtained without generating or reproducing the shape data. In addition, the entire virtual space can be generated without holding an enormous amount of light space data, so that the object can be operated in the three-dimensional space.

Description: The present invention relates to image processing for generating a virtual environment which can be experienced by the operator. Techniques below are known to generate a virtual environment which can be experienced by the operator. (1) A three-dimensional object or space is expressed by geometric model data such as polygon data or surface data, texture data representing surface characteristics or a pattern, light source data, and the like, and the appearance of a scene in an arbitrary direction is rendered using the computer graphics rendering technique, thereby expressing a three-dimensional object or space. With this technique, a virtual space is formed, and a virtual environment is generated and experienced. (2) A number of image groups of a three-dimensional real object or a real space are photographed, and a target object or space is described on the basis of the image groups. The appearance of the target is recorded without reconstructing the shape information of the target (this method is called nongeometric modeling), thereby reproducing the appearance in an arbitrary direction. More specifically, a photographed image is converted into light space data, and an image viewed from an arbitrary direction is generated from the light space data and presented. In prior art (1), the shape data of an object having a very complex shape can hardly be generated or reproduced. It is also hard to acquire shape data of an object having a complex shape from a real object using a three-dimensional measuring device. For this reason, the complex object can hardly be expressed. Particularly, it is more difficult to reproduce a real object having a certain complex shape or complex surface pattern/reflection characteristics (absorption/transmission characteristics). More exactly speaking, generally, a natural object can hardly be expressed although an artificial object can easily be expressed. However, a simple and artificial three-dimensional scene mainly constituted by planes, e.g., a room or a row of buildings can be relatively easily expressed using a relatively small quantity of data. In prior art (2), once nongeometric model data is generated from a certain amount of photographed image data, an image observed from an arbitrary viewpoint (there are restriction conditions in fact) can be generated. However, to present images viewed from all positions of the three-dimensional scene, an enormous amount of light space data must be generated and held. For this reason, the entire virtual space can hardly be generated using this data. In addition, since the target is expressed without reconstructing the shape information, operations of arranging and translating/rotating of the object expressed by the data as an object having a three-dimensional spacial extent are limited. Prior arts (1) and (2) are incompatible so the object expressed using nongeometric model data cannot be used in the virtual space generated by prior art (1). This is because although prior art (2) solves the problems of prior art (1), prior art (2) cannot be used to realize a virtual environment. According to the present invention, there is provided an image processing method as set out in claim 1. The present invention also provides an image processing apparatus as set out in claim 9. The present invention further provides a carrier carrying computer-readable instructions as set out in claim 17. Optional features are set out in the other claims. BRIEF DESCRIPTION OF THE DRAWINGS Fig. 1 is a block diagram of an apparatus for realizing the first, second, and third embodiments; Fig. 2 is a flow chart of the first embodiment; Fig. 3 is a flow chart showing part of the first embodiment; Fig. 4 is a flow chart showing part of the first embodiment; Fig. 5 is a flow chart showing part of the second embodiment; Fig. 6 is a flow chart showing part of the second embodiment; Fig. 7 is a flow chart showing part of the third embodiment; Fig. 8 is a flow chart showing part of the third embodiment; Fig. 9 is a view showing an example of hierarchical coordinate systems in the first embodiment; Fig. 10 is a diagram showing the tree structure corresponding to Fig. 9; Figs. 11A and 11B are schematic views showing a three-dimensional space so as to explain the principle of a light space; Fig. 12 is a view showing the relationship between a certain point in a real space and a light beam passing through the point; Fig. 13 is a view showing a map of a light beam passing through a certain point in the real space and projected on an x-u space as a light space; Figs. 14A and 14B are views showing transformation between the real space and the light space; Fig. 15 is a schematic view showing a state wherein a closed area (space) to be observed is assumed in nongeometric model data; Fig. 16 is a schematic view of geometric information of an MVDS; Fig. 17 is a schematic view showing a state wherein a representative point is added to the MVDS; Fig. 18 is a schematic view showing a state wherein a base is added to the MVDS; and Fig. 19 is a schematic view showing a state wherein a bounding box is added to the MVDS. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS [First Embodiment] Fig. 1 is a block diagram of the first embodiment. A CPU 1 executes the processing procedure of the first embodiment. A processing procedure memory device 2 stores the processing procedure. The processing procedure may be stored in the processing procedure memory device 2 in advance, or stored in a storage medium such as an FD, a CD-ROM, a ROM, or a magnetic tape and supplied through an external device interface 8. A data memory device 3 holds data generated or input before/after processing and during processing. A frame buffer 4 stores image data for presenting the processing process or processing result, which is to be sent to a display device. A window system 5 of the image processing apparatus displays image data stored in the frame buffer 4. A keyboard 6 is used to input an instruction in the processing process. A mouse 7 is a pointing device for designating a position on the screen. The external device interface 8 is used to input/output data or processing procedure. These units are connected via a bus 9. Fig. 2 is a flow chart showing the processing flow of the first embodiment. The first embodiment will be described in detail with reference to Fig. 2. In step S201, virtual space data using a geometric model for forming a virtual environment is input. To generate a virtual environment using a geometric model, internal objects, buildings, and background constituting the virtual space must be generated by, e.g., a modeler device capable of generating some computer graphics geometric data and surface characteristic data. An existing technique can be used for this generation processing. A geometric model and surface characteristic data may be generated in step S201, or data generated in another processing may be loaded. The geometric data means polygon data such as a triangular patch or free surface data such as NURBS. The surface characteristic data represent the material, reflection characteristics, and pattern of the object. The pattern is input as texture data. The texture data represents the surface pattern of polygon data or free surface data. The texture data describes the correspondence between pattern image data and a target object to which the image data is to be pasted. In step S202, a nongeometric model object expression data set (to be referred to as an MVDS (Multi-Viewpoint Data System) hereinafter) based on a multi-viewpoint image is acquired. With this method, the target object is expressed by describing the "appearance" of the object without estimating or measuring the shape of the object. The basic concept of this method will be described below. The geometric model describes the target object by recording the shape information of the target object. However, the MVDS describes the target object by recording data for reconstructing various "appearances" without reconstructing or measuring the shape of the target object. More specifically, a number of images are photographed around the target object, and the appearance of the target object is described on the basis of the images. Observation need not be performed in correspondence with all viewpoints necessary in reconstructing the appearance on the basis of the description data. It is considered that the reconstructed image can be generated from a certain limited amount of observation data. The MVDS means data converted from such finite multi-viewpoint observation data to readily generate an image viewed from various viewpoints. The MVDS is acquired by recording a number of data (light emerging from an area) which can be observed as an image from an assumed area where the target object supposedly exists. For this reason, in the MVDS, a space (area where light emerges; this area will be referred to as a closed area (space) R hereinafter) where the target object is present is explicitly or implicitly assumed, as shown in Fig. 15. In addition, to input the MVDS, the camera arrangement in photographing must be known. More specifically, the relative positional relationship between the closed area R and the camera arrangement in photographing is known. In other words, the direction (coordinate axes) of the closed area R and the scaling factor are obtained from the geometric arrangement information of the camera in photographing. The geometric arrangement information of the camera is obtained using a photographing device whose movement can be controlled, or determined on the basis of some image characteristic feature of the observed multi-viewpoint image. An image at an arbitrary viewpoint is reconstructed from the MVDS on the basis of the position and direction of a virtual camera viewed from the closed area R. As such an MVDS, light space data to be described below can be used. A technique of assuming a plane where z = O on a coordinate system as shown in Fig. 11A and expressing a three-dimensional space as a set of light beams passing through this plane (to be referred to as a reference plane 1101 hereinafter) is proposed (three-dimensional space expression by light space). In this technique, an image which can be observed at a viewpoint P in the three-dimensional space where z > 0 is equivalent to an image obtained by sampling only light beams passing through the viewpoint P from the set of the light beams passing through the reference plane 1101, as shown in Fig. 12. Generally, each light beam is represented by a position (x,y) through which the light beam passes, angles  and Ψ (Fig. 11B) between the light beam and the X- and Y-axes, time t when the light beam has passed through the plane, and the color (r,g,b) of the light beam. In fact, to prevent the calculation amount or data amount from becoming enormous, it is assumed that the object is stationary and no Y-axis parallax is present. Under this assumption, each light beam is projected on the x-u space while setting u = tan, and the light space is handled in this projected x-u space. In this case, a light beam passing through the certain point P exhibits a straight locus as shown in Fig. 13. This locus is represented by the following equations: x = X - Z·u u = tan where (X,Z) is the observation viewpoint P, x is the position where the light beam crosses the X-axis in the x-u space, and  is the angle formed between the light beam and the Z-axis. First, straight loci are obtained from an image obtained at a number of viewpoints (e.g., viewpoints A, B, and C), as shown in Figs. 14A and 14B, and assume that the x-u space is filled with this locus group at a high density. At this time, the image at a viewpoint Q where z > 0 can be obtained by calculating a locus passing through the viewpoint Q on the x-u space, as shown in Fig. 14B, and reversely obtaining the color of the light beam which has already been recorded on the locus. In step S203, some geometric information is added to the MVDS. This some geometric information will be described. The MVDS describes only the appearance of the object in the area R and does not explicitly describe the shape of the object. Only the assumed closed area R as shown in Fig. 16 is known as information of the three-dimensional space which is known from the MVDS. The presence position and shape of the object in the closed area R are undecided. To use the MVDS as an object in the virtual space, some geometric information for mixing the MVDS with the shape model input in step S201 is required. In this case, the some geometric information means three-dimensional information such as the three-dimensional position of a point, the direction of a vector, or a surface. In step S204, the MVDS is operated in the virtual space described by the three-dimensional shape information itself using the geometric information added in step S203. When the relationship (arrangement position or direction) between the geometric information added in step S203 and the coordinate system of the virtual space is described, the object expressed by the MVDS can be used in the virtual space. Fig. 3 shows an example of step S203, and Fig. 4 shows an example of step S204 corresponding to processing in Fig. 3. In step S301, a representative point of the object present in the closed area R is designated (Fig. 17). The representative point is set by designating, e.g., a central point of an area (area having a three-dimensional extent) where the object is present in the closed area R. This point may be designated on the basis of the camera arrangement in photographing the object and the arrangement information in setting the object for the purpose of photographing. Alternatively, the point may be designated from an object in the photographed multi-viewpoint image. In this case, a representative point near the center of the object is designated in the image, and a straight line is obtained in the closed area R by reverse projection of the perspective projection in photographing. This operation is performed for images photographed at a plurality of camera positions. An area where resultant straight lines concentrate is obtained, and the center of gravity of this area is set as the representative point. Any other method may be used. With some method, the representative point of the object in the closed area R is designated. In step S302, coordinate transformation T for describing the coordinate relationship of the closed area R having the representative point P in the virtual space is prepared. The coordinate transformation T defines the position of the representative point P and the direction of the closed area R viewed from the coordinate system of the virtual space. The coordinate transformation T has parameters for translation, rotation, and reduction. This coordinate transformation T is used in subsequent steps. Processing in step S204 will be described below with reference to Fig. 4 corresponding to step S204. In step S401, the arrangement position and direction of the MVDS in the virtual space are determined. In addition, components of translation and rotation and the like are described by the coordinate transformation T on the basis of the determined arrangement information. With this processing, the object expressed by the MVDS can be arranged in the virtual space. In step S402, it is determined whether the operation of the MVDS in the virtual space is to be started. In fact, it is assumed that virtual experience is being made while displaying the virtual space. It is determined whether, in this operation, the object expressed by the MVDS is allowed to be gripped and moved. If YES in step S402, the flow advances to step S403. In step S403, the coordinate transformation T is changed and updated on the basis of the operation, thereby translating and rotating the MVDS. If NO in step S402, the flow advances to step S404. It is determined in step S404 whether the operation is to be ended. If YES in step S404, the series of processing is ended. If NO in step S404, the flow returns to step S402. As the coordinate transformation T used in steps S401 to S404, coordinate transformation from a world coordinate system as a coordinate system where the virtual space is present may be used. Alternatively, the virtual space may be expressed by hierarchical coordinate systems, and coordinate transformation from one of the hierarchical coordinate systems may be used. In the latter case, elements (coordinate transformation data, shape data, surface characteristic data, illumination, and the like) constituting the virtual space are represented by a tree structure. This is because the space, ground, buildings, rooms, furnitures, illumination, and ornaments, which constitute the three-dimensional space, can be considered to have a hierarchical nesting structure. For example, an ornament placed on a desk moves together with the desk. The arrangement of the ornament depends on the arrangement of the desk. It is convenient to arrange the ornament in the coordinate system of the desk to be relative to the desk. For this reason, these elements have a hierarchical data structure with arrangement dependence. To represent it, the virtual space is represented by an n-ary tree structure. Fig. 9 is a view showing a simple example of a virtual space. In Fig. 9, prominence is placed on the room, desk, and sofa in the space. The room is described on a coordinate system C2 transformed from a world coordinate system C0 by coordinate transformation T2. The desk and sofa in the room are described on coordinate systems C3 and C4 transformed from the coordinate system C2 by coordinate transformations T3 and T4, respectively. The pot on the desk is described on a coordinate system C5 transformed from the coordinate system C3 by coordinate transformation T5. In this method, the MVDS is described as one element of this tree structure. In Fig. 9, the MVDS is arranged on the desk. Fig. 10 shows a schematic tree structure representing the virtual space shown in Fig. 9. With the above method, the object expressed by the MVDS can be arranged and operated in the virtual space. However, since geometric information added to the MVDS is only one representative point, the surface position of the object, and the like are undecided, so the "object" itself cannot be arranged on another object. Consider an MVDS of a vase is placed on the table. In this case, the vase may be arranged in the space such that the vase is "apparently" set on the table as a drawing result. More specifically, when the coordinate transformation T is adjusted while referring to the drawing result, the MVDS can be arranged as if the object were placed on another object. This also applies to translation and rotation. The arrangement or translation and rotation operations can also be automatically performed according to a predetermined procedure. [Second Embodiment] In the second embodiment, steps S203 and S204 of the first embodiment are changed, as will be described below. Processing in step S203 will be described with reference to Fig. 5, and processing in step S204 will be described with reference to Fig. 6. In step S501, a base S is designated at a position corresponding to the base of an object present in a closed area R (Fig. 18). The base S is set by designating the lowermost surface of an area (area having a three-dimensional spacial extent) where the object is present in the closed area. In general, the object represented by the MVDS is a natural object, as can be seen from the fact that the object is photographed with a camera, and the object having a base is stable while it is placed on another object. For this reason, it can be considered that designation of the base is often effective in subsequent steps. The base may be designated on the basis of the camera arrangement and the arrangement information of the set table of the object in photographing the object. Alternatively, the base may be designated from an object in the photographed multi-viewpoint image. In this case, a point near the base of the object is designated in the image, and a straight line is obtained in the closed area R by reverse projection of the perspective projection in photographing. This operation is performed for images photographed at a plurality of camera positions, and the base is determined on the basis of the loci of resultant straight lines present in the space. Any other method may be used. With some method, the base S of the object in the closed area R is designated. In step S502, coordinate transformation T for describing the coordinate relationship of the closed area R having the base S in the virtual space is prepared. The coordinate transformation T defines the position and direction of the base S viewed from the coordinate system of the virtual space. The coordinate transformation T has parameters for translation, rotation, and reduction. This coordinate transformation T is used in subsequent steps. This processing will be described next with reference to Fig. 6. In step S601, the arrangement position and direction of the MVDS in the virtual space are determined. Since the geometric information of the base S is added to the MVDS, the MVDS can be determined to be set on another object (e.g., the floor or desk) in the virtual space. In addition, components of translation and rotation and the like are described by the coordinate transformation T on the basis of the determined arrangement information. With this processing, the object expressed by the MVDS can be arranged in the virtual space. In step S602, it is determined whether the operation of the MVDS in the virtual space is to be started. In fact, it is assumed that virtual experience is being made while displaying the virtual space. It is determined whether, in this operation, the object expressed by the MVDS is allowed to be gripped and moved. If YES in step S602, the flow advances to step S603. In step S603, the coordinate transformation T is changed and updated on the basis of the operation, thereby translating and rotating the MVDS. If NO in step S602, the flow advances to step S604. It is determined in step S604 whether the operation is to be ended. If YES in step S604, the series of processing is ended. If NO in step S604, the flow returns to step S602. With the above method, the object represented by the MVDS can be arranged and operated in the virtual space. Since the base is used as geometric information added to the MVDS, the object expressed by the MVDS can be arranged on another object. This also applies to translation and rotation. An operation restricted on another object is enabled. In addition, the arrangement or translation and rotation operations can also be automatically performed according to a predetermined procedure. [Third Embodiment] In the third embodiment, steps S203 and S204 of the first embodiment are changed as will be described below. Processing in step S203 will be described with reference to Fig. 7, and processing in step S204 will be described with reference to Fig. 8. In step S701, a bounding box B for limiting the presence area of an object present in a closed area R is designated (Fig. 19). The bounding box B is set by designating an area (area having a three-dimensional spacial extent) where the object is present in the closed area. However, since the shape of the object cannot be perfectly obtained, a rectangular prism approximately representing the presence area of the object, or the like is designated. The bounding box may be designated on the basis of the camera arrangement and the arrangement information of the set table of the object in photographing the object, and the characteristic feature of the photographed multi-viewpoint image. In this method of obtaining the bounding box from the characteristic feature of the photographed multi-viewpoint image, the contour of the image on the image plane is obtained (or designated), and the contour curve is projected on the closed area R by reverse projection of the perspective projection in photographing. This operation is performed for images photographed at a plurality of camera positions, and an area enclosed by planes formed by projecting the contour line is obtained. A rectangular prism enclosing this area is set. Any other method may be used. With some method, the bounding box B of the object in the closed area R is designated. In step S702, coordinate transformation T for describing the coordinate relationship of the closed area R having the bounding box B in the virtual space is prepared. The coordinate transformation T defines the position and direction of the bounding box B viewed from the coordinate system of the virtual space. The coordinate transformation T has parameters for translation, rotation, and reduction. This coordinate transformation T is used in subsequent steps. This processing will be described next with reference to Fig. 8. In step S801, the arrangement position and direction of the MVDS in the virtual space are determined. Since the geometric information of the bounding box B is added to the MVDS, the MVDS can be determined to be set on another object (e.g., the floor or desk) or set while preventing interference with another object in the virtual space. In addition, components of translation and rotation and the like are described by the coordinate transformation T on the basis of the determined arrangement information. With this processing, the object expressed by the MVDS can be arranged in the virtual space. In step S802, it is determined whether the operation of the MVDS in the virtual space is to be started. In fact, it is assumed that virtual experience is being made while displaying the virtual space. It is determined whether, in this operation, the object expressed by the MVDS is allowed to be gripped and moved. If YES in step S802, the flow advances to step S803. In step S803, the coordinate transformation T is changed and updated on the basis of the operation, thereby translating and rotating the MVDS. If NO in step S802, the flow advances to step S804. It is determined in step S804 whether the operation is to be ended. If YES in step S804, the flow returns to step S204. If NO in step S804, the flow returns to step S802. With the above method, the object represented by the MVDS can be arranged and operated in the virtual space. Since the bounding box is used as geometric information added to the MVDS, the object expressed by the MVDS can be arranged on another object or arranged while preventing interference with another object. This also applied to translation and rotation. An operation restricted on another object or an operation for preventing rough interference with another object is enabled. In addition, the arrangement or translation and rotation operations can also be automatically performed according to a predetermined procedure. According to the first to third embodiments, the same effect as that obtained when the shape data of an object having a very complex shape is generated or reproduced can be obtained by expressing the object by nongeometric model data without generating or reproducing the shape data. In addition, the entire virtual space can be generated without holding an enormous quantity of light space data. Furthermore, only by adding simple geometric information to the nongeometric model data, an operation in the three-dimensional space can be performed without reconstructing the shape information to express the object. Furthermore, the object represented by the nongeometric model information can be used in the generated virtual space. Embodiments of the present invention may comprise a system constituted by a plurality of devices, or an apparatus comprising a single device. Furthermore, it goes without saying that an embodiment may comprise a program for a system or apparatus supplied for example on a storage medium to the system or apparatus, thereby operating the system or apparatus in accordance with a predetermined method.

Claims: An image processing method performed by an image processing apparatus comprising: receiving geometric model data defining a three-dimensional computer model of a virtual environment (S201); characterised by : receiving nongeometric model object expression data based on a multi-viewpoint image (S202); adding geometric information to the nongeometric model object expression data (S301, S501, S701); defining a relationship between the added geometric information and a coordinate system of the three-dimensional computer model (S302, S502, S702); and moving the nongeometric model object expression data in the virtual environment using the defined relationship (S403, S603, S803). A method according to claim 1, wherein the added geometric information defines a representative point in a closed area where the nongeometric model object expression data is present. A method according to claim 1, wherein the added geometric information defines a base in a closed area where the nongeometric model object expression data is present. A method according to claim 1, wherein the added geometric information defines a bounding box in a closed area where the nongeometric model object expression data is present. A method according to any preceding claim, wherein the nongeometric model object expression data is light space data. A method according to any preceding claim, wherein the movement of the nongeometric model object expression data is performed by changing the defined relationship between the added geometric information and the coordinate system of the three-dimensional computer model. A method according to any preceding claim, wherein the movement of the nongeometric model object expression data comprises translation of the nongeometric model object expression data in the virtual environment. A method according to any of claims 1 to 6, wherein the movement of the nongeometric model object expression data comprises rotation of the nongeometric model object expression data in the virtual environment. An image processing apparatus comprising: means (8) for receiving geometric model data defining a three-dimensional computer model of a virtual environment; characterised by : means (8) for receiving nongeometric model object expression data based on a multi-viewpoint image; means (1, 3) for adding geometric information to the nongeometric model object expression data; means (1, 3) for defining a relationship between the added geometric information and a coordinate system of the three-dimensional computer model; and means (1, 3) for moving the nongeometric model object expression data in the virtual environment using the defined relationship. A method according to claim 9, wherein the means for adding geometric information is operable to add geometric information defining a representative point in a closed area where the nongeometric model object expression data is present. An apparatus according to claim 9, wherein the means for adding geometric information is operable to add geometric information defining a base in a closed area where the nongeometric model object expression data is present. An apparatus according to claim 9, wherein the means for adding geometric information is operable to add geometric information defining a bounding box in a closed area where the nongeometric model object expression data is present. An apparatus according to any of claims 9 to 12, wherein the apparatus is configured to receive and process nongeometric model object expression data comprising light space data. An apparatus according to any of claims 9 to 13, wherein the means for moving the nongeometric model object expression data is operable to effect the movement by changing the defined relationship between the added geometric information and the coordinate system of the three-dimensional computer model. An apparatus according to any of claims 9 to 14, wherein the means for moving the nongeometric model object expression data is operable to translate the nongeometric model object expression data in the virtual environment. An apparatus according to any of claims 9 to 15, wherein the means for moving the nongeometric model object expression data is operable to rotate the nongeometric model object expression data in the virtual environment. A carrier carrying computer-readable instructions for programming a programmable processing apparatus to become operable to perform a method as set out in at least one of claims 1 to 8. A carrier according to claim 17 wherein the carrier comprises a storage medium storing the instructions.

Inventors: KATAYAMA AKIHIRO, UCHIYAMA SHINJI, KATAYAMA, AKIHIRO, UCHIYAMA, SHINJI
Applicants: CANON KK, CANON KABUSHIKI KAISHA
Application year: 1997
Main classification: G06T17
IPC codes: G06T17