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
JP3011733B2 - How to determine the contour of a picture - Google Patents
[go: Go Back, main page]

JP3011733B2 - How to determine the contour of a picture - Google Patents

How to determine the contour of a picture

Info

Publication number
JP3011733B2
JP3011733B2 JP5443790A JP5443790A JP3011733B2 JP 3011733 B2 JP3011733 B2 JP 3011733B2 JP 5443790 A JP5443790 A JP 5443790A JP 5443790 A JP5443790 A JP 5443790A JP 3011733 B2 JP3011733 B2 JP 3011733B2
Authority
JP
Japan
Prior art keywords
pixel
point
contour
function
value
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 - Lifetime
Application number
JP5443790A
Other languages
Japanese (ja)
Other versions
JPH03256045A (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.)
Dai Nippon Printing Co Ltd
B U G Inc
Original Assignee
Dai Nippon Printing Co Ltd
B U G Inc
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 Dai Nippon Printing Co Ltd, B U G Inc filed Critical Dai Nippon Printing Co Ltd
Priority to JP5443790A priority Critical patent/JP3011733B2/en
Publication of JPH03256045A publication Critical patent/JPH03256045A/en
Application granted granted Critical
Publication of JP3011733B2 publication Critical patent/JP3011733B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Preparing Plates And Mask In Photomechanical Process (AREA)

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は絵柄の輪郭線決定方法、特に、画像中から絵
柄の切抜き処理を行う場合に、絵柄の輪郭線を決定する
のに適した輪郭線決定方法に関する。
DETAILED DESCRIPTION OF THE INVENTION [Industrial Application Field] The present invention relates to a method for determining a contour of a picture, and more particularly, to a contour suitable for determining a contour of a picture when performing a process of clipping a picture from an image. It relates to a line determination method.

〔従来の技術〕[Conventional technology]

写真などの原稿から製版用フィルムを作成する場合、
原稿画像中の必要な絵柄の部分のみを切り出し、不要な
背景部分を除く作業が必要になる。このような画像の切
抜き処理を行う方法として、レイアウトスキャナなどを
用いた画像処理による方法が知られている。この切抜き
方法では、まずレイアウトスキャナによって、原稿の画
像をデジタルデータとして入力し、これをモニタ上に表
示する。そして、この表示画像内の絵柄の輪郭位置をマ
ウスやライトペンといったポインティングデバイスを用
いて指定してゆき、ポインティングデバイスによって入
力された座標データに基づいて絵柄の輪郭線を決定す
る。そして最後に、この輪郭線データを用いて、入力し
た画像に対する切抜き処理を行い、レイアウトスキャナ
によって切抜き済みの画像をフィルムに出力する。
When making a plate making film from a photo or other manuscript,
It is necessary to cut out only the necessary picture portions in the original image and remove unnecessary background portions. As a method of performing such image clipping processing, a method of image processing using a layout scanner or the like is known. In this clipping method, first, an image of a document is input as digital data by a layout scanner, and this is displayed on a monitor. Then, the contour position of the picture in the display image is designated using a pointing device such as a mouse or a light pen, and the contour of the picture is determined based on the coordinate data input by the pointing device. Finally, a clipping process is performed on the input image using the contour data, and the cutout image is output to a film by a layout scanner.

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

しかしながら、上述した従来の画像切抜き処理で行わ
れている輪郭線決定方法では、輪郭線上の複数の点の位
置を、オペレータがポインティングデバイスによって1
点ずつ指定してゆく作業が必要になる。このため、ポイ
ンティングデバイスの操作が煩雑になり、作業効率が低
いという問題がある。
However, in the outline determination method performed in the above-described conventional image clipping process, the position of a plurality of points on the outline is determined by an operator using a pointing device.
It is necessary to specify each point. Therefore, there is a problem that the operation of the pointing device becomes complicated and the work efficiency is low.

そこで本発明は、輪郭線上の点の位置をコンピュータ
に自動予測させ、オペレータによる点の指定を行うこと
なしに、輪郭線を自動的に決定できる絵柄の輪郭線決定
方法を提供することを目的とする。
Accordingly, an object of the present invention is to provide a method for determining a contour line of a picture that allows a computer to automatically predict the position of a point on the contour line and automatically determine the contour line without designating a point by an operator. I do.

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

本発明は、所定の画素値をもった画素の集合からなる
画像について、この画像に含まれる絵柄の輪郭線を決定
する方法において、 輪郭線上の第1点および第2点を初期点として入力す
る段階と、 この2つの初期点を結ぶ線分の第2点側への延長線上
の所定の画素を起点画素として決定する段階と、 起点画素の周囲に存在する複数の周囲画素のそれぞれ
について、輪郭線上にある画素としての性質の度合いを
示す輪郭関数値を演算する段階と、 ある1つの周囲画素と前述の第2点とを結ぶ線分を求
め、この線分上に位置する周囲画素について与えられた
輪郭関数値の平均を求める演算を、周囲画素の全部ある
いは一部について行い、各周囲画素について求められた
平均に基づいて、輪郭線上で前述の初期点に連なるべき
第3点を決定する段階と、 を行うようにしたものである。
According to the present invention, in a method for determining an outline of a picture included in an image composed of a set of pixels having a predetermined pixel value, a first point and a second point on the outline are input as initial points. A step of determining a predetermined pixel on an extension of the line segment connecting the two initial points to the second point side as a starting pixel; and a step of determining a contour of each of a plurality of peripheral pixels existing around the starting pixel. Calculating a contour function value indicating a degree of property as a pixel on the line; obtaining a line segment connecting a certain surrounding pixel with the second point; The calculation of the average of the obtained contour function values is performed for all or some of the surrounding pixels, and a third point to be connected to the above-mentioned initial point on the contour is determined based on the average obtained for each surrounding pixel. Stage , And.

〔作 用〕(Operation)

本発明による絵柄の輪郭線決定方法では、輪郭線上の
2点を入力すると、この2点に続くべき第3点の位置に
ついての予測演算が行われる。すなわち、まず入力した
2点を結ぶ線分の延長線上に起点を求め、この起点の周
囲に存在する複数の画素の中から最適な画素を選び、こ
の最適画素の位置を第3点についての予測位置とする演
算が行われる。最適画素は輪郭関数値に基づいて決定さ
れるため、本来の輪郭線に沿った最適な第3点位置が予
測できる。このような予測演算を行うようにしたため、
輪郭線上の点の位置をコンピュータに自動予測させ、オ
ペレータによる点の指定を行うことなしに輪郭線を自動
的に決定することができるようになり、作業効率が大幅
に向上する。
In the method for determining a contour line of a picture according to the present invention, when two points on the contour line are input, a prediction calculation is performed for a position of a third point that should follow the two points. That is, first, a starting point is obtained on an extended line of a line connecting two input points, an optimum pixel is selected from a plurality of pixels existing around the starting point, and the position of the optimum pixel is predicted for a third point. An operation to determine the position is performed. Since the optimal pixel is determined based on the contour function value, the optimal third point position along the original contour can be predicted. Since such a prediction operation is performed,
The position of a point on the contour is automatically predicted by a computer, and the contour can be automatically determined without designating a point by an operator, thereby greatly improving work efficiency.

〔実施例〕〔Example〕

以下、本発明を図示する実施例に基づいて説明する。
ここでは、本発明による絵柄の輪郭線決定方法を利用し
た画像切抜き処理を行うことのできる画像レイアウト装
置を実施例として示すことにする。
Hereinafter, the present invention will be described based on the illustrated embodiments.
Here, an image layout apparatus capable of performing an image clipping process using the picture contour line determining method according to the present invention will be described as an embodiment.

装置の全体構成 第1図に、この実施例に係る画像レイアウト装置の基
本構成を示すブロック図を示す。スキャナ装置1は、入
力ドラム1Aと出力ドラム1Bとを有し、入力ドラム1Aに原
稿2をセットすることにより、この原稿2の画像が制御
装置3に取り込まれる。制御装置3には、作図機4が接
続されており、この上には割付台紙5がセットされる。
また、制御装置3には、更に表示装置6、入力装置7、
メモリ8が接続されている。制御装置3は、コンピュー
タによって構成されており、接続された各機器を統括制
御するとともに、画像のレイアウト作業を行う機能を有
する。
Overall Configuration of Apparatus FIG. 1 is a block diagram showing a basic configuration of an image layout apparatus according to this embodiment. The scanner device 1 has an input drum 1A and an output drum 1B. By setting a document 2 on the input drum 1A, an image of the document 2 is taken into the control device 3. A plotting machine 4 is connected to the control device 3, on which the layout sheet 5 is set.
The control device 3 further includes a display device 6, an input device 7,
The memory 8 is connected. The control device 3 is configured by a computer, and has a function of integrally controlling each connected device and a function of laying out images.

この装置による画像のレイアウト作業を第2図の流れ
図に基づいて簡単に説明する。まず、ステップS1におい
て、割付データ入力を行う。これは、作図機4の上に割
付台紙5をセットし、割付データの入力を行う作業であ
る。作図機4はデジタイザを構成しており、ポインティ
ング装置4Aによって割付台紙5上のレイアウト用図形を
トレースすることにより、レイアウト用図形の形状およ
び位置に関する情報を含んだ割付データを入力すること
ができる。なお、作図機4には、コマンド指示部4Bが設
けられており、この入力作業に必要な種々のコマンド入
力を行うことができる。
An image layout operation by this apparatus will be briefly described with reference to the flowchart of FIG. First, in step S1, allocation data is input. This is an operation of setting the layout sheet 5 on the drawing machine 4 and inputting layout data. The plotter 4 constitutes a digitizer, and by tracing the layout graphic on the layout board 5 with the pointing device 4A, it is possible to input layout data including information on the shape and position of the layout graphic. The plotter 4 is provided with a command instructing unit 4B, and can input various commands necessary for this input operation.

続いて、ステップS2において、原稿入力を行う。これ
は、入力ドラム1Aによって原稿2から画像入力を行う作
業であり、原稿2を所定の角度で入力ドラム1A上にセッ
トして走査を行い、画像を所定の倍率でデジタルデータ
として取り込むことになる。この画像データはメモリ8
に格納される。
Subsequently, in step S2, an original is input. This is an operation of inputting an image from the original 2 by the input drum 1A. The original 2 is set on the input drum 1A at a predetermined angle and scanned, and the image is captured as digital data at a predetermined magnification. . This image data is stored in the memory 8
Is stored in

すべての原稿について画像入力が完了すると、ステッ
プS3において、画像位置決め操作を行う。すなわち、ス
テップS1で入力した割付データ内のレイアウト用図形
と、ステップS2で入力した画像とを表示装置6に表示
し、両者の位置合わせを行う。このとき、必要に応じて
画像データに対して変倍処理や回転処理を加えることに
なる。
When image input has been completed for all originals, an image positioning operation is performed in step S3. That is, the layout graphic in the layout data input in step S1 and the image input in step S2 are displayed on the display device 6, and the two are aligned. At this time, scaling processing and rotation processing are added to the image data as necessary.

