Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP2852859B2 - Line break processing method - Google Patents
[go: Go Back, main page]

JP2852859B2 - Line break processing method - Google Patents

Line break processing method

Info

Publication number
JP2852859B2
JP2852859B2 JP31452793A JP31452793A JP2852859B2 JP 2852859 B2 JP2852859 B2 JP 2852859B2 JP 31452793 A JP31452793 A JP 31452793A JP 31452793 A JP31452793 A JP 31452793A JP 2852859 B2 JP2852859 B2 JP 2852859B2
Authority
JP
Japan
Prior art keywords
line
color
line drawing
area
processing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP31452793A
Other languages
Japanese (ja)
Other versions
JPH07141502A (en
Inventor
博 柴崎
幸彦 磯川
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Dainippon Screen Manufacturing Co Ltd
Original Assignee
Dainippon Screen Manufacturing Co 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 Dainippon Screen Manufacturing Co Ltd filed Critical Dainippon Screen Manufacturing Co Ltd
Priority to JP31452793A priority Critical patent/JP2852859B2/en
Publication of JPH07141502A publication Critical patent/JPH07141502A/en
Application granted granted Critical
Publication of JP2852859B2 publication Critical patent/JP2852859B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Preparing Plates And Mask In Photomechanical Process (AREA)
  • Image Processing (AREA)
  • Editing Of Facsimile Originals (AREA)
  • Facsimile Image Signal Circuits (AREA)
  • Image Analysis (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】この発明は、線画を表わす線画デ
ータを修正することによって線画の線切れ部を処理する
方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a method for processing a line break in a line drawing by correcting line drawing data representing the line drawing.

【0002】[0002]

【従来の技術】カラー印刷の刷版を作成する製版工程に
おいては、文字や線画の原画となる版下台紙が作成され
る。版下台紙は、写植文字や製図された罫線が最終印刷
物と同寸法、同品質で配置されたものである。版下台紙
にはその後の工程に関する指示も記入されており、製版
工程の指示書としての役割も有している。
2. Description of the Related Art In a plate making process for preparing a printing plate for color printing, an underlaying board which is an original of characters and line drawings is prepared. The underlaying board is one in which typesetting characters and drafted ruled lines are arranged with the same size and quality as the final printed matter. Instructions for the subsequent steps are also written on the underlaying sheet, and also serve as instructions for the plate making process.

【0003】多くの場合、画像内の一部の領域を所望の
一様な色で塗りつぶす色付け処理が製版工程で行なわれ
る。近年の画像処理システムでは、これまで手作業で行
なっていた色付け処理を自動的に行なうものがある。こ
のようなシステムでは、版下画像の2値画像データをス
キャナで読み取り、さらに画像処理装置によって版下画
像内において線で区切られた所望の領域を所望の色で塗
りつぶすことによって色付け処理を行なう。
[0003] In many cases, a color-imparting process is performed in a plate-making process to fill a part of an image with a desired uniform color. 2. Description of the Related Art In recent image processing systems, there is a system that automatically performs a coloring process which has been performed manually until now. In such a system, the binary image data of the composition image is read by a scanner, and the image processing device performs a coloring process by painting a desired area separated by a line in the composition image with a desired color.

【0004】このような色付け処理を行なう場合に、版
下画像内で本来閉領域を形成すべき線画が「線切れ」を
起こしている場合がある。「線切れ」の原因は、原画
(版下台紙)上に存在する線切れや、画像読み取り装置
で読み取る際の読み取り不良などである。従来は、線切
れ部の位置をオペレータがCRTに表示された版下画像
内から直接探しだして、切れた線をつなげるように版下
画像を修正していた。
[0004] When such a coloring process is performed, there is a case where a line drawing that should form a closed region in the underlay image has "line breakage". The cause of the “line break” is a line break existing on the original image (underlaying board), a reading error when reading by the image reading device, and the like. Conventionally, the operator has directly searched for the position of a line break from the composition image displayed on the CRT, and has corrected the composition image so as to connect the broken lines.

【0005】[0005]

【発明が解決しようとする課題】しかし、線切れ部の幅
は1画素から数画素程度のことが多いため、オペレータ
がCRT上で発見することが困難であり、また、線切れ
部が多数存在する場合には、これらをすべて発見して修
正するのにかなりの処理時間を要するという問題があっ
た。
However, since the width of a line break is often about one pixel to several pixels, it is difficult for an operator to find the line break on a CRT, and there are many line breaks. In such a case, there is a problem that it takes a considerable processing time to find and correct all of them.

【0006】画像内の線切れ部を検出し、接続する方法
としては、例えば、本出願人により開示された特開平4
−239387号公報に記載されたものがある。
As a method for detecting and connecting a broken line in an image, for example, Japanese Patent Laid-Open No.
No. 2,393,387.

【0007】[0007]

【発明が解決しようとする課題】しかし、上述の方法で
は、走査線と平行な方向に沿ってギャップが開いている
ような線切れ部を検出するのが困難であるという問題が
あった。
However, the above-described method has a problem that it is difficult to detect a broken line where a gap is opened in a direction parallel to the scanning line.

【0008】この発明は、従来技術における上述の課題
を解決するためになされたものであり、線切れのギャッ
プの方向に係わらずに線切れ部を容易に検出することの
できる方法を提供することを目的とする。
SUMMARY OF THE INVENTION The present invention has been made to solve the above-mentioned problem in the prior art, and provides a method for easily detecting a broken line regardless of the direction of a broken line gap. With the goal.

【0009】[0009]

【課題を解決するための手段および作用】上述の課題を
解決するため、この発明の線切れ部の処理方法は、第1
の色の背景の上に第2の色の線が描かれた第1の線画を
表わす線画データを処理することにより、前記線画の線
切れ部を処理する方法であって、(A)前記第1の線画
内において前記第2の色の画像領域を所定の幅で太らせ
ることによって前記画像領域の周囲に付加領域を形成
し、これによって第2の線画を生成する工程と、(B)
前記第2の線画に含まれる前記第1の色の画像領域を前
記所定の幅で太らせることによって第3の線画を生成す
る工程と、(C)前記第3の線画に残存している前記付
加領域の周囲における色の変化の数を調べる工程と、
(D)前記色の変化数が4以上である場合には前記付加
領域を線切れ候補領域として検出する工程と、を備え
る。
SUMMARY OF THE INVENTION In order to solve the above-mentioned problems, a method for processing a broken line according to the present invention is described as follows.
(A) processing line breaks in the line drawing by processing line drawing data representing a first line drawing in which a line of a second color is drawn on a background of the color of (a). (B) forming an additional area around the image area by widening the image area of the second color by a predetermined width in one line drawing, thereby generating a second line drawing;
Generating a third line drawing by thickening the image area of the first color included in the second line drawing by the predetermined width; and (C) generating a third line drawing remaining in the third line drawing. Determining the number of color changes around the additional area;
(D) detecting the additional area as a line break candidate area when the number of color changes is four or more.

【0010】第2の色に関する太らせ処理と第1の色に
関する太らせ処理を所定の幅で実行することによって、
線切れ部のように微細な部分に付加領域が残存する。線
切れ部に残存している付加領域はその周囲における色の
変化数が4以上になるので、各付加領域の周囲における
色の変化数を調べることによって線切れ部の候補となる
線切れ候補領域を検出できる。
By executing the thickening process for the second color and the thickening process for the first color with a predetermined width,
The additional region remains in a minute portion such as a broken line. Since the number of color changes around the additional region remaining at the line break becomes four or more, the line break candidate region that is a candidate for a line break is obtained by examining the number of color changes around each additional region. Can be detected.

【0011】上記の方法は、さらに、(E)線切れ候補
領域を前記第2の色で塗りつぶすことによって、前記第
1の線画内に存在する線切れ部を接続する工程、を備え
ていてもよい。こうすれば、線切れ部を容易に接続でき
る。
The above method may further comprise the step of: (E) connecting a line break existing in the first line drawing by filling the line break candidate area with the second color. Good. In this case, the wire break can be easily connected.

【0012】[0012]

【実施例】図1は、この発明の一実施例を適用して線画
データの処理を行なう線画処理装置20の構成を示すブ
ロック図である。線画処理装置20は、次のような構成
要素を備えている。
FIG. 1 is a block diagram showing the configuration of a line drawing processing apparatus 20 for processing line drawing data according to an embodiment of the present invention. The line drawing processing device 20 includes the following components.

【0013】CPU22:線画処理装置の各部の制御、
および、線画データに関する各種の処理(ピンホール消
去、表示用画像データ作成、線切れ候補領域の検出、線
切れ部の補修、塗りつぶし等)を実行する。CPU22
と、以下に説明する構成要素とは、バス24を介して相
互に接続されている。
CPU 22: control of each part of the line drawing processing device;
In addition, various processes related to line drawing data (such as pinhole erasure, display image data creation, detection of a line break candidate region, repair of a line break, and filling) are performed. CPU 22
And components described below are interconnected via a bus 24.

【0014】ROM26:CPU22が実行する処理プ
ログラムを記憶する。
ROM 26: stores a processing program executed by the CPU 22.

【0015】RAM28:線画の画像処理に使用される
種々のパラメータや一時的なデータを記憶するメモリで
ある。
RAM 28: A memory for storing various parameters and temporary data used for image processing of line drawings.

【0016】線画メモリ32:線画データを記憶するメ
モリであり、カラーパレットもここに記憶されている。
線画メモリ32は、1頁分の線画データを記憶できるメ
モリプレーンを複数枚有している。線画処理の中にはソ
ース線画データ(処理前の線画データ)とデスティネー
ション線画データ(処理後の線画データ)を記憶する必
要があるものが存在するので、少なくとも2枚のメモリ
プレーンが用意されている。このような線画処理は、一
般に「ソース/デスティネーション処理」と呼ばれてい
る。例えば、後述する太らせ処理や細らせ処理はいずれ
もソース/デスティネーション処理である。
Line drawing memory 32: A memory for storing line drawing data, and a color palette is also stored here.
The line drawing memory 32 has a plurality of memory planes capable of storing line drawing data for one page. Since some line drawing processes need to store source line drawing data (line drawing data before processing) and destination line drawing data (line drawing data after processing), at least two memory planes are prepared. I have. Such line drawing processing is generally called “source / destination processing”. For example, the thickening process and the thinning process described later are both source / destination processes.

【0017】キーボード用I/Oインタフェイス34:
キーボード36とマウス38からの入力を受け付けるイ
ンタフェイス。
Keyboard I / O interface 34:
An interface for receiving inputs from the keyboard 36 and the mouse 38.

【0018】表示制御部42:線画データをカラーCR
T44に転送して線画を表示する際に使用されるインタ
フェイス。CRT44に線画を表示する際には、CPU
22が線画データを間引いた後にビットマップ展開して
間引き画像のビットマップデータを作成し、このビット
マップデータが表示制御部42に転送される。
Display controller 42: converts line drawing data to color CR
Interface used when displaying line drawing by transferring to T44. When displaying a line drawing on the CRT 44, the CPU
After the line drawing data is thinned out, the bit map data is developed by bit map development and the bit map data is transferred to the display control unit.

【0019】画像データ入出力用インタフェイス46:
平面スキャナ60から供給される線画データを受け取っ
たり、線画データを記録スキャナ50に転送したりする
際に使用されるインタフェイス。
Image data input / output interface 46:
An interface used when receiving line drawing data supplied from the flatbed scanner 60 and transferring the line drawing data to the recording scanner 50.

【0020】平面スキャナ60は、版下などの白黒の線
画から2値の線画データを読取るスキャナである。読取
った線画データは、ランレングスデータの形式で平面ス
キャナ60から線画処理装置20に供給され、線画メモ
リ32に記憶される。
The flat scanner 60 is a scanner that reads binary line drawing data from a black and white line drawing such as a block copy. The read line drawing data is supplied from the flat scanner 60 to the line drawing processor 20 in the form of run-length data, and is stored in the line drawing memory 32.

【0021】記録スキャナ50は、色付けされたカラー
の線画を表わす線画データからYMCKの4色の色分解
画像を感光フィルム上に記録するスキャナである。
The recording scanner 50 is a scanner that records four color separation images of YMCK on a photosensitive film from line drawing data representing a colored line drawing.

【0022】図2は、線画処理の手順を示すフローチャ
ートである。ステップS1では、平面スキャナ60を用
いて線画データを読取る。図3(A)は、読取られた線
画データで表わされる線画を示す平面図である。この線
画は、白色の背景領域の上に黒色の領域R1,PH1,
PH2が配置された画像である。背景領域には白色を示
す色番号#0が割り当てられており、領域R1,PH
1,PH2には黒色を示す色番号#1が割り当てられて
いる。なお、領域PH1,PH2はピンホールである。
また、領域R1は目視でも観察できる線切れ部CT1を
含んでいる。
FIG. 2 is a flowchart showing the procedure of the line drawing process. In step S1, line drawing data is read using the flat scanner 60. FIG. 3A is a plan view showing a line drawing represented by the read line drawing data. This line drawing consists of black regions R1, PH1,
It is an image in which PH2 is arranged. A color number # 0 indicating white is assigned to the background area, and the area R1, PH
1, PH2 is assigned a color number # 1 indicating black. The regions PH1 and PH2 are pinholes.
The region R1 includes a line break CT1 that can be visually observed.

【0023】図4は、図3(A)の線画を表わす線画デ
ータの構造を示す概念図である。図4(A)に示すよう
に、線画データは、ヘッダとカラーパレットとランレン
グスデータとで構成されている。ヘッダは、線画データ
のファイル名や、線画の大きさ、解像度などを含んでい
る。図4(B)に示すカラーパレットには、各色番号に
対応して4つの色版YMCKの網点面積率(網%)が登
録されている。図4(B)に示すカラーパレットには2
つの色番号#0,#1しか登録されていないが、線画の
各部に新たな色番号が割り当てられると、カラーパレッ
トにその色番号に対応する各色版の網%が登録される。
FIG. 4 is a conceptual diagram showing the structure of line drawing data representing the line drawing of FIG. As shown in FIG. 4A, the line drawing data is composed of a header, a color palette, and run-length data. The header includes the file name of the line drawing data, the size of the line drawing, the resolution, and the like. In the color palette shown in FIG. 4B, halftone dot area ratios (halftone%) of four color planes YMCK are registered corresponding to respective color numbers. The color palette shown in FIG.
Although only two color numbers # 0 and # 1 are registered, when a new color number is assigned to each part of the line drawing, the halftone% of each color plate corresponding to the color number is registered in the color palette.

【0024】図4(C)に示すランレングスデータは、
線画の各ランごとに形成された1単位のデータ(以下、
「単位ランレングスデータ」と呼ぶ)で構成されてい
る。単位ランレングスデータは、各ランの色番号とラン
長さとを含んでいる。なお、図4(C)は、図3(A)
に示す走査線SLに対応する単位ランレングスデータを
示したものである。色番号の欄に記載された記号「X」
は、無効データであることを示している。また、ラン長
さが0の単位ランレングスデータは、走査線の終端を示
すデータである。このような線画データは、線画メモリ
32に記憶される。
The run length data shown in FIG.
One unit of data formed for each run of the line drawing
(Referred to as “unit run-length data”). The unit run length data includes a color number and a run length of each run. Note that FIG. 4C corresponds to FIG.
3 shows unit run length data corresponding to the scanning line SL shown in FIG. Symbol "X" described in the column of color number
Indicates invalid data. The unit run length data having a run length of 0 is data indicating the end of a scanning line. Such line drawing data is stored in the line drawing memory 32.

【0025】図2のステップS2では、線画処理装置2
0において線画のピンホール消去が行なわれる。これ
は、線画内に含まれる互いに独立な領域(以下、単に
「独立領域」と呼ぶ)のそれぞれに関して画素数を算出
し、所定の画素数以下の独立領域をピンホール領域とし
て認識し、そのピンホール領域の色を周囲の色と同一の
色に変更する処理である。図3(A)の例では、領域P
H1,PH2がピンホールとして消去される。
In step S2 of FIG.
At 0, pinhole erasure of the line drawing is performed. This is because the number of pixels is calculated for each of the independent regions (hereinafter, simply referred to as “independent regions”) included in the line drawing, and the independent regions having a predetermined number of pixels or less are recognized as pinhole regions. This is a process of changing the color of the hole area to the same color as the surrounding color. In the example of FIG.
H1 and PH2 are erased as pinholes.

【0026】ステップS3では、オペレータがカラーC
RT44に表示された線画を観察し、肉眼で見える線切
れ部を手動操作で接続する。図3(A)の例では、領域
R1が線切れ部CT1を含むので、この部分を黒色で接
続する。なお、手動の接続処理では、オペレータが画面
上において2つの点の位置を指示するとともに、これら
の2点で接続される直線の幅と色とを指定する。線画処
理装置20は、これらの指示に応じて、指定された2点
を指定幅と指定色を有する直線で接続する。図3(B)
は、ピンホールPH1,PH2の消去と、目視可能な線
切れ部CT1の接続とを行なって得られた線画を示して
いる。
In step S3, the operator sets the color C
The line drawing displayed on the RT 44 is observed, and a line break visible with the naked eye is manually connected. In the example of FIG. 3A, since the region R1 includes the line break CT1, this portion is connected in black. In the manual connection process, the operator specifies the positions of two points on the screen and specifies the width and color of a straight line connected by these two points. In response to these instructions, the line drawing processing device 20 connects the specified two points with a straight line having a specified width and a specified color. FIG. 3 (B)
Shows a line drawing obtained by erasing the pinholes PH1 and PH2 and connecting the visible line break CT1.

【0027】図3(B)に示す黒色の領域R1は、まだ
線切れ部CT2を含んでいるが、これは肉眼では観察で
きないものであると仮定する。図3(B)(及び図3
(A))では、図示の便宜上、線切れ部CT2を拡大し
て示している。
The black region R1 shown in FIG. 3B still contains a line break CT2, which is assumed to be invisible to the naked eye. FIG. 3 (B) (and FIG.
(A)), for convenience of illustration, the broken line portion CT2 is enlarged.

【0028】図2のステップS4〜S6は、肉眼では直
接観察できない線切れ部を検出して接続する処理であ
る。まずステップS4では、線切れ部の候補となる領域
(以下、「線切れ候補領域」と呼ぶ)を検出する。
Steps S4 to S6 in FIG. 2 are processing for detecting and connecting line breaks which cannot be directly observed with the naked eye. First, in step S4, a region that is a candidate for a line break (hereinafter, referred to as a “line break candidate region”) is detected.

【0029】図5は、ステップS4における線切れ候補
領域の検出処理の詳細手順を示すフローチャートであ
る。また、図6は、ステップS4における処理内容を示
す説明図である。図6(A)は、図3(B)に示す黒色
の領域R1の拡大図であり、線切れ部CT2が誇張され
て描かれている。
FIG. 5 is a flowchart showing a detailed procedure of the line break candidate area detection process in step S4. FIG. 6 is an explanatory diagram showing the processing content in step S4. FIG. 6A is an enlarged view of the black region R1 shown in FIG. 3B, and the line break CT2 is exaggerated.

【0030】ステップS41では、線の色番号#1を有
する画像領域を予め指定された変形幅Wtだけ太らせる
とともに、太らせによって作成された付加領域に新たな
色番号を割り当てる。この実施例では、線の色番号とし
て色番号#1が使用されているが、線の色番号としては
任意の色番号を指定することが可能である。
In step S41, the image area having the line color number # 1 is thickened by a predetermined deformation width Wt, and a new color number is assigned to the additional area created by the thickening. In this embodiment, the color number # 1 is used as the line color number, but an arbitrary color number can be specified as the line color number.

【0031】ステップS41の処理の結果、図6(B)
に示すように、色番号#1の画像領域R1の外側と内側
に、新たな色番号#2を有する幅Wtの付加領域SRが
形成される。なお、変形幅Wtとしては、線切れ部のギ
ャップの最大幅の約1/2の値が予め指定されている。
As a result of the processing in step S41, FIG.
As shown in the figure, an additional region SR having a new color number # 2 and a width Wt is formed outside and inside the image region R1 of the color number # 1. Note that, as the deformation width Wt, a value of about 1 / of the maximum width of the gap at the line break is specified in advance.

【0032】ステップS41における太らせ処理は、8
近傍ウィンドウや4近傍ウィンドウなどのウィンドウオ
ペレータを用いた処理によって実現することが可能であ
り、また、色番号#1の画像領域R1の輪郭線を外側に
拡張する処理によって実現することも可能である。
The fattening process in step S41 is performed as follows:
This can be realized by a process using a window operator such as a nearby window or a four-neighbor window, or by expanding the outline of the image region R1 of the color number # 1 to the outside. .

【0033】ステップS42では、背景の色番号#0を
有する画像領域を変形幅Wtだけ太らせる。ただし、こ
の際、線の色番号#1を有する画像領域R1は、背景の
色番号#0を有する画像領域に侵食されないこととす
る。色番号#1の領域が侵食されないこととする処理
は、「色番号#1にプロテクトをかける」と呼ばれる。
図6(C)の線画は、ステップS42の処理によって得
られた線画である。この線画は、色番号#1の画像領域
R1と、ステップS42における太らせ処理の後に残っ
た付加領域SR1〜SR5とを含んでいる。
In step S42, the image area having the background color number # 0 is thickened by the deformation width Wt. However, at this time, the image region R1 having the line color number # 1 is not eroded by the image region having the background color number # 0. The process of not eroding the area of the color number # 1 is called “protecting the color number # 1”.
The line drawing in FIG. 6C is a line drawing obtained by the processing in step S42. This line drawing includes an image region R1 of the color number # 1 and additional regions SR1 to SR5 remaining after the thickening process in step S42.

【0034】なお、ステップS42において色番号#0
の領域を太らせる処理は、色番号#1の領域と色番号#
2の領域の和領域を細らせる処理と等価である。ただ
し、この場合にも色番号#1の領域にプロテクトをかけ
ておく必要がある。
In step S42, color number # 0
The process of thickening the area is performed by using the area of the color number # 1 and the color number #
This is equivalent to the process of narrowing the sum area of the two areas. However, also in this case, it is necessary to protect the area of the color number # 1.

【0035】ステップS43では、こうして得られた線
画に領域分離処理(「領域分割処理」とも呼ばれる)を
行なって、線画に含まれる独立領域を互いに識別する。
図6(C)の線画を対象として領域分離処理を行なう
と、色番号#0の領域BG1,BG2と、色番号#1の
領域R1と、色番号#2の領域SR1,SR2,SR
3,SR4,SR5が、それぞれ別個の独立領域として
識別される。なお、領域分離処理によって独立領域とし
て認識された場合にも、各独立領域の色番号はそのまま
に保たれる。
In step S43, the line drawing thus obtained is subjected to region separation processing (also referred to as "region division processing") to identify independent regions included in the line drawing.
When the area separation process is performed on the line drawing of FIG. 6C, the areas BG1 and BG2 of the color number # 0, the area R1 of the color number # 1, and the areas SR1, SR2 and SR of the color number # 2 are obtained.
3, SR4 and SR5 are each identified as a separate independent region. It should be noted that the color number of each independent area is kept as it is even when the area is recognized as an independent area by the area separation processing.

【0036】ステップS44では、独立領域の中で、付
加領域の色番号#2を有する領域(すなわち付加領域)
SR1〜SR5のそれぞれについて、その周囲における
色の変化の数Nを求めるとともに、Nの値に応じてその
付加領域の色番号を変更する。後述するように、周囲に
おける色の変化数Nが4以上の付加領域は線切れ候補と
認識され、その領域を代表する座標がメモリに記憶され
る。
In step S44, an area having the color number # 2 of the additional area (ie, additional area) in the independent area.
For each of SR1 to SR5, the number N of color changes around it is determined, and the color number of the additional area is changed according to the value of N. As will be described later, an additional area in which the number N of color changes in the surrounding area is 4 or more is recognized as a line break candidate, and coordinates representing the area are stored in the memory.

【0037】図7は、ステップS44の処理の詳細を示
すフローチャートである。また、図8は、図7の手順の
処理内容を示す説明図である。ステップT1では、付加
領域を1つ選択する。図8(A)の付加領域SRaは、
説明の便宜上、図6(C)に示す付加領域SR1〜SR
5のいずれとも異なっている。
FIG. 7 is a flowchart showing the details of the process in step S44. FIG. 8 is an explanatory diagram showing the processing contents of the procedure of FIG. In step T1, one additional area is selected. The additional region SRa in FIG.
For convenience of description, additional regions SR1 to SR shown in FIG.
5 is different.

【0038】ステップT2では、付加領域SRaを色番
号#3で塗りつぶすとともに、付加領域に含まれる画素
の座標の最小値(xmin ,ymin )と最大値(xmax ,
ymax )を求める(図8(A)参照)。なお、「色番号
#3で塗りつぶす」とは、付加領域SRaのランレング
スデータの色番号を#3に変更することを意味してい
る。
In step T2, the additional region SRa is painted with the color number # 3, and the minimum value (xmin, ymin) and the maximum value (xmax, xmax, xmin) of the coordinates of the pixels included in the additional region SRa.
ymax) (see FIG. 8A). Note that “painting with color number # 3” means changing the color number of the run-length data of the additional area SRa to # 3.

【0039】ステップT3では、(xmin −1,ymin
−1)〜(xmax +1,ymax +1)の範囲において、
付加領域SRaを1画素太らせる。この太らせ処理で
は、図8(B)に示す4近傍ウィンドウW1を2点(x
min −1,ymin −1),(xmax +1,ymax +1)
で規定される矩形領域内で順次移動させ、中心画素CP
1の色番号が#0または#1であって4つの周辺画素の
うちの少なくとも1つの色番号が#3である場合に、中
心画素CP1の色番号を#4または#5に変更する。こ
の際、元の色番号が#0であった部分は色番号を#4に
変更し、元の色番号が#1であった部分は色番号を#5
に変更する。図8(C)はこうして得られた線画を示し
ている。
In step T3, (xmin−1, ymin
-1) to (xmax + 1, ymax + 1)
The additional region SRa is made thicker by one pixel. In this fattening process, the four neighboring windows W1 shown in FIG.
min-1, ymin-1), (xmax + 1, ymax + 1)
Are sequentially moved within the rectangular area defined by
If the color number of # 1 is # 0 or # 1 and at least one of the four peripheral pixels is # 3, the color number of the center pixel CP1 is changed to # 4 or # 5. At this time, the color number is changed to # 4 for the portion where the original color number was # 0, and the color number is changed to # 5 for the portion where the original color number was # 1.
Change to FIG. 8C shows the line drawing thus obtained.

