JP3011732B2 - Image cutout processing device - Google Patents
Image cutout processing deviceInfo
- Publication number
- JP3011732B2 JP3011732B2 JP5443690A JP5443690A JP3011732B2 JP 3011732 B2 JP3011732 B2 JP 3011732B2 JP 5443690 A JP5443690 A JP 5443690A JP 5443690 A JP5443690 A JP 5443690A JP 3011732 B2 JP3011732 B2 JP 3011732B2
- Authority
- JP
- Japan
- Prior art keywords
- point
- contour
- pixel
- function
- image
- 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
Links
Landscapes
- Preparing Plates And Mask In Photomechanical Process (AREA)
Description
【発明の詳細な説明】 〔産業上の利用分野〕 本発明は画像切抜き処理装置、特に、写真などの原稿
画像中から背景部分を除いて、必要な絵柄の部分のみを
切り出して製版用フィルムを作成する装置に関する。DETAILED DESCRIPTION OF THE INVENTION [Industrial Application Field] The present invention relates to an image cut-out processing apparatus, and in particular, cuts out only a necessary pattern portion from a document image such as a photograph by removing a background portion, and forms a plate-making film. Related to the device to be created.
写真などの原稿から製版用フィルムを作成する場合、
原稿画像中の必要な絵柄の部分のみを切り出し、不要な
背景部分を除く作業が必要になる。このような画像の切
抜き処理を行う方法として、従来、次のような各方法が
知られている。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. Conventionally, the following methods are known as methods for performing such image clipping processing.
(1)手作業による方法 原稿のフィルム版の上にカットマスクを重ね、カッタ
ーなどを用いて手作業で、カットマスクを絵柄の輪郭線
に沿って切り抜き、マスク版を作成する。(1) Manual Method A cut mask is superimposed on a film plate of an original, and the cut mask is cut out along a contour line of a pattern by a cutter or the like by hand to create a mask plate.
(2)切抜きマスク作成装置を用いた方法 原稿、または原稿のフィルム版を、デジタイザ上に拡
大投影し、この投影画像を見ながら絵柄の輪郭位置を指
定してゆき、デジタイザに入力された座標データに基づ
いてマスク版を作成する。(2) Method using a cut-out mask creating device A manuscript or a film version of a manuscript is enlarged and projected on a digitizer, and a contour position of a picture is designated while viewing the projected image, and coordinate data inputted to the digitizer Create a mask plate based on.
(3)レイアウトスキャナなどを用いた画像処理による
方法 レイアウトスキャナによって、原稿の画像をデジタル
データとして入力し、これをモニタ上に表示する。そし
て、この表示画像内の絵柄の輪郭位置をマウスやライト
ペンといったポインティングデバイスを用いて指定して
ゆき、ポインティングデバイスによって入力された座標
データに基づいてマスクデータを作成する。最後に、こ
のマスクデータを用いて、入力した画像に対する切抜き
処理を行い、レイアウトスキャナによって切抜き済みの
画像をフィルムに出力する。(3) Method of Image Processing Using Layout Scanner or the Like An image of a document is input as digital data by a layout scanner and 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 mask data is created based on the coordinate data input by the pointing device. Finally, a clipping process is performed on the input image using the mask data, and the layout scanner outputs the clipped image to film.
しかしながら、上述した従来の画像切抜き処理方法に
は、いずれにも問題点がある。すなわち、上述(1)の
方法では、作業者の熟練が必要になり、切抜く画像が細
かくなるに従って、作業効率が大幅に低下することにな
る。また、上述(2)および(3)の方法では、作業者
の熟練度は(1)の方法ほど要求されないが、絵柄の輪
郭を1点ずつプロットして指定するという作業が必要に
なる。このため、ポインティングデバイスの操作が煩雑
になり、依然として作業効率が低い。However, any of the above-described conventional image clipping processing methods has problems. That is, in the above-mentioned method (1), the skill of the operator is required, and as the image to be cut out becomes finer, the work efficiency is greatly reduced. In the above methods (2) and (3), the skill of the operator is not required as much as in the method (1), but the work of plotting and designating the outline of the picture one by one is required. Therefore, the operation of the pointing device becomes complicated, and the work efficiency is still low.
そこで本発明は、操作性が良く、作業効率の高い画像
切抜き処理装置を提供することを目的とする。Therefore, an object of the present invention is to provide an image clipping processing device with good operability and high working efficiency.
本発明は、画像切抜き処理装置において、 処理対象となる画像を、画像データとして取り込む画
像入力手段と、 取り込んだ画像データを記憶する記憶手段と、 画像データに基づいて、画像表示を行う画像表示手段
と、 この画像表示手段によって表示された画像の輪郭線上
の1点を指示するための輪郭点指示手段と、 この輪郭点指示手段によって指示された最新の2点に
基づいて、輪郭線上でこの2点に連なる第3の点として
の予測点を求め、この予測点を画像表示手段によって表
示された画像に重ねて表示する予測点表示手段と、 輪郭点指示手段によって指示された複数の輪郭点を結
ぶ線により、画像を切り抜く処理を行う切抜き処理手段
と、 を設け、輪郭点指示手段に、予測点を新たなる指示点と
して取り扱う機能を付加するようにしたものである。The present invention provides an image clipping processing apparatus, comprising: an image input unit for capturing an image to be processed as image data; a storage unit for storing the captured image data; and an image display unit for displaying an image based on the image data. Contour point designating means for designating one point on the contour line of the image displayed by the image display means; and the two latest points designated by the contour point designating means on the contour line. Calculating a predicted point as a third point connected to the point, displaying the predicted point on the image displayed by the image display means, and displaying a plurality of contour points designated by the contour point designating means; And a cutout processing unit for performing a process of cutting out an image by connecting lines, and a function of treating a predicted point as a new designated point is added to the contour point designating unit. It is a thing.
本発明による画像切抜き装置では、輪郭線上の2点を
入力すると、この2点に続くべき第3点の予測点が表示
される。オペレータは、表示を見ながら、予測点の位置
が適当かどうかを判断することができる。そして、適当
であると判断した場合には、輪郭点指示手段によって、
この予測点を新たなる指示点として指示することができ
る。したがって、予測点の位置が適当であれば、オペレ
ータは第3点の位置を指定するために従来のようにポイ
ンティングデバイスを操作する必要はない。このような
点指定が帰納的に順次行われてゆくため、オペレータの
作業は非常に簡単になり、作業効率が大幅に向上する。In the image clipping device according to the present invention, when two points on the contour are input, a third predicted point to be followed by the two points is displayed. The operator can determine whether the position of the prediction point is appropriate while looking at the display. Then, if it is determined to be appropriate, by the contour point indicating means,
This predicted point can be designated as a new designated point. Therefore, if the position of the predicted point is appropriate, the operator does not need to operate the pointing device to specify the position of the third point as in the related art. Since such point designations are sequentially and recursively performed, the work of the operator becomes very simple, and the work efficiency is greatly improved.
以下、本発明を図示する実施例に基づいて説明する。
ここでは、本発明による画像切抜き処理装置を画像レイ
アウト装置の一部に組み込んだ実施例を説明する。Hereinafter, the present invention will be described based on the illustrated embodiments.
Here, an embodiment in which the image cutout processing device according to the present invention is incorporated in a part of an image layout device will be described.
装置の全体構成 第1図に、この実施例に係る画像レイアウト装置の基
本構成を示すブロック図を示す。スキャナ装置1は、入
力ドラム1Aと出力ドラム1Bとを有し、入力ドラム1Aに原
稿2をセットすることにより、この原稿2の画像が制御
装置3に取り込まれる。制御装置3には、作図機が接続
されており、この上には割付台紙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 drawing machine is connected to the control device 3, on which the layout sheet 5 is set. Further, a display device 6, an input device 7, and a memory 8 are connected to the control device 3. 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 line Zc, causes the contour line Zc to be recognized as data, divides a large number of pixels into two groups with the contour line Zc as a boundary, and selects 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 cutout 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 or not the position of the prediction point (that is, the position after the movement of the cursor Cu) is appropriate. If the operator determines that the position is appropriate, the operator presses the mouse button as it is, and presses the current cursor 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 position 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, Means to correct the cursor position with the mouse and then press the mouse button. In any case,
At this stage, the position of the third point P3 is determined. Next steps
In S17, 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, i = 3
Therefore, 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, in the state where the first designated point Pi-1 and the second designated point Pi are fixed on the contour Zc, the third designated point Pi + 1
Here is the procedure to predict the position of 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 an average value of a pixel value Q (t) within a predetermined section (for example, within a 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 the following 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
は、輪郭線Zcに対して直交するような方向に定義するの
が理想的である。そこで、第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 Zc. Therefore, as shown in FIG.
A cross section is taken in a direction that intersects at a more nearly orthogonal angle with 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 in 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,P30,
P40について、それぞれ輪郭関数値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 the five pixels P00, P10, P20, P30,
For P40, 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 the point P3b further away from the point P2 is selected as the optimal point, the line segment 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. When the second parameter Axy is obtained for all the surrounding pixels (25 in this example) in this way, a table as shown in FIG. 29 is obtained, for example.
そこで、第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点Pi−1と第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-1 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.
以上のとおり本発明による画像切抜き装置では、輪郭
線上の2点を入力すると、この2点に続くべき第3点の
予測点が表示され、この予測点をそのまま第3点として
入力することができるため、第3点の位置指定のための
操作が簡単になり、作業効率が大幅に向上する。As described above, in the image clipping device according to the present invention, when two points on the contour line are input, the third predicted point that should follow the two points is displayed, and this predicted point can be directly input as the third point. Therefore, the operation for specifying the position of the third point is simplified, and the working efficiency is greatly improved.
第1図は本発明による画像切抜き装置を画像レイアウト
装置に組み込んだ実施例の基本構成を示すブロック図、
第2図は第1図に示す画像レイアウト装置による画像レ
イアウト処理の手順を示す流れ図、第3図は第1図に示
す装置によって画像切抜き作業を行う場合の表示画面を
示す図、第4図は一般的な画像切抜き作業における表示
画面図、第5図は本発明による画像切抜き作業における
表示画面図、第6図は本発明の装置による画像切抜き処
理の手順を示す流れ図、第7図は第6図の手順のステッ
プS14の予測処理の一例を示す流れ図、第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を
示すテーブル、第29図は全周囲画素について求められた
パラメータ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 embodiment in which an image clipping device according to the present invention is incorporated in an image layout device.
FIG. 2 is a flowchart showing a procedure of an image layout process by the image layout apparatus shown in FIG. 1, FIG. 3 is a view showing a display screen when an image clipping operation is performed by the apparatus shown in FIG. 1, and FIG. FIG. 5 is a display screen diagram of a general image clipping operation, FIG. 5 is a display screen diagram of an image clipping operation according to the present invention, FIG. 6 is a flowchart showing a procedure of an image clipping process by the apparatus of the present invention, and FIG. FIG. 8 is a flowchart showing an example of the prediction process in step S14 of the procedure shown in FIG. 8, FIG. 8 is a diagram for explaining the principle of the prediction process shown in FIG. 7, and FIG. FIG. 10 shows an example, FIG. 10 is a graph showing the pixel value Q (t) of the contour obtained based on the image shown in FIG. 9, and FIG. 11 is obtained based on the graph shown in FIG. Graph showing a pixel value function f (t);
12 is a graph showing a contour model function fm (t) used in the prediction processing, FIG. 13 is a graph showing a window function w (t) used in the prediction processing, and FIG. 14 is a contour extraction function g used in the prediction processing
FIG. 15 is a graph showing (t), 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), and FIG. 16 is a contour extraction function g ( 17 is a graph showing a state in which the origin O of t) is superimposed on the point t0 in the pixel value function f (t). FIG.
18 (a) and 18 (b) are graphs showing the state where the contour function h (t) changes depending on the magnitude of the coefficient a, and FIGS. 19 (a), (b) and FIG. 20 (a),
FIG. 21B 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. The figure shows a pixel value function f (x) applied to actual pixels.
23 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, and FIG. 25 is a parameter Nxy And FIG. 26 is a diagram for explaining how to determine Axy and Axy. FIG. 26 is a diagram for explaining condition 1 for determining an optimum pixel.
FIG. 3 is a diagram for explaining condition 2 for determining an optimum pixel.
FIG. 28 is a table showing parameters Nxy obtained for all surrounding pixels, and FIG. 29 is a table showing parameters Axy obtained for all surrounding pixels. DESCRIPTION OF SYMBOLS 1 ... Scanner device, 1A ... Input drum, 1B ... Output drum, 2 ... Document, 3 ... Control device, 4 ... Drawing machine, 4A
…… Pointing device, 4B …… Command menu, 5
... Layout sheet, 6... Display device, 61... Image display section, 62.
... Command display unit, 7 input device, 8 memory
Cu: Cursor, T: Cut plane, Z: Picture, Z1, Z2 ...
... area, Zc ... outline.
───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 平2−101456(JP,A) 特開 平3−75648(JP,A) 特開 昭60−143341(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-3-75648 (JP, A) JP-A-60-143341 (JP, A) (58) Field (Int.Cl. 7 , DB name) G03F 1/00-1/16
Claims (1)
取り込む画像入力手段と、 取り込んだ画像データを記憶する記憶手段と、 前記画像データに基づいて、画像表示を行う画像表示手
段と、 前記画像表示手段によって表示された画像の輪郭線上の
1点を指示するための輪郭点指示手段と、 前記輪郭点指示手段によって指示された最新の2点に基
づいて、前記輪郭線上でこの2点に連なる第3の点とし
ての予測点を求め、この予測点を前記画像表示手段によ
って表示された画像に重ねて表示する予測点表示手段
と、 前記輪郭点指示手段によって指示された複数の輪郭点を
結ぶ線により、前記画像を切り抜く処理を行う切抜き処
理手段と、 を備え、前記輪郭点指示手段が、前記予測点を新たなる
指示点として取り扱う機能を有することを特徴とする画
像切抜き処理装置。An image input unit for capturing an image to be processed as image data; a storage unit for storing the captured image data; an image display unit for displaying an image based on the image data; Contour point designating means for designating one point on the contour line of the image displayed by the display means; and connecting the two points on the contour line based on the latest two points designated by the contour point designating means. Calculating a predicted point as a third point and connecting the plurality of contour points designated by the contour point designating means to a predicted point display means for displaying the predicted point superimposed on the image displayed by the image display means; And a cutout processing unit that cuts out the image with a line, wherein the contour point designating unit has a function of treating the predicted point as a new designated point. Image cutout processing device for a.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP5443690A JP3011732B2 (en) | 1990-03-06 | 1990-03-06 | Image cutout processing device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP5443690A JP3011732B2 (en) | 1990-03-06 | 1990-03-06 | Image cutout processing device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPH03256046A JPH03256046A (en) | 1991-11-14 |
| JP3011732B2 true JP3011732B2 (en) | 2000-02-21 |
Family
ID=12970660
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP5443690A Expired - Lifetime JP3011732B2 (en) | 1990-03-06 | 1990-03-06 | Image cutout processing device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP3011732B2 (en) |
-
1990
- 1990-03-06 JP JP5443690A patent/JP3011732B2/en not_active Expired - Lifetime
Also Published As
| Publication number | Publication date |
|---|---|
| JPH03256046A (en) | 1991-11-14 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| EP0179373B1 (en) | Method of processing picture data for printing process | |
| EP0172368A2 (en) | Method for displaying an image | |
| JPH118814A (en) | Digital photo processing system | |
| US20050163368A1 (en) | Image processing apparatus and method therefor | |
| US20050207646A1 (en) | Image processing method, apparatus therefor and memory medium storing program | |
| JP3011732B2 (en) | Image cutout processing device | |
| JP3011733B2 (en) | How to determine the contour of a picture | |
| JP4748401B2 (en) | Screen editing device, screen editing method, and screen editing program | |
| US5302967A (en) | Figure processing apparatus and method aided by display with ruled lines | |
| JPH09147102A (en) | Image processor | |
| JP3041360B2 (en) | Generating moving images | |
| JP3065364B2 (en) | Cutout mask making method and apparatus | |
| JP3090978B2 (en) | Image cutout processing device | |
| JPH08202856A (en) | Image processing method | |
| JP2000165639A (en) | Image processing apparatus and method, computer readable memory | |
| JPH052224B2 (en) | ||
| JP2863166B2 (en) | Magnification setting device for image reading device | |
| JPH08204944A (en) | Image processing device and copier | |
| JP3187137B2 (en) | Image processing method and apparatus | |
| JPH05108879A (en) | Method and device for processing image | |
| JP3381994B2 (en) | Display screen switching device | |
| JP2934011B2 (en) | Image processing method and apparatus | |
| JPH05128302A (en) | Character recognition method and apparatus thereof | |
| JPH06314326A (en) | Electronic file device | |
| JP2695815B2 (en) | Typesetting display device |
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 |