こうしてすべての画像についての位置決めが完了した
ら、ステップS4において、画像切抜き処理を行うことに
なる。この作業は、位置決めが完了した画像中に含まれ
る絵柄の輪郭線を定義し、この輪郭線の内側あるいは外
側のみを抽出する作業である。本発明は、新規な方法に
よりこの切抜き作業の作業効率を向上させるものであ
り、このステップS4の処理は本発明の特徴となる処理で
ある。そこで、このステップS4の処理については後に詳
述することにする。
When the positioning for all the images is completed in this way, the image clipping process is performed in step S4. This work is to define the outline of the picture included in the image whose positioning has been completed, and to extract only the inside or outside of this outline. The present invention is to improve the work efficiency of this cutting work by a novel method, and the process of step S4 is a process which is a feature of the present invention. Therefore, the processing in step S4 will be described later in detail.

すべての画像についての切抜き作業が完了したら、ス
テップS5において、レイアウト演算処理を行う。これ
は、制御装置3内で実行される演算処理であり、ステッ
プS2で入力した原稿画像から、ステップS3で位置決めし
たレイアウト用図形によって囲まれた部分を抽出し、こ
れを割付台紙5で指示されたとおりの位置に配置する処
理である。なお、ステップS4において、切抜き処理が行
われている場合には、輪郭線に沿って切り抜かれた絵柄
の部分だけが配置されることになる。このようなレイア
ウト演算処理が行われた後の画像データは、メモリ8に
格納されることになる。
When the clipping operation for all the images is completed, a layout calculation process is performed in step S5. This is an arithmetic process executed in the control device 3. The portion surrounded by the layout graphic positioned in step S3 is extracted from the document image input in step S2, and the extracted portion is designated by the layout sheet 5. This is the process of arranging them at the exact positions. In the case where the clipping process is performed in step S4, only the portion of the picture clipped along the contour is arranged. The image data after such a layout calculation process is stored in the memory 8.

最後に、ステップS6において、画像出力を行う。これ
は、レイアウト演算処理後の画像を、出力ドラム1Bから
フィルムに出力する処理である。こうして、所望の原稿
画像内の所望の絵柄を、所望の位置に割り付けるレイア
ウト作業が完了する。
Finally, in step S6, an image is output. This is a process of outputting the image after the layout calculation process from the output drum 1B to a film. In this manner, the layout work for arranging a desired pattern in a desired document image at a desired position is completed.

画像切抜き処理 それでは、本発明の特徴となる画像切抜き処理(第2
図ステップS4)を説明する。この処理では、表示装置6
に第3図に示すような画面が表示される。この画面は、
画像表示部61とコマンド表示部62とに分けられる。画像
表示部61には、切抜き対象となる絵柄を含んだ画像が表
示され、コマンド表示部62には、この切抜き処理を行う
ための種々のコマンドが表示される。この実施例では、
入力装置7としてマウスなどのポインティングデバイス
が用意されており、画像表示部61内の任意の1点を指定
することもできるし、コマンド表示部62に表示された任
意のコマンドを選択指示することもできる。
Image clipping processing Then, the image clipping processing (second
Step S4) will be described. In this processing, the display device 6
A screen as shown in FIG. 3 is displayed. This screen is
It is divided into an image display section 61 and a command display section 62. The image display section 61 displays an image including a picture to be cut out, and the command display section 62 displays various commands for performing the cut-out processing. In this example,
A pointing device such as a mouse is prepared as the input device 7, and any one point in the image display unit 61 can be designated, and any command displayed on the command display unit 62 can be selected and instructed. it can.

さて、ここで切抜き処理の本質的な意味あいを述べて
おく。いま、第4図(a)に示すように、絵柄Zが画像
表示部61に表示されているものとする。図ではこの絵柄
Zの内部にハッチングを施して示してある。このような
絵柄Zは、その輪郭線Zcの位置がデータとして認識され
ているわけではない。画像データは前述のように、入力
ドラム1Aの走査によって得られたラスターデータであ
る。別言すれば、所定の画素値をもった多数の画素の集
合として表現されている。したがって、データ上では、
輪郭線Zcは認識されているわけではない。ここで行う切
抜き処理は、輪郭線Zc上に存在する画素を特定し、輪郭
線Zcをデータとして認識させ、輪郭線Zcを境界として多
数の画素を2つの群に分け、一方の郡に属する画素のみ
を抽出する処理に他ならない。従来、このような切抜き
処理は、オペレータが表示装置6の画面を見ながら、輪
郭線Zc上の点を所定間隔ごとに指定することによって行
っている。たとえば、第4図(b)に示すように、画像
表示部61上で、輪郭線Zc上の点P1〜P6を指定したとする
と、これらの指定点を結ぶ線分によって輪郭線Zcが決定
される。指定点の入力は、マウスによって画面上のカー
ソルCuを移動させ、所望位置にカーソルCuが位置した時
点でマウスボタンを押すことにより、その位置を指定点
として入力することができる。こうして、順次、輪郭線
Zc上の点P1,P2,…を指定点として入力してゆくことによ
り、輪郭線Zcが決定される。もっとも、このような指定
点P1,P2,…を結ぶ線分は、厳密には輪郭線Zcとは完全に
は一致しない。したがって、オペレータは切抜きに必要
な精度が十分得られる間隔で、指定点入力を行うことに
なる。
Now, the essential meaning of the clipping process will be described. Now, it is assumed that the picture Z is displayed on the image display section 61 as shown in FIG. In the figure, the inside of the pattern Z is hatched. In such a pattern Z, the position of the outline Zc is not necessarily recognized as data. As described above, the image data is raster data obtained by scanning the input drum 1A. In other words, it is represented as a set of a large number of pixels having a predetermined pixel value. Therefore, on the data:
The contour line Zc is not recognized. The clipping process performed here specifies pixels existing on the contour Zc, causes the contour Zc to be recognized as data, divides a large number of pixels into two groups with the contour Zc as a boundary, and assigns pixels belonging to one group. It is nothing but a process of extracting only. Conventionally, such cutout processing is performed by an operator designating points on the contour Zc at predetermined intervals while looking at the screen of the display device 6. For example, as shown in FIG. 4 (b), when points P1 to P6 on the contour Zc are designated on the image display unit 61, the contour Zc is determined by a line connecting these designated points. You. The designated point can be input by moving the cursor Cu on the screen with a mouse and pressing the mouse button when the cursor Cu is located at a desired position, thereby inputting that position as the designated point. Thus, sequentially the contour
By inputting points P1, P2,... On Zc as designated points, the contour line Zc is determined. However, the line segment connecting the designated points P1, P2,... Does not exactly match the outline Zc strictly. Therefore, the operator performs the designated point input at intervals at which the accuracy required for the cutting is sufficiently obtained.

ここで、再び第3図を参照する。コマンド領域62に表
示されたコマンドA(内生きマスク)およびコマンドB
(外生きマスク)は、上述した従来の切抜き処理を行う
ためのコマンドである。これらのコマンドモードを選択
した場合、画像表示部61内に示された指定点P1,P2,P3,
…をマウスによって順次入力してゆくことができる。こ
うして、多数の指定点によって閉領域が形成されると、
コマンドAのモードでは、閉領域の内部が絵柄として抽
出されることになり、コマンドBのモードでは、閉領域
の外部が絵柄として抽出されることになる。また、一度
入力した指定点を消去する場合には、コマンドC(指定
点消去)を入力する。これにより、最後に入力された1
指定点が消去される。また、コマンドD(マスク消去)
は、指定した閉領域を消去するコマンドである。
Here, FIG. 3 is referred to again. Command A (in-vivo mask) and command B displayed in command area 62
(External mask) is a command for performing the above-described conventional clipping processing. When these command modes are selected, the designated points P1, P2, P3,
... can be sequentially input by a mouse. Thus, when a closed area is formed by many designated points,
In the command A mode, the inside of the closed area is extracted as a picture, and in the command B mode, the outside of the closed area is extracted as a picture. To delete a designated point that has been input once, a command C (designated point deletion) is input. As a result, the last input 1
The specified point is deleted. Command D (mask erase)
Is a command for erasing the specified closed area.

本発明の装置の特徴は、コマンドE(自動切抜き)お
よびコマンドF(オプション)のモードを更に付加した
点にある。コマンドEのモードを選択すると、指定点の
入力作業が非常に効率的になる。第4図(b)に示した
ように、従来の方法(コマンドA,Bのモードでの動作)
では、オペレータが画像表示部61を見ながら、カーソル
Cuを輪郭線Zc上の適当な位置まで移動させ、マウスボタ
ンを押すという作業を続けてゆかねばならない。コマン
ドEのモードでの動作では、カーソルCuを移動させる作
業が大幅に軽減される。すなわち、ある1指定点の入力
が完了すると、次の指定点として最適な位置にカーソル
Cuが自動的に移動するのである。この動作を、第5図を
参照しながら具体的に説明する。
A feature of the apparatus of the present invention is that a mode of a command E (automatic cutout) and a mode of a command F (option) are further added. When the mode of the command E is selected, the input operation of the designated point becomes very efficient. As shown in FIG. 4 (b), the conventional method (operation in the mode of command A or B)
Then, the operator looks at the image
We have to move the Cu to the appropriate position on the contour line Zc and continue to press the mouse button. In the operation in the mode of the command E, the operation of moving the cursor Cu is greatly reduced. That is, when the input of a certain designated point is completed, the cursor is moved to an optimal position as the next designated point.
Cu moves automatically. This operation will be specifically described with reference to FIG.

いま、第5図(a)に示すように、2つの指定点P1,P
2までが入力されているものとする。コマンドEのモー
ドでは、第2の指定点P2を入力すると、制御装置3が第
3の指定点P3の位置を予測する演算を行い、この予測位
置にカーソルCuを自動的に移動させる。第5図(a)
は、カーソルCuが指定点P2の位置から予測点の位置まで
移動した後の状態を示している。オペレータは、この予
測の位置(すなわち、カーソルCuの移動後の位置)が適
当であるか否かを判断し、適当であると判断した場合に
は、そのままマウスボタンを押し、現在のカーソル位置
を第3の指定点P3の位置として確定させる。第5図
(b)は、この直後の状態を示している。第3の指定点
P3が確定し、カーソルCuは、第4の指定点P4についての
予測点の位置まで自動的に移動されている。オペレータ
が続けてマウスボタンを押せば、このカーソル位置が指
定点P4として確定し、カーソルは更に第5の指定点P5に
ついての予測点の位置まで自動的に移動される。オペレ
ータが、予測点の位置が不適当であると判断した場合に
は、そのままカーソルCuの位置をマウスによって適切な
位置に修正し、マウスボタンを押して修正後の位置を指
定点として確定すればよい。
Now, as shown in FIG. 5 (a), two designated points P1, P
It is assumed that up to 2 has been entered. In the mode of the command E, when the second designated point P2 is input, the control device 3 performs an operation for predicting the position of the third designated point P3, and automatically moves the cursor Cu to this predicted position. Fig. 5 (a)
Shows a state after the cursor Cu has moved from the position of the designated point P2 to the position of the prediction point. The operator determines whether the position of this prediction (that is, the position after the movement of the cursor Cu) is appropriate, and if so, presses the mouse button as it is and changes the current cursor position. The position is determined as the position of the third designated point P3. FIG. 5 (b) shows a state immediately after this. Third designated point
P3 is determined, and the cursor Cu is automatically moved to the position of the prediction point for the fourth designated point P4. If the operator subsequently presses the mouse button, the cursor position is determined as the designated point P4, and the cursor is automatically moved to the position of the predicted point for the fifth designated point P5. When the operator determines that the position of the prediction point is inappropriate, the position of the cursor Cu may be corrected to an appropriate position with a mouse, and the corrected position may be determined as a designated point by pressing a mouse button. .

