JP4325469B2 - Object surface flattening apparatus and program - Google Patents

Object surface flattening apparatus and program Download PDF

Info

Publication number
JP4325469B2
JP4325469B2 JP2004113257A JP2004113257A JP4325469B2 JP 4325469 B2 JP4325469 B2 JP 4325469B2 JP 2004113257 A JP2004113257 A JP 2004113257A JP 2004113257 A JP2004113257 A JP 2004113257A JP 4325469 B2 JP4325469 B2 JP 4325469B2
Authority
JP
Japan
Prior art keywords
polygon
object surface
polygons
vertex
shape
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2004113257A
Other languages
Japanese (ja)
Other versions
JP2005301426A (en
JP2005301426A5 (en
Inventor
俊一 木村
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujifilm Business Innovation Corp
Original Assignee
Fuji Xerox Co Ltd
Fujifilm Business Innovation Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fuji Xerox Co Ltd, Fujifilm Business Innovation Corp filed Critical Fuji Xerox Co Ltd
Priority to JP2004113257A priority Critical patent/JP4325469B2/en
Publication of JP2005301426A publication Critical patent/JP2005301426A/en
Publication of JP2005301426A5 publication Critical patent/JP2005301426A5/ja
Application granted granted Critical
Publication of JP4325469B2 publication Critical patent/JP4325469B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Processing Or Creating Images (AREA)
  • Image Generation (AREA)

Description

本発明は、物体表面平坦化装置、物体表面平坦化方法およびプログラムに関する。   The present invention relates to an object surface flattening apparatus, an object surface flattening method, and a program.

コンピュータ上で現実感を持った画像を生成する手法としてコンピュータグラフィック(以下、CG)技術が広く利用されている。CG技術において、サーフェスモデル、あるいは、ポリゴングラフィックスと呼ばれる手法がある。これらは、物体の表面形状を多角形の集合体として近似するものである。このように多角形の集合体で表現された物体表面を展開することによって、たとえば、以下に示すような応用例が考えられる。   Computer graphic (hereinafter, CG) technology is widely used as a method for generating a realistic image on a computer. In the CG technology, there is a method called surface model or polygon graphics. These approximate the surface shape of an object as an aggregate of polygons. For example, the following application examples can be considered by developing the object surface expressed by a polygonal aggregate.

画像スキャナーの歪み補正方法の応用例として、たとえば、非特許文献1記載の技術(従来例1)を挙げることができる。非特許文献1記載の方法は、撮影された湾曲物体の表面形状を計算機上で平面形状に変換するものである。本の表面形状のように、もともとは平面であるにもかかわらず、画像のスキャン入力時の制約によって湾曲したまま画像入力せざるを得ない場合等に応用することができる。   As an application example of the distortion correction method of the image scanner, for example, the technique described in Non-Patent Document 1 (Conventional Example 1) can be cited. The method described in Non-Patent Document 1 is to convert the surface shape of a photographed curved object into a planar shape on a computer. The present invention can be applied to a case where an image must be input while being curved due to restrictions at the time of image scan input even though it is originally a flat surface like the surface shape of a book.

また、複雑な形状の表面に対して、できるだけ歪みの少ないテクスチャマッピングを行うことを目的とした方式として、たとえば、非特許文献2記載の方式(従来例2)が提案されている。非特許文献2に示されるように、展開不可能な表面を平面に展開することで、歪みをできるだけ小さくしたテクスチャマッピングを行うことができる。ここで、任意の2点間の距離を変化させずに、3次元空間内の物体表面を2次元平面に変換することができる場合、その物体表面は展開可能と定義し、2次元平面に変換できない場合、展開不可能と定義する。   For example, a method described in Non-Patent Document 2 (conventional example 2) has been proposed as a method for performing texture mapping with as little distortion as possible on a complex-shaped surface. As shown in Non-Patent Document 2, texture mapping with as little distortion as possible can be performed by developing a surface that cannot be developed on a plane. Here, if the object surface in the three-dimensional space can be converted to a two-dimensional plane without changing the distance between any two points, the object surface is defined as expandable and converted to a two-dimensional plane. If it cannot, define it as undeployable.

一般にガウス曲率が全面にわたって0の曲面は平面に展開可能であり、ガウス曲率が0ではない曲面は平面に展開不可能であることが知られている。たとえば、円筒の側面は平面に展開できるが、球面はガウス曲率が0ではないため、平面に展開することはできない。   In general, it is known that a curved surface having a Gaussian curvature of 0 over the entire surface can be developed on a plane, and a curved surface having a non-Gaussian curvature of 0 cannot be developed on a plane. For example, the side surface of a cylinder can be developed on a plane, but a spherical surface cannot be developed on a plane because the Gaussian curvature is not zero.

非特許文献2記載の方法では、まず、3次元形状の表面から抽出した点の間の距離(測地線の長さ)を計測し、その距離の変化の大きさができるだけ小さくなるように平面に展開する。次に、展開された平面にテクスチャをマッピングする。最後に曲面から平面への展開を逆に行って、平面テクスチャマップを元の3次元形状に変換する。このように、3次元形状を2次元平面に展開する手法は、見た目の歪みが小さなテクスチャマッピング手法として用いることができる。   In the method described in Non-Patent Document 2, first, the distance between the points extracted from the surface of the three-dimensional shape (the length of the geodesic line) is measured, and the surface is flattened so that the magnitude of the change in the distance is as small as possible. expand. Next, the texture is mapped to the developed plane. Finally, the development from the curved surface to the plane is performed in reverse to convert the plane texture map into the original three-dimensional shape. As described above, the method of developing a three-dimensional shape on a two-dimensional plane can be used as a texture mapping method with a small apparent distortion.

次に、展開不可能な曲面を平面に展開する方式の他の例として、平面に展開可能な物体表面(可展体面)を媒介として展開を行う方式(特許文献1)を示す。特許文献1記載の方式は、テクスチャ表面を展開することによって、テクスチャマッピングを効率的に行おうとする方式である。特許文献1記載の方式では、撮影した2次元データから3次元形状復元処理を用いた任意視点の画像を表示する方式に関するものである。   Next, as another example of a method of developing a non-developable curved surface into a plane, a method of performing development using an object surface (developable body surface) that can be developed into a plane as a medium (Patent Document 1) is shown. The method described in Patent Document 1 is a method for efficiently performing texture mapping by developing a texture surface. The method described in Patent Document 1 relates to a method for displaying an image of an arbitrary viewpoint using three-dimensional shape restoration processing from photographed two-dimensional data.

さらに、特許文献1記載の方式は、この表示方式において、テクスチャ画像情報のデータ量を削減する手法に関するものである。この表示方式においては、2次元データから得られた各微小平面のテクスチャを個々の微小平面ごとに保持するのではなく、3次元形状を平面に展開して、隙間のできるだけ少ない展開図のテクスチャを保持することによって効率的に画像データを保持することを目的としている。   Further, the method described in Patent Document 1 relates to a technique for reducing the amount of texture image information data in this display method. In this display method, the texture of each minute plane obtained from the two-dimensional data is not held for each individual minute plane, but the three-dimensional shape is developed on the plane, and the texture of the developed view with as few gaps as possible is obtained. The object is to hold image data efficiently by holding.

特許文献1記載の方式は、3次元オブジェクトの特徴点を可展体面である既知形状面(円筒、柱体、錐体等)の投影面に投影して平面に展開し、各特徴点を頂点とする多角形に対して、この展開平面上でテクスチャマッピングをするものである。このように、一度、展開可能な物体表面に投影することによって、複雑な3次元形状を平面に展開することが可能となる。以上、3つの従来例から、以下の3つの応用例を示した。
(1)画像スキャナーで画像をスキャンインした後で、スキャン時の条件により歪んでしまった画像を補正する。たとえば書物の表面を平面化する。
(2)複雑な3次元曲面を2次元平面に変換することにより、2次元平面上で簡易にテクスチャマッピングが可能になる。
(3)複雑な3次元曲面を2次元平面に変換することにより、保持するテクスチャ情報量を削減することができる。
The method described in Patent Document 1 projects the feature points of a three-dimensional object onto a projection surface of a known shape surface (cylinder, column, cone, etc.) that is a developable surface and develops it on a plane. The texture mapping is performed on the development plane for the polygon. As described above, by projecting the object surface that can be developed once, a complicated three-dimensional shape can be developed on a plane. From the above three conventional examples, the following three application examples have been shown.
(1) After an image is scanned in by an image scanner, an image distorted due to scanning conditions is corrected. For example, the surface of a book is flattened.
(2) By converting a complicated three-dimensional curved surface to a two-dimensional plane, texture mapping can be easily performed on the two-dimensional plane.
(3) By converting a complex three-dimensional curved surface into a two-dimensional plane, the amount of texture information to be held can be reduced.

「アイスキャナによる湾曲ドキュメント撮影」(電子情報通信学会論文誌D-II、Vol. J86-D-II, No. 3, March 2003, pp.409-417)"Curved Document Shooting with an Eye Scanner" (The IEICE Transactions D-II, Vol. J86-D-II, No. 3, March 2003, pp.409-417) 「Texture Mapping Using Surface Flattening via Multidimensional Scaling」(IEEE Trans. Visualization and Computer Graphics, vol. 8, no. 2, pp. 198-206, Apr.-June, 2002)"Texture Mapping Using Surface Flattening via Multidimensional Scaling" (IEEE Trans. Visualization and Computer Graphics, vol. 8, no. 2, pp. 198-206, Apr.-June, 2002) 特開2000−20735号公報JP 2000-20735 A

しかしながら、(1)非特許文献1記載の方法では、適用する物体表面を書物の表面に限定しており、一般の展開不可能な物体表面には適用できないという問題点があった。   However, (1) The method described in Non-Patent Document 1 has a problem that the object surface to be applied is limited to the surface of a book and cannot be applied to a general object surface that cannot be developed.

(2)非特許文献2記載の方法では、3次元形状から測地線を求める計算量が非常に大きいという問題点があった。   (2) The method described in Non-Patent Document 2 has a problem that the calculation amount for obtaining a geodesic line from a three-dimensional shape is very large.

(3)一方、特許文献1記載の方法では、厳密に測地線の距離を求めずに、3次元空間上にある物体表面を一旦可展体面に投影することで展開を行う方式を用いているため、計算量が少なくて済む。しかし、特許文献1記載の方法では、元の物体の3次元形状が平面に展開不可能な場合、できるだけ元の物体の表面に近い可展体面を選んでも、結局は、可展体面に投影する段階で歪みが発生してしまうという問題点があった。   (3) On the other hand, the method described in Patent Document 1 uses a method in which development is performed by once projecting the surface of an object in a three-dimensional space onto a developable surface without obtaining the distance of the geodesic line strictly. Therefore, the calculation amount is small. However, in the method described in Patent Document 1, if the three-dimensional shape of the original object cannot be developed on a plane, even if a developable surface that is as close as possible to the surface of the original object is selected, the result is eventually projected onto the developable surface. There was a problem that distortion occurred at the stage.

そこで、本発明は、上記従来例の問題点に鑑み、3次元空間内の物体表面が多角形の集合体として表されている場合に、物体表面が展開不可能な場合であっても、多角形を平面上でできるだけ歪みが小さくなるように並べることができる物体表面平坦化装置、物体表面平坦化方法およびプログラムを提供することを目的とする。   Therefore, in view of the problems of the conventional example described above, the present invention has many cases where the object surface cannot be expanded when the object surface in the three-dimensional space is represented as a polygonal aggregate. An object of the present invention is to provide an object surface flattening apparatus, an object surface flattening method, and a program capable of arranging squares so that distortion is minimized on a plane.

上記課題を解決するために、本発明は、請求項1に記載のように、コンピュータ上に多角形の集合体として表現された3次元空間内の物体表面を平面上に展開する物体表面平坦化装置であって、入力データから多角形の形状情報を抽出する手段と、前記多角形と辺を共有する周辺多角形の形状情報を抽出する手段と、前記多角形の形状情報および前記周辺多角形の形状情報から、前記平面上において前記多角形と前記周囲多角形との間で共有する辺間の距離についての関数を求め、前記関数に前記共有する辺間の距離が最小になるという条件を適用することにより、前記各多角形毎に、前記各多角形の位置を決定するための一次方程式を作成する係数取得手段と、前記各多角形を決定するための一次方程式を解くことにより、前記各多角形の位置を算出する多角形位置算出手段と、前記位置が算出された多角形を並べる手段とを具備することを特徴とする。 In order to solve the above-described problems, the present invention provides an object surface flattening that develops on a plane an object surface in a three-dimensional space expressed as a polygonal aggregate on a computer. A device for extracting polygon shape information from input data; a means for extracting shape information of a peripheral polygon sharing a side with the polygon; and shape information of the polygon and the peripheral polygon From the shape information, the function for the distance between the sides shared between the polygon and the surrounding polygon on the plane is obtained, and the condition that the distance between the shared sides is minimized in the function. By applying the coefficient acquisition means for creating a linear equation for determining the position of each polygon for each of the polygons, and solving the linear equation for determining the polygons, For each polygon Characterized by comprising a polygonal position calculating means for calculating a location, and means for arranging the polygon the position is calculated.

請求項1記載の発明によれば、入力多角形の位置は多角形の位置に関する式を解くことにより決定し、入力多角形を平面上に並べることができる。これにより、3次元空間内の物体表面が多角形の集合体として表されている場合に、物体表面が展開不可能な場合であっても、多角形を平面上でできるだけ歪みが小さくなるように並べることができる。また、歪みの小さな展開図を作成するのに必要な測地線の距離を求める必要が無いため、測地線の距離を求めるための計算量を削減できる。   According to the first aspect of the present invention, the position of the input polygon can be determined by solving an expression relating to the position of the polygon, and the input polygon can be arranged on a plane. As a result, when the object surface in the three-dimensional space is represented as a collection of polygons, even if the object surface cannot be expanded, the distortion of the polygon on the plane is minimized. Can be lined up. In addition, since it is not necessary to obtain the geodesic distance required to create a development with a small distortion, the amount of calculation for obtaining the geodesic distance can be reduced.

また、本発明は、請求項2に記載のように、請求項1記載の物体表面平坦化装置において、更に、前記並べられた各多角形の形状を補正する手段を具備することを特徴とする。請求項2記載の発明によれば、並べられた多角形間に重なりや隙間がある場合に、その多角形の形を補正して、重なりや隙間のない平面を作ることが可能になる。   Further, according to the present invention, as described in claim 2, the object surface flattening device according to claim 1, further comprising means for correcting the shapes of the arranged polygons. . According to the second aspect of the present invention, when there is an overlap or a gap between the arranged polygons, it is possible to correct the shape of the polygon to create a plane without the overlap or the gap.

また、本発明は、請求項3に記載のように、請求項1または請求項2記載の物体表面平坦化装置において、更に、多角形の頂点以外の辺上に他の多角形の頂点が存在している場合に、前記多角形の辺上にある頂点から線分あるいは半直線を引くことにより、その頂点と辺の交点を新たな頂点とする多角形分割手段を具備することを特徴とする。請求項3記載の発明によれば、多角形の辺上の頂点をなくすことができるので、入力多角形の辺上に頂点がある場合でも、入力多角形の辺上に頂点がない場合と同様に物体表面を平面に展開できるようになる。   Further, according to the present invention, as described in claim 3, in the object surface flattening device according to claim 1 or 2, there is further a vertex of another polygon on a side other than the vertex of the polygon. And a polygon dividing means that draws a line segment or a half line from the vertex on the side of the polygon and sets the intersection of the vertex and the side as a new vertex. . According to the invention of claim 3, since the vertex on the side of the polygon can be eliminated, even when there is a vertex on the side of the input polygon, it is the same as when there is no vertex on the side of the input polygon The object surface can be developed on a plane.

また、本発明は、請求項4に記載のように、請求項1から請求項3の何れか一項に記載の物体表面平坦化装置において、前記入力データは、3次元空間内の物体表面を構成する多角形の形状を表すデータを含み、前記多角形の形状を表すデータは、共通の始点から多角形の各頂点への2次元ベクトルであり、前記共通の始点へのベクトルは多角形の位置を表すベクトルであることを特徴とする。請求項4記載の発明によれば、多角形の形状を表すデータを、共通の始点を表すベクトルと、共通の始点から頂点への2次元ベクトルとによって表現することにより、多角形の位置と形状を別々に操作できるようになる。   Further, according to the present invention, as described in claim 4, in the object surface flattening device according to any one of claims 1 to 3, the input data includes an object surface in a three-dimensional space. Including data representing the shape of the polygon that constitutes the data, and the data representing the shape of the polygon is a two-dimensional vector from a common starting point to each vertex of the polygon, and the vector to the common starting point is a polygonal shape. It is a vector representing a position. According to the invention described in claim 4, by expressing the data representing the shape of the polygon by a vector representing a common starting point and a two-dimensional vector from the common starting point to the vertex, the position and shape of the polygon Can be operated separately.

また、本発明は、請求項5に記載のように、請求項1から請求項4の何れか一項に記載の物体表面平坦化装置において、前記入力データは、3次元空間内の物体表面を構成する多角形の相対位置を表すデータを含み、前記相対位置を表すデータは、3次元空間内の物体表面を構成する多角形の各辺に対し、該各辺をどの多角形が共有しているかを示す情報、および/または、3次元空間内の物体表面を構成する多角形にはどの辺が存在しているかを示す情報、および、各辺の両端の頂点インデクスのデータであることを特徴とする。請求項5記載の発明によれば、周辺多角形を効率的に抽出できる。   Further, according to the present invention, as described in claim 5, in the object surface flattening apparatus according to any one of claims 1 to 4, the input data includes an object surface in a three-dimensional space. Including data representing the relative positions of the polygons constituting the polygon, and the data representing the relative positions is determined by which polygons share each side with respect to each side of the polygon constituting the object surface in the three-dimensional space. Information indicating whether or not and / or information indicating which side exists in the polygon that forms the object surface in the three-dimensional space, and data of vertex indices at both ends of each side And According to the fifth aspect of the present invention, the surrounding polygon can be extracted efficiently.

また、本発明は、請求項6に記載のように、請求項1から請求項5の何れか一項に記載の物体表面平坦化装置において、前記係数取得手段は、ある中心多角形と、該中心多角形と辺を共有する周囲多角形との間で、共有すべき辺間の距離の和が最小になるような、中心多角形と周囲多角形との相対位置を示す一次方程式を作成することを特徴とする。請求項6記載の発明によれば、共有すべき辺間の距離の和が最小になるような、中心多角形と周囲多角形との相対位置を示す式の係数を取得することで、多角形を隙間無く、かつ重複無く並べることができる。 Further, according to the present invention, as described in claim 6, in the object surface flattening device according to any one of claims 1 to 5, the coefficient acquisition unit includes a center polygon, Create a linear equation that indicates the relative positions of the center polygon and the surrounding polygons so that the sum of the distances between the sides to be shared is minimized between the center polygon and the surrounding polygons that share the sides. It is characterized by that. According to the sixth aspect of the invention, by obtaining the coefficient of the expression indicating the relative position between the center polygon and the surrounding polygon so that the sum of the distances between the sides to be shared is minimized, Can be arranged without gaps and without duplication.

また、本発明は、請求項7に記載のように、請求項6記載の物体表面平坦化装置において、前記辺間の距離は、共有すべき頂点間の距離の2乗和に辺の長さを乗じたものであることを特徴とする。請求項7記載の発明によれば、同じ位置にあるべき頂点間の距離の2乗和を、共有すべき辺の長さで重み付けすることができる。   Further, according to the present invention, in the object surface flattening device according to claim 6, the distance between the sides is the sum of squares of the distances between the vertices to be shared. It is characterized by being multiplied by. According to the seventh aspect of the invention, the sum of squares of the distances between the vertices that should be at the same position can be weighted by the length of the side to be shared.

また、本発明は、請求項8に記載のように、請求項1から請求項7の何れか一項に記載の物体表面平坦化装置において、前記多角形位置算出手段は、最小二乗法で連立一次方程式を解くことで前記各多角形の位置を算出することを特徴とする。請求項8記載の発明によれば、最小二乗法を用いて連立一次式を解くことにより各多角形の位置を算出する。これにより、多角形の位置は、連立一次方程式を最小二乗法で解くという公知の手法を用いて計算することができる。   Further, according to the present invention, as described in claim 8, in the object surface flattening device according to any one of claims 1 to 7, the polygon position calculation means is simultaneous by a least square method. The position of each polygon is calculated by solving a linear equation. According to the invention described in claim 8, the position of each polygon is calculated by solving simultaneous linear equations using the least square method. Thereby, the position of the polygon can be calculated using a known method of solving simultaneous linear equations by the least square method.

また、本発明は、請求項9に記載のように、請求項1から請求項3の何れか一項に記載の物体表面平坦化装置において、前記入力データに含まれる多角形は、2次元行列にマッピングされるように配置された四角形であり、前記多角形の形状を抽出する手段は、前記四角形の配置場所に対応した多角形インデクスから前記3次元空間内の物体表面を構成する多角形の相対位置を表すデータを決定し、前記係数取得手段は、前記多角形の相対位置から、前記各多角形の位置に関する式の係数を決定することを特徴とする。請求項9記載の発明によれば、入力多角形が2次元行列にマッピングされるように配置された四角形である場合には、入力データの情報量と、展開処理のための計算量を削減することができる。   Further, according to the present invention, as described in claim 9, in the object surface flattening device according to any one of claims 1 to 3, the polygon included in the input data is a two-dimensional matrix. A polygon arranged so as to be mapped to the polygon, and the means for extracting the shape of the polygon is a polygon that forms the object surface in the three-dimensional space from the polygon index corresponding to the arrangement location of the rectangle. Data representing a relative position is determined, and the coefficient acquisition unit determines a coefficient of an expression relating to the position of each polygon from the relative position of the polygon. According to the ninth aspect of the present invention, when the input polygon is a quadrangle arranged so as to be mapped to a two-dimensional matrix, the amount of input data and the amount of calculation for expansion processing are reduced. be able to.

また、本発明は、請求項10に記載のように、請求項4記載の物体表面平坦化装置において、前記共通の始点は、多角形の頂点のうちの一つであることを特徴とする。請求項10記載の発明によれば、多角形の形状を表すデータから、この頂点に関する2次元ベクトルのデータを一つ省略することができる。   According to a tenth aspect of the present invention, in the object surface flattening apparatus according to the fourth aspect, the common starting point is one of polygonal vertices. According to the tenth aspect of the present invention, one piece of two-dimensional vector data relating to this vertex can be omitted from the data representing the polygonal shape.

また、本発明は、請求項11に記載のように、多角形の集合体として表現された3次元空間内の物体表面を平面上に展開するためにコンピュータに、入力データから多角形の形状情報を抽出するステップと、前記多角形と辺を共有する周辺多角形の形状情報を抽出するステップと、前記多角形の形状情報および前記周辺多角形の形状情報から、前記平面上において前記多角形と前記周囲多角形との間で共有する辺間の距離についての関数を求め、前記関数に前記共有する辺間の距離が最小になるという条件を適用することにより、前記各多角形毎に、前記各多角形の位置を決定するための一次方程式を作成するステップと、前記各多角形の位置を決定するための一次方程式を解くことにより、前記各多角形の位置を算出するステップと、前記位置が算出された多角形を並べるステップとを有することを特徴とする。 Further, according to the present invention, the polygon shape information is input from the input data to the computer in order to develop the object surface in the three-dimensional space expressed as a collection of polygons on a plane. Extracting the shape information of the surrounding polygon that shares an edge with the polygon, the shape information of the polygon and the shape information of the surrounding polygon, and the polygon on the plane. By obtaining a function for the distance between sides shared with the surrounding polygon, and applying the condition that the distance between the shared sides is minimized to the function, and creating an equation for determining the position of each polygon by solving linear equations to determine the position of each polygon, and calculating the position of each polygon, the Characterized by a step of arranging a polygon location is calculated.

また、本発明のプログラムは、請求項11に記載のように、3次元空間内の物体表面を平面上に展開するためにコンピュータに、入力データから多角形の形状情報を抽出するステップと、前記多角形と辺を共有する周辺多角形の形状情報を抽出するステップと、前記多角形の形状情報および前記周辺多角形の形状情報から、前記各多角形毎に、前記各多角形の位置に関する式の係数を取得するステップと、前記各多角形の位置に関する式を解くことにより、前記各多角形の位置を算出するステップと、前記位置が算出された多角形を並べるステップとを実行させる。 The program of the present invention, as described in claim 11 , extracts a polygon shape information from input data to a computer in order to develop an object surface in a three-dimensional space on a plane, A step of extracting shape information of a neighboring polygon sharing a side with the polygon, and an expression relating to a position of each polygon for each of the polygons from the shape information of the polygon and the shape information of the surrounding polygon The step of obtaining the coefficient, the step of calculating the position of each polygon by solving the formula relating to the position of each polygon, and the step of arranging the polygons for which the positions have been calculated are executed.

請求項11記載の発明によれば、入力多角形の位置は多角形の位置に関する式を解くことにより決定し、入力多角形を平面上に並べることができる。これにより、3次元空間内の物体表面が多角形の集合体として表されている場合に、物体表面が展開不可能な場合であっても、多角形を平面上でできるだけ歪みが小さくなるように並べることができる。また、歪みの小さな展開図を作成するのに必要な測地線の距離を求める必要が無いため、測地線の距離を求めるための計算量を削減できる。 According to the eleventh aspect of the present invention, the position of the input polygon can be determined by solving a formula relating to the position of the polygon, and the input polygon can be arranged on a plane. As a result, when the object surface in the three-dimensional space is represented as a collection of polygons, even if the object surface cannot be expanded, the distortion of the polygon on the plane is minimized. Can be lined up. In addition, since it is not necessary to obtain the geodesic distance required to create a development with a small distortion, the amount of calculation for obtaining the geodesic distance can be reduced.

また、本発明は、請求項12に記載のように、請求項11記載のプログラムにおいて、更に、前記並べられた各多角形の形状を補正するステップを前記コンピュータに実行させることを特徴とする。請求項12記載の発明によれば、並べられた多角形間に重なりや隙間がある場合に、その多角形の形を補正して、重なりや隙間のない平面を作ることが可能になる。このプログラムは、通信回線や記録媒体を用いてコンピュータに提供することが可能である。 Further, according to a twelfth aspect of the present invention, in the program according to the eleventh aspect , the computer further causes the computer to execute a step of correcting the shapes of the arranged polygons. According to the twelfth aspect of the present invention, when there is an overlap or a gap between the arranged polygons, it is possible to correct the shape of the polygon to create a plane without the overlap or the gap. This program can be provided to a computer using a communication line or a recording medium.

また、請求項13記載の発明によれば、上記プログラムを記録したコンピュータ読み取り可能な記録媒体が提供される。 According to a thirteenth aspect of the present invention, there is provided a computer-readable recording medium on which the program is recorded.

本発明によれば、3次元空間内の物体表面が多角形の集合体として表されている場合に、物体表面が展開不可能な場合であっても、多角形を平面上でできるだけ歪みが小さくなるように並べることができる物体表面平坦化装置、物体表面平坦化方法およびプログラムを提供できる。   According to the present invention, when the object surface in the three-dimensional space is represented as an aggregate of polygons, even if the object surface cannot be expanded, the polygon is reduced as much as possible on the plane. It is possible to provide an object surface flattening apparatus, an object surface flattening method, and a program that can be arranged as follows.

以下、本発明を実施するための最良の形態について説明する。最初に、図1と図2を用いて本発明の原理を説明する。図1は多角形の辺共有を説明する図である。図2は多角形の頂点が2点に分割される場合を説明する図である。発明においては、3次元空間内の物体表面が多面体の集合で形成されているものとし、その多面体を構成する多角形の形状は予め分かっているものとする。上記多角形を2次元平面上に並べるときには、多角形間の重複や隙間が少なくなるように各多角形を回転したほうが良い場合がある。   Hereinafter, the best mode for carrying out the present invention will be described. First, the principle of the present invention will be described with reference to FIGS. FIG. 1 is a diagram for explaining side sharing of a polygon. FIG. 2 is a diagram for explaining a case where a vertex of a polygon is divided into two points. In the invention, it is assumed that the surface of an object in a three-dimensional space is formed by a set of polyhedrons, and the shape of a polygon constituting the polyhedron is known in advance. When arranging the polygons on a two-dimensional plane, there are cases where it is better to rotate the polygons so that there is less overlap or gap between the polygons.

しかしながら、本発明では、この多角形の回転の最適化は行わず、各多角形の平行移動のみの最適化を行うものである。図1に示すように、3次元曲面上で隣接する多角形は、辺を共有している。ここでは、一つの辺は、最大2つの多角形のみに共有されているものとする。たとえば図1においては辺511は多角形512および多角形513に共有されている。これらの多角形を平面に展開して並べたときも、この辺511は隣接する多角形間512および513で共有されるのが望ましい。   However, in the present invention, this polygon rotation is not optimized, and only the parallel movement of each polygon is optimized. As shown in FIG. 1, polygons adjacent on a three-dimensional curved surface share sides. Here, it is assumed that one side is shared only by a maximum of two polygons. For example, in FIG. 1, the side 511 is shared by the polygon 512 and the polygon 513. Even when these polygons are developed and arranged on a plane, the side 511 is preferably shared between the adjacent polygons 512 and 513.

しかしながら、展開不可能な表面の場合、2次元に展開する段階で、各多角形の相対的な位置関係が変化するため、多角形を隙間無く、かつ、重複無く並べることが不可能となる。その場合、図2に示されるように、この共有されるべき辺の位置が辺5110と辺5111の二つに分割してしまう。   However, in the case of a non-developable surface, the relative positional relationship between the polygons changes at the stage of two-dimensional development, making it impossible to arrange the polygons without gaps and without overlapping. In this case, as shown in FIG. 2, the position of the side to be shared is divided into two sides 5110 and 5111.

本発明は、これらの分割された二つの辺間の距離をできるだけ小さくするように多角形を並べることによって、歪みの小さな展開画像を作成しようとするものである。上記のように、本発明においては、測地線を求めたり、頂点を他の可展開面に投影したりすることなく、出力多角形から直接平面テクスチャ画像を生成することができる。以下、図面を用いて本発明の実施例について説明する。   The present invention intends to create a developed image with small distortion by arranging polygons so that the distance between the two divided sides is as small as possible. As described above, in the present invention, a planar texture image can be generated directly from an output polygon without obtaining a geodesic line or projecting a vertex onto another developable surface. Embodiments of the present invention will be described below with reference to the drawings.

図3は実施例1に係る物体表面平坦化装置100のブロック図である。図3に示されるように、物体表面平坦化装置100は、多角形スキャン部102、周囲多角形抽出部103、一次方程式作成部104、多角形位置演算部105、並べ合わせ部106、多角形形状補正部107を備える。   FIG. 3 is a block diagram of the object surface flattening apparatus 100 according to the first embodiment. As shown in FIG. 3, the object surface flattening device 100 includes a polygon scanning unit 102, a surrounding polygon extracting unit 103, a linear equation creating unit 104, a polygon position calculating unit 105, an alignment unit 106, a polygon shape A correction unit 107 is provided.

物体表面平坦化装置100は、コンピュータ上に表現された3次元空間内の物体表面を平面上に展開するものである。この物体表面平坦化装置100は、3次元形状モデリング装置(図示せず)などの外部装置から3次元空間内の物体表面の多角形を表現する入力データ101を受け取る。   The object surface flattening apparatus 100 develops an object surface in a three-dimensional space expressed on a computer on a plane. The object surface flattening device 100 receives input data 101 representing a polygon of an object surface in a three-dimensional space from an external device such as a three-dimensional shape modeling device (not shown).

多角形スキャン部102は、入力データ101から中心多角形の形状情報を抽出する。周囲多角形抽出部103は、多角形スキャン部102で抽出された中心多角形の周囲の多角形、すなわち、中心多角形と辺を共有する周辺多角形の形状情報を抽出する。一次方程式作成部104は、多角形スキャン部102で抽出された多角形の形状情報と周囲多角形抽出部103で抽出された周辺多角形の形状情報を基に、各多角形毎に、各多角形の位置に関する係数を含む一次方程式を作成する。一次方程式作成部104が特許請求の範囲における係数取得手段に相当する。   The polygon scanning unit 102 extracts shape information of the center polygon from the input data 101. The surrounding polygon extraction unit 103 extracts the polygon information around the center polygon extracted by the polygon scanning unit 102, that is, the shape information of the surrounding polygon sharing the side with the center polygon. Based on the polygon shape information extracted by the polygon scan unit 102 and the peripheral polygon shape information extracted by the surrounding polygon extraction unit 103, the linear equation creation unit 104 performs each polygon for each polygon. Create a linear equation that includes a coefficient for the position of the square. The linear equation creation unit 104 corresponds to a coefficient acquisition unit in the claims.

多角形位置演算部105は、この一次方程式を解くことにより、全多角形の位置を算出する。並べ合わせ部106は、多角形位置演算部105で算出された多角形位置に基づき、各多角形を並べる。多角形形状補正部107は、隙間や重複が無いように、並べられた各多角形の形状を補正し、最終的な出力データ108を出力する。   The polygon position calculation unit 105 calculates the positions of all polygons by solving this linear equation. The alignment unit 106 arranges the polygons based on the polygon positions calculated by the polygon position calculation unit 105. The polygon shape correction unit 107 corrects the shapes of the arranged polygons so that there are no gaps or overlaps, and outputs final output data 108.

次に、各構成の動作を詳しく述べる。まず、入力データ101について説明する。入力データ101は、3次元空間内の物体表面を構成する多角形の形状および多角形の相対位置情報を表すデータである。ここで、物体表面を構成する各多角形を示すインデクスをiとする。総数P個の多角形がある場合、例えば、その多角形に1からPまでの番号をインデクスとして付与することができる。また、物体表面の多角形の各辺を示すインデクスをhとする。総数Q個の辺がある場合、例えば、各辺に1からQまでの番号をインデクスとして付与することができる。通常、各辺は複数の多角形から共有されている。   Next, the operation of each component will be described in detail. First, the input data 101 will be described. The input data 101 is data representing the shape of a polygon forming the object surface in the three-dimensional space and the relative position information of the polygon. Here, an index indicating each polygon constituting the object surface is i. When there are a total of P polygons, for example, numbers from 1 to P can be assigned to the polygons as indexes. In addition, an index indicating each side of the polygon on the object surface is set as h. When there are a total of Q sides, for example, numbers from 1 to Q can be assigned to each side as an index. Normally, each side is shared from a plurality of polygons.

ここで、実施例1においては、物体表面の多角形に関して、以下の条件を持つものとする。図7の(a)は、ある多角形の頂点以外の辺上には、他の多角形の頂点が存在していない様子を示している。図7の(b)は、ある多角形の頂点以外の辺上に、他の多角形の頂点が存在している様子を示している。本実施例においては、全ての多角形の頂点以外の辺上には、他の多角形の頂点の存在を認めないという条件を課している。この条件は、一つの辺が最大2つの多角形にのみ共有されるという条件に等しい。   Here, in the first embodiment, it is assumed that the polygons on the object surface have the following conditions. FIG. 7A shows a state in which vertices of other polygons do not exist on sides other than the vertices of a certain polygon. FIG. 7B shows a state in which vertices of other polygons exist on sides other than the vertices of a certain polygon. In the present embodiment, a condition is imposed that the existence of vertices of other polygons is not allowed on sides other than the vertices of all polygons. This condition is equivalent to the condition that one side is shared only by a maximum of two polygons.

本実施例においては、まず、並べ合わせ部106で、各多角形の形状を保存したまま、多角形を平行移動し、2次元平面状で並べる。次に、多角形形状補正部107で、多角形の形状の補正を行う。すなわち、多角形形状補正部107の前までは、入力された多角形の形状は保存される。そのため、多角形の形状を示す部分と、多角形の位置を示す部分とに分割してデータを保持することが望ましい。そこで、今、多角形iは、N個の頂点k1,k2,…,kNを持つものとする。   In this embodiment, first, the arranging unit 106 translates the polygons while keeping the shape of each polygon, and arranges the polygons in a two-dimensional plane. Next, the polygon shape correction unit 107 corrects the polygon shape. That is, the input polygonal shape is stored before the polygonal shape correcting unit 107. For this reason, it is desirable to hold data by dividing it into a part indicating the polygonal shape and a part indicating the polygonal position. Therefore, it is assumed that the polygon i has N vertices k1, k2,..., KN.

さらに、本実施例では、多角形iの形状を、共通の始点から多角形の各頂点へのN個の2次元ベクトルaik(k=k1,k2,…,kN)を用いて表す。また、多角形iの位置は、2次元ベクトルviを用いて表す。共通の始点ベクトルが多角形の位置を表すベクトルに相当する。 Furthermore, in the present embodiment, the shape of the polygon i is represented using N two-dimensional vectors a ik (k = k1, k2,..., KN) from the common starting point to each vertex of the polygon. The position of the polygon i is expressed using a two-dimensional vector v i . The common starting point vector corresponds to a vector representing the position of the polygon.

図4は多角形形状および位置の説明図である。これら2種類のベクトルを用いることにより、図4に示されるように、2次元平面上で多角形iを並べたときの多角形iの各頂点の座標を、
i+aik(k=k1,k2,…,kN)
で表すこととする。
FIG. 4 is an explanatory diagram of polygonal shapes and positions. By using these two types of vectors, as shown in FIG. 4, the coordinates of each vertex of the polygon i when the polygon i is arranged on a two-dimensional plane are
v i + a ik (k = k1, k2,..., kN)
It shall be expressed as

これらの頂点kは、3次元空間内では複数の多角形で共有されていたものである。しかしながら、2次元平面上では、同じ頂点kであっても、多角形iの頂点kの位置は、
i+aik
であり、多角形jの頂点kの位置は、
j+ajk
となり、別の位置に存在することになる。同様に各頂点を端点とする各辺も、3次元空間内では共有されていても、2次元平面上では共有されず、別の辺となる。
These vertices k are shared by a plurality of polygons in the three-dimensional space. However, on the two-dimensional plane, the position of the vertex k of the polygon i is the same vertex k.
v i + a ik
And the position of the vertex k of the polygon j is
v j + a jk
And will be in a different location. Similarly, each side having each vertex as an end point is not shared on the two-dimensional plane but is another side even if shared in the three-dimensional space.

さて、このように、多角形の各頂点の座標を指定することにより、多角形の形状を保存しながら多角形の位置だけを平行移動させたい場合には、多角形iの形状を示すベクトルaikは変化させないで、多角形iの位置を示すベクトルviのみを変化させれば良い。入力データ101は、このようにして定めた多角形形状に関するデータ、すなわち、aikを持つものとする。さらに、入力データ101内には、3次元空間内の物体表面を構成する多角形の相対位置情報を表すデータが含まれる。この相対位置情報に関するデータは、周囲多角形抽出部103において使用されるものである。上記相対位置情報は、以下に示す(情報1)、(情報2)、および、(情報3)である。 Now, by designating the coordinates of each vertex of the polygon as described above, when it is desired to translate only the position of the polygon while preserving the shape of the polygon, a vector a indicating the shape of the polygon i. It is only necessary to change the vector v i indicating the position of the polygon i without changing ik . It is assumed that the input data 101 has data regarding the polygonal shape thus determined, that is, a ik . Further, the input data 101 includes data representing the relative position information of polygons constituting the object surface in the three-dimensional space. The data regarding the relative position information is used in the surrounding polygon extraction unit 103. The relative position information is (Information 1), (Information 2), and (Information 3) shown below.

(情報1)3次元空間内の物体表面を構成する多角形の各辺に対し、各辺をどの多角形が共有しているかを示す、辺を共有する多角形のインデクスのデータである。例えば、各辺を示すインデクスをhとするとき、辺hを共有する多角形の集合Fhである。
(情報2)各辺の両端の頂点インデクスのデータである。例えば、各辺を示すインデクスをhとするとき、辺hの両端の頂点インデクスの集合Ghである。
(情報3)3次元空間内の物体表面を構成する各多角形にはどの辺が存在しているかを示す、多角形の辺のインデクスのデータである。例えば、各多角形を示すインデクスをiとするとき、多角形iの辺のインデクスの集合Hiである。
(Information 1) Polygon index data sharing sides indicating which polygons share each side with respect to each side of the polygon forming the object surface in the three-dimensional space. For example, when the index indicating each side is h, it is a polygon set Fh sharing the side h.
(Information 2) Data of vertex indexes at both ends of each side. For example, when the index indicating each side is h, it is a set Gh of vertex indexes at both ends of the side h.
(Information 3) Polygon side index data indicating which side exists in each polygon constituting the object surface in the three-dimensional space. For example, when the index indicating each polygon is i, it is a set Hi of the indices of the sides of the polygon i.

(情報1)と(情報3)は相互に変換可能であるため、どちらか一つだけを保持すればよい。しかしながら、上記の相互変換の計算量が多い場合には、(情報1)と(情報3)の両方を保持してももちろん良い。あるいは、多角形が規則的に並んでいて、多角形インデクスから、多角形の相対位置情報、すなわち、上記の(情報1)や(情報2)や(情報3)が容易に求められる場合には、上記相対位置情報は特に入力データ101に含まれる必要は無い。   Since (Information 1) and (Information 3) can be converted to each other, only one of them needs to be held. However, when the amount of calculation of the above mutual conversion is large, it is of course possible to hold both (information 1) and (information 3). Alternatively, when polygons are regularly arranged and the relative position information of the polygon, that is, (Information 1), (Information 2), and (Information 3) described above can be easily obtained from the polygon index. The relative position information need not be included in the input data 101.

さらに、図4に示されるように、各頂点の位置は、ベクトルviの終点から、各ベクトルaikを伸ばすことによって得られる。ベクトルviの終点と、多角形iの位置関係は任意であるため、多角形iの位置とベクトルviの終点の位置を予め固定しておくことにより、aik(k=k1,k2,…,kN)のうち、一つのベクトルを入力データ101として持つことを省略することが可能である。例えば、多角形iの位置を示すベクトルaikの共通の始点を、多角形iの頂点k1であるとする。つまり、常に、aik1=0とする。このようにすることで、aik1を入力データとして保持する必要が無くなる。よって、頂点に関する2次元ベクトルのデータを一つ省略することができる。これは一つの例であり、他の例として、例えば、多角形iの重心をベクトルviの終点とする、といった規定をとってももちろん良い。以上で入力データ101の説明を終わる。 Further, as shown in FIG. 4, the position of each vertex is obtained by extending each vector a ik from the end point of the vector v i . Since the positional relationship between the end point of the vector v i and the polygon i is arbitrary, by fixing the position of the polygon i and the end point of the vector v i in advance, a ik (k = k1, k2, .., KN), it is possible to omit having one vector as input data 101. For example, it is assumed that the common starting point of the vector a ik indicating the position of the polygon i is the vertex k1 of the polygon i. In other words, a ik1 = 0 is always set. In this way, it is not necessary to hold a ik1 as input data. Therefore, one piece of two-dimensional vector data related to the vertex can be omitted. This is one example, and as another example, for example, it may of course be provided that the centroid of the polygon i is the end point of the vector v i . This is the end of the description of the input data 101.

次に、多角形スキャン部102および周囲多角形抽出部103の説明を行う。多角形スキャン部102では、入力された多角形を一つ一つ全て抽出する。ここで、多角形スキャン部102で多角形iが抽出されたとする。周囲多角形抽出部103では、多角形iと辺を共有する多角形を全て抽出する。これで、多角形スキャン部102および周囲多角形抽出部103の説明を終わる。   Next, the polygon scanning unit 102 and the surrounding polygon extracting unit 103 will be described. The polygon scanning unit 102 extracts all the input polygons one by one. Here, it is assumed that the polygon i is extracted by the polygon scanning unit 102. The surrounding polygon extraction unit 103 extracts all polygons that share sides with the polygon i. This concludes the description of the polygon scanning unit 102 and the surrounding polygon extracting unit 103.

次に、一次方程式作成部104の説明を行う。一次方程式作成部104は、多角形を2次元平面上に並べたとき、ある中心多角形と、この中心多角形と辺を共有する周辺多角形との間で、共有すべき辺間の距離の和が最小になるような中心多角形と周辺多角形との相対位置を示す一次方程式の係数を作成する。ここでは、以下の距離関数を定義し、この距離関数が最小になるような多角形位置ベクトルviを求めることによって、多角形位置を決定する。 Next, the linear equation creation unit 104 will be described. When the polygons are arranged on a two-dimensional plane, the linear equation creating unit 104 determines the distance between the sides to be shared between a certain center polygon and the neighboring polygons sharing the side with the center polygon. A coefficient of a linear equation indicating the relative position between the central polygon and the peripheral polygon that minimizes the sum is created. Here, the following distance function is defined, and the polygon position is determined by obtaining a polygon position vector v i that minimizes the distance function.

まず、各頂点を示すインデクスをk、各辺を示すインデクスをh、各多角形を示すインデクスをiとする。さらに、(情報1)、(情報2)、および、(情報3)に示されるように、辺hを共有する多角形のインデクスの集合(多角形インデクス集合)をFh、辺hの両端の頂点のインデクスの集合(頂点インデクス集合)をGh、多角形iの辺のインデクスの集合(辺インデクス集合)をHiとする。   First, an index indicating each vertex is k, an index indicating each side is h, and an index indicating each polygon is i. Furthermore, as shown in (Information 1), (Information 2), and (Information 3), Fh is a set of polygonal indexes sharing the side h (polygonal index set), and vertices at both ends of the side h A set of indices (vertex index set) is Gh, and a set of indexes on the sides of the polygon i (side index set) is Hi.

ここで、辺hを共有する多角形のインデクスの集合Fhについて図5を用いて説明する。図5は多角形インデクス集合Fhの説明図である。例えば、3次元空間内の物体表面で、図5に示すように、辺hを多角形1と多角形2が共有しているとする。このとき、多角形インデクス集合は、
Fh={1,2}
である。また、図5のように、辺hの両端の頂点のインデクスが4と5であるとき、頂点インデクス集合は、
Gh={4,5}
である。
Here, a set Fh of polygonal indexes sharing the side h will be described with reference to FIG. FIG. 5 is an explanatory diagram of the polygonal index set Fh. For example, assume that polygon 1 and polygon 2 share side h on the surface of an object in a three-dimensional space, as shown in FIG. At this time, the polygon index set is
Fh = {1, 2}
It is. Also, as shown in FIG. 5, when the indices of the vertices at both ends of the side h are 4 and 5, the vertex index set is
Gh = {4,5}
It is.

次に、多角形iの辺のインデクスの集合をHiについて図6を用いて説明する。図6は、辺インデクス集合Hiの説明図である。図6に示すように、多角形iが辺1、2、3、4、5、6を持ち、その他の辺や頂点は持っていないとする。このとき、辺インデクス集合は、
Hi={1,2,3,4,5,6}
である。
Next, a set of indexes on the side of the polygon i will be described with reference to FIG. FIG. 6 is an explanatory diagram of the edge index set Hi. As shown in FIG. 6, it is assumed that the polygon i has sides 1, 2, 3, 4, 5, and 6 and has no other sides or vertices. At this time, the edge index set is
Hi = {1, 2, 3, 4, 5, 6}
It is.

ここで、ある辺hが、2次元平面上で、辺h1と辺h2に分割されたときの、辺h1、辺h2間の距離関数を図8を用いて説明する。図8は距離関数を説明するための図である。図8において、多角形1と多角形2は、3次元空間内では隣接しており、そのときの、頂点k11とk21は同じ位置に存在していた。かつ、頂点k12と頂点k22も同じ位置に存在していたとする。2次元平面上では、辺h1と辺h2が一致しない場合がある。その場合の辺h1と辺h2の距離を以下の式(1)で定義する。
(頂点k11と頂点k21間の距離の2乗+頂点k12と頂点k22の距離の2乗)×(辺h1の長さ+辺h2の長さ)/2 (1)
この辺間の距離は、共有すべき頂点間の距離の2乗和に辺の長さを乗じたものであり、同じ位置にあるべき頂点間の距離の2乗和を、共有すべき辺の長さで重み付けした距離であるということができる。上記の頂点k11とk21や、頂点k12とk22が離れた位置にあるときの影響は、辺h1や辺h2の長さに比例すると考えられるからである。
Here, a distance function between the side h1 and the side h2 when a side h is divided into the side h1 and the side h2 on the two-dimensional plane will be described with reference to FIG. FIG. 8 is a diagram for explaining the distance function. In FIG. 8, polygon 1 and polygon 2 are adjacent in the three-dimensional space, and vertices k11 and k21 at that time exist at the same position. In addition, it is assumed that the vertex k12 and the vertex k22 exist at the same position. On the two-dimensional plane, the side h1 and the side h2 may not match. In this case, the distance between the side h1 and the side h2 is defined by the following formula (1).
(Square of distance between vertex k11 and vertex k21 + square of distance between vertex k12 and vertex k22) × (length of side h1 + length of side h2) / 2 (1)
The distance between the sides is obtained by multiplying the square sum of the distances between the vertices to be shared by the length of the side, and the square sum of the distances between the vertices that should be at the same position is the length of the side to be shared. It can be said that the distance is weighted by the distance. This is because the influence when the vertices k11 and k21 and the vertices k12 and k22 are separated is considered to be proportional to the lengths of the side h1 and the side h2.

さらに、以下、上記で述べた距離関数を定式化する。辺hを共有する多角形の集合はFhである。Fhの各要素である多角形インデクスをiとする。すなわち、i∈Fhとする。さらに、辺hの両端の頂点インデクスをkとすると、k∈Ghである。また、2次元平面に展開したときの多角形iの頂点kの位置を示す位置ベクトルは、
i+aik
である。
Furthermore, the distance function described above is formulated below. A set of polygons sharing side h is Fh. Let i be the polygon index which is each element of Fh. That is, iεFh. Further, kεGh, where k is the vertex index at both ends of the side h. The position vector indicating the position of the vertex k of the polygon i when expanded on a two-dimensional plane is
v i + a ik
It is.

全てのi(i∈Fh)、k(k∈Gh)で、上記の位置ベクトルが同じになることが理想であるが、展開不可能な物体表面では誤差が生じる。すなわち、多角形i(i∈Fh)の頂点k(k∈Gh)の位置ベクトルvi+aikと、多角形j(j∈Fh,j≠i)の頂点k(k∈Gh)の位置ベクトルvj+ajkは、異なる場合がある。ここで、頂点k(k∈Gh)に関する誤差の2乗和を、辺hの長さで重み付けした値を辺hの距離関数Ehとする。この辺hの距離関数Ehは以下の式(2)のように表すことができる。 Ideally, the position vector is the same for all i (i∈Fh) and k (k∈Gh), but an error occurs on the surface of an object that cannot be developed. That is, the position vector v i + a ik of the vertex k (k∈Gh) of the polygon i (i∈Fh) and the position vector of the vertex k (k∈Gh) of the polygon j (j∈Fh, j ≠ i). v j + a jk may be different. Here, a value obtained by weighting the sum of squares of the error regarding the vertex k (kεGh) by the length of the side h is defined as a distance function Eh of the side h. The distance function Eh of the side h can be expressed as the following formula (2).

Figure 0004325469
ただし、
Figure 0004325469
However,

Figure 0004325469
とする。ここで、i=jの時には、(vi+aik)−(vj+ajk)=0であるので、(2)式は、
Figure 0004325469
And Here, when i = j, (v i + a ik ) − (v j + a jk ) = 0, so equation (2) is

Figure 0004325469
とできる。次に、全辺に渡って、Ehを加算したものが、全体の距離関数Eである。
Figure 0004325469
And can. Next, the total distance function E is obtained by adding Eh over the entire side.

Figure 0004325469
ここで、距離関数Eは、viの2次形式であり、2次の項の係数は正であるので、全ての多角形インデクスiに関して、
Figure 0004325469
Here, the distance function E is a quadratic form of v i and the coefficient of the quadratic term is positive.

Figure 0004325469
となるviが、距離関数Eを最小化する多角形の位置ベクトルとなる。そこで、i=mの時の最小化条件を求める。
Figure 0004325469
V i becomes a polygonal position vector that minimizes the distance function E. Therefore, the minimization condition when i = m is obtained.

Figure 0004325469
よって、i=mの時の最小化条件は、
Figure 0004325469
Therefore, the minimization condition when i = m is

Figure 0004325469
とできる。(8)式を変形すると、以下のようになる。
Figure 0004325469
And can. When the equation (8) is modified, it becomes as follows.

Figure 0004325469
(9)式は、vi(i=m,j、ただし、h∈Hm,j∈Fh,かつ,k∈Gh)の一次式である。
Figure 0004325469
Expression (9) is a linear expression of v i (i = m, j, where h∈Hm, j∈Fh, and k∈Gh).

一次方程式作成部104では、多角形スキャン部102で抽出された多角形mおよび、周囲多角形抽出部103で抽出された多角形mの周囲の多角形j(h∈Hm、かつ、j∈Fh)の形状情報から、一次方程式(9)の係数を作成する。上記で示される形状情報とは、amk(k∈Gh、h∈Hm)および、ajk(j∈Fh、k∈Gh、h∈Hm)のことである。また、上記(9)式は、2次元ベクトルの式ではあるが、2次元ベクトルの各要素ごとに演算をすることによって、通常のスカラー値と同じように方程式を作ることができる。 In the primary equation creation unit 104, the polygon m extracted by the polygon scanning unit 102 and the polygon j around the polygon m extracted by the surrounding polygon extraction unit 103 (h∈Hm and j∈Fh). ) Of the linear equation (9) is created from the shape information. The shape information shown above is a mk (k∈Gh, h∈Hm) and a jk (j∈Fh, k∈Gh, h∈Hm). Further, although the above equation (9) is a two-dimensional vector equation, an equation can be created in the same manner as a normal scalar value by performing an operation for each element of the two-dimensional vector.

以上のように、多角形mに関する一次方程式を作ることができた。多角形スキャン部102では、全ての多角形をスキャンする。その結果、一次方程式作成部104では、全ての多角形iに関する一次方程式を作ることができる。   As described above, a linear equation related to the polygon m could be made. The polygon scanning unit 102 scans all polygons. As a result, the linear equation creation unit 104 can create linear equations for all polygons i.

ここで、我々が求めようとしている未知情報は、viである。ここで、多角形の数をNとすると、未知数は、v1,v2,…,vNのN個である。(実際には、viは2次元ベクトルであるので、未知スカラー値は2×Nであるが、ここではベクトルを一つの数として扱い、未知数をNとして表記した)。また、一つの多角形mに対して、(9)式に示される一次方程式を作ることができる。多角形数はNであるので、N個の一次方程式を作成することができる。この連立一次方程式を以下のように行列を用いて表すことができる。
Ax=b (10)
Aは係数行列であり、(9)式のうち以下に示す部分から計算できる。
Here, the unknown information that we are seeking is v i . Here, if the number of polygons is N, there are N unknowns v 1 , v 2 ,..., V N. (In fact, since v i is a two-dimensional vector, the unknown scalar value is 2 × N, but here the vector is treated as one number and the unknown is represented as N). In addition, a linear equation represented by equation (9) can be created for one polygon m. Since the number of polygons is N, N linear equations can be created. This simultaneous linear equation can be expressed using a matrix as follows.
Ax = b (10)
A is a coefficient matrix, and can be calculated from the following part of equation (9).

Figure 0004325469
AはN×Nの行列である。
xはN行1列の未知ベクトルであり、(v1(u),v2(u),…,vN(u))Tである。
Figure 0004325469
A is an N × N matrix.
x is an unknown vector of N rows and 1 column, and is (v 1 (u), v 2 (u),..., v N (u)) T.

ここで、vi(u)はベクトルviの第u成分を示す(u=1,2)。さらに、bは、以下に示すN行1列の既知ベクトルである。これを式(12)に示す。 Here, v i (u) represents the u-th component of vector v i (u = 1, 2). Further, b is a known vector of N rows and 1 column shown below. This is shown in equation (12).

Figure 0004325469
ここで、(10)式のAは実は特異行列であり、逆行列を持たない。そのためこのままでは(10)式を解くことができない。これは、(9)式あるいは、(10)式が多角形の位置ベクトルvi各々の相対値のみを規定しているためである。何らかの方法によって、絶対的な位置を指定する必要がある。たとえば、インデクスが1の多角形の位置ベクトルの値を、v1=0とすることによって、(10)式を解くことが可能となる。このとき、(10)式の係数行列Aの第1列の数値は任意となる。そこで、行列Aから第1列を抜いたN行(N−1)列の行列をBとする。v1=0としたとき、(10)式は
Bx=b (13)
となる。
以上で、一次方程式作成部104の説明を終える。
Figure 0004325469
Here, A in the equation (10) is actually a singular matrix and has no inverse matrix. Therefore, equation (10) cannot be solved as it is. This is because (9) or (10) defines only the relative value of each of the polygonal position vectors v i . It is necessary to specify an absolute position by some method. For example, by setting the value of the position vector of a polygon with an index of 1 to v 1 = 0, it is possible to solve equation (10). At this time, the numerical value in the first column of the coefficient matrix A in the equation (10) is arbitrary. Therefore, a matrix of N rows (N−1) columns obtained by removing the first column from the matrix A is defined as B. When v 1 = 0, the equation (10) is expressed as Bx = b (13)
It becomes.
This is the end of the description of the primary equation creation unit 104.

次に、多角形位置演算部105で式(13)の解を求める。多角形位置演算部105では、未知数がN−1で式の数がNの連立一次方程式(13)を解くことになる。方程式(13)は、最小二乗法を用いて解けばよい。例えば、
x=(BTB)-1T
などとして解くことができる。
Next, the polygon position calculation unit 105 calculates a solution of Expression (13). Polygon position calculation unit 105 solves simultaneous linear equation (13) in which the unknown number is N-1 and the number of equations is N. Equation (13) may be solved using the least square method. For example,
x = (B T B) −1 B T b
And so on.

これにより、多角形の位置は、連立一次方程式を最小二乗法で解くという公知の手法を用いて計算することができる。以上で多角形位置演算部105の説明を終える。   Thereby, the position of the polygon can be calculated using a known method of solving simultaneous linear equations by the least square method. This is the end of the description of the polygon position calculation unit 105.

次に並べ合わせ部106の説明を行う。並べ合わせ部106では、多角形位置演算部105で求められた多角形位置viと、既知である多角形形状aik、および、多角形の相対位置情報を基に、多角形の並べ合わせを行う。ここで、多角形相対位置情報として、既に述べた(情報2)を保持しているものとする。すなわち、各多角形インデクスiに対して、多角形iの頂点インデクスの集合Giが分かっているものとする。このような条件の下で、各多角形の各頂点の座標は、(i=1,2,…,N)として、
i+aik (i=1,2,…,N、かつ、k∈Gi)
として求めることができる。以上で並べ合わせ部106の説明を終える。
Next, the alignment unit 106 will be described. The alignment unit 106 performs polygon alignment based on the polygon position v i obtained by the polygon position calculation unit 105, the known polygon shape a ik , and the relative position information of the polygon. Do. Here, it is assumed that (information 2) already described is held as polygon relative position information. That is, for each polygon index i, the vertex index set Gi of the polygon i is known. Under such conditions, the coordinates of each vertex of each polygon are (i = 1, 2,..., N),
v i + a ik (i = 1, 2,..., N and kεGi)
Can be obtained as This completes the description of the alignment unit 106.

次に、多角形形状補正部107の動作および出力データ108を説明する。ある頂点kは、複数の多角形で共有されるべきであるにも関わらず、並べ合わせ部106で多角形を並べた結果、各多角形の頂点kの座標が異なる場合が存在する。このままでは、並べ合わせた多角形の隙間や重複が存在するので、その隙間や重複を無くすように、多角形形状を補正する。実際には、頂点座標の補正を行う。各頂点kに対して、以下の処理を行う。すなわち、頂点kの座標ベクトルxkを各多角形に属する頂点kの重心として、以下のように決定する。 Next, the operation of the polygon shape correcting unit 107 and the output data 108 will be described. Although a certain vertex k should be shared by a plurality of polygons, there is a case where the coordinates of the vertex k of each polygon are different as a result of arranging the polygons by the aligning unit 106. In this state, since there are gaps and overlaps between the arranged polygons, the polygonal shape is corrected so as to eliminate the gaps and overlaps. Actually, the vertex coordinates are corrected. The following processing is performed for each vertex k. That is, the coordinate vector x k of the vertex k is determined as the center of gravity of the vertex k belonging to each polygon as follows.

Figure 0004325469
ここで、Jkは、頂点kを共有する多角形インデクスの集合であり、|Jk|は、集合Jkの要素数を示す。この頂点座標xkが出力データ108である。あるいは、出力データ108は、頂点座標ではなくて、多角形位置viと、補正された多角形形状a’ikとする場合も考えられる。この場合、多角形形状補正部107では、補正された多角形形状a’ikの計算を以下のように行えば良い。
a’ik=xk−vi
以上で、多角形形状補正部107の動作および出力データ108の説明を終える。これで、実施例1の動作の説明を終える。
Figure 0004325469
Here, Jk is a set of polygon indexes sharing the vertex k, and | Jk | indicates the number of elements of the set Jk. This vertex coordinate x k is the output data 108. Alternatively, the output data 108 may be a polygon position v i and a corrected polygon shape a ′ ik instead of the vertex coordinates. In this case, the polygon shape correcting unit 107 may calculate the corrected polygon shape a ′ ik as follows.
a ′ ik = x k −v i
This is the end of the description of the operation of the polygonal shape correcting unit 107 and the output data 108. This completes the description of the operation of the first embodiment.

実施例1によれば、入力多角形の位置は多角形の位置に関する式を解くことにより決定し、入力多角形を平面上に並べることができる。これにより、3次元空間内の物体表面が多角形の集合体として表されている場合に、物体表面が展開不可能な場合であっても、多角形を平面上でできるだけ歪みが小さくなるように並べることができる。また、歪みの小さな展開図を作成するのに必要な測地線の距離を求める必要が無いため、測地線の距離を求めるための計算量を削減できる。   According to the first embodiment, the position of the input polygon can be determined by solving an expression related to the position of the polygon, and the input polygon can be arranged on a plane. As a result, when the object surface in the three-dimensional space is represented as a collection of polygons, even if the object surface cannot be expanded, the distortion of the polygon on the plane is minimized. Can be lined up. In addition, since it is not necessary to obtain the geodesic distance required to create a development with a small distortion, the amount of calculation for obtaining the geodesic distance can be reduced.

次に、実施例2について説明する。実施例1では、物体表面が一般の多角形で構成されている場合について説明した。実施例2では、特に、物体表面が凸四角形で構成されている場合に関して、説明を行う。また、実施例2は、多角形が規則的に並んでいて、多角形インデクスから、多角形の相対位置情報、すなわち、前記の(情報1)、(情報2)、あるいは(情報3)が容易に求められる場合の例を述べるものである。   Next, Example 2 will be described. In the first embodiment, the case where the object surface is formed of a general polygon has been described. In the second embodiment, the case where the object surface is formed of a convex quadrangle will be described. Further, in the second embodiment, polygons are regularly arranged, and the relative position information of the polygons, that is, the above (Information 1), (Information 2), or (Information 3) is easy from the polygon index. An example in the case where it is required is described.

さらに、本実施例2は、多角形iの座標と多角形iの位置ベクトルviの終点との位置関係を明確にした例を示すものである。さらに、本実施例2でも、実施例1と同様に、全ての多角形の頂点以外の辺上には、他の多角形の頂点の存在を認めないという条件を課す。以下、本実施例の説明を具体的に行う。 Further, the second embodiment shows an example in which the positional relationship between the coordinates of the polygon i and the end point of the position vector v i of the polygon i is clarified. Furthermore, also in the second embodiment, as in the first embodiment, a condition is imposed that the existence of vertices of other polygons is not allowed on sides other than the vertices of all polygons. Hereinafter, the present embodiment will be specifically described.

図9は、物体の表面の四角形が規則正しく並んでいる様子の説明図である。本実施例では、図9に示されるように、物体表面を構成する四角形が、2次元配列の行と列に対応するように、規則正しく並んでいることを前提とする。図9の四角形内に書かれた数字はその四角形(多角形)のインデクスを示す。例えば多角形(四角形)1、2、3、4は第1行、多角形(四角形)2、6、10、14は第2列などといった、2次元配列へのマッピングが可能なように配列されている。   FIG. 9 is an explanatory diagram showing a state in which the rectangles on the surface of the object are regularly arranged. In the present embodiment, as shown in FIG. 9, it is assumed that the rectangles forming the object surface are regularly arranged so as to correspond to the rows and columns of the two-dimensional array. The numbers written in the rectangle in FIG. 9 indicate the index of the rectangle (polygon). For example, polygons (squares) 1, 2, 3, 4 are arranged in a first row, polygons (squares) 2, 6, 10, 14 are arranged in a two-dimensional array such that they can be mapped into a second column, etc. ing.

この場合、多角形スキャン部102は、四角形の配置場所に対応した多角形インデクスが分かれば、その多角形の周囲多角形のインデクスや、その多角形の頂点インデクスを簡単に求めることができるため、実施例1で述べたような3次元空間内の物体表面を構成する多角形の相対位置を表すデータ、すなわち、(情報1)や、(情報2)や、(情報3)を決定することができるため、これらの情報を入力データとして特に持つ必要がない。これらの情報を持ってももちろん構わない。   In this case, if the polygon scanning unit 102 knows the polygon index corresponding to the square arrangement location, the polygon scanning unit 102 can easily obtain the polygon index around the polygon and the vertex index of the polygon. It is possible to determine data representing the relative positions of polygons constituting the object surface in the three-dimensional space as described in the first embodiment, that is, (information 1), (information 2), and (information 3). Therefore, it is not necessary to have such information as input data. Of course, you can have this information.

図10は、物体表面の四角形が規則正しく並んでいない様子の説明図である。ところが、図10に示されるような四角形の位置関係では、各四角形を2次元配列にマッピングすることができないため、本実施例の適用外となる。すなわち、本実施例2は、実施例1の条件を狭くし、さらに具体的にして、分かりやすいように説明するものである。   FIG. 10 is an explanatory diagram showing a state in which the rectangles on the object surface are not regularly arranged. However, in the positional relationship of the quadrangle as shown in FIG. 10, each quadrangle cannot be mapped to a two-dimensional array, and thus this example is not applicable. That is, in the second embodiment, the conditions of the first embodiment are narrowed, more specifically, and will be described in an easy-to-understand manner.

さて、本実施例2においても、式(9)を用いて一次方程式を作成する。図11は実施例2の動作説明図である。ここで、簡単のために、図11に示されるように、多角形スキャン部102で抽出された多角形インデクスが0、周囲多角形抽出部103で抽出された多角形インデクスが1〜4であるとする。また、図11に示すように、辺インデクスを1〜4、頂点インデクスを1〜4とする。このとき、式(9)において、m=0、Hm=H0={1,2,3,4}、F1={0,1}、F2={0,2}、F3={0,3}、F4={0,4}となり、また、G1={1,3}、G2={2,4}、G3={1,2}、G4={3,4}となる。   Now, also in the present Example 2, a linear equation is created using Formula (9). FIG. 11 is a diagram for explaining the operation of the second embodiment. Here, for simplicity, as shown in FIG. 11, the polygon index extracted by the polygon scan unit 102 is 0, and the polygon index extracted by the surrounding polygon extraction unit 103 is 1 to 4. And Also, as shown in FIG. 11, the edge index is 1 to 4 and the vertex index is 1 to 4. At this time, in equation (9), m = 0, Hm = H0 = {1,2,3,4}, F1 = {0,1}, F2 = {0,2}, F3 = {0,3} , F4 = {0,4}, and G1 = {1,3}, G2 = {2,4}, G3 = {1,2}, G4 = {3,4}.

図12は実施例2の他の動作例を説明する図である。さらに、図12に示すように、2次元平面にマッピングするときの、各多角形1〜5の辺の長さを測定する。図12に示すように、多角形0の辺1の長さをL1、多角形1の辺1の長さをL1’とする。同様に、多角形0の辺2の長さをL2、多角形2の辺2の長さをL2’多角形0の辺3の長さをL3、多角形3の辺3の長さをL3’多角形0の辺4の長さをL4、多角形4の辺4の長さをL4’とする。ここで、LiとLi’の値は異なる値でも構わない。以上の条件下で、各辺の長さは、
L(1)=(L1+L1’)/2、
L(2)=(L2+L2’)/2、
L(3)=(L3+L3’)/2、
L(4)=(L4+L4’)/2
となる。このとき(9)式は、以下の(15)式に示すようになる。
2×{L(1)+L(2)+L(3)+L(4)}×v1
-2×L(1)×v1
-2×L(2)×v2
-2×L(3)×v3
-2×L(4)×v4

-{L(1)+L(3)}×a01-{L(3)+L(2)}×a02-{L(4)+L(1)}×a03-{L(2)+L(4)}×a04
+L(1)×(a11+a13)+L(2)×(a22+a24)+L(3)×(a31+a32)+L(4)×(a44+a43) (15)
となる。
FIG. 12 is a diagram for explaining another operation example of the second embodiment. Further, as shown in FIG. 12, the lengths of the sides of the polygons 1 to 5 are measured when mapping to a two-dimensional plane. As shown in FIG. 12, the length of the side 1 of the polygon 0 is L1, and the length of the side 1 of the polygon 1 is L1 ′. Similarly, the length of side 2 of polygon 0 is L2, the length of side 2 of polygon 2 is L2 ', the length of side 3 of polygon 0 is L3, and the length of side 3 of polygon 3 is L3. 'The length of the side 4 of the polygon 0 is L4, and the length of the side 4 of the polygon 4 is L4'. Here, the values of Li and Li ′ may be different values. Under the above conditions, the length of each side is
L (1) = (L1 + L1 ') / 2
L (2) = (L2 + L2 ') / 2,
L (3) = (L3 + L3 ') / 2,
L (4) = (L4 + L4 ') / 2
It becomes. At this time, the equation (9) becomes as shown in the following equation (15).
2 × {L (1) + L (2) + L (3) + L (4)} × v 1
-2 × L (1) × v 1
-2 × L (2) × v 2
-2 × L (3) × v 3
-2 × L (4) × v 4
=
-{L (1) + L (3)} × a 01- {L (3) + L (2)} × a 02- {L (4) + L (1)} × a 03- {L (2 ) + L (4)} × a 04
+ L (1) × (a 11 + a 13 ) + L (2) × (a 22 + a 24 ) + L (3) × (a 31 + a 32 ) + L (4) × (a 44 + a 43 ) (15)
It becomes.

係数行列Aは、各行の所定の列(各ベクトルviに相当する位置)に、係数2×{L(1)+L(2)+L(3)+L(4)}、あるいは、−2×L(h)を入れ、その他の位置に0を入れることによって作ることができる。本実施例2においては、上記の係数2×{L(1)+L(2)+L(3)+L(4)}、あるいは、−2×L(h)は、多角形に限らず同じであるため(どのベクトルの係数になるかは異なるが)、中心の多角形と周囲の多角形の相対位置さえわかれば、直ぐに選択することができるので、その都度計算を行う必要はない。このため、多角形位置演算部105は、多角形の相対位置から、各多角形の位置に関する一次方程式の係数を決定することができる。 The coefficient matrix A has a coefficient 2 × {L (1) + L (2) + L (3) + L (4)} or −2 × L at a predetermined column (position corresponding to each vector v i ) in each row. It can be made by putting (h) and putting 0 in other positions. In the second embodiment, the coefficient 2 × {L (1) + L (2) + L (3) + L (4)} or −2 × L (h) is the same regardless of the polygon. For this reason (which vector coefficient is different), it is not necessary to calculate each time because it can be selected immediately if the relative positions of the center polygon and the surrounding polygon are known. For this reason, the polygon position calculation part 105 can determine the coefficient of the linear equation regarding the position of each polygon from the relative position of a polygon.

また、実施例1でも述べたが、ベクトルviの終点と各多角形の位置関係は任意であるため、各四角形iの左下の頂点の座標をベクトルviの終点に一致させても良い。この場合、a01=a22=a43=0のように固定することができるので、入力データ101のデータ量を省略できる。このとき、式(15)は、以下の式(16)に示すようになる。
2×{L(1)+L(2)+L(3)+L(4)}×v1
-2×L(1)×v1
-2×L(2)×v2
-2×L(3)×v3
-2×L(4)×v4

-{L(3)+L(2)}×a02-{L(4)+L(1)}×a03-{L(2)+L(4)}×a04
+L(1)×(a11+a13)+L(2)×(a24)+L(3)×(a31+a32)+L(4)×(a44) (16)
となる。
As described in the first embodiment, since the positional relationship between the end point of the vector v i and each polygon is arbitrary, the coordinates of the lower left vertex of each quadrilateral i may be matched with the end point of the vector v i . In this case, since it can be fixed as a 01 = a 22 = a 43 = 0, the data amount of the input data 101 can be omitted. At this time, Expression (15) is as shown in Expression (16) below.
2 × {L (1) + L (2) + L (3) + L (4)} × v1
-2 × L (1) × v 1
-2 × L (2) × v 2
-2 × L (3) × v 3
-2 × L (4) × v 4
=
-{L (3) + L (2)} × a 02- {L (4) + L (1)} × a 03- {L (2) + L (4)} × a 04
+ L (1) × (a 11 + a 13 ) + L (2) × (a 24 ) + L (3) × (a 31 + a 32 ) + L (4) × (a 44 ) (16)
It becomes.

さらに、入力四角形が平行四辺形に限定する場合を考える。この場合、四角形の形状は二つのベクトルで表すことができるので、さらに入力データ101のデータ量を省略できる。他の部分は実施例1と同様に動作する。以上で実施例2の説明を終わる。   Further, consider a case where the input rectangle is limited to a parallelogram. In this case, since the quadrangular shape can be represented by two vectors, the data amount of the input data 101 can be further omitted. The other parts operate in the same manner as in the first embodiment. This is the end of the description of the second embodiment.

実施例2によれば、入力多角形が2次元行列にマッピングされるように配置された四角形である場合には、入力データの情報量と、展開処理のための計算量を削減することができる。   According to the second embodiment, when the input polygon is a quadrangle arranged so as to be mapped to a two-dimensional matrix, the information amount of input data and the calculation amount for the expansion process can be reduced. .

次に、実施例3について説明する。実施例1および実施例2では、全ての多角形の頂点以外の辺上には、他の多角形の頂点の存在を認めないという条件を課していたが、実施例3では、この条件を取り外し、多角形の頂点以外の辺上に、他の多角形の頂点の存在する場合に対しても本発明を適用可能にするものである。実施例3は、実施例1の物体表面平坦装置100と同じ構成で実現可能なであるため、図3を用いて説明する。まず、一般の多角形の場合に関して示す。   Next, Example 3 will be described. In Example 1 and Example 2, the condition that the existence of vertices of other polygons is not allowed on the sides other than the vertices of all polygons is imposed. The present invention can also be applied to the case where vertices of other polygons exist on the sides other than the removed vertices. Since the third embodiment can be realized with the same configuration as the object surface flattening device 100 of the first embodiment, it will be described with reference to FIG. First, the case of a general polygon will be described.

図13は実施例3の動作説明図である。図13に示されるように、多角形1の辺STに、他の多角形2および3の頂点Vが存在している場合を考える。この場合、実施例1に示された方式を適用することはできない。本実施例では、多角形1を、頂点Vの位置を新たな頂点とする二つの多角形に分割することによって、実施例1の手法を適用しようとするものである。多角形の分割は、多角形の形状情報および周辺多角形の形状情報に基づき多角形スキャン部102により行われる。したがって、多角形スキャン部102が特許請求の範囲における多角形分割手段に相当する。   FIG. 13 is a diagram for explaining the operation of the third embodiment. As shown in FIG. 13, consider a case in which vertices V of other polygons 2 and 3 exist on side ST of polygon 1. In this case, the method shown in the first embodiment cannot be applied. In the present embodiment, the technique of the first embodiment is applied by dividing the polygon 1 into two polygons having the position of the vertex V as a new vertex. The polygon is divided by the polygon scanning unit 102 based on the shape information of the polygon and the shape information of the surrounding polygon. Therefore, the polygon scanning unit 102 corresponds to the polygon dividing means in the claims.

適用の方法には以下の2種類がある。図14は多角形分割方式を説明する図である。図15は多角形分割方式の他の例を説明する図である。
(1)多角形1の頂点以外の辺上に他の多角形2、3の頂点Vが存在している場合に、頂点Vから、頂点S、T以外の一つの頂点に線を引くことによって多角形1を分割する。この方式の分割の様子を図14に示す。
(2)多角形1の頂点以外の辺上に他の多角形2、3の頂点Vが存在している場合に、頂点Vから、半直線を多角形1の内部の方向に引く。
There are the following two methods of application. FIG. 14 is a diagram for explaining the polygon division method. FIG. 15 is a diagram for explaining another example of the polygon division method.
(1) By drawing a line from the vertex V to one vertex other than the vertices S and T when the vertices V of the other polygons 2 and 3 exist on the sides other than the vertex of the polygon 1 Divide polygon 1. FIG. 14 shows how this method is divided.
(2) When the vertices V of the other polygons 2 and 3 exist on the sides other than the vertex of the polygon 1, a half line is drawn from the vertex V in the direction inside the polygon 1.

このように直線を引くことにより、頂点Vを多角形の辺上の頂点ではなくすることができる。さらに、上記(2)の場合、半直線の方向を、図15における多角形2と多角形3の間の線分と同じにすることによって、より妥当な分割が可能になる。   By drawing a straight line in this way, the vertex V can be made not a vertex on the side of the polygon. Furthermore, in the case of (2) above, by making the direction of the half straight line the same as the line segment between the polygon 2 and the polygon 3 in FIG.

実施例3によれば、多角形の頂点以外の辺上に他の多角形の頂点が存在している場合に、多角形の辺上にある頂点から線分あるいは半直線を引くことにより、その頂点と辺の交点を新たな頂点することで、多角形の辺上の頂点ではなくすことができるので、入力多角形の辺上に頂点がない場合と同様に物体表面を平面に展開できる。   According to Example 3, when a vertex of another polygon exists on a side other than the vertex of the polygon, the line segment or the half line is drawn from the vertex on the side of the polygon. By making the intersection of the vertex and the side a new vertex, it is possible to eliminate the vertex on the side of the polygon, so that the object surface can be developed on a plane as in the case where there is no vertex on the side of the input polygon.

なお、上記図3で説明した物体表面平坦化装置または物体表面平坦化方法は、例えば、CPU(Central Processing Unit)、ROM(Read Only Memory)、RAM(Random Access Memory)等を用いて実現され、プログラムをハードディスク装置や、CD−ROM、DVDまたはフレキシブルディスクなどの可搬型記憶媒体等からインストールし、または通信回路からダウンロードし、CPUがこのプログラムを実行することで、図3に示した各機能を実現する。   Note that the object surface flattening apparatus or the object surface flattening method described in FIG. 3 is realized using, for example, a CPU (Central Processing Unit), a ROM (Read Only Memory), a RAM (Random Access Memory), and the like. The program is installed from a hard disk drive, a portable storage medium such as a CD-ROM, a DVD, or a flexible disk, or downloaded from a communication circuit, and the CPU executes the program, so that each function shown in FIG. Realize.

以上本発明の好ましい実施例について詳述したが、本発明は係る特定の実施例に限定されるものではなく、特許請求の範囲に記載された本発明の要旨の範囲内において、種々の変形、変更が可能である。   Although the preferred embodiments of the present invention have been described in detail above, the present invention is not limited to the specific embodiments, and various modifications, within the scope of the gist of the present invention described in the claims, It can be changed.

多角形の辺共有を説明する図である。It is a figure explaining edge sharing of a polygon. 多角形の頂点が2点に分割される場合を説明する図である。It is a figure explaining the case where the vertex of a polygon is divided | segmented into 2 points | pieces. 本実施例に係る物体表面平坦化装置100のブロック図である。1 is a block diagram of an object surface flattening apparatus 100 according to an embodiment. 多角形形状および位置の説明図である。It is explanatory drawing of a polygon shape and a position. 多角形インデクス集合Fhの説明図である。It is explanatory drawing of the polygon index set Fh. 辺インデクス集合Hiの説明図である。It is explanatory drawing of edge index set Hi. (a)はある多角形の頂点以外の辺上には、他の多角形の頂点が存在していない様子を示す図、(b)はある多角形の頂点以外の辺上に、他の多角形の頂点が存在している様子を示す図である。(a) is a diagram showing a state in which there are no vertices of other polygons on the sides other than the vertices of a certain polygon, and (b) is a diagram showing other polygons on the sides other than the vertices of a certain polygon. It is a figure which shows a mode that the vertex of a square exists. 距離関数を説明するための図である。It is a figure for demonstrating a distance function. 物体の表面の四角形が規則正しく並んでいる様子の説明図である。It is explanatory drawing of a mode that the rectangle of the surface of an object is located regularly. 物体表面の四角形が規則正しく並んでいない様子の説明図である。It is explanatory drawing of a mode that the rectangle of the object surface is not regularly arranged. 実施例2の動作説明図である。FIG. 6 is an operation explanatory diagram of Embodiment 2. 実施例2の他の動作例を説明する図である。FIG. 10 is a diagram illustrating another operation example of the second embodiment. 実施例3の動作説明図である。FIG. 9 is an operation explanatory diagram of Embodiment 3. 多角形分割方式を説明する図である。It is a figure explaining a polygon division | segmentation system. 多角形分割方式の他の例を説明する図である。It is a figure explaining the other example of a polygon division system.

符号の説明Explanation of symbols

100 物体表面平坦化装置
102 多角形スキャン部
103 周囲多角形抽出部
104 一次方程式作成部
105 多角形位置演算部
106 並べ合わせ部
107 多角形形状補正部
DESCRIPTION OF SYMBOLS 100 Object surface flattening apparatus 102 Polygon scanning part 103 Surrounding polygon extraction part 104 Primary equation creation part 105 Polygon position calculating part 106 Arrangement part 107 Polygon shape correction part

Claims (13)

コンピュータ上に多角形の集合体として表現された3次元空間内の物体表面を平面上に展開する物体表面平坦化装置であって、
入力データから多角形の形状情報を抽出する手段と、
前記多角形と辺を共有する周辺多角形の形状情報を抽出する手段と、
前記多角形の形状情報および前記周辺多角形の形状情報から、前記平面上において前記多角形と前記周囲多角形との間で共有する辺間の距離についての関数を求め、前記関数に前記共有する辺間の距離が最小になるという条件を適用することにより、前記各多角形毎に、前記各多角形の位置を決定するための一次方程式を作成する係数取得手段と、
前記各多角形を決定するための一次方程式を解くことにより、前記各多角形の位置を算出する多角形位置算出手段と、
前記位置が算出された多角形を並べる手段とを具備することを特徴とする物体表面平坦化装置。
An object surface flattening device that develops on a plane an object surface in a three-dimensional space represented as a collection of polygons on a computer,
Means for extracting polygon shape information from input data;
Means for extracting shape information of a peripheral polygon sharing a side with the polygon;
From the shape information of the polygon and the shape information of the surrounding polygon , a function is calculated for a distance between sides shared between the polygon and the surrounding polygon on the plane, and the function is shared with the function Applying the condition that the distance between sides is minimized, for each polygon, coefficient acquisition means for creating a linear equation for determining the position of each polygon;
Polygon position calculating means for calculating the position of each polygon by solving a linear equation for determining each polygon;
An object surface flattening apparatus comprising: means for arranging the polygons whose positions are calculated.
前記物体表面平坦化装置は更に、前記並べられた各多角形の形状を補正する手段を具備することを特徴とする請求項1記載の物体表面平坦化装置。 2. The object surface flattening device according to claim 1, further comprising means for correcting the shapes of the arranged polygons. 前記物体表面平坦化装置は更に、多角形の頂点以外の辺上に他の多角形の頂点が存在している場合に、前記多角形の辺上にある頂点から線分あるいは半直線を引くことにより、その頂点と辺の交点を新たな頂点とする多角形分割手段を具備することを特徴とする請求項1または請求項2記載の物体表面平坦化装置。 The object surface flattening device further draws a line segment or a half line from a vertex on the side of the polygon when a vertex of another polygon exists on a side other than the vertex of the polygon. The object surface flattening apparatus according to claim 1 or 2, further comprising polygon dividing means having a new vertex at the intersection of the vertex and the side. 前記入力データは、3次元空間内の物体表面を構成する多角形の形状を表すデータを含み、
前記多角形の形状を表すデータは、共通の始点から多角形の各頂点への2次元ベクトルであり、
前記共通の始点へのベクトルは多角形の位置を表すベクトルであることを特徴とする請求項1から請求項3の何れか一項に記載の物体表面平坦化装置。
The input data includes data representing the shape of a polygon constituting the object surface in a three-dimensional space;
The data representing the shape of the polygon is a two-dimensional vector from a common starting point to each vertex of the polygon,
The object surface flattening device according to any one of claims 1 to 3, wherein the vector to the common starting point is a vector representing a polygonal position.
前記入力データは、3次元空間内の物体表面を構成する多角形の相対位置を表すデータを含み、
前記相対位置を表すデータは、
3次元空間内の物体表面を構成する多角形の各辺に対し、該各辺をどの多角形が共有しているかを示す情報、および/または、3次元空間内の物体表面を構成する多角形にはどの辺が存在しているかを示す情報、
および、各辺の両端の頂点インデクスのデータであることを特徴とする請求項1から請求項4の何れか一項に記載の物体表面平坦化装置。
The input data includes data representing the relative positions of polygons constituting the object surface in a three-dimensional space;
The data representing the relative position is
Information indicating which polygon shares each side of the polygon constituting the object surface in the three-dimensional space and / or the polygon constituting the object surface in the three-dimensional space Contains information about which side is present,
5. The object surface flattening device according to claim 1, wherein the data is vertex index data at both ends of each side. 6.
前記係数取得手段は、ある中心多角形と、該中心多角形と辺を共有する周囲多角形との間で、共有すべき辺間の距離の和が最小になるような、中心多角形と周囲多角形との相対位置を示す一次方程式を作成することを特徴とする請求項1から請求項5の何れか一項に記載の物体表面平坦化装置。 The coefficient acquisition means includes a center polygon and a surrounding area that minimize a sum of distances between sides to be shared between the center polygon and a surrounding polygon sharing the side with the center polygon. 6. The object surface flattening device according to claim 1, wherein a linear equation indicating a relative position with respect to the polygon is created . 前記辺間の距離は、共有すべき頂点間の距離の2乗和に辺の長さを乗じたものであることを特徴とする請求項6記載の物体表面平坦化装置。 7. The object surface flattening apparatus according to claim 6, wherein the distance between the sides is obtained by multiplying the square sum of the distances between vertices to be shared by the length of the side. 前記多角形位置算出手段は、最小二乗法で連立一次方程式を解くことで前記各多角形の位置を算出することを特徴とする請求項1から請求項7の何れか一項に記載の物体表面平坦化装置。 The object surface according to any one of claims 1 to 7, wherein the polygon position calculation means calculates the position of each polygon by solving simultaneous linear equations by a least square method. Flattening equipment. 前記入力データに含まれる多角形は、2次元行列にマッピングされるように配置された四角形であり、
前記多角形の形状を抽出する手段は、前記四角形の配置場所に対応した多角形インデクスから前記3次元空間内の物体表面を構成する多角形の相対位置を表すデータを決定し、
前記係数取得手段は、前記多角形の相対位置から、前記各多角形の位置に関する式の係数を決定することを特徴とする請求項1から請求項3の何れか一項に記載の物体表面平坦化装置。
The polygon included in the input data is a quadrangle arranged so as to be mapped to a two-dimensional matrix,
The means for extracting the shape of the polygon determines data representing a relative position of the polygon constituting the object surface in the three-dimensional space from the polygon index corresponding to the location of the quadrangle,
The object surface flatness according to any one of claims 1 to 3, wherein the coefficient acquisition unit determines a coefficient of an expression related to a position of each polygon from a relative position of the polygon. Device.
前記共通の始点は、多角形の頂点のうちの一つであることを特徴とする請求項4記載の物体表面平坦化装置。 5. The object surface flattening apparatus according to claim 4, wherein the common starting point is one of polygonal vertices. 多角形の集合体として表現された3次元空間内の物体表面を平面上に展開するためにコンピュータに、
入力データから多角形の形状情報を抽出するステップと、
前記多角形と辺を共有する周辺多角形の形状情報を抽出するステップと、
前記多角形の形状情報および前記周辺多角形の形状情報から、前記平面上において前記多角形と前記周囲多角形との間で共有する辺間の距離についての関数を求め、前記関数に前記共有する辺間の距離が最小になるという条件を適用することにより、前記各多角形毎に、前記各多角形の位置を決定するための一次方程式を作成するステップと、
前記各多角形の位置を決定するための一次方程式を解くことにより、前記各多角形の位置を算出するステップと、
前記位置が算出された多角形を並べるステップとを実行させるためのプログラム。
In order to expand the surface of an object in a three-dimensional space represented as a collection of polygons on a plane,
Extracting polygon shape information from input data;
Extracting shape information of a surrounding polygon that shares a side with the polygon; and
From the shape information of the polygon and the shape information of the surrounding polygon , a function is calculated for a distance between sides shared between the polygon and the surrounding polygon on the plane, and the function is shared with the function Creating a linear equation for determining the position of each polygon for each polygon by applying the condition that the distance between sides is minimized ;
Calculating the position of each polygon by solving a linear equation for determining the position of each polygon;
A program for executing the step of arranging the polygons whose positions are calculated.
前記プログラムは更に、前記並べられた各多角形の形状を補正するステップを前記コンピュータに実行させることを特徴とする請求項11記載のプログラム。 12. The program according to claim 11, further causing the computer to execute a step of correcting the shapes of the arranged polygons. 請求項11または請求項12のプログラムを記録したコンピュータ読み取り可能な記録媒体。 A computer-readable recording medium on which the program according to claim 11 or 12 is recorded.
JP2004113257A 2004-04-07 2004-04-07 Object surface flattening apparatus and program Expired - Fee Related JP4325469B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004113257A JP4325469B2 (en) 2004-04-07 2004-04-07 Object surface flattening apparatus and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004113257A JP4325469B2 (en) 2004-04-07 2004-04-07 Object surface flattening apparatus and program

Publications (3)

Publication Number Publication Date
JP2005301426A JP2005301426A (en) 2005-10-27
JP2005301426A5 JP2005301426A5 (en) 2007-05-24
JP4325469B2 true JP4325469B2 (en) 2009-09-02

Family

ID=35332922

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004113257A Expired - Fee Related JP4325469B2 (en) 2004-04-07 2004-04-07 Object surface flattening apparatus and program

Country Status (1)

Country Link
JP (1) JP4325469B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
FR2915605B1 (en) * 2007-04-26 2009-09-11 Airbus France Sas METHOD AND DIPOSITIVE FOR MODELING PREDECOUTS OR PONCIFS FOR THREE-DIMENSIONAL OBJECTS WITH UNDEVELOPPED SURFACES AND FOR ASSISTING THE TRANSFER OF TWO-DIMENSIONAL PATTERNS ON THESE OBJECTS

Also Published As

Publication number Publication date
JP2005301426A (en) 2005-10-27

Similar Documents

Publication Publication Date Title
JP4845147B2 (en) Perspective editing tool for 2D images
US7664312B2 (en) Information input and output method using dot pattern
JP4119529B2 (en) Virtual environment generation method and apparatus, and recording medium on which virtual environment generation program is recorded
TW200537393A (en) Graphic processing apparatus, graphic processing system, graphic processing method and graphic processing program
US20140267252A1 (en) Using curves to emulate soft body deformation
JPH0771936A (en) Device and method for processing image
CN111583381B (en) Game resource map rendering method and device and electronic equipment
JP3630934B2 (en) Texture recording method
JP4325469B2 (en) Object surface flattening apparatus and program
JP5356711B2 (en) Map information correction apparatus, map information correction method, and program
Inoue A new construction method for circle cartograms
US9532071B2 (en) Resampling apparatus, method, and recording medium having resampling program recorded therein for digital image
JP4541537B2 (en) Drawing device
JP3993423B2 (en) Electronic publication browsing apparatus, electronic publication browsing program, and computer-readable recording medium recording the program
JP2007282906A (en) Method, apparatus, and program of medical image processing
JP4325395B2 (en) Method, apparatus, and program for expanding object surface in three-dimensional space on plane
US10878610B1 (en) Generating an animation feature from line deformations
JP4177017B2 (en) Orthophoto generation method, orthophoto generation system, and orthophoto generation program
JPH10198824A (en) Video generation and processing device, and structure data preparing device for preparing structured data to be used for the same
JP6697573B2 (en) Hairstyle simulation device, hairstyle simulation method, and computer program
JP3679347B2 (en) Pattern change simulation system
JP6441032B2 (en) Corresponding point search device, corresponding point search program, and corresponding point search method
CN112488909A (en) Multi-face image processing method, device, equipment and storage medium
JP7281782B2 (en) video projection system
JP6800363B1 (en) program

Legal Events

Date Code Title Description
A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20070326

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20070326

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090224

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090422

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20090519

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20090601

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120619

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120619

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130619

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140619

Year of fee payment: 5

LAPS Cancellation because of no payment of annual fees