JP3354629B2 - Image processing device - Google Patents

Image processing device

Info

Publication number
JP3354629B2
JP3354629B2 JP14872393A JP14872393A JP3354629B2 JP 3354629 B2 JP3354629 B2 JP 3354629B2 JP 14872393 A JP14872393 A JP 14872393A JP 14872393 A JP14872393 A JP 14872393A JP 3354629 B2 JP3354629 B2 JP 3354629B2
Authority
JP
Japan
Prior art keywords
contour
area
data
area data
image 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
JP14872393A
Other languages
Japanese (ja)
Other versions
JPH06333038A (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.)
Ricoh Co Ltd
Original Assignee
Ricoh 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 Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to JP14872393A priority Critical patent/JP3354629B2/en
Publication of JPH06333038A publication Critical patent/JPH06333038A/en
Application granted granted Critical
Publication of JP3354629B2 publication Critical patent/JP3354629B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

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

【0001】[0001]

【産業上の利用分野】本発明は,プリンタ,デジタル複
写機等に使用される画像処理装置に関し,より詳細に
は,入力された対象画像データの指定された領域に任意
の画像処理(エリア処理)を施して外部に出力する画像
処理装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an image processing apparatus used for a printer, a digital copier, and the like, and more particularly, to an arbitrary image processing (area processing) in a designated area of input target image data. ) And outputs to the outside.

【0002】[0002]

【従来の技術】デジタル複写機等の画像処理装置では,
通常のコピー時には読み取り原稿全体に対して画像処理
が均一に行われるが,例えば,絵柄や,文字や写真が混
在した原稿に対する画像処理や,特殊効果を得るための
画像処理では,読み取り原稿の特定の領域に対して他の
領域と異なる画像処理が行われる。このような場合に
は,画像処理装置において処理対象となる閉領域(エリ
ア)が指定されると共に,画像処理内容(エリアデー
タ)が指定され,前記閉領域内の画像に対して指定内容
の画像処理(エリア処理)が行われる。
2. Description of the Related Art In an image processing apparatus such as a digital copying machine,
In normal copying, image processing is performed uniformly on the entire scanned document. For example, in image processing on a document with a mixture of patterns, characters, and photographs, and image processing for obtaining special effects, it is necessary to specify the scanned document. Image processing different from the other areas is performed on the area. In such a case, the closed area (area) to be processed is specified in the image processing apparatus, the image processing content (area data) is specified, and the image of the specified content is compared with the image in the closed area. Processing (area processing) is performed.

【0003】このような画像処理装置として,例えば,
特開昭59−45765号公報に開示されている「画像
処理装置」がある。この装置は,ビットマップメモリに
あらかじめ処理のオン/オフに対応する切り換え情報を
記憶しておき,画像処理中にあってはラスター走査の信
号にしたがってビットマップメモリ内のデータを順に読
み出して処理のオン/オフ制御に供する構成としたもの
である。
As such an image processing apparatus, for example,
There is an "image processing apparatus" disclosed in JP-A-59-45765. In this apparatus, switching information corresponding to ON / OFF of processing is stored in a bit map memory in advance, and during image processing, data in the bit map memory is sequentially read out according to a raster scanning signal to perform processing. It is configured to be used for on / off control.

【0004】ところが,ビットマップメモリに記憶され
るデータが画像処理のオン/オフ制御に直結しているた
め,制御を行う画像処理の種類が増加するに伴ってビッ
トマップメモリを深さ方向に増設する必要があり,大容
量のメモリが必要となるという欠点がある。従って,実
質的には複数種の画像処理の切換制御を行うことができ
ないという不都合があった。
However, since the data stored in the bitmap memory is directly linked to the on / off control of the image processing, the bitmap memory is increased in the depth direction as the type of image processing to be controlled increases. And there is a disadvantage that a large capacity memory is required. Therefore, there is an inconvenience that switching control of a plurality of types of image processing cannot be performed substantially.

【0005】このため,これを解決するものとして,対
象画像データに対するエリア処理の内容を,主走査方向
に対して所定の長さを有したエリアデータとして記憶す
るビットマップメモリを備え,1ライン中において同種
エリアデータで挟まれる部分に対して,該エリアデータ
の種類に応じたエリア処理を施す画像処理装置が提案さ
れている。この装置によれば,特に大容量のメモリを必
要とせず,矩形あるいは非矩形の領域に対して複数種類
のエリア処理の切換制御を行うことができる。
To solve this problem, a bit map memory for storing the contents of the area processing for the target image data as area data having a predetermined length in the main scanning direction is provided. Has proposed an image processing apparatus that performs an area process according to the type of the area data on a portion sandwiched between the same type of area data. According to this device, switching control of a plurality of types of area processing can be performed for a rectangular or non-rectangular area without particularly requiring a large-capacity memory.

【0006】[0006]

【発明が解決しようとする課題】しかしながら,上記従
来の技術によれば,エリアデータが主走査方向に対して
所定の長さを有しているため,エリアの交点や頂点,お
よびエリアどうしの近接部において,エリアデータをビ
ットマップメモリに書き込む際に,新たに書き込むエリ
アデータが既にビットマップ上に書き込まれている既存
のエリアデータと重なってしまい,新たに書き込むエリ
アデータによって既存のエリアデータが上書きされて消
えてしまうという問題点があった。換言すれば,既存の
エリアデータで指定された内容のエリア処理を行うこと
ができない恐れがあるという問題点があった。
However, according to the above-mentioned prior art, since the area data has a predetermined length in the main scanning direction, the intersections and vertices of the areas and the proximity of the areas are not considered. When writing area data to the bitmap memory, the area data to be newly written overlaps with the existing area data already written on the bitmap, and the area data to be newly written overwrites the existing area data. There was a problem that it disappeared. In other words, there is a problem that the area processing of the content specified by the existing area data may not be performed.

【0007】また,ビットマップメモリ上の1ラインの
主走査方向において,出現するエリアデータの順序でエ
リア処理を実行するため,複数のエリアデータによって
複数のエリアが指定された際に,指定された複数のエリ
アにおいて重複する領域がある場合には,必ずしも所望
のエリア処理を施した出力を得ることができない恐れが
あるという問題点があった。
Also, in order to execute area processing in the order of appearing area data in the main scanning direction of one line on the bit map memory, when a plurality of areas are specified by a plurality of area data, the area processing is performed. When there is an overlapping area in a plurality of areas, there is a problem that an output subjected to a desired area processing may not always be obtained.

【0008】また,上記従来の技術によれば,指定され
たエリアに対して複数種類のエリア処理を行うことがで
きるものの,エリアを矩形あるいは非矩形の領域として
指定する構成であるため,原稿画像の任意の閉ループ内
のみに対して選択的にエリア処理を施すことができず,
使い勝手が悪いという問題点があった。
Further, according to the above-mentioned conventional technique, although a plurality of types of area processing can be performed on a designated area, the area is designated as a rectangular or non-rectangular area. Area processing cannot be selectively performed only within an arbitrary closed loop of
There was a problem that the usability was poor.

【0009】本発明は上記に鑑みてなされたものであっ
て,エリアの交点や頂点,およびエリアどうしの近接部
においても,確実に指定されたエリア処理を実行できる
ことを第1の目的とする。
The present invention has been made in view of the above, and it is a first object of the present invention to be able to surely execute designated area processing even at intersections and vertices of areas and near areas between areas.

【0010】また,本発明は上記に鑑みてなされたもの
であって,複数のエリアが指定された場合に,後に指定
されたエリアが優先されて処理された画像出力を得るこ
とを第2の目的とする。
Further, the present invention has been made in view of the above, and in a case where a plurality of areas are designated, a second designated area is given priority to obtain a processed image output. Aim.

【0011】また,本発明は上記に鑑みてなされたもの
であって,予めエリア処理前に読み込んだ画像データか
ら輪郭線情報を取得することにより,その輪郭内部(閉
ループ)に対して任意のエリア処理を施せるようにする
ことを第3の目的とする。
Further, the present invention has been made in view of the above, and by acquiring contour line information from image data read in advance before area processing, an arbitrary area can be defined within the contour (closed loop). A third object is to enable processing.

【0012】[0012]

【課題を解決するための手段】本発明は上記の目的を達
成するために,対象画像データに対するエリア処理の内
容を,主走査方向に対して所定の長さを有したエリアデ
ータとして記憶するビットマップメモリを備え,1ライ
ン中において同種エリアデータで挟まれる部分に対し
て,該エリアデータの種類に応じたエリア処理を施す画
像処理装置において,前記エリアデータをビットマップ
メモリに書き込む際に,新たに書き込むエリアデータが
既にビットマップ上に書き込まれている既存のエリアデ
ータと重なるか否かを判定する判定手段と,前記判定手
段で既存のエリアデータと重なると判定された場合,既
存のエリアデータの位置に基づいて,新たに書き込むエ
リアデータの位置を主走査方向に補正する書込位置補正
手段とを備えた画像処理装置を提供するものである。
In order to achieve the above object, the present invention provides a bit for storing the contents of area processing for target image data as area data having a predetermined length in the main scanning direction. An image processing apparatus having a map memory and performing an area process according to the type of the area data on a portion sandwiched between the same type of area data in one line. Determining means for determining whether or not the area data to be written in the area data overlaps with the existing area data already written on the bit map; and when the determining means determines that the area data overlaps with the existing area data, A writing position correcting means for correcting the position of newly written area data in the main scanning direction based on the position of There is provided a management device.

【0013】また,前述した構成に加えて,複数のエリ
アデータによって複数のエリアが指定された際に,指定
された複数のエリアにおいて重複する領域がある場合,
あらかじめエリアデータ毎に設定された優先順位に基づ
いて,重複した領域に対するエリア処理として最も優先
順位の高いエリアデータを選択するエリアデータ選択手
段を備えた画像処理装置を提供するものである。
In addition to the above-described structure, when a plurality of areas are designated by a plurality of area data, if there is an overlapping area in the designated plurality of areas,
An object of the present invention is to provide an image processing apparatus provided with area data selecting means for selecting area data having the highest priority as area processing for an overlapped area based on priorities set in advance for each area data.

【0014】また,対象画像データに対するエリア処理
の内容を,主走査方向に対して所定の長さを有したエリ
アデータとして記憶するビットマップメモリを備え,1
ライン中において同種エリアデータで挟まれる部分に対
して,該エリアデータの種類に応じたエリア処理を施す
画像処理装置において,対象画像の2値化データを前記
ビットマップメモリに取り込んで,ビットマップメモリ
上の2値化データに対して輪郭追跡処理を施し,輪郭線
情報を抽出する輪郭線抽出手段と,前記輪郭線抽出手段
で抽出した輪郭線情報を記憶する輪郭線記憶手段と,前
記輪郭線抽出手段による輪郭線情報の抽出の終了後,前
記ビットマップメモリをクリアし,前記輪郭線記憶手段
に記憶されている輪郭線情報に基づいて,エリアデータ
をビットマップメモリに書き込むエリアデータ書込手段
とを備えた画像処理装置を提供するものである。
A bit map memory for storing the contents of the area processing for the target image data as area data having a predetermined length in the main scanning direction;
In an image processing apparatus for performing an area process according to the type of area data on a portion sandwiched between the same type of area data in a line, binarized data of a target image is fetched into the bitmap memory, and Contour extracting means for performing contour tracing processing on the binarized data and extracting contour information; contour storing means for storing contour information extracted by the contour extracting means; After the extraction of the outline information by the extraction means, the bitmap memory is cleared and area data writing means for writing area data to the bitmap memory based on the outline information stored in the outline storage means. And an image processing apparatus having the same.

【0015】また,前述した構成に加えて,2値化デー
タに太らせ処理を施す画像太らせ処理手段を備え,前記
ビットマップメモリに取り込む対象画像の2値化データ
が,太らせ処理後の画像データとするものである。
In addition to the above-described configuration, the image processing apparatus further includes image thickening processing means for performing thickening processing on the binarized data, and the binarized data of the target image to be taken into the bitmap memory is processed after the thickening processing. It is assumed to be image data.

【0016】また,前記輪郭線抽出手段は,前記ビット
マップメモリ上の2値化データから輪郭線情報を抽出す
る際に,輪郭線が途中で途切れている場合,輪郭線が途
切れた位置より,所定方向・所定範囲のビットマップメ
モリ上に存在する画像を検出し,検出位置より輪郭追跡
処理を継続するものである。
When extracting the contour information from the binarized data in the bitmap memory, the contour extracting means determines the position of the contour from the position where the contour is broken. An image existing in the bitmap memory in a predetermined direction and a predetermined range is detected, and the contour tracing process is continued from the detected position.

【0017】また,前記輪郭線抽出手段は,前記ビット
マップメモリ上の2値化データから輪郭線情報を抽出す
る際に,輪郭線の輪郭長を検出して,所定のしきい値と
比較し,前記輪郭長がしきい値より小さい場合には,検
出した輪郭線情報を破棄し,あらたに別の輪郭線を検出
して輪郭線情報の抽出を行うものである。
When extracting the contour information from the binary data in the bitmap memory, the contour extracting means detects the contour length of the contour and compares it with a predetermined threshold value. If the contour length is smaller than the threshold value, the detected contour information is discarded, another contour is newly detected, and the contour information is extracted.

【0018】また,前記輪郭線抽出手段は,前記ビット
マップメモリ上の2値化データから輪郭線情報を抽出す
る際に,追跡している輪郭線が内輪郭・外輪郭の何れで
あるかを検出し,外輪郭である場合には,検出した輪郭
線情報を破棄し,あらたに別の輪郭線を検出して輪郭線
情報の抽出を行うものである。
When extracting the contour information from the binary data in the bitmap memory, the contour extracting means determines whether the contour being tracked is an inner contour or an outer contour. If the detected contour is an outer contour, the detected contour information is discarded, another contour is newly detected, and the contour information is extracted.

【0019】また,前記エリアデータ書込手段は,エリ
アデータをビットマップメモリに書き込む際に,書き込
み位置が輪郭線上になるように補正するものである。
Further, the area data writing means corrects the writing position so as to be on the contour line when writing the area data to the bit map memory.

【0020】[0020]

【作用】本発明の画像処理装置(請求項1)は,エリア
データをビットマップメモリに書き込む際に,新たに書
き込むエリアデータが既にビットマップ上に書き込まれ
ている既存のエリアデータと重なるか否かを判定し,既
存のエリアデータと重なる場合には,既存のエリアデー
タの位置に基づいて,新たに書き込むエリアデータの位
置を主走査方向に補正することにより,既存のエリアデ
ータを失うことなく,確実にビットマップメモリに記憶
させる。
According to the first aspect of the present invention, when writing area data to a bitmap memory, it is determined whether or not area data to be newly written overlaps existing area data already written on a bitmap. And if it overlaps with the existing area data, the position of the newly written area data is corrected in the main scanning direction based on the position of the existing area data, so that the existing area data is not lost. , And surely store it in the bitmap memory.

【0021】また,本発明の画像処理装置(請求項2)
は,複数のエリアデータによって複数のエリアが指定さ
れた際に,指定された複数のエリアにおいて重複する領
域がある場合,あらかじめエリアデータ毎に設定された
優先順位に基づいて,重複した領域に対するエリア処理
として最も優先順位の高いエリアデータを選択すること
により,所望のエリア処理を実現する。
Further, an image processing apparatus according to the present invention (claim 2)
When multiple areas are specified by multiple area data, if there are overlapping areas in the specified areas, the area for the overlapping area is determined based on the priority set in advance for each area data. A desired area process is realized by selecting the area data having the highest priority as the process.

【0022】また,本発明の画像処理装置(請求項3)
は,対象画像の2値化データをビットマップメモリに取
り込んで,ビットマップメモリ上の2値化データに対し
て輪郭追跡処理を施し,輪郭線情報を抽出して所定のメ
モリに記憶する。その後,ビットマップメモリをクリア
し,記憶されている輪郭線情報に基づいて,エリアデー
タをビットマップメモリに書き込むことにより,輪郭線
情報の内部(閉ループ内)をエリアとして取得する。
Further, the image processing apparatus of the present invention (claim 3)
Captures the binarized data of the target image into a bitmap memory, performs contour tracing processing on the binarized data on the bitmap memory, extracts contour line information, and stores it in a predetermined memory. Thereafter, the bitmap memory is cleared, and area data is written into the bitmap memory based on the stored contour information, thereby acquiring the inside of the contour information (within a closed loop) as an area.

【0023】また,本発明の画像処理装置(請求項4)
は,ビットマップメモリに取り込む対象画像の2値化デ
ータに太らせ処理を施すことにより,正しく輪郭線情報
を取得する。
Further, the image processing apparatus of the present invention (claim 4)
Obtains correct outline information by subjecting the binarized data of the target image to be taken into the bitmap memory to a fattening process.

【0024】また,本発明の画像処理装置(請求項5)
は,ビットマップメモリ上の2値化データから輪郭線情
報を抽出する際に,輪郭線が途中で途切れている場合,
輪郭線が途切れた位置より,所定方向・所定範囲のビッ
トマップメモリ上に存在する画像を検出し,検出位置よ
り輪郭追跡処理を継続することにより,正しく輪郭線情
報を取得する。
Further, the image processing apparatus of the present invention (claim 5)
When extracting contour information from the binary data in the bitmap memory, if the contour is interrupted in the middle,
An image existing in the bitmap memory in a predetermined direction and a predetermined range is detected from the position where the outline is interrupted, and the outline tracking processing is continued from the detected position to correctly obtain outline information.

【0025】また,本発明の画像処理装置(請求項6)
は,ビットマップメモリ上の2値化データから輪郭線情
報を抽出する際に,輪郭線の輪郭長を検出して,所定の
しきい値と比較し,輪郭長がしきい値より小さい場合に
は,検出した輪郭線情報を破棄し,あらたに別の輪郭線
を検出して輪郭線情報の抽出を行うことにより,2値化
データ中の孤立点を判別して,正しく輪郭線情報を取得
する。
Further, an image processing apparatus according to the present invention (claim 6)
Is used to detect the contour length of the contour when extracting the contour information from the binarized data in the bitmap memory, compare the contour length with a predetermined threshold value, and determine if the contour length is smaller than the threshold value. Is to discriminate the isolated points in the binarized data and obtain correct contour information by discarding the detected contour information, extracting another contour line and extracting the contour information. I do.

【0026】また,本発明の画像処理装置(請求項7)
は,ビットマップメモリ上の2値化データから輪郭線情
報を抽出する際に,追跡している輪郭線が内輪郭・外輪
郭の何れであるかを検出し,外輪郭である場合には,検
出した輪郭線情報を破棄し,あらたに別の輪郭線を検出
して輪郭線情報の抽出を行うことにより,所望の閉ルー
プ(輪郭線情報)を正しく取得する。
An image processing apparatus according to the present invention (claim 7)
Detects edge information from the binary data in the bitmap memory, detects whether the tracked edge is an inner edge or an outer edge. The desired closed loop (contour information) is correctly obtained by discarding the detected contour information, detecting another contour and extracting the contour information.

【0027】また,本発明の画像処理装置(請求項8)
は,エリアデータをビットマップメモリに書き込む際
に,書き込み位置が輪郭線上になるように補正すること
により,輪郭線付近においても適切にエリアを習得す
る。
An image processing apparatus according to the present invention (claim 8)
When writing the area data to the bitmap memory, the area is properly learned even near the contour by correcting the writing position to be on the contour.

【0028】[0028]

【実施例】以下,本発明の画像処理装置をデジタル複写
機に適用した場合を実施例として図面を参照して詳細に
説明する。
BRIEF DESCRIPTION OF THE DRAWINGS FIG. 1 is a block diagram of a digital copying machine according to an embodiment of the present invention;

【0029】図1は,本実施例の画像処理装置を適用し
たデジタル複写機のブロック構成図を示し,原稿を読み
取ってラスタースキャン型の画像データを出力する画像
読取部101と,エリア処理を含む各種画像処理を施す
本実施例の画像処理装置としての画像処理部102と,
画像処理後の画像データを記録紙に出力する画像記録部
103と,エリア処理におけるエリア指定用の座標を入
力するためのディジタイザ104と,上記各部を制御す
るシステム制御部105とから構成される。
FIG. 1 is a block diagram of a digital copying machine to which the image processing apparatus of the present embodiment is applied. The digital copying machine includes an image reading unit 101 that reads a document and outputs raster scan type image data, and includes area processing. An image processing unit 102 as an image processing apparatus of the present embodiment for performing various image processing;
It comprises an image recording unit 103 for outputting image data after image processing to recording paper, a digitizer 104 for inputting coordinates for area designation in area processing, and a system control unit 105 for controlling the above-mentioned units.

【0030】図2は,画像処理部102の構成を示し,
画像読取部101から入力した画像データに空間フィル
タ処理を施すフィルタ処理部201と,フィルタ処理部
201から入力した画像データに対して,影付け,中抜
き(輪郭抽出),ネガポジ反転の順で加工処理を施す加
工処理部202と,加工処理部202から入力した画像
データに対して濃度調整,ディザ,イレースの順で処理
を施す中間調処理部203と,画像読取部101から解
像度400dpiの2値化データ(画像データ)を入力
し,100dpiの2値化データに変換する400/1
00変換部204と,画像データに対するエリア処理の
内容を,主走査方向に対して所定の長さ(本実施例で
は,4ビット)を有したエリアデータとして記憶するビ
ットマップメモリ205と,ビットマップメモリ205
に対するエリアデータの書き込み制御およびエリアデー
タに基づくエリア処理の制御を行うエリア処理制御部2
06と,後述する閉ループモードにおいて,輪郭追跡処
理で抽出した輪郭線情報を記憶する輪郭線記憶手段とし
てもRAM207とを備えている。
FIG. 2 shows the configuration of the image processing unit 102.
A filter processing unit 201 for performing a spatial filter process on the image data input from the image reading unit 101; and processing of the image data input from the filter processing unit 201 in the order of shadowing, hollowing (outline extraction), and negative / positive inversion. A processing unit 202 that performs processing; a halftone processing unit 203 that performs processing on image data input from the processing unit 202 in the order of density adjustment, dithering, and erasing; 400/1 which inputs the digitized data (image data) and converts it into binary data of 100 dpi
A bit map memory 205 for storing the contents of area processing for image data as area data having a predetermined length (4 bits in this embodiment) in the main scanning direction; Memory 205
Processing control unit 2 for controlling writing of area data to the area and controlling area processing based on the area data
06, and also a RAM 207 as contour storage means for storing contour information extracted by contour tracking processing in a closed loop mode described later.

【0031】図3は,エリア処理に使用するエリアデー
タのデータ構造を示す。本実施例では,エリアデータを
4ビットで構成し,先頭1ビットが「1」でエリアデー
タの開始を示し,後の3ビットで8種類のエリア番号を
指定可能としている。このエリア番号はエリアの指定順
序を示す。
FIG. 3 shows the data structure of area data used for area processing. In the present embodiment, the area data is composed of 4 bits, the first one bit is "1" to indicate the start of the area data, and the last three bits can specify eight types of area numbers. This area number indicates an area designation order.

【0032】従って,ビットマップメモリ205のエリ
ア処理を開始するビットの座標に,エリアデータの先頭
ビットの座標を一致させて,先頭ビットを含めむ4ビッ
トを用いてエリアデータを書き込むことになる。また,
エリアデータが4ビットの長さを有しているため,先頭
ビットの書き込み位置(座標)から前後3ビットの範囲
に既存のエリアデータの先頭ビットが存在する場合に
は,エリアデータの書き込み位置が重複することにな
る。
Accordingly, the coordinates of the first bit of the area data are made to coincide with the coordinates of the bit for starting the area processing in the bitmap memory 205, and the area data is written using 4 bits including the first bit. Also,
Since the area data has a length of 4 bits, if the first bit of the existing area data exists within a range of 3 bits before and after the write position (coordinate) of the first bit, the write position of the area data is Will overlap.

【0033】図4は,エリア処理の対象となるエリア
(領域)を指定する方法を示し,図示の如く,矩形モー
ド,直角多角形モード,多角形モード,閉ループモード
の4つのモードで指定することが可能である。矩形モー
ドは,同図(a)に示すように,2点(,)の指定
順序は任意で,指定された2点の対角線上の矩形をエリ
アとして入力するものである。また,直角多角形モード
は,同図(b)に示すように,始点()の位置,指定
の回転方向が任意で,指定された順序(〜)で各点
を直角の頂点とする多角形をエリアとして入力するもの
である。また,多角形モードは,同図(c)に示すよう
に,始点()の位置,指定の回転方向が任意で,指定
された順序(〜)で各点を直線で結んだ多角形をエ
リアとして入力するものである。ここで,各点の入力は
ディジタイザ104を介して行われる。なお,〜の
点をエリア指定点を呼ぶ。
FIG. 4 shows a method of designating an area (area) to be subjected to area processing. As shown in the figure, designation is made in four modes of a rectangular mode, a right polygon mode, a polygon mode, and a closed loop mode. Is possible. In the rectangular mode, as shown in FIG. 11A, the order of specifying two points (,) is arbitrary, and a rectangle on the diagonal line of the two specified points is input as an area. In the right-angled polygon mode, as shown in FIG. 4B, the position of the starting point () and the specified rotation direction are arbitrary, and each point is a right-angled vertex in the specified order (-). Is input as an area. In the polygon mode, the position of the starting point () and the specified rotation direction are arbitrary, and a polygon connecting each point with a straight line in the specified order (~) as shown in FIG. Is entered. Here, the input of each point is performed via the digitizer 104. Note that the points (1) to (4) are called area designation points.

【0034】また,閉ループモードは,同図(d)に示
すように,原稿上の閉ループ内の一点(図中の×)をデ
ィジタイザ104を介して指定した後,プレスキャンに
よって原稿画像を2値化データとして入力し,さらに輪
郭線を抽出することにより,閉ループを認識し,閉ルー
プ内をエリアとして入力するものである。
In the closed loop mode, as shown in FIG. 3D, after a point (x in the figure) in the closed loop on the document is designated via the digitizer 104, the document image is binary-coded by pre-scanning. A closed loop is recognized by inputting the data as coded data and further extracting a contour line, and the inside of the closed loop is input as an area.

【0035】以上の構成において, (1)矩形モード,直角多角形モード,多角形モードの
エリア入力 (2)エリアデータの出力 (3)閉ループモードのエリア入力 (3−1)開始ポイント検出処理 (3−2)輪郭追跡処理 (3−3)孤立点・内閉ループ検出処理 の順序で,その動作を詳細に説明する。
In the above configuration, (1) rectangular mode, rectangular polygon mode, polygon mode area input (2) area data output (3) closed loop mode area input (3-1) start point detection processing ( 3-2) Contour tracking processing (3-3) Isolated point / inner closed loop detection processing The operation will be described in detail in the following order.

【0036】(1)矩形モード,直角多角形モード,多
角形モードのエリア入力 図5は,矩形モード,直角多角形モード,多角形モード
でのエリア入力のフローチャートを示す。先ず,操作部
(図示せず)を介してエリア処理を指定した後,ディジ
タイザ104を用いて,図4(a)〜(c)に示したよ
うに,エリア指定点の座標を入力することにより,エリ
ア処理を施す領域(エリア)を指定する(S501)。
(1) Area Input in Rectangular Mode, Right-Angle Polygon Mode, and Polygon Mode FIG. 5 shows a flowchart of area input in the rectangular mode, right-angle polygon mode, and polygon mode. First, after specifying an area process via an operation unit (not shown), the coordinates of an area designated point are input by using a digitizer 104 as shown in FIGS. 4 (a) to 4 (c). Then, an area to be processed is designated (S501).

【0037】エリア処理制御部206は,エリア指定点
の座標に基づいて,エリア処理を施すエリアの輪郭線の
座標を演算し(S502),求めた座標およびエリアの
指定順序に基づいて,ビットマップメモリ205にエリ
アデータを書き込むエリアデータ書き込み処理を実行す
る(S503)。なお,ビットマップメモリ205はエ
リア指定を開始する前にあらかじめクリア(全てのビッ
トが「0」に設定)されているものとする。
The area processing control unit 206 calculates the coordinates of the contour of the area to be subjected to the area processing based on the coordinates of the area designated point (S502), and based on the obtained coordinates and the area designation order, the bit map. An area data writing process for writing area data to the memory 205 is executed (S503). It is assumed that the bitmap memory 205 has been cleared (all bits are set to “0”) before starting the area designation.

【0038】図6は,ステップS503のエリアデータ
書き込み処理の詳細フローを示す。エリア処理制御部2
06は,エリアデータをビットマップメモリ205に書
き込む際に,先ず,ビットマップメモリ205上におい
て,書き込もうとする注目エリアデータの書き込み位置
に既存のエリアデータ(既に書き込まれているエリアデ
ータ)があるか否かを判定する(S601)。具体的に
は,エリアデータが4ビットの長さを有しているため,
注目エリアデータの先頭ビットの書き込み位置から前後
3ビットの範囲に既存のエリアデータの先頭ビットが存
在するか否か検索し,既存のエリアデータの先頭ビット
がある場合には注目エリアデータの書き込み位置と重複
する,すなわち,既存のエリアデータが存在すると判定
する。
FIG. 6 shows a detailed flow of the area data writing process in step S503. Area processing control unit 2
06, when area data is written to the bitmap memory 205, first, is there any existing area data (area data already written) in the bitmap memory 205 at the write position of the target area data to be written? It is determined whether or not it is (S601). Specifically, since the area data has a length of 4 bits,
A search is performed to determine whether or not the first bit of the existing area data exists within a range of three bits before and after the writing position of the first bit of the area data of interest. Is determined, that is, existing area data exists.

【0039】ステップS601で既存のエリアデータが
あると判定された場合には,既存のエリアデータの先頭
ビットの座標に基づいて,注目エリアデータの書き込み
位置を±4ドットの範囲で主走査方向に移動させて,書
き込み位置の補正を行う(S602)。ここで,注目エ
リアデータの書き込み位置の補正を行うのは,注目エリ
アデータをそのままの座標で書き込むと,既存のエリア
データが上書きされてしまい,既存のエリアデータが消
えてしまったり,あるいは,エリアデータの内容が変わ
ってしまう恐れがあるためである。また,±4ドットの
範囲で主走査方向に移動させるのは,エリアデータが4
ドットで構成されているためである。なお,本実施例で
は,注目エリアデータの書き込み位置を補正する構成と
したが,注目エリアデータの書き込み位置あるいは既存
のエリアデータの書き込み位置のどちらを補正しても良
いのは勿論である。
If it is determined in step S601 that there is existing area data, the writing position of the area data of interest is set within the range of ± 4 dots in the main scanning direction based on the coordinates of the first bit of the existing area data. The writing position is moved to correct the writing position (S602). Here, the correction of the writing position of the attention area data is performed if the attention area data is written with the coordinates as it is, the existing area data is overwritten and the existing area data is erased, or the area data is erased. This is because the contents of the data may be changed. When moving in the main scanning direction within the range of ± 4 dots, the area data is
This is because it is composed of dots. In this embodiment, the writing position of the area of interest data is corrected. However, it goes without saying that either the writing position of the area of interest data or the writing position of the existing area data may be corrected.

【0040】一方,ステップS601で既存のエリアデ
ータがないと判定された場合,およびステップS602
で注目エリアデータの書き込み位置を補正した後,注目
エリアデータをビットマップメモリ205に書き込む
(S603)。その後,全てのエリアデータの書き込み
が終了するまでS601〜S603を繰り返して処理を
終了する(S604)。なお,エリア処理制御部206
は,エリアの指定順序に応じてエリア番号を割り付けて
エリアデータを書き込むとともに,エリア番号に対応さ
せてエリア処理の内容をテーブルとして内部のメモリに
記憶する。
On the other hand, when it is determined in step S601 that there is no existing area data, and in step S602
After correcting the write position of the area of interest data, the area of interest data is written to the bitmap memory 205 (S603). Thereafter, steps S601 to S603 are repeated until the writing of all the area data is completed, and the process ends (S604). The area processing control unit 206
Assigns an area number in accordance with the area designation order and writes the area data, and stores the contents of the area processing as a table in the internal memory in correspondence with the area number.

【0041】(2)エリアデータの出力 次に,エリア処理制御部206によるエリアデータの出
力処理について説明する。エリア処理制御部206は,
ビットマップメモリ205に書き込まれているエリアデ
ータを,1ライン(副走査方向)ずつ読み出して,主走
査方向に1ドットずつ検索してエリアデータを検出し,
エリアデータ中のエリア番号に応じて,エリアデータの
書き込み時に作成したテーブルを参照してエリア処理の
内容を特定し,フィルタ処理部201,加工処理部20
2,中間調処理部203を制御してエリア処理の内容に
応じた画像処理を実行する。
(2) Output of Area Data Next, the output processing of area data by the area processing control unit 206 will be described. The area processing control unit 206
The area data written in the bitmap memory 205 is read out one line at a time (sub-scanning direction), and the area data is detected by searching one dot at a time in the main scanning direction.
According to the area number in the area data, the content of the area processing is specified by referring to the table created at the time of writing the area data.
2. Control the halftone processing unit 203 to execute image processing according to the content of the area processing.

【0042】図7は,エリアデータの出力処理のフロー
チャートを示し,先ず,注目ライン(1ライン)中にエ
リア(領域)の重複するエリアデータがあるかを判定し
(S701),エリアの重複するエリアデータがある場
合には,それぞれのエリアデータ(エリア番号)を比較
し,重複する部分に関しては優先順位の高いエリアデー
タを選択し(S702),ステップS703へ進む。こ
こで,エリア番号の大きいエリアデータが後から指定さ
れたエリアであり,本実施例では,後から指定されたエ
リアを優先的に処理することを前提として,エリア番号
の大きなエリアデータの優先順位が高いものとする。
FIG. 7 shows a flow chart of the area data output processing. First, it is determined whether or not there is area data in which the area (area) overlaps in the line of interest (one line) (S701), and the area overlaps. If there is area data, each area data (area number) is compared, and area data having a higher priority is selected for overlapping parts (S702), and the process proceeds to step S703. Here, the area data having the larger area number is the area specified later, and in this embodiment, the priority of the area data having the larger area number is assumed on the assumption that the area specified later is processed preferentially. Shall be high.

【0043】一方,エリアの重複するエリアデータがな
い場合には,ステップS703において,エリアデータ
に基づいて,1ライン分のエリア処理を実行する。
On the other hand, if there is no overlapping area data, area processing for one line is executed in step S703 based on the area data.

【0044】その後,ビットマップメモリ205内の全
てのラインが終了するまで上記ステップS701〜S7
03を繰り返し,処理を終了する(S704)。
Thereafter, steps S701 to S7 are repeated until all the lines in the bitmap memory 205 are completed.
03 is repeated, and the process ends (S704).

【0045】(3)閉ループモードのエリア入力 次に,本発明の要部である閉ループモードのエリア入力
について説明する。図8は,閉ループモードのエリア入
力処理のフローチャートを示す。閉ループモードのエリ
ア入力は,操作部(図示せず)を用いて閉ループモード
を指定し,原稿上の閉ループ内の一点(指定ポイント)
をディジタイザ104を介して指定した後,エリア処理
制御部206によって実行される。
(3) Area Input in Closed Loop Mode Next, the area input in the closed loop mode which is a main part of the present invention will be described. FIG. 8 shows a flowchart of the area input processing in the closed loop mode. For the area input of the closed loop mode, a closed loop mode is designated using an operation unit (not shown), and one point (designated point) in a closed loop on the document is designated.
Is specified via the digitizer 104, and is executed by the area processing control unit 206.

【0046】先ず,プレスキャンによって原稿画像を2
値化データとして入力し(S801),次に,開始ポイ
ント検出処理で閉ループを検出するための輪郭線の開始
点(座標)を求め(S802),さらに輪郭追跡処理で
輪郭線を抽出し(S803),孤立点・内閉ループ検出
処理において,輪郭線が孤立点(文字等)や,目的とす
る閉ループ内に存在する内閉ループでないことを確認後
(S804),閉ループのエリアを確定し,エリアデー
タ書き込み処理において,閉ループの座標に基づいてエ
リアデータをビットマップメモリ205に書き込む(S
805)。
First, the original image is scanned by prescanning.
The data is input as valued data (S801). Next, the start point (coordinates) of the contour for detecting a closed loop is determined by the start point detection processing (S802), and the contour is extracted by the contour tracking processing (S803). ), In the isolated point / inner closed loop detection processing, after confirming that the contour is not an isolated point (character or the like) or an inner closed loop existing in the target closed loop (S804), the area of the closed loop is determined, and the area data is determined. In the writing process, the area data is written to the bitmap memory 205 based on the coordinates of the closed loop (S
805).

【0047】ステップS801の2値化データの入力で
は,原稿をプレスキャンして,原稿読取部101で2値
化画像(解像度400dpi)として読み取り,400
/100変換部204を介して,4×4画素のOR処理
を行って100dpiの2値化データに変換して,ビッ
トマップメモリ205に記憶させる。これによって,結
果的に2値化データの太らせ処理を行ったことになり,
読み取った2値化画像に線切れがあったときでも,ある
程度の線切れ幅(最大3画素の線切れ幅,約0.178
5mm相当)の場合には自動補正される。
In the input of the binary data in step S801, the original is pre-scanned, read as a binary image (resolution 400 dpi) by the original reading unit 101, and read.
Through the / 100 conversion unit 204, OR processing of 4 × 4 pixels is performed to convert the data into binary data of 100 dpi, and stored in the bitmap memory 205. As a result, the binarized data is thickened as a result.
Even if a line break occurs in the read binary image, a certain line break width (line break width of a maximum of 3 pixels, about 0.178)
(Equivalent to 5 mm) is automatically corrected.

【0048】(3−1)開始ポイント検出処理 次に,図9を参照して,図8のステップS802の開始
ポイント検出処理について詳細に説明する。先ず,ディ
ジタイザ104を介して指定した指定ポイントの座標に
基づいて,ビットマップメモリ205から指定ポイント
の座標位置の2値化データを入力し(S901),指定
ポイントの画素が黒か否かを判定する(S902)。
(3-1) Start Point Detection Processing Next, the start point detection processing of step S802 in FIG. 8 will be described in detail with reference to FIG. First, based on the coordinates of the designated point designated via the digitizer 104, binarized data of the coordinate position of the designated point is input from the bitmap memory 205 (S901), and it is determined whether or not the pixel of the designated point is black. (S902).

【0049】ここで,指定ポイントの画素が黒の場合に
は,エラーとしてシステム制御部105にエラーコード
を出力して(S903),処理を終了する。
If the pixel at the designated point is black, an error code is output to the system control unit 105 as an error (S903), and the process ends.

【0050】一方,指定ポイントの画素が黒でない場
合,すなわち白画素の場合には,指定ポイントの画素を
注目画素に設定し(S904),注目画素の左隣の画素
が黒か否か判定する(S905)。ここで,注目画素の
左隣の画素が黒ならば,左隣の画素を開始ポイントとし
て設定し,その座標をスタックし(S906),処理を
終了する。
On the other hand, if the pixel at the designated point is not black, that is, if it is a white pixel, the pixel at the designated point is set as the target pixel (S904), and it is determined whether the pixel to the left of the target pixel is black. (S905). Here, if the pixel on the left of the target pixel is black, the pixel on the left is set as the start point, the coordinates are stacked (S906), and the process ends.

【0051】一方,注目画素の左隣の画素が白ならば,
黒画素を検出するまで逐次左隣の画素を調べ,A3サイ
ズメモリ左端に相当するアドレスまで黒画素が検出され
ない場合には(S907),エラーとしてシステム制御
部105にエラーコードを出力して(S908),処理
を終了する。
On the other hand, if the pixel on the left of the target pixel is white,
Until a black pixel is detected, the pixels on the left are sequentially examined. If no black pixel is detected up to the address corresponding to the left end of the A3 size memory (S907), an error code is output to the system control unit 105 as an error (S908). ), End the process.

【0052】上記の処理によって,例えば,図10
(a)の原稿画像の1001で示す部分が,図10
(b)のようにビットマップメモリ205上に2値化デ
ータとして取り込まれており,指定ポイントとして閉ル
ープ内に×で示す位置が指定された場合に,指定ポイン
トの左隣の画素を逐次調べて,黒画素である閉ループ端
の画素を開始ポイントとして得ることになる。
By the above processing, for example, FIG.
The portion indicated by reference numeral 1001 of the original image in FIG.
As shown in (b), when the data is fetched as binary data on the bitmap memory 205 and a position indicated by X is designated as a designated point in a closed loop, the pixel on the left of the designated point is sequentially examined. , The pixel at the end of the closed loop, which is a black pixel, is obtained as the starting point.

【0053】(3−2)輪郭追跡処理 次に,図11を参照して,輪郭追跡処理(図8のステッ
プS803)について詳細に説明する。先ず,開始ポイ
ントを注目画素に設定し(S1101),注目画素の左
隣の画素が白・黒のいずれかを判定する(S110
2)。
(3-2) Contour Tracking Process Next, the contour tracking process (step S803 in FIG. 8) will be described in detail with reference to FIG. First, the start point is set to the target pixel (S1101), and it is determined whether the pixel on the left of the target pixel is white or black (S110).
2).

【0054】ステップS1102において白画素なら
ば,注目画素の左隣の画素を始点として,反時計回り
に,8近接画素の最初の黒画素を検出する(S110
3)。ステップS1102において黒画素ならば,注目
画素の左隣の画素を始点として,時計回りに,8近接画
素の最初の白画素の前の黒画素を検出する(S111
0)。
If the pixel is a white pixel in step S1102, the first black pixel of eight adjacent pixels is detected counterclockwise starting from the pixel on the left of the target pixel as a starting point (S110).
3). If the pixel is a black pixel in step S1102, a black pixel before the first white pixel of the eight neighboring pixels is detected clockwise starting from the pixel on the left of the target pixel as a starting point (S111).
0).

【0055】ステップS1103あるいはステップS1
104で,黒画素の検出に成功しなかった場合,すなわ
ち8近接画素が全て白画素であった場合,あるいは,全
て黒画素であった場合には(S1105),エラーとし
てシステム制御部105にエラーコードを出力して(S
1106),処理を終了する。ただし,この場合には一
度黒画素として検出された画素(前回の注目画素あるい
は前前回の注目画素)を再度黒画素として検出しないも
のとする。
Step S1103 or step S1
At 104, if the detection of a black pixel is not successful, that is, if all eight neighboring pixels are all white pixels, or if all eight black pixels are black pixels (S1105), an error is sent to the system control unit 105 as an error. Output the code (S
1106), the process ends. However, in this case, it is assumed that a pixel once detected as a black pixel (the previous target pixel or the previous previous target pixel) is not detected again as a black pixel.

【0056】また,黒画素の検出に成功した場合には
(S1105),検出した黒画素と注目画素との相対位
置よりチェインコードを求めて,黒画素の座標値および
チェインコードを輪郭線情報としてRAM207にスタ
ックし(S1107),所定のカウンタをカウントアッ
プして輪郭追跡処理を開始してからの通算の画素数をカ
ウントする(S1108)。次に,検出画素をあらたな
注目画素として(S1109),あらたな注目画素と開
始ポイントとが一致するまでステップS1102以下の
ステップを繰り返し,あらたな注目画素と開始ポイント
とが一致したら処理を終了する(S1110)。
If the detection of the black pixel is successful (S1105), a chain code is obtained from the relative position between the detected black pixel and the pixel of interest, and the coordinate value of the black pixel and the chain code are used as outline information. It is stacked on the RAM 207 (S1107), and a predetermined counter is counted up to count the total number of pixels since the start of the contour tracking process (S1108). Next, the detected pixel is set as a new target pixel (S1109), and the steps from step S1102 are repeated until the new target pixel matches the start point. When the new target pixel matches the start point, the process ends. (S1110).

【0057】上記の輪郭追跡処理によって,例えば,図
12(a)に示すように,閉ループの内側の領域におい
て,指定ポイントが指定され,指定ポイントから開始ポ
イントが求められている場合には,矢印の進行方向で示
すようにして閉ループの輪郭追跡が実施され,閉ループ
が輪郭として習得される。
In the above-described contour tracing process, for example, as shown in FIG. 12A, when a designated point is designated in a region inside a closed loop and a start point is obtained from the designated point, an arrow , The closed-loop contour is tracked as indicated by the traveling direction, and the closed loop is acquired as the contour.

【0058】ところが,図12(b)あるいは図12
(c)に示すように,本来検出したい閉ループと指定ポ
イントとの間に文字や,内閉ループ(閉ループ内閉ルー
プ)が存在した場合には,開始ポイント検出処理で文字
や,内閉ループの黒画素を開始ポイントとして検出する
ため,輪郭追跡処理で文字や,内閉ループの輪郭追跡を
行ってしまう場合がある。このため,輪郭追跡処理の後
に孤立点・内閉ループ検出処理を実行して,文字および
内閉ループが検出されいないか判定する。
However, FIG. 12B or FIG.
As shown in (c), if there is a character or an inner closed loop (closed loop inner closed loop) between the closed loop originally desired to be detected and the designated point, the character or the black pixel of the inner closed loop is detected in the start point detection processing. In order to detect the start point, the contour tracing process may sometimes trace the contour of a character or an inner closed loop. Therefore, an isolated point / inner closed loop detection process is executed after the contour tracking process to determine whether a character and an inner closed loop are detected.

【0059】(3−3)孤立点・内閉ループ検出処理 次に,図13を参照して,孤立点・内閉ループ検出処理
(図8のステップS804)について詳細に説明する。
先ず,開始ポイントと同じY座標の画素のチェインコー
ドを検出し(S1301),チェインコードが下方向か
否かを判定する(S1302)。ここで,チェインコー
ドが下方向の場合には,注目画素に対して右下,左下,
下のいずれかの方向で黒画素が検出されたことを示す。
換言すれば,指定ポイントが検出した閉ループの外側に
存在することを示すため,エラーとしてシステム制御部
105にエラーコードを出力して(S1303),処理
を終了する。
(3-3) Isolated Point / Inner Closed Loop Detection Processing Next, the isolated point / inner closed loop detection processing (step S804 in FIG. 8) will be described in detail with reference to FIG.
First, a chain code of a pixel having the same Y coordinate as the start point is detected (S1301), and it is determined whether or not the chain code is downward (S1302). Here, when the chain code is in the downward direction, the lower right, lower left,
Indicates that a black pixel has been detected in any of the following directions.
In other words, an error code is output to the system control unit 105 as an error to indicate that the designated point exists outside the detected closed loop (S1303), and the process ends.

【0060】一方,チェインコードが下方向でない場合
には,画素カウント値(輪郭追跡処理を開始してからの
通算の画素数:輪郭画素数)と所定のしきい値とを比較
し(S1304),画素カウント値がしきい値以下であ
れば,孤立点と見なし,エラーとしてシステム制御部1
05にエラーコードを出力して(S1305),処理を
終了する。
On the other hand, if the chain code is not downward, the pixel count value (the total number of pixels since the start of the contour tracking process: the number of contour pixels) is compared with a predetermined threshold value (S1304). If the pixel count value is equal to or less than the threshold value, it is regarded as an isolated point and an error
05 is output (S1305), and the process ends.

【0061】エリア処理制御部206は,孤立点・内閉
ループ検出処理でエラーが検出されなかった場合に,閉
ループが正しく検出されたと判断し,先ず,ビットマッ
プメモリ205をクリアし,続いて,RAM207内に
スタックされている輪郭線情報に基づいて,エリアデー
タが輪郭線上になるように,すなわち,エリアデータの
先頭ビットが輪郭線上の黒画素の位置に重なるように補
正して,エリアデータをビットマップメモリ205に書
き込む。なお,このときのエリアデータ書き込み処理
は,図6のフローチャートと基本的に同様であるので説
明を省略する。
If no error is detected in the isolated point / inner closed loop detection processing, the area processing controller 206 determines that the closed loop has been correctly detected, and clears the bit map memory 205 first, and then the RAM 207. The area data is corrected based on the outline information stacked in the area data so that the area data is on the outline, that is, the first bit of the area data is overlapped with the position of the black pixel on the outline. Write to the map memory 205. Note that the area data writing process at this time is basically the same as the flowchart of FIG. 6, and a description thereof will be omitted.

【0062】また,前述したの実施例では,輪郭追跡処
理,孤立点・内閉ループ検出処理でエラーを検出したら
システム制御部105へエラーコードを出力して処理を
終了するようにしたが,エリア処理制御部206におい
て,エラーの内容に応じて,輪郭追跡を行う注目画素の
位置を補正して輪郭追跡処理を再度実行するようにして
も良い。
In the above-described embodiment, when an error is detected in the contour tracking processing and the isolated point / inner closed loop detection processing, an error code is output to the system control unit 105 and the processing is terminated. The control unit 206 may correct the position of the pixel of interest for which contour tracing is performed according to the content of the error, and execute the contour tracing process again.

【0063】また,前述した実施例の輪郭追跡処理で
は,ステップS1105,S1106において,黒画素
の検出に成功しなかった場合に,エラーとして処理を終
了したが,原稿画像が薄くて,2値化データの輪郭線が
途中で切れている場合もあるので,例えば,図14に示
すように,黒画素の検出に成功しなかった位置(その時
の注目画素)より,所定方向・所定範囲のビットマップ
メモリ205上に存在する画素を検出し,黒画素が検出
された場合にその黒画素の位置より輪郭追跡処理を継続
することにより,所定の範囲で輪郭線が切れた場合に
は,輪郭追跡処理を中止することなく,閉ループを検出
することができる。図14においては,画素を検出する
方向を過去の注目画素の進行方向の左右を含む前方向と
し,注目画素から3画素離れた位置の画素までを検出し
ている。
In the contour tracing process according to the above-described embodiment, if the detection of the black pixel is not successful in steps S1105 and S1106, the process is terminated as an error. Since the outline of the data may be cut off in the middle, for example, as shown in FIG. 14, a bit map in a predetermined direction and a predetermined range is determined from a position where a black pixel is not successfully detected (the target pixel at that time). By detecting pixels existing in the memory 205 and continuing the contour tracing process from the position of the black pixel when a black pixel is detected, the contour tracing process is performed when the contour is cut within a predetermined range. Without stopping the operation, a closed loop can be detected. In FIG. 14, the direction in which a pixel is detected is set to the forward direction including the left and right of the past traveling direction of the target pixel, and pixels up to three pixels away from the target pixel are detected.

【0064】また,輪郭追跡処理において,ビットマッ
プメモリ205上の2値化データから輪郭線情報を抽出
する際に,注目画素周辺の画像の有無,注目画素周辺の
2値化データの白・黒および注目画素の前後の輪郭線方
向に応じて,エリアデータの書き込み禁止/許可情報を
生成し,輪郭線情報と共に前記禁止/許可情報をRAM
207に記憶し,エリアデータ書き込み処理において,
エリアデータをビットマップメモリに書き込む際に,前
記禁止/許可情報に基づいて,エリアデータの書き込み
位置を補正するようにしても良い。
In the contour tracing process, when extracting the contour line information from the binarized data on the bitmap memory 205, the presence or absence of an image around the target pixel and the white / black of the binary data around the target pixel are determined. In addition, write / prohibit information of area data is generated according to the contour directions before and after the pixel of interest, and the prohibition / permission information is stored in RAM along with the contour information.
207, and in the area data writing process,
When writing the area data to the bitmap memory, the writing position of the area data may be corrected based on the prohibition / permission information.

【0065】[0065]

【発明の効果】以上説明したように本発明の画像処理装
置は,対象画像データに対するエリア処理の内容を,主
走査方向に対して所定の長さを有したエリアデータとし
て記憶するビットマップメモリを備え,1ライン中にお
いて同種エリアデータで挟まれる部分に対して,該エリ
アデータの種類に応じたエリア処理を施す画像処理装置
において,前記エリアデータをビットマップメモリに書
き込む際に,新たに書き込むエリアデータが既にビット
マップ上に書き込まれている既存のエリアデータと重な
るか否かを判定する判定手段と,前記判定手段で既存の
エリアデータと重なると判定された場合,既存のエリア
データの位置に基づいて,新たに書き込むエリアデータ
の位置を主走査方向に補正する書込位置補正手段とを備
えたため,エリアの交点や頂点,およびエリアどうしの
近接部においても,確実に指定されたエリア処理を実行
することができる。
As described above, the image processing apparatus of the present invention has a bit map memory for storing the contents of area processing on target image data as area data having a predetermined length in the main scanning direction. An image processing apparatus for performing an area process according to the type of area data on a portion sandwiched between the same type of area data in one line, wherein an area to be newly written when the area data is written to a bit map memory is provided. Determining means for determining whether or not the data overlaps with the existing area data already written on the bitmap; and when the determining means determines that the data overlaps with the existing area data, the position of the existing area data is determined. Writing position correction means for correcting the position of newly written area data in the main scanning direction based on the Intersections and vertices, and also in the proximity of each other area, it is possible to reliably perform the specified area process.

【0066】また,本発明の画像処理装置は,複数のエ
リアデータによって複数のエリアが指定された際に,指
定された複数のエリアにおいて重複する領域がある場
合,あらかじめエリアデータ毎に設定された優先順位に
基づいて,重複した領域に対するエリア処理として最も
優先順位の高いエリアデータを選択するエリアデータ選
択手段を備えたため,複数のエリアが指定された場合
に,後に指定されたエリアを優先的に処理した画像出力
を確実に得ることができる。
In the image processing apparatus of the present invention, when a plurality of areas are designated by a plurality of area data, if there is an overlapping area in the designated plurality of areas, the area is set in advance for each area data. An area data selecting means for selecting the area data having the highest priority as the area processing for the overlapping area based on the priority is provided, so that when a plurality of areas are specified, the area specified later is given priority. A processed image output can be reliably obtained.

【0067】また,本発明の画像処理装置は,対象画像
データに対するエリア処理の内容を,主走査方向に対し
て所定の長さを有したエリアデータとして記憶するビッ
トマップメモリを備え,1ライン中において同種エリア
データで挟まれる部分に対して,該エリアデータの種類
に応じたエリア処理を施す画像処理装置において,対象
画像の2値化データを前記ビットマップメモリに取り込
んで,ビットマップメモリ上の2値化データに対して輪
郭追跡処理を施し,輪郭線情報を抽出する輪郭線抽出手
段と,前記輪郭線抽出手段で抽出した輪郭線情報を記憶
する輪郭線記憶手段と,前記輪郭線抽出手段による輪郭
線情報の抽出の終了後,前記ビットマップメモリをクリ
アし,前記輪郭線記憶手段に記憶されている輪郭線情報
に基づいて,エリアデータをビットマップメモリに書き
込むエリアデータ書込手段とを備えたため,予めエリア
処理前に読み込んだ画像データから輪郭線情報を取得す
ることにより,その輪郭内部(閉ループ)に対して任意
のエリア処理を施すことができる。また,エリア処理の
指定の簡単化およびエリア処理の使い勝手を向上させる
ことができる。
Further, the image processing apparatus of the present invention is provided with a bit map memory for storing the contents of the area processing for the target image data as area data having a predetermined length in the main scanning direction. In an image processing apparatus that performs an area process according to the type of the area data on a portion sandwiched between the same type of area data, the binary data of the target image is fetched into the bitmap memory and Contour extracting means for performing contour tracing processing on the binarized data to extract contour information, contour storing means for storing contour information extracted by the contour extracting means, and contour extracting means After the completion of the extraction of the contour information, the bit map memory is cleared, and the area is stored based on the contour information stored in the contour storage means. Since area data writing means for writing data to a bit map memory is provided, by obtaining contour line information from image data read before area processing, arbitrary area processing can be performed on the inside of the contour (closed loop). Can be applied. Further, it is possible to simplify the designation of the area processing and improve the usability of the area processing.

【0068】また,本発明の画像処理装置は,太らせ処
理後の画像データをビットマップメモリに取り込むた
め,原稿画像の輪郭線が薄い場合や,途切れている場合
も,ある程度の範囲で輪郭線の抽出を行え,正しく輪郭
線情報を検出して,適切なエリア処理を施すことができ
る。
Since the image processing apparatus of the present invention takes in the image data after the fattening process into the bitmap memory, even if the outline of the original image is thin or interrupted, the outline is within a certain range. Can be extracted, contour line information can be correctly detected, and appropriate area processing can be performed.

【0069】また,本発明の画像処理装置は,ビットマ
ップメモリ上の2値化データから輪郭線情報を抽出する
際に,輪郭線が途中で途切れている場合,輪郭線が途切
れた位置より,所定方向・所定範囲のビットマップメモ
リ上に存在する画像を検出し,検出位置より輪郭追跡処
理を継続するため,原稿画像の輪郭線が途切れている場
合も,ある程度の範囲で輪郭線の抽出を行え,正しく輪
郭線情報を検出して,適切なエリア処理を施すことがで
きる。
In the image processing apparatus of the present invention, when the contour information is extracted from the binarized data in the bit map memory, if the contour is interrupted on the way, the position is determined from the position where the contour is interrupted. In order to detect an image existing in the bitmap memory in a predetermined direction and a predetermined range, and to continue the contour tracing process from the detected position, even if the outline of the original image is interrupted, extraction of the outline in a certain range is performed. Thus, the contour line information can be correctly detected, and appropriate area processing can be performed.

【0070】また,本発明の画像処理装置は,ビットマ
ップメモリ上の2値化データから輪郭線情報を抽出する
際に,輪郭線の輪郭長を検出して,所定のしきい値と比
較し,前記輪郭長がしきい値より小さい場合には,検出
した輪郭線情報を破棄し,あらたに別の輪郭線を検出し
て輪郭線情報の抽出を行うため,原稿画像中に孤立点や
閉ループ画像でない画像が存在する場合にも,正しい輪
郭線情報を習得し,適切なエリア処理を施すことができ
る。
When extracting the contour information from the binary data in the bit map memory, the image processing apparatus of the present invention detects the contour length of the contour and compares it with a predetermined threshold value. If the contour length is smaller than the threshold value, the detected contour information is discarded, and another contour is detected to extract the contour information. Even when there is an image that is not an image, it is possible to learn correct outline information and perform appropriate area processing.

【0071】また,本発明の画像処理装置は,ビットマ
ップメモリ上の2値化データから輪郭線情報を抽出する
際に,追跡している輪郭線が内輪郭・外輪郭の何れであ
るかを検出し,外輪郭である場合には,検出した輪郭線
情報を破棄し,あらたに別の輪郭線を検出して輪郭線情
報の抽出を行うため,原稿画像中のエリアとして指定す
る閉ループ内に他の閉ループが存在している場合にも,
正しい輪郭線情報を習得し,適切なエリア処理を施すこ
とができる。
Further, the image processing apparatus of the present invention, when extracting contour information from the binary data in the bitmap memory, determines whether the tracked contour is an inner contour or an outer contour. If it is detected and it is an outer contour, the detected contour information is discarded, and another contour is newly detected to extract the contour information. Even if there are other closed loops,
It is possible to learn correct outline information and perform appropriate area processing.

【0072】また,本発明の画像処理装置は,エリアデ
ータをビットマップメモリに書き込む際に,書き込み位
置が輪郭線上になるように補正するため,得られた輪郭
線情報に応じて閉ループ内部に任意のエリア処理を施す
際に,輪郭線付近においても適切なエリア処理を施した
画像出力を得ることができる。
Further, the image processing apparatus of the present invention corrects the writing position to be on the contour line when writing the area data to the bitmap memory, so that the arbitrary position can be set inside the closed loop according to the obtained contour line information. When performing the area processing described above, it is possible to obtain an image output that has been subjected to appropriate area processing even near the contour line.

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

【図1】本実施例の画像処理装置を適用したデジタル複
写機のブロック構成図である。
FIG. 1 is a block diagram of a digital copying machine to which an image processing apparatus according to an embodiment is applied.

【図2】本実施例の画像処理装置である画像処理部の構
成図である。
FIG. 2 is a configuration diagram of an image processing unit which is an image processing apparatus of the present embodiment.

【図3】エリア処理に使用するエリアデータのデータ構
造を示す説明図である。
FIG. 3 is an explanatory diagram showing a data structure of area data used for area processing.

【図4】エリア処理の対象となるエリア(領域)を指定
する方法を示す説明図である。
FIG. 4 is an explanatory diagram showing a method of designating an area (area) to be subjected to area processing.

【図5】矩形モード,直角多角形モード,多角形モード
でのエリア入力のフローチャートである。
FIG. 5 is a flowchart of area input in a rectangular mode, a right-angle polygon mode, and a polygon mode.

【図6】エリアデータ書き込み処理の詳細フローであ
る。
FIG. 6 is a detailed flow of an area data writing process.

【図7】エリアデータの出力処理のフローチャートであ
る。
FIG. 7 is a flowchart of an area data output process.

【図8】閉ループモードのエリア入力処理のフローチャ
ートである。
FIG. 8 is a flowchart of an area input process in a closed loop mode.

【図9】開始ポイント検出処理のフローチャートであ
る。
FIG. 9 is a flowchart of a start point detection process.

【図10】開始ポイントの検出例を示す説明図である。FIG. 10 is an explanatory diagram showing an example of detecting a start point.

【図11】輪郭追跡処理のフローチャートである。FIG. 11 is a flowchart of a contour tracking process.

【図12】輪郭追跡処理を示す説明図である。FIG. 12 is an explanatory diagram showing a contour tracking process.

【図13】孤立点・内閉ループ検出処理のフローチャー
トである。
FIG. 13 is a flowchart of an isolated point / inner closed loop detection process.

【図14】輪郭線が途中で切れている場合の輪郭追跡処
理の継続を示す説明図である。
FIG. 14 is an explanatory diagram showing continuation of the contour tracking process when the contour is cut off in the middle.

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

101 画像読取部 102 画像処理部 103 画像記録部 104 ディジタイザ 105 システム制御部 201 フィルタ処理部 202 加工処理部 203 中間調処理部 204 400/100変換部 205 ビットマップメモリ 206 エリア処理制御部 207 RAM DESCRIPTION OF SYMBOLS 101 Image reading part 102 Image processing part 103 Image recording part 104 Digitizer 105 System control part 201 Filter processing part 202 Processing part 203 Halftone processing part 204 400/100 conversion part 205 Bitmap memory 206 Area processing control part 207 RAM

───────────────────────────────────────────────────── フロントページの続き (58)調査した分野(Int.Cl.7,DB名) G06T 3/00 400 G06T 1/00 450 H04N 1/387 JICSTファイル(JOIS)──────────────────────────────────────────────────続 き Continued on the front page (58) Fields investigated (Int. Cl. 7 , DB name) G06T 3/00 400 G06T 1/00 450 H04N 1/387 JICST file (JOIS)

Claims (8)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 対象画像データに対するエリア処理の内
容を,主走査方向に対して所定の長さを有したエリアデ
ータとして記憶するビットマップメモリを備え,1ライ
ン中において同種エリアデータで挟まれる部分に対し
て,該エリアデータの種類に応じたエリア処理を施す画
像処理装置において,前記エリアデータをビットマップ
メモリに書き込む際に,新たに書き込むエリアデータが
既にビットマップ上に書き込まれている既存のエリアデ
ータと重なるか否かを判定する判定手段と,前記判定手
段で既存のエリアデータと重なると判定された場合,既
存のエリアデータの位置に基づいて,新たに書き込むエ
リアデータの位置を主走査方向に補正する書込位置補正
手段とを備えたことを特徴とする画像処理装置。
1. A bit map memory for storing the contents of area processing for target image data as area data having a predetermined length in the main scanning direction, wherein a portion sandwiched between similar area data in one line is provided. In contrast, in an image processing apparatus that performs area processing according to the type of the area data, when writing the area data to the bitmap memory, the area data to be newly written is already written on the bitmap. Determining means for determining whether or not the data overlaps with the area data; and, if the determining means determines that the data overlaps with the existing area data, the position of the area data to be newly written is determined based on the position of the existing area data. An image processing apparatus comprising: a writing position correcting unit that corrects in a direction.
【請求項2】 複数のエリアデータによって複数のエリ
アが指定された際に,指定された複数のエリアにおいて
重複する領域がある場合,あらかじめエリアデータ毎に
設定された優先順位に基づいて,重複した領域に対する
エリア処理として最も優先順位の高いエリアデータを選
択するエリアデータ選択手段を備えたことを特徴とする
請求項1記載の画像処理装置。
2. When a plurality of areas are designated by a plurality of area data, if there are overlapping areas in the designated plurality of areas, the overlapping areas are determined based on a priority set in advance for each area data. 2. The image processing apparatus according to claim 1, further comprising area data selecting means for selecting area data having the highest priority as the area processing for the area.
【請求項3】 対象画像データに対するエリア処理の内
容を,主走査方向に対して所定の長さを有したエリアデ
ータとして記憶するビットマップメモリを備え,1ライ
ン中において同種エリアデータで挟まれる部分に対し
て,該エリアデータの種類に応じたエリア処理を施す画
像処理装置において,対象画像の2値化データを前記ビ
ットマップメモリに取り込んで,ビットマップメモリ上
の2値化データに対して輪郭追跡処理を施し,輪郭線情
報を抽出する輪郭線抽出手段と,前記輪郭線抽出手段で
抽出した輪郭線情報を記憶する輪郭線記憶手段と,前記
輪郭線抽出手段による輪郭線情報の抽出の終了後,前記
ビットマップメモリをクリアし,前記輪郭線記憶手段に
記憶されている輪郭線情報に基づいて,エリアデータを
ビットマップメモリに書き込むエリアデータ書込手段と
を備えたことを特徴とする画像処理装置。
3. A bit map memory for storing the content of area processing for target image data as area data having a predetermined length in the main scanning direction, wherein a portion sandwiched between similar area data in one line is provided. In response to this, in an image processing apparatus that performs area processing according to the type of the area data, the binarized data of the target image is fetched into the bitmap memory, and the outline data is stored in the bitmap memory. Contour extraction means for performing a tracking process to extract contour information, contour storage means for storing contour information extracted by the contour extraction means, and completion of contour information extraction by the contour extraction means Thereafter, the bit map memory is cleared, and the area data is stored in the bit map memory based on the contour information stored in the contour storage means. An image processing apparatus comprising: an area data writing unit for writing.
【請求項4】 2値化データに太らせ処理を施す画像太
らせ処理手段を備え,前記ビットマップメモリに取り込
む対象画像の2値化データが,太らせ処理後の画像デー
タであることを特徴とする請求項3記載の画像処理装
置。
4. An image fattening means for subjecting the binarized data to fattening processing, wherein the binarized data of the target image to be taken into the bitmap memory is image data after fattening processing. The image processing apparatus according to claim 3, wherein
【請求項5】 前記輪郭線抽出手段は,前記ビットマッ
プメモリ上の2値化データから輪郭線情報を抽出する際
に,輪郭線が途中で途切れている場合,輪郭線が途切れ
た位置より,所定方向・所定範囲のビットマップメモリ
上に存在する画像を検出し,検出位置より輪郭追跡処理
を継続することを特徴とする請求項3記載の画像処理装
置。
5. The contour line extracting means, when extracting contour line information from the binary data in the bitmap memory, if the contour line is interrupted in the middle, from the position where the contour line is interrupted, 4. The image processing apparatus according to claim 3, wherein an image existing in the bitmap memory in a predetermined direction and a predetermined range is detected, and the contour tracing process is continued from the detected position.
【請求項6】 前記輪郭線抽出手段は,前記ビットマッ
プメモリ上の2値化データから輪郭線情報を抽出する際
に,輪郭線の輪郭長を検出して,所定のしきい値と比較
し,前記輪郭長がしきい値より小さい場合には,検出し
た輪郭線情報を破棄し,あらたに別の輪郭線を検出して
輪郭線情報の抽出を行うことを特徴とする請求項3記載
の画像処理装置。
6. The contour line extracting means detects a contour length of a contour line when extracting contour line information from the binarized data in the bitmap memory, and compares the contour length with a predetermined threshold value. 4. The method according to claim 3, wherein when the contour length is smaller than a threshold value, the detected contour information is discarded, and another contour is detected to extract the contour information. Image processing device.
【請求項7】 前記輪郭線抽出手段は,前記ビットマッ
プメモリ上の2値化データから輪郭線情報を抽出する際
に,追跡している輪郭線が内輪郭・外輪郭の何れである
かを検出し,外輪郭である場合には,検出した輪郭線情
報を破棄し,あらたに別の輪郭線を検出して輪郭線情報
の抽出を行うことを特徴とする請求項3記載の画像処理
装置。
7. When extracting contour information from the binary data in the bitmap memory, the contour extracting means determines whether the tracked contour is an inner contour or an outer contour. 4. The image processing apparatus according to claim 3, wherein the detected contour information is discarded if the detected contour is an outer contour, and another contour is detected to extract the contour information. .
【請求項8】 前記エリアデータ書込手段は,エリアデ
ータをビットマップメモリに書き込む際に,書き込み位
置が輪郭線上になるように補正することを特徴とする請
求項3記載の画像処理装置。
8. The image processing apparatus according to claim 3, wherein said area data writing means corrects the writing position so as to be on the contour line when writing the area data to the bitmap memory.
JP14872393A 1993-05-26 1993-05-26 Image processing device Expired - Fee Related JP3354629B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP14872393A JP3354629B2 (en) 1993-05-26 1993-05-26 Image processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP14872393A JP3354629B2 (en) 1993-05-26 1993-05-26 Image processing device

Publications (2)

Publication Number Publication Date
JPH06333038A JPH06333038A (en) 1994-12-02
JP3354629B2 true JP3354629B2 (en) 2002-12-09

Family

ID=15459171

Family Applications (1)

Application Number Title Priority Date Filing Date
JP14872393A Expired - Fee Related JP3354629B2 (en) 1993-05-26 1993-05-26 Image processing device

Country Status (1)

Country Link
JP (1) JP3354629B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4612760B2 (en) * 2000-04-25 2011-01-12 キヤノン株式会社 Image processing apparatus and method
US6922485B2 (en) * 2001-12-06 2005-07-26 Nec Corporation Method of image segmentation for object-based image retrieval

Also Published As

Publication number Publication date
JPH06333038A (en) 1994-12-02

Similar Documents

Publication Publication Date Title
US6580804B1 (en) Pixel-based digital watermarks located near edges of an image
US5901253A (en) Image processing system with image cropping and skew correction
US5448376A (en) Image processing apparatus for deleting undesired image from image of document
EP0554985B1 (en) Method and apparatus for contour vector extraction and image enlargement/reduction
JP4586241B2 (en) Image processing device
JPH07115534A (en) Image reader
JP3354629B2 (en) Image processing device
JP2812401B2 (en) Image processing device
JPH11288453A (en) Method and system for detecting skew angle and black boundary line of original image in scan environment for reproduction
JP2557480B2 (en) Color image processor
JPS63260265A (en) Color picture processing method
JP3587586B2 (en) Image processing device
JP2978550B2 (en) Mark detection device
JP3814547B2 (en) Image processing apparatus and method
JPH09135331A (en) Image processor
JP3064305B2 (en) Digital copier
JP2985303B2 (en) Recording device area recognition method
JP3147246B2 (en) Image processing apparatus and method
JPH05211607A (en) Device and method for image processing
JP2957050B2 (en) Image data enlarger
KR970010488B1 (en) Digital image editing method and apparatus
JP2557481B2 (en) Color image processor
JPH0638021A (en) Color image processor
JPH089141A (en) Marker erasing device
JPH07160897A (en) Picture processor

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees