WO2009142037A1 - 近似処理方法、および近似処理装置 - Google Patents

近似処理方法、および近似処理装置 Download PDF

Info

Publication number
WO2009142037A1
WO2009142037A1 PCT/JP2009/053252 JP2009053252W WO2009142037A1 WO 2009142037 A1 WO2009142037 A1 WO 2009142037A1 JP 2009053252 W JP2009053252 W JP 2009053252W WO 2009142037 A1 WO2009142037 A1 WO 2009142037A1
Authority
WO
WIPO (PCT)
Prior art keywords
point
curved surface
approximate
control
control point
Prior art date
Application number
PCT/JP2009/053252
Other languages
English (en)
French (fr)
Inventor
卓 前川
悠 西山
真之 森岡
Original Assignee
国立大学法人横浜国立大学
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 国立大学法人横浜国立大学 filed Critical 国立大学法人横浜国立大学
Priority to JP2010512954A priority Critical patent/JP5436416B2/ja
Priority to US12/994,011 priority patent/US8805908B2/en
Publication of WO2009142037A1 publication Critical patent/WO2009142037A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • G06T17/20Finite element generation, e.g. wire-frame surface description, tesselation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • G06T17/30Polynomial surface description

Definitions

  • the present invention relates to an approximation processing method and an approximation processing device for generating a curve or a curved surface by approximating point cloud data.
  • Free curved surfaces are used in the bodies of various industrial products such as ships, automobiles, airplanes, etc., and have both functionality and beauty, and they are designed for home appliances and the appearance of many consumer products. Used for designing beautiful shapes.
  • 3D models are represented on a computer by polygonal models or curved patches such as NURBS and B-Spline.
  • This polygon model is efficient in performing shape processing such as phase change, but because it is composed of flat surfaces, it cannot express a smooth surface, and the amount of data becomes enormous as the shape is expressed in detail. There are problems such as becoming.
  • the curved surface patch can express a smooth curved surface with a small number of control parameters, but has a problem that the patch shape is limited to a square and it is difficult to maintain continuity between patches. Therefore, a subdivision method having the advantages of a polygon model and a curved surface patch is attracting attention as an effective method for free geometric modeling, and has already been actively used in the field of animation.
  • the subdivision method is a method of smoothing the shape by repeatedly performing regular division on the initial polygon mesh, and ultimately obtaining a smooth curved surface.
  • the curved surface by the division is called a subdivision surface (SubdivisionfaceSurface), and the ultimate curved surface is called a limit surface.
  • the subdivision method has a feature that a smooth curved surface can be easily generated even for a model having an arbitrary phase. Further, since the curved surface is defined smoothly in any part, a wide use such as modeling is progressing.
  • Non-Patent Document 1 a Catmull-Clark subdivision curved surface interpolation method for a polyhedral mesh proposed by Halsted et al. Is known (Non-Patent Document 1). This method not only needs to solve a large-scale linear system, but also needs to solve a minimization problem for correcting a curved surface called fairing, which greatly increases the calculation cost.
  • Non-Patent Document 2 Non-Patent Document 2
  • Non-Patent Document 2 The method of Hoppe et al. (Non-Patent Document 2) performs parameterization on a linearly approximated surface, whereas Marinov and Kobbelt perform parameterization on a limit surface using Stam's theory. However, calculation of the control points requires a great deal of time because it solves a large-scale linear system. (Non-patent document 8)
  • the method using the linear system solution method such as solving the determinant for the approximation or interpolation operation
  • the number of operations increases as the number of data points and control points in the point group increases due to the nature of the operation of the linear system.
  • the operation for generating a curved surface from the point group is an operation for solving a large-scale linear system, and a large amount of calculation time is required. There is a problem that it takes.
  • An object of the present invention is to propose a method and an apparatus for generating a curved or curved surface.
  • the present invention provides a control point by selecting a feature point holding a shape feature from a polygonal line or a mesh formed by data points of a point group in an approximation process for approximating the shape of a data point of a point group by a curve or a curved surface.
  • the curve or curved surface is approximated by this control point.
  • the corrected control points are calculated by a simple geometric algorithm without requiring much calculation time for solving the linear system. The approximation is possible in a short time.
  • Interpolation and approximation methods are known for fitting by control points, but interpolation methods fit point group data points with the same number of data points as the number of data points, whereas approximation methods use data points.
  • the point data points are fitted by the number of control points smaller than the number of data points.
  • QEM Surface simplification using quadric errors ⁇ metrics: Non-Patent Document 3
  • QEM Surface simplification using quadric errors ⁇ metrics: Non-Patent Document 3
  • the present invention uses a point cloud data point as start data, obtains a control point from this data point by processing such as QEM, sequentially corrects the control point by a calculation process, and selects from the point cloud data point and this data point If the control points are known, they may be corrected sequentially from the known control points by the calculation process. If this control point is known, the process of selecting the control point from the data points of the point group can be omitted.
  • control point is moved by calculating the nearest point on the curve or curved surface closest to each data point of the given point group by the Newton method, and an error vector connecting the calculated nearest point to each data point. Is approximated by sequentially moving the control points based on the error vector. Since the process of moving the control point can be performed by the process of the geometric algorithm without solving the linear system, high-speed processing can be performed.
  • the linear system itself is not required, and an approximate curve or an approximate curved surface can be generated only by a geometric process. Therefore, the processing speed can be increased as compared with the conventional method.
  • the present invention is not limited to three dimensions and can be similarly applied to two dimensions.
  • it can also be applied to the generation of curves approximating data points.
  • the present invention can be an aspect of a method and an apparatus regarding approximation processing.
  • the approximation processing device includes means for executing this approximation processing method by software or hardware.
  • the approximation processing method of the present invention is an approximation processing method that approximates data points of a point group by a curve or curved surface defined by control points, and forms an approximate curve or approximate curved surface by using control points that preserve shape characteristics. And a calculation step of calculating a correction position of the control point.
  • the calculation step for calculating the correction position of the control point includes an approximate curve or a first calculation step for calculating the closest point to the data point on the approximate curve, and a data point from the closest point calculated in the first calculation step.
  • the process of forming an approximate curve or approximate curved surface and each calculation process can be performed by a calculation means incorporating a geometric algorithm.
  • the approximate curve or approximate curved surface is approximated to the curve or curved surface formed by the data points as targets.
  • the data points of the point group used in the approximation processing method of the present invention can be acquired by, for example, a three-dimensional shape measuring instrument.
  • the first control point can be obtained by connecting the data points of a given point cloud to form a polygonal line or mesh, and selecting a point that preserves the shape characteristics by processing such as QEM from this polygonal line or mesh. it can. With this point as the initial control point, the position of the control point is corrected by the first to third calculation steps.
  • the nearest point closest to the data point on the approximate curve or the approximate curve can be calculated by the Newton method.
  • the second calculation step is a step of calculating an error vector connecting the data point and the nearest point for each data point in all data points of the point group.
  • the third calculation step is a step of calculating control points corrected by moving each control point based on the error vector calculated in the second calculation step, and a plurality of errors calculated in the second calculation step.
  • the error vector calculated for the nearest point around the control point to be corrected is weighted, this weighted error vector is added to the vector, and the addition vector obtained by vector addition is used as the movement vector to be corrected.
  • the error vector used for the movement of the control point is obtained by vector addition of the error vector calculated at the nearest point around the control point in the second calculation step.
  • this vector addition by weighting the error vector, the number of computations until the control point converges can be reduced.
  • the weighting process in the third calculation step can be performed by an arithmetic process that multiplies each error vector by a coefficient.
  • This coefficient is determined according to the distance between the control point and the nearest point, and weighting is performed by setting a larger value at the nearest point near the control point and setting a smaller value at the nearest point far from the control point. It is assumed that the closest point closer to the control point is more relevant to the control point, and the number of operations until the control point converges by weighting the error vector of the closest point close to the control point with a large coefficient. Can be reduced.
  • the weighting coefficient can be determined according to the barycentric coordinate system.
  • the approximation processing of the present invention calculates an approximation error of an approximate curve or approximate curved surface based on the distance between the data point and the nearest point corresponding to the data point, and controls the control point until the calculated approximation error becomes less than a predetermined value. Repeat the calculation process.
  • the mesh formed by the control points is divided into planes to increase the number of control points. Or re-mesh the mesh formed by the control points locally. The control point calculation process, the increase of control points by surface division, and local remeshing are repeated until the approximation error becomes less than a predetermined value.
  • the approximation error does not become less than a predetermined value even if the approximation process by moving the control points is repeated a predetermined number of times, the number of control points is increased by inserting knots. The control point calculation process and the control point increase are repeated until the approximation error becomes less than a predetermined value.
  • the approximation processing device of the present invention is an approximation processing device that approximates a data point of a point group by a curve or curved surface defined by control points, and forms an approximate curve or approximate curved surface by using control points that store shape characteristics.
  • a first calculating step for calculating the nearest point closest to the data point on the approximate curve or the approximate curved surface, and a first calculating step for calculating an error vector connecting the data points from the nearest point obtained in the first calculating step.
  • a calculation means for performing each step of the second calculation step and the third calculation step of moving the control point based on the error vector obtained in the second calculation step and calculating the corrected control point.
  • the computing means is constituted by a process for forming an approximate curve or an approximate curved surface, a CPU and a storage device for executing a geometric algorithm for performing each calculation process by software, or a circuit for executing each geometric algorithm by hardware. can do.
  • the approximate curve or approximate curved surface is approximated to the curve or curved surface formed by the data points of interest.
  • Curved surfaces include loop subdivision using triangle mesh (Non-patent Document 4), B-Spline, NURBS, Catmull-Clark subdivision using quadrilateral mesh (Non-patent Document 5), Doo-Sabin subdivision (Non-patent Document 6), etc. It can be defined by control points determined by subdivision or the like.
  • the curve can be defined by a control point determined by a B-Spline curve or Chaikin subdivision (Non-patent Document 7). Note that Chaikin subdivision converges to a second-order B-Spline curve, and generally an n-order B-Spline curve can also be approximated.
  • calculation time can be reduced in generating a curve or curved surface that approximates a data point of a point group.
  • FIG. It is a figure for demonstrating error vector e (k) i, j around a control point. It is a figure for demonstrating the increase in the control point P.
  • FIG. It is a figure for demonstrating an example of local remeshing. It is a figure for demonstrating an example of local remeshing. It is a figure which shows the example of a result by this invention. It is a figure which shows one Example of the approximation process of this invention. It is a figure for demonstrating the weighting in the approximation of the B-Spline curve of this invention.
  • FIG. 1 is a schematic diagram for explaining the outline of the approximation processing of the present invention
  • FIG. 2 is a flowchart for explaining the outline of the approximation processing of the present invention
  • FIG. 3 is a schematic configuration diagram of the approximation processing apparatus of the present invention. .
  • FIG. 1 and 2 schematically show a procedure for obtaining the approximate curved surface S ⁇ from the data points p i of the point group P.
  • 3D laser scanner 3-dimensional shape measuring instrument
  • high density and irregular point cloud obtained from such P is formed by the data points p i of the point group P that seek control points representing the characteristic shape by techniques such as QEM from the mesh shows the procedure for obtaining a final approximated surface S ⁇ from the control point.
  • the data point of the point group and the control point selected from the data point are known, it may be applied to the procedure for obtaining the approximate curved surface S ⁇ by sequentially correcting using the known control point.
  • an object is measured by a three-dimensional measuring instrument such as a 3D laser scanner to obtain a data point p i of the point group p (FIG. 1A) (S1).
  • Data points p i of the point group p obtained by measurement are connected and meshed.
  • FIG. 1B an example of a triangular mesh is shown (FIG. 1B) (S2).
  • control points are simplified while retaining the shape characteristics of the original object.
  • a control mesh is formed by these control points.
  • a triangular mesh or a quadrilateral mesh can be used.
  • an existing method such as QEM can be used for the simplification processing of the mesh that leaves this feature.
  • the mesh formed from the first control point P (0) is defined as the initial control mesh M (0) n
  • the mesh obtained by changing the control points is defined as the control mesh M n thereafter.
  • the subscript 0 represents the initial stage
  • n represents the number of control points (FIG. 1 (c)) (S3).
  • An initial approximate curved surface S (0) is generated using the control point P (0) of the initial control mesh M (0) n (FIG. 1 (d)) (S4).
  • An initial nearest point S (0) (t i ) corresponding to each data point p i of the point group p is obtained on the initial approximate curved surface S (0) generated in S4 (S5).
  • the position of the initial control point P (0) is moved by the obtained movement vector d, and the control point whose position is corrected is set as the control point P (k) (S7).
  • the subscript (k) of the control point P (k) represents the number of repetitions, and the control point obtained in the (k) -th step is represented by P (k) .
  • the initial control point P (0) is represented by a superscript (0), and the subscript (k) of the control point P (k) obtained repeatedly thereafter is repeatedly increased by “1” for each repetition.
  • the number of times can be represented by a numerical value of “k” in the subscript (k).
  • An approximate curved surface S (k) is generated using the control point P (k) obtained by moving by the movement vector d (FIG. 1 (g)) (S8).
  • a nearest point S (k) (t i ) corresponding to each data point p i of the point group p is obtained on the approximate curved surface S (k) generated in S8 (S9).
  • the approximate curved surface S (k) is approximated to the shape of the object by sequentially moving and correcting the control point P (k) .
  • Whether or not the approximate curved surface S (k) approximates the shape of the object is evaluated by the following steps S10 to S11, and the degree of approximation of the approximate curved surface S (k) does not satisfy a predetermined allowable value. For this purpose, control points are moved by repeating the steps S6 to S9, or the control points are increased by dividing the mesh in steps S13 to S15.
  • the error E is obtained from the nearest point S (k) (t i ), the data point p i and the absolute value error (S10).
  • the error E is compared with a predetermined allowable value (S11). If the error is not within the allowable value, the degree of approximation is improved by repeating the steps S6 to S9 and moving the control point. In addition, the control points are increased by inserting knots in steps S13 to S15.
  • the mesh division by the steps S13 to S15 is performed when the error does not fall within the allowable value even if the steps S6 to S9 are repeated for the set number of times (S12).
  • the nearest point S (t i ) is obtained for the obtained approximate curved surface S m (FIG. 1 (k)) (S15), and the process returns to S6 to calculate the movement vector d of the control mesh M m .
  • the approximate curved surface S ⁇ obtained when the distance error converges within the allowable range by the approximation processing is an approximate curved surface that approximates the data point p i of the point group p.
  • the process of the present invention is performed by a geometric algorithm operation.
  • ) (t i ) is calculated by the Newton method, and in step S7, an error vector e i between the data point p i and the nearest point S (k) (t i ) is obtained, and control is performed using this error vector e i.
  • a control vector d for moving the point P (k) is obtained.
  • the control point P (k) is moved by the obtained control vector d, and the approximate curved surface S (k + 1) is obtained by using the moved control point P (k + 1) in the step S8.
  • Loop subdivision using a triangular mesh For example, Loop subdivision using a triangular mesh, Catmull-Clark subdivision using a quadrilateral mesh, Doo-Sabin subdivision, etc. can be used. Can be applied.
  • Chaikin subdivision can be used, and an n-order B-Spline curve can also be applied. Chaikin subdivision converges to a quadratic B-Spline curve.
  • the approximation processing of the present invention has the following advantages in terms of calculation cost and generality of calculation.
  • it is not necessary to solve the linear system by correcting the control points with a geometric algorithm, so that the calculation speed of the processing can be improved.
  • the approximation algorithm of the present invention generates a curved surface by a simple geometric process, and is applied not only to subdivided curved surfaces but also to curves and curved surfaces defined by control points such as B-Spline curved surfaces and curved lines. It has generality for curved surface generation.
  • FIG. 3 shows an example of the configuration when a computer stores a program storing the approximation processing software of the present invention.
  • the input unit 1 inputs data points p i of the point group p and stores them in the data storage unit 2 a in the storage unit 2.
  • the storage means 2 stores, in addition to the data storage unit 2a, a calculation tool storage unit 2b for storing a calculation tool program for performing geometric processing calculation, a calculation processing program such as subdivision processing in addition to the calculation of approximation processing.
  • the data storage unit 2a stores the data points p i of the point group p, and also forms an initial control mesh M (0) n formed from the data points p i of the point group p and generated from the mesh by QEM or the like. May be stored.
  • the computing means 3 follows the computation procedure by the program stored in the computation processing program storage unit 2c, and sequentially reads out the computation tool program designated by this program from the computation tool storage unit 2b to perform computation processing.
  • the calculation performed by the calculation means 3 includes, for example, calculation processing for forming a triangular mesh from the data points p i of the point group p stored in the data storage unit 2a, and initial control by obtaining an initial control point P (0) from the mesh.
  • Arithmetic processing for generating mesh M (0) n Arithmetic processing for generating mesh M (0) n , arithmetic processing for generating initial approximate curved surface S (0) performed using initial control mesh M (0) n , approximate curved surface S (k for performing control mesh M n ) Calculation processing for generating n , calculation processing for calculating the initial nearest point S (0) (t i ) closest to the data point p i on the initial approximate surface S (0 ) by the Newton method, approximate surface S (k ) An arithmetic process for calculating the nearest point S (k) (t i ) closest to the data point p i on n by the Newton method, and an error vector between the data point p i and the initial nearest point S (0) (t i ) e i, determine the error vector e i of the data points p i and the closest point S (k) (t i) , this error vector e i Arithmetic processing of performing a vector operation of
  • the calculation result stored in the calculation result storage unit 2e can be read and displayed on the display means 4 or output to the output means 5.
  • the output means 5 can be an external device such as a recording device that records the calculation result on a recording medium or a processing device that performs a predetermined operation using the calculation result.
  • the function implemented by the computing means including the storage means can be implemented by hardware by configuring the circuit with a circuit.
  • the flow of the approximation algorithm is to generate an initial control mesh that retains shape characteristics from a triangular mesh of a given point cloud by QEM or the like, and generate an initial approximate curved surface from this initial control mesh.
  • the closest point on the approximate surface generated from the control point (the first control mesh is the first control mesh and the control mesh that has moved the control point after the first) is obtained from the data point, and the nearest point is obtained from this data point.
  • a new approximate curved surface is generated by moving the control point using the error vector.
  • the approximate curved surface approximated by the original shape is obtained by repeating the process of generating the approximate curved surface by the movement of the control point and the control point after the movement.
  • Data points p i of the point group p are obtained by a three-dimensional measuring instrument, and the data points p i are connected and meshed with, for example, a triangular mesh.
  • 4A and 4B schematically show a triangular mesh formed by meshing data points p i of the point group p.
  • a triangular mesh may be obtained in advance from the data points p i and stored in the storage means, and read from the storage means.
  • the three-dimensional control mesh may be a quadrilateral mesh in addition to the triangular mesh.
  • Loop subdivision Non-Patent Document 4
  • Catmull-Clark subdivision Non-patent Document 5
  • Doo-Sabin subdivision Non-patent Document 6
  • An initial control mesh M (0) n consisting of initial control points P (0) is generated from a triangular mesh by a processing method such as well-known QEM (Surface simplification using quadric error metrics: Non-Patent Document 3), and initial control is performed.
  • the control point P (0) of the mesh M (0) n is stored in the storage unit 2a.
  • An initial approximate curved surface S (0) is generated using the stored initial control point P (0) .
  • the initial approximate curved surface generated by the initial control mesh M (0) n is represented by the approximate curved surface S (0) .
  • the approximate curved surface generated by the control mesh M n generated by moving the control point is expressed by the approximate curved surface S (k) n .
  • FIG. 4A shows the data points p i of the point group p
  • FIG. 4B shows the data points p i of the point group p and the control mesh M n generated from the data points p i
  • FIG. 4C shows the control mesh M n generated from the data points p i of the point group p and the approximate curved surface S (k) n generated by the control mesh M n
  • the solid line indicates the control mesh M n
  • the white circle “ ⁇ ” indicates the control point P of the control mesh M n
  • a broken line indicates a curved surface to be approximated
  • a data point p i (not shown in FIG. 4C) is a point on the curved surface to be approximated.
  • FIG. 4C shows a state where there is an error between the approximate curved surface S (k) and the approximation target curved surface.
  • FIGS. 5A and 5B show a state in which the approximate curved surface S (k) approaches the approximate target curved surface.
  • the data point p i is indicated by a black circle “ ⁇ ” in FIG.
  • the approximate curved surface S (k) is formed so as to approximate the curved surface to be approximated by the control point P.
  • the approximate curved surface S (k + 1) is obtained by moving the control point P.
  • the error between the approximate curved surface S (k + 1) and the approximation target curved surface is reduced, and the approximation target curved surface is gradually approached.
  • Figure 5 shows the data points p i, the relationship between the approximated surface S (k) closest point closest to the data point p i on S (k) (t i) .
  • the closest point S (k) (t i ) is the point closest to the data point p i on the approximate curved surface S (k) , and is indicated by a cross in the figure.
  • the nearest point S (k + 1) (t i ) is the closest point to the data point p i on the approximate curved surface S (k + 1) , and is indicated by a cross in the figure. ing.
  • FIG. 5A shows the control point P (k) before movement and the approximate curved surface S (k) by this control point P (k)
  • FIG. 5B shows the control point P (k + 1) after movement.
  • an approximate curved surface S (k + 1) by the control point P (k + 1) is approximated.
  • FIG. 6 is a diagram for explaining the nearest point S (k) (t i ) on the approximate curved surface S (k) .
  • T p is a tangent plane
  • p i is a data point
  • S (v, w) is a point on the approximate curved surface in the parameter (v, w)
  • i is a data point number.
  • v and w are parameters of the curved surface
  • Sv and Sw indicate the differentiation of the subdivision curved surface S in the v and w directions.
  • i is a data point number
  • j is the number of iterations of Newton's method in parameterization
  • ( ⁇ v, ⁇ w) is a surface update parameter.
  • the error between the data point p i and the nearest point S (k) (t i ) can be represented by a vector.
  • it is represented by an error vector e i from the data point p i to the nearest point S (k) (t i ).
  • this error vector e i is indicated by a straight line connecting the data point p i and the nearest point S (k) (t i ) or S (k + 1) (t i ).
  • the present invention obtains an error vector e i between the data point p i and the nearest point S (k) (t i ) for the data point p i existing around the control point P, and a plurality of error vectors e i are obtained. In some cases, these error vectors e i are added together to obtain a movement vector d, and a new control point P (k + 1) is obtained by moving the control point P by the movement vector d.
  • the movement state of the control point is shown in FIG.
  • FIG. 5A shows the control point P (k) before the movement and the approximate curved surface S (k) by the control point P (k)
  • FIG. 5B shows the control point P (k + 1) after the movement. And an approximate curved surface S (k + 1) by the control point P (k + 1) .
  • the error vector by weighting each error vector e i obtained by each data point p i and the closest point S (k) (t i) , weighted
  • the movement vector d is obtained by vector addition of e i .
  • the nearest point S (k) (t i ) corresponding to this one data point p i is obtained, the error vector e i performing the weighted error vector e i between the data points p i and the closest point S (k) (t i) and motion vector d.
  • an error vector e i for performing weighting exists around the control point P.
  • the surroundings of the control point P can be, for example, within an approximate curved surface generated by a mesh having the control point P (k) as a common vertex, and these meshes form a loop around the control point P (k). is doing.
  • the error vector e i Since the mesh existing around the control point P (k) differs depending on each control point, and the error vector e i existing corresponding to each mesh also differs depending on each mesh, the error vector e to be weighted Although the number of i is not constant, the data point p i and the nearest point S (k) (t i ) that form the error vector e i are determined by the number of data points in the point group, so that all the control points P The number of error vectors e i used for is constant.
  • the degree of weighting can be determined according to the distance between the control point P and the nearest point S (k) (t i ).
  • the degree of weighting is set large, and the error vector e related to the data point p i existing far from the control point P is set.
  • the degree of weighting is set small. By performing this weighting, the number of repetitions for obtaining the approximate curved surface S can be reduced.
  • FIG. 8 shows one triangular mesh (a triangle in which a thick solid line in FIG. 8 is formed) among a plurality of triangular meshes formed around the control point P (k) .
  • the triangular mesh is indicated by a thick solid line, and the approximate curved surface S corresponding to this triangular mesh is shown with shading.
  • a data point p i indicated by a black circle “ ⁇ ” is a point on the curved surface to be approximated
  • a closest point S (k) (t i ) indicated by a cross is a point closest to the data point p i .
  • the arrow between the data point p i and the nearest point S (k) (t i ) indicates the error vector e (k) i, J.
  • FIG. 8 shows only one set of the data point p i , the nearest point S (k) (t i ), and the error vector e (k) i, J in the triangular mesh and the approximate curved surface S.
  • “J” represents the J-th closest point S (k) (t i ) existing around the control point P.
  • the error vector e (k) i, J is weighted according to the distance between the nearest point S (k) (t i ) and the control point P (k) .
  • the weighting process can be performed by multiplying the error vector e (k) i, J by a weighting coefficient u (k) i, J.
  • the error vector e (k) i, J existing near the control point P is multiplied by a large value of the weighting coefficient u (k) i, J and is moved far from the control point P.
  • the existing error vector e (k) i, J is multiplied by setting the value of the weighting coefficient u (k) i, J small.
  • the weighting coefficient u (k) i, J by this barycentric coordinate system is represented by a curve on the approximate curved surface S (k) in FIG.
  • the weighting factor u (k) i at the control point P * (k), J is "1"
  • the control point P * (k) weighted at the edge of the approximated surface S remote from the coefficient u (k) i , J is “0” (S6a).
  • FIG. 9 is a diagram for explaining the error vector e (k) i, J around the control point.
  • a single control point P (k) has a plurality of triangular meshes having the control point P (k) as a common vertex, and the nearest point S (k ) on the approximate curved surface S (k) formed by each triangular mesh. ) Since a weighted error vector e * (k) i is generated for (t i ), a plurality of weighted error vectors e * (k) i, J are generated for one control point P (k) . At the control point P (k) , these weighted error vectors e * (k) i, J are added to obtain a control vector d (k) that moves the control point.
  • the evaluation function E calculates an absolute value error between the data point p i and the nearest point S (k) (t i ). As the evaluation function E, an average error Eave and a maximum error Emax can be determined.
  • ⁇ p i ⁇ S (k) (t i ) ⁇ 2 represents the root mean square of (p i ⁇ S (k) (t i )).
  • FIG. 10 is a diagram for explaining an increase in control points P due to mesh division.
  • FIG. 10A shows an example of 13 triangular meshes.
  • one triangular mesh is divided into four triangular meshes by adding a new control point (indicated by a white circle “ ⁇ ” in the figure) to the center of the three control points in the central triangular mesh. Further, the control points added in order not to break the compatibility are connected to the control points of the outer triangular mesh, and each of the outer three triangular meshes is divided into two triangular meshes.
  • the degree of approximation can be increased by local remeshing.
  • 11 and 12 are examples of local remeshing.
  • FIG. 11 is a diagram for explaining the phase adjustment of the control point P.
  • FIG. It is known to evaluate the quality of the mesh by the order d (v) of the control points.
  • the optimum order d opt (v) at the vertex of the boundary is 4, and the optimum order d opt (v) at the other vertex is 6.
  • the evaluation function R (M) When the value of the evaluation function R (M) is compared between the mesh shown in FIG. 11A and the mesh shown in FIG. 11B, the value of the evaluation function R (M) of the mesh shown in FIG. The value is lower than the value of the mesh evaluation function R (M) shown in FIG. Therefore, the evaluation function R (M) can be lowered by changing the connection state of the mesh, which indicates that the quality of the mesh is increased.
  • FIG. 12 shows an example in which the elongated mesh is removed by adjusting the control points.
  • the angle of the triangular mesh is increased by changing from the connection state of the control points shown in FIG. 12A to the connection state of the control points shown in FIG. 12B, thereby removing the elongated mesh.
  • FIG. 13 shows changes in error and calculation time due to repetition.
  • the average error Eave reached 0.01% at the 16th iteration, and the maximum error Emax reached 0.05% at the 30th iteration.
  • the peak of the maximum error Emax that appears every fifth time is due to the adjustment of the control point.
  • Table 1 below shows the error and calculation time of each model example, and examples of the present invention and other methods. Other methods used for comparison are [Marinov and Kobbelt 2005] (Non-Patent Document 8) and [Cheng etl 2007] (Non-Patent Document 9).
  • the approximation processing of the present invention is performed using a Pentium (registered trademark) IV 3.0 GHz PC and 2 GB RAM with an average error of 0.01% and a maximum error of 0.05%.
  • Non-patent Document 8 ⁇ Comparison of the approximation processing of the present invention and the method of [Marinov and Kobbelt 2005] (Non-patent Document 8), it can be evaluated that the processing speed is about 6 times according to the present invention.
  • [Marinov and Kobbelt 2005] (Non-patent Document 8) uses a Pentium (registered trademark) 2.8 GHz PC and 2 GB RAM, and uses the mean square error instead of the mean error.
  • Non-Patent Document 9 ⁇ Comparison of the approximate processing of the present invention and the method of [Cheng et al. 2007] (Non-Patent Document 9) According to the present invention, it can be evaluated that the processing speed is about 6 times. In [Cheng et al. 2007] (Non-Patent Document 9), this is implemented using a Xeon 2.8GHz PC and 2GB RAM.
  • FIG. 14 is a diagram showing an embodiment of the approximation process of the present invention.
  • FIG. 14A shows an image of the target object to be approximated
  • FIG. 14B shows the data point superimposed on the image of the target object
  • FIG. 14C shows a triangular mesh by QEM.
  • FIG. 14D shows an error vector and a control vector
  • FIG. 14E shows an approximate curved surface obtained by the approximation process.
  • the feature point S is selected from the n + 1 point group while maintaining the shape.
  • a Douglas-Peucker Algorithm which is a method for simplifying the approximate curve.
  • This Douglas-Poiker algorithm is a method for simplifying approximate curves, and is widely used in computer graphics and geographic information systems. It can be simplified with a single edge connecting the start and end points of approximate curves. Start, find the distance to the remaining vertices for that edge, and if there are vertices whose distance from the edge is farther than the threshold, divide the approximate curve by the farthest vertex and The process of simplifying the edge is performed inductively.
  • a perpendicular line is drawn from the input point group to the curve defined by the control point P, and the vector directed to the foot input point of the perpendicular line when the perpendicular line is dropped to the music is used as the error vector.
  • the perpendicular corresponds to the closest point from the input point to the curve, and can be obtained by the Newton method.
  • the approximation method differs from the interpolation method in that the number of control points is smaller than the number of input points, so the error vector and the control point do not correspond one-to-one, and the error vector and the movement vector match. Not. Therefore, for each input point, the error vector is weighted based on the B-spline basis function for each control point that affects the span where the perpendicular falls. Each control point P is moved by a weighted movement vector to obtain a new control point P.
  • the error vector is weighted based on the B-spline basis function.
  • This weighting is performed by paying attention to k control points constituting one span.
  • a motion vector is defined by weighting the error vector based on the B-spline basis function for each control point that affects the span where the perpendicular falls.
  • FIG. 15 is a diagram for explaining weighting in the approximation of the B-spline curve.
  • the span s in which the perpendicular line descending from the input point Q to the curve falls is searched.
  • the error vector weighted by the B-spline basis function is added to each of k control points constituting the span s.
  • the control points P s ⁇ 1 , P s , P s + 1 , and P s + 2 constituting the span s are added together.
  • the above process is performed for all data points of the input point group, and the sum vector is normalized to obtain the direction vector of movement. Normalization can be performed by dividing the magnitude of the weighted error vector by the scalar amount added for each control point. Further, the movement amount is obtained by dividing the sum of the sizes (the scalar amount) by the total number of the sums and averaging.
  • the present invention can be applied not only to the subdivided curved surface and B-Spline as described above but also to NURBS and the like.
  • the present invention can be applied to reverse engineering in the field of 3D modeling.

Landscapes

  • Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Geometry (AREA)
  • Computer Graphics (AREA)
  • Mathematical Analysis (AREA)
  • Pure & Applied Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Mathematical Optimization (AREA)
  • Algebra (AREA)
  • Image Generation (AREA)
  • Image Processing (AREA)

Abstract

制御点により定義される曲線又は曲面で点群を近似する近似処理方法において、形状の特徴を保存する制御点を用いて近似曲線(近似曲面)を形成する工程と、近似曲線(近似曲面)上において、データ点に最も近い最近点を算出する第1の算出工程と、第1の算出工程で求めた最近点からデータ点を結ぶ誤差ベクトルを算出する第2の算出工程と、第2の算出工程で求めた誤差ベクトルに基づいて制御点を移動し修正後の制御点を算出する第3の算出工程とを備える。近似曲線(近似曲面)の形成工程と第1~第3の算出工程を繰り返し、近似曲線(近似曲面)をそれぞれ対象とするデータ点が構成する曲線(曲面)に近似させる。制御点の修正において、制御点の算出を単純な幾何アルゴリズムで行うことによって、制御点が収束する演算回数が低減し、線形システムを解くことなく短時間で点群のデータ点を近似する曲線又は曲面を生成する。 

Description

近似処理方法、および近似処理装置
 本発明は、点群データを近似して曲線あるいは曲面を生成する近似処理方法、近似処理装置に関する。
 自由曲面は、船、自動車、飛行機等、様々な工業製品のボディに用いられており、機能性と美しさの両方を兼ね備えるものであり、家庭電気製品や多くの消費材の外観など意匠的に美しい形状のデザイン設計に用いられる。
 近年、3Dレーザスキャナによって高密度の点群データを高速かつ容易に収集することができるようになり、物体形状を高精度で測定できることが可能と成っている。例えば、3Dモデリングの分野においては、デザイナが手作業で作成したモックアップモデルを3Dレーザスキャナで計測し、コンピュータに取り込んだ点群データやポリゴンデータをもとに製品として生産するために必要な曲面データなどのCADデータを作成していくという、いわゆるリバースエンジニアリングの手法が行われている。
 一般に、3DモデルはポリゴンモデルまたはNURBSやB-Splineなどの曲面パッチによりコンピュータ上で表現される。
 このポリゴンモデルは位相変化などの形状処理を行う上で効率的であるが、平面で構成されるため滑らかな表面を表現することができず、さらに形状を詳細に表現するほどデータ量が膨大になるなどの問題がある。
 曲面パッチは少ない制御パラメータで滑らかな曲面が表現できる反面、パッチ形状が四角形に限定される上にパッチ間の連続性を保つことが困難であるなどの問題がある。そこで、ポリゴンモデルと曲面パッチの利点を併せ持つ細分割手法が自由な幾何形状モデリングの有効な手法として注目されており、すでにアニメーションの分野では盛んに利用されている。
 細分割手法とは、初期ポリゴンメッシュに対して繰り返し規則的な分割を行うことによりその形状を滑らかにし、究極的には滑らかな曲面を得る手法である。その分割による曲面は細分割曲面(Subdivision Surface)と呼ばれ、究極的な曲面は極限曲面と呼ばれる。細分割手法は任意の位相を持つモデルに対しても簡単に滑らかな曲面を生成できるという特徴を持ち、さらにどの部分においても曲面が滑らかなに定義されるためモデリングなど幅広い利用が進んでいる。
 リバースエンジニアリングの分野において、従来、細分割曲面、B-Spline、NURBS等を用いることによって、測定した点群データを近似して曲面を生成する方法が提案されている。点群のデータ点を近似あるいは補間する従来提案される方法では、データ点から得られる初期制御点と生成される曲面との距離誤差が最小となるように制御点を逐次求める演算処理を行っている。この制御点を求める演算は、点群の列をS、この点群を近似する曲面と生成するための制御点の列をP、曲面を定める基底関数マトリックスをAとしたとき、AP=Sで表される線形の行列式を解くことで行われる。
 従来提案されている近似方法として、例えば、Halstedらが提案する多面体メッシュに対するCatmull-Clark細分割曲面の補間手法が知られている(非特許文献1)。この手法は大規模な線形システムを解く必要があるばかりでなく、さらにフェアリングと呼ばれる曲面修正のために最小化問題を解く必要があり、非常に計算コストが大きくなる。
 また、Hoppeらは、点群のデータ点に対するLoop細分割曲面の近似手法として、細分割操作を行ったポリゴンメッシュを線形近似した細分割曲面とみなし、その曲面に対して各点からの正射影を行うことでパラメータ化し、各点とそれに対する線形近似した細分割曲面上の点との距離が最小となる最小自乗問題として扱う手法を提案している。(非特許文献2)
 Hoppeら(非特許文献2)の方法は線形近似した面でパラメータ化を行っているのに対し、MarinovとKobbeltはStamの理論を用いて極限曲面上でパラメータ化を行っている。しかし、制御点の算出には大規模な線形システムを解いており多大な時間を要する。(非特許文献8)
 SDM法(Squared Distance Minimization)を応用し、点群にLoop細分割曲面をフィットさせる方法が提案されている。この方法では、初期曲面から二乗距離関数を局所的に二次近似した目的関数を逐次的に変形させ目標曲面に変形させている。この方法も線形システムを解いているため計算に多大な時間を要している。(非特許文献9)
 また、B-Spline曲線、曲面の補間において与えられた点群とその点群より生成された曲線、曲面のノットの関係を利用した手法が提案されている。この方法では、与えられた点群とノットとの距離を移動ベクトルとし、そのベクトル分対応する制御点を移動させ、この処理を点とノットとの距離が0になるまで繰り返す。だたし、両端で2重制御点を採用しているため、CADデータには利用できない。また、ノットとの誤差ベクトルを用いるため、うねりを生じる場合も出てくる。(非特許文献10)
M.Halsted, M.Kass and T.DeRose.Efficient,fair interpolation using Catmull-Clark surfaces.In Eugene Fiume,editor.Proceedings of SIGGRAPH 1993,pages47-61.ACM,ACM Press / ACM SIGGRAPH, 1993 H.Hoppe, T.DeRose, T.Duchamp and M.Halsted. Piecewise smooth surface reconstruction.In Proceedings of SIGGRAPH 1994,pages 47-61.ACM,ACM Press / ACM SIGGRAPH, 1994 M.Garland and P.S.Heckbert.Sueface simplification using quadric error metrics. In Proceedings of ACM SIGGRAPH 97,209-216. C.T.Loop.Smooth subdivision surface based on triangle. Masters thesis, Department of Mathematics. University of Utha.1987/. E.Catmull and J.Clark. Recusively generated b-spline surfaces on arbitrary topological meshes.Computer-Aided Design,10(6):350-355,1987. D.Doo and M.Sabin. Behavior of recursive division surfaces near extraordinary points.Computer-Aided Design,10(6):356-360,1978. G.M.Chaikin.An algorithm for high-speed curve generation. Computer Graphics and Image Processing,3:346-349,1974. M.Marinov and L.Kobbelt, Optimization methods for scattered data approximation with subdivision surface,Graphical Models 67,2005,452-473. K-S.D.Cheng, Wang.W, Qin.H, K-Y.K.Wong, Yang.H and Liu.Yang.2007.Design and analysis of optimization methods for subdivision surface fitting. IEEE Transaction on Visualization and Computer Graphics 13,5,878-890. Lin. H, Wang. G, and Dong. C. 2003. Constructing iterative non-uniform B-spline curve and surface to fit data points. Science in China 33, 912-923.
 上記した、細分割曲面、B-Spline、NURBS等を用いて点群のデータ点を近似する従来提案される方法において、近似あるいは補間の演算を行列式を解くといった線形システムの解法を用いる方法では、その線形システムの演算の性質上、点群のデータ点及び制御点の個数が増加するほど演算回数が増加する。一般に、3Dモデリングに要する点群及びこの点群から形成される制御点の個数は多数であるため、点群から曲面を生成する演算は大規模な線形システムを解く演算となり、多大な計算時間を要するという問題がある。
 さらに、円滑な曲面を得るには、初期制御点と生成される曲面との距離誤差が最小となるまで、大規模な線形システムを解く演算処理を繰り返す必要があり、所望とする円滑な曲面を得るには膨大な時間を要することになる。
 そこで、本発明は前記した従来の問題点を解決し、点群のデータ点を近似する曲線又は曲面の生成において、演算時間を短縮することを目的とし、線形システムを解くことなく点群を近似する曲線又は曲面を生成する方法及び装置を提案することを目的とする。
 本発明は、点群のデータ点の形状を曲線又は曲面で近似する近似処理において、点群のデータ点によって形成される折線あるいはメッシュから、形状の特徴を保持した特徴点を選択して制御点とし、この制御点によって曲線又は曲面を近似する。本発明は、この制御点を順次修正して近似度を高める際に、修正した各制御点の算出を単純な幾何アルゴリズムによって行うことによって、線形システムを解くための多大な計算時間を要すること無く短時間で近似を可能とするものである。
 なお、制御点によるフィッティングでは補間手法と近似手法が知られているが、補間手法はデータ点のデータ数と同数の制御点によって点群のデータ点をフィッティングするのに対して、近似手法ではデータ点のデータ数より少ない制御点によって数で点群のデータ点をフィッティングするものである。
 点群のデータ点から形状を保持して制御点を選択する手法としてQEM(Surface simplification using quadric error metrics:非特許文献3)を用いることができる。
 本発明は、点群のデータ点を開始データとし、このデータ点からQEM等の処理によって制御点を求め、算出工程によって制御点を順次修正する他、点群のデータ点とこのデータ点から選択した制御点とが既知である場合には、算出工程によって既知の制御点から順次修正してもよい。この制御点が既知である場合には、点群のデータ点から制御点を選択する処理を省くことができる。
 本発明において、制御点の移動は、与えられた点群の各データ点に対して最も近い曲線又は曲面上の最近点をニュートン法によって算出し、算出した最近点から各データ点に結ぶ誤差ベクトルを求め、この誤差ベクトルによって制御点を逐次的に移動させて近似を行う。この制御点を移動する処理は、線形システムを解くことなく幾何アルゴリズムの処理で行うことができるため、高速処理を行うことができる。
 本発明の方法は幾何アルゴリズムの処理で各制御点を扱うことになるため、線形システム自体を必要としない上に、幾何的なプロセスのみで近似曲線又は近似曲面を生成することができる。したがって、従来の方法と比べ処理を高速化することができる。
 なお、本発明は、三次元に限らず二次元についても同様に適用することができ、三次元上の点群のデータ点を近似する細分割曲面を生成するほか、二次元上の点群のデータ点を近似する曲線の生成にも適用することができる。
 また、本発明は、近似処理に関して、方法および装置の態様とすることができる。近似処理装置は、この近似処理方法をソフトウエアあるいはハードウエアによって実行させるための各手段を備える。
 本発明の近似処理方法は、制御点により定義される曲線又は曲面によって点群のデータ点を近似する近似処理方法において、形状の特徴を保存する制御点を用いて近似曲線又は近似曲面を形成する工程と、制御点の修正位置を算出する算出工程とを備える。
 制御点の修正位置を算出する算出工程は、近似曲線又は近似曲線上においてデータ点に最も近い最近点を算出する第1の算出工程と、第1の算出工程で算出した最近点からデータ点を結ぶ誤差ベクトルを算出する第2の算出工程と、第2の算出工程で求めた誤差ベクトルに基づいて制御点を移動して修正後の制御点を算出する第3の算出工程とを含む。
 近似曲線又は近似曲面を形成する工程および各算出工程は、幾何アルゴリズムが組み込まれた演算手段により行うことができる。幾何アルゴリズムにより近似曲線又は近似曲面の形成工程と第1~第3の算出工程を繰り返すことによって、近似曲線又は近似曲面をそれぞれ対象とするデータ点が構成する曲線又は曲面に近似させる。
 本発明の近似処理方法に用いる点群のデータ点は、例えば、三次元形状計測器等によって取得することができる。最初の制御点は、与えられた点群のデータ点を結んで折れ線又はメッシュを形成し、この折れ線又はメッシュからQEM等の処理によって形状の特徴を保存した点を選択することで取得することができる。この点を初期制御点として、第1~第3の算出工程によって制御点の位置を修正する。
 この制御点の修正位置を算出する算出工程は単純な幾何処理であるため、従来の方法で必要な線形システムを解く必要がなくなる。
 第1の算出工程は、ニュートン法によって近似曲線又は近似曲線上においてデータ点に最も近い最近点を算出することができる。
 第2の算出工程は、点群の全データ点において、各データ点についてそのデータ点と最近点とを結ぶ誤差ベクトルを算出する工程である。
 第3の算出工程は、第2の算出工程で算出した誤差ベクトルに基づいて各制御点を移動することによって修正した制御点を算出する工程であり、第2の算出工程で算出した複数の誤差ベクトルの内、修正を行う制御点の周囲にある最近点について算出した誤差ベクトルに重み付け処理を行い、この重み付けした誤差ベクトルをベクトル加算し、ベクトル加算で得た加算ベクトルを移動ベクトルとして、修正対象の制御点を移動し、移動後の制御を修正制御点として算出する。
 制御点の移動に用いる誤差ベクトルは、第2の算出工程において制御点の周囲の最近点で算出した誤差ベクトルをベクトル加算することで求める。このベクトル加算において、誤差ベクトルに重み付けを行うことによって、制御点が収束するまでの演算回数を低減させることができる。
 第3の算出工程における重み付け処理は、各誤差ベクトルに係数を乗じる演算処理によって行うことができる。この係数は制御点と最近点との距離に応じて定め、制御点に近い最近点により大きな値を設定し、制御点から遠い最近点により小さな値を設定することによって重み付けを行う。制御点に近い最近点ほど制御点との関連性が高いと想定され、制御点に近い最近点の誤差ベクトルに対して大きな値の係数で重み付けすることで、制御点が収束するまでの演算回数を低減させることができる。
 重み付けを行う係数は、重心座標系(barycentric coordinate)に従って定めることができる。
 本発明の近似処理は、データ点とこのデータ点に対応する最近点との距離に基づいて、近似曲線又は近似曲面の近似誤差を算出し、算出した近似誤差が所定値未満となるまで制御点の算出処理を繰り返す。
 近似曲面の形成において、制御点の移動による近似処理を所定回数繰り返しても近似誤差が所定値未満とならない場合には、制御点で形成されるメッシュの面分割を行って、制御点数を増加させたり、制御点で形成されるメッシュを局所的に再メッシュ化する。近似誤差が所定値未満となるまで制御点の算出工程と、面分割による制御点の増加や局所的な再メッシュ化とを繰り返す。
 また、近似曲線の形成において、制御点の移動による近似処理を所定回数繰り返しても近似誤差が所定値未満とならない場合には、ノット挿入によって制御点数を増加させる。近似誤差が所定値未満となるまで制御点の算出工程と制御点の増加とを繰り返す。
 本発明の近似処理装置は、制御点により定義される曲線又は曲面によって点群のデータ点を近似する近似処理装置であり、形状の特徴を保存する制御点を用いて近似曲線又は近似曲面を形成する工程と、近似曲線又は近似曲面上において、データ点に最も近い最近点を算出する第1の算出工程と、第1の算出工程で求めた最近点からデータ点を結ぶ誤差ベクトルを算出する第2の算出工程と、第2の算出工程で求めた誤差ベクトルに基づいて制御点を移動し修正後の制御点を算出する第3の算出工程の各工程を行う演算手段を備える。
 演算手段は、近似曲線又は近似曲面を形成する工程、および各算出工程を行う幾何アルゴリズムをソフトウエアで実行するためのCPU及び記憶装置、又は各幾何アルゴリズムをハードウエアで実行するための回路によって構成することができる。近似曲線又は近似曲面の形成工程と第1~第3の算出工程の演算を繰り返して行うことによって、近似曲線又は近似曲面をそれぞれ対象とするデータ点が構成する曲線又は曲面に近似させる。
 曲面は、三角形メッシュによるLoop細分割(非特許文献4)、B-Spline、NURBS、四角形メッシュによるCatmull-Clark細分割(非特許文献5)、Doo-Sabin細分割(非特許文献6)等の細分割等で定められる制御点により定義することができる。
 また、曲線については、B-Spline曲線や、Chaikin細分割(非特許文献7)で定められる制御点により定義することができる。なお、Chaikin細分割は2次のB-Spline曲線に収束し、一般的にn次のB-Spline曲線についても近似を行うことができる。
 以上説明したように、本発明によれば、点群のデータ点を近似する曲線又は曲面の生成において、演算時間を短縮することができる。
 また、本発明によれば、線形システムを解くことなく点群のデータ点を近似する曲線又は曲面を生成することができる。
本発明の近似処理の概略を説明するための概略図である。 本発明の近似処理の概略を説明するためのフローチャートである。 本発明の近似処理装置の概略構成図である。 本発明の近似処理を実施する工程を説明するための概略図である。 本発明の近似処理を実施する工程を説明するための概略図である。 近似曲面S(k)上の最近点S(k)(ti)を説明するための図である。 本発明の近似処理を実施する工程を説明するためのフローチャートである。 誤差ベクトルe(k) iの重み付けを説明するための図である。 制御点の周りの誤差ベクトルe(k) i,jを説明するための図である。 制御点Pの増加を説明するための図である。 局所的な再メッシュの一例を説明するための図である。 局所的な再メッシュの一例を説明するための図である。 本発明による結果例を示す図である。 本発明の近似処理の一実施例を示す図である。 本発明のB-Spline曲線の近似における重み付けを説明するための図である。
符号の説明
 1…入力手段
 2…記憶手段
 2a…データ記憶部
 2b…演算ツールプログラム記憶部
 2c…演算プログラム処理プログラム部
 2d…一次記憶部
 2e…演算記憶部
 3…演算手段
 4…表示手段
 5…出力手段
 以下、本発明の実施の形態について、図を参照しながら詳細に説明する。
 図1は本発明の近似処理の概略を説明するための概略図、図2は本発明の近似処理の概略を説明するためのフローチャート、図3は本発明の近似処理装置の概略構成図である。
 図1,図2は、点群Pのデータ点piから近似曲面Sを求める手順を概略的に示している。なお、ここでは、3Dレーザスキャナ(3次元形状計測器)等から得られた高密度・不規則な点群Pのデータ点piから開始し、この点群Pのデータ点piで形成されるメッシュからQEM等の手法によって形状の特徴を表す制御点を求め、この制御点から最終的な近似曲面Sを得る手順によって示している。
 また、点群のデータ点とこのデータ点から選択した制御点とが既知である場合には、既知の制御点を用いて順次修正し近似曲面Sを得る手順に適用してもよい。
 なお、ここでは、主に曲面について説明するが、曲線についても同様に扱うことができる。また、以下のフローチャートでは、データ点を測定する工程から開始する場合について示している。
 はじめに、3Dレーザスキャナ等の三次元計測器によって対象物を測定し点群pのデータ点piを求める(図1(a))(S1)。測定して得られた点群pのデータ点piを連結してメッシュ化する。ここでは三角形メッシュの例を示している(図1(b))(S2)。
 データ点piにより形成される三角形メッシュから、元の対象物の形状特徴を保持しつつ簡略化し制御点とする。この制御点により制御メッシュが形成される。メッシュは三角形メッシュや四角形メッシュを用いることができる。この特徴を残すメッシュの簡略化の処理は、例えば、QEM等の既存の手法を用いることができる。
 ここで、最初の制御点P(0)から形成したメッシュを初期制御メッシュM(0) nとし、以後、制御点を変更して得られるメッシュを制御メッシュMnとする。ここで、添え字の0は初期段階を表し、nは制御点数を表すものとする(図1(c))(S3)。
 初期制御メッシュM(0) nの制御点P(0)を用いて初期近似曲面S(0)を生成する(図1(d))(S4)。S4で生成した初期近似曲面S(0)上において点群pの各データ点piに対応する初期最近点S(0)(ti)を求める(S5)。
 この初期最近点S(0)(ti)からデータ点piに対する誤差ベクトルeiを求め(図1(e))、初期制御点P(0)の周囲に存在する誤差ベクトルeiを用いて初期制御点P(0)の位置を移動する移動ベクトルdを求める。初期制御点P(0)の周囲に複数の誤差ベクトルeiが存在する場合には、これらの複数の誤差ベクトルeiをベクトル加算して移動ベクトルdを求める(S6)。
 求めた移動ベクトルdによって初期制御点P(0)の位置を移動し、位置を修正した制御点を制御点P(k)とする(S7)。
 次回の処理では、最近点S(k)(ti)からデータ点piに対する誤差ベクトルeiを求め(図1(e))、制御点P(k)の周囲に存在する誤差ベクトルeiを用い、複数の誤差ベクトルeiが存在する場合には、これらの複数の誤差ベクトルeiについてベクトル加算し、制御点P(k)の位置を移動する移動ベクトルdを求め(S6)、求めた移動ベクトルdによって制御点P(k)の位置を移動し、位置を修正した制御点を制御点P(k+1)とする(図1(f))(S7)。
 なお、制御点P(k)の添え字(k)は繰り返しの回数を表し、(k)回目の工程で得られる制御点をP(k)で表している。初期制御点P(0)は添え字(0)を上付して表し、その後に繰り返して得られる制御点P(k)の添え字(k)は繰り返し毎に“1”増やすことによって、繰り返し回数を添え字(k)の“k”の数値で表すことができる。
 移動ベクトルdによって移動して得られた制御点P(k)を用いて近似曲面S(k)を生成する(図1(g))(S8)。S8で生成した近似曲面S(k)上において点群pの各データ点piに対応する最近点S(k)(ti)を求める(S9)。
 上記したS6~S9の工程を繰り返すことによって、制御点P(k)を順次移動して修正することによって近似曲面S(k)を対象体の形状に近似させる。
 近似曲面S(k) が対象体の形状に近似したか否かの評価は以下のS10~S11の工程で行い、近似曲面S(k)の近似の程度が予め定めた許容値を満足しない場合には、S6~S9の工程を繰り返して行う制御点の移動、あるいは、S13~S15の工程によってメッシュの分割によって制御点を増加させる。
 近似曲面S(k)が対象体の形状に近似したか否かの評価は、最近点S(k)(ti)とデータ点piと絶対値誤差から誤差Eを求め(S10)、求めた誤差Eを予め定めておいた許容値と比較し(S11)、誤差が許容値内とならない場合には、S6~S9の工程を繰り返して制御点の移動することで近似の程度を向上させ、また、S13~S15の工程によってノットの挿入によって制御点を増加させる。
 S13~S15の工程によるメッシュの分割は、S6~S9の工程を設定回数分繰り返しても誤差が許容値内とならない場合に行う(S12)。
 S12において、S6~S9の工程を設定回数分繰り返しても誤差が許容値内とならない場合には、制御メッシュMnにおいて、誤差が許容値内とならない箇所の制御メッシュを分割し(図1(i))(S13)、分割で得られた制御メッシュMmを用いて近似曲面Smを求める(図1(j))(S14)。なお、ここで、制御メッシュMmの添え字“m”は制御メッシュMnと異なるメッシュ構成であることを表し、近似曲面Smは制御メッシュMmを用いて形成した近似曲面であることを表している。
 求めた近似曲面Smについて最近点S(ti)を求め(図1(k))(S15)、S6に戻り制御メッシュMmの移動ベクトルdの算出を行う。
 近似処理によって距離誤差が許容範囲内に収束したときに得られる近似曲面Sは、点群pのデータ点piを近似する近似曲面となる。
 本発明の工程は幾何アルゴリズムの演算によって行われる。例えば、S5,S9の工程では、初期近似曲面S(0)あるいは近似曲面S(k)上において、データ点piに最も近い初期最近点S(0)(ti)あるいは最近点S(k)(ti)をニュートン法で算出し、S7の工程では、データ点piと最近点S(k)(ti)との誤差ベクトルeiを求め、この誤差ベクトルeiを用いて制御点P(k)を移動する制御ベクトルdを求める。求めた制御ベクトルdによって制御点P(k)を移動し、S8の工程では移動した制御点P(k+1)を用いて近似曲面S(k+1)を求める。
 なお、曲面を細分割処理する場合には、例えば、三角形メッシュによるLoop細分割、四角形メッシュによるCatmull-Clark細分割、Doo-Sabin細分割等を用いることができ、また、B-Spline曲面についても適用することができる。また、曲線の細分割として、例えば、Chaikin細分割を用いることができる他、n次のB-Spline曲線についても適用することができる。なお、Chaikin細分割は2次のB-Spline曲線に収束する。
 本発明の近似処理によれば、計算コスト、演算の一般性の点で以下の利点がある。本発明の近似処理では、制御点の修正を幾何アルゴリズムによって行うことによって、線形システムを解く必要がないため、処理の演算速度を向上させることができる。
 また、本発明の近似のアルゴリズムは、単純な幾何プロセスにより曲面生成を行っており、細分割曲面のみならず、B-Spline曲面や曲線など、制御点により定義される曲線、曲面に対して適用することができ、曲面生成について一般性を有する。
 図3は、本発明の近似処理のソフトウエアを記憶したプログラムをコンピュータで実行させる場合の一構成例を示している。
 入力手段1は、点群pのデータ点piを入力し、記憶手段2中のデータ記憶部2aに記憶する。記憶手段2は、データ記憶部2aの他に、幾何処理の演算を行う演算ツールのプログラムを記憶する演算ツール記憶部2b、近似処理の演算の他、細分割処理等の演算処理のプログラムを記憶する演算処理プログラム記憶部2c、途中演算結果等を一時的に記憶する一時記憶部2d、近似処理によって得られた曲面の演算結果を記憶する演算結果記憶部2e等を備える。
 データ記憶部2aは、点群pのデータ点piを記憶する他、点群pのデータ点piから形成し三角形メッシュ、あるいは、メッシュからQEM等によって生成した初期制御メッシュM(0) nを記憶してもよい。
 演算手段3は、演算処理プログラム記憶部2cに記憶されるプログラムによる演算手順に従い、また、このプログラムに指定される演算ツールのプログラムを演算ツール記憶部2bから逐次読み出して演算処理を行う。
 演算手段3で行う演算としては、例えば、データ記憶部2aに記憶された点群pのデータ点piから三角形メッシュを形成する演算処理、メッシュから初期制御点P(0)を求めて初期制御メッシュM(0) nを生成する演算処理、初期制御メッシュM(0) nを用いて行う初期近似曲面S(0)を生成する演算処理、制御メッシュMnを用いて行う近似曲面S(k) nの生成を行う演算処理、初期近似曲面S(0)上においてデータ点piに最も近い初期最近点S(0)(ti)をニュートン法で算出する演算処理、近似曲面S(k) n上においてデータ点piに最も近い最近点S(k)(ti)をニュートン法で算出する演算処理、データ点piと初期最近点S(0)(ti)との誤差ベクトルei、データ点piと最近点S(k)(ti)との誤差ベクトルeiを求め、この誤差ベクトルeiを用いて制御点P(k)を移動する制御ベクトルdを算出するベクトル演算を行う演算処理、制御ベクトルdによって制御点Pを移動する演算処理等がある。
 演算結果記憶部2eに記憶された演算結果は、読み出されて表示手段4に表示したり、出力手段5に出力することができる。出力手段5は、演算結果を記録媒体に記録する記録装置、演算結果を用いて所定動作を行う加工装置等の外部装置とすることができる。
 なお、上記、ソフトウエア処理を行う構成は、専用のソフトウエア処理装置や、通常のパーソナルコンピュータに適用することができる。
 また、上記構成において、記憶手段を含む演算手段で実施される機能を回路で構成することでハードウエアにより実施することもできる。
 次に、本発明の近似処理の詳細について、三次元の点群から近似曲面を生成する場合について、図2のフローチャート,図4~図13の説明図を用いて説明する。以下のフローは一例であり、本発明の近似処理を実施する工程及び手順であれば他のフローで構成してもよい。
 近似のアルゴリズムの流れは、与えられた点群の三角形メッシュから、形状の特徴を保持する初期制御メッシュをQEM等によって生成し、この初期制御メッシュから初期近似曲面を生成する。次に、データ点から制御メッシュ(1回目は初期制御メッシュ、2回目以降は制御点を移動した制御メッシュ)より生成される近似曲面上で最も近い最近点を求め、このデータ点から最近点への誤差ベクトルを求め、この誤差ベクトルを用いて制御点を移動して新たな近似曲面を生成する。この制御点の移動と移動後の制御点による近似曲面の生成の工程を繰り返すことにより、元の形状により近似した近似曲面を求める。
 以下、図4~図13を用いて幾何アルゴリズムによる近似処理を説明する。三次元計測器によって点群pのデータ点piを求め、各データ点piを結んで、例えば、三角形メッシュによりメッシュ化する。図4(a)、(b)は点群pのデータ点piとメッシュ化で形成した三角形メッシュを模式的に示している。
 なお、点群pのデータ点piに加えて、このデータ点piから三角形メッシュを予め求めて記憶手段に記憶しておき、記憶手段から読み出しても良い。三次元の制御メッシュは、三角形メッシュの他に、四角形メッシュを用いてもよい。三角形メッシュの細分割手法としてはLoop細分割(非特許文献4)が知られ、四角形メッシュの細分割手法としてはCatmull-Clark細分割(非特許文献5)、Doo-Sabin細分割(非特許文献6)等が知られている。
 三角形メッシュから、よく知られたQEM(Surface simplification using quadric error metrics:非特許文献3)等の処理方法で初期制御点P(0)からなる初期制御メッシュM(0) nを生成し、初期制御メッシュM(0) nの制御点P(0)を記憶部2aに記憶する。記憶した初期制御点P(0)を用いて初期近似曲面S(0)を生成する。なお、初期制御メッシュM(0) nによって生成される初期近似曲面を近似曲面S(0)で表す。以後、制御点を移動することで生成される制御メッシュMnによってk回目に生成される近似曲面を近似曲面S(k) nで表す。
 図4(a)は点群pのデータ点piを示し、図4(b)は点群pのデータ点piとデータ点piから生成した制御メッシュMnとを示している。図4(c)は、点群pのデータ点piから生成した制御メッシュMnと、制御メッシュMnによって生成される近似曲面S(k) nを示している。ここで、実線は制御メッシュMnを示し、白抜きの丸印“○”は制御メッシュMnの制御点Pを示している。破線は近似対象の曲面を示し、データ点pi(図4(c)には示していない)はこの近似対象の曲面上の点である。図4(c)は、近似曲面S(k)と近似対象曲面との間には誤差がある状態を示している。
 図5(a),(b)は、近似曲面S(k)が近似対象曲面に近づく状態を示している。なお、データ点piは図5中では黒丸“●”で示している。近似曲面S(k)は、制御点Pによって近似対象の曲面に近似するように形成される。
 制御点Pを移動することによって近似曲面S(k+1)を求める。制御点Pの移動を繰り返すことによって、近似曲面S(k+1)と近似対象曲面との間の誤差は減少し、近似対象曲面に逐次近づいていく。制御点Pの移動は、データ点piと、近似曲面S(k)上でデータ点piに最も近い最近点S(k)(ti)との誤差ベクトルeiに基づいて行う。
 図5は、データ点piと、近似曲面S(k)上においてデータ点piに最も近い最近点S(k)(ti)との関係を示している。図5(a)において、最近点S(k)(ti)は近似曲面S(k)上においてデータ点piに最も近い点であり、図中では×印で示している。また、図5(b)において、最近点S(k+1)(ti)は近似曲面S(k+1)上においてデータ点piに最も近い点であり、図中では×印で示している。
 図5(a)は移動前の制御点P(k)とこの制御点P(k)による近似曲面S(k)を示し、図5(b)は移動後の制御点P(k+1)とこの制御点P(k+1)による近似曲面S(k+1)を示している。制御点を移動することによって形成された近似曲面S(k+1)は近似対象の曲面に漸近する。
 図6は、近似曲面S(k)上の最近点S(k)(ti)を説明するための図である。図6において、Tpは接平面、piはデータ点、S(v,w)はパラメータ(v,w)における近似曲面上の点、iはデータ点番号を示している。
 1つのデータ点から近似曲面への垂線は次式により与えられる。
  [(p-S(v,w))・Sv (v,w)]=0
  [(p-S(v,w))・Sw (v,w)]=0             …(1)
 なお、vとwは曲面のパラメータであり、Sv、Swは細分割曲面Sのv、w方向の微分を示している。
 各データ点piから、制御点によって張られる細分割曲面S上の最短距離となる点は、Marinov and  Kobbelt(非特許文献8)によると、pから接平面Tpへの垂線を求める曲面のパラメータ(Δv、Δw)に関する以下の式を解くことにより求めることができる。
  [p-(S(v,w)+Sv(v,w)Δv+Sw(v,w)Δw)]・Sv(v,w)]i j=0 
  [p-(S(v,w)+Sv(v,w)Δv+Sw(v,w)Δw)]・Sw(v,w)]i j=0 …(2)
 ここで、iはデータ点番号、jはパラメータ化におけるニュートン法の繰返し回数であり、(Δv,Δw)は曲面のアップデートパラメータである。
 データ点piと最近点S(k)(ti)との間の誤差はベクトルによって表すことができる。ここでは、データ点piから最近点S(k)(ti)への誤差ベクトルeiによって表す。図5中では、この誤差ベクトルeiは、データ点piと最近点S(k)(ti)あるいはS(k+1)(ti)とを結ぶ直線で示している。
 本発明は、制御点Pの周囲に存在するデータ点piについて、そのデータ点piと最近点S(k)(ti)との誤差ベクトルeiを求め、複数の誤差ベクトルeiがある場合には、これらの誤差ベクトルeiをベクトル加算して移動ベクトルdを求め、この移動ベクトルdによって制御点Pを移動することによって新たな制御点P(k+1)を求める。この制御点の移動状態は、前記の図5に示している。図5(a)は移動前の制御点P(k)とこの制御点P(k)による近似曲面S(k)を表し、図5(b)は移動後の制御点P(k+1)とこの制御点P(k+1)による近似曲面S(k+1)を表している。
 制御点P(k)を誤差ベクトルeiを用いて移動する際、各データ点piおよび最近点S(k)(ti)により求めた各誤差ベクトルeiに重み付けし、重み付けした誤差ベクトルeiをベクトル加算して移動ベクトルdを求める。なお、制御点P(k)の周囲にデータ点piが1点のみしか存在しない場合には、この1点のデータ点piに対応する最近点S(k)(ti)を求め、このデータ点piと最近点S(k)(ti)との誤差ベクトルeiに重み付けを行った誤差ベクトルeiを移動ベクトルdとする。
 また、重み付けを行う誤差ベクトルeiは制御点Pの周囲に存在する。制御点Pの周囲として、例えば、制御点P(k)を共通の頂点とするメッシュが生成する近似曲面内とすることができ、これらメッシュは制御点P(k)を中心として1ループを形成している。制御点P(k)の周囲に存在するメッシュは各制御点に応じて異なり、また、各メッシュに対応して存在する誤差ベクトルeiも各メッシュに応じて異なるため、重み付けを行う誤差ベクトルeiの個数は一定ではないが、誤差ベクトルeiを形成するデータ点piおよび最近点S(k)(ti)は、点群のデータ点の点数により定まっているため、全制御点Pについて用いる誤差ベクトルeiの個数は一定である。
 ここで、重み付けを行う程度は、制御点Pと最近点S(k)(ti)との距離に応じて定めることができる。制御点P(k)の近くに存在するデータ点piに係わる誤差ベクトルeiに対しては重み付けの程度を大きく設定し、制御点Pから遠くに存在するデータ点piに係わる誤差ベクトルeiに対しては重み付けの程度を小さく設定する。この重み付けを行うことによって、近似曲面Sを得るための繰り返し回数を低減させることができる。
 以下、図7のフローチャートおよび図8の説明図を用いて誤差ベクトルeiの重み付けについて説明する。図8では、制御点P(k)の周囲に形成される複数の三角形メッシュの内の一つの三角形メッシュ(図8中の太い実線が形成される三角形)について示している。図8において、三角形メッシュを太い実線で示し、この三角形メッシュに対する近似曲面Sに濃淡を付して示している。
 図8において、黒丸“●”で示すデータ点piは近似対象の曲面上の点であり、×印で示す最近点S(k)(ti)はデータ点piに最も近い点であり、データ点piと最近点S(k)(ti)との間の矢印は誤差ベクトルe(k) i,Jを示している。なお、図8では、三角形メッシュおよび近似曲面Sにおいて、データ点piと最近点S(k)(ti)と誤差ベクトルe(k) i,Jの1組のみを示している。“J”は制御点Pの周囲に存在するJ番目の最近点S(k)(ti)を表している。
 制御点P(k)の移動は、この制御点P(k)の周囲に存在する誤差ベクトルe(k) i,Jに重み付けし、さらに、重み付けした重み付け誤差ベクトルe*(k) i,Jをベクトル加算して求めた加算誤差ベクトルΣe*(k) i,Jを用いて行う。なお、“*”は重み付けしたことを表している。
 この誤差ベクトルe(k) i,Jの重み付けは、その最近点S(k)(ti)と制御点P(k)との距離に応じて行う。重み付け処理は、誤差ベクトルe(k) i,Jに重み付け係数u(k) i,Jを乗じることによって行うことができる。
 重み付け処理において、制御点Pの近くに存在する誤差ベクトルe(k) i,Jに対しては、重み付け係数u(k) i,Jの値を大きく設定して乗じ、制御点Pから遠くに存在する誤差ベクトルe(k) i,Jに対しては、重み付け係数u(k) i,Jの値を小さく設定して乗じる。ここで、重み付け係数u(k) i,Jは、u(k) i,J=1.0-v(k) i,J-w(k) i,Jで表される重心座標系(barycentric coordinate)を用いることができる。この重心座標系(barycentric coordinate)による重み付け係数u(k) i,Jは、図8において近似曲面S(k)上の曲線で表される。
 この重み付け係数u(k) i,Jを用いることによって、重み付けされた誤差ベクトル*(k) i,J
  e*(k) i,J=u(k) i,J・e(k) i,J    …(3)
  J=1,…,m
で表される。なお、mは制御点P(k)を共通の頂点としてその周囲に形成される複数の近似曲面S上に存在する最近点S*(k)(ti)の個数である。また、制御点P*(k)における重み付け係数u(k) i,Jは“1”であり、制御点P*(k)から離れた近似曲面Sの縁部における重み付け係数u(k) i,Jは“0”である(S6a)。
 次に、制御点P(k)の周囲に存在する全最近点S(k)(ti)について、重み付けした重み付け誤差ベクトルe*(k) i,Jを加算して正規化することによって、制御ベクトルdを求める(S6b)。
 図9は、制御点の周りの誤差ベクトルe(k) i,Jを説明するための図である。
 各三角形メッシュが形成するそれぞれの近似曲面S(k)において、各最近点S(k)(ti)についてデータ点piからの誤差ベクトルe(k) i,Jに重み付けを行って重み付け誤差ベクトルe(k) i,Jを求める。
 一つの制御点P(k)にはその制御点P(k)を共通の頂点とする複数の三角形メッシュが存在し、各三角形メッシュが形成する近似曲面S(k)にある最近点S(k)(ti)について重み付けられた誤差ベクトルe*(k) iが生成されるため、一つの制御点P(k)に複数の重み付け誤差ベクトルe*(k) i,Jが生成される。制御点P(k)において、これらの重み付け誤差ベクトルe*(k) i,Jを加算して制御点を移動する制御ベクトルd(k)を求める。
 制御点P(k)を移動する制御ベクトルd(k)は、
  d(k)=ΣJ*(k) i,J/Σu(k) i,J     …(4)
で表される。Σu(k) i,Jは重み付け係数u(k) i,Jの加算値であり、この加算値で誤差ベクトルe*(k) i,Jの加算値(ΣJ*(k) i,J)を除算することで正規化する。
 この制御ベクトルd(k)によって制御点P(k)を移動することで新たな制御点P(k+1)を生成する。求めた新たな制御点P(k+1)に基づいて近似曲面S(k+1)を求める。
 ここで、誤差関数Eを用いた近似処理の近似の程度の評価について説明する。評価関数Eは、データ点piと最近点S(k)(ti)との絶対値誤差を算出する。評価関数Eとして、平均誤差Eaveと最大誤差Emaxを定めることができる。
 それぞれ次式で定めることができる。
  平均誤差Eave=Σn i=1∥pi-S(k)(ti)∥2/n    …(5)
  最大誤差Emax=max1≦i≦n∥pi-S(k)(ti)∥2    …(6)
 なお、∥pi-S(k)(ti)∥2は、(pi-S(k)(ti))の自乗平均を表している。
 前記した図2のフローチャートのS10の誤差Eと許容値との比較において、求めた平均誤差Eaveと最大誤差Emaxについて予め定めておいた許容値と比較し、平均誤差Eaveおよび最大誤差Emaxが許容範囲内となるまで、S6~S9の工程を繰り返す。
 S6~S9の工程による制御点の移動を所定回数繰り返しても、誤差Eaveおよび最大誤差Emaxが許容範囲内に収束しない場合には(S12)、メッシュを分割して、制御点Pを増加して(S13)、近似曲面Sm、最近点S(k)(ti)を求め(S14,15)、平均誤差Eaveおよび最大誤差Emaxが許容範囲内となるまで、再度S6~S9の工程を繰り返す。
 図10は、メッシュの分割による制御点Pの増加を説明するための図である。図10(a)は、13個の三角形メッシュの例を示している。
 一例として、中央の三角形メッシュにおいて、3つの制御点の中央に新たに制御点(図中の白丸“○”で示す)を加えることによって、1つの三角形メッシュを4つの三角形メッシュに分割する。さらに、互換性を崩さないために追加した制御点を外側の三角形メッシュの制御点とを接続して、外側の3つの三角形メッシュのそれぞれを2つの三角形メッシュに分割する。
 また、他の例では、中央に並ぶ3個の三角形メッシュにおいて、それぞれの三角形メッシュが持つ3つの制御点の中央に新たに制御点(図中の白丸“○”で示す)を加えることによって、各三角形メッシュについて1つの三角形メッシュを4つの三角形メッシュに分割する。さらに、互換性を崩さないために追加した制御点を外側の三角形メッシュの制御点とを接続して、外側の3つの三角形メッシュのそれぞれを2つの三角形メッシュに分割する。
 また、制御点の点数を増加する他に、局所的な再メッシュによって近似度を高めることができる。図11、図12は局所的な再メッシュの一例である。
 図11は制御点Pの位相的な調整を説明するための図である。メッシュの質を制御点の位数d(v)によって評価することが知られている。境界の頂点での最適な位数dopt(v)は4であり、その他の頂点での最適な位数dopt(v)は6である。
 メッシュの質を評価する評価関数R(M)として
  R(M)=Σ(d(v)-dopt(v))2    …(7)
が知られ、この評価値が低いほどメッシュの質が高いことを示している。なお、vはMの要素である。
 評価関数R(M)の値を、図11(a)に示すメッシュと図11(b)に示すメッシュとで比較すると、図11(b)に示すメッシュの評価関数R(M)の値は図11(a)に示すメッシュの評価関数R(M)の値よりも低い値となる。したがって、メッシュの接続状態を変更することによって評価関数R(M)を下げることができ、このことはメッシュの質が高まったことを示している。
 また、細長いメッシュは望ましくないうねりの要因となるため、細長いメッシュを取り除く必要がある。
 図12は、制御点を調整することで細長いメッシュを取り除く例を示している。図12(a)に示す制御点の接続状態から図12(b)に示す制御点の接続状態に変更することによって三角形メッシュの角度を大きくし、これによって細長いメッシュを除去する。
 以下に、本発明による結果例を図13に示す。図13は、繰り返しによる誤差と計算時間の変化を示している。
 平均誤差Eaveは16回目の繰り返しで0.01%に達し、最大誤差Emaxは30回目の繰り返しで0.05%に達した。なお、5回目毎に表れる最大誤差Emaxのピークは、制御点の調整によるものである。
 また、以下の表1は、各モデル例による誤差と計算時間を、本発明の例と他の手法による例を示している。比較に用いた他の手法は[Marinov and Kobbelt 2005](非特許文献8)と[Cheng etl 2007](非特許文献9)である。
Figure JPOXMLDOC01-appb-T000001
 表1において、本発明の近似処理では、平均誤差を0.01%とし最大誤差を0.05%とし、Pentium(登録商標)IV 3.0GHzのPC、2GBのRAMを用いて実施している。
 本発明の近似処理と[Marinov and Kobbelt 2005](非特許文献8)の手法とを比較すると、本発明によれば約6倍の処理速度であると評価することができる。なお、[Marinov and Kobbelt 2005](非特許文献8)では、Pentium(登録商標) 2.8GHzのPC、2GBのRAMを用いて実施し、平均誤差に代えて自乗平均誤差を用いている。
 本発明の近似処理と[Cheng et al. 2007](非特許文献9)の手法とを比較すると、本発明によれば約6倍の処理速度であると評価することができる。なお、[Cheng et al. 2007] (非特許文献9)では、Xeon 2.8GHzのPC、2GBのRAMを用いて実施している。
 図14は、本発明の近似処理の一実施例を示す図である。図14(a)は近似対象の対象物のイメージを示し、図14(b)はデータ点を対象物のイメージに重ねて示した図であり、図14(c)はQEMによる三角形メッシュを示し、図14(d)は誤差ベクトルおよび制御ベクトルを示し、図14(e)は近似処理で得られた近似曲面を示している。
 上記では三次元による近似曲面を生成する例について説明したが、二次元による近似曲線を生成する場合にも適用することができる。
 以下、近似曲線を生成する例について説明する。以下では、与えられたn+1個の点群を近似するB-spline曲線について説明する。
 はじめに、n+1個の点群から形状を保ちつつ特徴点Sを選び出す。このとき、近似曲線の簡略化手法であるダグラス・ポイカーアルゴリズム(Douglas-Peucker Algorithm)を用いる。このダグラス・ポイカーアルゴリズムは、近似曲線の簡略化手法であって、コンピュータグラフィックや地理情報システムにおいて広く用いられるものであり、近似曲線の始点と終点とを結んだ一本のエッジで簡略化から開始し、そのエッジに対して残りの頂点との距離を求め、エッジからの距離が閾値よりも遠い頂点がある場合には、最も遠い頂点によって近似曲線を分け、分けた近似曲線に対してそれぞれのエッジを簡略化する過程を帰納的に行うものである。
 選び出されたN+1の特徴点Sに対してパラメータ値を割り当て、ノットベクトルTを定義する。ノットベクトルTと特徴点Sを制御点Pとして初期曲線を生成する。ここで、本発明の曲線近似では、誤差ベクトルの算出と制御点の移動の2つの工程で行う。
 誤差ベクトルの算出では、入力点群から制御点Pで定義される曲線へ垂線を下し、曲へ垂線を下ろしたときの垂線の足入力点に向かうベクトルを誤差ベクトルとする。垂線は入力点から曲線への最近点に相当し、ニュートン法によって求めることができる。
 制御点の移動において、近似手法は補間手法と違って入力点群数に比べ制御点数が少ないため、誤差ベクトルと制御点とは一対一に対応しておらず、誤差ベクトルと移動ベクトルは一致していない。そのため、それぞれの入力点について、垂線が下りたスパンに影響を与える制御点ごとに誤差ベクトルをB-spline基底関数に基づいて重み付けを行う。それぞれの制御点Pを重み付けした移動ベクトルによって移動して新たな制御点Pを求める。
 この工程を繰り返すこと曲線近似を行うことができる。入力点群全てに対して距離が閾値を満たすまで上記二つ工程を繰り返すことにより、入力点群に近似するB-spline曲線を生成する。また、繰り返しの過程において、距離が大きい部分には適宜ノットを挿入することによって曲線の自由度を上げながら近似を行う。
 B-spline曲線の近似において、誤差ベクトルの重み付けはB-spline基底関数に基づいて行う。
 この重み付けでは、一つのスパンを構成するk個の制御点に着目して行う。各入力点について、垂線が下りたスパンに影響を与える制御点ごとに誤差ベクトルをB-spline基底関数に基づいて重み付けすることによって、移動ベクトルを定義する。B-spline基底関数を用いた重み付けを行うことで、制御点に近い誤差ベクトルほど大きく重み付けを行うことができる。
 図15はB-spline曲線の近似における重み付けを説明するための図である。図15において、入力点Qから曲線に下ろした垂線の足が下りたスパンsを探す。
 スパンsを構成するk個の制御点毎に、B-spline基底関数で重み付けした誤差ベクトルを足し合わせる。図15に示す例では、スパンsを構成する制御点Ps-1,Ps,Ps+1,Ps+2ごとに足し合わせる。
 上記した工程を入力した点群の全てのデータ点について行い、総和ベクトルを正規化して移動の方向ベクトルを求める。正規化は、重み付けした誤差ベクトルの大きさを制御点ごとに足し合わせたスカラー量で除算することで行うことができる。また、大きさの総和(前記スカラー量)を足し合わせた総数で割って平均化することで移動量を求める。
 本願発明は、上記して細分割曲面やB-Splineに限らず、NURBS等にも適用することができる。
 本発明は、3Dモデリングの分野におけるリバースエンジニアリングに適用することができる。