このように、コマンドEのモードでは、はじめに2つ
の指定点P1,P2を入力すれば、第3の指定点P3以後の各
指定点は、その予測点にカーソルCuが予め移動されるた
め、オペレータの入力作業は非常に楽になる。予測点が
常に適切な位置(最後に確定した指定点に連なる輪郭線
Zc上の位置)を示すような動作が行われれば、オペレー
タはマウスボタンを継続的に押し続ける作業を行うだけ
で、第3の指定点P3以後の各指定点の入力を行うことが
できる。また、予測点が輪郭線Zcからはずれた場合であ
っても、オペレータはマウスの操作により、これを輪郭
線Zc上の位置に修正して次の指定点として入力すること
ができるので、常に正確な作業を行うことができる。必
要があれば、前述したコマンドCを入力することによ
り、一度入力した指定点を消去する操作を行うこともで
きる。なお、コマンドF(オプション)は、前述のコマ
ンドEのモードにおいて予測点を求める演算に用いるパ
ラメータを設定するためのコマンドであり、このパラメ
ータについては後にその都度説明する。また、切抜き処
理が完了したら、コマンドG(操作終了)の入力によっ
て作業は終了する。
As described above, in the mode of the command E, if two designated points P1 and P2 are input first, the designated point after the third designated point P3 is moved to the predicted point by the cursor Cu in advance. The input work becomes very easy. The predicted point is always at the appropriate position (the contour line connected to the last fixed point specified)
(Position on Zc), the operator can input each designated point after the third designated point P3 only by continuing to press and hold the mouse button. Also, even if the predicted point deviates from the contour line Zc, the operator can correct this to a position on the contour line Zc and input it as the next designated point by operating the mouse. Work can be performed. If necessary, by inputting the above-described command C, an operation of deleting the designated point once inputted can be performed. The command F (option) is a command for setting a parameter used in the calculation for obtaining the prediction point in the mode of the command E described above, and this parameter will be described later each time. When the cutout processing is completed, the operation is terminated by inputting the command G (operation end).

続いて、本発明の特徴となるコマンドEのモードにお
ける制御装置3の処理を、第6図の流れ図に基づいて説
明する。まず、ステップS11において、第1点目が入力
される。すなわち、第1の指定点P1が入力されることに
なる。続いて、ステップS12において、第2点目が入力
される。すなわち、第2の指定点P2が入力されることに
なる。本発明の特徴は、このように既に確定した2つの
指定点(これを2つの初期点と呼ぶことにする)に基づ
いて、第3の指定点の位置を予測することにある。そこ
で、ステップS13において、変数iを初期値2に設定す
る。この変数iは、最後に確定した指定点の番号を示す
ものであり、i=2は、指定点P2までが確定しているこ
とを示す。続くステップS14では、第(i−1)点目と
第i点目とに基づき、第(i+1)点目の予測を行う。
すなわち、2つの初期点に基づいて、第3の指定点の位
置の予測が行われる。i=2の場合、第1点目P1と第2
点目P2とに基づき、第3点目P3の位置予測が行われるこ
とになる。そして、ステップS15において、予測点の表
示が行われる。第5図(a)に示す例では、この予測点
はカーソルCuによって表示されている。続くステップS1
6では、第(i+1)点目の入力が行われる。i=2の
場合、第3点目の入力が行われる。この入力は、予測点
の市を利用して行うことになる。すなわち、予測点の位
置をそのまま第3点目P3の位置として良いと判断した場
合には、オペレータはマウスボタンをそのまま押すこと
になり、位置の修正が必要であると判断した場合には、
オペレータはマウスでカーソル位置の修正を行ってから
マウスボタンを押すことになる。いずれにしても、この
段階で第3点目P3の位置が確定する。次のステップS17
では、iが更新される。すなわち、iが1だけ増やさ
れ、i=3となる。更にステップS18において、作業を
終了するか否かが判断され、作業続行の場合には、再び
ステップS14からの手順を繰り返す。今度は、i=3と
なっているので、第2点目P2と第3点目P3とを2つの初
期点として用い、第4点目P4の位置予測が行われること
になる。ステップS15では、第4点目P4についての予測
点が表示され、ステップS16で第4点目P4の位置が確定
する。本発明の特徴は、このように、第(i−1)点目
と第i点目という2つの初期点に基づいて、第(i+
1)点目の予測を行う点にある。なお、このステップS1
4において行われる予測処理の具体例を、以下に詳述す
る。
Next, the processing of the control device 3 in the mode of the command E, which is a feature of the present invention, will be described with reference to the flowchart of FIG. First, in step S11, a first point is input. That is, the first designated point P1 is input. Subsequently, in step S12, a second point is input. That is, the second designated point P2 is input. The feature of the present invention resides in that the position of the third designated point is predicted based on the two designated points that have already been determined in this way (this will be referred to as two initial points). Therefore, in step S13, the variable i is set to the initial value 2. The variable i indicates the number of the last specified point, and i = 2 indicates that up to the specified point P2 has been determined. In the following step S14, the (i + 1) -th point is predicted based on the (i-1) -th point and the i-th point.
That is, the position of the third designated point is predicted based on the two initial points. When i = 2, the first point P1 and the second point P1
Based on the point P2, the position of the third point P3 is predicted. Then, in step S15, a prediction point is displayed. In the example shown in FIG. 5 (a), the predicted point is indicated by the cursor Cu. Next step S1
In 6, the (i + 1) -th point is input. If i = 2, a third point is input. This input is performed using the city of the prediction point. That is, if it is determined that the position of the predicted point can be directly used as the position of the third point P3, the operator presses the mouse button as it is, and if it is determined that the position needs to be corrected,
The operator corrects the cursor position with the mouse and then presses the mouse button. In any case, the position of the third point P3 is determined at this stage. Next step S17
Then, i is updated. That is, i is increased by 1 and i = 3. Further, in step S18, it is determined whether or not to end the operation, and if the operation is to be continued, the procedure from step S14 is repeated again. This time, since i = 3, the second point P2 and the third point P3 are used as two initial points, and the position prediction of the fourth point P4 is performed. In step S15, a predicted point for the fourth point P4 is displayed, and in step S16, the position of the fourth point P4 is determined. The feature of the present invention is that, based on the two initial points of the (i−1) -th point and the i-th point, the (i +
1) The point is to perform the prediction. This step S1
A specific example of the prediction processing performed in 4 will be described in detail below.

輪郭線の予測処理 さて、上述の切抜き処理では、輪郭線上に複数の指定
点P1,P2,P3,…を入力する場合、指定点P1およびP2を初
期点として入力しておけば、指定点P3以後についてはそ
の位置を自動予測させるような動作が可能であることを
述べた。ここでは、2つの初期点に基づいて第3の点を
予測するための具体的な手法の一例を説明する。
Contour Prediction Processing In the above-described cutout processing, when a plurality of designated points P1, P2, P3,... Are input on the contour, if the designated points P1 and P2 are input as initial points, the designated point P3 From then on, it was stated that an operation for automatically predicting the position was possible. Here, an example of a specific method for predicting a third point based on two initial points will be described.

第7図はこの予測処理の手順を示す流れ図である。い
ま、第8図に示すような具体例に即してこの手順を説明
する。第8図において、輪郭線Zcが図のように形成され
ているものとする。前述のように、この輪郭線Zc自体
は、データとして与えられているものではなく、領域Z1
と領域Z2との間の境界として認識されるべきものであ
る。データとして与えられているのは、領域Z1内の各画
素についての画素値と、領域Z2内の各画素についての画
素値と、である。領域Z1内の画素の画素値と、領域Z2内
の画素の画素値との間には大きな差があるため、オペレ
ータは輪郭線Zcを視覚的に認識することができる。
FIG. 7 is a flowchart showing the procedure of the prediction process. Now, this procedure will be described with reference to a specific example as shown in FIG. In FIG. 8, it is assumed that the contour line Zc is formed as shown in the figure. As described above, the contour Zc itself is not given as data, but is stored in the area Z1.
Is to be recognized as the boundary between and Z2. Provided as data are a pixel value for each pixel in the area Z1 and a pixel value for each pixel in the area Z2. Since there is a large difference between the pixel value of the pixel in the area Z1 and the pixel value of the pixel in the area Z2, the operator can visually recognize the outline Zc.

ここで、輪郭線Zc上に第1の指定点Pi−1と第2の指
定点Piとが確定している状態で、第3の指定点Pi+1の
位置を予測する手順を示そう。この手順は、第7図の流
れ図に示すように、3つのステップからなる。すなわ
ち、ステップS21における起点画素決定処理、ステップS
22における周囲画素についての輪郭関数値演算処理、そ
してステップS23における最適画素決定処理である。以
下、これらの各処理について順に説明する。
Here, a procedure for predicting the position of the third designated point Pi + 1 in a state where the first designated point Pi-1 and the second designated point Pi are fixed on the contour Zc will be described. This procedure consists of three steps as shown in the flowchart of FIG. That is, the starting pixel determination processing in step S21,
This is the outline function value calculation processing for the surrounding pixels in 22 and the optimum pixel determination processing in step S23. Hereinafter, each of these processes will be described in order.

(1)起点画素決定 前述までの説明では、指定点を点として取り扱った説
明を行ってきたが、実際には、この指定点は画素に対応
したものである。たとえば、第8図において、指定点Pi
−1、あるいは指定点Piは、この点を中心としてその周
囲に正方形として描かれた画素に対応するものである
(もっとも、第8図では説明の便宜上、1画素をかなり
拡大して描いてある。厳密な意味での輪郭線Zcは、画素
間の境界として定義されるものであるから、第8図に示
すようななめらかな境界線Zcが得られる場合の1画素の
大きさは非常に小さなものでなければならない)。した
がって、以下の説明では、指定点をPi−1、Piと表現す
るとともに、これに対応した画素についても同じ符号を
用い、画素Pi−1、Piと表現することにする。
(1) Determination of Origin Pixel In the above description, a description has been given of a case where a designated point is treated as a point. However, actually, the designated point corresponds to a pixel. For example, in FIG.
-1 or the designated point Pi corresponds to a pixel drawn as a square around this point (however, in FIG. 8, one pixel is drawn considerably enlarged for convenience of explanation). Since the contour line Zc in the strict sense is defined as a boundary between pixels, the size of one pixel when a smooth boundary line Zc as shown in FIG. Must be something). Therefore, in the following description, the designated point is expressed as Pi-1 and Pi, and the corresponding pixels are expressed as the pixels Pi-1 and Pi using the same reference numerals.

