JPH01297775A - Circle and circular arc extracting method - Google Patents

Circle and circular arc extracting method

Info

Publication number
JPH01297775A
JPH01297775A JP12695088A JP12695088A JPH01297775A JP H01297775 A JPH01297775 A JP H01297775A JP 12695088 A JP12695088 A JP 12695088A JP 12695088 A JP12695088 A JP 12695088A JP H01297775 A JPH01297775 A JP H01297775A
Authority
JP
Japan
Prior art keywords
arc
circle
vector
polygonal
approximated
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.)
Pending
Application number
JP12695088A
Other languages
Japanese (ja)
Inventor
Katsuo Fukazawa
克夫 深沢
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP12695088A priority Critical patent/JPH01297775A/en
Publication of JPH01297775A publication Critical patent/JPH01297775A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To perform the extraction of a circle and a circular arc at high speed by approximating an original picture with a polygonal line, finding an approximated circle from two adjacent polygonal lines, and approximating the original picture with the circle or the circular arc when distance between the approximated circle and the polygonal line is within a prescribed value. CONSTITUTION:The original picture read by a scanner is approximated with the polygonal line and obtained vector data is stored in a memory. And two adjacent vector data are read out by a vector tracing part, and the circle approximated to the two vector data is found at a circular arc vector decision part, and the maximum value (h) of the distance between the vector and the circle is compared with the prescribed value. When the distance between the vector and the circle is less than the prescribed value, it is judged as the circle or the circular arc, and the vector data is replaced by circle data or circular arc data.

Description

【発明の詳細な説明】 〔概要〕 原画を形成する線と有向折れ線との距離が所定の閾値内
含まれるように原画を有向折れ線で近似し、連続する有
向折れ線により組み立てられた折れ線群が円弧を形成す
るか否かを判断し、円弧を形成すると判断した場合は当
該折れ線群を円又は円弧で近似して原画から円又は円弧
を抽出する円・円弧抽出方法に関し、 高速に円または円弧を抽出することができる円・円弧抽
出方法を提供することを目的とし、隣接する2本の当該
有向折れ線で組み立てられた折れ線対を円弧で近似した
場合に得られる当該円弧の半径、当該折れ線対を組み立
てている各折れ線の長さ及び前記閾値に基づいて定まる
所定の評価値が所定の許容範囲内に含まれるか否かを判
断し、当該範囲内に含まれていると判断した場合には当
該折れ線対から組み立てられている折れ線群を円又は円
弧で近似する構成である。
[Detailed Description of the Invention] [Summary] An original picture is approximated by directed polygonal lines so that the distance between the line forming the original picture and the directed polygonal line is within a predetermined threshold, and a polygonal line is assembled from continuous directed polygonal lines. Regarding a circle/arc extraction method that judges whether a group of polygonal lines forms an arc or not, and when it is determined that a group of polygonal lines forms an arc, approximates the group of polygonal lines with a circle or an arc to extract the circle or arc from the original image. Or, the purpose is to provide a circle/arc extraction method that can extract a circular arc, and the radius of the circular arc obtained when a polygonal line pair assembled with two adjacent directed polygonal lines is approximated by a circular arc, It is determined whether or not a predetermined evaluation value determined based on the length of each polygon line that composes the polygon line pair and the threshold value is within a predetermined tolerance range, and it is determined that it is within the range. In this case, the group of broken lines assembled from the pair of broken lines is approximated by a circle or an arc.

〔産業上の利用分野〕[Industrial application field]

本発明は図面を計算機に入力する際に、図形を近似する
技術のうち折れ線(ペタ1−ル)として近似された線画
のデータの圧縮や清書等を目的とした円・円弧抽出方法
に係り、特に原画を所定の閾値な用いて有向折れ線で近
似し、連続する有向折れ線により組み立てられた折れ線
群が円弧を形成するか否かを判断し、円弧を形成すると
判断した場合には原画から円または円弧を抽出する円・
円弧抽出方法に関する。
The present invention relates to a method for extracting circles and arcs for the purpose of compressing and cleansing data of line drawings approximated as polygonal lines (petals) among techniques for approximating figures when inputting drawings into a computer. In particular, the original image is approximated by directed polygonal lines using a predetermined threshold value, and it is determined whether or not the polygonal line group assembled by continuous directed polygonal lines forms an arc. Extract a circle or arc
Concerning an arc extraction method.

〔従来の技術〕[Conventional technology]

近年、CADシステム、マツピングシステム等の図形処
近似理技術の計算機化に伴ない、既存図形の計算機への
入力の要求が高まっている。
In recent years, with the computerization of graphic processing approximation techniques such as CAD systems and mapping systems, there has been an increasing demand for inputting existing graphics into computers.

スキャナ等で入力した図面は画素で表現されたイメージ
データであるため、これを計算機での処理に適した有向
折れ線データ(ベクトルデータ)に変換する必要がある
。このとき、原画て円・円弧で記述されている部分は単
なる折れ線近似したデータてなく円・円弧として抽出し
た方が原画の意図に、より忠実な表現が得られるという
意味でのぞましい。またこの方がデータ量か少なくなる
という利点もある。
Since drawings input using a scanner or the like are image data expressed in pixels, it is necessary to convert this into directed polygonal line data (vector data) suitable for processing by a computer. At this time, it is preferable to extract the parts of the original drawing as circles and arcs, rather than simply using data approximated by polygonal lines, in the sense that a more faithful representation of the original drawing's intent can be obtained. This method also has the advantage of reducing the amount of data.

従来、原画から円または円弧の抽出を行うには、原画を
一旦有向折れ線に近似した後、隣接する有向折れ線のな
す角度を求めることにより当該折れ線により組み立てら
れる折れ線群が円または円弧を形成するか否かを判断し
ていた。
Conventionally, in order to extract a circle or an arc from an original drawing, the original drawing is first approximated to a directed polygonal line, and then the angles formed by adjacent directed polygonal lines are determined, and the polygonal lines assembled by the polygonal lines form a circle or arc. I was deciding whether to do it or not.

または、原画若しくは原画を芯線化したイメージテ゛−
夕を用いて円または円弧部分を抽出方法が行われていた
Or, the original image or an image image created by converting the original image into a core line.
A method was used to extract circles or arcs using the rays.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

ところで、従来の方法にあっては、隣接する各折れ線間
の角度を求めたり、または原画を芯線化したイメージデ
ータを用いて円または円弧部分の抽出を行うようにして
いるため精度良く円または円弧の近似を行うことば可能
であるが、角度の検出または参照する画素が多いため処
理に時間がかかるという問題点を有していた。
By the way, in the conventional method, the angle between each adjacent polygonal line is calculated, or the circle or arc part is extracted using image data obtained by converting the original image into core lines, so the circle or arc can be extracted with high accuracy. However, since there are many pixels to be used for angle detection or reference, there is a problem in that the processing takes time.

そこで、本発明は以上の問題点を解決することを技術的
課題とするものであり、高速に円または円弧を抽出する
ことができる円・円弧抽出方法を提供することを目的と
してなされたものである。
Therefore, the technical object of the present invention is to solve the above-mentioned problems, and has been made with the purpose of providing a circle/arc extraction method that can extract circles or arcs at high speed. be.

〔課題を解決するための手段〕[Means to solve the problem]

以上の技術的課題を解決するため本発明は第1図に示す
ように、原画を形成する線と有向折れ線との距離が所定
の閾値内含まれるように原画を有向折れ線で近似し(S
L)、連続する有向折れ線により組み立てられた折れ線
群が円弧を形成するか否かを判断し、円弧を形成すると
判断した場合は当該折れ線群を円又は円弧で近似して原
画から円又は円弧を抽出する円・円弧抽出方法において
、隣接する2木の当該有向折れ線で組み立てられた折れ
線対を円弧で近似した場合に得られる当該円弧の半径、
当該折れ線対を組み立てている各折れ線の長さ及び前記
閾値に基づいて定まる所定の評価値が所定の許容範囲内
に含まれるか否かを判断し(S2)、当該範囲内に含ま
れていると判断した場合には当該折れ線対から組み立て
られている折れ線群を円又は円弧で近似する(S3)も
のである。
In order to solve the above technical problems, the present invention, as shown in FIG. S
L) Determine whether or not a polygonal line group assembled from continuous directed polygonal lines forms an arc, and if it is determined that it forms an arc, approximate the polygonal line group with a circle or arc and create a circle or arc from the original image. In the circle/arc extraction method that extracts, the radius of the circular arc obtained when a polygonal line pair assembled from two adjacent trees of the directed polygonal lines is approximated by a circular arc,
It is determined whether a predetermined evaluation value determined based on the length of each polygonal line that composes the polygonal line pair and the threshold value is included within a predetermined tolerance range (S2), and whether it is included within the range. If it is determined that this is the case, the polygonal line group assembled from the polygonal line pair is approximated by a circle or an arc (S3).

〔作用〕[Effect]

本発明により円または円弧の抽出を行う場合には、ステ
ップS1で原画を所定の閾値に基づいて有向折れ線で近
似する。
When extracting a circle or an arc according to the present invention, in step S1, the original image is approximated by a directed polygonal line based on a predetermined threshold value.

ここで、閾値とは原画の線と近似された折れ線との近似
が許容される最長距離をいう。
Here, the threshold value refers to the longest distance at which approximation between the line of the original image and the approximated polygonal line is allowed.

続いて、ステップS2において隣接する2木の当該有向
折れ線で組み立てられた折れ線対を円弧で近似した場合
に得られる当該円弧の半径、当該折れ線対を組み立てて
いる各折れ線の長さ及び前記閾値に基づいて定まる所定
の評価値が所定の許容範囲内に含まれるか否かを判断す
る。
Next, in step S2, the radius of the arc obtained when the polygonal line pair assembled from the two adjacent trees of directed polygonal lines is approximated by a circular arc, the length of each polygonal line that composes the polygonal line pair, and the threshold value. It is determined whether a predetermined evaluation value determined based on the above is included within a predetermined tolerance range.

これはある半径の円弧を一定の閾値で有向折れ線に近似
した場合には作成された各折れ線の長さは当該半径で決
まるある範囲に収まるということを利用したものである
This takes advantage of the fact that when a circular arc with a certain radius is approximated to a directed polygonal line using a certain threshold, the length of each polygonal line created falls within a certain range determined by the radius.

ここで、所定の評価値及び所定の範囲とは、例えは第4
図に示すように当該半径をr、有向折れ線の長さを文と
し、前記閾値をd、当該原画の円弧と折れ線との距離を
11とした場合には、h≦d           ■ であり、一方、第4図から明らかなように(交/2)2
+ (r−h)2=r2      ■である。
Here, the predetermined evaluation value and the predetermined range are, for example, the fourth
As shown in the figure, if the radius is r, the length of the directed polygonal line is text, the threshold is d, and the distance between the arc of the original drawing and the polygonal line is 11, then h≦d; , as is clear from Figure 4, (cross/2)2
+ (r-h)2=r2 (2).

したがって、■と■とを整理すると、 文2=4h(2r−d)≦4d(2r−d)   ■と
いう関係式が得られる。
Therefore, by rearranging ■ and ■, the following relational expression can be obtained: Sentence 2 = 4h (2r-d) ≦4d (2r-d) ■.

そこで、例えば所定の評価値として12/4d(2r−
d)をとれば、折れ線対が円または円弧を形成するため
には当該値は1以下の所定の許容範囲に収まるべきこと
になる。
Therefore, for example, the predetermined evaluation value is 12/4d (2r-
If d) is taken, the value must fall within a predetermined tolerance range of 1 or less in order for the polygonal line pair to form a circle or an arc.

続いて、ステップS3において当該範囲内に含まれてい
ると判断した場合には当該折れ線対から組み立てられて
いる折れ線群は円または円弧を形成すると判断して円又
は円弧で近似する。
Subsequently, if it is determined in step S3 that the polygonal line group is within the range, it is determined that the polygonal line group assembled from the polygonal line pair forms a circle or an arc, and is approximated by a circle or an arc.

〔実施例〕〔Example〕

次に本発明に係る実施例について説明する。 Next, embodiments according to the present invention will be described.

第2図に本実施例に係る円・円弧抽出方法を実現するだ
めの装置を示す。
FIG. 2 shows a device for realizing the circle/arc extraction method according to this embodiment.

原画を画素から形成されたイメージとして読み取るスキ
ャナ1と、当該イメージを一定の閾値に基づいて有向折
れ線(以下「ベクトル」という)で近似する折れ線近似
部2と、ベクトルデータ(ベクトルの始点と終点の位置
座標の組み)を格納するメモリとしてのベクトルテーブ
ル格納部3と、当該ベクトルテーブル格納部3に格納さ
れているベクトルデータを順次読み出して、円弧の条件
を満たすベクトルの連鎖を追跡し、後述するベクトル判
定部5により円弧と判定された場合には中心座標のすれ
テストを行い、双方が円弧と判断された場合には後述す
る円弧ベクトル格納部6に円弧ベクトルを送出し、双方
が円弧と判断されなかった場合には新たに前記ベクトル
テーブル格納部3からムク1ヘルデータの読み出しを行
う円弧ベクトル追跡部4と、隣接する2本のベクトル対
について長さ円弧で近似したときの半径、中心座標及び
内積値を求め、円弧になり得るかどうかの判定を行い結
果を追跡部4に送出する円弧ベクトル判定部5と、前記
円弧ベクトル追跡部4により円弧であると判断された場
合に当該データを格納する円弧テーブル格納部6と、当
該円弧ベクトル格納部6に格納されている最終的な円弧
近似結果を出力する円弧近似部7とを有している。
A scanner 1 that reads an original image as an image formed from pixels, a polygonal line approximation unit 2 that approximates the image with a directed polygonal line (hereinafter referred to as a "vector") based on a certain threshold, The vector table storage unit 3 serves as a memory for storing the set of position coordinates of If the vector determining unit 5 determines that it is a circular arc, a center coordinate deviation test is performed, and if both are determined to be circular arcs, the circular arc vector is sent to the circular arc vector storage unit 6, which will be described later, to confirm that both are circular arcs. If the determination is not made, the arc vector tracking unit 4 newly reads the Muku 1 health data from the vector table storage unit 3, and calculates the radius and center of two adjacent vector pairs when approximated by length arcs. an arc vector determination unit 5 that calculates coordinates and inner product values, determines whether or not it can be an arc, and sends the result to the tracking unit 4; and when the arc vector tracking unit 4 determines that it is an arc, the data is It has an arc table storage section 6 that stores the arc table storage section 6, and an arc approximation section 7 that outputs the final arc approximation result stored in the arc vector storage section 6.

次に本実施例の動作を説明する。Next, the operation of this embodiment will be explained.

本実施例は第3図に示すように前記スキャナ1により読
み取られたイメージデータはステップSJIで前記折れ
線近似部2で前記閾値dで、第4図に示すようにベクト
ル化(有向折れ線で近似)し、−旦前記ベクトル格納部
3に格納する。
In this embodiment, as shown in FIG. 3, the image data read by the scanner 1 is vectorized (approximated by directed polygonal lines) at the threshold value d in the polygonal line approximation unit 2 in step SJI as shown in FIG. ) and then stored in the vector storage section 3.

ステップSJ2で前記円弧ベクトル追跡部4は当該ベク
トル格納部3に格納されている未処理のベクトルデータ
があった場合には当該ベクトルテ′−夕を読み出す。
In step SJ2, the arc vector tracking unit 4 reads out the vector data if there is unprocessed vector data stored in the vector storage unit 3.

ステップSJ3で読み出された当該ベクトルを注目へク
トルとする。
The vector read in step SJ3 is set as the hector of interest.

ステップSJ4で前記円弧ヘクトル追跡部4ば注目ベク
トルの端点(始点または終点)に隣接している接続ベク
トルデータを見つける。
In step SJ4, the arc hector tracking unit 4 finds connection vector data adjacent to the end point (start point or end point) of the vector of interest.

ステップSJ5で当該注目ベクトルと接続ベクトルとで
組み立てられる折れ線対が円弧を形成し得るか否かを判
断する。
In step SJ5, it is determined whether the pair of broken lines assembled from the vector of interest and the connected vector can form an arc.

ここで、折れ線対が円弧を形成するか否かの判断は次の
ようにして行う。
Here, it is determined whether or not a pair of polygonal lines forms an arc as follows.

前述した■において、ベクトル化の閾値dは一般に抽出
すべき円の半径rに比較してかなり小さいため■は簡略
化されて 立2≦8dr          ■ となる。この値はある閾値dでベクトル化した半径rの
円はある長さ以上にはならないということを意味してい
る。
In the above-mentioned case (2), since the vectorization threshold d is generally quite small compared to the radius r of the circle to be extracted, the case (2) is simplified to 2≦8dr (2). This value means that a circle of radius r that is vectorized using a certain threshold value d will not exceed a certain length.

■を整理すると E=文2/8dr≦1 が得られ、Eを連続する2木のベクトルに対する円弧の
評価値として用いる。
By rearranging (2), E=sentence 2/8 dr≦1 is obtained, and E is used as the evaluation value of the arc for two consecutive tree vectors.

また当該値が1以下の範囲に含まれる場合が当該折れ線
群が円または円弧を形成するということになるが、実際
の図面では手書きの歪等により、Eの値を1にするのは
問題があり、原画に書かれる円・円弧の歪の度合いによ
って値を換えることが必要である。したがって、式■は E=12/8dr≦に とする必要がある。
Also, if the value is within the range of 1 or less, the group of polygonal lines forms a circle or arc, but in actual drawings, it is problematic to set the value of E to 1 due to handwritten distortions, etc. Yes, it is necessary to change the value depending on the degree of distortion of the circle/arc drawn on the original picture. Therefore, equation (2) needs to satisfy E=12/8dr≦.

ここで、k以下の場合が前記許容範囲に相当し、原画に
描かれた円弧の歪具合によって決めるパラメータてあり
、−例を上げると手書き図面の場合にはこの値を1.5
にして用いる。
Here, the case of k or less corresponds to the above-mentioned tolerance range, and there is a parameter determined depending on the degree of distortion of the arc drawn on the original drawing.
Use as a.

この値を連続するベクトルに対して求め、ある閾値以内
にあるか否かを判断することで、ベクトルが円弧を形成
するか否かを簡単に判断することができる。
By finding this value for consecutive vectors and determining whether it is within a certain threshold, it is possible to easily determine whether the vector forms an arc.

以上求めた評価値Eの他に次の判定を求める。In addition to the evaluation value E obtained above, the following judgments are obtained.

(a)連続する2木のベクトルの内積りがD≧0なるこ
と (b)求めた仮の半径rが、r≦l’maXなること(
C)いままでに2本のベクトルから求めた中心座標のず
れがある範囲内に納まっていること。
(a) The inner product of two consecutive tree vectors is D≧0 (b) The obtained temporary radius r is r≦l'maX (
C) The deviation of the center coordinates determined from the two vectors so far is within a certain range.

ここで、(a)は2木のベクトルのなす角度が鋭角の場
合は除外する処理、(b)はあまり大きい半径の円弧が
抽出された場合、直線部分のゆらぎの場合があるため、
それを除く処理、(C)は2つの円弧が端点て接してい
る場合に中心座標のずれによって切り離す処理である。
Here, (a) is a process that excludes cases where the angle formed by the two-tree vector is an acute angle, and (b) is a process that excludes cases where the angle formed by the two-tree vector is an acute angle.
The process for removing it (C) is a process for separating two circular arcs by shifting their center coordinates when they touch at their end points.

尚、2本のベタ1−ルを円弧で近似したときの半径と中
心位置を求めるには2本のベクトルから垂直二等分線を
引いて交点を求めることで得ることができる。
Note that the radius and center position when two vectors are approximated by circular arcs can be obtained by drawing a perpendicular bisector from the two vectors and finding the intersection.

第5図に具体的な例を示す。A specific example is shown in FIG.

ベクトル文。、窯、(u。9文1は各ベクトル長を表す
)は既に円弧を形成する候補として抽出されているもの
とする。注目ベタ1ヘル蛮、に接続している接続ベクト
ルに1anbl。の3木があった場合に、この3本につ
いてそれぞれ先に述ぺた円弧の評価値E、ベクトルの内
積、半径の範囲を求め窯。、λ□で組み立てられる折れ
線対で形成される円弧の要素となり得るか否かを判断す
る。
Vector sentence. , kiln, (u.9 sentence 1 represents each vector length) has already been extracted as a candidate for forming an arc. Attention beta 1 hell barbarian, 1 anbl to the connection vector connected to. If there are three trees, calculate the evaluation value E of the arc, the inner product of the vector, and the radius range for each of these three trees. , λ□.

例えば蛮。について判断を行う場合には第5図に示すよ
うに蛮、と窯、とて組み立てられる前記折れ線対に関し
て、当該折れ線対を円弧で近似した場合の半径をr18
、閾値をd、前記範囲をkとした場合に以下の関係が成
立する場合に蛮。、蛮、で組み立てられる折れ線対で形
成される円弧の要素となり得ると判断される。
For example, barbarism. When making a judgment, as shown in FIG.
, when the threshold value is d and the range is k, it is barbaric if the following relationship holds. It is determined that it can be an element of an arc formed by a pair of broken lines assembled by , , and .

すなわち、 flx ” / 8dria 、 la ’ /8dr
ta≦k(文、・窯、)≧0(すなわち1θ181≦9
0°)1”min≦rla≦rmax (+−minは
ベクトルで近似可能な最小の円弧の半径を示す) である。
i.e. flx”/8dria, la’/8dr
ta≦k(bun,・kiln,)≧0 (i.e. 1θ181≦9
0°) 1”min≦rla≦rmax (+-min indicates the radius of the smallest circular arc that can be approximated by a vector).

こうして、第3図に戻り、ステップSJ5で以上の判断
を行った場合に円弧にならないと判断された場合には再
びステップSJ2に進むが、円弧になり得ると判断され
た場合にはステップSJ6に進み、注目ベクトルと接続
ベタ1ヘルとを新しく円弧テーブル格納部6に登録する
In this way, returning to FIG. 3, when the above judgment is made in step SJ5, if it is determined that it will not be a circular arc, the process will proceed to step SJ2 again, but if it is determined that it can be a circular arc, the process will proceed to step SJ6. Then, the vector of interest and the connected solid 1 hell are newly registered in the arc table storage section 6.

次にステップSJ7に進み接続ベクトルとを新たに注目
ベクトルとする。
Next, the process proceeds to step SJ7, and the connection vector is newly set as a vector of interest.

ステップSJ8で前記円弧ベクトル追跡部4は注目ベク
トルの端点に接続しているベクトルを発見する。
In step SJ8, the arc vector tracking section 4 discovers a vector connected to the end point of the vector of interest.

ステップSJ9て前記円弧ベクトル判定部5は注目ベク
トルと接続ベクトルとが円弧を形成し得るか否かを前述
した(ステップ5J5)方法で判断する。
In step SJ9, the arc vector determination unit 5 determines whether the vector of interest and the connected vector can form an arc using the method described above (step SJ5).

円弧にならない場合にはステップ5J13に進み当該ベ
クトル対(折れ線対)で組み立てられる折れ線群につい
ては前記円弧テーブル格納部6への登録は終了する。
If it is not an arc, the process proceeds to step 5J13, and the registration in the arc table storage unit 6 for the polyline group assembled by the vector pair (broken line pair) is completed.

一方、円弧になり得ると判断した場合にはステップ5J
IOに進み前記円弧ヘクトル追跡部4は現在までの中心
座標のずれが円弧について一定の範囲内か否かの判断を
行う。
On the other hand, if it is determined that it can be a circular arc, step 5J
Proceeding to IO, the arc hector tracking unit 4 determines whether the deviation of the center coordinates up to now is within a certain range for the arc.

すなわち、第5図に示すようにベクトル対茎。、窯、に
より近似される円弧の中心座標oo1(x、y)及びペ
クlヘル対窯1.蛮、により近似される円弧の中心座標
01a (x + y)による中心座標のずれ(ΔX、
Δy)が円弧の一定の範囲内か否が判断される。
That is, vector versus stem as shown in FIG. , kiln, and the center coordinates of the arc approximated by oo1(x,y) and peklhel vs. kiln1. The deviation of the center coordinate (ΔX,
It is determined whether Δy) is within a certain range of the arc.

これにより円弧とならない場合にはステップ5J13に
進み前記円弧テーブルへの登録は終了し、再びステップ
SJ2に進み前記円弧ベクトル追跡部4は未処理のベク
トルデータを前記ベクトル格納部3で探索し以上の手順
を繰り返すことになる。
If this does not result in a circular arc, the process proceeds to step 5J13, where the registration in the circular arc table is completed, and the process proceeds to step SJ2 again, where the circular arc vector tracking section 4 searches the vector storage section 3 for unprocessed vector data and performs the above process. You will have to repeat the procedure.

ステップSJ2で前記円弧ベクトル追跡部4が未処理の
ベタ1ヘルデータを発見し得ない場合にはステップ5J
14に進み円弧近似部7による円弧近似処理がなされる
ことになる。
If the arc vector tracking unit 4 cannot find unprocessed solid 1 hell data in step SJ2, step 5J
The process proceeds to step 14, where arc approximation processing is performed by the arc approximation section 7.

一方、ステップ5JIOにおいて円弧になり得ると判断
した場合にはステップ5JIIに進み、前記円弧ベクト
ル追跡部4は接続した前記ベクトルを前記円弧テーブル
格納部6に登録する。
On the other hand, if it is determined in step 5JIO that it can be an arc, the process proceeds to step 5JII, where the arc vector tracking section 4 registers the connected vector in the arc table storage section 6.

さらにステップ5J12に進み再び前記円弧ベクトル追
跡部4は前記接続ムク1−ルを注目ベタ1ヘルとしてス
テップSJ8に進み以上の手順を繰り返すことになる。
Further, the process proceeds to step 5J12, and the arc vector tracking unit 4 again sets the connection square 1-1 as the focus of attention, and proceeds to step SJ8 to repeat the above procedure.

尚、前記円弧ベクトル追跡部4か注目ベクトルに対して
接続ベクトルの探索を行う場合にはベクトルの始点側と
終点側の2方向に向って探索が行われる。
Incidentally, when the arc vector tracking section 4 searches for a connection vector with respect to the vector of interest, the search is performed in two directions: the starting point side and the ending point side of the vector.

こうして、以上の判定はどれも容易に行うことができる
ため、高速な処理が可能である。
In this way, all of the above determinations can be easily made, and high-speed processing is possible.

また、抽出する円・円弧の半径の最大値rmaXが予め
与えられているので、先の不等式から許容されるベクト
ル長の最大値がわかるためベクトル長から最初に不要な
ベクトルを除外することにより、より高速な処理が可能
である。
Also, since the maximum value rmaX of the radius of the circle/arc to be extracted is given in advance, the maximum allowable vector length can be found from the above inequality, so by first excluding unnecessary vectors from the vector length, Faster processing is possible.

さらに、本実施例では隣接するベクトル間で内積な求め
、その符号の正負を判断してベクトルの向きの変化が鋭
角か否かを判断することにより、隣接ベクトルの角度を
知ることなく円または円弧に近似され得ない場合を除外
するようにしているため、高速に処理をすることが可能
である。
Furthermore, in this embodiment, by calculating the inner product between adjacent vectors, determining whether the sign is positive or negative, and determining whether the change in direction of the vector is an acute angle, it is possible to create a circle or arc without knowing the angle of adjacent vectors. Since cases that cannot be approximated are excluded, high-speed processing is possible.

〔発明の効果〕〔Effect of the invention〕

以上説明したよ・うに本発明は折れ線群が円または円弧
を形成するか否かの判断に、折れ線に近似する際に使用
した閾値な用いることにより、近似した各折れ線の長さ
が所定の範囲内に収まるということを利用している。
As explained above, the present invention uses the threshold value used when approximating a polygonal line to determine whether a group of polygonal lines forms a circle or an arc, so that the length of each approximated polygonal line is within a predetermined range. It takes advantage of the fact that it fits inside.

したがって、隣接する有向折れ線の角度変化等の複雑な
データを参照することなく高速に円または円弧の抽出を
行うことができる。
Therefore, circles or arcs can be extracted at high speed without referring to complicated data such as changes in angles of adjacent directed polygonal lines.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明の原理流れ図、第2図は実施例に係るブ
ロック図、第3図は実施例に係る流れ図、第4図は実施
例に係る円弧の評価値の説明図、第5図は実施例に係る
円弧近似の説明図である。 1・・・スキャナ 2・・・折れ線近似部 2・・・折れ線近似部 3・・・ベクトルテーブル格納部 4・・・円弧ベクトル追跡部− 5・・・円弧ベクトル判定部 6・・・円弧テーブル格納部 7・・・円弧近似部
Fig. 1 is a flowchart of the principle of the present invention, Fig. 2 is a block diagram of the embodiment, Fig. 3 is a flowchart of the embodiment, Fig. 4 is an explanatory diagram of the arc evaluation value of the embodiment, and Fig. 5 FIG. 2 is an explanatory diagram of arc approximation according to the embodiment. 1... Scanner 2... Broken line approximation unit 2... Broken line approximation unit 3... Vector table storage unit 4... Arc vector tracking unit - 5... Arc vector determination unit 6... Arc table Storage section 7...Circular arc approximation section

Claims (1)

【特許請求の範囲】 原画を形成する線と有向折れ線との距離が所定の閾値内
含まれるように原画を有向折れ線で近似し(S1)、連
続する有向折れ線により組み立てられた折れ線群が円弧
を形成するか否かを判断し、円弧を形成すると判断した
場合は当該折れ線群を円又は円弧で近似して原画から円
又は円弧を抽出する円・円弧抽出方法において、 隣接する2本の当該有向折れ線で組み立てられた折れ線
対を円弧で近似した場合に得られる当該円弧の半径、当
該折れ線対を組み立てている各折れ線の長さ及び前記閾
値に基づいて定まる所定の評価値が所定の許容範囲内に
含まれるか否かを判断し(S2)、 当該範囲内に含まれていると判断した場合には当該折れ
線材から組み立てられている折れ線群を円又は円弧で近
似する(S3)ことを特徴とする円・円弧抽出方法。
[Claims] The original picture is approximated by directed polygonal lines so that the distance between the lines forming the original picture and the directed polygonal lines is within a predetermined threshold (S1), and a polygonal line group assembled from continuous directed polygonal lines is created. In the circle/arc extraction method, which judges whether or not the line forms an arc, and if it is determined that it forms an arc, approximates the group of polygonal lines with a circle or arc to extract the circle or arc from the original image. A predetermined evaluation value that is determined based on the radius of the arc obtained when the polygonal line pair assembled with the directed polygonal lines is approximated by a circular arc, the length of each polygonal line that composes the polygonal line pair, and the threshold value is predetermined. (S2), and if it is determined that it is within the range, the group of broken lines assembled from the broken wire is approximated by a circle or an arc (S3). ) A method for extracting circles and arcs.
JP12695088A 1988-05-26 1988-05-26 Circle and circular arc extracting method Pending JPH01297775A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP12695088A JPH01297775A (en) 1988-05-26 1988-05-26 Circle and circular arc extracting method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP12695088A JPH01297775A (en) 1988-05-26 1988-05-26 Circle and circular arc extracting method

Publications (1)

Publication Number Publication Date
JPH01297775A true JPH01297775A (en) 1989-11-30

Family

ID=14947908

Family Applications (1)

Application Number Title Priority Date Filing Date
JP12695088A Pending JPH01297775A (en) 1988-05-26 1988-05-26 Circle and circular arc extracting method

Country Status (1)

Country Link
JP (1) JPH01297775A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0682325A2 (en) * 1994-05-13 1995-11-15 United Kingdom Atomic Energy Authority Identification method and apparatus

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61131085A (en) * 1984-11-29 1986-06-18 Fujitsu Ltd Processing system for linear graphic discrimination
JPS61208585A (en) * 1985-03-13 1986-09-16 Hitachi Ltd Data compression system for two dimensional line image

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61131085A (en) * 1984-11-29 1986-06-18 Fujitsu Ltd Processing system for linear graphic discrimination
JPS61208585A (en) * 1985-03-13 1986-09-16 Hitachi Ltd Data compression system for two dimensional line image

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0682325A2 (en) * 1994-05-13 1995-11-15 United Kingdom Atomic Energy Authority Identification method and apparatus
EP0682325A3 (en) * 1994-05-13 1997-03-19 Atomic Energy Authority Uk Identification method and apparatus.

Similar Documents

Publication Publication Date Title
JP4924165B2 (en) Shape comparison device and shape comparison method
CN108665490B (en) Graph matching method based on multi-attribute coding and dynamic weight
KR20020031591A (en) Shape descriptor extracting method
KR20210057907A (en) Method and Apparatus for Generating Intelligent Engineering Drawings Based on Deep Learning
Wang et al. 2D affine-invariant contour matching using B-spline model
Tombre et al. Vectorization in graphics recognition: to thin or not to thin
KR20230009641A (en) Method for detecting crack in structures
Rosin et al. Curve segmentation and representation by superellipses
Ramel et al. A structural representation for understanding line-drawing images
US20020006224A1 (en) Computer automated process for vectorization of raster images
CN110390336B (en) Method for improving feature point matching precision
JPH01297775A (en) Circle and circular arc extracting method
JP2785776B2 (en) Figure shaping device
Ramel et al. Automatic reading of handwritten chemical formulas from a structural representation of the image
CN112116011B (en) Feature coding method and similarity comparison method for CAD graph
Salehin et al. Conics detection method based on pascal's theorem
CN112802098A (en) TM-SRC-based three-dimensional non-texture target pose estimation method
JPS6232584A (en) Method for extracting contour shape feature
KR20010092891A (en) Content-based image retrieval method based on sketch features
Shigeta et al. Extraction and Recognition of Components from Point Clouds of Industrial Plants
Kim et al. Solving discontinuity and distortion problems in boundary based image segmentation and representation
Choi et al. Extract Shape from Clipart Image Using Modified Chain Code–Rectangle Representation
CN115170735A (en) Three-dimensional local surface feature description method based on deviation angle statistics
JPH04119477A (en) Curve approximating method
JPH07182509A (en) Graphic recognition device