Claims (10)

  1.  制御点により定義される曲線又は曲面によって点群のデータ点を近似する近似処理方法において、
     形状の特徴を保存する制御点を用いて近似曲線又は近似曲面を形成する工程と、
     前記近似曲線又は近似曲面上において、前記データ点に最も近い最近点を算出する第1の算出工程と、
     前記第1の算出工程で求めた最近点から前記データ点を結ぶ誤差ベクトルを算出する第2の算出工程と、
     前記第2の算出工程で求めた誤差ベクトルに基づいて前記制御点を移動し修正後の制御点を算出する第3の算出工程とを備え、
     前記近似曲線又は近似曲面を形成する工程および各算出工程は、幾何アルゴリズムを組み込んだ演算手段により行い、
     前記近似曲線又は近似曲面の形成工程と前記第1~第3の算出工程を繰り返すことによって、前記近似曲線又は近似曲面をそれぞれ対象とするデータ点が構成する曲線又は曲面に近似させることを特徴とする近似処理方法。
  2.  前記第1の算出工程は、ニュートン法によって近似曲線又は近似曲面上において前記データ点に最も近い最近点を算出することを特徴とする請求項1に記載の近似処理方法。
  3.  前記第3の算出工程は、前記第2の算出工程で算出した複数の誤差ベクトルの内、修正を行う制御点の周囲にある最近点について算出した誤差ベクトルに重み付け処理を行い、当該重み付けした誤差ベクトルをベクトル加算し、当該ベクトル加算された加算ベクトルを移動ベクトルとして前記制御点を移動し、移動後の制御点を修正後制御点として算出することを特徴とする請求項1又は2に記載の近似処理方法。
  4.  前記第3の算出工程における重み付け処理は、前記制御点の周囲の最近点について求めた誤差ベクトルに係数を乗じる演算処理であり、
     前記係数は制御点と最近点との距離に応じて、制御点に近い程ほど大きな値を設定することを特徴とする請求項3に記載の近似処理方法。
  5.  前記係数は、重心座標系(barycentric coordinate)に従って定めることを特徴とする請求項4に記載の近似処理方法。
  6.  前記データ点と当該データ点に対応する近似曲線又は近似曲面上の最近点との距離に基づいて、近似曲線又は近似曲面の近似誤差を算出し、
     前記近似誤差が所定値未満となるまで前記第1~第3の算出工程を繰り返すことを特徴とする請求項1から5の何れか一つに記載の近似処理方法。
  7.  前記制御点の算出処理の繰り返し回数が所定回数を超えた場合には、面分割による制御点の個数を増加させ、
     前記近似誤差が所定値未満となるまで前記制御点の算出工程と前記面分割による制御点の増加を繰り返すことを特徴とする請求項6に記載の近似処理方法。
  8.  前記曲面は、三角形メッシュによるLoop細分割、四角形メッシュによるCatmull-Clark,Doo-Sabin細分割、NURBS、B-Splineの何れか一つにより定められる制御点により定義されることを特徴とする請求項1から請求項7の何れか一つに記載の近似処理方法。
  9.  点群のデータ点を結んで折れ線又はメッシュを形成する工程と、
     当該折れ線又はメッシュの特徴をとらえた頂点を求め、当該頂点を初期制御点とする工程とを備え、
     前記近似曲線又は近似曲面を形成する工程は、前記初期制御点を用いて第1回目の近似曲線又は近似曲面の形成を行うことを特徴とする請求項1から請求項8の何れか一つに記載の近似処理方法。
  10.  制御点により定義される曲線又は曲面によって点群を近似する近似処理装置において、
     形状の特徴点を保存する制御点を用いて近似曲線又は近似曲面を形成する工程と、
     前記近似曲線又は近似曲面上において、前記データ点に最も近い最近点を算出する第1の算出工程と、
     前記第1の算出工程で求めた最近点から前記データ点を結ぶ誤差ベクトルを算出する第2の算出工程と、
     前記第2の算出工程で求めた誤差ベクトルに基づいて前記制御点を移動し修正後の制御点を算出する第3の算出工程の各工程を行う演算手段を備え、
     前記演算手段は、前記近似曲線又は近似曲面を形成する工程、および前記各算出工程を行う幾何アルゴリズムをソフトウエアで実行するためのCPU及び記憶装置、又は各幾何アルゴリズムをハードウエアで実行するための回路を備え、前記近似曲線又は近似曲面の形成工程と前記第1~第3の算出工程を繰り返すことによって、前記近似曲線又は近似曲面をそれぞれ対象とする曲線又は曲面に近似させることを特徴とする近似処理装置。
PCT/JP2009/053252 2008-05-23 2009-02-24 近似処理方法、および近似処理装置 WO2009142037A1 (ja)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2010512954A JP5436416B2 (ja) 2008-05-23 2009-02-24 近似処理方法、および近似処理装置
US12/994,011 US8805908B2 (en) 2008-05-23 2009-02-24 Approximation processing method and approximation processing device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2008135643 2008-05-23
JP2008-135643 2008-05-23

Publications (1)

Publication Number Publication Date
WO2009142037A1 true WO2009142037A1 (ja) 2009-11-26

Family

ID=41339976

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2009/053252 WO2009142037A1 (ja) 2008-05-23 2009-02-24 近似処理方法、および近似処理装置

Country Status (3)

Country Link
US (1) US8805908B2 (ja)
JP (1) JP5436416B2 (ja)
WO (1) WO2009142037A1 (ja)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102629292A (zh) * 2012-03-26 2012-08-08 河北省送变电公司 连接管钢梁不同平面间的斜角钢制弯计算方法
JP2014059672A (ja) * 2012-09-14 2014-04-03 Mitsutoyo Corp 三次元モデル生成方法、システム及びプログラム
JP6180587B1 (ja) * 2016-05-31 2017-08-16 株式会社セルシス 2つの画像を対応づける方法、及びプログラム
JP2019145083A (ja) * 2017-12-22 2019-08-29 ダッソー システムズDassault Systemes 実オブジェクトのスキンを表すファセットの集合の決定
JP2020113811A (ja) * 2019-01-08 2020-07-27 セイコーエプソン株式会社 測色方法、画像表示方法、測色装置、画像表示装置及び画像表示システム
WO2021044891A1 (ja) * 2019-09-02 2021-03-11 マツダ株式会社 曲面のフィッティング処理方法、フィッティング処理装置およびフィッティング処理プログラム、並びに、該フィッティング処理プログラムを記憶したコンピュータ読取可能な記憶媒体

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9336628B2 (en) * 2008-05-08 2016-05-10 United Technologies Corporation Systems and methods involving surface fitting
US8669983B2 (en) * 2010-08-31 2014-03-11 Microsoft Corporation Buffer construction with geodetic circular arcs
CN103136431B (zh) * 2013-03-26 2015-07-15 山东大学 一种自由曲面的保面积参数特性优化方法
CN104392021B (zh) * 2014-10-24 2016-04-06 山东大学 一种层次自由曲面的保角参数特性优化方法
US10115226B2 (en) * 2016-07-21 2018-10-30 Christie Digital Systems Usa, Inc. System and method for geometric warping correction in projection mapping
US20240020935A1 (en) * 2022-07-15 2024-01-18 The Boeing Company Modeling system for 3d virtual model

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH04117572A (ja) * 1990-09-07 1992-04-17 Ricoh Co Ltd 3次元立体形状生成装置
WO2007083602A1 (ja) * 2006-01-23 2007-07-26 National University Corporation Yokohama National University 補間処理方法、補間処理装置、形状評価方法、および形状評価装置

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6084586A (en) * 1991-10-29 2000-07-04 Sony Corporation Method and apparatus for forming objects based on free-form curves and free-form surfaces generated by minimizing sum of distances from an input series of points to a free-form curve
JP3054108B2 (ja) * 1997-08-15 2000-06-19 理化学研究所 自由曲面の測定データ合成方法
WO2004111927A2 (en) * 2003-06-13 2004-12-23 UNIVERSITé LAVAL Three-dimensional modeling from arbitrary three-dimensional curves
US20090027398A1 (en) * 2007-07-26 2009-01-29 Tufts University Method for recognizing a shape from a path of a digitizing device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH04117572A (ja) * 1990-09-07 1992-04-17 Ricoh Co Ltd 3次元立体形状生成装置
WO2007083602A1 (ja) * 2006-01-23 2007-07-26 National University Corporation Yokohama National University 補間処理方法、補間処理装置、形状評価方法、および形状評価装置

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102629292A (zh) * 2012-03-26 2012-08-08 河北省送变电公司 连接管钢梁不同平面间的斜角钢制弯计算方法
JP2014059672A (ja) * 2012-09-14 2014-04-03 Mitsutoyo Corp 三次元モデル生成方法、システム及びプログラム
JP6180587B1 (ja) * 2016-05-31 2017-08-16 株式会社セルシス 2つの画像を対応づける方法、及びプログラム
JP2017215729A (ja) * 2016-05-31 2017-12-07 株式会社セルシス 2つの画像を対応づける方法、及びプログラム
JP2019145083A (ja) * 2017-12-22 2019-08-29 ダッソー システムズDassault Systemes 実オブジェクトのスキンを表すファセットの集合の決定
JP7256005B2 (ja) 2017-12-22 2023-04-11 ダッソー システムズ 実オブジェクトのスキンを表すファセットの集合の決定
JP2020113811A (ja) * 2019-01-08 2020-07-27 セイコーエプソン株式会社 測色方法、画像表示方法、測色装置、画像表示装置及び画像表示システム
JP7326742B2 (ja) 2019-01-08 2023-08-16 セイコーエプソン株式会社 測色方法、画像表示方法、測色装置、画像表示装置及び画像表示システム
WO2021044891A1 (ja) * 2019-09-02 2021-03-11 マツダ株式会社 曲面のフィッティング処理方法、フィッティング処理装置およびフィッティング処理プログラム、並びに、該フィッティング処理プログラムを記憶したコンピュータ読取可能な記憶媒体
JP7446579B2 (ja) 2019-09-02 2024-03-11 マツダ株式会社 曲面のフィッティング処理方法、フィッティング処理装置およびフィッティング処理プログラム、並びに、該フィッティング処理プログラムを記憶したコンピュータ読取可能な記憶媒体

Also Published As

Publication number Publication date
JPWO2009142037A1 (ja) 2011-09-29
US8805908B2 (en) 2014-08-12
JP5436416B2 (ja) 2014-03-05
US20110078223A1 (en) 2011-03-31

Similar Documents

Publication Publication Date Title
JP5436416B2 (ja) 近似処理方法、および近似処理装置
JP4934789B2 (ja) 補間処理方法および補間処理装置
Suzuki et al. Subdivision surface fitting to a range of points
KR100707841B1 (ko) 3차원 목표곡선을 이용한 곡면 변형 장치 및 그 방법
CN111581776B (zh) 一种基于几何重建模型的等几何分析方法
CN109683552B (zh) 一种基面曲线导向的复杂点云模型上的数控加工路径生成方法
CN106384384B (zh) 一种三维产品模型的形状优化方法
CN111462328B (zh) 一种基于渐进插值细分曲面的多个三维网格模型插值方法
Sieger et al. A comprehensive comparison of shape deformation methods in evolutionary design optimization
Abdul-Rahman et al. Freeform texture representation and characterisation based on triangular mesh projection techniques
Knopf et al. Adaptive reconstruction of free-form surfaces using Bernstein basis function networks
Krause et al. Reconstruction of freeform objects with arbitrary topology using neural networks and subdivision techniques
JP2007156604A (ja) 曲面作成方法及び曲面作成プログラム並びに3次元形状処理装置
Hormann From scattered samples to smooth surfaces
Bock et al. Generation of high-order polynomial patches from scattered data
JP2005149245A (ja) Cadシステム、曲面解析装置、曲面再生装置、その方法及びそのプログラム
Kuriyama et al. Discrete parameterization for deforming arbitrary meshes
CN114937110B (zh) 一种gpu加速的引流线建模方法、系统、设备及介质
CN117315196B (zh) 一种模型的构建方法、装置、设备和存储介质
Gandotra et al. Representation of model for efficient collision detection in virtual reality environment
CN116229005B (zh) 三维巷道模型的测地线确定方法和装置
Knopf et al. Intelligent systems for interactive design and visualization
Hube et al. Seamless integration of analysis and design: Automatic CAD reconstruction of post-analysis geometries
Huang et al. Research on insertion points planning of head model
Qiu et al. Curvature estimation of point set data based on the moving-least square surface

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 09750399

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2010512954

Country of ref document: JP

WWE Wipo information: entry into national phase

Ref document number: 12994011

Country of ref document: US

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 09750399

Country of ref document: EP

Kind code of ref document: A1