JP2002336188A - Endoscope system for measurement - Google Patents

Endoscope system for measurement

Info

Publication number
JP2002336188A
JP2002336188A JP2001151092A JP2001151092A JP2002336188A JP 2002336188 A JP2002336188 A JP 2002336188A JP 2001151092 A JP2001151092 A JP 2001151092A JP 2001151092 A JP2001151092 A JP 2001151092A JP 2002336188 A JP2002336188 A JP 2002336188A
Authority
JP
Japan
Prior art keywords
image
algorithm
scale
coordinates
measurement
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.)
Withdrawn
Application number
JP2001151092A
Other languages
Japanese (ja)
Inventor
Katsumi Hirakawa
克己 平川
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.)
Olympus Corp
Original Assignee
Olympus Optical Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Olympus Optical Co Ltd filed Critical Olympus Optical Co Ltd
Priority to JP2001151092A priority Critical patent/JP2002336188A/en
Publication of JP2002336188A publication Critical patent/JP2002336188A/en
Withdrawn legal-status Critical Current

Links

Landscapes

  • Testing, Inspecting, Measuring Of Stereoscopic Televisions And Televisions (AREA)
  • Image Analysis (AREA)
  • Instruments For Viewing The Inside Of Hollow Bodies (AREA)
  • Endoscopes (AREA)
  • Processing Or Creating Images (AREA)
  • Image Processing (AREA)
  • Closed-Circuit Television Systems (AREA)

Abstract

PROBLEM TO BE SOLVED: To grasp a distance from a subject and present data by displaying a three-dimensional image. SOLUTION: An endoscope system is equipped with a stereoscopic video image endoscope (hereinbelow referred to as an endoscope) 301, video processors 310L and 310R for processing the respective image signals of left and right images picked up by the endoscope 301 and a host computer 311 for storing the RGB signals outputted from the video processors 310L and 310R to apply gradation drawing processing to them.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は観察対象を立体視可
能な計測用内視鏡装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a measurement endoscope apparatus capable of stereoscopically observing an observation object.

【0002】[0002]

【従来の技術】近年、内視鏡の視差を持つ位置に2系統
の撮像手段を設けて立体感のある視野を得るようにした
立体内視鏡装置が、例えば特開平2−119836号公
報等に種々提案されている。
2. Description of the Related Art In recent years, a stereoscopic endoscope apparatus in which two systems of image pickup means are provided at a position having a parallax of an endoscope so as to obtain a visual field having a three-dimensional effect is disclosed in, for example, Japanese Patent Application Laid-Open No. 2-119936. Various proposals have been made.

【0003】また、立体映像の観察のため、あるいは、
バーチャルリアリティ装置のディスプレイとして用いる
ために、頭部に装着して使用する両眼視眼鏡型ディスプ
レイ(ヘッドマウントディスプレイとも呼ばれる)が、
開発され、例えば特開平11−69383号公報等で
は、このヘッドマウントディスプレイからなる立体表示
装置を医療分野に応用した立体表示装置を提案してい
る。
[0003] For observation of stereoscopic images, or
In order to use it as a display of a virtual reality device, a binocular spectacle type display (also called a head mounted display) used by wearing it on the head,
For example, Japanese Patent Application Laid-Open No. 11-69383 proposes a stereoscopic display device in which the stereoscopic display device including the head mounted display is applied to the medical field.

【0004】[0004]

【発明が解決しようとする課題】特開平11−6938
3号公報の問題点は、 ・左右の画像に単に機器情報を描画しているだけなの
で、実際には、融像合限界を超えた視差を持ち機器情報
は立体視できないこともありうる。その場合、機器情報
が内視鏡画像の立体視の妨げになる可能性がある。ま
た、このとき内視鏡画像の立体視を行う場合と、機器情
報の立体視を行う場合で、ユーザが立体視用の機器を調
整する必要が生じ、ユーザに付加的な作業を強いること
になる。
Problems to be Solved by the Invention
The problems of the third publication are as follows: Since the device information is simply drawn on the left and right images, the device information may have a parallax exceeding the fusion limit and may not be stereoscopically viewed. In that case, the device information may hinder the stereoscopic viewing of the endoscope image. Also, at this time, when performing stereoscopic viewing of the endoscope image and when performing stereoscopic viewing of the device information, it is necessary for the user to adjust the device for stereoscopic viewing, and the user is forced to perform additional work. Become.

【0005】特開平2−119836号公報は以下のこ
とが問題であった。
Japanese Patent Application Laid-Open No. 2-119836 has the following problems.

【0006】・立体的に見えるカーソルを表示するだけ
ではカーソルと対象との位置関係を把握することは困難
な場合があるが、それを補助する手段がないこと。 ・カーソルを動かし、計測行為を行わないと対象の大き
さを把握できないこと。
It is sometimes difficult to grasp the positional relationship between the cursor and the object only by displaying a three-dimensionally visible cursor, but there is no means for assisting this.・ The size of the target cannot be grasped unless the cursor is moved and measurement is not performed.

【0007】(本発明の目的)請求項1の目的は、立体
的に見える図形を表示し、対象との距離の把握、情報の
提示及び、表示図形の視差の確認等を行うことである。
An object of the present invention is to display a figure which looks three-dimensional, grasp the distance to an object, present information, and confirm the parallax of the displayed figure.

【0008】請求項2の目的は、対象までの距離に応じ
た目盛を表示することにより、対象の大きさを把握でき
るようにすることである。
A second object of the present invention is to make it possible to grasp the size of an object by displaying a scale corresponding to the distance to the object.

【0009】請求項3の目的は、立体的に見える図形を
複数表示することにより、対象と図形との位置関係の把
握を容易にすることである。
A third object of the present invention is to make it easy to grasp the positional relationship between the object and the graphic by displaying a plurality of three-dimensional graphics.

【0010】請求項4の目的は、対象までの距離に応じ
て、図形の表示を停止する手段を提供することである。
A fourth object of the present invention is to provide means for stopping the display of a graphic according to the distance to the object.

【0011】請求項5の目的は、立体視した状態におい
て、入力に応じて所定の処理を実行する手段を提供する
ことである。
A fifth object of the present invention is to provide a means for executing a predetermined process according to an input in a stereoscopic state.

【0012】請求項6の目的は、立体視した状態におい
て、視野内を指定することにより、指定場所に応じた処
理を実行する手段を提供することである。
It is an object of the present invention to provide a means for executing a process corresponding to a designated place by designating an inside of a field of view in a stereoscopic state.

【0013】請求項7の目的は、立体視した状態におい
て、視野内に表示する図形のパラメータを変更し、パラ
メータにしたがって図形を表示する手段を提供すること
である。
It is an object of the present invention to provide a means for changing a parameter of a figure to be displayed in a visual field in a stereoscopic state and displaying the figure according to the parameter.

【0014】請求項8の目的は、立体視した状態におい
て、入力処理装置に入力された情報を視野内に表示し、
確認する手段を提供することである。
An object of the present invention is to display information input to the input processing device in a visual field in a stereoscopic state,
It is to provide a means to confirm.

【0015】請求項9の目的は、立体視した状態におい
て、指定領域を計測する手段を提供することである。
An object of a ninth aspect is to provide means for measuring a designated area in a stereoscopic state.

【0016】[0016]

【課題を解決するための手段】本発明の計測用内視鏡装
置は、所定の観察対象を第1の撮像手段で撮像して得ら
れる第1の画像と、前記第1の撮像手段とは異なる方向
から前記所定の観察対象を第2の撮像手段で撮像して得
られた第2の画像とをそれぞれ表示する立体視可能な計
測用内視鏡装置において、前記第1の撮像手段または前
記第2の撮像手段のいずれか一方と仮想的または実際の
対象物までの距離を設定する距離設定手段と、前記第1
の撮像手段によって得られた画像と前記第2の撮像手段
によって得られた画像において前記対象物の同一点が撮
像されている対応点を求める対応点決定手段と、前記対
象物までの前記距離に応じた図形を少なくとも一つの前
記対応点に描画する図形描画手段と前記対応点の視差を
導出し視差を検査する検査手段とを有して構成される。
According to the measurement endoscope apparatus of the present invention, a first image obtained by capturing an image of a predetermined observation target with a first image capturing means and the first image capturing means are different from each other. In a measurement endoscope apparatus capable of stereoscopic viewing, each of which displays a second image obtained by imaging the predetermined observation target from a different direction with a second imaging unit, the first imaging unit or the first imaging unit A distance setting means for setting a distance between one of the second imaging means and a virtual or actual object;
Corresponding point determining means for finding a corresponding point at which the same point of the object is imaged in the image obtained by the image capturing means and the image obtained by the second image capturing means; The apparatus comprises a figure drawing means for drawing a corresponding figure on at least one of the corresponding points, and an inspection means for deriving a parallax of the corresponding point and inspecting the parallax.

【0017】[0017]

【発明の実施の形態】以下、図面を参照しながら本発明
の実施の形態について述べる。
Embodiments of the present invention will be described below with reference to the drawings.

【0018】図1ないし図34は本発明の第1の実施の
形態に係わり、図1は内視鏡装置の構成を示す構成図、
図2は図1のホストコンピュータの構成を示すブロック
図、図3は図1の内視鏡の先端部の構成を示す構成図、
図4は図1の内視鏡の撮像系における座標系を説明する
図、図5は図1の内視鏡の歪曲収差補正を説明する第1
の図、図6は図1の内視鏡の歪曲収差補正を説明する第
2の図、図7は図2のホストコンピュータの作用を説明
する第1の図、図8は図2のホストコンピュータの作用
を説明する第2の図、図9は図2のホストコンピュータ
の作用を説明する第3の図、図10は図2のホストコン
ピュータの作用を説明する第4の図、図11は図2のホ
ストコンピュータにより処理されるメイン処理の流れを
示す第1のフローチャート、図12は図2のホストコン
ピュータにより処理されるメイン処理の流れを示す第2
のフローチャート、図13は図11及び図12のメイン
処理で使用されるアルゴリズムAの処理の流れを示すフ
ローチャート、図14は図11及び図12のメイン処理
で使用されるアルゴリズムBの処理の作用を説明する第
1の図、図15は図11及び図12のメイン処理で使用
されるアルゴリズムBの処理の作用を説明する第2の
図、図16は図11及び図12のメイン処理で使用され
るアルゴリズムA’の処理の流れを示すフローチャー
ト、図17は図11及び図12のメイン処理で使用され
るアルゴリズムBの処理の流れを示すフローチャート、
図18は図11及び図12のメイン処理で使用されるア
ルゴリズムCの処理の流れを示すフローチャート、図1
9は図18のアルゴリズムCの処理の作用を説明する第
1の図、図20は図18のアルゴリズムCの処理の作用
を説明する第2の図、図21は図11及び図12のメイ
ン処理で使用されるアルゴリズムDの処理の流れを示す
フローチャート、図22は図21のアルゴリズムDの処
理の作用を説明する第1の図、図23は図21のアルゴ
リズムDの処理の作用を説明する第2の図、図24は図
11及び図12のメイン処理で使用されるアルゴリズム
Eの処理の流れを示すフローチャート、図25は図24
のアルゴリズムEの処理の作用を説明する第1の図、図
26は図24のアルゴリズムEの処理の作用を説明する
第2の図、図27は図11及び図12のメイン処理で使
用されるアルゴリズムFの処理の流れを示すフローチャ
ート、図28は図27のアルゴリズムFの処理の作用を
説明する第1の図、図29は図27のアルゴリズムFの
処理の作用を説明する第2の図、図30は図11及び図
12のメイン処理で使用されるアルゴリズムGの処理の
流れを示すフローチャート、図31は図30のアルゴリ
ズムGの処理の作用を説明する第1の図、図32は図3
0のアルゴリズムGの処理の作用を説明する第2の図、
図33は図11及び図12のメイン処理で使用されるア
ルゴリズムHの処理の流れを示す第1のフローチャー
ト、図34は図11及び図12のメイン処理で使用され
るアルゴリズムHの処理の流れを示す第2のフローチャ
ートである。
FIGS. 1 to 34 relate to a first embodiment of the present invention. FIG. 1 is a configuration diagram showing a configuration of an endoscope apparatus.
2 is a block diagram showing a configuration of the host computer of FIG. 1, FIG. 3 is a configuration diagram showing a configuration of a distal end portion of the endoscope of FIG. 1,
FIG. 4 is a view for explaining a coordinate system in the imaging system of the endoscope in FIG. 1, and FIG. 5 is a first view for explaining distortion correction of the endoscope in FIG.
6, FIG. 6 is a second diagram for explaining the distortion correction of the endoscope in FIG. 1, FIG. 7 is a first diagram for explaining the operation of the host computer in FIG. 2, and FIG. 8 is a host computer in FIG. FIG. 9 is a third diagram illustrating the operation of the host computer of FIG. 2, FIG. 10 is a fourth diagram illustrating the operation of the host computer of FIG. 2, and FIG. FIG. 12 is a first flowchart showing a flow of main processing performed by the host computer of FIG. 2, and FIG. 12 is a second flowchart showing a flow of main processing processed by the host computer of FIG.
FIG. 13 is a flowchart showing the flow of processing of algorithm A used in the main processing of FIGS. 11 and 12, and FIG. 14 shows the operation of processing of algorithm B used in the main processing of FIGS. 11 and 12. FIG. 15 is a first diagram for explaining the operation, and FIG. 15 is a second diagram for explaining the operation of the algorithm B used in the main process in FIGS. 11 and 12, and FIG. 16 is a diagram used in the main process in FIGS. 17 is a flowchart showing the flow of processing of algorithm A ′, FIG. 17 is a flowchart showing the flow of processing of algorithm B used in the main processing of FIGS. 11 and 12,
FIG. 18 is a flowchart showing the flow of processing of algorithm C used in the main processing of FIGS. 11 and 12, and FIG.
9 is a first diagram illustrating the operation of the process of the algorithm C in FIG. 18, FIG. 20 is a second diagram illustrating the operation of the process of the algorithm C in FIG. 18, and FIG. 21 is the main process of FIGS. FIG. 22 is a flowchart showing the operation of algorithm D in FIG. 21, and FIG. 23 is a flowchart showing the operation of algorithm D in FIG. 21. 2 and FIG. 24 are flowcharts showing the processing flow of the algorithm E used in the main processing of FIGS. 11 and 12, and FIG.
FIG. 26 is a second diagram illustrating the operation of the algorithm E of FIG. 24, and FIG. 27 is used in the main process of FIG. 11 and FIG. 27 is a flowchart showing the flow of the processing of the algorithm F, FIG. 28 is a first diagram illustrating the operation of the process of the algorithm F in FIG. 27, FIG. 29 is a second diagram illustrating the operation of the process of the algorithm F in FIG. FIG. 30 is a flowchart showing the flow of processing of the algorithm G used in the main processing of FIGS. 11 and 12, FIG. 31 is a first diagram for explaining the operation of the processing of the algorithm G of FIG. 30, and FIG.
FIG. 2 is a second diagram for explaining the operation of the processing of the algorithm G of 0;
FIG. 33 is a first flowchart showing the flow of processing of algorithm H used in the main processing of FIGS. 11 and 12, and FIG. 34 shows the flow of processing of algorithm H used in the main processing of FIGS. 11 and 12. It is a 2nd flowchart shown.

【0019】本実施の形態の内視鏡装置は、図1に示す
ように、ステレオ式ビデオイメージエンドスコープ(以
下、内視鏡と記す)301と、この内視鏡301によっ
て撮像される左画像および右画像の各画像信号を信号処
理するビデオプロセッサ310L および310Rと、
前記各ビデオプロセッサ310L、310Rから出力さ
れるRGB信号を記憶し、目盛描画処理などを行うホス
トコンピュータ311と、前記ビデオプロセッサ310
L、310RのRGB信号による映像信号を入力し、左
画像、右画像を表示する観察モニタ312L、312R
と、ホストコンピュータ311に接続され、パラメー
タの入力などを行うマウス331と、ホストコンピュー
タ311に接続され、パラメータの入力などを行うキー
ボード332と、ホストコンピュータ311で処理した
左画像および、右画像を表示するヘッドマウントディス
プレイ313を備え、前記ビデオプロセッサ312L、
312Rは、互いに同期した信号処理を行うようになっ
ている。
As shown in FIG. 1, the endoscope apparatus according to the present embodiment has a stereo video image endoscope (hereinafter, referred to as an endoscope) 301 and a left image captured by the endoscope 301. And video processors 310L and 310R for processing each image signal of the right and right images,
A host computer 311 for storing RGB signals output from the video processors 310L and 310R and performing scale drawing processing and the like;
L, 310R video signals based on RGB signals are input, and an observation monitor 312L, 312R that displays a left image and a right image
A mouse 331 connected to the host computer 311 for inputting parameters and the like; a keyboard 332 connected to the host computer 311 for inputting parameters and the like; and a left image and a right image processed by the host computer 311 are displayed. The video processor 312L,
The 312R performs signal processing synchronized with each other.

【0020】前記ホストコンピュータ311は、図2に
示すように構成されている。すなわち、ホストコンピュ
ータ311は、ホストバス329に接続されているCP
U321および、メインメモリ322、ローカルバス3
30に接続されている左画像用画像入出力ボード324
L、右画像用画像入出力ボード324R、周辺機器イン
タフェース326、327、ビデオボード328を備え
ている。
The host computer 311 is configured as shown in FIG. That is, the host computer 311 communicates with the CP connected to the host bus 329.
U321, main memory 322, local bus 3
Image input / output board 324 for the left image connected to 30
L, an image input / output board for right image 324R, peripheral device interfaces 326 and 327, and a video board 328.

【0021】ホストバス329とローカルバス330
は、ホストーローカルブリッジ323により接続され、
ホストーローカルブリッジ323を介してデータ転送を
行う。
The host bus 329 and the local bus 330
Are connected by a host-local bridge 323,
Data transfer is performed via the host-local bridge 323.

【0022】画像入出力ボード324Lおよび、324
Rは、画像キャプチャー機能および、ビデオ出力機能を
有し、画像キャプチャー時、およびビデオ出力時には、
それぞれボード上に存在する図示しないメモリ334
L、334Rに画像を一時的に保存する。
Image input / output boards 324L and 324
R has an image capture function and a video output function, and at the time of image capture and video output,
A memory 334 (not shown) existing on each board
L, 334R to temporarily store the image.

【0023】左画像用画像入出力ボード324Lは、左
画像用ビデオプロセッサ310Lに接続され、図示しな
いボード上のメモリ334Lに取り込んだ左画像をメイ
ンメモリ322に転送する。右画像用画像入出力ボード
324Rは、右画像用ビデオプロセッサ310R に接
続され、図示しないボード上のメモリ334Rに取り込
んだ右画像をメインメモリ322に転送する。
The left image input / output board 324L is connected to the left image video processor 310L, and transfers the left image taken into the memory 334L on the board (not shown) to the main memory 322. The right image image input / output board 324R is connected to the right image video processor 310R, and transfers the right image captured in the memory 334R on the board (not shown) to the main memory 322.

【0024】CPU321は、メインメモリ322に転
送された左画像、右画像に目盛描画などの処理を行っ
て、左画像を左画像用画像入出力ボード324L、右画
像を右画像用画像入出力ボード324Rに転送し、ヘッ
ドマウントディスプレイ313に表示することができ
る。
The CPU 321 performs processing such as scale drawing on the left image and the right image transferred to the main memory 322, and converts the left image into a left image image input / output board 324L and the right image into a right image image input / output board. 324R, and can be displayed on the head mounted display 313.

【0025】また、前記周辺機器インタフェース326
はマウス331に、周辺機器インタフェース327はキ
ーボード332に接続されるようになっている。ビデオ
ボード328はディスプレイ333に接続される。
The peripheral device interface 326
Is connected to the mouse 331, and the peripheral device interface 327 is connected to the keyboard 332. Video board 328 is connected to display 333.

【0026】内視鏡301は、図3のように細長の挿入
部302を備え、この挿入部302の先端部には、複数
の例えば2つの観察窓と照明窓とが設けられている。前
記各観察窓の内側には互いに視差を有する位置に左眼用
対物レンズ系303L、右眼用対物レンズ系304Rが
設けられている。各対物レンズ系303L、303Rの
結像位置にはそれぞれ固体撮像素子304L、304R
が配設されている。
The endoscope 301 has an elongated insertion portion 302 as shown in FIG. 3, and a plurality of, for example, two observation windows and an illumination window are provided at the tip of the insertion portion 302. Inside the observation windows, a left-eye objective lens system 303L and a right-eye objective lens system 304R are provided at positions having parallax with each other. The solid-state imaging devices 304L and 304R are located at the image forming positions of the objective lens systems 303L and 303R, respectively.
Are arranged.

【0027】また、前記照明窓の内側には、配光レンズ
305が設けられ、この配光レンズ305の後端にはフ
ァイババンドルよりなるライトガイド306が連設され
ている。このライトガイド306は前記挿入部302内
に挿通され、入射端部は図示しない光源装置に接続され
るようになっている。
A light distribution lens 305 is provided inside the illumination window, and a light guide 306 made of a fiber bundle is connected to the rear end of the light distribution lens 305. The light guide 306 is inserted into the insertion portion 302, and the incident end is connected to a light source device (not shown).

【0028】そして、この光源装置から出力される照明
光が前記ライトガイド306および配光レンズ305を
介して被写体に照射されるようになっている。この被写
体からの光は、前記対物レンズ303R、303Lによ
って、それぞれ左画像、右画像として、固体撮像素子3
04L、304Rに結像されるようになっている。
The illumination light output from the light source device is applied to the subject via the light guide 306 and the light distribution lens 305. The light from this subject is converted into a left image and a right image by the objective lenses 303R and 303L, respectively, as a solid-state image sensor 3
04L and 304R are formed.

【0029】まず、このように構成された計測内視鏡装
置の目盛描画の概略の流れを説明する。
First, a schematic flow of the scale drawing of the measurement endoscope apparatus configured as described above will be described.

【0030】内視鏡301による画像は、歪曲収差によ
る歪みが大きく無視できないため、歪曲収差補正を行
う。補正を行う前の画像を原画像、特に左右の画像をそ
れぞれ左原画像、右原画像と呼称し、補正画像を単に左
画像、右画像と呼ぶこととする。
In the image obtained by the endoscope 301, distortion due to distortion cannot be largely ignored. Images before correction are referred to as original images, particularly left and right images, respectively, as left original images and right original images, and corrected images are simply referred to as left images and right images.

【0031】本実施の形態では、歪曲収差補正を行わな
い原画像に対して目盛描画などの処理を行い立体視を行
うが、補正後の画像に目盛描画を行い、立体視すること
も可能である。
In the present embodiment, processing such as scale drawing is performed on the original image on which distortion correction is not performed, and stereoscopic viewing is performed. However, scale drawing may be performed on the corrected image to perform stereoscopic viewing. is there.

【0032】撮像系における座標系を図4に示す。ワー
ルド座標系XLLLの原点を左光学中心Oleftとす
る。また、右光学中心をOrightと呼ぶ。
FIG. 4 shows a coordinate system in the imaging system. The origin of the world coordinate system X L Y L Z L and left optical center O left. The right optical center is called O right .

【0033】図4のように、左原画像のローカル座標系
をiLL、右原画像のローカル座標系をiRRとする。
左右原画像の座標系とも原点は画像の左上である。図4
における左右の画像は歪曲収差補正済みの画像である。
As shown in FIG. 4, the local coordinate system of the left original image is i L j L , and the local coordinate system of the right original image is i R j R.
In both coordinate systems of the left and right original images, the origin is at the upper left of the image. FIG.
The left and right images in are the images after the distortion correction.

【0034】また、左画像の座標系はiL'L'、右画像
の座標系はiR'R'である。左右画像の座標系とも原点
は画像の左上である。左原画像上の画素Aを左原画像の
ローカル座標で表した座標をAL(iL,jL)、歪曲収
差補正後の左画像において、画素Aに対応する画素の同
じ座標系で表した座標をAL'(iL',jL')で表すもの
とする。
Further, the coordinate system of the left image coordinate system i L 'j L', right image is i R 'j R'. In both coordinate systems of the left and right images, the origin is at the upper left of the image. A L (i L , j L ) represents the coordinates of the pixel A on the left original image in the local coordinates of the left original image, and the same coordinate system of the pixel corresponding to the pixel A in the left image after distortion correction. The coordinates obtained are represented by A L ′ (i L ′ , j L ′ ).

【0035】同様に右原画像上の画素Aを右原画像のロ
ーカル座標で表した座標をAR(iR,jR)、歪曲収差
補正後の右画像において、画素Aに対応する画素の座標
をAR '(iR',jR')で表すものとする。
Similarly, the pixel A on the right original image is represented by A R (i R , j R ) in the local coordinates of the right original image, and the pixel A corresponding to the pixel A in the right image after the distortion correction is obtained. Let the coordinates be represented by A R (i R ′ , j R ′ ).

【0036】AL(iL,jL)を左光学中心を原点とし
たワールド座標で表した座標をAL W(xL,yL
L)、AR(iR,jR)を右光学中心を原点としたワー
ルド座標A R W(xR,yR,zR)とする。AL'(iL'
L')を左光学中心を原点としたワールド座標で表した
座標をAL' W(xL',yL',zL')、AR'(iR'
R')を右光学中心を原点としたワールド座標A
R' W(xR',yR',zR')とする。
AL(IL, JL) With the left optical center as the origin
A is the coordinate expressed in world coordinatesL W(XL, YL,
zL), AR(IR, JR) With the origin at the right optical center
Field coordinates A R W(XR, YR, ZR). AL '(IL ',
jL ') In world coordinates with the origin at the left optical center
Coordinate AL ' W(XL ', YL ', ZL '), AR '(IR ',
jR ') Is the world coordinate A with the right optical center as the origin.
R ' W(XR ', YR ', ZR ').

【0037】歪曲収差補正は例えば、以下の方法を使用
する。以下では、左画像を例に説明するが右画像でも同
様である。内視鏡301により図5の正方形のグリッド
を撮像した場合、得られる画像は図6のようになる。こ
の歪み画像が正方形になるようにあらかじめ各面素の座
標変換を求めておき、原画像から歪曲収差補正画像を作
成する。座標変換を画素の座標(iL,jL)の関数とし
て次式で表す。
For the correction of distortion, for example, the following method is used. Hereinafter, the left image will be described as an example, but the same applies to the right image. When the square grid of FIG. 5 is imaged by the endoscope 301, the obtained image is as shown in FIG. The coordinate transformation of each surface element is obtained in advance so that the distortion image becomes a square, and a distortion aberration corrected image is created from the original image. The coordinate transformation is represented by the following equation as a function of the pixel coordinates (i L , j L ).

【0038】[0038]

【数1】iL'=p(iL,jL) jL'=q(iL,jL) (1) p、qはiL,jLの多項式で表現される。より具体的手
法については米国特許USP4,895,431におい
て開示されている。
[Number 1] i L '= p (i L , j L) j L' = q (i L, j L) (1) p, q is i L, is expressed by a polynomial of j L. A more specific approach is disclosed in US Pat. No. 4,895,431.

【0039】実際には、処理の高速化のため(iL',j
L')を入力とし、(iL,jL)を出力としたルックアッ
プテーブルを作成し、補正画像の座標(iL',jL')の
画素値を原画像の座標(iL,jL)の画素値から決定す
ることにより、歪曲収差補正処理を実現する。前記ルッ
クアップテーブルを用いることにより、歪曲収差補正画
像上のある画素(iL',jL')が、原画像のどの画素か
ら作成されたかが分かる。以下では、(iL',jL')に
対応する(iL,jL)を逆補正対応と呼ぶことにする。
また、(iL,jL)に対応する(iL',jL')を順補正
対応と呼ぶことにする。
Actually, (i L ′ , j
L ′ ) is input and (i L , j L ) is output as a lookup table, and the pixel values of the corrected image coordinates (i L ′ , j L ′ ) are converted to the original image coordinates (i L , j L , By determining the pixel value from j L ), the distortion correction processing is realized. By using the look-up table, it is possible to determine from which pixel of the original image a certain pixel (i L ′ , j L ′ ) on the distortion-corrected image is created. In the following, it will be referred to as inverse correction corresponding to (i L ', j L' ) corresponding to the (i L, j L).
Also, it will be referred to as forward correction corresponding to (i L, j L) corresponding to the (i L ', j L' ).

【0040】同様に、(iR',jR')に対応する
(iR,jR)を逆補正対応、(iR,jR)に対応する
(iR',jR')を順補正対応と呼ぶことにする。
Similarly, (i R , j R ) corresponding to (i R , j R ) corresponds to the inverse correction, and (i R , j R ) corresponding to (i R , j R ) corresponds to (i R , j R ). This is referred to as forward correction correspondence.

【0041】以下では、図7のように内視鏡先端からD
is1[mm]に存在する立体目盛を描画する例を説明す
る。
In the following, as shown in FIG.
An example of drawing a solid scale existing at is1 [mm] will be described.

【0042】内視鏡先端からDis1[mm]離れた位置
にあるZL軸に垂直な鉛直平面を仮定する。左画像上の
目盛描画位置をあらかじめ与える。図8のように水平方
向に5個、垂直方向に5個の目盛を考えるが、各目盛の
座標をM[k] L'(i[k] L',j[k ] L')(k=0,1,‥
‥,9)とする。
[0042] Assume a perpendicular vertical plane Z L axis in the endoscope tip Dis1 [mm] away. Give the scale drawing position on the left image in advance. As shown in FIG. 8, five horizontal scales and five vertical scales are considered, and the coordinates of each scale are represented by M [k] L ' (i [k] L' , j [k ] L ' ) (k = 0,1, ‥
9, 9).

【0043】次に各目盛ごとに、左画像上の画素M[k]
L'(i[k] L',j[k] L')に映っている鉛直平面の点γを
求め(図4参照)、図9のように点γが映っている右画
像の点M[k] R'(i[k] R',j[k] R')(k=0,1,‥
‥,9)を求める。換言すると、鉛直平面上のある点γ
の左右画像での像の位置を確定することになる。
Next, for each scale, the pixel M [k] on the left image
The point γ on the vertical plane shown in L ′ (i [k] L ′ , j [k] L ′ ) is obtained (see FIG. 4), and the point M in the right image showing the point γ as shown in FIG. [k] R ' (i [k] R' , j [k] R ' ) (k = 0,1, ‥
‥, 9). In other words, a certain point γ on the vertical plane
The position of the image in the left and right images is determined.

【0044】さらに、左右画像の像の位置から逆補正対
応を使って、左右原画像の位置を求め、その位置に目盛
を描画することにより、内視鏡先端からDis1[mm]
に浮かんで見える立体目盛がヘッドマウントディスプレ
イ(以下、HMD)313の視野内に観察可能となる。
Further, the positions of the left and right original images are obtained from the positions of the images of the left and right images by using the inverse correction correspondence, and a scale is drawn at the positions, so that Dis1 [mm] from the tip of the endoscope.
3D scale that can be seen floating in the image can be observed in the field of view of a head mounted display (hereinafter, HMD) 313.

【0045】第1の実施の形態において、同様の方法に
より、立体図形、パラメータ、グラフィカル・ユーザ・
インタフェース(以下、GUI)、マウスカーソルを視
野内に立体描画する。描画はオーバーレイ画像に行う。
左オーバーレイ画像の座標系は左原画像ローカル座標系
と同じであり、右オーバーレイ画像の座標系は右原画像
ローカル座標系と同じである。
In the first embodiment, a solid figure, parameters, graphical user
An interface (hereinafter, GUI) and a mouse cursor are three-dimensionally drawn in the visual field. Drawing is performed on the overlay image.
The coordinate system of the left overlay image is the same as the local coordinate system of the left original image, and the coordinate system of the right overlay image is the same as the local coordinate system of the right original image.

【0046】左右のオーバーレイ画像での描画状態は図
10のようになる。オーバーレイ画像は公知のキーイン
グ技術により左右原画像と合成される。
The drawing state of the left and right overlay images is as shown in FIG. The overlay image is synthesized with the left and right original images by a known keying technique.

【0047】なお、キーイングは文献1(C言語で学ぶ
実践画像処理、井上誠喜他著、オーム社)に詳しい。
The keying is described in detail in Document 1 (Practical image processing learned in C language, written by Seiki Inoue et al., Ohmsha).

【0048】左右原画像の横サイズをW[画素]、縦サ
イズをH[画素]、左右画像の横サイズをWd[画
素]、縦サイズをHd[画素]とする。左右のオーバー
レイ画像のサイズもW[画素]、縦サイズをH[画素]
である。
The horizontal size of the left and right original images is W [pixel], the vertical size is H [pixel], the horizontal size of the left and right images is Wd [pixel], and the vertical size is Hd [pixel]. The size of the left and right overlay images is also W [pixels], and the vertical size is H [pixels]
It is.

【0049】第1の実施の形態の具体的なメイン処理の
流れを図11及び図12に従って説明する。
A specific flow of the main processing according to the first embodiment will be described with reference to FIGS.

【0050】あらかじめ、HMD313による立体視で
立体視可能な視差を調べておく。例えばさまざまな視差
の図形を描画しHMDにより観察することで明らかにす
ることができる。
The parallax that can be stereoscopically viewed by the HMD 313 is checked in advance. For example, it can be clarified by drawing figures with various parallaxes and observing them with an HMD.

【0051】ここで、視差とは右オーバレイ画像におけ
る図形描画iR座標と、左オーバレイ画像における図形
描画iL座標との差をいう。その範囲をD1[画素]<
(視差)<D2[画素]とする。
Here, the parallax means the difference between the figure drawing i R coordinate in the right overlay image and the figure drawing i L coordinate in the left overlay image. The range is D1 [pixel] <
(Parallax) <D2 [pixel].

【0052】ステップS1において、後述するアルゴリ
ズムBによりSc[mm]に対する1目盛の間隔[画
素]を決定する。それぞれ左画像水平目盛間隔SpxL'
左画像垂直目盛間隔SpyL'、右画像水平目盛間隔Sp
xR'、右画像垂直目盛間隔SpyR'とする。
In step S1, an interval [pixel] of one scale with respect to Sc [mm] is determined by an algorithm B described later. The left image horizontal scale interval Spx L ' ,
Left image vertical scale interval Spy L ' , right image horizontal scale interval Sp
xR ' , the right image vertical scale interval Spy R' .

【0053】ステップS2において、左画像水平目盛間
隔SpxL'、左画像垂直目盛間隔Spy L'を用いて、左画像
における目盛描画座標M[k] L'(k=0,1,‥‥,1
0)を決定する。あらかじめ与えられた左画像の目盛描
画中心座標(CxL',CyL')を用いて、式(2)で決定
される。
In step S2, the left image horizontal scale
Spax SpxL ', Left image vertical scale interval Spy L 'Using the left image
Scale drawing coordinate M at[k] L '(K = 0,1, ‥‥, 1
0) is determined. Scale drawing of the left image given in advance
Image center coordinates (CxL ', CyL ') And is determined by equation (2)
Is done.

【0054】[0054]

【数2】 水平目盛 M[k] L'=(CxL'+SpxL'・ (k−2),CyL')=(i[k] L' ,j[k] L') (0 ≦k≦4) 垂直目盛 M[k] L'=(CxL',CyL'+SpyL'・ (k−6))=(i[k] L' ,j[k] L') (5 ≦k≦9) (2) ステップS3において、内視鏡先端から目盛までの距離
をD is1[mm]として、後述するアルゴリズムAによ
りM[k] L'(i[k] L',j[k] L')(k=0,1,‥‥,
9)の逆補正対応画素M[k] L(i[k] L',j[k] L')(k
=0,1,‥‥,9)および、その対応点M[k] R(i
[k] L',j[k] L')(k=0,1,‥‥,10)を求め
る。M[k] Lおよび、M[k] R(k=0,1,‥‥,9)を
用いて後述するアルゴリズムCにより図10のように左
オーバーレイ画像に立体目盛600L、右オーバーレイ
画像に600Rを描画する。
## EQU2 ## Horizontal scale M [k] L ' = (CxL ' + SpxL '. (K-2), CyL ' ) = (i [k] L ' , j [k] L' ) (0≤ k ≦ 4) Vertical scale M [k] L ′ = (CxL , CyL + SpyL · (k−6)) = (i [k] L ′ , j [k] L ′ ) (5 ≦ (2) In step S3, the distance from the endoscope tip to the scale is set to Dis1 [mm], and M [k] L ' (i [k] L' , j [k ] is determined by algorithm A described later. ] L ′ ) (k = 0, 1, ‥‥,
9) The inverse correction corresponding pixel M [k] L (i [k] L ' , j [k] L' ) (k
= 0, 1, ‥‥, 9) and the corresponding point M [k] R (i
[k] L ′ , j [k] L ′ ) (k = 0, 1, ‥‥, 10). Using M [k] L and M [k] R (k = 0, 1,..., 9), the algorithm C described later uses a solid scale 600L for the left overlay image and a 600R for the right overlay image as shown in FIG. To draw.

【0055】ステップS4において、補助図形の左オー
バーレイ画像での描画座標を決定する。ここでは、(C
X2L,Cy2L)をあらかじめ与えておく。
In step S4, the drawing coordinates of the auxiliary figure in the left overlay image are determined. Here, (C
X2 L , Cy2 L ) are given in advance.

【0056】ステップS5において、内視鏡先端から立
体図形までの距離を図7のようにD is2[mm]とし
て、後述するアルゴリズムA’より(CX2L,Cy2L)の
対応点を求める。後述するアルゴリズムDにより図10
のように左オーバーレイ画像に立体図形601L、右オ
ーバーレイ画像に601Rを描画する。宙に浮かんで見
える目盛に対して対象が前後にあるかどうかはわかりや
すいが、ちょうど横にあるというのは把握しにくい。そ
こで、目盛と内視鏡先端からの距離が異なる補助図形を
描画することで、対象と目盛との位置関係の把握を容易
にする。また、描画する補助図形は複数でもよく、各図
形に対して内視鏡先端から立体図形までの距離を与え、
ステップS4、S5の処理を実施することで描画するこ
とができる。
[0056] In step S5, the distance from the endoscope tip to solid figure as D is2 [mm] as shown in FIG. 7, obtaining the corresponding points from the algorithm A 'to be described later (CX2 L, Cy2 L). FIG.
, A three-dimensional figure 601L is drawn on the left overlay image and a 601R is drawn on the right overlay image. It is easy to see whether the object is in front of or behind the scale that appears in the air, but it is difficult to grasp that it is just beside. Therefore, by drawing auxiliary figures having different distances from the scale and the endoscope end, it is easy to grasp the positional relationship between the target and the scale. Also, a plurality of auxiliary figures may be drawn, and the distance from the endoscope end to the three-dimensional figure is given to each figure,
By performing the processing in steps S4 and S5, drawing can be performed.

【0057】ステップS6において、ボタン604、6
05の左オーバーレイ画像での描画位置を式(3)で与
える。ボタンサイズはあらかじめ与えた幅Bx、高さBy
とし、ボタン604の中心座標をそれぞれ(CX3L,Cy
3L)として、4頂点の座標を決定する。ボタン605に
ついても同様である。
In step S6, buttons 604, 6
The drawing position in the left overlay image 05 is given by Expression (3). Button size is given width Bx, height By
And then, each of the center coordinates of the button 604 (CX3 L, Cy
3 L ), the coordinates of the four vertices are determined. The same applies to the button 605.

【0058】[0058]

【数3】 頂点1:(CX3L−Bx/2,Cy3L−By/2) 頂点2:(CX3L+Bx/2,Cy3L−By/2) 頂点3:(CX3L−Bx/2,Cy3L+By/2) 頂点4:(CX3L+Bx/2,Cy3L+By/2) (3) ステップS7において、内視鏡先端からGUI(ここで
はボタン)までの距離を図7のようにDis3[mm]と
して、後述するアルゴリズムA’により右オーバーレイ
画像のGUI描画座標を求める。後述するアルゴリズム
Eにより図10のようにGUIとして、ボタン604
L、605Lを左オーバーレイ画像に、604R、60
5Rを右オーバーレイ画像に描画する。
[Number 3] vertex 1: (CX3 L -Bx / 2 , Cy3 L -By / 2) vertex 2: (CX3 L + Bx / 2, Cy3 L -By / 2) vertex 3: (CX3 L -Bx / 2 , Cy3 L + by / 2) vertices 4: (in CX3 L + Bx / 2, Cy3 L + by / 2) (3) step S7, the distance from the endoscope tip to GUI (buttons in this case) as shown in FIG. 7 dis3 As [mm], the GUI drawing coordinates of the right overlay image are obtained by the algorithm A ′ described later. A button 604 is displayed as a GUI as shown in FIG.
L, 605L to the left overlay image, 604R, 60
5R is drawn on the right overlay image.

【0059】ステップS8において、左オーバーレイ画
像におけるパラメータを描画する基準線の座標を決定す
る。1パラメータにつき、基準線つまり直線を決定する
のに必要な2座標を与える。
In step S8, the coordinates of a reference line for drawing parameters in the left overlay image are determined. For each parameter, two coordinates necessary for determining a reference line, that is, a straight line, are given.

【0060】ステップS9において、内視鏡先端からパ
ラメータまでの距離を図7のようにDis4[mm]とし
て、後述するアルゴリズムA’により右画像のパラメー
タ描画座標を求める。後述するアルゴリズムFにより図
10のように、左オーバーレイ画像にパラメータ602
L、右オーバーレイ画像に602Rを描画する。図10
では、「20.0mm」を描画している。
In step S9, the distance from the tip of the endoscope to the parameter is set to Dis4 [mm] as shown in FIG. 7, and the parameter drawing coordinates of the right image are obtained by an algorithm A 'described later. As shown in FIG. 10, a parameter 602 is added to the left overlay image by an algorithm F described later.
L, 602R is drawn on the right overlay image. FIG.
In this example, “20.0 mm” is drawn.

【0061】ステップS10において、左オーバーレイ
画像におけるマウスカーソル可動領域内の座標を与え
る。マウスカーソルは図31,32のように矢印先頭部
分の1点により表すものとする。ここでは、カーソル可
動領域を左原画像全体とする。
In step S10, coordinates in the mouse cursor movable area in the left overlay image are given. The mouse cursor is represented by one point at the head of the arrow as shown in FIGS. Here, the cursor movable area is the entire left original image.

