JPS6379181A - Image processing device - Google Patents
Image processing deviceInfo
- Publication number
- JPS6379181A JPS6379181A JP61223698A JP22369886A JPS6379181A JP S6379181 A JPS6379181 A JP S6379181A JP 61223698 A JP61223698 A JP 61223698A JP 22369886 A JP22369886 A JP 22369886A JP S6379181 A JPS6379181 A JP S6379181A
- Authority
- JP
- Japan
- Prior art keywords
- image
- ram3
- point
- index value
- loop
- 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
Links
- 238000006243 chemical reaction Methods 0.000 abstract description 8
- 238000000034 method Methods 0.000 description 6
- 230000009466 transformation Effects 0.000 description 6
- 238000010586 diagram Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 1
Abstract
Description
【発明の詳細な説明】
(産業上の利用分野)
本発明はHough変換を高速実行する画像処理装置に
関する。DETAILED DESCRIPTION OF THE INVENTION (Field of Industrial Application) The present invention relates to an image processing device that performs Hough transformation at high speed.
(従来技術)
最近、テレビカメラで撮影した空間画像から消点を求め
てカメラの向きを判断するなどの消点応用技術が注目さ
れているが、この消点検出に当ワて直線の決定か必要で
ある。(Prior art) Recently, vanishing point application technology has been attracting attention, such as determining the direction of the camera by determining the vanishing point from a spatial image taken with a television camera. is necessary.
従来1画像処理などてHough変換による直線の決定
が用いられているが、Houg11変換は点列から直線
成分や円弧成分を抽出するための処理である。この方法
においては、点列の座標を(X、。Conventionally, determination of straight lines by Hough transformation has been used in image processing, etc., but Hough 11 transformation is a process for extracting straight line components and circular arc components from a sequence of points. In this method, the coordinates of the point sequence are (X, .
yi)とすると、直線式y=ax+bと一致する点の個
数をすべてのa、bに対して求めることにより直線成分
を抽出して直線式を求め、また円の式(x xo)2
+ (y yo)” =r2と一致する点の個数を、
すべてのX。+3’o、rに対して計算することにより
円の式を求めている。特に、直線式の場合はaの大きさ
としては−ωから+(1)までとる必要かあるがリニア
にとるのてはなく、0=jan −’aとした場合のθ
を−πからπまてリニアにとるのか精度上理想的である
。yi), by finding the number of points that match the linear equation y = ax + b for all a and b, extracting the linear component and finding the linear equation, and also using the circle equation (x xo) 2
+ (y yo)” = the number of points that match r2,
All X. The equation of the circle is obtained by calculating for +3'o and r. In particular, in the case of a linear equation, it is necessary to take the size of a from -ω to +(1), but it is not possible to take it linearly, but when 0 = jan -'a, θ
It is ideal for accuracy to take linearity from -π to π.
しかしながら、このような従来の1101J g h変
換な用いた画像処理装置にあっては、特別に)I o
u g h変換専用のプロセッサはなく、またjan−
’の計算にも時間を要するため1画面全体をHough
変換すると、膨大な計算時間がかかるという問題があっ
た。However, in an image processing device that uses such a conventional 1101J g h conversion,
There is no dedicated processor for Ugh conversion, and
It takes time to calculate ', so the entire screen is
There was a problem in that conversion required a huge amount of calculation time.
(発明の目的および構成)
本発明は上記の点にかんがみてなされたもので、 [
Iough変換を用いて画像処理する際の処理時間を短
縮することを目的とし、この目的を達成するために、画
像を構成する点列の座標データから所定の定数を減算し
、減算結果に基づいて所定の参照テーブルを用いて演算
指標値を求め、求めた演算指標値をインクレメントする
ように構成した。(Object and structure of the invention) The present invention has been made in view of the above points, and [
The purpose is to shorten the processing time when processing images using Iough transformation. The calculation index value is calculated using a predetermined reference table, and the calculated calculation index value is incremented.
(実施例) 以下本発明を図面に基づいて説明する。(Example) The present invention will be explained below based on the drawings.
第1図は本発明による画像処理装置のブロック線図であ
る。FIG. 1 is a block diagram of an image processing apparatus according to the present invention.
まず構成を説明すると、ホストコンピュータ(マイクロ
プログラム式が望ましい)1を中心に、画像メモリ2、
RAM3、加算器4a、4b、定数レジスタ5a、5b
、LUT (ルックアップテーブル)6、インクリメン
ト@算部7より成る。画像メモリは2画像データを記憶
し、RAM3は、点列のアドレスデータな格納するため
のもので、少なくともホストコンピュータ1て書き込み
加算器4aにX、を、加算器4bにy□を出力できる。First, to explain the configuration, the host computer (preferably a microprogram type) 1 is centered around the image memory 2,
RAM3, adders 4a, 4b, constant registers 5a, 5b
, an LUT (lookup table) 6, and an increment@ calculation section 7. The image memory stores two image data, and the RAM 3 is for storing point sequence address data, and can at least write X to the host computer 1 and output y to the adder 4a and y□.
画像メモリ2を256X256(M=256)とすると
RAM3のデータはX。If the image memory 2 is 256×256 (M=256), the data in the RAM 3 is X.
yそれぞれ8bitで合計16bitでよい。加算器4
aと4bはそれぞれRAM3の出力(X、。y can be 8 bits each, making the total 16 bits. Adder 4
a and 4b are the outputs of RAM3 (X, .
y+)とレジスタ5a、5bの出力(−XQ、−yo)
とを加算する。レジスタ5a、5bの内容はホストコン
ピュータ1により書き込む。加算器4a、4bの出力(
X =−X On yi−yo)はLUT6に入力され
る。LUT6はRAMで構成されホストコンピュータ1
により内容を書き込んだ後、入力X。y+) and the outputs of registers 5a and 5b (-XQ, -yo)
Add. The contents of registers 5a and 5b are written by host computer 1. Outputs of adders 4a and 4b (
X = -X On yi-yo) is input to LUT6. LUT6 is composed of RAM and is connected to host computer 1.
After writing the contents, input X.
Yに対し演算指標値Zを出力する。X、Yはそれぞれ8
〜9bit、Zは8bit程度とする(1枚の画像メモ
リを流用してもよい)(64に〜256にバイトのRA
M)。LUT6の出力はインクリメント演算部7に入力
される。インクリメント演算部7は少なくとも256バ
イトのRAMを持ち演算指標値Zて表わされるアドレス
の内容をインクリメント(+1)l、、て再格納する。A calculation index value Z is output for Y. X and Y are each 8
-9 bits, Z about 8 bits (one image memory may be used) (RA of 64 to 256 bytes)
M). The output of the LUT 6 is input to the increment calculation section 7. The increment calculation unit 7 has a RAM of at least 256 bytes, and increments (+1)l, . . . and re-stores the contents of the address represented by the calculation index value Z.
インクリメント演算部7は256木のカウンタで構成し
てもよい。The increment calculation unit 7 may be configured with a 256-tree counter.
本発明による画像処理装置においては、画像を入力した
後、エツジを強調し2値化する。そして“l”の部分す
なわちエツジ部について)tough変換を行う。In the image processing apparatus according to the present invention, after inputting an image, edges are emphasized and binarized. Then, tough conversion is performed on the "l" portion, that is, the edge portion.
第2図は本発明により直線を求めるHough変換のフ
ローチャートである。FIG. 2 is a flowchart of Hough transformation for obtaining a straight line according to the present invention.
まずホストコンピュータlによりLUT6の書き込みを
行なう(F、−1)。この場合入力(x、y)に対して
出力(演算指標値)ZはIYI≦IXIのとき、すなわ
ち直線の傾きa=Y/Xの絶対値か1以下のときはZ=
X/Yとし、lyl>lXtのとき、すなわち傾きaの
絶対値か1以上のときはZ=X/Yとする。こうすれば
−■<a<ωに対し−1<Z<1か得られ、8bit精
度で計算しても誤差は少なくなる。First, the host computer 1 writes to LUT6 (F, -1). In this case, the output (calculation index value) Z for the input (x, y) is when IYI≦IXI, that is, when the slope of the straight line a = the absolute value of Y/X or less than 1, Z =
When lyl>lXt, that is, when the absolute value of the slope a is 1 or more, Z=X/Y. In this way, -1<Z<1 can be obtained for -■<a<ω, and the error will be reduced even if the calculation is performed with 8-bit accuracy.
次に、画像メモリ2を掃引し、画像を構成する点列の座
標(x i 、y r )をRAM3に格納する(F−
2)。i=1〜Nとし、Nは点の個数てあり。Next, the image memory 2 is swept and the coordinates (x i , y r ) of the point sequence forming the image are stored in the RAM 3 (F-
2). Let i=1 to N, where N is the number of points.
画像により異なる。XOをゼロとし、yoを−M/2か
らM/2(画像の大きさはMXMである)まで変化させ
(F−3)以下の処理を行う。y。Varies depending on the image. Set XO to zero, change yo from -M/2 to M/2 (the image size is MXM), and perform the following processing (F-3). y.
は直線式y=ax+bの切片すに対応する。 ′ルー
プ内処理については、まず、インクリメント演算部7を
初期化して各カウンタの値またはRAMの内容をゼロに
セットする(F−4)。次t、:RAM3をIII!ニ
i = 1〜Nまで掃引する(F−5)。RAM3の出
力(xi 、y+ )は加算器4a、4bでそれぞれレ
ジスタ5a、5bの出力と加算されてX i−X On
’J 1−yOが計算され(F−6)、LUT6にX
、Yとして入力される(F−7)。LUT6からは入力
X=x、−xo+Y=y=−Yoに対応する値、すなわ
ちある点(x t + y 、)と、点(xo、yo)
とを結ぶ直線の傾きに対応する演算指標値Zが出力され
る。そして、インクリメント演算部7では、この傾きに
相当する演算指標値Zで示されるアドレスの内容がイン
クレメントされる(F−8)。こうして、RAM3をi
=1〜Nで掃引すると点(X o + yO)とすべて
の点(x i −y i )とを結ぶ直線の傾きの頻度
がインクリメント演算部7に残る。corresponds to the intercept of the linear equation y=ax+b. ' Regarding the in-loop processing, first, the increment calculation section 7 is initialized and the value of each counter or the contents of the RAM is set to zero (F-4). Next t: RAM3 III! Sweep from i=1 to N (F-5). The outputs (xi, y+) of the RAM 3 are added to the outputs of the registers 5a and 5b by adders 4a and 4b, respectively, and X i-X On
'J 1-yO is calculated (F-6) and
, Y (F-7). From LUT6, the values corresponding to the inputs X=x, -xo+Y=y=-Yo, that is, a certain point (x t + y,) and the point (xo, yo)
A calculation index value Z corresponding to the slope of the straight line connecting the lines is output. Then, the increment calculation unit 7 increments the content of the address indicated by the calculation index value Z corresponding to this slope (F-8). In this way, RAM3 is
=1 to N, the frequency of the slope of the straight line connecting the point (X o + yO) and all the points (x i - y i ) remains in the increment calculation unit 7.
最後にインクリメント演算部7の内容αJ(j=1〜2
56)を読み出し1画像メモリ2の(j。Finally, the contents αJ (j=1 to 2
56) and (j.
yo)位置、(jが傾きaに対応し、Yoが切片すに対
する)に格納して(F−9)1回のループが終了する。yo) position (where j corresponds to the slope a and Yo to the intercept) (F-9) and one loop ends.
この処理をy。=−M/2からM/2まて、M回ループ
すれば、1画面の1次(直線) Hough変換が終
了する(F−10)。第3図(ロ)は同図(イ)に示ず
よな画像をHough変換して得られる画像の座標系を
示している。This process is y. If the loop is repeated M times from =-M/2 to M/2, the linear (linear) Hough transformation of one screen is completed (F-10). FIG. 3(B) shows the coordinate system of an image obtained by Hough-transforming the different images shown in FIG. 3(A).
次に第4図には本発明により円弧成分を求めるための処
理のフローチャートを示す。Next, FIG. 4 shows a flowchart of the process for determining the arc component according to the present invention.
LUT6への書き込みは前述した直線の傾きに代って、
半径に対応する値すなわち X+V1である。画像メモ
リ2を掃引し点の座標(X=、yi)をRAM3に格納
する(P−2)、Xoを−M/2〜M/2まで変化させ
、yoも−M/2〜M/2まで変化させて画面全体を掃
引し、各点でループ内演算を行う(P−3,P−4)、
、ループ内の演算は直線の場合と同様であり、まずイン
クリメント演算部7を初期化しくP−5)、RAM3を
i=1〜Nで順に掃引する(P−6)。次いでRAM出
力3の(Xi、yi)は加算器4a、4bでレジスタ5
a、5bの出力を加算されて(X。−x o) 、(y
r −y o)か計算され(P−7)、LUT6にX
、Yとして入力される(P−8)、LUT6から出力す
る演算指標値Zはこの場合は点(X、。Writing to LUT6 is performed using the slope of the straight line described above.
The value corresponding to the radius is X+V1. Sweep the image memory 2 and store the coordinates (X=, yi) of the point in the RAM 3 (P-2), change Xo from -M/2 to M/2, and yo also from -M/2 to M/2 Sweep the entire screen by varying it up to , and perform calculations within the loop at each point (P-3, P-4).
, the calculations in the loop are the same as in the case of a straight line; first, the increment calculation section 7 is initialized (P-5), and the RAM 3 is sequentially swept with i=1 to N (P-6). Next, (Xi, yi) of RAM output 3 is sent to register 5 by adders 4a and 4b.
The outputs of a and 5b are added (X.-x o), (y
r −y o) is calculated (P-7), and X
, Y (P-8), and the calculation index value Z output from LUT 6 is the point (X,) in this case.
yi)と点(xo、yo)との距離に対応した値となる
ためインクリメント演算部7でインクリメントされた(
P−9)、内容αJ(j=1〜256)は距離の頻度と
なる。したがって、点(x o + y o )が円弧
の中心にあればα、は大きな値となり、そのときのjの
値は半径の大きさに対応する。そこでインクリメント演
算部7の内容αjを順に読み出しある閾値より大きいα
jの個数を画像メモリの(xo、yo)位置に格納して
(P−10)1回のループを終了する。この処理をX。Since the value corresponds to the distance between yi) and the point (xo, yo), it is incremented by the increment calculation unit 7 (
P-9), the content αJ (j=1 to 256) is the frequency of distance. Therefore, if the point (x o + y o ) is at the center of the circular arc, α will be a large value, and the value of j at that time corresponds to the size of the radius. Then, the contents αj of the increment calculation unit 7 are read out in order and α that is larger than a certain threshold value is read out.
The number of objects j is stored in the (xo, yo) position of the image memory (P-10) and one loop is completed. This process is
=−M/2からM/2およびy。=−M/2からM/2
までについて行うことにより画面全体にわたって掃引す
れば(P−11)、結果として円弧の中心点に値を持つ
画像となる。=-M/2 to M/2 and y. =-M/2 to M/2
If the entire screen is swept by performing the steps up to (P-11), the result will be an image that has a value at the center point of the arc.
(発明の効果)
以上説明したように、本発明においては、画像を構成す
る点列の座標データから所定の定数を減算し、減算結果
の基づいて所定の参照テーブルを用いて演算指標値を求
め、求めた演算指標値をインクレメントするように構成
したので、精度の良いllough変換が高速で実行で
きるという効果か得られる。(Effects of the Invention) As explained above, in the present invention, a predetermined constant is subtracted from the coordinate data of a sequence of points constituting an image, and a calculation index value is calculated using a predetermined reference table based on the subtraction result. Since the calculated calculation index value is incremented, it is possible to perform lough conversion with high precision at high speed.
第1図は本発明による画像処理装置の一実施例のブロッ
ク線図、第2図は本発明による画像処理装着における直
線成分の検出手順を示すフローチャート、第3図は本発
明により Hough変換して得られる直線成分の座標
系を示しており、(イ)は変換前の画像、(ロ)は変換
後の画像、第4図は本発明による画像処理装置における
円弧成分の検出子1唄を示すフローチャート、第5図は
本発明により得られる円弧成分の座標系を示しており、
(イ)はもとの画像、(ロ)は得られた画像である。
l・・・ホストコンピュータ、2・・・画像メモリ、3
−RA M、4a、4b−加算器、5a、5b−レジス
タ、6・・・LUT (ルックアップテーブル)、7・
・・インクリメント演算部
特許出願人 日産自動車株式会社
代理人 弁理士 鈴 木 弘 男
第1図
第3図
(イ) (ロ)
−X −」第5図FIG. 1 is a block diagram of an embodiment of the image processing apparatus according to the present invention, FIG. 2 is a flowchart showing the procedure for detecting linear components in the image processing device according to the present invention, and FIG. The coordinate system of the linear component obtained is shown, (a) is the image before conversion, (b) is the image after conversion, and FIG. 4 shows one song of the arc component detector in the image processing device according to the present invention. The flowchart, FIG. 5, shows the coordinate system of the arc component obtained by the present invention,
(a) is the original image, and (b) is the obtained image. l...Host computer, 2...Image memory, 3
-RAM, 4a, 4b-adder, 5a, 5b-register, 6...LUT (lookup table), 7...
Incremental operation unit patent applicant Hiroshi Suzuki, agent of Nissan Motor Co., Ltd., patent attorney Figure 1 Figure 3 (a) (b)
-X-'' Figure 5
Claims (1)
憶された画像データのうち点列の座標データを順次出力
する書込み読み出し可能なメモリと、該書込み読み出し
可能なメモリから出力する座標データから所定の定数を
減算する減算手段と、処理に応じて所定の参照テーブル
が格納され前記減算手段からの減算結果に基づいて該参
照テーブルを用いて演算指標値を出力するルックアップ
テーブルと、該ルックアップテーブルから出力する演算
指標値で示されるアドレスの内容をインクリメントする
インクリメント手段とを有することを特徴とする画像処
理装置。An image memory that stores image data; a writable and readable memory that sequentially outputs coordinate data of a point sequence among the image data stored in the image memory; a subtraction means for subtracting a constant; a lookup table in which a predetermined reference table is stored in accordance with processing and outputs a calculation index value using the reference table based on the subtraction result from the subtraction means; and the lookup table. An image processing apparatus comprising: an incrementing means for incrementing the contents of an address indicated by an arithmetic index value output from an image processing apparatus.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP61223698A JPS6379181A (en) | 1986-09-24 | 1986-09-24 | Image processing device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP61223698A JPS6379181A (en) | 1986-09-24 | 1986-09-24 | Image processing device |
Publications (1)
Publication Number | Publication Date |
---|---|
JPS6379181A true JPS6379181A (en) | 1988-04-09 |
Family
ID=16802251
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP61223698A Pending JPS6379181A (en) | 1986-09-24 | 1986-09-24 | Image processing device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JPS6379181A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5555555A (en) * | 1993-01-19 | 1996-09-10 | Aisin Seiki Kabushiki Kaisha | Apparatus which detects lines approximating an image by repeatedly narrowing an area of the image to be analyzed and increasing the resolution in the analyzed area |
-
1986
- 1986-09-24 JP JP61223698A patent/JPS6379181A/en active Pending
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5555555A (en) * | 1993-01-19 | 1996-09-10 | Aisin Seiki Kabushiki Kaisha | Apparatus which detects lines approximating an image by repeatedly narrowing an area of the image to be analyzed and increasing the resolution in the analyzed area |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US3905045A (en) | Apparatus for image processing | |
US5224064A (en) | Transcendental function approximation apparatus and method | |
US5029226A (en) | Method and apparatus for effecting spot/void filtering of image data | |
JPS62299881A (en) | Image rotation display unit | |
US5093871A (en) | Method and apparatus for effecting background suppression of image data | |
US4945505A (en) | Cordic apparatus and method for approximating the magnitude and phase of a complex number | |
JPH0835818A (en) | Image processing apparatus and method | |
CN111666442B (en) | Image retrieval method and device and computer equipment | |
US5140444A (en) | Image data processor | |
US5383142A (en) | Fast circuit and method for detecting predetermined bit patterns | |
JPS6379181A (en) | Image processing device | |
EP0365226A2 (en) | Cordic apparatus and method for approximating the magnitude and phase of a complex number | |
US5475810A (en) | Pie chart processing method and processor | |
US5325316A (en) | Compression processing method of real number data in processing system and apparatus therefor | |
JPH11515118A (en) | Method and apparatus for detecting double entries in a lookup table | |
JPH104358A (en) | Signal processing method and equipment | |
JPS61222374A (en) | Picture image reader | |
JPH0519354B2 (en) | ||
JPH0410669B2 (en) | ||
JP2861435B2 (en) | Pipeline type arithmetic unit | |
JPS62257580A (en) | Picture measuring circuit | |
JPS6073791A (en) | Picture processing device | |
JP3505970B2 (en) | Input position coordinate correction method | |
JP2013037482A (en) | Information processing method, information processor, and program | |
JPH01223880A (en) | Line noise rejection method |