【0040】ステップT4では、図8(D)に示す8近
傍ウィンドウW2を用いて付加領域SRaの周囲におけ
る色の変化の数N(以下、「色変化数」と呼ぶ)を求め
る。図8(D)に示すように、8近傍ウィンドウW2の
8つの周辺画素には、1〜8の優先度が割り当てられて
いる。ステップT4の処理では、中心画素CP2を色番
号#4と#5の領域内の各画素に配置し、色番号が#4
また#5である周辺画素の中で最も優先度の高い周辺画
素(以下、「優先周辺画素」と呼ぶ)の色番号を調べ
る。そして、この優先周辺画素の色番号と中心画素CP
2の色番号とが異なる場合(すなわち一方が#4で他方
が#5の場合)に色が変化していると判断し、色変化数
1を計数する。一方、優先周辺画素の色番号と中心画素
CP2の色番号とが等しい場合には、色変化が無いと判
断する。こうして、色番号#4と#5の各画素に8近傍
ウィンドウW2の中心画素を適用することによって付加
領域SRaの周囲の色変化数Nを求める。なお、ステッ
プT4の具体的な処理では、2点(xmin −2,ymin
−2),(xmax +2,ymax +2)で規定される矩形
領域内において8近傍ウィンドウW2を主走査方向yに
沿って順次移動させ、中心画素CP2の色番号が#4ま
たは#5の場合に上記のような色変化の有無の判断を行
なう。
In step T4, the number N of color changes around the additional region SRa (hereinafter, referred to as the "color change number") is obtained using the eight neighborhood windows W2 shown in FIG. 8D. As shown in FIG. 8D, eight peripheral pixels of the eight neighboring windows W2 are assigned priorities of 1 to 8. In the process of step T4, the center pixel CP2 is arranged at each pixel in the regions of the color numbers # 4 and # 5, and the color number # 4
Also, the color number of the peripheral pixel having the highest priority among the peripheral pixels of # 5 (hereinafter referred to as “priority peripheral pixel”) is checked. Then, the color number of the priority peripheral pixel and the central pixel CP
If the color number is different from the color number 2 (that is, if one is # 4 and the other is # 5), it is determined that the color has changed, and the number of color changes 1 is counted. On the other hand, when the color number of the priority peripheral pixel is equal to the color number of the center pixel CP2, it is determined that there is no color change. In this manner, the number N of color changes around the additional region SRa is obtained by applying the center pixel of the 8-neighbor window W2 to each pixel of the color numbers # 4 and # 5. In the specific processing of step T4, two points (xmin−2, ymin
-2), the eight neighboring windows W2 are sequentially moved in the main scanning direction y within the rectangular area defined by (xmax + 2, ymax + 2), and the color number of the center pixel CP2 is # 4 or # 5. The presence or absence of the color change as described above is determined.

【0041】図8(E),(F)は、8近傍ウィンドウ
W2の中心画素CP2を図8(C)の点P1と点P2に
配置した場合をそれぞれ示している。図8(E)の場合
には、優先周辺画素の色番号#4(図中、丸で示す)と
中心画素の色番号#5とは異なるので、色変化があると
判断されて、色変化数Nの値が1つ増加する。一方、図
8(F)の場合には、優先周辺画素の色番号#4と中心
画素の色番号#4とが等しいので、色変化が無いと判断
されて、色変化数Nはそのままの値に保たれる。このよ
うな処理を色番号#4と#5の領域に対して実行すれ
ば、付加領域SRaの周囲における色変化数Nを求める
ことができる。
FIGS. 8E and 8F show the case where the center pixel CP2 of the 8-neighbor window W2 is arranged at the points P1 and P2 in FIG. 8C, respectively. In the case of FIG. 8E, since the color number # 4 of the priority peripheral pixel (indicated by a circle in the figure) is different from the color number # 5 of the central pixel, it is determined that there is a color change, and The value of the number N increases by one. On the other hand, in the case of FIG. 8F, since the color number # 4 of the priority peripheral pixel is equal to the color number # 4 of the center pixel, it is determined that there is no color change, and the number N of color changes remains unchanged. Is kept. If such processing is performed on the areas of color numbers # 4 and # 5, the number N of color changes around the additional area SRa can be obtained.

【0042】ステップT5では、色変化数Nの値が4以
上であるか否かが判断される。図9は、色変化数Nの値
が2,4,6にそれぞれ等しい場合を示す説明図であ
る。図9からも解るように、付加領域の周囲における色
変化数Nは偶数である。また、図9(A)に示すような
色変化数Nが2の付加領域は、もともと線切れ部以外の
微細な部分に形成された領域である。一方、図9
(B),(C)に示すように、色変化数Nが4以上の付
加領域は線切れ部のような比較的小さなギャップに形成
された領域である。そこで、色変化数Nが4以上の場合
には、その付加領域を線切れ候補領域として認識し、ス
テップT6においてその線切れ候補領域を示す候補領域
表示座標CDISP((xmin +xmax )/2,(ymin +
ymax )/2)と候補領域処理座標CPROC(xmin ,y
1 )とをメモリに記憶する。図10は、候補領域表示座
標CDISPと候補領域処理座標CPROCの一例を示す説明図
である。候補領域表示座標CDISPは、後述するように、
線切れ候補領域の位置をカラーCRT44に表示する際
に用いられる座標であり、線切れ候補領域の最大座標と
最小座標の平均値で構成されている。候補領域処理座標
CPROCは、後述するように、線切れ候補領域の補修処理
を行なう際に処理の開始点を示す座標として用いられ
る。候補領域処理座標CPROCの主走査座標y1 は、線切
れ候補領域の副走査座標の最小値xmin におけるy座標
の最小の座標値である。
In step T5, it is determined whether the value of the color change number N is 4 or more. FIG. 9 is an explanatory diagram showing a case where the value of the color change number N is equal to 2, 4, and 6, respectively. As can be seen from FIG. 9, the number N of color changes around the additional area is an even number. Further, the additional area where the color change number N is 2 as shown in FIG. 9A is an area originally formed in a fine portion other than the line break. On the other hand, FIG.
As shown in (B) and (C), the additional area where the color change number N is 4 or more is an area formed in a relatively small gap such as a broken line. Therefore, when the color change number N is 4 or more, the additional area is recognized as a line break candidate area, and candidate area display coordinates CDISP ((xmin + xmax) / 2, ( ymin +
ymax) / 2) and the candidate area processing coordinates CPROC (xmin, y
1) is stored in the memory. FIG. 10 is an explanatory diagram showing an example of the candidate area display coordinates CDISP and the candidate area processing coordinates CPROC. The candidate area display coordinates CDISP are, as described later,
These coordinates are used when the position of the line break candidate area is displayed on the color CRT 44, and include an average value of the maximum coordinates and the minimum coordinates of the line break candidate area. As will be described later, the candidate area processing coordinates CPROC are used as coordinates indicating the start point of the processing when performing the repair processing of the line break candidate area. The main scanning coordinate y1 of the candidate area processing coordinates CPROC is the minimum y-coordinate value at the minimum value xmin of the sub-scanning coordinates of the line break candidate area.

【0043】なお、ステップT6では、処理対象となっ
ている付加領域の色番号#3はそのままに保たれる。す
なわち、線切れ候補領域として決定された付加領域につ
いては色番号が#3に保たれる。一方、ステップT5に
おいて色変化数Nが4未満の(すなわちN=2の)場合
には、ステップT7において色番号#3の領域(処理対
象となっている付加領域)を色番号#0で塗りつぶす
(図9(A)参照)。ステップT7の処理は、その付加
領域を消去することと等価である。
In step T6, the color number # 3 of the additional area to be processed is kept as it is. That is, the color number is maintained at # 3 for the additional area determined as the line break candidate area. On the other hand, if the color change number N is less than 4 (that is, N = 2) in step T5, the area of color number # 3 (the additional area to be processed) is painted out with color number # 0 in step T7. (See FIG. 9A). The process of step T7 is equivalent to erasing the additional area.

【0044】このように、線切れ候補領域として決定さ
れた付加領域については、ステップT6においてその領
域を代表する点を示す候補領域表示座標CDISPと候補領
域処理座標CPROCがメモリに記憶されるとともに、線切
れ候補領域の色番号が#3のままに保たれる。一方、線
切れ候補領域でないと決定された領域については、ステ
ップT7においてその領域の色番号を背景の色を示す色
番号#0に変更することによって、その領域を消去す
る。
As described above, for the additional area determined as the line break candidate area, the candidate area display coordinates CDISP and the candidate area processing coordinates CPROC indicating the points representing the area in step T6 are stored in the memory. The color number of the line break candidate area is kept at # 3. On the other hand, the area determined to be not the line break candidate area is erased by changing the color number of the area to the color number # 0 indicating the background color in step T7.

【0045】ステップT6またはT7が終了すると、ス
テップT8において、色番号#4と#5の領域が、それ
ぞれの元の色番号#0、#1に変更される。この理由
は、色番号#4と#5の領域は、付加領域の周囲におけ
る色変化数Nを調べるために便宜的に形成された領域だ
からである。ステップT9では、線画に含まれるすべて
の付加領域についてステップT1〜T8の処理が終了し
たか否かが判断される。終了していなければ、ステップ
T1に戻り、次の付加領域について上述のステップT1
〜T8の処理が実行される。
When step T6 or T7 ends, in step T8, the areas of color numbers # 4 and # 5 are changed to the original color numbers # 0 and # 1, respectively. This is because the areas of the color numbers # 4 and # 5 are formed for convenience in order to check the number N of color changes around the additional area. In step T9, it is determined whether or not the processing in steps T1 to T8 has been completed for all the additional regions included in the line drawing. If not, the process returns to step T1, and the above-described step T1 is performed for the next additional area.
To T8 are executed.

【0046】図6(D)は、図6(C)の線画について
図7の処理を実行した結果を示している。図6(C)に
示す5つの付加領域SR1〜SR5の内で、第1の付加
領域SR1以外の付加領域は消去されており、また、第
1の付加領域SR1の色番号は#2から#3に変更され
ている。
FIG. 6D shows the result of executing the processing of FIG. 7 on the line drawing of FIG. 6C. Of the five additional regions SR1 to SR5 shown in FIG. 6C, the additional regions other than the first additional region SR1 have been deleted, and the color numbers of the first additional region SR1 are # 2 to # 2. It has been changed to 3.

【0047】こうして図7の処理(すなわち図5のステ
ップS44の処理)が終了すると、図2のステップS5
が実行される。ステップS5では、線画の中に線切れ候
補領域が存在するか否かが判断される。線切れ候補領域
が無ければ、後述するステップS7における色付け処理
に移行する。一方、線切れ候補領域が存在すれば、ステ
ップS6において線切れ候補領域を補修する処理が実行
される。
When the processing in FIG. 7 (ie, the processing in step S44 in FIG. 5) is completed, the processing in step S5 in FIG.
Is executed. In step S5, it is determined whether or not a line break candidate area exists in the line drawing. If there is no line break candidate area, the process proceeds to a coloring process in step S7 described later. On the other hand, if there is a line break candidate area, processing for repairing the line break candidate area is executed in step S6.