【0062】ステップS11において、内視鏡先端から
カーソルまでの距離を図7のようにDis5[mm]とし
て、後述するアルゴリズムA’により左マウスカーソル
座標に対する右マウスカーソル座標を導出する。また、
後述するアルゴリズムGにより図10のように左オーバ
レイ画像にマウスカーソル606L、右オーバーレイ画
像に606Rを描画する。
In step S11, the distance from the distal end of the endoscope to the cursor is set to Dis5 [mm] as shown in FIG. 7, and the right mouse cursor coordinates with respect to the left mouse cursor coordinates are derived by algorithm A 'described later. Also,
A mouse cursor 606L is drawn on the left overlay image and 606R is drawn on the right overlay image as shown in FIG.

【0063】ステップS12において、目盛、補助図
形、ボタン、パラメータ、マウスカーソル各図形の視差
を調べ立体視可能な範囲に入っているかどうかを調べ
る。例えば目盛の場合は次式となる。
In step S12, the parallax of each of the scales, auxiliary figures, buttons, parameters, and mouse cursor figures is checked to determine whether they are within a stereoscopically viewable range. For example, in the case of a scale, the following expression is used.

【0064】D1<M[k] R−M[k] L<D2 範囲に入っていない場合は、ステップS13において、
内視鏡先端から各図形までの距離の再設定を行うよう警
告表示をしステップS14に進み、範囲に入っている場
合はそのままステップS14に進む。ステップS13で
は入力装置(キーボード332等)で距離を入力させて
も良い。
If D1 <M [k] R- M [k] L <D2, the process proceeds to step S13.
A warning is displayed to reset the distance from the endoscope tip to each figure, and the process proceeds to step S14. If the distance is within the range, the process directly proceeds to step S14. In step S13, the distance may be input using an input device (such as the keyboard 332).

【0065】ステップS14において、後述するアルゴ
リズムHにより、GUI及びキーボードによるパラメー
タの変更手段を実行する。
In step S14, a parameter changing means using a GUI and a keyboard is executed by an algorithm H described later.

【0066】[アルゴリズムA]対応点決定の処理であ
るアルゴリズムAの流れを図13に従って説明する。
[Algorithm A] The flow of algorithm A, which is a process for determining corresponding points, will be described with reference to FIG.

【0067】ステップS21において、画像を取得す
る。ビデオプロセッサ310L、310Rから出力され
た画像が、画像入出力ボード324L、324Rにより
メインメモリ322に転送される。
In step S21, an image is obtained. The images output from the video processors 310L and 310R are transferred to the main memory 322 by the image input / output boards 324L and 324R.

【0068】ステップS22において、あらかじめ設定
された内視鏡先端からの描画図形までの距離τ[m
m]、左画像における図形描画座標αL'(iL',jL'
を取得する。
In step S22, a distance τ [m from the end of the endoscope to a drawing figure set in advance.
m], figure drawing coordinates α L ′ (i L ′ , j L ′ ) in the left image
To get.

【0069】ステップS23において、αL'の逆補正対
応画素αLを求める。 αLが左オーバーレイ画像の描画
位置である。逆補正対応策素の求めかたは、式(1)と
逆の処理を行う、もしくは(iL',jL')が出力である
ルックアップテーブルの入力値を探索することで求める
ことができる。求められた座標ををαL(iL,jL)と
する。
In step S23, a pixel α L corresponding to the inverse correction of α L ′ is obtained. α L is the drawing position of the left overlay image. The method of obtaining the inverse correction countermeasure element can be obtained by performing a process reverse to the expression (1), or by searching for an input value of a lookup table that outputs (i L ′ , j L ′ ). Let the obtained coordinates be α L (i L , j L ).

【0070】ステップS24において、次式の座標変換
により、αL'をワールド座標系に変換する。それをαL'
W(xL',yL',zL')とする。次式において、fLは左
光学系の焦点距離、CLは左CCD1画素あたりの横サ
イズ、あるいは左CCD1画素あたりの縦サイズであ
る。
In step S24, α L ′ is converted into a world coordinate system by the following coordinate conversion. Α L '
W (xL ' , yL ' , zL ' ). In the following equation, f L is a focal length, C L of the left optical system is left CCD1 horizontal size per pixel or left CCD1 vertical size per pixel.

【0071】[0071]

【数4】xL'=(iL'−Wd/2)×CxLL'=(Hd/2−jL')×CyLL'=fL (4) ステップS25において、鉛直平面上の仮想対象点座標
を求める。 αL' Wと左光学中心Oleft(0,0,0)を
通過する直線Lと、(0,0,τ)を通る鉛直平面との
交点を求める。この交点を仮想対象点と呼び、座標γL W
(xL γ,yL γ,zL γ)とする。実際には図14及び
図15の撮像系に見られる三角形の相似を利用すること
により、仮想対象点の座標を求めることが可能である。
Equation 4] x L '= (i L' -Wd / 2) in × Cx L y L '= ( Hd / 2-j L') × Cy L z L '= f L (4) step S25, the vertical Find the virtual target point coordinates on the plane. The intersection of a straight line L passing through α L ′ W and the left optical center Oleft (0, 0, 0) and a vertical plane passing through (0, 0, τ) is obtained. This intersection is called a virtual target point, and the coordinates γ L W
(X L γ, y L γ , z L γ) and. Actually, it is possible to obtain the coordinates of the virtual target point by using the similarity of the triangles seen in the imaging systems of FIGS. 14 and 15.

【0072】[0072]

【数5】xL γ=(xL'×τ)/zLL γ=(yL'×τ)/zLL γ=τ (5) ステップS26において、右画像における対応点の座標
の導出を行う。座標変換により右光学系中心を原点とし
た座標系XRRRにおける仮想対象点γR Wの座標を求
める。その座標をγR W(xR γ,yR γ,zR γ)とす
る。Rは回転行列、(Mx,My,Mz)はXLLL
おける右カメラの座標である。
In Equation 5] x L γ = (x L ' × τ) / z L y L γ = (y L' × τ) / z L z L γ = τ (5) Step S26, the corresponding point in the right image The coordinates are derived. Determining the coordinates of the virtual object point gamma R W in the coordinate system X R Y R Z R with the origin of the right optical system centered by the coordinate transformation. The coordinates γ R W (x R γ, y R γ, z R γ) to. R is the rotation matrix, (Mx, My, Mz) are the coordinates of the right camera in the X L Y L Z L.

【0073】[0073]

【数6】 Rは回転行列であり、表し方は様々である。例えば、極
座標系においてθ1はZL軸を中心とした回転量を、θ2
はXL軸を中心とした回転量を表すと次式となる。
(Equation 6) R is a rotation matrix, which can be expressed in various ways. For example, the rotation amount θ1 is centered on the Z L axis in the polar coordinate system, .theta.2
Represents the amount of rotation about the XL axis as follows.

【0074】[0074]

【数7】 γR Wと右光学中心Orightを通過する直線L’と、右画
像との交点を求めることにより、仮想対象点γR Wに対す
る右画像での像の座標を求める。その座標をβ
R W(xR,yR,zR)とする。実際には図14及び図1
5の撮像系に見られる三角形の相似を利用することによ
り、求めることが可能である。fRは右光学系の焦点距
離である。
(Equation 7)γR WAnd right optical center OrightAnd a straight line L 'passing through
By finding the intersection with the image, the virtual target point γR WAgainst
Find the coordinates of the image in the right image. The coordinates are β
R W(XR, YR, ZR). FIG. 14 and FIG.
5 using the similarity of triangles found in the imaging system
Can be sought. fRIs the focal length of the right optical system
It is separation.

【0075】[0075]

【数8】xR=(xR γ/zR γ)×fRR=(yR γ/zR γ)×fRR=fR (8) ステップS27において、座標変換によりβR Wを右画像
のローカル座標系に変換する。その座標をβR'(iR'
R')とする。CxRは右CCD1画素あたりの横サイ
ズ、CyRは右CCD1画素あたりの縦サイズである。
In Equation 8] x R = (x R γ / z R γ) × f R y R = (y R γ / z R γ) × f R z R = f R (8) Step S27, the coordinate transformation β converting the R W in the local coordinate system of the right image. Let the coordinates be β R ' (i R' ,
j R ′ ). Cx R horizontal size per right CCD1 pixel, the Cy R a longitudinal size per right CCD1 pixel.

【0076】[0076]

【数9】iR'=Wd/2+xR/CxRR'=Hd/2−yR/CyR (9) βR'は歪曲収差補正画像における像の座標を表している
ため、右原画像における像βR(iR,jR)をルックア
ップテーブルにより求める。
Equation 9] i R for '= Wd / 2 + x R / Cx R j R' = Hd / 2-y R / Cy R (9) β R ' is representing the coordinates of the image in the distortion correction image, right The image β R (i R , j R ) in the original image is obtained by a look-up table.

【0077】以上によりαL(iL,jL)が左オーバー
レイ画像の描画位置、βR(iR,jR)が右オーバーレ
イ画像における描画位置となる。
As described above, α L (i L , j L ) is the drawing position of the left overlay image, and β R (i R , j R ) is the drawing position of the right overlay image.

【0078】[アルゴリズムA’]対応点決定の処理で
あるアルゴリズムA’の流れを図16に従って説明す
る。アルゴリズムAとの違いは、処理のターゲットとな
る座標が左画像の座標でなく、左原画像(つまり左オー
バーレイ画像)の座標であるという点である。
[Algorithm A '] The flow of algorithm A', which is the processing for determining corresponding points, will be described with reference to FIG. The difference from the algorithm A is that the coordinates to be processed are not the coordinates of the left image but the coordinates of the left original image (that is, the left overlay image).

【0079】ステップS31において、画像を取得す
る。ビデオプロセッサ310L、310Rから出力され
た画像が、画像入出力ボード324L、324Rにより
メインメモリ322に転送される。
In step S31, an image is obtained. The images output from the video processors 310L and 310R are transferred to the main memory 322 by the image input / output boards 324L and 324R.

【0080】ステップS32において、あらかじめ設定
された内視鏡先端からの距離τ[mm]、左オーバーレ
イ画像における図形描画座標αL(iL,jL)を取得す
る。
In step S32, a predetermined distance τ [mm] from the endoscope tip and a figure drawing coordinate α L (i L , j L ) in the left overlay image are acquired.

【0081】ステップS33において、αLの順補正対
応画素αL'を求める。(iL,jL)をルックアップテー
ブルの入力として、その出力がαL'(iL',jL')とな
る。αLとαL'の関係は、座標αLが歪曲収差補正により
座標αL'になるという関係にある。
[0081] In step S33, obtaining the alpha forward correction corresponding pixels of L α L '. Using (i L , j L ) as an input to the lookup table, its output is α L ′ (i L ′ , j L ′ ). The relationship between α L and α L ′ is that the coordinate α L becomes the coordinate α L ′ due to distortion correction.

【0082】ステップS34において、次式の座標変換
により、αL'をワールド座標系に変換する。それをαL'
W(xL',yL',zL')とする。次式において、fLは左
光学系の焦点距離、CxLは左CCD1画素あたりの横サ
イズ、CyLは左CCD1画素あたりの縦サイズである。
In step S34, α L ′ is converted into a world coordinate system by the following coordinate conversion. Α L '
W (xL ' , yL ' , zL ' ). In the following equation, f L is the focal length of the left optical system, Cx L is the horizontal size per left CCD pixel, and Cy L is the vertical size per left CCD pixel.

【0083】[0083]

【数10】xL'=(iL'−Wd/2)×CxLL'=(Hd/2−jL')×CyLL'=fL (10) ステップS35において、鉛直平面上の仮想対象点座標
を求める。 αL' Wと左光学中心Oleft(0,0,0)を
通過する直線Lと、(0,0,τ)を通る鉛直平面との
交点を求める。この交点を仮想対象点と呼び、座標γL W
(xL γ,yL γ,zL γ)とする。実際には図14及び
図15の撮像系に見られる三角形の相似を利用すること
により、仮想対象点の座標を求めることが可能である。
Equation 10] x L '= (i L' -Wd / 2) in × Cx L y L '= ( Hd / 2-j L') × Cy L z L '= f L (10) Step S35, the vertical Find the virtual target point coordinates on the plane. The intersection of a straight line L passing through α L ′ W and the left optical center Oleft (0, 0, 0) and a vertical plane passing through (0, 0, τ) is obtained. This intersection is called a virtual target point, and the coordinates γ L W
(X L γ, y L γ , z L γ) and. Actually, it is possible to obtain the coordinates of the virtual target point by using the similarity of the triangles seen in the imaging systems of FIGS. 14 and 15.

【0084】[0084]

【数11】xL γ=(xL'×τ)/zLL γ=(yL'×τ)/zLL γ=τ (11) ステップS36において、右画像における対応点の座標
の導出を行う。座標変換により右光学系中心を原点とし
た座標系XRRRにおける仮想対象点γR Wの座標を求
める。その座標をγR W(xR γ,yR γ,zR γ)とす
る。Rは回転行列、(MX,My,Mz)はXLLLにお
ける右カメラの座標である。
In Equation 11] x L γ = (x L ' × τ) / z L y L γ = (y L' × τ) / z L z L γ = τ (11) step S36, the corresponding point in the right image The coordinates are derived. Determining the coordinates of the virtual object point gamma R W in the coordinate system X R Y R Z R with the origin of the right optical system centered by the coordinate transformation. The coordinates γ R W (x R γ, y R γ, z R γ) to. R is the rotation matrix, (MX, My, Mz) are the coordinates of the right camera in the X L Y L Z L.

【0085】[0085]

【数12】 Rは回転行列であり、アルゴリズムAと同様に次式とな
る。
(Equation 12) R is a rotation matrix, which is expressed by the following equation as in the algorithm A.

【0086】[0086]

【数13】 γR Wと左光学中心Orightを通過する直線L’と、右画
像との交点を求めることにより、仮想対象点γR Wに対す
る右画像での像の座標を求める。その座標をβ
R W(xR,yR,zR)とする。実際には図14及び図1
5の撮像系に見られる三角形の相似を利用することによ
り、求めることが可能である。fRは右光学系の焦点距
離である。
(Equation 13)γR WAnd the left optical center OrightAnd a straight line L 'passing through
By finding the intersection with the image, the virtual target point γR WAgainst
Find the coordinates of the image in the right image. The coordinates are β
R W(XR, YR, ZR). FIG. 14 and FIG.
5 using the similarity of triangles found in the imaging system
Can be sought. fRIs the focal length of the right optical system
It is separation.

【0087】[0087]

【数14】xR=(xR γ/zR γ)×fRR=(yR γ/zR γ)×fRR=fR (14) ステップS37において、座標変換によりβR Wを右画像
のローカル座標系に変換する。その座標をβR'(iR'
R')とする。CxRは右CCD1画素あたりの横サイ
ズ、CyRは右CCD1画素あたりの縦サイズである。
In Equation 14] x R = (x R γ / z R γ) × f R y R = (y R γ / z R γ) × f R z R = f R (14) step S37, the coordinate transformation β converting the R W in the local coordinate system of the right image. Let the coordinates be β R ' (i R' ,
j R ′ ). Cx R horizontal size per right CCD1 pixel, the Cy R a longitudinal size per right CCD1 pixel.

【0088】[0088]

【数15】 iR'=Wd/2+xR/CxRR'=Hd/2−yR/CyR (15) βR'は歪曲収差補正画像における像の座標を表している
ため、右原画像における像βR(iR,jR)をルックア
ップテーブルにより求める。
(15) i R ′ = Wd / 2 + x R / Cx R j R ′ = Hd / 2−y R / Cy R (15) Since β R ′ represents the coordinates of the image in the distortion-corrected image, the right The image β R (i R , j R ) in the original image is obtained by a look-up table.

【0089】以上によりαL(iL,jL)、βR(iR
R)がオーバーレイ画像における描画位置となる。
As described above, α L (i L , j L ) and β R (i R ,
j R ) is the drawing position in the overlay image.

【0090】[アルゴリズムB]目盛り間隔を決定する
アルゴリズムBの流れを図17に従って説明する。ステ
ップS41において、あらかじめ与えられた目盛間隔S
c[mm]を取得する。
[Algorithm B] The flow of algorithm B for determining the scale interval will be described with reference to FIG. In step S41, a scale interval S given in advance
Get c [mm].

【0091】ステップS42において、撮像系の比例関
係により左画像の水平方向の目盛間隔[画素]を決定す
る。水平方向にSc[mm]の目盛を作成する場合、目
盛を描画する画像平面におけるX座標は、撮像系をY軸
側から見た図14から以下のようになる。図14におけ
るX軸、Y軸はグローバル座標系のXL、YLまたは
R、YRを表す。
In step S42, the proportional relation of the imaging system is determined.
Determines the horizontal scale interval [pixels] of the left image
You. When creating a scale of Sc [mm] in the horizontal direction,
The X coordinate on the image plane where the sculpture is drawn
From FIG. 14 as viewed from the side, the following is obtained. In FIG.
X and Y axes are X in the global coordinate system.L, YLOr
X R, YRRepresents

【0092】[0092]

【数16】Sc/zγ=Sx/fL Sx=(ScfL)zγ (16) 単位を[mm]から[画素]に変換する。Equation 16] for converting Sc / z γ = Sx / f L Sx = a (Scf L) z γ (16 ) units from the [mm] in the pixel.

【0093】[0093]

【数17】 SPxL'=Sx/CxL (17) したがってSc[mm]に対応する画素数はSPxL'とな
る。
Equation 17] SPx L '= Sx / Cx L (17) Thus the number of pixels corresponding to Sc [mm] is SPx L' becomes.

【0094】ステップS43において、同様に右画像の
水平方向の描画間隔は次式になる。
In step S43, the drawing interval of the right image in the horizontal direction is given by the following equation.

【0095】[0095]

【数18】Sc/zγ’=Sx/fR Sx=(ScfR)zγ’ (18) 単位を[mm]から[画素]に変換する。Equation 18] for converting Sc / z gamma a '= Sx / f R Sx = (Scf R) z γ' (18) units from [mm] to [pixel].

【0096】[0096]

【数19】 SPxR'=Sx/CxR (19) したがってSc[mm]に対応する画素数はSPxR'とな
る。
Equation 19] SPx R '= Sx / Cx R (19) Thus the number of pixels corresponding to Sc [mm] is SPx R' becomes.

【0097】ステップS44において、撮像系の比例関
係により左画像の垂直方向の目盛間隔を決定する。垂直
方向にSc[mm]の目盛を作成する場合、目盛を描画
する画像平面におけるY座標は、撮像系をX軸側から見
た図15から比例関係により以下のようになる。図15
におけるY軸、Z軸はグローバル座標系のYL、ZLまた
はYR、ZRを表す。
In step S44, the vertical scale interval of the left image is determined based on the proportional relationship of the imaging system. When a scale of Sc [mm] is created in the vertical direction, the Y coordinate on the image plane on which the scale is drawn is as follows based on a proportional relationship from FIG. 15 when the imaging system is viewed from the X-axis side. FIG.
Y axis in, Z-axis represents the Y L, Z L or Y R, Z R of the global coordinate system.

【0098】[0098]

【数20】Sc/zγ=Sy/fL Sy=(ScfL)zγ (20) 単位を[mm]から[画素]に変換する。Equation 20] for converting Sc / z γ = Sy / f L Sy = a (Scf L) z γ (20 ) units from [mm] to [pixel].

【0099】[0099]

【数21】 SPyL'=Sy/CyL (21) したがってSc[mm]に対応する画素数はSPyL'とな
る。
SPy L ′ = Sy / Cy L (21) Therefore, the number of pixels corresponding to Sc [mm] is SPy L ′ .

【0100】ステップS45において、同様に右画像の
垂直方向の描画間隔は(22)式になる。
In step S45, similarly, the drawing interval of the right image in the vertical direction is given by equation (22).

【0101】[0101]

【数22】Sc/zγ’=Sy/fR Sy=(ScfR)zγ’ (22) 単位を[mm]から[画素]に変換する。Equation 22] for converting Sc / z γ '= Sy / f R Sy = (Scf R) z γ' (22) units from [mm] to [pixel].

【0102】[0102]

【数23】 SPyR'=Sy/CyR (23) したがってSc[mm]に対応する画素数はSPyR'とな
る。
SPy R ′ = Sy / Cy R (23) Therefore, the number of pixels corresponding to Sc [mm] is SPy R ′ .

【0103】[アルゴリズムC]与えられた座標を中心
に、水平目盛としてあらかじめ与えた長さSL1の垂直ラ
インを描画する。垂直目盛として長さSL2の水平ライン
を描画する。いずれの目盛に対しても中心座標間で直線
を描画する。ここでは、目盛数が水平5個、垂直5個の
場合を説明する。目盛描画処理であるアルゴリズムCの
流れを図18に従って説明する。
[Algorithm C] A vertical line with a length SL1 given in advance as a horizontal scale is drawn around the given coordinates. Draw a horizontal line of length SL2 as a vertical scale. A straight line is drawn between the center coordinates on any scale. Here, a case where the number of scales is 5 horizontally and 5 vertically will be described. The flow of algorithm C, which is a scale drawing process, will be described with reference to FIG.

【0104】ステップS51において、k=0とする。
ステップS52において、左右オーバーレイ描画する目
盛を図19、図20のようにM[k] L、M[k] Rで表す。目
盛描画座標を取得する。取得した座標をM
[k] L(i[k] L,j[k] L)、M[k] R(i[k] R,j[k] R)と
する。ここで、図19、図20、さらに図8、図9から
分かるようにk≦4の座標は水平目盛の座標、k>4の
座標は垂直目盛の座標である。
In step S51, k = 0.
In step S52, the scales for left and right overlay drawing are represented by M [k] L and M [k] R as shown in FIGS. Get the scale drawing coordinates. The acquired coordinates are M
[k] L (i [k] L , j [k] L ) and M [k] R (i [k] R , j [k] R ). Here, as can be seen from FIGS. 19 and 20, and further FIGS. 8 and 9, the coordinates of k ≦ 4 are the coordinates of the horizontal scale, and the coordinates of k> 4 are the coordinates of the vertical scale.

【0105】ステップS53において、k≦4ならばス
テップS54を実施する。そうでなければステップS5
5を実施する。
In step S53, if k ≦ 4, step S54 is performed. Otherwise, step S5
Perform Step 5.

【0106】ステップS54において、左オーバーレイ
画像に水平目盛を描画する。つまり、(i[k] L
[k] L)を中心として図19のように垂直ラインを描画
する。右オーバーレイ画像に水平目盛を描画する。つま
り、(i[k] R,j[k] R)を中心として図20のように垂
直ラインを描画する。ステップS56を実施する。
In step S54, a horizontal scale is drawn on the left overlay image. That is, (i [k] L ,
j [k] L ) and a vertical line is drawn as shown in FIG. Draw a horizontal scale on the right overlay image. That is, a vertical line is drawn centering on (i [k] R , j [k] R ) as shown in FIG. Step S56 is performed.

【0107】ステップS55において、左オーバーレイ
画像に垂直目盛を描画する。(i[k ] L,j[k] L)を中心
として、図19のように水平ラインを描画する。右オー
バーレイ画像に垂直目盛を描画する。(i[k] R
[k] R)を中心として、図20のように水平ラインを描
画する。
In step S55, a vertical scale is drawn on the left overlay image. A horizontal line is drawn centering on (i [k ] L , j [k] L ) as shown in FIG. Draw a vertical scale on the right overlay image. (I [k] R ,
A horizontal line is drawn centered on j [k] R ) as shown in FIG.

【0108】ステップS56において、k>0かつk≠
5ならば左オーバーレイ画像において(i[k] L
[k] L)、(i[k-1] L,j[k-1] L)間で直線を描画す
る。右オーバーレイ画像において(i[k] R,j[k] R)、
(i[k-1] R,j[k-1] R)間で直線を描画する。k≠5と
いう条件は水平目盛と垂直目盛間で直線を描画しないよ
うにするためである。
In step S56, k> 0 and k ≠
If it is 5, in the left overlay image (i [k] L ,
j [k] L ) and a straight line between (i [k-1] L , j [k-1] L ). In the right overlay image (i [k] R , j [k] R ),
A straight line is drawn between (i [k-1] R , j [k-1] R ). The condition of k ≠ 5 is to prevent a straight line from being drawn between the horizontal scale and the vertical scale.

【0109】ステップS57において、kを1増加させ
る。ステップS58において、k<10ならばステップ
S53に戻る。
In step S57, k is incremented by one. If k <10 in step S58, the process returns to step S53.

【0110】結果として得られる目盛が図10に示す目
盛600L、600Rである。
The resulting scales are the scales 600L and 600R shown in FIG.

【0111】[アルゴリズムD]あらかじめ与えられた
座標を中心に、図形を描画する。ここでは、縦ラインお
よび、横ラインの長さがあらかじめ与えたSL3である十
字型の補助図形を、取得した座標を中心として描画す
る。図形としては十字型に限定されるものではない。例
えばステップS1,S2と同様の処理を実施すること
で、立体目盛を補助図形として描画することが可能であ
る。補助図形描画の流れを図21に従って説明する。
[Algorithm D] A figure is drawn around the coordinates given in advance. Here, a cross-shaped auxiliary graphic whose vertical line and horizontal line lengths are SL3 given in advance is drawn with the acquired coordinates as the center. The shape is not limited to the cross shape. For example, by performing the same processing as in steps S1 and S2, it is possible to draw a solid scale as an auxiliary figure. The flow of auxiliary figure drawing will be described with reference to FIG.

【0112】ステップS61において、左画像における
十字型図形の描画座標として座標(i[0] L,j[0] L)を
取得する。右画像における十字型図形の描画座標とし
て、座標(i[0] R,j[0] R)を取得する。
In step S61, coordinates (i [0] L , j [0] L ) are obtained as drawing coordinates of a cross-shaped figure in the left image. The coordinates (i [0] R , j [0] R ) are acquired as the drawing coordinates of the cross-shaped figure in the right image.

【0113】ステップS62において、左オーバーレイ
画像に十字型図形を描画する。(i [0] L,j[0] L)を中
心として、図22のように縦横ラインの長さがSL3の十
字型図形を描画する。描画状態は図10の十字型図形6
01Lとなる。
In step S62, the left overlay
Draw a cross shape on the image. (I [0] L, J[0] L) Inside
As shown in FIG. 22, the length of the vertical and horizontal lines is not more than SL3.
Draw a glyph. The drawing state is the cross-shaped figure 6 in FIG.
01L.

【0114】ステップS63において、右オーバーレイ
画像に十字型図形を描画する。(i [0] R,j[0] R)を中
心として、図23のように縦横ラインの長さがSL3の十
字型図形を描画する。描画状態は図10の十字型図形6
01Rとなる。
In step S63, the right overlay
Draw a cross shape on the image. (I [0] R, J[0] R) Inside
As shown in FIG. 23, the length of the vertical and horizontal lines is 10
Draw a glyph. The drawing state is the cross-shaped figure 6 in FIG.
01R.

【0115】[アルゴリズムE]取得した座標を用いて
ボタンを描画する。ボタン描画処理であるアルゴリズム
Eの流れを図24に従って説明する。
[Algorithm E] A button is drawn using the acquired coordinates. The flow of algorithm E, which is a button drawing process, will be described with reference to FIG.

【0116】ステップS71において,左GUI座標を
取得する.取得した座標を(i[0] L,j[0] L)〜(i
[3] L,j[3] L)とする。右GUI座標を取得する。取得
した座標を(i[0] R,j[0] R)〜(i[3] R,j[3] R)と
する。
In step S71, the left GUI coordinates are obtained. The acquired coordinates are represented by (i [0] L , j [0] L ) to (i
[3] L , j [3] L ). Get the right GUI coordinates. Let the acquired coordinates be (i [0] R , j [0] R ) to (i [3] R , j [3] R ).

【0117】ステップS72において、GUI可視属性
がTRUEならば、ステップS73を実行する。そうで
なければステップS74を実行する。
In step S72, if the GUI visibility attribute is TRUE, step S73 is executed. If not, step S74 is executed.

【0118】ステップS73において、左オーバーレイ
画像にボタンを描画する。(i[0] L,j[0] L)〜(i
[3] L,j[3] L)を4頂点とした長方形のボタンを図25
のようにオーバーレイ画像に描画する。右画像にボタン
を描画する。(i[0] R,j[0] R)〜(i[3] R,j[3] R
を4頂点とした長方形のボタンを図26のようにオーバ
ーレイ画像に描画する。描画状態は図10の604L、
605L、604R、605Rボタンのようになる。処
理を終了する。
In step S73, a button is drawn on the left overlay image. (I [0] L , j [0] L ) to (i
[3] L , j [3] L ) is a rectangular button with four vertices.
Is drawn on the overlay image as follows. Draw a button on the right image. (I [0] R , j [0] R ) to (i [3] R , j [3] R )
Is drawn on the overlay image as shown in FIG. 26. The drawing state is 604L in FIG.
It looks like a 605L, 604R, 605R button. The process ends.

【0119】ステップS74において、GUI可視属性
がFALSEならば、左右のオーバーレイ画像からボタ
ンを消去する。処理を終了する。
In step S74, if the GUI visibility attribute is FALSE, the buttons are deleted from the left and right overlay images. The process ends.

【0120】[アルゴリズムF]取得した座標を用いて
パラメータを描画する。パラメータ描画処理であるアル
ゴリズムFの流れを図27に従って説明する。
[Algorithm F] The parameters are drawn using the obtained coordinates. The flow of algorithm F, which is a parameter drawing process, will be described with reference to FIG.

【0121】ステップS81において、左オーバーレイ
画像におけるパラメータを描画する基準線の座標を取得
する。取得した座標を(i[0] L,j[0] L)、(i[1] L
[1 ] L)とする。右オーバーレイ画像におけるパラメー
タを描画する基準線の座標を取得する。取得した座標を
(i[0] R,j[0] R)、(i[1] R,j[1] R)とする。
In step S81, the coordinates of a reference line for drawing parameters in the left overlay image are obtained. The acquired coordinates are (i [0] L , j [0] L ), (i [1] L ,
j [1 ] L ). The coordinates of a reference line for drawing a parameter in the right overlay image are acquired. The acquired coordinates are (i [0] R , j [0] R ) and (i [1] R , j [1] R ).

【0122】ステップS82において、パラメータ可視
属性がTRUEであればステップS83を実行する。そ
うでなければステップS84を実行する。
In step S82, if the parameter visibility attribute is TRUE, step S83 is executed. Otherwise, execute step S84.

【0123】ステップS83において、左オーバーレイ
画像にパラメータを描画する。(i [0] L,j[0] L)、
(i[1] L,j[1] L)を基準線として図28のようにパラ
メータをオーバーレイ画像に描画する。基準線が水平方
向に対して傾いた場合は、水平方向に対する式(24)
の角度θLに応じて傾けたフォントを使用して、
In step S83, the left overlay
Draw parameters on the image. (I [0] L, J[0] L),
(I[1] L, J[1] L) As a reference line, as shown in FIG.
Draw the meter on the overlay image. Reference line is horizontal
When tilted with respect to the direction, the equation (24) for the horizontal direction
Angle θLUse a font that is tilted according to

【数24】 θL=tan-1(jj[1] L−jj[0] L)/(i[1] L−i[0] L) jj[k] L=H−j[k] L (k=0,1) (24) 右オーバーレイ画像にパラメータを描画する。
(i[0] R,j[0] R)、(i[1] R,j[1] R)を基準線とし
て図29のようにパラメータをオーバーレイ画像に描画
する。基準線と水平方向に対する式(25)の角度θR
に応じて傾けたフォントを使用して、パラメータを描画
する。処理を終了する。描画状態は図10のパラメータ
602L、602Rとなる。
Equation 24] θ L = tan -1 (jj [ 1] L -jj [0] L) / (i [1] L -i [0] L) jj [k] L = H-j [k] L (K = 0, 1) (24) Draw parameters on the right overlay image.
Using (i [0] R , j [0] R ) and (i [1] R , j [1] R ) as reference lines, parameters are drawn on the overlay image as shown in FIG. Angle θ R of equation (25) with respect to the reference line and the horizontal direction
Draw parameters using a font tilted according to. The process ends. The drawing state is the parameters 602L and 602R in FIG.

【0124】[0124]

【数25】 θR=tan-1(jj[1] R−jj[0] R)/(i[1] R−i[0] R) jjk] R=H−j[k] R (k=0,1) (25) ステップS84において、パラメータ可視属性がFAL
SEであればパラメータを左右のオーバーレイ画像から
消去する。処理を終了する。
Θ R = tan −1 (JJ [1] R− JJ [0] R ) / (i [1] R− i [0] R ) jjk ] R = H−j [k] R ( k = 0,1) (25) In step S84, the parameter visibility attribute is set to FAL.
If it is SE, the parameters are deleted from the left and right overlay images. The process ends.

【0125】[アルゴリズムG]取得した座標を用いて
マウスカーソルを描画する。カーソル描画であるアルゴ
リズムGの流れを図30に従って説明する。
[Algorithm G] A mouse cursor is drawn using the acquired coordinates. The flow of algorithm G, which is cursor drawing, will be described with reference to FIG.

【0126】ステップS91において、現在の左オーバ
ーレイ画像の座標におけるマウスカーソルの座標
(iL,jL)を取得する。それに対応する右オーバーレ
イ画像の対応点の座標を(iR,jR)とする。前述のよ
うに左オーバーレイ画像の座標系は、左原画像ローカル
座標と同じであり、右オーバーレイ画像の座標系は、右
原画像ローカル座標と同じである。
In step S91, the coordinates (i L , j L ) of the mouse cursor at the coordinates of the current left overlay image are obtained. Let the coordinates of the corresponding point of the right overlay image corresponding to that be (i R , j R ). As described above, the coordinate system of the left overlay image is the same as the local coordinates of the left original image, and the coordinate system of the right overlay image is the same as the local coordinates of the right original image.

【0127】ステップS92において、カーソル可視属
性がTRUEであればステップS93を実施する。そう
でなければステップS94を実施する。
At step S92, if the cursor visibility attribute is TRUE, step S93 is executed. Otherwise, step S94 is performed.

【0128】ステップS93において、左オーバーレイ
画像にマウスカ4ソルを描画する。(iL,jL)を中心
として図31のようにマウスカーソルをオーバーレイ画
像に描画する。右オーバーレイ画像にマウスカーソルを
描画する。(iR,jR)を中心として図32のようにマ
ウスカーソルをオーバーレイ画像に描画する。描画状態
は図10のカーソル606L、606Rとなる。処理を
終了する。
In step S93, a mouse cursor is drawn on the left overlay image. The mouse cursor is drawn on the overlay image as shown in FIG. 31 around (i L , j L ). Draw the mouse cursor on the right overlay image. The mouse cursor is drawn on the overlay image as shown in FIG. 32 around (i R , j R ). The drawing state is the cursors 606L and 606R in FIG. The process ends.

【0129】ステップS94において、カーソル可視属
性がFALSEであれば、マウスカーソルを左右のオー
バーレイ画像から消去する。処理を終了する。
At step S94, if the cursor visibility attribute is FALSE, the mouse cursor is deleted from the left and right overlay images. The process ends.

【0130】[アルゴリズムH]キーボードまたは、マ
ウスなどの入力装置によりパラメータ変更機能を提供す
る。パラメータ変更処理であるアルゴリズムHの流れを
図33及び図34に従って説明する。
[Algorithm H] A parameter changing function is provided by an input device such as a keyboard or a mouse. The flow of algorithm H, which is a parameter change process, will be described with reference to FIGS.

【0131】変更可能なパラメータとしては、目盛り間
隔を例とするが、他のパラメータでも可能である。マウ
スカーソル、パラメータおよびGUIは入力手段による
入力が一定時間以上ない場合は画面から消去する。入力
が再開されると自動的にパラメータおよび、GUIは再
描画される。
The changeable parameter is, for example, a scale interval, but other parameters can be used. The mouse cursor, parameters, and GUI are deleted from the screen when there is no input by the input means for a predetermined time or more. When the input is restarted, the parameters and GUI are automatically redrawn.

【0132】ステップS1 0 1において、キーボー
ド、マウスなどの入力がない状態、つまりアイドル状態
が所定の時間を超えたかどうか判断する。超えた場合
は、ステップS1O2を実施、そうでない場合はステッ
プS103を実施する。
In step S101, it is determined whether or not there is no input from the keyboard, mouse, etc., that is, whether or not the idle state has exceeded a predetermined time. If it exceeds, step S1O2 is executed, and if not, step S103 is executed.

【0133】ステップS102において、GUI可視属
性、パラメータ可視属性をFALSEに変更し、アルゴ
リズムE、アルゴリズムFを使用してGUI及びパラメ
ータを消去する。カーソル可視属性をFALSEに変更
し、アルゴリズムGによりマウスカーソルを消去する。
In step S102, the GUI visible attribute and the parameter visible attribute are changed to FALSE, and the algorithm and the algorithm F are used to erase the GUI and the parameter. The cursor visibility attribute is changed to FALSE, and the mouse cursor is erased by the algorithm G.

【0134】ステップS103において、キーボードの
入力を判断する。入力がなければステップS106を実
行する。
In step S103, keyboard input is determined. If there is no input, step S106 is executed.

【0135】ステップS104において、パラメータ可
視属性をTRUEに変更し、アルゴリズムFにより再描
画する。
In step S104, the parameter visibility attribute is changed to TRUE, and redrawing is performed using algorithm F.

【0136】ステップS105において、入力されたキ
ー判定を行う。例えばテンキー「1」で−1パラメータ
減少、テンキー「3」で+1パラメータ増加とする。
「1」が押された場合目盛間隔を−1[mm]し、
「3」が押された場合目盛間隔を+1[mm]する。そ
の後、アルゴリズムB、Aの順に呼び出し目盛を再描画
する。ステップS106において、変更後のパラメータ
をアルゴリズムFにより再描画する。
In step S105, the entered key is determined. For example, the numeric keypad “1” decreases by −1 parameter, and the numeric keypad “3” increases +1 parameter.
When "1" is pressed, the scale interval is set to -1 [mm],
When "3" is pressed, the scale interval is increased by +1 [mm]. After that, the call scale is redrawn in the order of the algorithms B and A. In step S106, the parameters after the change are redrawn by the algorithm F.

【0137】ステップS107において、マウスの入力
を判断する。マウスの入力がなければステップS112
を実施する。
In step S107, a mouse input is determined. If there is no mouse input, step S112
Is carried out.

【0138】ステップS108において、マウスが移動
された場合は、GUI可視属性、パラメータ可視属性を
TRUEに変更し、アルゴリズムE、Fを使用してGU
I、パラメータを描画する。カーソル可視属性をTRU
Eに変更し、アルゴリズムGによりカーソルを描画す
る。
If the mouse is moved in step S108, the GUI visibility attribute and the parameter visibility attribute are changed to TRUE, and the GUI
I, draw parameters. TRU cursor visibility attribute
Change to E and draw the cursor using algorithm G.

【0139】ステップS109において、マウス左ボタ
ンを押された場合はカーソルがGUI領域に存在するか
どうか判断する。GUI領域ならばステップS110を
実施し、そうでない場合はステップS112を実施す
る。
In step S109, when the left mouse button is pressed, it is determined whether or not the cursor exists in the GUI area. If it is in the GUI area, step S110 is performed; otherwise, step S112 is performed.

【0140】ステップS110において、GUI領域を
判断する。「−」ボタンならば、目盛間隔を−1[m
m]し、アルゴリズムB、アルゴリズムAの順で呼び出
し目盛を再描画する。「+」ボタンならば、目盛間隔を
+1[mm]し、アルゴリズムB、アルゴリズムAの順
で呼び出し目盛を再描画する。
In step S110, a GUI area is determined. If the "-" button, the scale interval is -1 [m
m], and the call scale is redrawn in the order of algorithm B and algorithm A. In the case of the "+" button, the scale interval is set to +1 [mm], and the call scale is redrawn in the order of algorithm B and algorithm A.

【0141】ステップS111において、変更後のパラ
メータをアルゴリズムFにより再描画する。
In step S111, the changed parameters are redrawn by the algorithm F.

【0142】ステップS112においてアプリケーショ
ンの終了を判定する。終了ならば処理を終了する。そう
でなければステップS101に戻る。
At step S112, the termination of the application is determined. If completed, the process ends. Otherwise, the process returns to step S101.

【0143】図35ないし図48は本発明の第2の実施
の形態に係わり、図35はホストコンピュータによる処
理の流れを示す第1のフローチャート、図36は図35
の第1のフローチャートに続く第2のフローチャート、
図37は図35及び図36の処理の作用を説明する第1
の図、図38は図35及び図36の処理の作用を説明す
る第2の図、図39は図35及び図36の処理の作用を
説明する第3の図、図40は図35及び図36の処理の
作用を説明する第4の図、図41は図36の第2のフロ
ーチャートの変形例の処理の流れを示すフローチャー
ト、図42は図41のフローチャートの作用を説明する
第1の図、図43は図41のフローチャートの作用を説
明する第2の図、図44は図41のフローチャートの作
用を説明する第3の図、図45は図41のフローチャー
トの作用を説明する第4の図、図46は図41のフロー
チャートの作用を説明する第5の図、図47は図41の
フローチャートの作用を説明する第6の図、図48は図
41のフローチャートの作用を説明する第7の図であ
る。
FIGS. 35 to 48 relate to the second embodiment of the present invention. FIG. 35 is a first flowchart showing the flow of processing by the host computer, and FIG.
A second flowchart following the first flowchart of
FIG. 37 is a first diagram illustrating the operation of the processing in FIGS. 35 and 36.
38, FIG. 38 is a second diagram illustrating the operation of the process of FIGS. 35 and 36, FIG. 39 is a third diagram illustrating the operation of the process of FIGS. 35 and 36, and FIG. FIG. 41 is a fourth diagram illustrating the operation of the process of FIG. 36, FIG. 41 is a flowchart illustrating the flow of a process of a modification of the second flowchart of FIG. 36, and FIG. 42 is a first diagram illustrating the operation of the flowchart of FIG. 43 is a second diagram illustrating the operation of the flowchart of FIG. 41, FIG. 44 is a third diagram illustrating the operation of the flowchart of FIG. 41, and FIG. 45 is a fourth diagram illustrating the operation of the flowchart of FIG. FIG. 46 is a fifth diagram illustrating the operation of the flowchart of FIG. 41, FIG. 47 is a sixth diagram illustrating the operation of the flowchart of FIG. 41, and FIG. 48 is a seventh diagram illustrating the operation of the flowchart of FIG. FIG.

【0144】第2の実施の形態は、第1の実施の形態と
ほとんど同じであるので、異なる点のみ説明し、同一の
構成には同じ符号をつけ説明は省略する。
Since the second embodiment is almost the same as the first embodiment, only different points will be described, and the same components will be denoted by the same reference numerals and description thereof will be omitted.

【0145】第2の実施の形態において、機器構成は第
1の実施の形態と同様である。本実施の形態の説明を工
業用分野で行うが、医療分野および、その他の分野でも
同様に実施することが可能である。ここでは、エンジン
のタービンブレードの計測を例に説明を行う。
In the second embodiment, the device configuration is the same as in the first embodiment. The present embodiment will be described in the industrial field, but can be similarly performed in the medical field and other fields. Here, a description will be given of an example of measurement of a turbine blade of an engine.

【0146】具体的にはブレードの図37に示すクラッ
ク(ひび割れ)の大きさを計測する。計測されたクラッ
クの大きさによりブレード交換の実施が判断される。
More specifically, the size of a crack (crack) shown in FIG. 37 of the blade is measured. The blade replacement is determined based on the measured crack size.

【0147】以下では、対象を立体視した状況下で、ク
ラックの両端を入力装置で指定し、クラックの大きさを
計測後、計測結果を表示する流れを図35及び図36に
従って説明する。入力装置としてマウスを例に説明する
が、他のデバイスでも可能である。
In the following, a description will be given of a flow in which both ends of a crack are designated by an input device, the size of the crack is measured, and the measurement result is displayed in a situation where the object is stereoscopically viewed, with reference to FIGS. 35 and 36. Although a mouse is described as an example of the input device, other devices are also possible.

【0148】ステップS200において、第1の実施の
形態によりタービンブレードの立体視を行う。
In step S200, the turbine blade is stereoscopically viewed according to the first embodiment.

【0149】ステップS201において、第1の実施の
形態のステップS10、11と同様にアルゴリズムGに
より、図37のようにオーバレイ画像にマウスカーソル
621L、621Rを描画する。カーソル可動領域を左
原画像全体とする。
In step S201, the mouse cursors 621L and 621R are drawn on the overlay image as shown in FIG. 37 by the algorithm G as in steps S10 and S11 of the first embodiment. The cursor movable area is the entire left original image.

【0150】ステップS202において、マウスのボタ
ン入力を判断する。左ボタン入力があればステップS2
05を実行する。
In step S202, it is determined whether a mouse button has been input. If there is a left button input, step S2
Execute 05.

【0151】ステップS203において、マウスカーソ
ルの移動に応じて、アルゴリズムGによりオーバーレイ
画像にマウスカーソルを描画する。
In step S203, the mouse cursor is drawn on the overlay image by algorithm G according to the movement of the mouse cursor.

【0152】ステップS204において、アプリケーシ
ョンの終了判断を行う。終了ならば処理を終了する。そ
うでなければステップS202に戻る。
In step S204, the termination of the application is determined. If completed, the process ends. Otherwise, the process returns to step S202.

【0153】ステップS205において、図37のよう
にマウスカーソルの位置に図形620L、622L、6
20R、622Rを描画する。描画は、第1の実施の形
態のアルゴリズムDと同様に左右オーバーラップ画像に
行う。
In step S205, the figures 620L, 622L, 6
20R and 622R are drawn. Drawing is performed on the left and right overlapping images in the same manner as in the algorithm D of the first embodiment.

【0154】内視鏡先端から図形までの距離はマウスカ
ーソルと同じDis5[mm]とする。マウスにより1点
ずつ合計2点を指定し、クラック両端を指定する。これ
を指定点と呼び、それぞれをP[0] L、P[1] Lとする。ス
テップS206で1点目の指定の場合は、ステップS2
02に戻る。2点目が指定された場合は、ステップS2
07に進む。なお、1点目の指定の際に、以前の2点の
指定点がすでに描画されていればマウスカーソルの位置
に図形を描画する前に消去する。
The distance from the tip of the endoscope to the figure is set to the same Dis5 [mm] as the mouse cursor. A total of two points are designated one by one with the mouse, and both ends of the crack are designated. These are called designated points, and are designated as P [0] L and P [1] L , respectively. If the first point is specified in step S206, step S2
Return to 02. If the second point is designated, step S2
Proceed to 07. Note that when the first point is specified, if the previous two specified points have already been drawn, they are deleted before drawing the figure at the position of the mouse cursor.

【0155】ステップS207において、左右原画像を
歪曲収差補正する。歪曲収差補正済み画像を左画像、右
画像と呼ぶ。
In step S207, the left and right original images are corrected for distortion. The distortion corrected images are referred to as a left image and a right image.

【0156】ステップS208において、左右画像に対
して前処理を行う。公知のエッジ検出方法で左右画像の
エッジを検出する。所定の閾値Th1によりエッジ画像を
2値化する。次に、細線化によりエッジを1画素の幅に
整えた後、小さいエッジ群を消去する。まず、公知のラ
ベリングによりエッジ群に番号をつける。同じ番号が振
られたエッジ群の画素数を調べ、画素数が閾値Th2より
小さいエッジを消去する。左画像における各エッジをE
[i] L(i=0,1,2,‥‥)とする。細線化は文献1
(C言語で学ぶ実践画像処理、井上誠喜他著、オーム
社)に詳しい。
In step S208, preprocessing is performed on the left and right images. The edges of the left and right images are detected by a known edge detection method. The edge image is binarized by a predetermined threshold Th1. Next, after the edges are adjusted to the width of one pixel by thinning, small edge groups are erased. First, the edge groups are numbered by known labeling. The number of pixels of the edge group assigned the same number is checked, and edges having the number of pixels smaller than the threshold Th2 are deleted. Each edge in the left image is E
[i] Let L (i = 0, 1, 2,...). Reference 1
(Practical image processing in C language, written by Seiki Inoue et al., Ohmsha).

【0157】ステップS209において、指定点とエッ
ジの3次元位置を求める。第1の実施の形態同様の方法
により、P[0] L、P[1] L、E[i] L(i=0,1,2,‥
‥)の順補正対応の画素を求める。それぞれを
[0] L'、P[1] L'、E[i] L'(i=0,1,2,‥‥)
とする。対応点の検出によりP[0] L'、P[1] L'、E[i]
L'に対応する像の3次元位置を求める。
In step S209, the three-dimensional positions of the designated point and the edge are obtained. By the same method as in the first embodiment, P [0] L , P [1] L , and E [i] L (i = 0, 1, 2,.
画素) A pixel corresponding to the forward correction is obtained. P [0] L ' , P [1] L' , E [i] L ' (i = 0, 1, 2,...)
And P [0] L ' , P [1] L' , E [i]
The three-dimensional position of the image corresponding to L ' is obtained.

【0158】対応点検出は、左右画像に対する公知のエ
ピポーラ拘束を用いたテンプレートマッチングにより求
める。
The corresponding points are detected by template matching using known epipolar constraints on the left and right images.

【0159】図38のようにテンプレートは、P[0] L'
または、P[1] L'または、E[i] L'の座標を中心とした小
領域を切り取り作成する。
As shown in FIG. 38, the template is P [0] L '
Alternatively, a small area centered on the coordinates of P [1] L ' or E [i] L' is cut out and created.

【0160】図38ではE[i] L'の座標を中心としたテ
ンプレートを示している。その対応点をP[0] R'、P[1]
R'、E[i] R'(i=0,1,2,‥‥)とする(これら
の逆補正対応画素はP[0] R、P[1] R、E[i] R(i=0,
1,2,‥‥)である)。
FIG. 38 shows a template centered on the coordinates of E [i] L ' . The corresponding points are P [0] R ' and P [1]
R ′ , E [i] R ′ (i = 0, 1, 2, ‥‥) (these pixels corresponding to the inverse correction are P [0] R , P [1] R , E [i] R (i = 0,
1, 2, ‥‥)).

【0161】三角測量の原理によりP[0] L'、P[1] L'
[i] L'に対応する像の3次元位置P[0] L' W(x[0] L'
[0] L',z[0] L')、P[1] L' W(x[1] L',y[1] L',z
[1] L')、E[i] L' W(xE[i] L',yE[i] L',zE[i] L'
を決定する。三角測量の原理は、特開平6−33945
4号公報などに詳しい。
According to the principle of triangulation, P[0] L ', P[1] L ',
E[i] L 'Three-dimensional position P of the image corresponding to[0] L ' W(X[0] L ',
y[0] L ', Z[0] L '), P[1] L ' W(X[1] L ', Y[1] L ', Z
[1] L '), E[i] L ' W(XE [i] L ', YE [i] L ', ZE [i] L ')
To determine. The principle of triangulation is described in JP-A-6-33945.
No.4 is detailed.

【0162】ステップS209において、指定点の3次
元位置P[0] L' W、P[1] L' Wを通過する直線Lmを決定す
る。
In step S209, a straight line Lm passing through the three-dimensional positions P [0] L ' W and P [1] L' W of the designated point is determined.

【0163】[0163]

【数26】 ステップS210において、図39のようにE[i] L' W
Lmの距離をすべて求める。その中から最大距離Mmaxを
求める。
(Equation 26) In step S210, all distances between E [i] L' W and Lm are obtained as shown in FIG. The maximum distance Mmax is determined from the values.

【0164】ステップS211において、図40のよう
にでオーバーラップ画像上で、最大距離を示すE[i] L'
の逆補正対応位置座標E[i] L及びその対応点E[i] Rに図
形を描画し、その図形近傍に距離Mmaxを表示する(図
23では、8.5mm)。マークする方法は第1の実施
の形態におけるアルゴリズムDと同様に行い、距離表示
方法は第1の実施の形態におけるアルゴリズムFと同様
に行うことで立体的に表示する。ステップS202に戻
る。
In step S211, E [i] L ′ indicating the maximum distance on the overlap image as shown in FIG.
Is drawn at the inverse correction corresponding position coordinate E [i] L and its corresponding point E [i] R , and the distance Mmax is displayed near the figure (8.5 mm in FIG. 23). The method of marking is performed in the same manner as in the algorithm D in the first embodiment, and the method of displaying the distance is performed in the same manner as the algorithm F in the first embodiment to display three-dimensionally. It returns to step S202.

【0165】以上により対象を立体視しながら、対象の
大きさを計測することが可能となり、さらに立体視した
状態で計測結果を見ることができる。なお指定点の入力
時は、画面をフリーズ状態で行うようにしても良い。
As described above, it is possible to measure the size of the target while viewing the target in a stereoscopic manner, and furthermore, it is possible to see the measurement result in a state where the target is viewed in a stereoscopic manner. When inputting the designated point, the screen may be frozen.

【0166】また、計測対象の指定として次のような方
法も考えられる。以下では、対象を立体視した状況下
で、クラックを含む領域を入力装置で指定し、クラック
の大きさを計測後、計測結果を表示する流れを図41に
従って説明する。入力装置としてマウスを例に説明する
が、他のデバイスでも可能である。クラック部分を囲む
図形としては、矩形で説明するが、円、矩形、自由曲線
などが考えられ、矩形に限定されるものでない。
The following method is also conceivable for designating the measurement object. In the following, a description will be given of a flow of displaying a measurement result after specifying a region including a crack with the input device and measuring the size of the crack in a situation where the target is viewed stereoscopically, with reference to FIG. 41. Although a mouse is described as an example of the input device, other devices are also possible. Although the figure surrounding the crack portion will be described as a rectangle, a circle, a rectangle, a free curve, and the like can be considered, and the figure is not limited to a rectangle.

【0167】ステップS201〜ステップS204は同
じである。ただし、ステップS202において左ボタン
入力時に実行されるステップをステップS220とす
る。以下、異なる処理を説明する。
Steps S201 to S204 are the same. However, the step executed when the left button is input in step S202 is referred to as step S220. Hereinafter, different processes will be described.

【0168】ステップS220において、図42のよう
に、マウスカーソル621Lにより始点及び対角を為す
対角点の2点を指定することで矩形領域630Lを指定
する。この矩形領域630Lは、図43に示すように、
対角点を指定してマウスカーソル621Lを移動するこ
とで変更が可能となっており、矩形領域630Lは第1
の実施の形態のアルゴリズムDと同様に左右オーバーラ
ップ画像に描画する。内視鏡先端から矩形までの距離は
マウスカーソル621Lと同じDis5[mm]とする。
In step S220, as shown in FIG. 42, a rectangular area 630L is designated by designating two points, a starting point and a diagonal point forming a diagonal point, with the mouse cursor 621L. This rectangular area 630L, as shown in FIG.
By changing the mouse cursor 621L by specifying a diagonal point, the change can be performed.
Is drawn on the left and right overlap images in the same manner as the algorithm D of the embodiment. The distance from the tip of the endoscope to the rectangle is set to the same Dis5 [mm] as the mouse cursor 621L.

【0169】ステップS221において、左右原画像を
歪曲収差補正する。歪曲収差済み画像を左画像、右画像
と呼ぶ。
In step S221, the left and right original images are corrected for distortion. The distortion-corrected images are called a left image and a right image.

【0170】ステップS222において、左画像におい
て、矩形領域内の公知のエッジ検出方法で領域内の輪郭
線を2値画像として抽出する。細線化によりエッジを1
画素の幅に整える。
In step S222, in the left image, the outline in the rectangular area is extracted as a binary image by a known edge detection method. 1 edge by thinning
Trim to pixel width.

【0171】ステップS223において、左画像の矩形
領域内において、公知のラベリングにより輪郭線に番号
を割り当て、輪郭線を区別する。同じ番号が振られたエ
ッジ群の画素数を調べ、画素数が閾値Th2より小さいエ
ッジを消去し、小さいエッジ群を消去する。その後、矩
形領域内で最大個数含まれる番号Lvを求める。
In step S223, in the rectangular area of the left image, numbers are assigned to the outlines by known labeling, and the outlines are distinguished. The number of pixels of the edge group assigned the same number is checked, edges having a pixel number smaller than the threshold Th2 are deleted, and small edge groups are deleted. Thereafter, the number Lv included in the maximum number in the rectangular area is obtained.

【0172】ステップS224において、図44のよう
に左画像の矩形領域内の番号Lvを持つ輪郭線を領域左
から右へ、上から下へ走査して探索する。最初のLvを
持つ輪郭の画像での座標をStL'(iL'st,jL'st)と
する。
In step S224, as shown in FIG. 44, a contour line having a number Lv in the rectangular area of the left image is searched by scanning the area from left to right and from top to bottom. Let the coordinates of the contour image having the first Lv be St L ′ (i L ′ st, j L ′ st).

【0173】StL'(iL'st,jL'st)を追跡開始位置
として、すべての輪郭線E[n] L'(n=0,1,2,‥
‥,NE)を輪郭線追跡する。ここで、NEは輪郭線の
個数である。追跡途中で領域外に達した場合はその時点
で、追跡を終了する。各輪郭線に含まれる画素をe
[n,m] L'(m=0,1,2,‥‥,NPn)とする。ここ
で、NPnは輪郭線E[n] L'に含まれているエッジの個数
である。図45は、E[0] L'、E[1] L'、E[2] L'が抽出
された例を示す。E[0] L'はStL'(iL'st,jL'st)を
開始点として、図45のようにE[0] L'の追跡終了点ま
でが抽出されている。E[1] L'はStL'(iL'st,jL's
t)を開始点として、図45のようにE[1] L'の追跡終了
点までが抽出されteいる。E[2] L'も同様である。
Using St L ′ (i L ′ st, j L ′ st) as the tracking start position, all the contour lines E [n] L ′ (n = 0, 1, 2,.
{, NE) is traced. Here, NE is the number of contour lines. If it reaches outside the area during tracking, tracking ends at that point. Pixels included in each contour are denoted by e
[n, m] L ′ (m = 0, 1, 2, ‥‥, NPn). Here, NPn is the number of edges included in the contour line E [n] L ' . FIG. 45 shows an example in which E [0] L ′ , E [1] L ′ , and E [2] L ′ are extracted. E [0] L ' is extracted from the start point of St L' (i L ' st, j L' st) to the tracking end point of E [0] L ' as shown in FIG. E [1] L ' is St L' (i L ' st, j L' s
Starting from t), as shown in FIG. 45, up to the tracking end point of E [1] L ' is extracted. The same applies to E [2] L ' .

【0174】ステップS225において、抽出された輪
郭線から主要な輪郭線を決定する。輪郭線が1つのみ抽
出された場合は以下の処理は行わない。 E[n] L'から主
要輪郭線を決定する方法として、ここでは以下の条件を
満たすものから2つを選択する。若い番号ほど優先して
選択するものとする。
In step S225, a main contour is determined from the extracted contours. If only one contour is extracted, the following processing is not performed. As a method for determining the main contour from E [n] L ', two methods are selected here that satisfy the following conditions. The younger the number, the higher the priority.

【0175】条件1:E[n] L'始点から出発して、計測
領域を示す矩形まで達しているものを選択する。 条件2:E[n] L'の中からもっとも長い輪郭線を選択す
る。
Condition 1: Starting from the start point of E [n] L ', a point that reaches the rectangle indicating the measurement area is selected. Condition 2: The longest contour line is selected from E [n] L ' .

【0176】図45では、条件1、条件2とも満たすE
[0] L'、E[1] L'が選択される。E[0 ] L'、E[1] L'ともS
tL'(iL'st,jL'st)を開始点とした輪郭線である
が、両輪郭線から連続した1つの輪郭線を作成する。こ
れは、一方の輪郭線の画素順序を反転してもう一方と合
成することで可能である。ただし、両輪郭線ともStL'
(iL'st,jL'st)を含んでいるので、一方の輪郭線の
StL'(iL'st,jL'st)を削除する必要がある。
In FIG. 45, E satisfying both the conditions 1 and 2 is satisfied.
[0] L ' and E [1] L' are selected. E [0 ] L ' and E [1] L' are both S
A contour line starting from t L ′ (i L ′ st, j L ′ st) is created from the two contour lines. This can be done by inverting the pixel order of one contour line and combining it with the other. However, both contour lines are St L '
(I L 'st, j L ' st) because it contains, it is necessary to remove the St L of one contour line '(i L' st, j L 'st).

【0177】図46に示すE[0] L'{e[0,0] L',e
[0,1] L',‥‥,e[0,NP0] L'}、E[1] L '{e[1,0] L'
[1,1] L',‥‥,e[1,NP1] L'}において、E[0] L'
反転して、画素列E[0][1] L'{e[0,NP0] L',e
[0,NP-1] L',‥‥,e[0,1] L',e[1,0 ] L'
[1,1] L',‥‥,e[1,NP1] L'}ができる。この例では
E0の輪郭線の開始点e[0,0] L'を削除している。前記E
[0][1] L'を図47のようにE[0][1] L'{e[0] L'
[1] L',‥‥,e[NP0+NP1-1] L'}と表記し直す。
E [0] L ' {e [0,0] L' , e shown in FIG.
[0,1] L ' , ‥‥, e [0, NP0] L' }, E [1] L ' {e [1,0] L' ,
In e [1,1] L ' , { , e [1, NP1] L' }, E [0] L ' is inverted to obtain a pixel sequence E [0] E [1] L' {e [0 , NP0] L ' , e
[0, NP-1] L ' , ‥‥, e [0,1] L' , e [1,0 ] L ' ,
e [1,1] L ' , { , e [1, NP1] L' }. In this example, the start point e [0,0] L ' of the contour line of E0 is deleted. Said E
[0] E [1] L ' is changed to E [0] E [1] L' {e [0] L ' , as shown in FIG.
e [1] L ' , ‥‥, e [NP0 + NP1-1] L' }.

【0178】ステップS226において、ステップS2
08同様エピポーラ拘束を用いたパターンマッチングお
よび、三角測量の原理により画素列E[0][1] L'の3次
元位置E[0][1] L' W{e[0] L',e[1] L',‥‥,e
[NP0+NP1-1] L'}を決定する。特に、e[0] L'
[0] L'、e[NP0+NP1-1] L'をP[1] L'と表し、その3次
元位置をP [0] L' W(x[0] L',y[0] L',z[0] L')、P
[1] L' W(x[1] L',y[1] L',z[1] L')とする。
In step S226, step S2
08 and pattern matching using epipolar constraints
And a pixel row E based on the principle of triangulation.[0]E[1] L '3rd
Original position E[0]E[1] L ' W{E[0] L ', E[1] L ', ‥‥, e
[NP0 + NP1-1] L 'Determine}. In particular, e[0] L 'To
P[0] L ', E[NP0 + NP1-1] L 'To P[1] L 'And the third order
Original position is P [0] L ' W(X[0] L ', Y[0] L ', Z[0] L '), P
[1] L ' W(X[1] L ', Y[1] L ', Z[1] L ').

【0179】ステップS227において、P[0] L' W
[1] L' Wにより直線Lmを決定する。
In step S227, P [0] L ' W ,
A straight line Lm is determined from P [1] L' W .

【0180】[0180]

【数27】 [0][1] L' Wの各エッジと直線Lmとの距離を求め、そ
の中から最大距離とその時のエッジを求める。
[Equation 27] E [0] E [1] The distance between each edge of L' W and the straight line Lm is obtained, and the maximum distance and the edge at that time are obtained from the distance.

【0181】ステップS228において、図48のよう
にオーバーラップ画像上で、最大距離を示すE[0][1]
L'の逆補正対応位置座標E[0][1] Lに図形を描画し
(633L、633R)、その図形近傍に距離Mmax
(632L、632R)を表示する。マークする方法は
第1の実施の形態におけるアルゴリズムDと同様に行
い、距離表示方法は第1の実施の形態におけるアルゴリ
ズムFと同様に行うことで立体的に表示する。ステップ
S202に戻る。
In step S228, E [0] E [1] indicating the maximum distance on the overlap image as shown in FIG.
A figure is drawn at the position coordinates E [0] E [1] L corresponding to the inverse correction of L ' (633L, 633R), and a distance Mmax is provided near the figure.
(632L, 632R) is displayed. The method of marking is performed in the same manner as in the algorithm D in the first embodiment, and the method of displaying the distance is performed in the same manner as the algorithm F in the first embodiment to display three-dimensionally. It returns to step S202.

【0182】以上により対象を立体視しながら、対象の
計測対象を囲むことで計測が容易にでき、さらに立体視
した状態で計測結果を見ること可能となる。なお指定点
の入力時は、画面をフリーズ状態で行うようにしても良
い。
As described above, the measurement can be easily performed by surrounding the object to be measured while the object is stereoscopically viewed, and the measurement result can be viewed in a stereoscopic state. When inputting the designated point, the screen may be frozen.

【0183】図49ないし図52は本発明の第3の実施
の形態に係わり、図49はホストコンピュータによる処
理の流れを示すフローチャート、図50は図49のフロ
ーチャートの作用を説明する第1の図、図51は図49
のフローチャートの作用を説明する第2の図、図52は
図49のフローチャートで使用されるアルゴリズムJの
処理の流れを示すフローチャートである。
FIGS. 49 to 52 relate to the third embodiment of the present invention. FIG. 49 is a flowchart showing the flow of processing by the host computer, and FIG. 50 is a first diagram for explaining the operation of the flowchart of FIG. FIG. 51 shows FIG.
FIG. 52 is a flow chart showing the flow of processing of algorithm J used in the flow chart of FIG. 49.

【0184】第3の実施の形態は、第1の実施の形態と
ほとんど同じであるので、異なる点のみ説明し、同一の
構成には同じ符号をつけ説明は省略する。
Since the third embodiment is almost the same as the first embodiment, only different points will be described, and the same components will be denoted by the same reference numerals and description thereof will be omitted.

【0185】第1の実施の形態と同様に立体目盛を内視
鏡先端からDis1[mm]で表示することを考える。内
視鏡先端から対象までの距離がDis1[mm]より近い
場合においても立体目盛を表示すると、対象に隠れるべ
き立体目盛が見えているのであるから違和感がある。
As in the first embodiment, it is assumed that the solid scale is displayed in Dis1 [mm] from the endoscope end. If the solid scale is displayed even when the distance from the endoscope end to the object is shorter than Dis1 [mm], there is a sense of discomfort because the solid scale to be hidden by the object is visible.

【0186】そこで、内視鏡先端から対象までの距離が
Dis1[mm]より近い場合に、立体図形を表示しない
立体視システムを以下に示す。
Therefore, a stereoscopic vision system that does not display a stereoscopic figure when the distance from the endoscope end to the object is shorter than Dis1 [mm] will be described below.

【0187】以下では、距離に応じて表示を停止する立
体図形の例として立体目盛で説明するが、図形は、立体
目盛に限定されるものではなく、例えば第1の実施の形
態のアルゴリズムDにおける十字図形などでも、同様の
処理を十字図形に対して実施することで距離に応じて表
示を停止することが可能である。また、表示を停止する
立体図形は複数でもよく、各図形に対して同様の停止処
理を行うことで距離に応じて表示を停止することが可能
である。
In the following, a three-dimensional scale will be described as an example of a three-dimensional figure whose display is stopped in accordance with the distance. However, the figure is not limited to the three-dimensional scale. For example, the figure is not limited to the three-dimensional scale. Even in the case of a cross figure or the like, display can be stopped according to the distance by performing the same processing on the cross figure. In addition, there may be a plurality of three-dimensional figures for which the display is stopped, and the display can be stopped according to the distance by performing the same stop processing for each figure.

【0188】第1の実施の形態同様に、図8及び図9の
ように水平方向に5個、垂直方向に5個の目盛を左オー
バーレイ画像および、右オーバーレイ画像に描画するこ
とを考える。第1の実施の形態では内視鏡先端から目盛
までの距離をあらかじめ与えたが、本実施の形態では、
対象の実際の3次元座標を求め、その位置に目盛を描画
する。
As in the first embodiment, it is assumed that five scales in the horizontal direction and five scales in the vertical direction are drawn on the left overlay image and the right overlay image as shown in FIGS. In the first embodiment, the distance from the endoscope tip to the scale is given in advance, but in the present embodiment,
The actual three-dimensional coordinates of the object are obtained, and a scale is drawn at that position.

【0189】図8のように左画像の各目盛描画座標をM
[k] L'(i[k] L',j[k] L')(k=0,1,‥‥,
9)、図9のように右画像の目盛描画座標をM
[k] R'(i[k] R',j[k] R')(k=0,1,‥‥,9)
と表す。図8のように水平目盛の中心はM[ 2] L'(i[2]
L',j[2] L')である。代表として、M
[2] L'(i[2] L',j[2] L')(もしくは、垂直目盛の中
心M[7] L'(i[7] L',j[7] L'))に映っている物体の
3次元位置γ(xL W,yL W,zL W)を求める。zL Wを通
過する鉛直平面上に対象があると仮定して、第1の実施
の形態同様に目盛間隔および左右オーバーレイ画像のお
ける目盛描画座標を決定し、左右オーバレイ画像に目盛
を描画する。オーバーレイ画像は公知のキーイング技術
により左右原画像と合成される。
As shown in FIG. 8, each scale drawing coordinate of the left image is M
[k] L ' (i [k] L' , j [k] L ' ) (k = 0, 1, ‥‥,
9), as shown in FIG.
[k] R ' (i [k] R' , j [k] R ' ) (k = 0,1, ‥‥, 9)
It expresses. As shown in FIG. 8, the center of the horizontal scale is M [ 2] L ′ (i [2]
L ' , j [2] L' ). As a representative, M
[2] L ' (i [2] L' , j [2] L ' ) (or the center of the vertical scale M [7] L' (i [7] L ' , j [7] L' )) reflected by the three-dimensional position γ of the object are (x L W, y L W , z L W) determined. Assuming that the target is on a vertical plane passing through z L W , the scale interval and the scale drawing coordinates in the left and right overlay images are determined as in the first embodiment, and the scale is drawn on the left and right overlay images. The overlay image is synthesized with the left and right original images by a known keying technique.

【0190】次に、内視鏡先端に対して対象がzL W[m
m]より近づいたことを検出する方法を述べる。
[0190] Next, subject to the distal end of the endoscope is z L W [m
m] will be described.

【0191】図50において、左右カメラの位置は固定
されているとする。今、左カメラと対象との距離をξと
する。左画像上の点Q1に対応する対象上の点Qは、Q1
と左光学中心Oleftを通過する直線と対象との交点から
求めることができる。Qに対する右画像上の像Q2はQ
と右光学中心Orightを通過する直線と右画像との交点
から求めることができる。
In FIG. 50, it is assumed that the positions of the left and right cameras are fixed. Now, let ξ be the distance between the left camera and the target. The point Q on the object corresponding to the point Q1 on the left image is Q1
And the straight line passing through the left optical center O left and the intersection with the object. The image Q2 on the right image for Q is Q
And the right image passing through the right optical center O right .

【0192】次に、左カメラと対象との距離をξ’
(ξ’<ξ)とする。左画像上の点Q1に対応する対象上
の点Q’は、Q1と左光学中心を通過する直線と対象と
の交点から求めることができる。対象上の点Q’に対応
する右画像上の像Q2’の座標はQ2同様に求めることが
できる。つまり、左画像上のある決まった点(計測指定
点と呼ぶ)に対する右画像上の対応点の座標は、カメラ
と対象間の距離により変化するが、一意に決めることが
できる。
Next, the distance between the left camera and the target is ξ ′.
(Ξ '<ξ). The point Q 'on the object corresponding to the point Q1 on the left image can be obtained from the intersection of Q1 and a straight line passing through the left optical center with the object. The coordinates of the image Q2 'on the right image corresponding to the point Q' on the object can be obtained in the same manner as Q2. That is, the coordinates of the corresponding point on the right image with respect to a certain point on the left image (referred to as a designated measurement point) vary depending on the distance between the camera and the object, but can be uniquely determined.

【0193】また、Q1およびQ2、Q2’は同じ対象の
像であるから、その近傍は類似している可能性が高い。
したがって、左カメラと対象までの距離を図51のよう
にz L W[mm]から0[mm]までρ[mm]ずつ近づ
けながら、k通り(kは正の整数)の左画像の計測指定
点(CxL',CyL')に対する右画像での対応点M[k] R '
(i[k] R',j[k] R')(k=0,1,2,‥‥)を求め
る(ρは実数)。現在、撮像されている左右画像で(Cx
L',CyL')とM[k] R'(i[k] R',j[k] R')(k=0,
1,2,‥‥)の類似度が高ければ、対象がDis1−
(ρ×k)の距離にあるという判断を下すことができる。
Further, Q1, Q2 and Q2 'are the same objects.
Since the image is an image, there is a high possibility that its vicinity is similar.
Therefore, the distance between the left camera and the target is as shown in FIG.
To z L WApproaching from [mm] to 0 [mm] by ρ [mm]
While specifying the measurement of the left image in k ways (k is a positive integer)
Point (CxL ', CyL ') In the right image[k] R '
(I[k] R ', J[k] R ') (K = 0,1,2, ‥‥)
(Ρ is a real number). Currently, the left and right images (Cx
L ', CyL ') And M[k] R '(I[k] R ', J[k] R ') (K = 0,
If the similarity of (1, 2, ‥‥) is high, the target is Dis1-
It can be determined that the distance is (ρ × k).

【0194】まず、内視鏡先端からzL W[mm]にある
立体目盛の描画位置を決定し、左右オーバーレイ画像に
描画する(ステップS251からステップS254)。
次に、内視鏡先端からの距離がzL W[mm]から0[m
m]間で、段階的に左画像(CxL',CyL')に対する右
画像での対応点を求め、記憶する(ステップS255〜
ステップS257)。類似度により内視鏡先端から対象
までの距離がzL W[mm]より近いかどうか判断して目
盛の描画、消去を行う(ステップS261〜267)と
いう流れで実現する。処理の流れを図49に従って説明
する。
[0194] First, to determine the drawing position of the solid scale in z L W [mm] from the endoscope distal end, to draw to the left and right overlay image (from step S251 step S254).
Next, 0 distance from the endoscope tip from the z L W [mm] [m
m] between stepwise left image (Cx L ', Cy L' ) determine the corresponding point in the right image for the stores (step S255~
Step S257). Distance from the endoscope tip to a subject by similarity scale drawing to determine whether closer z L W [mm], realized in the flow of erasing (step S261~267). The processing flow will be described with reference to FIG.

【0195】ステップS251において、現在撮影され
ている画像を用いて、水平目盛の中心座標M[2] L'(i
[2] L',j[2] L')に映っている対象の3次元座標を求め
る。つまり、その位置が目盛の3次元位置になる。本実
施の形態では、M[2] L'(i[ 2] L',j[2] L')の左画像
上での座標は本実施の形態では計測指定点(CxL',Cy
L')と同一とする。あらかじめ与えられた左画像におけ
るM[2] L'(i[2] L',j[2] L')の右画像における対応
点を、公知のエピポーラ拘束を用いたテンプレートマッ
チングにより求める。テンプレートは、M[2] L'(i[2]
L',j[2] L')を中心としたあらかじめ与えられたサイ
ズ(Tx×Ty)の小領域を作成する。対応点の座標を用
いて、三角測量の原理により計測指定点(CxL',C
yL')の3次元位置を求める。その座標をγ(xL W,yL
W,zL W)とする。
In step S251, the center coordinates M [2] L ' (i
[2] L ′ , j [2] L ′ ) The three-dimensional coordinates of the object shown in the figure are obtained. That is, that position becomes the three-dimensional position of the scale. In the present embodiment, the coordinates of M [2] L ' (i [ 2] L' , j [2] L ' ) on the left image are measured designated points (CxL ' , Cy) in the present embodiment.
L ' ). A corresponding point in the right image of M [2] L ' (i [2] L' , j [2] L ' ) in the left image given in advance is determined by template matching using a known epipolar constraint. The template is M [2] L ' (i [2]
A small area of a predetermined size (Tx × Ty) centering on L ′ , j [2] L ′ ) is created. Using the coordinates of the corresponding point, the designated measurement point (Cx L ' , C
y L ′ ) is obtained. Let the coordinates be γ (x L W , y L
W , z L W ).

【0196】ステップS252において、内視鏡先端か
らの目盛までの距離をzL Wとして、アルゴリズムBによ
りSc[mm]に対する1目盛の間隔[画素]を決定す
る。それらを左画像水平目盛間隔SpxL'、左画像垂直
目盛間隔SpyL'、右画像水平目盛間隔SpxR'、右画像
垂直目盛間隔SpyR'とする。
[0196] In step S252, the distance to the scale of the endoscope tip as z L W, the algorithm B to determine the Sc 1 scale interval for [mm] [pixels]. These are a left image horizontal scale interval Spx L ' , a left image vertical scale interval Spy L' , a right image horizontal scale interval Spx R ' , and a right image vertical scale interval Spy R' .

【0197】ステップS253において、左画像水平目
盛間隔SpxL'、左画像垂直目盛間隔SpyL'により、描
画位置を決定する。M[n] L'(n=0,1,‥‥,9)
は、あらかじめ与えられた左画像の計測指定点(C
xL',CyL')を用いて、次式で決定される。
In step S253, the drawing position is determined by the left image horizontal scale interval Spx L ' and the left image vertical scale interval Spy L' . M [n] L ' (n = 0, 1, ‥‥, 9)
Is the designated measurement point (C
x L ′ , Cy L ′ ) is determined by the following equation.

【0198】[0198]

【数28】 水平目盛 M[n] L'=(CxL'+SpxL'・(n−2),CyL') 垂直目盛 M[n] L'=(CxL' ,CyL'+ SpyL'・(n−6)) ( 28) ステップS254において、内視鏡先端から目盛までの
距離をzL W[mm]として、アルゴリズムAによりM
[n] L'(n=0,1,‥‥,9)の逆補正対応画素M[n]
L(n=0,1,‥‥,9)および、その対応点M[n] R
(n=0,1,‥‥,9)を求める。M[n] Lおよび、M
[n] R(n=0,1,‥‥,10)を用いてアルゴリズム
Cにより図10のように左オーバーレイ画像に立体目盛
600L、右オーバーレイ画像に600Rを描画する。
Equation 28] horizontal scale M [n] L '= ( Cx L' + Spx L '· (n-2), Cy L') vertical scale M [n] L '= ( Cx L', Cy L '+ Spy in L '· (n-6) ) (28) step S254, the distance from the endoscope tip to the scale as z L W [mm], M by algorithm a
[n] L ′ (n = 0, 1, ‥‥, 9) inverse correction corresponding pixel M [n]
L (n = 0, 1, ‥‥, 9) and its corresponding point M [n] R
(N = 0, 1,..., 9) is obtained. M [n] L and M
By using algorithm [n] R (n = 0, 1, ‥‥, 10), a solid scale 600L is drawn on the left overlay image and 600R is drawn on the right overlay image as shown in FIG.

【0199】ステップS255において、k=0とす
る。ステップS256において、内視鏡先端からの目盛
までの距離[mm]をzL W−(ρ×k)とする。ここで、ρ
は距離変化ステップとする。距離を変化させながら、ア
ルゴリズムAによりM[2] L'の対応点M[k] R'を求める。
[k] R'の座標をM[k] R'(i[k] R',j[k] R')とする。
In step S255, k = 0. In step S256, the distance [mm] to scale the endoscope tip z L W - and (ρ × k). Where ρ
Is a distance change step. While changing the distance, the corresponding point M [k] R ' of M [2] L' is obtained by the algorithm A.
M [k] R 'coordinates of M [k] R' (i [k] R ', j [k] R') to be.

【0200】ステップS257において、kを1増加
し、ステップS258でzL W−(ρ×k)>0ならばス
テップS256に戻る。
[0200] In step S257, the k 1 increased, z L W in step S258 - returns to the (ρ × k)> 0 if step S256.

【0201】ステップS259において、後述するアル
ゴリズムJによって目盛描画を行う。ステップS260
において、アプリケーション終了判定を行う。終了なら
ば処理を終了する。そうでなければステップS259に
戻る。
In step S259, scale drawing is performed using algorithm J described later. Step S260
In, an application end determination is made. If completed, the process ends. Otherwise, the process returns to step S259.

【0202】[アルゴリズムJ]対象までの距離に応じ
て目盛を描画、消去する処理の流れを図52に従って説
明する。
[Algorithm J] The flow of processing for drawing and erasing a scale according to the distance to an object will be described with reference to FIG.

【0203】ステップS261において、k=0とす
る。ステップS262において、計測指定点(CxL'
CyL')とM[k] R'(k=0,1,2,‥‥)それぞれを
中心とした小領域との相関をテンプレートマッチングに
よりM[k] R'(i[k] R',j[k] R ')を中心とした所定の
探索領域で求める。
At step S261, k = 0. In step S262, the designated measurement point (Cx L ' ,
Cy L ′ ) and M [k] R ′ (k = 0, 1, 2, ‥‥) are correlated with small areas centered on M [k] R ′ (i [k] R ′ ) by template matching. , J [k] R ) in a predetermined search area.

【0204】ステップS263において、M[k] R'(i
[k] R',j[k] R')の探索領域内の最大相関値が、所定の
閾値Th3より大きい場合は、先端からDis1未満に対象
が存在すると判断する。その場合ステップS266を実
行する。
In step S263, M [k] R ' (i
If the maximum correlation value in the search area of [k] R ' , j [k] R' ) is larger than a predetermined threshold Th3, it is determined that the target exists less than Dis1 from the tip. In that case, step S266 is executed.

【0205】ステップS264において、計測指定点と
すべてのM[k] R'(i[k] R',j[k] R ')との相関を調べ
終えた場合はステップS267を実行する。
In step S264, when the correlation between the designated measurement point and all M [k] R ' (i [k] R' , j [k] R ' ) has been checked, step S267 is executed.

【0206】ステップS265のおいて、kを1増加さ
せてステップS262に戻る。ステップS266におい
て、左オーバーレイ画像のM[n] L(i[n] L,j[n] L)、
右画像のM[n] R(i[n] L,j[n] L)(n=0,1,2,
‥‥,9)の目盛を消去する。処理を終了する。
In step S265, k is incremented by 1, and the flow returns to step S262. In step S266, M [n] L (i [n] L , j [n] L ) of the left overlay image,
M [n] R (i [n] L , j [n] L ) of the right image (n = 0, 1, 2,
(4) Delete the scale of (9). The process ends.

【0207】ステップS267において、左オーバーレ
イ画像のM[n] L(i[n] L,j[n] L)、右画像のM
[k] R(i[n] L,j[n] L)(n=0,1,2,‥‥,9)
に目盛を描画する。処理を終了する。
In step S267, M [n] L (i [n] L , j [n] L ) of the left overlay image and M [n] L of the right image
[k] R (i [n] L , j [n] L ) (n = 0,1,2, ‥‥, 9)
Draw a scale on. The process ends.

【0208】[付記]以上説明した第1、第2及び第3
の実施の形態によれば、次の付記項に示した内容が特徴
事項といえる。
[Appendix] The first, second, and third described above
According to the embodiment, the contents shown in the following additional items can be said to be the characteristic items.

【0209】(付記項1) 所定の観察対象を第1の撮
像手段で撮像して得られる第1の画像と、前記第1の撮
像手段とは異なる方向から前記所定の観察対象を第2の
撮像手段で撮像して得られた第2の画像とをそれぞれ表
示する立体視可能な計測用内視鏡装置において、前記第
1の撮像手段または前記第2の撮像手段のいずれか一方
と仮想的または実際の対象物までの距離を設定する距離
設定手段と、前記第1の撮像手段によって得られた画像
と、前記第2の撮像手段によって得られた画像におい
て、前記対象物の同一点が撮像されている対応点を求め
る対応点決定手段と、前記対象物までの前記距離に応じ
た図形を少なくとも一つの前記対応点に描画する図形描
画手段と、前記対応点の視差を導出し、視差を検査する
検査手段とを有することを特徴とする計測用内視鏡装
置。
(Additional Item 1) A first image obtained by capturing an image of a predetermined observation target by the first imaging means and a second image obtained by imaging the predetermined observation target from a direction different from that of the first imaging means are converted to a second image. In a measurement endoscope apparatus capable of displaying a second image obtained by imaging by an imaging unit and capable of displaying a stereoscopic view, a virtual image is generated by either one of the first imaging unit or the second imaging unit. Alternatively, in a distance setting means for setting a distance to an actual object, an image obtained by the first imaging means, and an image obtained by the second imaging means, the same point of the object is imaged. Corresponding point determining means for obtaining a corresponding point, graphic drawing means for drawing a graphic corresponding to the distance to the object at at least one of the corresponding points, deriving parallax of the corresponding point, Inspection means for inspection A measuring endoscope apparatus characterized by the following.

【0210】(付記項2) 前記図形描画手段は、前記
対象物までの距離に応じた目盛を描画する目盛描画機能
を有することを特徴とする付記項1に記載の計測用内視
鏡装置。
(Additional Item 2) The measurement endoscope apparatus according to Additional Item 1, wherein the graphic drawing means has a scale drawing function of drawing a scale according to a distance to the object.

【0211】これによれば、目盛と対象との比較により
対象の大きさを把握できるようになる。
According to this, the size of the object can be grasped by comparing the scale with the object.

【0212】(付記項3) 前記図形描画手段は、前記
対象物までの複数の距離に対して、前記対応点決定手段
により求められた対応点に前記図形を描画するを有する
ことを特徴とする付記項1に記載の計測用内視鏡装置。
(Additional Item 3) The graphic drawing means is characterized in that the graphic drawing means draws the graphic at corresponding points determined by the corresponding point determining means with respect to a plurality of distances to the object. 2. The measurement endoscope apparatus according to claim 1.

【0213】これによれば、対象と図形との位置関係の
把握が容易になる。
According to this, it is easy to grasp the positional relationship between the object and the figure.

【0214】(付記項4) 前記対象物までの複数の距
離に対して描画される図形が、前記対象物までの距離に
応じた目盛であることを特徴とする付記項3に記載の計
測用内視鏡装置。
(Additional Item 4) The measurement drawing according to Additional Item 3, wherein the figure drawn at a plurality of distances to the object is a scale corresponding to the distance to the object. Endoscope device.

【0215】これによれば、対象と図形との位置関係の
把握と、対象の大きさの把握が容易になる。
According to this, it is easy to grasp the positional relationship between the object and the figure and to grasp the size of the object.

【0216】(付記項5) 前記図形描画手段は、前記
対象物までの距離に応じた図形描画を停止する機能を有
することを特徴とする付記項1ないし4に記載の計測用
内視鏡装置。
(Additional Item 5) The endoscope apparatus for measurement according to additional items 1 to 4, characterized in that the graphic drawing means has a function of stopping graphic drawing according to the distance to the object. .

【0217】これによれば、対象物までの距離に応じ
て、図形の表示を停止することが可能となる。
According to this, it is possible to stop displaying the graphic according to the distance to the object.

【0218】(付記項6) 入力に応じて所定の処理を
実施する入力処理装置を持つことを特徴とする請求項1
ないし4に記載の計測用内視鏡装置。
(Additional Item 6) An input processing device for performing a predetermined process in accordance with an input.
5. The measurement endoscope device according to any one of items 4 to 4.

【0219】これによれば、立体視した状態において、
入力に応じた処理を実行できる。
According to this, in a stereoscopic state,
Processing can be executed according to the input.

【0220】(付記項7) 前記入力処理装置は、前記
図形または、画像内を指定し、指定された場所に応じて
所定の処理を実施することを特徴とする付記項6に記載
の計測用内視鏡装置。
(Additional Item 7) The measurement apparatus according to additional item 6, wherein the input processing device specifies the figure or the inside of the image and performs a predetermined process according to the specified location. Endoscope device.

【0221】これによれば、立体視した状態において、
視野内を指定することにより所定の処理を実行できる。
According to this, when stereoscopically viewed,
By designating the inside of the field of view, a predetermined process can be executed.

【0222】(付記項8) 前記入力処理装置の入力装
置がキーボードであることを特徴とする付記項6または
7に記載の計測用内視鏡装置。
(Additional Item 8) The measurement endoscope apparatus according to additional item 6 or 7, wherein the input device of the input processing device is a keyboard.

【0223】これによれば、立体視した状態において、
キーボード入力に応じた所定の処理を実行できる。
According to this, when stereoscopically viewed,
A predetermined process can be executed according to a keyboard input.

【0224】(付記項9) 前記入力処理装置の入力装
置がマウスであることを特徴とする付記項6または7に
記載の計測用内視鏡装置。
(Additional Item 9) The measurement endoscope apparatus according to additional item 6 or 7, wherein the input device of the input processing device is a mouse.

【0225】これによれば、立体視した状態において、
マウス入力に応じた所定の処理を実行できる。
According to this, in a stereoscopic state,
A predetermined process corresponding to a mouse input can be executed.

【0226】(付記項10) 前記図形描画手段は、前
記入力処理装置からの指示に基づき、前記図形に関する
パラメータを変更することを特徴とする付記項6または
7に記載の計測用内視鏡装置。
(Additional Item 10) The measurement endoscope apparatus according to additional item 6 or 7, wherein the graphic drawing means changes parameters related to the graphic based on an instruction from the input processing device. .

【0227】これによれば、立体視した状態において、
視野内に表示する図形のパラメータを変更し、パラメー
タにしたがって図形を表示することが可能となる。
According to this, when stereoscopically viewed,
It is possible to change the parameters of the graphic displayed in the field of view and display the graphic according to the parameters.

【0228】(付記項11) 前記図形描画手段は、前
記入力処理装置からの指示内容を描画することを特徴と
する付記項6または7に記載の計測用内視鏡装置。
(Additional Item 11) The measurement endoscope apparatus according to additional item 6 or 7, wherein the graphic drawing means draws an instruction content from the input processing device.

【0229】これによれば、立体視した状態において、
指示内容を確認することが可能となる。
According to this, in a stereoscopic state,
It is possible to confirm the instruction content.

【0230】(付記項12) 前記図形描画手段は、図
形に関するパラメータを描画することを特徴とする付記
項6または7に記載の計測用内視鏡装置。
(Additional Item 12) The measurement endoscope apparatus according to additional item 6 or 7, wherein the graphic drawing means draws a parameter relating to a graphic.

【0231】これによれば、立体視した状態において、
図形に関するパラメータを確認することが可能となる。
According to this, in a stereoscopic state,
It is possible to check parameters related to the figure.

【0232】(付記項13) 前記入力処理装置によ
り、画像内対象物上の点を指定し、指定した点について
計測する計測手段を有することを特徴とする付記項7に
記載の計測用内視鏡装置。
(Additional Item 13) The measurement endoscope according to additional item 7, wherein the input processing device has a measuring means for designating a point on the object in the image and measuring the designated point. Mirror device.

【0233】これによれば、立体視した状態において、
指定した点についての計測が可能となる。
According to this, in a stereoscopic state,
Measurement at the specified point becomes possible.

【0234】(付記項14) 前記計測手段は、前記入
力処理装置により指定した画像内対象物上の2点よりな
る直線と、任意の点との距離により計測を行うことを特
徴とする付記項13に記載の計測用内視鏡装置。
(Additional Item 14) The additional item is characterized in that the measuring means performs measurement by a distance between a straight line composed of two points on the object in the image designated by the input processing device and an arbitrary point. 14. The measurement endoscope apparatus according to claim 13.

【0235】これによれば、立体視した状態において、
指定した2点による直線と任意の点についての計測が可
能となる。
According to this, in a stereoscopic state,
It is possible to measure a straight line by two designated points and an arbitrary point.

【0236】(付記項15) 前記入力処理装置によ
り、画像内対象物の計測領域を指定し、指定した領域に
ついて計測を行う計測手段を有することを特徴とする付
記項7に記載の計測用内視鏡装置。
(Supplementary note 15) The measuring instrument according to Supplementary note 7, wherein the input processing device includes a measuring unit for designating a measurement area of the object in the image and measuring the designated area. Endoscope device.

【0237】これによれば、計測領域を指定することに
より、領域に対する計測が可能となる。
According to this, by specifying the measurement area, measurement for the area becomes possible.

【0238】(付記項16) 前記計測手段は、前記計
測領域内の主要な輪郭線を抽出し、輪郭線に対して計測
を行うことを特徴とする付記項15に記載の計測用内視
鏡装置。
(Additional Item 16) The measurement endoscope according to Additional Item 15, wherein the measuring means extracts a main contour in the measurement area and measures the contour. apparatus.

【0239】これによれば、立体視した状態において、
輪郭線に対する計測が可能となる。
According to this, in a stereoscopic state,
The measurement for the contour line becomes possible.

【0240】(付記項17) 前記計測手段は、前記主
要な輪郭線上の2点のエッジによりなる直線と、任意の
点との距離により計測を行うことを特徴とする付記項1
5に記載の計測用内視鏡装置。
(Additional Item 17) The additional measurement item 1 is characterized in that the measuring means performs measurement based on a distance between a straight line composed of two edges on the main contour and an arbitrary point.
6. The measurement endoscope apparatus according to 5.

【0241】これによれば、立体視した状態において、
点のエッジによる直線と任意の点についての計測が可能
となる。
According to this, in a stereoscopic state,
It is possible to measure a straight line by a point edge and an arbitrary point.

【0242】(付記項18) 前記図形描画手段は、前
記計測手段による結果を描画することを特徴とする付記
項13ないし17に記載の計測用内視鏡装置。
(Additional Item 18) The measurement endoscope apparatus according to additional items 13 to 17, wherein the graphic drawing means draws a result obtained by the measuring means.

【0243】[0243]

【発明の効果】以上説明したように本発明によれば、立
体的に見える図形を表示し、対象との距離の把握、情報
の提示を行うことができるという効果がある。
As described above, according to the present invention, there is an effect that a figure which looks three-dimensional can be displayed, the distance to the object can be grasped, and information can be presented.

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

【図1】本発明の第1の実施の形態に係る内視鏡装置の
構成を示す構成図
FIG. 1 is a configuration diagram showing a configuration of an endoscope apparatus according to a first embodiment of the present invention.

【図2】図1のホストコンピュータの構成を示すブロッ
ク図
FIG. 2 is a block diagram showing the configuration of the host computer shown in FIG. 1;

【図3】図1の内視鏡の先端部の構成を示す構成図FIG. 3 is a configuration diagram showing a configuration of a distal end portion of the endoscope in FIG. 1;

【図4】図1の内視鏡の撮像系における座標系を説明す
る図
FIG. 4 is a view for explaining a coordinate system in the imaging system of the endoscope in FIG. 1;

【図5】図1の内視鏡の歪曲収差補正を説明する第1の
FIG. 5 is a first diagram illustrating distortion correction of the endoscope in FIG. 1;

【図6】図1の内視鏡の歪曲収差補正を説明する第2の
FIG. 6 is a second diagram illustrating distortion correction of the endoscope in FIG. 1;

【図7】図2のホストコンピュータの作用を説明する第
1の図
FIG. 7 is a first diagram illustrating the operation of the host computer in FIG. 2;

【図8】図2のホストコンピュータの作用を説明する第
2の図
FIG. 8 is a second diagram illustrating the operation of the host computer in FIG. 2;

【図9】図2のホストコンピュータの作用を説明する第
3の図
FIG. 9 is a third diagram illustrating the operation of the host computer in FIG. 2;

【図10】図2のホストコンピュータの作用を説明する
第4の図
FIG. 10 is a fourth diagram illustrating the operation of the host computer in FIG. 2;

【図11】図2のホストコンピュータにより処理される
メイン処理の流れを示す第1のフローチャート
FIG. 11 is a first flowchart showing a flow of a main process performed by the host computer of FIG. 2;

【図12】図2のホストコンピュータにより処理される
メイン処理の流れを示す第2のフローチャート
FIG. 12 is a second flowchart showing the flow of a main process performed by the host computer of FIG. 2;

【図13】図11及び図12のメイン処理で使用される
アルゴリズムAの処理の流れを示すフローチャー
FIG. 13 is a flowchart showing a processing flow of an algorithm A used in the main processing of FIGS. 11 and 12;

【図14】図11及び図12のメイン処理で使用される
アルゴリズムBの処理の作用を説明する第1の図、
FIG. 14 is a first diagram illustrating an operation of processing of algorithm B used in the main processing of FIGS. 11 and 12,

【図15】図11及び図12のメイン処理で使用される
アルゴリズムBの処理の作用を説明する第2の図、
FIG. 15 is a second diagram illustrating the operation of the processing of algorithm B used in the main processing of FIGS. 11 and 12,

【図16】図11及び図12のメイン処理で使用される
アルゴリズムA’の処理の流れを示すフローチャート
FIG. 16 is a flowchart showing a processing flow of an algorithm A ′ used in the main processing of FIGS. 11 and 12;

【図17】図11及び図12のメイン処理で使用される
アルゴリズムBの処理の流れを示すフローチャート
FIG. 17 is a flowchart showing a processing flow of an algorithm B used in the main processing of FIGS. 11 and 12;

【図18】図11及び図12のメイン処理で使用される
アルゴリズムCの処理の流れを示すフローチャート
FIG. 18 is a flowchart showing the flow of processing of an algorithm C used in the main processing of FIGS. 11 and 12;

【図19】図18のアルゴリズムCの処理の作用を説明
する第1の図
FIG. 19 is a first diagram illustrating the operation of the process of algorithm C in FIG. 18;

【図20】図18のアルゴリズムCの処理の作用を説明
する第2の図
20 is a second diagram illustrating the operation of the process of algorithm C in FIG. 18;

【図21】図11及び図12のメイン処理で使用される
アルゴリズムDの処理の流れを示すフローチャート
FIG. 21 is a flowchart showing a processing flow of an algorithm D used in the main processing of FIGS. 11 and 12;

【図22】図21のアルゴリズムDの処理の作用を説明
する第1の図
FIG. 22 is a first diagram illustrating the operation of the processing of algorithm D in FIG. 21;

【図23】図21のアルゴリズムDの処理の作用を説明
する第2の図
FIG. 23 is a second diagram illustrating the operation of the process of algorithm D in FIG. 21;

【図24】図11及び図12のメイン処理で使用される
アルゴリズムEの処理の流れを示すフローチャート
FIG. 24 is a flowchart showing the flow of processing of an algorithm E used in the main processing of FIGS. 11 and 12;

【図25】図24のアルゴリズムEの処理の作用を説明
する第1の図
FIG. 25 is a first diagram illustrating the operation of the processing of algorithm E in FIG. 24;

【図26】図24のアルゴリズムEの処理の作用を説明
する第2の図
FIG. 26 is a second diagram illustrating the operation of the processing of algorithm E in FIG. 24;

【図27】図11及び図12のメイン処理で使用される
アルゴリズムFの処理の流れを示すフローチャート
FIG. 27 is a flowchart showing the flow of processing of an algorithm F used in the main processing of FIGS. 11 and 12;

【図28】図27のアルゴリズムFの処理の作用を説明
する第1の図
FIG. 28 is a first diagram illustrating the operation of the processing of algorithm F in FIG. 27;

【図29】図27のアルゴリズムFの処理の作用を説明
する第2の図
FIG. 29 is a second diagram illustrating the operation of the process of the algorithm F in FIG. 27;

【図30】図11及び図12のメイン処理で使用される
アルゴリズムGの処理の流れを示すフローチャート
FIG. 30 is a flowchart showing the flow of processing of an algorithm G used in the main processing of FIGS. 11 and 12;

【図31】図30のアルゴリズムGの処理の作用を説明
する第1の図
FIG. 31 is a first diagram illustrating the operation of the processing of algorithm G in FIG. 30;

【図32】図30のアルゴリズムGの処理の作用を説明
する第2の図
FIG. 32 is a second diagram illustrating the operation of the processing of algorithm G in FIG. 30;

【図33】図11及び図12のメイン処理で使用される
アルゴリズムHの処理の流れを示す第1のフローチャー
FIG. 33 is a first flowchart showing a processing flow of an algorithm H used in the main processing of FIGS. 11 and 12;

【図34】図11及び図12のメイン処理で使用される
アルゴリズムHの処理の流れを示す第2のフローチャー
FIG. 34 is a second flowchart showing the flow of processing of algorithm H used in the main processing of FIGS. 11 and 12;

【図35】本発明の第2の実施の形態に係るホストコン
ピュータによる処理の流れを示す第1のフローチャート
FIG. 35 is a first flowchart showing a processing flow by a host computer according to the second embodiment of the present invention;

【図36】図35の第1のフローチャートに続く第2の
フローチャート
FIG. 36 is a second flowchart following the first flowchart of FIG. 35;

【図37】図35及び図36の処理の作用を説明する第
1の図
FIG. 37 is a first diagram illustrating the operation of the processing in FIGS. 35 and 36;

【図38】図35及び図36の処理の作用を説明する第
2の図
FIG. 38 is a second diagram illustrating the operation of the processing in FIGS. 35 and 36;

【図39】図35及び図36の処理の作用を説明する第
3の図
FIG. 39 is a third diagram illustrating the operation of the processing in FIGS. 35 and 36;

【図40】図35及び図36の処理の作用を説明する第
4の図
FIG. 40 is a fourth diagram illustrating the operation of the processing in FIGS. 35 and 36;

【図41】図36の第2のフローチャートの変形例の処
理の流れを示すフローチャート
FIG. 41 is a flowchart showing the flow of processing of a modification of the second flowchart in FIG. 36;

【図42】図41のフローチャートの作用を説明する第
1の図
FIG. 42 is a first diagram illustrating the operation of the flowchart in FIG. 41;

【図43】図41のフローチャートの作用を説明する第
2の図
FIG. 43 is a second diagram illustrating the operation of the flowchart in FIG. 41;

【図44】図41のフローチャートの作用を説明する第
3の図
FIG. 44 is a third diagram illustrating the operation of the flowchart in FIG. 41;

【図45】図41のフローチャートの作用を説明する第
4の図
FIG. 45 is a fourth diagram illustrating the operation of the flowchart in FIG. 41;

【図46】図41のフローチャートの作用を説明する第
5の図
FIG. 46 is a fifth diagram for explaining the operation of the flowchart in FIG. 41;

【図47】図41のフローチャートの作用を説明する第
6の図
FIG. 47 is a sixth diagram for explaining the operation of the flowchart in FIG. 41;

【図48】図41のフローチャートの作用を説明する第
7の図
FIG. 48 is a seventh diagram illustrating the operation of the flowchart in FIG. 41;

【図49】本発明の第3の実施の形態に係るホストコン
ピュータによる処理の流れを示すフローチャート
FIG. 49 is a flowchart showing the flow of processing by the host computer according to the third embodiment of the present invention.

【図50】図49のフローチャートの作用を説明する第
1の図
FIG. 50 is a first diagram illustrating the operation of the flowchart in FIG. 49;

【図51】図49のフローチャートの作用を説明する第
2の図
FIG. 51 is a second diagram illustrating the operation of the flowchart in FIG. 49;

【図52】図49のフローチャートで使用されるアルゴ
リズムJの処理の流れを示すフローチャート
FIG. 52 is a flowchart showing the processing flow of algorithm J used in the flowchart of FIG. 49;

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

301…内視鏡(ステレオ式ビデオイメージエンドスコ
ープ) 310L,310R…ビデオプロセッサ 311…ホストコンピュータ 312L、312R …観察モニタ 313…ヘッドマウントディスプレイ 321…CPU 322…メインメモリ 323…ホストーローカルブリッジ 324L、324R…画像入出力ボード 325…外部記憶インタフェース 326、327…周辺機器インタフェース 328…ビデオボード 329…ホストバス 330…ローカルバス 331…マウス 332…キーボード 333…ディスプレイ
301 ... endoscope (stereo video image end scope) 310L, 310R ... video processor 311 ... host computer 312L, 312R ... observation monitor 313 ... head mounted display 321 ... CPU 322 ... main memory 323 ... host-local bridge 324L, 324R ... Image input / output board 325 ... External storage interface 326,327 ... Peripheral device interface 328 ... Video board 329 ... Host bus 330 ... Local bus 331 ... Mouse 332 ... Keyboard 333 ... Display

─────────────────────────────────────────────────────
────────────────────────────────────────────────── ───

【手続補正書】[Procedure amendment]

【提出日】平成13年6月8日(2001.6.8)[Submission date] June 8, 2001 (2001.6.8)

【手続補正1】[Procedure amendment 1]

【補正対象書類名】明細書[Document name to be amended] Statement

【補正対象項目名】0004[Correction target item name] 0004

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【0004】[0004]

【発明が解決しようとする課題】特開平11−6938
3号公報の問題点は、 ・左右の画像に単に機器情報を描画しているだけなの
で、実際には、融像限界を超えた視差を持ち機器情報は
立体視できないこともありうる。その場合、機器情報が
内視鏡画像の立体視の妨げになる可能性がある。また、
このとき内視鏡画像の立体視を行う場合と、機器情報の
立体視を行う場合で、ユーザが立体視用の機器を調整す
る必要が生じ、ユーザに付加的な作業を強いることにな
る。
Problems to be Solved by the Invention
The problems of the third publication are as follows: Since the device information is simply drawn on the left and right images, the device information may have a parallax exceeding the fusion limit and the device information may not be stereoscopically viewed. In that case, the device information may hinder the stereoscopic viewing of the endoscope image. Also,
At this time, when performing stereoscopic viewing of the endoscope image and when performing stereoscopic viewing of the device information, it is necessary for the user to adjust the device for stereoscopic viewing, thereby forcing the user to perform additional work.

【手続補正2】[Procedure amendment 2]

【補正対象書類名】明細書[Document name to be amended] Statement

【補正対象項目名】0053[Correction target item name] 0053

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【0053】ステップS2において、左画像水平目盛間
隔SpxL'、左画像垂直目盛間隔Spy L'を用いて、左画像
における目盛描画座標M[k] L'(k=0,1,‥‥,
)を決定する。あらかじめ与えられた左画像の目盛描
画中心座標(CxL',CyL')を用いて、式(2)で決定
される。
In step S2, the left image horizontal scale
Spax SpxL ', Left image vertical scale interval Spy L 'Using the left image
Scale drawing coordinate M at[k] L '(K = 0,1, ‥‥,
9). Scale drawing of the left image given in advance
Image center coordinates (CxL ', CyL ') And is determined by equation (2)
Is done.

【手続補正3】[Procedure amendment 3]

【補正対象書類名】明細書[Document name to be amended] Statement

【補正対象項目名】0054[Correction target item name] 0054

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【0054】[0054]

【数2】 水平目盛 M[k] L'=(CxL'+SpxL'・ (k−2),CyL')=(i[k] L' ,j[k] L') (0 ≦k≦4) 垂直目盛 M[k] L'=(CxL',CyL'+SpyL'・ (k−6))=(i[k] L' ,j[k] L') (5 ≦k≦9) (2) ステップS3において、内視鏡先端から目盛までの距離
をD is1[mm]として、後述するアルゴリズムAによ
りM[k] L'(i[k] L',j[k] L')(k=0,1,‥‥,
9)の逆補正対応画素M[k] L(i[k] L',j[k] L')(k
=0,1,‥‥,9)および、その対応点M[k] R(i
[k] L',j[k] L')(k=0,1,‥‥,)を求める。
[k] Lおよび、M[k] R(k=0,1,‥‥,9)を用い
て後述するアルゴリズムCにより図10のように左オー
バーレイ画像に立体目盛600L、右オーバーレイ画像
に600Rを描画する。
## EQU2 ## Horizontal scale M [k] L ' = (CxL ' + SpxL '. (K-2), CyL ' ) = (i [k] L ' , j [k] L' ) (0≤ k ≦ 4) Vertical scale M [k] L ′ = (CxL , CyL + SpyL · (k−6)) = (i [k] L ′ , j [k] L ′ ) (5 ≦ (2) In step S3, the distance from the endoscope tip to the scale is set to Dis1 [mm], and M [k] L ' (i [k] L' , j [k ] is determined by algorithm A described later. ] L ′ ) (k = 0, 1, ‥‥,
9) The inverse correction corresponding pixel M [k] L (i [k] L ' , j [k] L' ) (k
= 0, 1, ‥‥, 9) and the corresponding point M [k] R (i
[k] L ′ , j [k] L ′ ) (k = 0, 1, ‥‥, 9 ).
Using M [k] L and M [k] R (k = 0, 1,..., 9), the algorithm C described later uses a solid scale 600L for the left overlay image and a 600R for the right overlay image as shown in FIG. To draw.

【手続補正4】[Procedure amendment 4]

【補正対象書類名】明細書[Document name to be amended] Statement

【補正対象項目名】0131[Correction target item name]

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【0131】変更可能なパラメータとしては、目盛間隔
を例とするが、他のパラメータでも可能である。マウス
カーソル、パラメータおよびGUIは入力手段による入
力が一定時間以上ない場合は画面から消去する。入力が
再開されると自動的にパラメータおよび、GUIは再描
画される。
The parameter that can be changed is, for example, the scale interval, but other parameters are also possible. The mouse cursor, parameters, and GUI are deleted from the screen when there is no input by the input means for a predetermined time or more. When the input is restarted, the parameters and GUI are automatically redrawn.

【手続補正5】[Procedure amendment 5]

【補正対象書類名】明細書[Document name to be amended] Statement

【補正対象項目名】0173[Correction target item name] 0173

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【0173】StL'(iL'st,jL'st)を追跡開始位置
として、すべての輪郭線E[n] L'(n=0,1,2,‥
‥,NE)を輪郭線追跡する。ここで、NEは輪郭線の
個数である。追跡途中で領域外に達した場合はその時点
で、追跡を終了する。各輪郭線に含まれる画素をe
[n,m] L'(m=0,1,2,‥‥,NPn)とする。ここ
で、NPnは輪郭線E[n] L'に含まれているエッジの個数
である。図45は、E[0] L'、E[1] L'、E[2] L'が抽出
された例を示す。E[0] L'はStL'(iL'st,jL'st)を
開始点として、図45のようにE[0] L'の追跡終了点ま
でが抽出されている。E[1] L'はStL'(iL'st,jL's
t)を開始点として、図45のようにE[1] L'の追跡終了
点までが抽出されている。[2] L'も同様である。
Using St L ′ (i L ′ st, j L ′ st) as the tracking start position, all the contour lines E [n] L ′ (n = 0, 1, 2,.
{, NE) is traced. Here, NE is the number of contour lines. If it reaches outside the area during tracking, tracking ends at that point. Pixels included in each contour are denoted by e
[n, m] L ′ (m = 0, 1, 2, ‥‥, NPn). Here, NPn is the number of edges included in the contour line E [n] L ' . FIG. 45 shows an example in which E [0] L ′ , E [1] L ′ , and E [2] L ′ are extracted. E [0] L ' is extracted from the start point of St L' (i L ' st, j L' st) to the tracking end point of E [0] L ' as shown in FIG. E [1] L ' is St L' (i L ' st, j L' s
Starting from t), the tracking end point of E [1] L ' is extracted as shown in FIG. The same applies to E [2] L ' .

【手続補正6】[Procedure amendment 6]

【補正対象書類名】明細書[Document name to be amended] Statement

【補正対象項目名】0198[Correction target item name]

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【0198】[0198]

【数28】 水平目盛 M[n] L'=(CxL'+SpxL'・(n−2),CyL') 垂直目盛 M[n] L'=(CxL' ,CyL'+ SpyL'・(n−6)) ( 28) ステップS254において、内視鏡先端から目盛までの
距離をzL W[mm]として、アルゴリズムAによりM
[n] L'(n=0,1,‥‥,9)の逆補正対応画素M[n]
L(n=0,1,‥‥,9)および、その対応点M[n] R
(n=0,1,‥‥,9)を求める。M[n] Lおよび、M
[n] R(n=0,1,‥‥,)を用いてアルゴリズムC
により図10のように左オーバーレイ画像に立体目盛6
00L、右オーバーレイ画像に600Rを描画する。
Equation 28] horizontal scale M [n] L '= ( Cx L' + Spx L '· (n-2), Cy L') vertical scale M [n] L '= ( Cx L', Cy L '+ Spy in L '· (n-6) ) (28) step S254, the distance from the endoscope tip to the scale as z L W [mm], M by algorithm a
[n] L ′ (n = 0, 1, ‥‥, 9) inverse correction corresponding pixel M [n]
L (n = 0, 1, ‥‥, 9) and its corresponding point M [n] R
(N = 0, 1,..., 9) is obtained. M [n] L and M
[n] R (n = 0,1, ‥‥, 9 )
As shown in FIG. 10, the solid scale 6 is displayed on the left overlay image.
00L and 600R are drawn on the right overlay image.

【手続補正7】[Procedure amendment 7]

【補正対象書類名】図面[Document name to be amended] Drawing

【補正対象項目名】図51[Correction target item name] FIG.

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【図51】 FIG. 51

───────────────────────────────────────────────────── フロントページの続き (51)Int.Cl.7 識別記号 FI テーマコート゛(参考) G06T 1/00 315 G06T 1/00 315 5C061 17/40 17/40 F H04N 7/18 H04N 7/18 M 13/00 13/00 Fターム(参考) 2H040 BA15 BA22 GA02 GA11 4C061 CC06 HH51 JJ17 LL08 NN05 WW12 5B050 AA02 BA09 EA19 EA28 FA02 FA06 FA14 5B057 AA07 CA12 CB13 CC01 CD14 DA07 DA16 DB03 DC03 5C054 CA04 CC03 FA02 FC15 FD02 FE13 HA05 5C061 AA01 AA21 AB04 AB18 AB20──────────────────────────────────────────────────続 き Continued on the front page (51) Int.Cl. 7 Identification symbol FI Theme coat ゛ (Reference) G06T 1/00 315 G06T 1/00 315 5C061 17/40 17/40 F H04N 7/18 H04N 7/18 M 13/00 13/00 F-term (reference) 2H040 BA15 BA22 GA02 GA11 4C061 CC06 HH51 JJ17 LL08 NN05 WW12 5B050 AA02 BA09 EA19 EA28 FA02 FA06 FA14 5B057 AA07 CA12 CB13 CC01 CD14 DA07 DA16 DB03 DC03 5C051 CA04 CC03 FA02 AA01 AA21 AB04 AB18 AB20

Claims (9)

【特許請求の範囲】[Claims] 【請求項1】 所定の観察対象を第1の撮像手段で撮像
して得られる第1の画像と、前記第1の撮像手段とは異
なる方向から前記所定の観察対象を第2の撮像手段で撮
像して得られた第2の画像とをそれぞれ表示する立体視
可能な計測用内視鏡装置において、 前記第1の撮像手段または前記第2の撮像手段のいずれ
か一方と仮想的または実際の対象物までの距離を設定す
る距離設定手段と、 前記第1の撮像手段によって得られた画像と、前記第2
の撮像手段によって得られた画像において、前記対象物
の同一点が撮像されている対応点を求める対応点決定手
段と、 前記対象物までの前記距離に応じた図形を少なくとも一
つの前記対応点に描画する図形描画手段と、 前記対応点の視差を導出し、視差を検査する検査手段と
を有することを特徴とする計測用内視鏡装置。
1. A first image obtained by capturing an image of a predetermined observation target by a first imaging unit, and the predetermined observation target by a second imaging unit from a direction different from the first imaging unit. In a measurement endoscope apparatus capable of displaying a second image obtained by imaging in a stereoscopic view, either one of the first imaging means or the second imaging means and a virtual or actual A distance setting unit for setting a distance to an object; an image obtained by the first imaging unit;
In an image obtained by the imaging means, a corresponding point determining means for finding a corresponding point at which the same point of the object is imaged, and a figure corresponding to the distance to the object is converted into at least one corresponding point. An endoscope apparatus for measurement, comprising: a figure drawing means for drawing; and an inspection means for deriving a parallax of the corresponding point and inspecting the parallax.
【請求項2】 前記図形描画手段は、前記対象物までの
距離に応じた目盛を描画する目盛描画機能を有すること
を特徴とする請求項1に記載の計測用内視鏡装置。
2. The measurement endoscope apparatus according to claim 1, wherein the graphic drawing means has a scale drawing function for drawing a scale according to a distance to the object.
【請求項3】 前記図形描画手段は、前記対象物までの
複数の距離に対して、前記対応点決定手段により求めら
れた対応点に前記図形を描画するを有することを特徴と
する請求項1に記載の計測用内視鏡装置。
3. The apparatus according to claim 1, wherein said figure drawing means draws said figure at a corresponding point determined by said corresponding point determining means for a plurality of distances to said object. The endoscope device for measurement according to 1.
【請求項4】 前記図形描画手段は、前記対象物までの
距離に応じた図形描画を停止する機能を有することを特
徴とする請求項1ないし3に記載の計測用内視鏡装置。
4. The measurement endoscope apparatus according to claim 1, wherein the graphic drawing means has a function of stopping graphic drawing according to a distance to the object.
【請求項5】 入力に応じて所定の処理を実施する入力
処理装置を持つことを特徴とする請求項1ないし3に記
載の計測用内視鏡装置。
5. The measurement endoscope apparatus according to claim 1, further comprising an input processing device for performing a predetermined process according to an input.
【請求項6】 前記入力処理装置は、前記図形または、
画像内を指定し、指定された場所に応じて所定の処理を
実施することを特徴とする請求項5に記載の計測用内視
鏡装置。
6. The input processing device according to claim 1, wherein
The measurement endoscope apparatus according to claim 5, wherein an inside of the image is designated, and a predetermined process is performed according to the designated place.
【請求項7】 前記図形描画手段は、前記入力処理装置
からの指示に基づき、前記図形に関するパラメータを変
更することを特徴とする請求項5または6に記載の計測
用内視鏡装置。
7. The measurement endoscope apparatus according to claim 5, wherein the graphic drawing unit changes parameters related to the graphic based on an instruction from the input processing device.
【請求項8】 前記図形描画手段は、前記入力処理装置
からの指示内容を描画することを特徴とする請求項5ま
たは6に記載の計測用内視鏡装置。
8. The measurement endoscope apparatus according to claim 5, wherein the graphic drawing means draws an instruction content from the input processing device.
【請求項9】 前記入力処理装置により、画像内対象物
上の点を指定し、指定した点について計測する計測手段
を有することを特徴とする請求項6に記載の計測用内視
鏡装置。
9. The measurement endoscope apparatus according to claim 6, further comprising a measurement unit that specifies a point on the object in the image by the input processing device and measures the specified point.
JP2001151092A 2001-05-21 2001-05-21 Endoscope system for measurement Withdrawn JP2002336188A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2001151092A JP2002336188A (en) 2001-05-21 2001-05-21 Endoscope system for measurement

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2001151092A JP2002336188A (en) 2001-05-21 2001-05-21 Endoscope system for measurement

Publications (1)

Publication Number Publication Date
JP2002336188A true JP2002336188A (en) 2002-11-26

Family

ID=18996002

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2001151092A Withdrawn JP2002336188A (en) 2001-05-21 2001-05-21 Endoscope system for measurement

Country Status (1)

Country Link
JP (1) JP2002336188A (en)

Cited By (20)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002345735A (en) * 2001-05-30 2002-12-03 Olympus Optical Co Ltd Image processing measurement device and measurement endoscope
JP2004187711A (en) * 2002-12-06 2004-07-08 Olympus Corp Endoscopic equipment
JP2005204724A (en) * 2004-01-20 2005-08-04 Olympus Corp Endoscope apparatus for measurement
WO2007063980A1 (en) * 2005-12-03 2007-06-07 Atsushi Takahashi Intraoral panoramic image pickup device and intraoral panoramic image pickup system
WO2007077895A1 (en) * 2005-12-28 2007-07-12 Olympus Medical Systems Corp. Subject insertion system and method for guiding subject insertion device
JP2007181670A (en) * 2005-12-30 2007-07-19 Intuitive Surgical Inc Medical robotic system providing three-dimensional telestration
JP2008206956A (en) * 2007-01-31 2008-09-11 Olympus Corp Endoscope device for measurement
JP2008295512A (en) * 2007-05-29 2008-12-11 Olympus Corp Endoscope apparatus for measurement, and program
US7518632B2 (en) 2005-12-13 2009-04-14 Olympus Corporation Endoscope device
JP2011015721A (en) * 2009-07-07 2011-01-27 Fa System Engineering Kk Stereoscopic scale image forming device of stereoscopic video display device
JP2011153995A (en) * 2010-01-28 2011-08-11 Fa System Engineering Kk Stereoscopic caliper image forming apparatus and program of stereoscopic video display
US8201097B2 (en) 2007-01-05 2012-06-12 Sony Corporation Information processing apparatus, display control method, and program
JP2012147857A (en) * 2011-01-17 2012-08-09 Olympus Medical Systems Corp Image processing apparatus
JP2015531271A (en) * 2012-09-14 2015-11-02 ソニー株式会社 Surgical image processing system, surgical image processing method, program, computer-readable recording medium, medical image processing apparatus, and image processing inspection apparatus
JP2017086803A (en) * 2015-11-17 2017-05-25 富士フイルム株式会社 Measurement device, endoscope system, and measurement method
JPWO2018051679A1 (en) * 2016-09-15 2019-06-24 富士フイルム株式会社 Measurement support apparatus, endoscope system, processor of endoscope system, and measurement support method
JPWO2018159292A1 (en) * 2017-03-03 2019-11-07 富士フイルム株式会社 Measurement support apparatus, endoscope system, and processor of endoscope system
WO2020148084A1 (en) * 2019-01-14 2020-07-23 Lufthansa Technik Ag Borescope for optically inspecting gas turbines
US11419694B2 (en) 2017-03-28 2022-08-23 Fujifilm Corporation Endoscope system measuring size of subject using measurement auxiliary light
US11490785B2 (en) 2017-03-28 2022-11-08 Fujifilm Corporation Measurement support device, endoscope system, and processor measuring size of subject using measurement auxiliary light

Cited By (28)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002345735A (en) * 2001-05-30 2002-12-03 Olympus Optical Co Ltd Image processing measurement device and measurement endoscope
JP2004187711A (en) * 2002-12-06 2004-07-08 Olympus Corp Endoscopic equipment
JP2005204724A (en) * 2004-01-20 2005-08-04 Olympus Corp Endoscope apparatus for measurement
WO2007063980A1 (en) * 2005-12-03 2007-06-07 Atsushi Takahashi Intraoral panoramic image pickup device and intraoral panoramic image pickup system
JP5016311B2 (en) * 2005-12-03 2012-09-05 淳 高橋 Intraoral panoramic image capturing apparatus, intraoral panoramic image capturing system
JPWO2007063980A1 (en) * 2005-12-03 2009-05-07 高橋 淳 Intraoral panoramic image capturing apparatus, intraoral panoramic image capturing system
US7518632B2 (en) 2005-12-13 2009-04-14 Olympus Corporation Endoscope device
US8314834B2 (en) 2005-12-13 2012-11-20 Olympus Corporation Endoscope device
WO2007077895A1 (en) * 2005-12-28 2007-07-12 Olympus Medical Systems Corp. Subject insertion system and method for guiding subject insertion device
US7841981B2 (en) 2005-12-28 2010-11-30 Olympus Medical Systems Corp. Body-insertable device system and body-insertable device guiding method
JP2007181670A (en) * 2005-12-30 2007-07-19 Intuitive Surgical Inc Medical robotic system providing three-dimensional telestration
US8201097B2 (en) 2007-01-05 2012-06-12 Sony Corporation Information processing apparatus, display control method, and program
JP2008206956A (en) * 2007-01-31 2008-09-11 Olympus Corp Endoscope device for measurement
JP2013238860A (en) * 2007-01-31 2013-11-28 Olympus Corp Endoscope apparatus
JP2008295512A (en) * 2007-05-29 2008-12-11 Olympus Corp Endoscope apparatus for measurement, and program
JP2011015721A (en) * 2009-07-07 2011-01-27 Fa System Engineering Kk Stereoscopic scale image forming device of stereoscopic video display device
JP2011153995A (en) * 2010-01-28 2011-08-11 Fa System Engineering Kk Stereoscopic caliper image forming apparatus and program of stereoscopic video display
JP2012147857A (en) * 2011-01-17 2012-08-09 Olympus Medical Systems Corp Image processing apparatus
JP2015531271A (en) * 2012-09-14 2015-11-02 ソニー株式会社 Surgical image processing system, surgical image processing method, program, computer-readable recording medium, medical image processing apparatus, and image processing inspection apparatus
JP2017086803A (en) * 2015-11-17 2017-05-25 富士フイルム株式会社 Measurement device, endoscope system, and measurement method
JPWO2018051679A1 (en) * 2016-09-15 2019-06-24 富士フイルム株式会社 Measurement support apparatus, endoscope system, processor of endoscope system, and measurement support method
US11536556B2 (en) 2016-09-15 2022-12-27 Fujifilm Corporation Measurement support device, endoscope system, processor for endoscope system, and measurement support method for measuring object size
JPWO2018159292A1 (en) * 2017-03-03 2019-11-07 富士フイルム株式会社 Measurement support apparatus, endoscope system, and processor of endoscope system
US10708553B2 (en) 2017-03-03 2020-07-07 Fujifilm Corporation Measurement support device, endoscope system, processor for endoscope system
US11419694B2 (en) 2017-03-28 2022-08-23 Fujifilm Corporation Endoscope system measuring size of subject using measurement auxiliary light
US11490785B2 (en) 2017-03-28 2022-11-08 Fujifilm Corporation Measurement support device, endoscope system, and processor measuring size of subject using measurement auxiliary light
WO2020148084A1 (en) * 2019-01-14 2020-07-23 Lufthansa Technik Ag Borescope for optically inspecting gas turbines
US11940351B2 (en) 2019-01-14 2024-03-26 Lufthansa Technik Ag Borescope that processes image data into 3-d data for optically inspecting gas turbines

Similar Documents

Publication Publication Date Title
JP2002336188A (en) Endoscope system for measurement
CN111783820B (en) Image labeling method and device
CN107223269B (en) Three-dimensional scene positioning method and device
JP6011102B2 (en) Object posture estimation method
US10930008B2 (en) Information processing apparatus, information processing method, and program for deriving a position orientation of an image pickup apparatus using features detected from an image
EP1536378B1 (en) Three-dimensional image display apparatus and method for models generated from stereo images
US9317924B2 (en) Information processing apparatus, three-dimensional position calculation method, and program
JP6946087B2 (en) Information processing device, its control method, and program
JP2012247364A (en) Stereo camera apparatus, stereo camera system and program
JPH0935061A (en) Image processing method
JPWO2017002209A1 (en) Display control apparatus, display control method, and display control program
JP2001067463A (en) Device and method for generating facial picture from new viewpoint based on plural facial pictures different in viewpoint, its application device and recording medium
JP2018112790A (en) Information processing apparatus and method for controlling the same, and program
JP2018031753A (en) Object detection method and apparatus for the same
US11055865B2 (en) Image acquisition device and method of operating image acquisition device
JP7061092B2 (en) Image processing equipment and programs
JP2021009557A (en) Information processing device, information processing method, and program
JPH11248431A (en) Three-dimensional model forming apparatus and computer readable medium recorded with three-dimensional model generating program
JP2005174151A (en) Three-dimensional image display device and method
JP2001005978A (en) Device and method for extracting object, and program providing medium
JP2018032144A (en) Image processor, image processing method and program
JP4409924B2 (en) Three-dimensional image display apparatus and method
JP4351090B2 (en) Image processing apparatus and image processing method
JP6704712B2 (en) Information processing apparatus, control method of information processing apparatus, and program
JP4427305B2 (en) Three-dimensional image display apparatus and method

Legal Events

Date Code Title Description
A300 Application deemed to be withdrawn because no request for examination was validly filed

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20080805