さて、第8図において、まず起点Pi+1′が決定され
る。この起点Pi+1′は、第1の指定点Pi−1と第2の
指定点Piとを結ぶ線分の第2の指定点Pi側への延長線上
の点であり、第2の指定点Piから距離di+1′の位置に
ある点として決定される。距離di+1′は、第3の指定
点Pi+1としての予測点と、第2の指定点Piとの間のお
およその距離を決定するパラメータとなる。この距離di
+1′は、所定の定数に設定しておいてもよいし、第1
の指定点Pi−1と第2の指定点Piとの間の距離diに基づ
いて設定することもできる。たとえば、di+1′=diと
設定しておけば、ほぼ等間隔の位置に各指定点が配置さ
れるような予測がなされることになるし、di+1′=2d
iと設定すれば、だんだんと間隔が広がるような位置に
指定点が配置されるような予測がなされることになる。
このように、距離di+1′をパラメータとして設定して
おけば、第1の指定点Pi−1と第2の指定点Piとに基づ
いて、起点Pi+1′は一義的に求まることになる。パラ
メータPi+1′は、第3図で説明したコマンドEによっ
て設定しうるパラメータの1つである。なお、この起点
Pi+1′を中心点にもつ画素(第8図では拡大した正方
形で示す)を同じ符号を用いて起点画素Pi+1′と呼ぶ
ことにする。ステップS21の起点画素決定処理は、この
ようにして起点画素Pi+1′を決める処理である。
In FIG. 8, the starting point Pi + 1 'is first determined. The starting point Pi + 1 'is a point on an extension of the line connecting the first designated point Pi-1 and the second designated point Pi to the second designated point Pi side, and is a point from the second designated point Pi. It is determined as a point at the position of the distance di + 1 '. The distance di + 1 'is a parameter for determining an approximate distance between the prediction point as the third designated point Pi + 1 and the second designated point Pi. This distance di
+1 'may be set to a predetermined constant,
Can be set based on the distance di between the designated point Pi-1 and the second designated point Pi. For example, if di + 1 '= di is set, prediction is performed such that the designated points are arranged at substantially equal intervals, and di + 1' = 2d
If it is set to i, prediction will be made such that the designated point is arranged at a position where the interval gradually increases.
In this way, if the distance di + 1 'is set as a parameter, the starting point Pi + 1' is uniquely determined based on the first designated point Pi-1 and the second designated point Pi. The parameter Pi + 1 'is one of the parameters that can be set by the command E described in FIG. In addition, this starting point
A pixel having Pi + 1 'as a center point (shown by an enlarged square in FIG. 8) is referred to as a starting pixel Pi + 1' using the same reference numerals. The starting pixel determination processing in step S21 is processing for determining the starting pixel Pi + 1 'in this manner.

(2)周囲画素について輪郭関数値演算 輪郭線Zcが直線に近ければ、起点画素Pi+1′はほぼ
輪郭線上にのるため、第3の指定点Pi+1の位置を予測
する画素としてこの起点画素Pi+1′をそのまま用いる
ことができる。しかしながら、輪郭線Zcが常に直線であ
るとは限らない。第8図の例では、輪郭線Zcがカーブし
ているため、第3の指定点Pi+1の位置を予測する画素
としての最適な画素は、図のハッチングを施した画素に
なる。このような最適画素を決定するための準備段階
が、ステップS22の輪郭関数値演算処理である。ここで
輪郭関数値とは、一言で説明すれば、輪郭線上にある画
素としての性質の度合いを示す値であり、起点画素Pi+
1′の周囲に存在する周囲画素のそれぞれについて、こ
の輪郭関数値を求めるのがステップS22の処理である。
続くステップS23では、この各輪郭関数値に基づいて最
適画素を決定することになる。
(2) Contour function value calculation for surrounding pixels If the contour line Zc is close to a straight line, the origin pixel Pi + 1 'is almost on the contour line. Therefore, the origin pixel Pi + 1' is used as a pixel for predicting the position of the third designated point Pi + 1. Can be used as it is. However, the contour line Zc is not always a straight line. In the example of FIG. 8, since the contour line Zc is curved, an optimal pixel as a pixel for predicting the position of the third designated point Pi + 1 is a hatched pixel in the figure. The preparation stage for determining such an optimal pixel is the contour function value calculation processing in step S22. Here, the outline function value is, in short, a value indicating the degree of the property as a pixel on the outline, and the starting point pixel Pi +
The processing of step S22 is to obtain the contour function value for each of the surrounding pixels existing around 1 '.
In the following step S23, an optimum pixel is determined based on each contour function value.

それでは、この輪郭関数値についての理論的な説明を
行おう。いま、第9図に示すような絵柄を考える。輪郭
線Zcによって、2つの領域Z1およびZ2に分けられてい
る。ここで、この輪郭線Zcに対して垂直な方向に切断面
T(図の一点鎖線の位置において、紙面に垂直に立った
面)を作り、この切断面Tにおける画素値の変化を調べ
てみる。第10図は、横軸に切断面T上の横方向位置tを
とり、縦軸にその位置に存在する画素のもつ画素値Q
(t)をとったグラフである。画素値Q(t)は、輪郭
線Zcを境にして大きく変化する。すなわち、第10図のグ
ラフでは、左半分が領域Z1内の画素の画素値を示してお
り、右半分が領域Z2内の画素の画素値を示している。こ
こで、この画素値Q(t)に基づいて、第11図に示すよ
うな画素値関数f(t)を次の(1)式により求める。
Now, let's give a theoretical explanation of this contour function value. Now, consider a pattern as shown in FIG. It is divided into two regions Z1 and Z2 by the contour line Zc. Here, a cut plane T (a plane standing perpendicular to the paper surface at the position of the dashed line in the figure) is formed in a direction perpendicular to the contour line Zc, and changes in pixel values on the cut plane T are examined. . In FIG. 10, the horizontal axis represents the horizontal position t on the cutting plane T, and the vertical axis represents the pixel value Q of the pixel existing at that position.
It is a graph which took (t). The pixel value Q (t) changes greatly around the contour line Zc. That is, in the graph of FIG. 10, the left half shows the pixel values of the pixels in the area Z1, and the right half shows the pixel values of the pixels in the area Z2. Here, based on the pixel value Q (t), a pixel value function f (t) as shown in FIG. 11 is obtained by the following equation (1).

f(t)=Q(t)−M (1) ここで、Mは画素値Q(t)の所定区間内(たとえ
ば、第10図の横軸に表わされた区間内)についての平均
値である。こうして求められた画素値関数f(t)は、
第11図に示すように、値0を中心として正および負の両
側の値をとる関数となる。
f (t) = Q (t) -M (1) Here, M is the average value of the pixel value Q (t) in a predetermined section (for example, in the section shown on the horizontal axis in FIG. 10). It is. The pixel value function f (t) thus obtained is
As shown in FIG. 11, the function takes both positive and negative values around the value 0.

さて、続いて、第12図に示すような輪郭モデル関数fm
(t)を定義しよう。この関数は、 fm(t)=(2u(t)−1) (2) として定義され、関数u(t)は、 u(t)=1(t≧0) (3) u(t)=0(t<0) として定義されるステップ関数である。この輪郭モデル
関数fm(t)は、輪郭線Zcを最も理想的な輪郭線と考え
たときに得られる画素値関数f(t)の究極値に対応す
る。次に、第13図に示すような窓関数w(t)を定義す
る。この関数は、たとえば、 w(t)=exp(−a|t|) (4) として定義される。そして、式(2)で定義される輪郭
モデル関数fm(t)と、式(4)で定義される窓関数w
(t)との積として、次式のような輪郭抽出関数g
(t)を定義する。
Now, subsequently, a contour model function fm as shown in FIG.
Let's define (t). This function is defined as fm (t) = (2u (t) -1) (2), and the function u (t) is expressed as u (t) = 1 (t ≧ 0) (3) u (t) = It is a step function defined as 0 (t <0). This contour model function fm (t) corresponds to the ultimate value of the pixel value function f (t) obtained when the contour Zc is considered as the most ideal contour. Next, a window function w (t) as shown in FIG. 13 is defined. This function is defined as, for example, w (t) = exp (−a | t |) (4). Then, the contour model function fm (t) defined by equation (2) and the window function w defined by equation (4)
As a product of (t), a contour extraction function g such as
(T) is defined.

g(t)=fm(t)・w(t) (5) この輪郭抽出関数g(t)は、第14図に示すような関
数となる。
g (t) = fm (t) .w (t) (5) The contour extraction function g (t) is a function as shown in FIG.

ここで、再び第11図に示す画素値関数f(t)に着目
する。この関数f(t)は、データとして入力されてい
る画像について、実際の値を計算することができる関数
である。たとえば、第9図に示すような画像がデータと
して与えられているのであれば、切断面Tを定めてやる
ことにより、画素値Q(t)が求まり、これから画素値
関数f(t)が計算される。一方、輪郭抽出関数g
(t)は、式(4)における係数aを適当に設定するこ
とにより定義できる関数である。いま、実際のデータか
ら得られた画素値関数f(t)に、予め定義された輪郭
抽出関数g(t)を重ねてみる。輪郭線抽出関数g
(t)についての原点Oを、画素値関数f(t)の横軸
上の点t1の位置に重ねた状態を第15図に、点t0の位置に
重ねた状態を第16図に、それぞれ示す。いずれのグラフ
でも、輪郭線抽出関数g(t)を破線で示してある。こ
こで、重ねた関数の近似の度合いを考えると、第15図よ
りも第16図の方が近似の度合いが大きいと言える。すな
わち、原点Oを点t1に重ねた場合は、関数f(t)と関
数g(t)とはそれほど近似していないが、原点Oを点
t0に重ねた場合は、両関数はかなり近似してくる。この
近似の度合いを示す関数として定義された関数が、輪郭
関数h(t)である。第17図に、この輪郭関数h(t)
の一例を示す。位置t0における関数値h(t0)がピーク
値をとっているのは、関数g(t)の原点Oを関数f
(t)の点t0の上に重ねるようにしたとき(第16図の状
態)に、両関数は最も近似することを示している。ま
た、位置t1における関数値h(t1)の値はかなり低くな
っているが、これは関数g(t)の原点Oを関数f
(t)の点t1の上に重ねるようにしたとき(第15図の状
態)に、両関数の近似の度合いは低下することを示して
いる。このような近似の度合いを示す輪郭関数h(t)
は次のように定義するとよい。
Here, attention is again paid to the pixel value function f (t) shown in FIG. The function f (t) is a function that can calculate an actual value for an image input as data. For example, if an image as shown in FIG. 9 is given as data, a pixel value Q (t) is obtained by defining a cut plane T, and a pixel value function f (t) is calculated from this. Is done. On the other hand, the contour extraction function g
(T) is a function that can be defined by appropriately setting the coefficient a in equation (4). Now, a predefined contour extraction function g (t) is superimposed on a pixel value function f (t) obtained from actual data. Contour extraction function g
FIG. 15 shows a state where the origin O of (t) is overlapped with the position of the point t1 on the horizontal axis of the pixel value function f (t), and FIG. 16 shows a state where it is overlapped with the position of the point t0. Show. In each of the graphs, the contour line extraction function g (t) is indicated by a broken line. Here, considering the degree of approximation of the superimposed functions, it can be said that the degree of approximation is larger in FIG. 16 than in FIG. That is, when the origin O is superimposed on the point t1, the function f (t) and the function g (t) are not very similar, but the origin O is
When overlaid on t0, both functions are fairly similar. A function defined as a function indicating the degree of this approximation is the contour function h (t). FIG. 17 shows this contour function h (t).
An example is shown below. The function value h (t0) at the position t0 has a peak value because the origin O of the function g (t) is
Both functions are most similar when they are superimposed on the point t0 of (t) (the state of FIG. 16). Although the value of the function value h (t1) at the position t1 is considerably low, this is because the origin O of the function g (t) is
This shows that the degree of approximation of both functions is reduced when they are overlaid on the point t1 of (t) (the state of FIG. 15). A contour function h (t) indicating the degree of such approximation
May be defined as:

結局、この輪郭関数h(t)は、輪郭抽出関数g
(t)の原点Oを、画素値関数f(t)の横軸上の位置
tの上に重ねた状態で、両関数の積を積分した相関関数
として定義される。たとえば、t=t1における輪郭関数
値h(t1)は、第15図に示すように、輪郭抽出関数g
(t)の原点Oを、画素値関数f(t)の横軸上の位置
t1の上に重ねた状態で求めた両関数の積を、tの全域
(−∞〜∞)にわたって積分した値となる。
Eventually, this contour function h (t) becomes the contour extraction function g
With the origin O of (t) superimposed on the position t on the horizontal axis of the pixel value function f (t), it is defined as a correlation function obtained by integrating the product of both functions. For example, the contour function value h (t1) at t = t1, as shown in FIG.
The origin O of (t) is defined as the position on the horizontal axis of the pixel value function f (t).
A value obtained by integrating the product of the two functions obtained in a state of being superimposed on t1 over the entire range (−∞ to ∞) of t.

さて、この輪郭関数h(t)は、前述のように、画素
値関数f(t)と輪郭抽出関数g(t)との間の相関関
係を示すものであるが、そもそも輪郭抽出関数g(t)
は、輪郭モデル関数fm(t)に基づいて定義された関数
である。そして、この輪郭モデル関数fm(t)は、理想
的な輪郭線を考えたときの画素値関数に対応し、原点O
の位置がこの理想的な輪郭線の位置ということになる。
したがって、輪郭関数h(t)が示す本質的な意味あい
は、位置tが輪郭線としての性質を示す度合いを数量的
に表現したものということができる。位置tが輪郭線に
近くなるほど大きな値をとる。逆に言えば、輪郭関数h
(t)の値が大きくなった位置に輪郭線が存在すると判
断してよい。したがって、第17図のグラフでは、輪郭関
数h(t)がピーク値をとる位置t0が輪郭線の位置であ
ると判断できる。
As described above, the contour function h (t) indicates the correlation between the pixel value function f (t) and the contour extraction function g (t). In the first place, the contour extraction function g ( t)
Is a function defined based on the contour model function fm (t). The contour model function fm (t) corresponds to a pixel value function when an ideal contour is considered, and the origin O
Is the position of this ideal contour line.
Therefore, the essential meaning of the contour function h (t) can be said to be a numerical representation of the degree to which the position t exhibits the property as a contour line. The value becomes larger as the position t becomes closer to the contour. Conversely, the contour function h
It may be determined that a contour line exists at a position where the value of (t) has increased. Therefore, in the graph of FIG. 17, it can be determined that the position t0 where the contour function h (t) takes a peak value is the position of the contour line.

以上が本発明によって輪郭線の位置を決定する方法の
基本原理である。もう一度、この方法を整理すると、ま
ず、第9図に示すような実際の画像データについて、切
断面Tを決定し、位置を示す軸tを決める。そして、こ
の切断面T上の画素についての画素値をt軸上に並べ、
第10図に示すような画素値Q(t)を得て、これから画
素値関数f(t)を求める。一方では、係数aを設定す
ることにより第13図に示すような窓関数w(t)を定義
し、第12図に示す輪郭モデル関数fm(t)と窓関数w
(t)との積として、輪郭抽出関数g(t)を得る。そ
して、式(6)に基づく演算によって輪郭関数h(t)
を求め、そのピーク値の位置t0を輪郭線の位置とする。
The above is the basic principle of the method for determining the position of the contour line according to the present invention. Once again, this method is organized. First, a cut plane T is determined for actual image data as shown in FIG. 9, and an axis t indicating a position is determined. Then, the pixel values of the pixels on the cut plane T are arranged on the t-axis,
A pixel value Q (t) as shown in FIG. 10 is obtained, and a pixel value function f (t) is obtained therefrom. On the other hand, a window function w (t) as shown in FIG. 13 is defined by setting the coefficient a, and the contour model function fm (t) and the window function w shown in FIG.
As a product of (t), a contour extraction function g (t) is obtained. Then, the contour function h (t) is calculated by an operation based on Expression (6).
And the position t0 of the peak value is set as the position of the contour line.

ところで、窓関数w(t)を定義するために設定する
係数aの役割について述べておく。係数aを小さく設定
した場合、求まる輪郭関数h(t)は第18図(a)に示
すようになだらかなカーブとなる。逆に係数aを大きく
設定した場合、求まる輪郭関数h(t)は第18図(b)
に示すように急峻なカーブとなる。ところが、実際の画
素値関数f(t)には、ノイズ成分が含まれているた
め、実際の輪郭関数h(t)は第19図のようになる。係
数aは小さく設定すれば、輪郭抽出関数g(t)がロー
パスフィルタとして機能してノイズは低減する。ところ
が、ピーク値付近の幅が広くなるため、第19図(a)に
示すように、ピーク値を決定する上での誤差εが大きく
なってしまう。逆に係数aを大きく設定すれば、輪郭抽
出関数g(t)がハイパスフィルタとして機能するた
め、ピーク値付近の幅は狭まるが、ノイズを低減させる
ことができず、やはりピーク値を決定する上での誤差ε
が大きくなってしまう。結局、係数aとしては、第19図
(a)と(b)との間をとるような適当な値を選ぶ必要
がある。また、輪郭線どうしの間隔が狭く、同じ切断面
上に複数の輪郭線が含まれてしまうような場合、輪郭関
数h(t)は第20図のようになる。この場合、係数aを
小さく設定すると、第20図(a)に示すように、輪郭位
置の識別がしにくくなり、係数aを大きく設定すると、
第20図(b)に示すように、ノイズが大きくなってしま
う。したがって、やはり係数aを両者の間の適当な中間
値に設定する必要がある。この係数aも、第3図で説明
したコマンドEによって設定できるパラメータの1つで
ある。
By the way, the role of the coefficient a set for defining the window function w (t) will be described. When the coefficient a is set small, the obtained contour function h (t) has a gentle curve as shown in FIG. 18 (a). Conversely, when the coefficient a is set to be large, the contour function h (t) obtained is as shown in FIG.
As shown in FIG. However, since the actual pixel value function f (t) includes a noise component, the actual contour function h (t) is as shown in FIG. If the coefficient a is set small, the contour extraction function g (t) functions as a low-pass filter to reduce noise. However, since the width near the peak value is widened, the error ε in determining the peak value increases as shown in FIG. 19 (a). Conversely, if the coefficient a is set to be large, the contour extraction function g (t) functions as a high-pass filter, so that the width around the peak value is narrowed, but noise cannot be reduced, and the peak value is also determined. Error ε
Becomes large. Eventually, it is necessary to select an appropriate value for the coefficient a, which takes a value between FIGS. 19 (a) and (b). In the case where the interval between the contour lines is small and a plurality of contour lines are included on the same cut plane, the contour function h (t) is as shown in FIG. In this case, if the coefficient a is set to be small, it becomes difficult to identify the contour position as shown in FIG. 20 (a), and if the coefficient a is set to be large,
As shown in FIG. 20 (b), noise increases. Therefore, it is necessary to set the coefficient a to an appropriate intermediate value between the two. This coefficient a is also one of the parameters that can be set by the command E described in FIG.

以上、輪郭関数値を求めるための理論を説明したが、
続いて、この理論に従った具体的な演算方法の一例を示
す。いま、第21図に示すように、2つの画素Pi−1とPi
とに基づいて、起点画素Pi+1′が決定されているもの
とする。ここで、この起点画素Pi+1′の周囲に存在す
るn×n個の画素を周囲画素として抽出する。この例で
はn=5、すなわち、5×5=25個の画素を周囲画素と
して抽出している(第21図では破線で示す)。この周囲
画素数を決定する数nも、第3図で説明したコマンドE
によって設定できるパラメータの1つである。以後、図
の横方向をx、縦方向をyとして、各画素をPxy(x≧
0,y≧0)なる形式で表現し、更にその周囲画素をPqr
(0≦q≦n−1,0≦r≦n−1)なる形式で表現する
ことにする。たとえば、第21図において、一番上の行の
5つの画素は、P00,P10,P20,P30,P40と表現され、左下
隅の画素はP04、右下隅の画素はP44と表現されることに
なる。
In the above, the theory for obtaining the contour function value has been described.
Next, an example of a specific calculation method according to this theory will be described. Now, as shown in FIG. 21, two pixels Pi-1 and Pi-1
It is assumed that the origin pixel Pi + 1 'is determined based on the above. Here, n × n pixels existing around the starting pixel Pi + 1 ′ are extracted as surrounding pixels. In this example, n = 5, that is, 5 × 5 = 25 pixels are extracted as surrounding pixels (indicated by broken lines in FIG. 21). The number n for determining the number of surrounding pixels is also determined by the command E described in FIG.
Is one of the parameters that can be set. Hereinafter, each pixel is represented by Pxy (x ≧ x), where x is the horizontal direction and y is the vertical direction.
0, y ≧ 0), and the surrounding pixels are represented by Pqr
(0 ≦ q ≦ n−1, 0 ≦ r ≦ n−1). For example, in FIG. 21, the five pixels in the top row are expressed as P00, P10, P20, P30, and P40, the pixel at the lower left corner is expressed as P04, and the pixel at the lower right corner is expressed as P44. Become.

続いて、切断面を決定しなければならない。画素は縦
横に配列されているため、切断面を決定するには、縦方
向と横方向との2とおりの方向がデータ処理効率の面か
らみて有利である。第9図に示したように、切断面T
は、輪郭線Tcに対して直交するような方向に定義するの
が理想的である。そこで、第21図に示すように、画素Pi
と起点画素Pi+1′とを結ぶ線に対して、より直交に近
い角度で交差する方向に切断面をとるようにする。この
例では、横方向に切断面をとることになり、5つの切断
面Y0〜Y4が、一点鎖線で示すように定義される。
Subsequently, the cut plane must be determined. Since the pixels are arranged vertically and horizontally, two directions, that is, the vertical direction and the horizontal direction, are advantageous from the viewpoint of data processing efficiency in determining the cut plane. As shown in FIG.
Is ideally defined in a direction orthogonal to the contour line Tc. Therefore, as shown in FIG.
A cross section is taken in a direction that intersects at a more nearly orthogonal angle with respect to a line connecting the pixel and the origin pixel Pi + 1 ′. In this example, the cutting plane is taken in the horizontal direction, and five cutting planes Y0 to Y4 are defined as shown by dashed lines.

まず、切断面Y0上の5つの画素P00,P10,P20,P30,P40
について、それぞれ輪郭関数値を求めてみる。はじめ
に、画素値関数f(x)を求める(切断面Y0はx軸方向
であるから、この具体例では、画像切断面位置を示す変
数としてtの代わりにxを用いる)。これは、実際に各
画素について与えられた画素値に基づいて容易に求ま
り、たとえば、第22図のような関数f(x)が得られた
ものとする。すなわち、5つの画素P00,P10,P20,P30,P4
0のそれぞれについての画像切断面位置をx0,x1,x2,x3,x
4とすれば、画素値関数の値は、f00,f10,f20,f30,f40と
なる。第22図の画素値関数f(x)は、第11図に示す画
素値関数f(t)に対応するものである。続いて、輪郭
抽出関数g(x)を、たとえば第23図に示すように定義
する。これは第14図に示す輪郭抽出関数g(t)に対応
するものである。第23図の例では、関数g(x)を定義
するのに用いる窓関数w(x)の底を“exp"から“2"に
変更しているので、関数値g1,g2,g3,g4はそれぞれ1/2ず
つに減少してゆく関係になっている。また、関数値はx
軸の正方向、負方向ともに、m番目(この例ではm=
4)の値まで定義している。この関数値が定義がされた
幅を示す値mも、第3図で説明したコマンドEによって
設定できるパラメータの1つである。こうして、2つの
関数f(x)とg(x)が決まれば、この両関数から輪
郭関数h(x)を演算によって求めることができる。具
体的な演算式は次のようになる。
First, five pixels P00, P10, P20, P30, and P40 on the cutting plane Y0
, The contour function value will be obtained for each. First, a pixel value function f (x) is determined (since the cut plane Y0 is in the x-axis direction, in this specific example, x is used instead of t as a variable indicating an image cut plane position). This is easily obtained based on the pixel value actually given for each pixel, and for example, it is assumed that a function f (x) as shown in FIG. 22 is obtained. That is, five pixels P00, P10, P20, P30, P4
X0, x1, x2, x3, x
If it is 4, the values of the pixel value function will be f00, f10, f20, f30, f40. The pixel value function f (x) shown in FIG. 22 corresponds to the pixel value function f (t) shown in FIG. Subsequently, the contour extraction function g (x) is defined, for example, as shown in FIG. This corresponds to the contour extraction function g (t) shown in FIG. In the example of FIG. 23, since the base of the window function w (x) used to define the function g (x) is changed from “exp” to “2”, the function values g1, g2, g3, g4 Have a relationship of decreasing by 1/2 each. The function value is x
Both the positive and negative directions of the axis are m-th (in this example, m =
The values up to 4) are defined. The value m indicating the width in which the function value is defined is also one of the parameters that can be set by the command E described with reference to FIG. When the two functions f (x) and g (x) are determined in this way, the contour function h (x) can be obtained by calculation from these two functions. The specific arithmetic expression is as follows.

ただし、周辺画素Pqrの範囲外におけるf(x)の値
は0とする。この式(7)は、前述の式(6)に対応す
る式であり、切断面Y0上の5つの画素P00,P10,P20,38,P
40について、それぞれ輪郭関数値h(X0),h(X1),h
(X2),h(X3),h(X4)を与える式となる。ここで、こ
れを更に2次元に拡張する。すなわち、切断面Y0につい
て行った演算と同様の演算を、切断面Y1〜Y4についても
行えば、任意の画素Pxyについての輪郭関数値hxyを、
画素関数値fxyを用いて次式により求めることが可能で
ある。
However, the value of f (x) outside the range of the peripheral pixel Pqr is 0. This equation (7) is an equation corresponding to the above-mentioned equation (6), and includes five pixels P00, P10, P20, 38, P on the cut plane Y0.
For 40, the contour function values h (X0), h (X1), h
(X2), h (X3), h (X4). Here, this is further extended to two dimensions. That is, if the same operation as the operation performed on the cut plane Y0 is also performed on the cut planes Y1 to Y4, the contour function value hxy for an arbitrary pixel Pxy is calculated as follows.
It can be obtained by the following equation using the pixel function value fxy.

こうして、第24図に示すように、25個の周囲画素のそ
れぞれについての輪郭関数値hxyを求めたテーブルが得
られる。この輪郭関数値がある程度以上であれば、その
画素は輪郭線上の画素であると判断することができる。
なお、輪郭関数値hxyを求めるために、Pi+1′,a,n,
m、といった各パラメータを用いたが、これらのパラメ
ータは、切り抜く絵柄の細かさに応じて、第3図で説明
したコマンドEによって最適な値に設定することにな
る。
In this way, as shown in FIG. 24, a table is obtained in which the contour function values hxy for each of the 25 surrounding pixels are obtained. If this contour function value is a certain value or more, it can be determined that the pixel is a pixel on the contour line.
In order to obtain the contour function value hxy, Pi + 1 ', a, n,
Although each parameter such as m is used, these parameters are set to optimal values by the command E described in FIG. 3 according to the fineness of the picture to be cut out.

(3)最適画素決定 さて、以上までの作業により、第7図に示す流れ図に
おけるステップS22の輪郭関数値演算処理までが終了し
たことになる。そこで、最後に、ステップS23の最適画
素決定処理を行う。これは、求まった輪郭関数値hxyに
基づいて、この例の場合は25個の周囲画素の中から最適
画素を決定する処理である。すなわち、第25図に示すよ
うに、第1の画素Pi−1、第2の画素Pi、に連なる輪郭
線上の第3の画素となるべき予測画素として最適な画素
を決定する処理ということができる。前述のように、輪
郭関数値hxyは、輪郭線上にある画素としての性質の度
合いを示す値である。この値が大きければ、その画素は
輪郭線に近い位置に存在することになる。したがって、
輪郭関数値が所定値以上であれば、その画素は輪郭線上
に存在すると判断してよい。しかしながら、一般に、周
囲画素の中で輪郭線上に存在すると判断される画素は複
数存在する。そこで、これらの画素の中から、次の2つ
の条件に基づいて第3の画素Pi+1として最適な画素Po
ptを決定する。
(3) Determination of Optimal Pixel By the above operations, the processing up to the contour function value calculation processing in step S22 in the flowchart shown in FIG. 7 has been completed. Therefore, finally, the optimum pixel determination processing in step S23 is performed. This is a process for determining an optimum pixel from among the 25 surrounding pixels in this case based on the obtained contour function value hxy. That is, as shown in FIG. 25, it can be said that a process of determining an optimal pixel as a predicted pixel to be a third pixel on a contour line connected to the first pixel Pi-1 and the second pixel Pi. . As described above, the contour function value hxy is a value indicating the degree of property as a pixel on the contour line. If this value is large, the pixel exists at a position close to the contour line. Therefore,
If the contour function value is equal to or greater than a predetermined value, it may be determined that the pixel exists on the contour line. However, in general, there are a plurality of pixels determined to exist on the contour line among the surrounding pixels. Therefore, from these pixels, based on the following two conditions, the optimum pixel Po + 1 is set as the third pixel Pi + 1.
Determine pt.

<条件1> 第2画素Piと最適画素Poptとの距離ができるだけ長
い。
<Condition 1> The distance between the second pixel Pi and the optimum pixel Popt is as long as possible.

<条件2> 第2の画素Piと最適画素Poptとを結ぶ線が、できるだ
け輪郭線と同一直線上にある。
<Condition 2> A line connecting the second pixel Pi and the optimum pixel Popt is as co-linear as possible with the contour line.

この2条件は次のような意味をもつ。まず条件1は、
切抜き作業の効率を上げるための条件である。第4図
(b)に示すような切抜き作業を行う場合、指定点P1,P
2,…を順次入力してゆくわけであるが、隣接する指定点
間の距離ができるだけ長い方が、1つの閉曲線を指定す
るために必要な指定点の数が少なくなる。別言すれば、
i番目の指定点Piと(i+1)番目の指定点Pi+1との
間の距離がなるべく離れていた方が効率がよい。このた
め、条件1として、第2の画素Piと第3の画素としての
最適画素Poptとの距離ができるだけ長くなるという条件
を設定している。これは、第26図に示すような例を考え
れば容易に理解できよう。第26図において、輪郭線Zc上
の第1点P1と第2点P2とが既に定まっており、第3点P3
としての最適点を決定する場合を考える。ここで、最適
点として、点P3aと点P3bとの2つの候補が挙がったとす
れば、点P2からより離れた点P3bを最適点として選んだ
方が効率的である。
These two conditions have the following meanings. First, condition 1 is
This is a condition for improving the efficiency of the cutting operation. When performing a cutting operation as shown in FIG. 4 (b), the designated points P1, P
2,... Are sequentially input, but when the distance between adjacent designated points is as long as possible, the number of designated points required to designate one closed curve is reduced. In other words,
The efficiency is better if the distance between the i-th designated point Pi and the (i + 1) -th designated point Pi + 1 is as far as possible. Therefore, the condition 1 is set such that the distance between the second pixel Pi and the optimum pixel Popt as the third pixel is as long as possible. This can be easily understood by considering an example as shown in FIG. In FIG. 26, the first point P1 and the second point P2 on the contour Zc have already been determined, and the third point P3
Consider the case where the optimal point is determined. Here, assuming that two candidates of the points P3a and P3b are selected as the optimum points, it is more efficient to select a point P3b farther from the point P2 as the optimum point.

ただ、この距離は長ければ長いほど良いというもので
はない。最適画素Poptをあまり離れた位置に決定する
と、輪郭線が途中で折れ曲がっているような場合には、
輪郭線からはずれてしまう結果になる。これは、第27図
に示すような例を考えれば容易に理解できよう。第27図
において、輪郭線Zc上の第1点P1と第2点P2とが既に定
まっており、第3点P3としての最適点を決定する場合を
考える。ここで、最適点として、点P3aと点P3bとの2つ
の候補が挙がったとする。この場合、点P2からより離れ
た点P3bを最適点として選択してしまうと、積分P2P3b
(図では破線で示す)は区間kにおいて、輪郭線Zcの折
れ曲がり部分からはずれてしまうことになる。したがっ
て、この場合は、点P3aを最適点として選択すべきであ
る。線分P2P3aは輪郭線Zcとほぼ同一直線上にある。こ
れが条件2のもつ意味合いである。
However, the longer this distance is, the better. If the optimal pixel Popt is determined at a position far away, if the contour line is bent in the middle,
The result is a deviation from the contour. This can be easily understood by considering an example as shown in FIG. In FIG. 27, a case is considered where the first point P1 and the second point P2 on the contour line Zc are already determined, and the optimum point as the third point P3 is determined. Here, it is assumed that two candidates, a point P3a and a point P3b, have been selected as optimal points. In this case, if a point P3b further away from the point P2 is selected as the optimum point, the integration P2P3b
(Indicated by a broken line in the drawing) is deviated from the bent portion of the contour Zc in the section k. Therefore, in this case, the point P3a should be selected as the optimum point. Line segment P2P3a is substantially on the same straight line as contour line Zc. This is the meaning of condition 2.

したがって、最適点(最適画素)としては、輪郭線上
に存在すると判断された複数の画素の中から、上述の条
件1および条件2をともに満足するような点(画素)が
選ばれる。この両条件を満足する画素を探すために、次
のような処理を考える。まず、周囲画素のすべてについ
て、第1のパラメータNxyを求める。このパラメータNxy
は、「第2の画素Piと当該画素とを結ぶ線分上に存在す
る周囲画素の総数」として定義される。これを第25図を
参照して説明しよう。たとえば、画素P00についてのパ
ラメータN00を求めてみよう。この場合、第2画素Piか
ら画素P00へ矢印を引き(厳密に言えば、各画素の中心
を結ぶ矢印を引く)、この矢印上に存在する周囲画素の
数を数えればよい。第25図の例では、斜線のハッチング
を施した画素P00およびP10の2つがこれに該当する。し
たがって、画素P00についての第1のパラメータN00の値
は2である。また、画素P22についてのパラメータN22
は、第2の画素Piから画素P22へ矢印を引き、この矢印
上に存在する周囲画素(ドットのハッチングを施した画
素P30,P21,P31,P22)の数を数えれば、N22=4となる。
こうして、すべての周囲画素(この例では25個)につい
て、それぞれ第1のパラメータNxyを求めると、たとえ
ば、第28図に示すようなテーブルが得られる。次に、第
2のパラメータAxyを、「第2の画素Piと当該画素とを
結ぶ線分上に存在する周囲画素の輪郭関数値の総計」と
定義する。これを再び第25図を参照して説明しよう。た
とえば、画素P00についてのパラメータA00を求めてみよ
う。この場合、第2の画素Piから画素P00へ引いた矢印
上の周囲画素(斜線のハッチングを施した画素P00およ
びP10)についての輪郭関数値の和を求めればよい。す
なわち、A00=h00+h10となる。また、画素P22について
のパラメータA22は、第2の画素Piから画素P22へ矢印を
引き、この矢印上に存在する周囲画素(ドットのハッチ
ングを施した画素P30,P21,P31,P22)についての輪郭関
数値の和を求めればよい。すなわち、A22=h30+h21+h
31+h22となる。こうして、すべての周囲画素(この例
では25個)について、それぞれ第2のパラメータAxyを
求めると、たとえば、第29図に示すようなテーブルが得
られる。
Therefore, as the optimal point (optimal pixel), a point (pixel) that satisfies both the above conditions 1 and 2 is selected from a plurality of pixels determined to exist on the contour line. To find a pixel that satisfies both conditions, consider the following processing. First, a first parameter Nxy is obtained for all surrounding pixels. This parameter Nxy
Is defined as “the total number of surrounding pixels existing on a line segment connecting the second pixel Pi and the pixel”. This will be described with reference to FIG. For example, let's find the parameter N00 for the pixel P00. In this case, an arrow is drawn from the second pixel Pi to the pixel P00 (strictly speaking, an arrow connecting the center of each pixel is drawn), and the number of peripheral pixels existing on the arrow may be counted. In the example of FIG. 25, two of the pixels P00 and P10, which are hatched, correspond to this. Therefore, the value of the first parameter N00 for the pixel P00 is 2. Also, the parameter N22 for the pixel P22
Is obtained by drawing an arrow from the second pixel Pi to the pixel P22, and counting the number of surrounding pixels (pixels P30, P21, P31, P22 with hatched dots) existing on the arrow, N22 = 4 .
Thus, when the first parameter Nxy is obtained for all the surrounding pixels (25 in this example), for example, a table as shown in FIG. 28 is obtained. Next, the second parameter Axy is defined as "the total of the contour function values of the surrounding pixels existing on the line segment connecting the second pixel Pi and the pixel". This will be described again with reference to FIG. For example, let's find the parameter A00 for the pixel P00. In this case, the sum of the contour function values for the surrounding pixels on the arrow drawn from the second pixel Pi to the pixel P00 (pixels P00 and P10 hatched with diagonal lines) may be obtained. That is, A00 = h00 + h10. The parameter A22 for the pixel P22 is obtained by drawing an arrow from the second pixel Pi to the pixel P22, and defining the outline of the surrounding pixels (dot-hatched pixels P30, P21, P31, and P22) on the arrow. What is necessary is just to find the sum of the function values. That is, A22 = h30 + h21 + h
31 + h22. Thus, when the second parameter Axy is obtained for all the surrounding pixels (25 in this example), for example, a table as shown in FIG. 29 is obtained.

そこで、第29図のテーブルから、第2のパラメータAx
yがある程度大きな周囲画素を抽出する。たとえば、パ
ラメータAxyの値が上位10%以内に入る周囲画素を候補
として抽出するような方法が可能である。こうすると、
この例の場合、第29図にハッチングを施した3つの周囲
画素P13,P04,P14が抽出される。なお、このような抽出
を行う場合、たとえ上位10%以内に入っていたとして
も、Axyの絶対値が所定値以上でなければ抽出を行わな
いようにするのが好ましい。これにより、輪郭線上にな
い画素が誤って抽出されてしまうことを防ぐことができ
る。このような抽出作業は、前述の条件1を満足する画
素を抽出する作業に他ならない。なぜなら、第2のパラ
メータAxyは、第2の画素Piからその画素に引かれた矢
印が長いほど大きな値をとるため、Axyが大きいほど、
その画素は第2の画素Piから離れた位置にある画素とい
うことが言える。
Then, from the table of FIG. 29, the second parameter Ax
Extract surrounding pixels where y is relatively large. For example, it is possible to adopt a method of extracting surrounding pixels in which the value of the parameter Axy falls within the upper 10% as candidates. In this case,
In the case of this example, three surrounding pixels P13, P04, and P14 hatched in FIG. 29 are extracted. When performing such extraction, it is preferable not to perform extraction unless the absolute value of Axy is equal to or greater than a predetermined value, even if it falls within the top 10%. Thus, it is possible to prevent pixels that are not on the outline from being erroneously extracted. Such an extraction operation is nothing less than an operation of extracting a pixel satisfying the above condition 1. Because the second parameter Axy takes a larger value as the arrow drawn from the second pixel Pi to the pixel is longer, the larger the Axy is,
It can be said that the pixel is a pixel located at a position distant from the second pixel Pi.

さて、条件1を満足する候補が決まったら、これらの
候補について、Axy/Nxyの値を計算する。その結果、次
のようになる。
Now, when candidates satisfying the condition 1 are determined, the values of Axy / Nxy are calculated for these candidates. As a result:

Axy Nxy Axy/Nxy 画素P13 30 6 5 画素P04 32 8 4 画素P14 31 7 4.43 ここで、Axy/Nxyは、「第2の画素Piと当該画素とを
結ぶ線分上に存在する周囲画素の輪郭関数値の平均値」
ということになる。この平均値の最も大きな画素が、条
件2を満足する画素ということになり、最終的に求める
最適画素である。なぜなら、前述のように、輪郭関数値
hxyは、輪郭線上にある画素としての性質の度合いを示
すものであるから、この輪郭関数値hxyの平均値が大き
いような経路は、輪郭線に沿った経路と判断できるから
である。かくして、最適画素はAxy/Nxyが最も大きい画
素P13となる。この条件2についての理論は、第27図の
例を参照すると、より理解が深まるはずである。第27図
において、点P3aの位置にある画素についてのAxy/Nxyの
値と、点P3bの位置にある画素についてのAxy/Nxyの値
と、を比較すると、前者の方が後者よりも大きくなるは
ずである。なぜなら、後者では、輪郭関数値hxyの値が
区間kにおいて小さくなるため、平均値が下がってしま
うためである。こうして、第27図の例においても、2つ
の候補点P3aとP3bのうち、条件2により適合する点、す
なわち、Axy/Nxyの値がより大きな点P3aが最適点として
決定されることになる。
Axy Nxy Axy / Nxy pixel P13 30 65 pixel P04 32 8 4 pixel P14 31 7 4.43 Here, Axy / Nxy is defined as “the outline of a peripheral pixel existing on a line connecting the second pixel Pi and the pixel. Average Function Value "
It turns out that. The pixel having the largest average value is the pixel that satisfies the condition 2, and is the optimal pixel finally obtained. Because, as described above, since the contour function value hxy indicates the degree of the property as a pixel on the contour line, a path in which the average value of the contour function value hxy is large follows the contour line. This is because the route can be determined. Thus, the optimal pixel is the pixel P13 having the largest Axy / Nxy. The theory for Condition 2 should be better understood with reference to the example of FIG. In FIG. 27, comparing the value of Axy / Nxy for the pixel at the position of point P3a with the value of Axy / Nxy for the pixel at the position of point P3b, the former is larger than the latter. Should be. This is because, in the latter case, the value of the contour function value hxy becomes smaller in the section k, so that the average value decreases. Thus, also in the example of FIG. 27, of the two candidate points P3a and P3b, the point that satisfies the condition 2, that is, the point P3a having a larger value of Axy / Nxy is determined as the optimum point.

なお、上述の実施例では、第1のパラメータAxyおよ
び第2のパラメータNxyを、すべての周囲画素(この例
の場合25個)について求めているが、第24図に示すよう
な輪郭関数値hxyについてのテーブルが求まった時点
で、輪郭関数値hxyが所定値以上である画素(すなわ
ち、輪郭線上にあると判断できる画素)だけを抽出して
しまい、この抽出した画素についてのみ、両パラメータ
Axy,Nxyを求める演算を行うようにしてもよい。ただ、
前述のように、輪郭関数値hxyにはノイズ成分が含まれ
ているため、上述の実施例のように、すべての周囲画素
について両パラメータAxy,Nxyを求める演算を行うのが
誤差を少なくする上で好ましい。また、パラメータAxy
の大きさによっていくつかの候補が抽出された後、上述
の実施例では、この候補についてAxy/Nxyを計算し、そ
の値の最も大きな画素を最適画素と決定しているが、抽
出した候補のAxyの値がほぼ等しい場合には、Axy/Nxyな
る演算を行わずに、Nxyの最も小さな画素を最適画素と
決定する方法を採っても良好な結果が得られる。また、
本発明は複数の色版をもったカラー画像についても適用
可能である。この場合は、各色版ごとにパラメータAxy
を求め、その中でAxyの最も大きい値が得られた色版上
で最適画素を決定するようにすればよい。
In the above-described embodiment, the first parameter Axy and the second parameter Nxy are obtained for all surrounding pixels (in this case, 25), but the contour function value hxy as shown in FIG. At the time point when the table is obtained, only the pixels for which the contour function value hxy is equal to or greater than a predetermined value (that is, the pixels that can be determined to be on the contour) are extracted.
The calculation for obtaining Axy and Nxy may be performed. However,
As described above, since the contour function value hxy includes a noise component, performing the calculation for obtaining both parameters Axy and Nxy for all surrounding pixels as in the above-described embodiment reduces the error. Is preferred. Also, the parameter Axy
After several candidates are extracted according to the size of the candidate, in the above-described embodiment, Axy / Nxy is calculated for this candidate, and the pixel having the largest value is determined as the optimal pixel. When the values of Axy are substantially equal, a good result can be obtained even if a method of determining the pixel with the smallest Nxy as the optimum pixel without performing the operation of Axy / Nxy. Also,
The present invention is also applicable to a color image having a plurality of color plates. In this case, the parameter Axy
May be obtained, and the optimum pixel may be determined on the color plate in which the largest value of Axy is obtained.

以上のようにして、第7図の流れ図に示した予測処理
が完了する。こうして、第1点P−iと第2点Piとに基
づいて、第3点Pi+1としての最適な位置を予測するこ
とができる。このような予測処理は、第6図に示した画
像切抜き処理の手順におけるステップS14の処理の一例
として述べたが、それ以外にも種々の用途に利用するこ
とができよう。要するに、この予測処理は、所定の画素
値をもった画素の集合からなる画像について、この画像
に含まれる絵柄の輪郭線を自動的に決定することができ
るものである。すなわち、輪郭線上の第1点および第2
点を初期点として与えてやれば、第3点の位置を自動的
に予測決定することができるのであるから、第4点以降
についても帰納的に予測決定することができる。したが
って、輪郭線に沿った自動切抜き処理をはじめ、輪郭線
の自動決定が必要な種々の処理に応用することができ
る。
As described above, the prediction processing shown in the flowchart of FIG. 7 is completed. Thus, an optimal position as the third point Pi + 1 can be predicted based on the first point Pi and the second point Pi. Such a prediction process has been described as an example of the process of step S14 in the procedure of the image clipping process shown in FIG. 6, but may be used for various other purposes. In short, this prediction process can automatically determine the contour of the picture included in the image composed of a set of pixels having a predetermined pixel value. That is, the first point and the second point on the contour
If a point is given as an initial point, the position of the third point can be automatically predicted and determined, so that the fourth and subsequent points can be predicted and determined recursively. Therefore, the present invention can be applied to various processes that require automatic determination of a contour line, such as automatic cutting processing along a contour line.

〔発明の効果〕〔The invention's effect〕

以上のとおり本発明による絵柄の輪郭線決定方法で
は、輪郭線上の2点に基づいて、この2点に続くべき第
3点の位置についての予測演算を行うようにしたため、
輪郭線上の点の位置をコンピュータに自動予測させ、オ
ペレータによる点の指定を行うことなしに輪郭線を自動
的に決定することができるようになり、作業効率が大幅
に向上する。
As described above, in the pattern outline determination method according to the present invention, the prediction calculation is performed on the position of the third point that should follow the two points based on the two points on the outline.
The position of a point on the contour is automatically predicted by a computer, and the contour can be automatically determined without designating a point by an operator, thereby greatly improving work efficiency.

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

第1図は本発明による輪郭線決定方法を利用した画像切
抜き機能をもつ画像レイアウト装置の基本構成を示すブ
ロック図、第2図は第1図に示す画像レイアウト装置に
よる画像レイアウト処理の手順を示す流れ図、第3図は
第1図に示す装置によって画像切抜き作業を行う場合の
表示画面を示す図、第4図は一般的な輪郭線決定作業に
おける表示画面図、第5図は本発明による輪郭線決定作
業における表示画面図、第6図は本発明の輪郭線決定方
法を利用した画像切抜き処理の手順を示す流れ図、第7
図は本発明の輪郭線決定方法の基本となる予測処理の一
例を示す流れ図、第8図は第7図に示す予測処理の原理
を説明する図、第9図は第7図に示す予測処理の対象と
なる画像の一例を示す図、第10図は第9図に示す画像に
基づいて得られた輪郭部の画素値Q(t)を示すグラ
フ、第11図は第10図に示すグラフに基づいて得られた画
素値関数f(t)を示すグラフ、第12図は予測処理に用
いる輪郭モデル関数fm(t)を示すグラフ、第13図は予
測処理に用いる窓関数w(t)を示すグラフ、第14図は
予測処理に用いる輪郭抽出関数g(t)を示すグラフ、
第15図は輪郭抽出関数g(t)の原点Oを、画素値関数
f(t)における点t1に重ねた状態を示すグラフ、第16
図は輪郭抽出関数g(t)の原点Oを、画素値関数f
(t)における点t0に重ねた状態を示すグラフ、第17図
は予測処理に用いる輪郭関数h(t)を示すグラフ、第
18図(a),(b)は輪郭関数h(t)が、係数aの大
きさによって変化する状態を示すグラフ、第19図
(a),(b)および第20図(a),(b)はノイズ成
分を含んだ輪郭関数h(t)が、係数aの大きさによっ
て変化する状態を示すグラフ、第21図は実際の画素につ
いて予測処理を行う方法を説明する図、第22図は実際の
画素に適用する画素値関数f(x)を示すグラフ、第23
図は実際の画素に適用する輪郭抽出関数g(x)を示す
グラフ、第24図は全周囲画素について求められた輪郭関
数値hxyを示すテーブル、第25図はパラメータNxyおよ
びAxyの求め方を説明する図、第26図は最適画素を決定
するための条件1を説明する図、第27図は最適画素を決
定するための条件2を説明する図、第28図は全周囲画素
について求められたパラメータNxyを示すテーブル、第2
9図は全周囲画素について求められたパラメータAxyを示
すテーブルである。 1……スキャナ、1A……入力ドラム、1B……出力ドラ
ム、2……原稿、3……制御装置、4……作図機、4A…
…ポインティング装置、4B……コマンドメニュー、5…
…割付台紙、6……表示装置、61……画像表示部、62…
…コマンド表示部、7……入力装置、8……メモリ、Cu
……カーソル、T……切断面、Z……絵柄、Z1,Z2……
領域、Zc……輪郭線。
FIG. 1 is a block diagram showing a basic configuration of an image layout apparatus having an image clipping function using a contour line determining method according to the present invention, and FIG. 2 shows a procedure of an image layout process by the image layout apparatus shown in FIG. FIG. 3 is a view showing a display screen when an image cutting operation is performed by the apparatus shown in FIG. 1, FIG. 4 is a display screen view in a general outline determination work, and FIG. 5 is an outline according to the present invention. FIG. 6 is a flowchart showing a procedure of an image clipping process using the contour line determining method of the present invention.
FIG. 9 is a flowchart showing an example of a prediction process which is the basis of the contour determination method of the present invention. FIG. 8 is a diagram for explaining the principle of the prediction process shown in FIG. 7, and FIG. 9 is a prediction process shown in FIG. FIG. 10 is a graph showing the pixel value Q (t) of the contour portion obtained based on the image shown in FIG. 9, and FIG. 11 is a graph shown in FIG. FIG. 12 is a graph showing a contour model function fm (t) used for prediction processing, and FIG. 13 is a window function w (t) used for prediction processing. FIG. 14 is a graph showing a contour extraction function g (t) used in the prediction processing;
FIG. 15 is a graph showing a state where the origin O of the contour extraction function g (t) is superimposed on the point t1 in the pixel value function f (t).
The figure shows the origin O of the contour extraction function g (t) as the pixel value function f
FIG. 17 is a graph showing a state superimposed on a point t0 in (t), FIG. 17 is a graph showing a contour function h (t) used for prediction processing, and FIG.
FIGS. 18 (a) and (b) are graphs showing a state in which the contour function h (t) changes depending on the magnitude of the coefficient a. FIGS. 19 (a) and (b) and FIGS. b) is a graph showing a state in which the contour function h (t) including a noise component changes depending on the magnitude of the coefficient a. FIG. 21 is a diagram for explaining a method of performing prediction processing on actual pixels. Is a graph showing a pixel value function f (x) applied to an actual pixel, and FIG.
FIG. 24 is a graph showing a contour extraction function g (x) applied to actual pixels. FIG. 24 is a table showing contour function values hxy obtained for all surrounding pixels. FIG. FIG. 26 is a diagram for explaining condition 1 for determining an optimum pixel, FIG. 27 is a diagram for explaining condition 2 for determining an optimum pixel, and FIG. 28 is obtained for all surrounding pixels. Table showing the parameter Nxy, the second
FIG. 9 is a table showing parameters Axy obtained for all surrounding pixels. 1 ... Scanner, 1A ... Input drum, 1B ... Output drum, 2 ... Document, 3 ... Control device, 4 ... Drawing machine, 4A ...
... Pointing device, 4B ... Command menu, 5 ...
... Mounting mount, 6 ... Display device, 61 ... Image display unit, 62 ...
... Command display section, 7 ... Input device, 8 ... Memory, Cu
…… Cursor, T …… Cutting plane, Z …… Picture, Z1, Z2 ……
Area, Zc ... Outline line.

───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 平2−101456(JP,A) 特開 昭58−176638(JP,A) (58)調査した分野(Int.Cl.7,DB名) G03F 1/00 - 1/16 ────────────────────────────────────────────────── ─── Continuation of the front page (56) References JP-A-2-101456 (JP, A) JP-A-58-176638 (JP, A) (58) Fields investigated (Int. Cl. 7 , DB name) G03F 1/00-1/16

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】所定の画素値をもった画素の集合からなる
画像について、この画像に含まれる絵柄の輪郭線を決定
する方法であって、 前記輪郭線上の第1点および第2点を初期点として入力
する段階と、 前記2つの初期点を結ぶ線分の前記第2点側への延長線
上の所定の画素を起点画素として決定する段階と、 前記起点画素の周囲に存在する複数の周囲画素のそれぞ
れについて、輪郭線上にある画素としての性質の度合い
を示す輪郭関数値を演算する段階と、 ある1つの周囲画素と前記第2点とを結ぶ線分を求め、
この線分上に位置する周囲画素について与えられた輪郭
関数値の平均を求める演算を、前記周囲画素の全部ある
いは一部について行い、各周囲画素について求められた
前記平均に基づいて、前記輪郭線上で前記初期点に連な
るべき第3点を決定する段階と、 を有することを特徴とする絵柄の輪郭線決定方法。
1. A method for determining an outline of a picture included in an image composed of a set of pixels having a predetermined pixel value, wherein a first point and a second point on the outline are initially set. Inputting as a point; determining a predetermined pixel on an extension of the line connecting the two initial points to the second point side as a starting pixel; and a plurality of surroundings existing around the starting pixel. Calculating, for each of the pixels, a contour function value indicating a degree of property as a pixel on the contour line; and obtaining a line segment connecting a certain surrounding pixel and the second point,
An operation for calculating the average of the contour function values given for the surrounding pixels located on this line segment is performed for all or some of the surrounding pixels, and based on the average obtained for each surrounding pixel, Determining a third point to be connected to the initial point in the step (a).
JP5443790A 1990-03-06 1990-03-06 How to determine the contour of a picture Expired - Lifetime JP3011733B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP5443790A JP3011733B2 (en) 1990-03-06 1990-03-06 How to determine the contour of a picture

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP5443790A JP3011733B2 (en) 1990-03-06 1990-03-06 How to determine the contour of a picture

Publications (2)

Publication Number Publication Date
JPH03256045A JPH03256045A (en) 1991-11-14
JP3011733B2 true JP3011733B2 (en) 2000-02-21

Family

ID=12970687

Family Applications (1)

Application Number Title Priority Date Filing Date
JP5443790A Expired - Lifetime JP3011733B2 (en) 1990-03-06 1990-03-06 How to determine the contour of a picture

Country Status (1)

Country Link
JP (1) JP3011733B2 (en)

Also Published As

Publication number Publication date
JPH03256045A (en) 1991-11-14

Similar Documents

Publication Publication Date Title
EP0172368A2 (en) Method for displaying an image
US4965678A (en) Area designation apparatus in image processing system
JP2003271665A (en) Graphical user interface for retrieval
US20050163368A1 (en) Image processing apparatus and method therefor
JP3011733B2 (en) How to determine the contour of a picture
JP3011732B2 (en) Image cutout processing device
US5302967A (en) Figure processing apparatus and method aided by display with ruled lines
JP3380660B2 (en) Image processing device
JP4748401B2 (en) Screen editing device, screen editing method, and screen editing program
US6208766B1 (en) Process for influencing the quality images furnished by an electronic imaging system
JP3041360B2 (en) Generating moving images
JPH06251115A (en) Image processor
JP2020088507A (en) Image processing apparatus and image processing method
JPH052224B2 (en)
JP3090978B2 (en) Image cutout processing device
JP2934011B2 (en) Image processing method and apparatus
JPH10154040A (en) Image processor
JP3386209B2 (en) Device for rearranging objects displayed on a display screen
JP3381994B2 (en) Display screen switching device
JP3187137B2 (en) Image processing method and apparatus
JPH05108879A (en) Method and device for processing image
JP3026093B2 (en) Image correction method and apparatus
JPH05128302A (en) Character recognition method and apparatus thereof
JPH03276190A (en) Image input/output editing device
JP2791017B2 (en) Area processing method

Legal Events

Date Code Title Description
R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20081210

Year of fee payment: 9

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20091210

Year of fee payment: 10

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20101210

Year of fee payment: 11

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20101210

Year of fee payment: 11