【0048】図11は、ステップS6における線切れ候
補領域の補修処理の手順を示すフローチャートである。
ステップS61では、すべての線切れ候補領域を自動補
修するか否かが判断される。イラストや罫線などの大き
な線画部品のみを含む線画を処理する場合には、線切れ
候補領域は常に線切れ部なので、オペレータが全候補領
域の自動補修を選択する。一方、線画が文字などの微細
な線画部品を含む場合には、線切れ候補領域が文字など
の微細な部分の一部である可能性があるので、個別の選
択補修を選択する。
FIG. 11 is a flowchart showing the procedure of the repair processing of the line break candidate area in step S6.
In step S61, it is determined whether or not all the line break candidate areas are automatically repaired. When processing a line drawing including only large line drawing parts such as illustrations and ruled lines, the operator selects automatic repair of all the candidate regions because the line break candidate region is always a line break. On the other hand, when the line drawing includes a fine line drawing part such as a character, there is a possibility that the line break candidate area is a part of a fine part such as a character, so the individual selective repair is selected.

【0049】ステップS61において全候補領域を自動
補修することが指示された場合には、ステップS62に
おいて、全候補領域を線の色番号#1で塗りつぶす。線
切れ候補領域には色番号#3が割り当てられているの
で、ステップS62の処理は、ランレングスデータにお
ける色番号を#3から#1に変更する処理である。図6
(D)からも解るように、線切れ候補領域SR1は線を
表わす領域R1の線切れ部CT2のギャップを埋めてい
るので、線切れ候補領域SR1の色番号#3を線の色番
号#1に変更することによって、実質的に線切れ部CT
2を接続することができる。なお、色番号を変更する際
には、候補領域処理座標CPROC(図10)が利用され、
この座標位置の画素に連結する画素の色番号を順次#3
から#1に変更する。なお、連結する画素の検出には4
近傍のアルゴリズムが使用される。このように、候補領
域処理座標CPROCを利用すれば、線切れ候補領域の補修
を確実に実行することができる。
If it is instructed in step S61 to automatically repair all candidate areas, in step S62 all candidate areas are painted out with line color number # 1. Since color number # 3 is assigned to the line break candidate area, the process of step S62 is a process of changing the color number in the run-length data from # 3 to # 1. FIG.
As can be seen from (D), since the line break candidate region SR1 fills the gap of the line break CT2 of the region R1 representing the line, the color number # 3 of the line break candidate region SR1 is replaced with the line color number # 1. Is substantially changed to the line break CT
2 can be connected. When the color number is changed, the candidate area processing coordinates CPROC (FIG. 10) are used.
The color number of the pixel connected to the pixel at this coordinate position is sequentially # 3
From # 1 to # 1. Note that the detection of connected pixels is
A neighboring algorithm is used. As described above, by using the candidate area processing coordinates CPROC, the repair of the line break candidate area can be surely executed.

【0050】図11のステップS61において、全候補
領域を自動補修することが指示されていない場合には、
ステップS63において、未処理の線切れ候補領域が存
在するか否かが判断される。未処理の候補領域が存在す
る場合には、ステップS64において線切れ候補領域を
1つ選択し、その候補領域を補修するモードをオペレー
タが指定する。なお、ステップS64においては、予め
メモリに記憶された候補領域表示座標CDISPが1つ読出
されて、その位置の画素(あるいはその周囲の数画素)
がカラーCRT44の画面上に他の画像領域の色と明瞭
に区別されて表示される。例えば、カラーCRT44に
線画が白黒の画像として表示されている場合には、候補
領域表示座標DDICPの位置を赤色などの目立つ色で表示
する。
In step S61 of FIG. 11, when it is not instructed to automatically repair all candidate areas,
In step S63, it is determined whether an unprocessed line break candidate area exists. If there is an unprocessed candidate area, one of the line break candidate areas is selected in step S64, and the operator specifies a mode for repairing the candidate area. In step S64, one candidate area display coordinate CDISP previously stored in the memory is read out, and the pixel at that position (or several pixels around it) is read out.
Is displayed on the screen of the color CRT 44 so as to be clearly distinguished from the colors of other image areas. For example, when the line drawing is displayed as a black and white image on the color CRT 44, the position of the candidate area display coordinates DDICP is displayed in a conspicuous color such as red.

【0051】補修のモードとしては、自動補修モード、
手操作補修モード、消去モードの3つがある。ステップ
S64において自動補修モードが選択されると、ステッ
プS65において、処理対象となっている線切れ候補領
域が色番号#1で塗りつぶされる。
The repair mode includes an automatic repair mode,
There are three modes: manual repair mode and erase mode. When the automatic repair mode is selected in step S64, the line break candidate area to be processed is painted with the color number # 1 in step S65.

【0052】ステップS64において手操作補修モード
が選択されると、ステップS66において、処理対象と
なっている線切れ候補領域が色番号#0で塗りつぶされ
る。これは、線切れ候補領域を消去することと等価であ
る。そして、ステップS67において、手操作によって
その線切れ部を補修する。手操作による補修としては、
直線の2端点を指定してその間を所定の幅で接続する、
いわゆる直線描画処理を利用することができる。
When the manual repair mode is selected in step S64, the line break candidate area to be processed is painted out with the color number # 0 in step S66. This is equivalent to erasing the line break candidate region. Then, in step S67, the broken line portion is repaired by a manual operation. As manual repairs,
Specify two end points of a straight line and connect them with a predetermined width.
So-called straight line drawing processing can be used.

【0053】ステップS64において消去モードが選択
されると、ステップS68において、処理対象となって
いる線切れ候補領域が色番号#0で塗りつぶされて消去
される。
When the erase mode is selected in step S64, in step S68, the line break candidate area to be processed is painted out with the color number # 0 and erased.

【0054】ステップS64〜S68の処理によって1
つの線切れ候補領域の補修が終了すると、ステップS6
3に戻り未処理の線切れ候補領域が存在するか否かが再
び判断される。こうして、各線切れ候補領域についてス
テップS63〜S68の処理が繰り返し実行される。
By the processing of steps S64 to S68, 1
When the repair of the two line break candidate areas is completed, step S6
Returning to 3, it is determined again whether or not there is an unprocessed line break candidate area. Thus, the processing of steps S63 to S68 is repeatedly executed for each line break candidate area.

【0055】上述したように、線切れ候補領域をカラー
CRT44に表示する際には、候補領域表示座標CDISP
によって線切れ候補領域の中心位置を示すので、どのよ
うに補修すべきかをオペレータが容易に判断できる。候
補領域表示座標CDISPの位置の画素は線切れ候補領域に
含まれていない場合があるが、色番号の変更は候補領域
処理座標CPROCの画素から実行するので、線切れ候補領
域の補修処理を確実に行なうことができる。このよう
に、各線切れ候補領域を代表する座標として候補領域表
示座標CDISPと候補領域処理座標CPROCの2つを記憶し
ておくことによって、容易にかつ確実に線切れ部の補修
を行なうことが可能となる。ただし、線切れ候補領域を
代表する座標としては、1つの座標のみ(例えば候補領
域処理座標CPROCのみ)を記憶するようにしておいても
よい。
As described above, when displaying the line break candidate area on the color CRT 44, the candidate area display coordinates CDISP
Indicates the center position of the line break candidate area, so that the operator can easily determine how to repair. The pixel at the position of the candidate area display coordinates CDISP may not be included in the line break candidate area. However, since the color number is changed from the pixel at the candidate area processing coordinates CPROC, the repair processing of the line break candidate area is surely performed. Can be performed. In this way, by storing the candidate area display coordinates CDISP and the candidate area processing coordinates CPROC as the coordinates representing each of the line break candidate areas, the line break can be easily and reliably repaired. Becomes However, only one coordinate (for example, only the candidate area processing coordinates CPROC) may be stored as the coordinates representing the line break candidate area.

【0056】ステップS6における線切れ候補領域の補
修が終了すると、ステップS7(図2)において線画の
色付け処理が実行される。色付け処理は、オペレータが
線画中の領域を1つずつ指定して所望の色でその領域を
塗りつぶす処理である。ステップS7,S8で所望の領
域について色付け処理が終了すると、ステップS9にお
いて線画を出力する。この実施例においては、ステップ
S9において記録スキャナ50において線画の網目版画
像が感光フィルムに記録される。
When the repair of the line break candidate region in step S6 is completed, a line drawing coloring process is executed in step S7 (FIG. 2). The coloring process is a process in which an operator designates regions in a line drawing one by one and fills the regions with a desired color. When the coloring process is completed for the desired area in steps S7 and S8, a line drawing is output in step S9. In this embodiment, a mesh image of a line drawing is recorded on a photosensitive film by the recording scanner 50 in step S9.

【0057】以上のように、上記実施例では、線の色番
号#1を有する領域R1を所定の変形幅Wtだけ太らせ
(図6(B))、この後に背景の色番号#0を有する領
域を変形幅Wtだけ太らせることによって、付加領域S
R1〜SR5を形成する(図6(C))。そして、各付
加領域の周囲における色変化数Nが4以上の場合にその
付加領域を線切れ候補領域として認識するので、線切れ
部を容易に認識することが可能である。また、上記の方
法によって線切れ候補領域を形成すれば、線切れ部のギ
ャップの方向に関わらずに線切れ候補領域を形成するこ
とが可能である。さらに、線切れ候補領域の色番号#3
を線の色番号#1に変更するだけで線切れ部が接続され
るので、線切れ部の接続を容易に行なうことができる。
なお、文字の細かい部分など、本来は線切れ部ではない
微細な部分が線切れ候補領域として認識された場合に
は、この候補領域の色番号を#0に変更するだけで、そ
の候補領域を容易に消去することが可能である。このよ
うに、上記実施例では、線切れ部として接続したい部分
を容易に検出して接続できるとともに、線切れ部でない
微細な部分をそのままに保つことができる。
As described above, in the above-described embodiment, the region R1 having the line color number # 1 is thickened by the predetermined deformation width Wt (FIG. 6B), and thereafter the background color number # 0 is provided. By increasing the area by the deformation width Wt, the additional area S
R1 to SR5 are formed (FIG. 6C). When the number N of color changes around each additional region is 4 or more, the additional region is recognized as a line break candidate region, so that a line break can be easily recognized. Further, if the line break candidate region is formed by the above method, it is possible to form the line break candidate region regardless of the direction of the gap at the line break. Further, color number # 3 of the line break candidate area
Is changed to only the line color number # 1 so that the line break can be easily connected.
If a fine part that is not originally a line break, such as a fine part of a character, is recognized as a line break candidate area, the color number of this candidate area is simply changed to # 0, and the candidate area is changed to # 0. It can be easily erased. As described above, in the above-described embodiment, it is possible to easily detect and connect a portion to be connected as a broken portion, and to keep a fine portion that is not a broken portion as it is.

【0058】なお、この発明は上記実施例に限られるも
のではなく、その要旨を逸脱しない範囲において種々の
態様において実施することが可能であり、例えば次のよ
うな変形も可能である。
The present invention is not limited to the above-described embodiment, but can be implemented in various modes without departing from the gist thereof. For example, the following modifications are possible.

【0059】(1)付加領域の周囲における色変化数N
を求める方法としては、図8に示すもの以外の種々の方
法を採用することができる。図12は、図8の方法に代
わる方法を示す説明図である。図12(A)に示す付加
領域SRaに対して、図12(B)に示す8近傍ウィン
ドウW3を適用することにより、図12(C)に示すよ
うに、付加領域SRaの周囲に周辺領域PR1〜PR4
を形成する。すなわち、8近傍ウィンドウW3の中心画
素CP3が色番号#0または#1を有し、かつ、8つの
周辺画素のうちの少なくとも1つが色番号#3を有する
場合に、その画素を周辺領域の画素として決定すること
によって周辺領域PR1〜PR4が得られる。8近傍ウ
ィンドウを用いて形成した周辺領域PR1〜PR4は互
いに連結しているので、これらの周辺領域PR1〜PR
4における色変化の数を検出することによって、付加領
域SRaの周囲における色変化数Nを求めることが可能
である。なお、図8(C)の例と同様に、周辺領域PR
1〜PR4に新たな色番号を割り当てても良い。
(1) The number N of color changes around the additional area
Various methods other than the method shown in FIG. FIG. 12 is an explanatory diagram showing a method that is an alternative to the method of FIG. By applying the 8-neighbor window W3 shown in FIG. 12B to the additional region SRa shown in FIG. 12A, as shown in FIG. 12C, a peripheral region PR1 is formed around the additional region SRa. ~ PR4
To form That is, when the central pixel CP3 of the eight neighboring window W3 has the color number # 0 or # 1 and at least one of the eight peripheral pixels has the color number # 3, the pixel is regarded as a pixel in the peripheral area. As a result, peripheral regions PR1 to PR4 are obtained. Since the peripheral regions PR1 to PR4 formed using the eight neighboring windows are connected to each other, these peripheral regions PR1 to PR4 are connected to each other.
By detecting the number of color changes in No. 4, the number of color changes N around the additional region SRa can be obtained. Note that, similarly to the example of FIG.
New color numbers may be assigned to 1 to PR4.

【0060】(2)上記実施例では、線画がランレング
スデータで表わされるものとしたが、線画をビットマッ
プデータで表わすようにしてもよい。なお、ランレング
スデータを用いる場合に、太らせ処理や細らせ処理をラ
ンレングスデータのままで実行することも可能である
が、ランレングスデータをビットマップデータに変換し
た後に太らせ処理や細らせ処理を行なうようにしてもよ
い。
(2) In the above embodiment, the line drawing is represented by the run-length data. However, the line drawing may be represented by bitmap data. Note that when run-length data is used, it is possible to execute the fattening process or the thinning process as it is with the run-length data. However, after the run-length data is converted into bitmap data, the fattening process or the thinning process is performed. You may make it perform a convergence process.

【0061】(3)上記実施例では、変形幅Wtを、線
切れ部として検出したいギャップの最大幅の約1/2の
値であるとしたが、変形幅Wtの値は次のような事項を
考慮して決定することが好ましい。図13は、線幅t1
とギャップt2との関係に応じて付加領域の形状が異な
ることを示す説明図である。図13(A)は、線幅t1
がギャップt2よりも大きな場合について、図5のステ
ップS41とステップS42の太らせ処理を実行した結
果を示しており、図13(B)は線幅t1がギャップt
2よりも小さな場合について太らせ処理と細らせ処理を
実行した結果を示している。t1>t2の場合(図13
(A))には色番号#1に関する太らせ処理によって形
成された付加領域SRの一部SRRが、色番号#0に関
する太らせ処理の後にも残存しているのに対して、t1
<t2の場合(図13(B))には色番号#1に関する
太らせ処理によって形成された付加領域SRのすべて
が、色番号#0の太らせ処理によって消滅している。こ
れは次のような理由による。付加領域SRの幅の最小値
は、線のギャップ部における幅Wgで与えられ、この幅
Wgの値は図13(A),(B)のどちらの場合にも線
幅t1にほぼ等しい。従って、図13(A)のように幅
Wg=t1よりも小さな変形幅Wtで色番号#0の太ら
せ処理を行なった場合には、付加領域SRの一部SRR
が残るのに対して、図13(B)のように幅Wg=t1
よりも大きな変形幅Wtで色番号#0の太らせ処理を行
なった場合には付加領域SRが消滅してしまうからであ
る。
(3) In the above embodiment, the deformation width Wt is assumed to be a value of about 1/2 of the maximum width of the gap to be detected as a line break, but the value of the deformation width Wt is as follows. It is preferable to determine in consideration of the following. FIG. 13 shows the line width t1.
FIG. 9 is an explanatory diagram showing that the shape of an additional region differs according to the relationship between the additional region and the gap t2. FIG. 13A shows the line width t1.
13 is larger than the gap t2, and shows the result of executing the thickening process in step S41 and step S42 in FIG. 5, and FIG.
The result of executing the fattening process and the thinning process for a case smaller than 2 is shown. When t1> t2 (FIG. 13
In (A)), a part SRR of the additional region SR formed by the thickening process for the color number # 1 remains after the thickening process for the color number # 0, whereas the tR1
In the case of <t2 (FIG. 13B), all the additional regions SR formed by the thickening process for the color number # 1 have disappeared by the thickening process for the color number # 0. This is for the following reasons. The minimum value of the width of the additional region SR is given by the width Wg in the gap portion of the line, and the value of the width Wg is substantially equal to the line width t1 in both cases of FIGS. Therefore, when the thickening process of the color number # 0 is performed with the deformation width Wt smaller than the width Wg = t1 as shown in FIG.
, The width Wg = t1 as shown in FIG.
This is because if the thickening process of the color number # 0 is performed with a larger deformation width Wt, the additional region SR disappears.

【0062】図13に示されるように、線幅t1よりも
大きなギャップを有する線切れ部は自動検出することが
困難であるが、通常はほとんどの場合、目視で検出でき
るので、当初のステップS3で処理が可能である。一
方、線幅t1と同等以下のギャップを有する線切れ部を
検出するためには、変形幅Wtを線幅t1の約1/2以
下の値に設定すればよいことが解る。特に変形幅Wtを
線幅t1の約1/2に設定すれば、線幅t1以下のギャ
ップを有する線切れ部をほとんどすべて検出し、接続す
ることが可能になる。
As shown in FIG. 13, it is difficult to automatically detect a line break having a gap larger than the line width t1, but usually it can be detected visually in most cases. Can be processed. On the other hand, in order to detect a broken portion having a gap equal to or less than the line width t1, it is understood that the deformation width Wt may be set to a value of about 以下 or less of the line width t1. In particular, if the deformation width Wt is set to about の of the line width t1, it is possible to detect and connect almost all line breaks having gaps equal to or smaller than the line width t1.

【0063】[0063]

【発明の効果】以上説明したように、請求項1に記載し
た発明によれば、2回の太らせ処理によって形成された
付加領域のうちで周囲における色の変化数が4以上のも
のを線切れ候補領域として検出するので、ギャップの方
向に係わらずに線切れ候補領域を容易に検出することが
できるという効果がある。
As described above, according to the first aspect of the present invention, among the additional areas formed by the two fattening processes, those having a surrounding color change number of 4 or more are lined. Since it is detected as a break candidate region, there is an effect that a line break candidate region can be easily detected regardless of the direction of the gap.

【0064】また、請求項2に記載した発明によれば、
線切れ部を容易に接続できるという効果がある。
According to the second aspect of the present invention,
There is an effect that the wire break can be easily connected.

【図面の簡単な説明】[Brief description of the drawings]

【図1】この発明の一実施例を適用して線画データの処
理を行なう線画処理装置20の構成を示すブロック図。
FIG. 1 is a block diagram showing a configuration of a line drawing processing device 20 that processes line drawing data by applying an embodiment of the present invention.

【図2】線画処理の手順を示すフローチャート。FIG. 2 is a flowchart illustrating a procedure of a line drawing process.

【図3】実施例において処理の対象となる線画を示す平
面図。
FIG. 3 is a plan view showing a line drawing to be processed in the embodiment.

【図4】線画データの構造を示す概念図。FIG. 4 is a conceptual diagram showing the structure of line drawing data.

【図5】線切れ候補領域の検出処理の詳細手順を示すフ
ローチャート。
FIG. 5 is a flowchart showing a detailed procedure of a line break candidate area detection process.

【図6】線切れ候補領域の検出処理の内容を示す説明
図。
FIG. 6 is an explanatory diagram showing the details of a line break candidate area detection process.

【図7】ステップS44の処理の詳細を示すフローチャ
ート。
FIG. 7 is a flowchart showing details of the process in step S44.

【図8】ステップS44の処理内容を示す説明図。FIG. 8 is an explanatory diagram showing the processing content of step S44.

【図9】色変化数Nに応じた処理内容を示す説明図。FIG. 9 is an explanatory diagram showing processing contents according to the number N of color changes.

【図10】候補領域表示座標と候補領域処理座標の一例
を示す説明図。
FIG. 10 is an explanatory diagram showing an example of candidate area display coordinates and candidate area processing coordinates.

【図11】線切れ候補領域の補修処理の手順を示すフロ
ーチャート。
FIG. 11 is a flowchart showing the procedure of a repair process for a line break candidate area.

【図12】付加領域の周囲における色変化数を求める他
の方法を示す説明図。
FIG. 12 is an explanatory diagram showing another method for obtaining the number of color changes around an additional area.

【図13】線幅とギャップとの関係に応じた付加領域の
形状を示す説明図。
FIG. 13 is an explanatory diagram showing a shape of an additional area according to a relationship between a line width and a gap.

【符号の説明】[Explanation of symbols]

20…線画処理装置 22…CPU 24…バス 26…ROM 28…RAM 32…線画メモリ 34…キーボード用I/Oインタフェイス 36…キーボード 38…マウス 42…表示制御部 44…CRT 44…カラーCRT 46…画像データ入出力用インタフェイス 50…記録スキャナ 60…平面スキャナ SL…走査線 SR…付加領域 Wt…変形幅 Reference Signs List 20 line drawing processing device 22 CPU 24 bus 26 ROM 28 RAM 32 line drawing memory 34 keyboard I / O interface 36 keyboard 38 mouse 42 display control unit 44 CRT 44 color CRT 46 Image data input / output interface 50: recording scanner 60: flat scanner SL: scanning line SR: additional area Wt: deformation width

───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 昭62−208178(JP,A) 特開 平1−119874(JP,A) 特開 平4−239387(JP,A) (58)調査した分野(Int.Cl.6,DB名) G06T 5/00 - 5/50 G06T 7/00 G03F 1/00 H04N 1/40 - 1/409──────────────────────────────────────────────────続 き Continuation of the front page (56) References JP-A-62-208178 (JP, A) JP-A-1-119874 (JP, A) JP-A-4-239387 (JP, A) (58) Field (Int.Cl. 6 , DB name) G06T 5/00-5/50 G06T 7/00 G03F 1/00 H04N 1/40-1/409

Claims (2)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 第1の色の背景の上に第2の色の線が描
かれた第1の線画を表わす線画データを処理することに
より、前記線画の線切れ部を処理する方法であって、
(A)前記第1の線画内において前記第2の色の画像領
域を所定の幅で太らせることによって前記画像領域の周
囲に付加領域を形成し、これによって第2の線画を生成
する工程と、(B)前記第2の線画に含まれる前記第1
の色の画像領域を前記所定の幅で太らせることによって
第3の線画を生成する工程と、(C)前記第3の線画に
残存している前記付加領域の周囲における色の変化の数
を調べる工程と、(D)前記色の変化数が4以上である
場合には前記付加領域を線切れ候補領域として検出する
工程と、を備える線切れ部処理方法。
1. A method of processing a line cut portion of a line drawing by processing line drawing data representing a first line drawing in which a line of a second color is drawn on a background of a first color. hand,
(A) forming an additional region around the image region by thickening the image region of the second color by a predetermined width in the first line drawing, thereby generating a second line drawing; (B) the first line drawing included in the second line drawing;
(C) generating a third line drawing by thickening the image region of the color of the third line drawing by the predetermined width; and (C) determining the number of color changes around the additional region remaining in the third line drawing. A line break processing method comprising: a checking step; and (D) detecting the additional area as a line break candidate area when the number of color changes is four or more.
【請求項2】 請求項1記載の線切れ部処理方法であっ
て、さらに、(E)線切れ候補領域を前記第2の色で塗
りつぶすことによって、前記第1の線画内に存在する線
切れ部を接続する工程、を備える線切れ部処理方法。
2. The line break processing method according to claim 1, further comprising: (E) filling the line break candidate area with the second color, thereby forming a line break existing in the first line drawing. And a step of connecting the parts.
JP31452793A 1993-11-18 1993-11-18 Line break processing method Expired - Fee Related JP2852859B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP31452793A JP2852859B2 (en) 1993-11-18 1993-11-18 Line break processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP31452793A JP2852859B2 (en) 1993-11-18 1993-11-18 Line break processing method

Publications (2)

Publication Number Publication Date
JPH07141502A JPH07141502A (en) 1995-06-02
JP2852859B2 true JP2852859B2 (en) 1999-02-03

Family

ID=18054368

Family Applications (1)

Application Number Title Priority Date Filing Date
JP31452793A Expired - Fee Related JP2852859B2 (en) 1993-11-18 1993-11-18 Line break processing method

Country Status (1)

Country Link
JP (1) JP2852859B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10271497A (en) 1997-03-24 1998-10-09 Minolta Co Ltd Image processor

Also Published As

Publication number Publication date
JPH07141502A (en) 1995-06-02

Similar Documents

Publication Publication Date Title
CA1235535A (en) Method of providing raster information for a graphics display
JP3773642B2 (en) Image processing apparatus and image forming apparatus
JPH05242246A (en) Method and device for extracting outline of picture
JPH04192671A (en) Pin hole delete method
JP3142550B2 (en) Graphic processing unit
JPH07184040A (en) Detection device of region encircled by marker by means of singe optical path scanning for photograph copying machine and its method
US20020060693A1 (en) Image processor
JP2639517B2 (en) Image area color processing method
JP2852859B2 (en) Line break processing method
JP3285930B2 (en) Image processing device
JP2901856B2 (en) White plate figure correction method
JPH04328956A (en) Picture data read method
JP2000022943A (en) Device and method for discriminating image area, and recording medium recorded with image area discriminating program
JP2875454B2 (en) Image and line drawing boundary image correction method
JP3063506B2 (en) Raster data processing device
JP3029762B2 (en) Pinhole treatment method
JPH08321942A (en) Image processing apparatus and image joining method for divided drawings
JP3350324B2 (en) Character output device
JPH0554151B2 (en)
JPH05233807A (en) Labeling processing apparatus and labeling processing method
JPH0676035A (en) Image data processing system
JP3990743B2 (en) Printer control method and printer control apparatus
JP2957050B2 (en) Image data enlarger
JPS5922764A (en) Method for correcting enlarged character
JP2882056B2 (en) How to identify specific patterns

Legal Events

Date Code Title Description
R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees