JPH07129772A - Method and device for recognizing start and end points of arc - Google Patents
Method and device for recognizing start and end points of arcInfo
- Publication number
- JPH07129772A JPH07129772A JP27331693A JP27331693A JPH07129772A JP H07129772 A JPH07129772 A JP H07129772A JP 27331693 A JP27331693 A JP 27331693A JP 27331693 A JP27331693 A JP 27331693A JP H07129772 A JPH07129772 A JP H07129772A
- Authority
- JP
- Japan
- Prior art keywords
- line
- line segment
- arc
- point
- end point
- 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.)
- Withdrawn
Links
Landscapes
- Image Analysis (AREA)
Abstract
(57)【要約】
【目的】線図形から円弧部分の始終点を検出する方法で
あって、計算量が少なくかつノイズの影響を受けにくい
方法を提供する。
【構成】線図形に折れ線近似処理を施し(ステップ2
3)、円弧の端点を認識する(ステップ25)。円弧端
点の認識は、円弧と直線との接続点において、折れ線
近似による線分が直線側で長く円弧側で短くなり、直
線側での線分と円弧側での線分とのなす角が2直角では
ないがかなり大きい、の2条件が成立することを利用し
て行なう。
(57) [Abstract] [Purpose] To provide a method for detecting the start and end points of a circular arc portion from a line figure, which requires a small amount of calculation and is not easily affected by noise. [Structure] A polygonal line is approximated to a polygonal line (step 2).
3) The end points of the arc are recognized (step 25). At the connection point between the arc and the straight line, the arc end point is recognized such that the line segment resulting from the broken line approximation is longer on the straight line side and shorter on the arc side, and the angle formed by the line segment on the straight line side and the line segment on the arc side is 2 This is done by using the fact that the two conditions, that is, not a right angle, but a large amount, are satisfied.
Description
【0001】[0001]
【産業上の利用分野】本発明は、2値画像に対する特徴
抽出に関し、特に、与えられた線図形から円弧部分を抽
出するためにこの円弧部分の始点と終点とを認識する、
円弧の始終点認識方法および装置に関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to feature extraction for a binary image, and more particularly, to recognize a starting point and an ending point of a circular arc portion in order to extract the circular arc portion from a given line figure.
The present invention relates to a method and an apparatus for recognizing start and end points of an arc.
【0002】[0002]
【従来の技術】手書き入力によって入力された線図形や
イメージスキャナで読み込まれた線図形に対して特徴抽
出を施し、その線図形がどのような図形要素(直線、線
分、円弧など)から構成されているかを認識することが
行なわれている。この場合、入力される線図形は、1個
の図形要素のみからなることは少なく、線分や円弧が連
結されたものであることが多い。2. Description of the Related Art Feature extraction is performed on a line figure input by handwriting or a line figure read by an image scanner, and the line figure is composed of what kind of figure element (straight line, line segment, arc, etc.). Is being recognized. In this case, the input line graphic is rarely composed of only one graphic element, and is often one in which line segments and arcs are connected.
【0003】ここで、線図形から円弧部分の端点(始点
と終点)を抽出する従来の方法について、図5を用いて
説明する。ここでは、図5(a)に示すような線図形91
が入力されたものとする。Here, a conventional method for extracting the end points (start point and end point) of an arc portion from a line figure will be described with reference to FIG. Here, a line pattern 91 as shown in FIG.
Is entered.
【0004】まず、必要に応じて細線化処理を行なった
のち、図5(b)に示すように、この線図形91を比較的
細かなベクトルに分割してベクトル化を行なう。得られ
たベクトル列がv(1),v(2),...,v(n)で表わされ
る。そして、隣接するベクトル相互がなす角a(1),a
(2),...,a(n−1)を求める。角a(i)は、ベクトルv
(i)とベクトルv(i+1)のなす角である。そして、こ
の角の値の変化率g(1),g(2),...,g(n−2)を求め
る。変化率g(i)は、g(i)=g(i+1)−g(i)で表
わされる。First, if necessary, a thinning process is performed, and then, as shown in FIG. 5B, the line figure 91 is divided into relatively fine vectors for vectorization. The obtained vector sequence is represented by v (1), v (2), ..., V (n). Then, an angle a (1), a formed between adjacent vectors
(2), ..., a (n-1) is calculated. The angle a (i) is the vector v
It is the angle formed by (i) and the vector v (i + 1). Then, the rate of change g (1), g (2), ..., G (n-2) of the value of this angle is obtained. The rate of change g (i) is represented by g (i) = g (i + 1) -g (i).
【0005】そして、変化率が0であるベクトルをグル
ープ化する。図5(b)に示した例では、グループA〜C
の3グループが生成している。そして、隣接するベクト
ル間の角a(i)がほぼ0°となっているグループを直線
グループとし、その他のグループを円弧グループする。
変化率g(i)が変化する点であって、この点のどちらか
一方側が直線グループであり他方側が円弧グループであ
るならば、この点を円弧の端点すなわち始点か終点のど
ちらかとして認識する。以上の処理により、円弧の始終
点が抽出されたことになる。Then, the vectors whose change rate is 0 are grouped. In the example shown in FIG. 5B, groups A to C
3 groups are generated. Then, a group in which the angle a (i) between adjacent vectors is approximately 0 ° is defined as a straight line group, and the other groups are defined as arc groups.
If the rate of change g (i) changes and one side of this point is a straight line group and the other side is a circular arc group, this point is recognized as the end point of the circular arc, that is, either the start point or the end point. . With the above processing, the start and end points of the arc are extracted.
【0006】[0006]
【発明が解決しようとする課題】上述した従来の円弧の
始終点認識方法では、入力された線図形を細かいベクト
ルに分割するので、多大な計算機パワーと計算時間とを
必要とし、かつ入力される線図形中に含まれる手ブレな
どのノイズの影響を受けやすく前処理を必要とするなど
の問題点がある。In the above-described conventional arc start / end point recognition method, since the input line figure is divided into fine vectors, a large amount of computer power and calculation time are required, and the input is performed. There is a problem in that it is easily affected by noise such as camera shake contained in a line figure and requires preprocessing.
【0007】本発明の目的は、計算量が少なくかつノイ
ズの影響を受けにくい、円弧の始終点認識方法および装
置を提供することにある。An object of the present invention is to provide a method and apparatus for recognizing the start and end points of an arc, which has a small amount of calculation and is not easily affected by noise.
【0008】[0008]
【課題を解決するための手段】本発明の円弧の始終点認
識方法は、線図形を入力する入力工程と、入力された線
図形に対して折れ線近似処理を施し、連結した複数の線
分に前記線図形を分割する折れ線近似工程と、前記線図
形に対応する複数の線分中から1つの線分を選択して該
選択された線分を注目線分とするとき、以下の2条件
およびの両方、条件;前記注目線分に隣接する2線
分のうちの一方の線分の長さが前記注目線分の長さおよ
び前記2線分のうちの他方の線分の長さのそれぞれに比
べて所定の比率以上で大きく、条件;前記一方の線分
と前記注目線分がなす角が2直角ではないが2直角に近
い、および以下の2条件およびの少なくとも一方、
条件;前記注目線分の長さと前記他方の線分の長さが
ほぼ等しく、条件;前記一方の線分と前記注目線分が
なす角が、前記注目線分と前記他方の線分がなす角とほ
ぼ等しい、の各条件について当該条件が成立するかを調
べ、調べられた条件の中で不成立のものがない場合に、
前記一方の線分と前記注目線分の接続点を円弧部分の端
点として認識する円弧端点認識工程とを有し、前記線図
形に対応する各線分について前記円弧端点認識工程を順
次適用する。According to the method for recognizing the start and end points of an arc of the present invention, an input step of inputting a line figure and a polygonal line approximation process for the input line figure are performed to obtain a plurality of connected line segments. In the polygonal line approximation step of dividing the line figure, and when one line segment is selected from a plurality of line segments corresponding to the line figure and the selected line segment is set as a target line segment, the following two conditions and Both of the conditions; the length of one of the two line segments adjacent to the target line segment is the length of the target line segment and the length of the other line segment of the two line segments, respectively. Is larger than a predetermined ratio and is greater than a predetermined condition; the angle formed by the one line segment and the target line segment is not two right angles but is close to two right angles, and at least one of the following two conditions:
Condition: The length of the target line segment and the length of the other line segment are substantially equal, and the condition: the angle formed by the one line segment and the target line segment is formed by the target line segment and the other line segment. For each condition, which is almost equal to the angle, check whether the condition is satisfied, and if none of the checked conditions are not satisfied,
A circular arc end point recognition step of recognizing the connection point of the one line segment and the target line segment as an end point of a circular arc portion, and the circular arc end point recognition step is sequentially applied to each line segment corresponding to the line figure.
【0009】本発明の円弧の始終点認識装置は、線図形
を入力する入力手段と、入力された線図形に対して折れ
線近似処理を施し、連結した複数の線分に前記線図形を
分割する折れ線近似手段と、前記複数の線分を格納する
格納手段と、前記格納手段から1つずつ線分を読み出し
て注目線分とし、以下の2条件およびの両方、条件
;前記注目線分に隣接する2線分のうちの一方の線分
の長さが前記注目線分の長さおよび前記2線分のうちの
他方の線分の長さのそれぞれに比べて所定の比率以上で
大きく、条件;前記一方の線分と前記注目線分がなす
角が2直角ではないが2直角に近い、および以下の2条
件およびの少なくとも一方、条件;前記注目線分
の長さと前記他方の線分の長さがほぼ等しく、条件;
前記一方の線分と前記注目線分がなす角が、前記注目線
分と前記他方の線分がなす角とほぼ等しい、の各条件に
ついて当該条件が成立するかを調べ、調べられた条件の
中で不成立のものがない場合に、前記一方の線分と前記
注目線分の接続点を円弧部分の端点として認識する円弧
端点認識手段と、を有する。The arc start / end point recognition device of the present invention divides the line figure into a plurality of connected line segments by applying input means for inputting the line figure and a polygonal line approximation process to the input line figure. A polygonal line approximation unit, a storage unit that stores the plurality of line segments, and a line segment that is read from the storage unit one by one to be a target line segment, and the following two conditions and both of the following conditions; The length of one of the two line segments is larger than the length of the target line segment and the length of the other line segment of the two line segments by a predetermined ratio or more, The angle formed by the one line segment and the target line segment is not two right angles, but is close to two right angles, and at least one of the following two conditions and conditions; the length of the target line segment and the other line segment Conditions of approximately equal length;
The angle formed by the one line segment and the target line segment is substantially equal to the angle formed by the target line segment and the other line segment, and it is checked whether or not the condition is satisfied for each condition, and If there is nothing that does not hold, an arc end point recognition unit that recognizes the connection point of the one line segment and the target line segment as the end point of the arc portion.
【0010】[0010]
【作用】線図形に対して折れ線近似処理を施した場合、
この線図形は、いくつかの頂点とこれら頂点を結ぶ線分
とからなる折れ線で近似される。この場合、頂点間の距
離は、もとの線図形において曲率が小さいところでは長
く、曲率が大きいところでは短くなる。また一般の線図
形では、円弧部分はその前後に直線(線分)部分が連結
されていることが多い。[Operation] When a polygonal line approximation process is applied to a line figure,
This line figure is approximated by a polygonal line consisting of several vertices and a line segment connecting these vertices. In this case, the distance between the vertices is long in the original line figure where the curvature is small, and is short where the curvature is large. In a general line figure, a straight line (line segment) is often connected before and after the arc portion.
【0011】そこで直線部分と円弧部分との接続点に着
目すると、条件;折れ線近似による線分が直線側で長
く円弧側で短くなり、条件;直線側での線分と円弧側
での線分とのなす角が2直角ではないがかなり大きい、
の2条件が成立している。したがって、この2条件が成
立する点が直線部分と円弧部分の接続点の候補となる。
条件は、V字型に折れ曲がっているような点を検出す
るのを防ぐための条件でもある。実際には、円弧以外の
曲線が直線と接続している場合も、これら条件,が
成立する可能性がある。そのため、条件;円弧側での
各線分の長さがほぼ等しい、条件;連続する3線分間
で隣接する2線分のなす角がほぼ等しい、の2条件の少
なくとも一方の成立を確かめる必要があり、条件,
の成立がどちらかでも否定された場合には円弧部分の端
点ではないとする必要がある。Therefore, focusing on the connection point between the straight line portion and the circular arc portion, the condition; the line segment by the polygonal line approximation is longer on the straight line side and shorter on the arc side, and the condition is: the line segment on the straight line side and the line segment on the arc side. The angle between and is not 2
2 conditions are satisfied. Therefore, the point where these two conditions are satisfied is a candidate for the connection point of the straight line portion and the circular arc portion.
The condition is also a condition for preventing detection of a point that is bent in a V shape. In reality, these conditions may be satisfied even when a curve other than a circular arc is connected to a straight line. Therefore, it is necessary to confirm the establishment of at least one of the following two conditions: the condition; the lengths of the line segments on the arc side are almost equal; and the condition: the angles formed by two adjacent line segments in three consecutive line segments are almost equal. ,conditions,
If either of the above is denied, it is necessary to consider that it is not the end point of the arc part.
【0012】したがって、条件,の両方と、条件,
の少なくとも一方について、これら条件の成立を調
べ、調べた結果において不成立のものがない場合に、そ
こが直線と円弧との接続点、すなわち円弧部分の端点
(始点あるいは終点)であると結論づけることができ
る。Therefore, both of the conditions
For at least one of the above conditions, it is possible to conclude that these conditions are the connection points between the straight line and the circular arc, that is, the end points (start point or end point) of the circular arc, if there are no unsatisfied results. it can.
【0013】複数の線分への折れ線近似処理による分割
の刻みは、従来法における細かいベクトルへの分割の刻
みに比べ、かなり粗くなるので、その分、計算量を削減
でき、計算に要する時間も短くなる。また、刻みが粗い
分だけ、ノイズの影響を受けにくくなり、ノイズによる
誤認識の影響が後段側に及ばなくなる。[0013] Since the divisional division into a plurality of line segments by the polygonal line approximation processing is considerably coarser than the divisional division into fine vectors in the conventional method, the amount of calculation can be reduced accordingly, and the time required for the calculation can be reduced. It gets shorter. Further, the rougher the step, the less likely it is to be affected by noise, and the influence of erroneous recognition due to noise does not reach the subsequent stage.
【0014】実際に計算を行なう際、線分よりもベクト
ルとしてデータを扱う方が計算が容易になることがある
が、このような場合には、折れ線近似工程において、複
数の線分の代りに、それぞれ線図形の一方の端点側から
他方の端点側に向かう複数のベクトルが得られるように
し、円弧端点認識工程ではこのベクトルに対して条件判
定が行なわれるようにすればよい。この場合、当業者に
は容易に理解できることであるが、(向きの定義されな
い)線分相互の角の定義と、(向きを有する)ベクトル
相互の角の定義とは異なるから、円弧端点認識工程ある
いは円弧端点認識手段での条件判断では、角の定義が異
なることを考慮する必要がある。In actual calculation, it may be easier to handle the data as a vector rather than a line segment. In such a case, in the polygonal line approximation step, instead of a plurality of line segments, It is only necessary to obtain a plurality of vectors respectively from the one end point side of the line figure toward the other end point side, and the condition determination may be performed on this vector in the arc end point recognition step. In this case, as can be easily understood by those skilled in the art, since the definition of the angle between the line segments (the direction of which is not defined) and the definition of the angle between the vectors (having the direction) are different, the arc end point recognition step Alternatively, it is necessary to consider that the definition of the corner is different in the condition judgment by the arc end point recognition means.
【0015】ここで、折れ線近似処理の概要について、
図4を用いて簡単に説明する。Here, regarding the outline of the polygonal line approximation processing,
A brief description will be given with reference to FIG.
【0016】折れ線近似処理では、点列で表わされた線
図形を対象とし、入力点列には、細線化された端点と通
過点のみが存在するものとする。入力点列の一方の端点
を始点とし、他方の端点を終点とする。入力パラメータ
として、errmax,conemaxの2つの正定数を定義する。In the polygonal line approximation processing, a line figure represented by a point sequence is targeted, and it is assumed that only the thinned end points and passing points are present in the input point sequence. One end point of the input point sequence is the start point, and the other end point is the end point. Two positive constants errmax and conemax are defined as input parameters.
【0017】また、次の点を探す操作とは、入力点列を
出発点より走査して行き、errmax離れた点を探す操作の
ことである。ただし、一度、走査した点は走査しない、
すなわち、後戻りしないものとする。次の点を探す操作
を行なう点を出発点とし、次の点を探す操作により得ら
れた点を(折れ線近似処理での)注目点とし、出発点と
注目点との間の点(次の点を探す操作によって過去に探
された点)を過去の点とする。さらに、出発点と注目点
を結ぶ線分を垂直2等分線とし底辺の長さがconemaxの
2倍である2等辺三角形(この三角形の頂点は出発点で
ある)を定義するとき、この2等辺三角形の内部の領域
をcone領域とする。複数のcone領域の共通領域を共通co
ne領域とする。The operation of searching for the next point is an operation of scanning the input point sequence from the starting point and searching for a point errmax away. However, once scanned, the point is not scanned,
That is, it does not go back. The starting point is the point at which the operation for finding the next point is performed, and the point obtained by the operation for finding the next point is the point of interest (in the polygonal line approximation process), and the point between the starting point and the point of interest ( The point found in the past by the operation of searching for a point) is the past point. Further, when defining a line segment connecting the starting point and the target point as a vertical bisector, and defining an isosceles triangle whose base length is twice conemax (the vertex of this triangle is the starting point), The area inside the equilateral triangle is the cone area. Common area of multiple cone areas
Set as ne area.
【0018】このように定義を行ない、さらにまた、
(折れ線近似による)頂点とは、折れ線近似の結果出力
される点のこととし、仮の頂点とは、頂点として仮に記
憶する点のこととする。始点と終点は頂点である。With the above definition,
The vertices (by polygonal line approximation) are points output as a result of polygonal line approximation, and the temporary vertices are points temporarily stored as vertices. The start and end points are vertices.
【0019】まず、始点を出発点とし(ステップ4
1)、出発点を注目点とする(ステップ42)。そし
て、注目点の次の点を探し、その点を注目点とする。ま
た、その注目点を仮の頂点とする(ステップ43)。さ
らに、注目点の次の点を探し、その点を注目点とする
(ステップ44)。First, the starting point is used as the starting point (step 4
1) The starting point is set as the point of interest (step 42). Then, the point next to the point of interest is searched, and that point is set as the point of interest. The point of interest is set as a temporary vertex (step 43). Further, a point next to the point of interest is searched for, and that point is set as the point of interest (step 44).
【0020】ここで、注目点が過去の点と比べ、出発点
より遠くにあるかどうかを調べる(ステップ45)。注
目点が遠くにない場合にはステップ49に進み、遠くに
ある場合には、その注目点が過去の点についての共通co
ne領域に存在するかどうかを調べる(ステップ46)。
共通cone領域にない場合にはステップ48に進み、共通
cone領域にある場合には、その注目点を仮の頂点とし
(ステップ47)、ステップ48に進む。Here, it is checked whether the point of interest is farther from the starting point than the point of the past (step 45). If the point of interest is not far, the process proceeds to step 49. If it is far, the point of interest is the common co
It is checked whether it exists in the ne area (step 46).
If it is not in the common cone area, the process proceeds to step 48 and the common
If it is in the cone area, the target point is set as a temporary vertex (step 47), and the process proceeds to step 48.
【0021】ステップ48では、共通cone領域が全く存
在しなくなったかどうかが調べられる。共通cone領域が
存在する場合には、ステップ44に進んで次の注目点を
探索し、共通cone領域が全く存在しない場合には、ステ
ップ49に進む。In step 48, it is checked if the common cone area is no longer present. If the common cone area exists, the process proceeds to step 44 to search for the next target point, and if the common cone area does not exist at all, the routine proceeds to step 49.
【0022】ステップ49では、仮の頂点を頂点とし、
その頂点を新たな出発点とし、ステップ42に戻る。In step 49, the temporary vertex is set as a vertex,
The vertex is set as a new starting point, and the process returns to step 42.
【0023】以上の動作を始点から終点まで繰り返すこ
とにより、線図形の折れ線近似が行なわれる。By repeating the above operation from the start point to the end point, the polygonal line approximation of the line figure is performed.
【0024】[0024]
【実施例】次に、本発明の実施例について図面を参照し
て説明する。図1は、本発明の一実施例の円弧の始終点
認識装置の構成を示すブロック図である。Embodiments of the present invention will now be described with reference to the drawings. FIG. 1 is a block diagram showing the configuration of an arc start / end point recognition apparatus according to an embodiment of the present invention.
【0025】この円弧の始終点認識装置は、線図形が入
力するタブレットやイメージスキャナなどの入力部1、
入力された線図形に対して細線化処理を行なう細線化部
2、細線化処理の施された線図形に対して折れ線近似処
理を施す折れ線近似処理部3、折れ線近似処理の結果と
して得られた複数のベクトルを格納する格納部4、格納
部4からベクトルを取り出し、上述の4条件〜がい
ずれも成立するかどうかを調べていずれも成立する場合
に円弧の端点として認識する円弧端点認識部5とによっ
て構成されている。This arc start / end point recognition device includes an input unit 1 such as a tablet or an image scanner for inputting a line figure,
It is obtained as a result of the line thinning unit 2 that performs the thinning process on the input line figure, the polygonal line approximation processing unit 3 that performs the polygonal line approximation process on the line figure that has been subjected to the line thinning process, and the polygonal line approximation process. A storage unit 4 for storing a plurality of vectors, a vector is taken out from the storage unit 4, and it is checked whether or not all of the above four conditions (1) to (4) are satisfied. It is composed of and.
【0026】次に本実施例の動作について、図2(a)を
用いて説明する。Next, the operation of this embodiment will be described with reference to FIG.
【0027】まず、入力部1によって線画像が入力され
(ステップ21)、細線化部2において、この線画像に
対して細線化処理が施される(ステップ22)。ここで
は、細線化処理後の線図形が図3(a)で表わされたとす
る。First, a line image is input by the input unit 1 (step 21), and the line thinning unit 2 performs a thinning process on the line image (step 22). Here, it is assumed that the line figure after the thinning process is represented in FIG.
【0028】次に、細線化処理後の線図形11に対し
て、折れ線近似処理が施す(ステップ23)。ここで
は、図3(b)に示されるように、線図形11の一端側か
ら他端側に向かう複数のベクトルに、入力された線図形
11が分割されたする。このように生成されたベクトル
は、格納部4に格納される。そして線図形の一端に最も
近い折れ線近似の頂点(ベクトルの接続点)を注目点と
する(ステップ24)。Next, a polygonal line approximation process is performed on the line figure 11 after the thinning process (step 23). Here, as shown in FIG. 3B, it is assumed that the input line graphic 11 is divided into a plurality of vectors extending from one end side to the other end side of the line graphic 11. The vector thus generated is stored in the storage unit 4. Then, the vertex approximate to the polygonal line (the connection point of the vector) closest to one end of the line figure is set as the target point (step 24).
【0029】次に、円弧端点認識部5は、格納部4を参
照し、上述の4条件〜の成立の有無を確認し、設定
された注目点が円弧端点であるかどうかの識別を行なう
(ステップ25)。そして、折れ線近似の全ての頂点に
ついて上記ステップ25が行なわれたどうかを判定し
(ステップ26)、注目点として設定されたことがない
頂点がある場合にはその頂点を新たな注目点として(ス
テップ27)、ステップ25に進み、全ての頂点につい
てステップ25が実行されている場合には処理を終了す
る。Next, the arc end point recognition unit 5 refers to the storage unit 4 to confirm whether or not the above-mentioned four conditions (1) to (4) are satisfied, and discriminates whether or not the set target point is the arc end point ( Step 25). Then, it is determined whether or not step 25 has been performed for all the vertices of the polygonal line approximation (step 26), and if there is a vertex that has not been set as the attention point, that vertex is set as a new attention point (step 27), the process proceeds to step 25, and if step 25 has been executed for all the vertices, the process ends.
【0030】ここで、円弧端点認識部4の動作につい
て、図2(b)を用いて説明する。Here, the operation of the arc end point recognizing section 4 will be described with reference to FIG.
【0031】線図形上で連続する3つベクトルをベクト
ルa〜cとし、ベクトルaの終点(すなわちベクトルb
の始点)が注目点であるようにする。まず、「ベクトル
aがベクトルbおよびベクトルcよりかなり長い」とい
う条件が成立するかのチェックを行ない(ステップ3
1)、成立する場合にはステップ32に進み、不成立の
場合にはステップ36に進んでこの注目点が円弧の端点
ではないとする。具体的には、Three consecutive vectors on the line figure are defined as vectors a to c, and the end point of the vector a (that is, the vector b).
Make sure that the starting point) is the point of interest. First, it is checked whether the condition "vector a is considerably longer than vector b and vector c" is satisfied (step 3).
1) If it is satisfied, the process proceeds to step 32, and if it is not satisfied, the process proceeds to step 36, and it is assumed that the target point is not the end point of the arc. In particular,
【0032】[0032]
【数1】 の成立をチェックする。ここでrは0<r<1の定数で
あるが、例えば、0.5に設定する。[Equation 1] Check the establishment of. Here, r is a constant of 0 <r <1, but is set to 0.5, for example.
【0033】ステップ32では、「ベクトルbとベクト
ルcの長さがほぼ同じである」という条件が成立するか
どうかがチェックされる。成立しない場合には、上述と
同様にステップ36に進んでこの注目点が端点ではない
とし、成立する場合には、ステップ33に進む。具体的
には、sを定数として、In step 32, it is checked whether or not the condition that "the lengths of the vector b and the vector c are almost the same" is satisfied. If not established, the process proceeds to step 36 in the same manner as described above, and the point of interest is not the end point, and if established, the process proceeds to step 33. Specifically, s is a constant,
【0034】[0034]
【数2】 の成立をチェックする。sは例えば2程度に設定する。[Equation 2] Check the establishment of. s is set to about 2, for example.
【0035】ステップ33では、「ベクトルaとbのな
す角が0°ではないが0°に近い」という条件の成立の
有無が確認される。この条件は、線分のなす角が2直角
ではないが2直角に近いという条件と、等価である。条
件が成立しない場合には、上述と同様にステップ36に
進んでこの注目点が端点ではないとし、成立する場合に
は、ステップ34に進む。具体的には、ベクトルaとb
のなす角をθとし、tを定数として、In step 33, it is confirmed whether or not the condition "the angle formed by the vectors a and b is not 0 ° but close to 0 °" is satisfied. This condition is equivalent to the condition that the angle formed by the line segments is not 2 right angles but is close to 2 right angles. If the condition is not satisfied, the process proceeds to step 36 in the same manner as described above, and the target point is not the end point. If the condition is satisfied, the process proceeds to step 34. Specifically, the vectors a and b
Let θ be the angle formed by and t be a constant,
【0036】[0036]
【数3】θ<t の成立をチェックする。tは例えば60°程度に設定す
る。## EQU3 ## The establishment of θ <t is checked. For example, t is set to about 60 °.
【0037】ステップ34では、「ベクトルaとベクト
ルbのなす角がベクトルbとベクトルcのなす角とほぼ
同じ」という条件が成立するかどうかのチェックがなさ
れる。条件が成立しない場合には、上述と同様にステッ
プ36に進んでこの注目点が端点ではないとし、成立す
る場合には、ステップ35に進み、この注目点が円弧の
端点であると最終的に結論付ける。具体的には、ベクト
ルaとbのなす角をθとし、ベクトルbとcのなす角を
φとし、uを定数として、In step 34, it is checked whether or not the condition "the angle formed by the vector a and the vector b is almost the same as the angle formed by the vector b and the vector c" is satisfied. If the condition is not satisfied, the procedure proceeds to step 36 in the same manner as described above, and the target point is not the end point. If the condition is satisfied, the procedure proceeds to step 35, and finally the target point is the end point of the arc. Make a conclusion. Specifically, the angle between the vectors a and b is θ, the angle between the vectors b and c is φ, and u is a constant.
【0038】[0038]
【数4】 の成立をチェックする。例えばuは2程度に設定する。
以上のようにして、注目点ごとにその注目点が円弧の端
点であるかどうかの識別が行なわれる。ここで使用され
るパラメータr,s,t,uは、入力される線図形の品位
や種類に応じて、適宜に設定することができる。[Equation 4] Check the establishment of. For example, u is set to about 2.
As described above, whether or not the target point is the end point of the arc is identified for each target point. The parameters r, s, t, u used here can be appropriately set according to the quality and type of the input line figure.
【0039】なお、ここで示したベクトルによる例で
は、注目点に関して前方方向と後方方向とに対する操作
が対称的ではないので、同じ注目点に関し、ベクトルa
をベクトル−b'、ベクトルbをベクトル−a'とし、さ
らにベクトルaより1つ始点側にあるベクトルをベクト
ルdとするとき、ベクトルdをベクトル−c'として、
これらベクトルa',b',c'について同様の処理(逆転
処理)を行なう必要がある。逆転処理を行なわないと、
円弧の端点についての検出漏れを生じる。線分で考えた
場合には、方向が考慮されていないので、逆転処理を行
なう必要はない。In the example of the vector shown here, since the operation in the forward direction and the backward direction with respect to the target point is not symmetrical, the vector a
Is a vector −b ′, a vector b is a vector −a ′, and a vector on the starting point side of the vector a is a vector d, the vector d is a vector −c ′.
It is necessary to perform similar processing (reverse processing) on these vectors a ', b', c '. Without reverse processing,
A detection failure occurs at the end points of the arc. When the line segment is considered, the direction is not taken into consideration, so that it is not necessary to perform the reverse processing.
【0040】[0040]
【発明の効果】以上説明したように本発明は、入力され
た線図形に折れ線近似処理を施し、円弧部分と直線部分
の接続点において、折れ線近似による線分が直線側で
長く円弧側で短くなり、直線側での線分と円弧側での
線分とのなす角が2直角ではないがかなり大きい、の2
条件が成立することに着目することにより、細かいベク
トルを生成する必要がなくなって演算量、演算時間とも
削減され、かつノイズの影響を受けにくくなるという効
果がある。As described above, according to the present invention, the polygonal line approximation processing is performed on the input line figure, and the line segment by the polygonal line approximation is long on the straight line side and short on the arc side at the connection point of the arc portion and the straight line portion. Therefore, the angle formed by the line segment on the straight line side and the line segment on the arc side is not 2 right angles, but quite large.
By paying attention to the fact that the condition is satisfied, there is an effect that it is not necessary to generate a fine vector, the calculation amount and the calculation time are reduced, and the influence of noise is reduced.
【図1】本発明の一実施例の円弧の始終点認識装置の構
成を示すブロック図である。FIG. 1 is a block diagram showing a configuration of an arc start / end point recognition device according to an embodiment of the present invention.
【図2】(a)は図1の装置の動作を示すフローチャート
であり、(b)は円弧端点認識部の動作を示すフローチャ
ートである。2A is a flowchart showing an operation of the apparatus of FIG. 1, and FIG. 2B is a flowchart showing an operation of an arc end point recognition unit.
【図3】(a),(b)は、図1の装置における円弧の始終点
認識方法を説明する図である。3A and 3B are diagrams illustrating a method of recognizing the start and end points of an arc in the apparatus of FIG.
【図4】折れ線近似処理を説明するフローチャートであ
る。FIG. 4 is a flowchart illustrating a polygonal line approximation process.
【図5】(a),(b)は従来の円弧の始終点認識方法を説明
する図である。5A and 5B are diagrams illustrating a conventional method for recognizing the start and end points of a circular arc.
1 入力部 2 細線化部 3 折れ線近似部 4 格納部 5 円弧端点認識部 21〜27,31〜36 ステップ 1 Input part 2 Thinning part 3 Polygonal line approximation part 4 Storage part 5 Arc end point recognition part 21-27, 31-36 steps
Claims (3)
よび終点を探索する始終点認識方法であって、 線図形を入力する入力工程と、 入力された線図形に対して折れ線近似処理を施し、連結
した複数の線分に前記線図形を分割する折れ線近似工程
と、 前記線図形に対応する複数の線分中から1つの線分を選
択して該選択された線分を注目線分とするとき、以下の
2条件およびの両方、 条件;前記注目線分に隣接する2線分のうちの一方の
線分の長さが前記注目線分の長さおよび前記2線分のう
ちの他方の線分の長さのそれぞれに比べて所定の比率以
上で大きく、 条件;前記一方の線分と前記注目線分がなす角が2直
角ではないが2直角に近い、および以下の2条件およ
びの少なくとも一方、 条件;前記注目線分の長さと前記他方の線分の長さが
ほぼ等しく、 条件;前記一方の線分と前記注目線分がなす角が、前
記注目線分と前記他方の線分がなす角とほぼ等しい、の
各条件について当該条件が成立するかを調べ、調べられ
た条件の中で不成立のものがない場合に、前記一方の線
分と前記注目線分の接続点を円弧部分の端点として認識
する円弧端点認識工程とを有し、 前記線図形に対応する各線分について前記円弧端点認識
工程を順次適用することを特徴とする円弧の始終点認識
方法。1. A start / end point recognition method for searching a start point and an end point of an arc portion from a given line figure, comprising an input step of inputting a line figure and a polygonal line approximation process for the input line figure. A polygonal line approximation step of dividing the line figure into a plurality of connected line segments, selecting one line segment from the plurality of line segments corresponding to the line figure, and selecting the selected line segment as a target line segment. The following two conditions and both of the following conditions: the length of one of the two line segments adjacent to the target line segment is the length of the target line segment and the other of the two line segments Is greater than each of the lengths of the line segments by a predetermined ratio or more, and the condition; the angle formed by the one line segment and the line segment of interest is not two right angles but close to two right angles, and the following two conditions and At least one of the conditions: the length of the line segment of interest and the length of the other line segment Are substantially equal to each other, and the condition; the angle formed by the one line segment and the target line segment is substantially equal to the angle formed by the target line segment and the other line segment. And, if none of the examined conditions are not satisfied, an arc end point recognition step of recognizing the connection point of the one line segment and the target line segment as an end point of an arc portion, the line figure The method for recognizing the start and end points of an arc, wherein the arc end point recognition step is sequentially applied to each line segment corresponding to.
が、それぞれ、線図形の一方の端点側から他方の端点側
に向かうベクトルとして表わされ、円弧端点認識工程で
は前記ベクトルに対して条件判定が行なわれる請求項1
に記載の円弧の始終点認識方法。2. A plurality of line segments obtained in the polygonal line approximation step are respectively expressed as a vector from one end side of the line figure to the other end side thereof, and the arc end point recognition step sets a condition for the vector. Claim 1 in which a determination is made
The method for recognizing the start and end points of an arc described in.
よび終点を探索する始終点認識装置であって、 線図形を入力する入力手段と、 入力された線図形に対して折れ線近似処理を施し、連結
した複数の線分に前記線図形を分割する折れ線近似手段
と、 前記複数の線分を格納する格納手段と、 前記格納手段から1つずつ線分を読み出して注目線分と
し、以下の2条件およびの両方、 条件;前記注目線分に隣接する2線分のうちの一方の
線分の長さが前記注目線分の長さおよび前記2線分のう
ちの他方の線分の長さのそれぞれに比べて所定の比率以
上で大きく、 条件;前記一方の線分と前記注目線分がなす角が2直
角ではないが2直角に近い、および以下の2条件およ
びの少なくとも一方、 条件;前記注目線分の長さと前記他方の線分の長さが
ほぼ等しく、 条件;前記一方の線分と前記注目線分がなす角が、前
記注目線分と前記他方の線分がなす角とほぼ等しい、の
各条件について当該条件が成立するかを調べ、調べられ
た条件の中で不成立のものがない場合に、前記一方の線
分と前記注目線分の接続点を円弧部分の端点として認識
する円弧端点認識手段と、を有することを特徴とする円
弧の始終点認識装置。3. A start / end point recognizing device for searching for a start point and an end point of an arc portion from a given line figure, wherein input means for inputting the line figure and polygonal line approximation processing for the input line figure. , A polygonal line approximation unit that divides the line figure into a plurality of connected line segments, a storage unit that stores the plurality of line segments, and a line segment that is read from the storage unit one by one as a target line segment. 2 conditions and both, condition; the length of one of the two line segments adjacent to the target line segment is the length of the target line segment and the length of the other line segment of the two line segments The angle between the one line segment and the target line segment is not two right angles but is close to two right angles, and at least one of the following two conditions and the conditions: The length of the target line segment and the length of the other line segment It is checked whether or not the condition is satisfied for each of the conditions that the angle formed by the one line segment and the line segment of interest is substantially equal to the angle formed by the line segment of interest and the other line segment. A circular arc end point recognizing means for recognizing a connection point of the one line segment and the target line segment as an end point of the circular arc portion when none of the examined conditions is satisfied. Start / end point recognition device.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP27331693A JPH07129772A (en) | 1993-11-01 | 1993-11-01 | Method and device for recognizing start and end points of arc |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP27331693A JPH07129772A (en) | 1993-11-01 | 1993-11-01 | Method and device for recognizing start and end points of arc |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH07129772A true JPH07129772A (en) | 1995-05-19 |
Family
ID=17526186
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP27331693A Withdrawn JPH07129772A (en) | 1993-11-01 | 1993-11-01 | Method and device for recognizing start and end points of arc |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH07129772A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2007139774A (en) * | 2005-11-15 | 2007-06-07 | General Electric Co <Ge> | Computer-implemented method and system for characterizing geometric parameters of edge abrupts in machined parts |
-
1993
- 1993-11-01 JP JP27331693A patent/JPH07129772A/en not_active Withdrawn
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2007139774A (en) * | 2005-11-15 | 2007-06-07 | General Electric Co <Ge> | Computer-implemented method and system for characterizing geometric parameters of edge abrupts in machined parts |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JP3170299B2 (en) | Image reading processing device | |
| JPH1139493A (en) | Pattern matching apparatus and method in view of distance and direction | |
| JP2823882B2 (en) | Line image vectorization method | |
| US5054102A (en) | Self-centering character stroke thickening for optical character recognition | |
| JPH0432428B2 (en) | ||
| JPH03154177A (en) | Curve approximating method for linear graphic | |
| JPH07129772A (en) | Method and device for recognizing start and end points of arc | |
| JP2626528B2 (en) | Figure recognition device | |
| JP2000132692A (en) | Curve feature point extraction method and recording medium recording this method | |
| KR102395599B1 (en) | System and method to recognize line objects in image drawings based on deep learning | |
| JPH07200735A (en) | Figure recognition device | |
| JP2682416B2 (en) | Figure recognition device | |
| EP0422245B1 (en) | Recognizing apparatus | |
| JP2587812B2 (en) | Figure extraction method | |
| JPH07193716A (en) | Edge emphasizing device | |
| JPH0528260A (en) | Contour vector extraction system | |
| JPH10312460A (en) | Image processing method and high-precision image processing device | |
| JP2778439B2 (en) | Figure recognition device | |
| JPH0950532A (en) | Contour detector | |
| JP2859453B2 (en) | Image thinning method | |
| JPH04276888A (en) | Character reader | |
| JP3250317B2 (en) | Character recognition device | |
| JP2802132B2 (en) | Image forming device | |
| JP4165175B2 (en) | Figure recognition device | |
| JP2782977B2 (en) | Line figure vectorization method and apparatus |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A300 | Withdrawal of application because of no request for examination |
Free format text: JAPANESE INTERMEDIATE CODE: A300 Effective date: 20010130 |