JP2004117235A - 3-dimensional form measuring method and 3-dimensional form measuring apparatus - Google Patents

3-dimensional form measuring method and 3-dimensional form measuring apparatus Download PDF

Info

Publication number
JP2004117235A
JP2004117235A JP2002282512A JP2002282512A JP2004117235A JP 2004117235 A JP2004117235 A JP 2004117235A JP 2002282512 A JP2002282512 A JP 2002282512A JP 2002282512 A JP2002282512 A JP 2002282512A JP 2004117235 A JP2004117235 A JP 2004117235A
Authority
JP
Japan
Prior art keywords
image
measured
distance
light
diffused light
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.)
Granted
Application number
JP2002282512A
Other languages
Japanese (ja)
Other versions
JP3825383B2 (en
Inventor
Akihiko Hashimoto
橋本 秋彦
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.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone Corp
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 Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2002282512A priority Critical patent/JP3825383B2/en
Publication of JP2004117235A publication Critical patent/JP2004117235A/en
Application granted granted Critical
Publication of JP3825383B2 publication Critical patent/JP3825383B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide a measuring method and apparatus which can measure a correct distance when an outdoor day light exists, and can measure the whole part independently of monochrome contrast of an object to be measures and distance from illumination, and improves instrumentation resolution. <P>SOLUTION: An object to be measured is irradiated with an airlight from a certain distance and photographed, thereby obtaining an image 1. The object is irradiated with an airlight from a different distance, thereby obtaining an image 2. Illumination is not used or light intensity is changed, thereby obtaining an image 3. Intensity values recorded on pixels of same position of the image 1, image 2 and image 3 are calculated. This process is applied to all pixels, and a 3-dimensional form of the object is obtained. About regions where the intensity value is larger or smaller than a prescribed value, measurement is again performed by changing the amount of airlight. Three or more portions of the object are irradiated with mutually changed airlight. An image is photographed for every irradiation, and photographing is performed from image 1 to image N. An image N+1 is obtained without illumination. Intensity values recorded on pixels of same coordinate value of the image 1 to the image N+1 are calculated. <P>COPYRIGHT: (C)2004,JPO

Description

【0001】
【発明の属する技術分野】
本発明は被計測物体の3次元形状または3次元形状と色を計測する方法および装置であり、主に計測産業、通信産業、映像産業の分野において用いられる。
【0002】
【従来の技術】
カメラを用いて被計測物体の3次元形状を取得する様々な計測方法が提案されている。これらの方法はステレオ法に代表される被計測物体に特別な照明を照射しないパッシブ型計測法と、被計測物体に特別な照明を照射するアクティブ型計測法に分類できる。
【0003】
パッシブ型計測法はカメラ2台でできるため非常に低コストで汎用性もあり、昔から精力的に研究されてきたが、未だに計測の信頼性が低く汎用的に使える方法としては実用段階に至っていない。
【0004】
一方、アクティブ型計測法は計測精度、分解能、計測信頼性も実用水準に到達しており、近年では動画像計測も可能となった。しかしながら、一般に装置が大型かつ高価であり携帯化できるサイズヘの小型化が困難である問題があった。
【0005】
また、アプリケーションによっては計測精度や分解能が低くて構わない場合も多いが、従来のアクティブ型計測法ではこれらのスペックを下げても装置の低価格化や小型化を効率よくはかることができない。
【0006】
これに対し、異なる距離から拡散光を被計測物体に照射して撮影し、各々の画像の輝度値の比を取ることによって距離を求める装置がある(特許文献1)。
この装置の構成を図1に示す。11は遠方の光源、12は近方の光源、13は被計測物体、14はカメラである。この装置は計測精度、分解能はあまり高くないものの、基本的には2つの光源とカメラを用意するだけで装置を構成することができるので、極めて低価格に作ることが可能であり、比較的小型の装置にすることも可能である。
【0007】
この装置の動作原理を数式で説明する。
遠方の光源11と被計測物体13間の距離をx、遠方の光源11および近方の光源12の光量をLとする(簡潔な式で説明するため光量を同じLとしたが本計測法は11と12の相対的な強度比が既知であれば異なる光量であっても構わない)と、遠方の光源11で照明された被計測物体13上のある地点の輝度V1は、遠方の光源11と近方の光源12からの照射光をカメラ方向へ反射する反射率をkとすると、
(式1)V1=kL/4πx
の輝度で撮影される。近方の光源12が遠方の光源11より距離x0だけ被計測物体13に近いとすると、近方の光源12で照明された該地点の輝度V2は、
(式2)V2=kL/4π(x−x0)
の輝度で撮影される。式1と式2の比をとることによって、距離xが、
(式3)x=x0/{1−√(V1/V2)}
として求まる。
【0008】
前記特許文献1では1点の距離計測なのか3次元形状全体の計測なのか明示されていないが、計測原理は同じで3次元形状計測を明示的に示した発明が特許文献2の請求項に記載されている。また、特許文献2と同様な発明が数式の表現を変えて、特許文献3の請求項1、2、特許文献4の請求項1、特許文献5の請求項1、特許文献6の請求項1に記載されている。
【0009】
【特許文献1】
特開昭61−155909号公報
【特許文献2】
特公平6−076888号公報
【特許文献3】
特開2002−077944号公報
【特許文献4】
特開2002−065581号公報
【特許文献5】
特開2002−095625号公報
【特許文献6】
特開2002−065585号公報
【0010】
【発明が解決しようとする課題】
しかし、この従来の計測方法には以下に掲げる問題点がある。
1.外光が存在すると正しい距離を求められない。
外光が存在する場合、外光量をLa、外光を撮影カメラの向きに反射する反射率をk’とすると、式1、式2は以下の式4、式5に置き換わる。
(式4)V1=k’La+kL/4πx
(式5)V2=k’La+kL/4π(x−x0)
これらの式の比をとっても、未知の量であるk’、Laが残るため距離xを求めることが出来ない。従って、従来の計測方法では暗室や内視鏡のように外光がない環境下でしか動作できない。外光が存在する場合にも正しい距離を計測できる計測方法および装置を提供することが本発明の課題1である。
【0011】
2.被計測物体の黒い領域や照明から遠い領域と白い領域や照明に近い領域を同時に計測することが困難である。
被計測物体の黒い(低反射率)領域や照明から遠い領域が計測できるように光量を上げると、被計測物体の白い(高反射率)領域や照明に近い領域の輝度がオーバーフローを起こして撮影できなくなる。一方で、オーバーフローを避けるため光量を下げると、被計測物体の黒い領域や照明から遠い領域の輝度が非常に小さくなってしまう。本計測法では輝度値V1とV2のわずかな差を利用して距離を算出するので、V1やV2の値そのものが小さいと、その差はTVカメラの撮影できる輝度階調未満となり計測不能となってしまう問題が起こる。この計測不能な状態をここではアンダーフローと呼ぶことにする。被計測物体の白黒の濃淡や照明からの遠近に関わらず全体を計測できる計測方法および装置を提供することが本発明の課題2である。
【0012】
3.計測分解能が悪い。
被計測物体上の反射率の違いや照明からの遠近によって、撮影された画像は広範囲な輝度分布を有する。それと比較してV1とV2の差はわずかな値でしかない。例えば、V1とV2の差が数階調しかないとするなら、計測分解能もわずか数階調に過ぎない。これでは物体の存在位置がわかる程度の大まかな距離情報しか取得できない。計測分解能を向上した計測方法および装置を提供することが本発明の課題3である。
【0013】
【課題を解決するための手段】
課題1を解決するため、本発明請求項1の方法は図2に示すステップで処理を行う。第1のステップ21において拡散光をある距離から被計測物体に照射し、被計測物体を撮影、記録することによって画像1を取得し、第2のステップ22において第1のステップよりx0だけ近い距離から拡散光を被計測物体に照射し、被計測物体を撮影、記録することによって画像2を取得し、第3のステップ23において、無照明、または、第1のステップ21または第2のステップ22の距離から拡散光の光量を変えて被計測物体に照射し、被計測物体を撮影、記録することによって画像3を取得し、第4のステップ24において画像1と画像2と画像3の同位置の画素に記録された輝度値を演算することによって該画素に写っている被計測物体までの距離を算出し、第5のステップ25において第4のステップ24の処理を全画素に行うことによって被計測物体の3次元形状を求める。
【0014】
各ステップ毎に行われる作用について説明する。第1のステップ21において、ある距離から拡散光を被計測物体に照射し、被計測物体を撮影、記録することによって画像1を取得する。この時、被計測物体上のある地点の輝度V1は、拡散光の強度をL、該地点と照明手段までの距離をx、照明光を撮影手段方向に反射する反射率をk、外光の光量をLa、外光を撮影手段方向に反射する反射率をk’とすると、
(式4)V1=k’La+kL/4πx
なる輝度値で撮影される。
【0015】
次に第2のステップ22において、第1のステップ21より距離x0だけ近い距離から拡散光を被計測物体に照射し、被計測物体を撮影、記録することによって画像2を取得する。この時、被計測物体上の該地点の輝度V2は、
(式5)V2=k’La+kL/4π(x−x0)
なる輝度値で撮影される。
【0016】
次に第3のステップ23において、無照明、または、第1のステップ21または第2のステップ22の距離から拡散光の光量を変えて被計測物体に照射し、被計測物体を撮影、記録することによって画像3を取得する。ここで無照明であるならば、光源で照明された被計測物体中の同位置の輝度V3は、
(式6)V3=k’La
となり、第1のステップ21の位置から拡散光の光量を1/n倍で照射するなら、
(式61)V3=k’La+kL/4nπx
となり、第2のステップ22の位置から拡散光の光量を1/n倍で照射するなら、
(式62)V3=k’La+kL/4nπ(x−x0)
となる。
【0017】
次に第4のステップ24において、画像1と画像2と画像3の同位置の画素に記録された輝度値を演算することによって該画素に写っている被計測物体の距離を算出する。例えば画像3が無照明で撮影された画像の場合、式4、式5、式6を連立させることによって、
(式7)x=x0/〔1−√{(V1−V3)/(V2−V3)}〕
にて距離xが算出される。
【0018】
なお、式61や式62を式6の代わりに用いてもnが既知であればxは算出できる。外光はあるが照明光に比べて光量が小さい場合、補助的に照明する式61や式62の方法は計測精度を高める上で有利である。
【0019】
最後に第5のステップ25において、第4のステップ24の画素の演算処理を画像全体に適用することによって画像に写った被計測物体の3次元形状を算出する。
【0020】
本発明請求項2の装置は、異なる距離から拡散光を照射する照明手段と、被計測物体を撮影する手段と、画像データの記録手段と、画像データの演算手段を有し、請求項1の方法に従って動作する。
【0021】
まず、異なる距離から拡散光を照射する照明手段と、被計測物体を撮影する手段とを用いて第1のステップ21と第2のステップ22と第3のステップ23を実行し、撮影した画像データを記録手段を用いて記録する。次に画像データの演算手段を用いて第4のステップ24と第5のステップ25を実行する。
【0022】
請求項1の方法および請求項2の装置を用いることによって、外光の存在する条件下でも形状計測が可能となり課題1を解決することができる。
【0023】
課題2を解決するため、本発明請求項3の方法は以下に示すステップの処理を行う。第6のステップにおいて、十分に強い(弱い)光量の拡散光を照射して、請求項1の方法で被計測物体の3次元形状を計測する。第7のステップにおいて、第6のステップで取得した画像内で輝度値がオーバーフロー(アンダーフロー)して計測できなかった領域について、光量を弱く(強く)して、再度第6のステップを実行して計測できなかった領域を再計測する。第8のステップにおいて、計測できない領域がなくなるか、または、所定の反復回数に達するまで第7のステップを繰り返す。
【0024】
十分に強い光量から計測を開始し徐々に光量を落とす場合を例にとって各ステップで行われる作用の説明を行う。まず、第6のステップにおいて、十分に強い光量の拡散光を照射して、請求項1の方法で被計測物体の3次元形状を計測する。すると、図3(A)に示すような被計測物体の白い領域や照明に近い領域の輝度が撮影においてオーバーフローを起こしてしまい計測できなかった領域35が発生している。
【0025】
次に第7のステップにおいて光量を弱くして第6のステップを繰り返す。すると、図3(B)に示すように前回オーバーフローを起こして計測できなかった領域の一部が再計測可能となる。一方、被計測物体の黒い領域や照明から遠い領域の中からアンダーフローで計測できなかった領域36が発生するが、該領域は前回の計測にて既に計測済みである。第8のステップにおいて、計測できない領域がなくなるか、または、所定の反復回数に達するまで第7のステップを繰り返す。すると、図3(C)に示すようにオーバーフローを起こしていた領域が全て再計測でき、図3(A)から(C)までの計測できた領域を全てあわせると全領域が計測できていることになる。
十分弱い光量から始める場合は、図3(C)から始まり、図3(A)にて計測が終了することとなる。
【0026】
本発明請求項4の装置は、光量を変えられ異なる距離から拡散光を照射する照明手段と、被計測物体を撮影する手段と、画像データの記録手段と、画像データの演算手段を有し、請求項3の方法に従って動作する。
【0027】
まず、光量を変えられ異なる距離から拡散光を照射する照明手段と、被計測物体を撮影する手段とを用いて第6のステップを実行し、計測可能だった領域のみ計測結果を記録する。次に第7のステップを実行して新たに計測可能となった領域について計測結果を追加記録する。そして、計測できない領域がなくなるか、または、所定の反復回数に達するまで第7のステップを繰り返すことによって被計測物体の3次元形状を求める。
【0028】
請求項3の方法または請求項4の装置を用いることによって、被計測物体の白黒の濃淡や照明からの遠近に関わらず全体の3次元形状が計測可能となり課題2を解決することができる。
【0029】
課題3を解決するため、本発明請求項5の方法は以下に示すステップの処理を行う。第1のステップにて被計測物体までの距離を徐々にN回変えた距離から拡散光を被計測物体を照射し、各照射毎に被計測物体の画像を撮影、記録することによってN枚の画像1から画像Nまでを取得する。第2のステップにて、無照明で被計測物体を撮影、記録することによって画像N+1を取得する。第3のステップにて画像1から画像N+1の同位置の画素に記録された輝度値を演算することによって該画素に写っている被計測物体の距離を算出する。
【0030】
その一例として、請求項1の方法を組み合わせて距離を算出する方法を示す。請求項1の方法を用いて距離を算出するためには距離の異なる拡散光で撮影された2枚の画像と画像N+1が必要なので、例えば、N=4(画像1から画像4)の撮影を行った場合には、画像1と画像2、画像2と画像3、画像3と画像4、画像1と画像3、画像2と画像4、画像1と画像4の組と、画像5(N+1)で演算することによって6つの距離が算出できる。これらの平均値を最終的な距離とする。第4のステップにて第3のステップを全画素に行うことによって被計測物体の3次元形状を算出する。
【0031】
請求項5の作用について説明する。図4は実際の距離と計測の結果得られる距離との関係を表したグラフを画像の組み合わせ毎に示した図である。4つの距離x1、x2、x3、x4(ただしx1>x2>x3>x4)から拡散光を照射して4枚の画像1から画像4を取得した場合、これらの画像の組み合わせによって得られるグラフを45から410に示す。本来、理想的にはグラフは斜線でなければならないが、いずれのグラフも分解能が悪いため階段状の折れ線となる。しかし、これらのグラフの平均値を算出すると411が得られ、階段が細かくなる、つまり、計測分解能が向上して斜線に近づくのがわかる。
【0032】
本発明請求項6の装置は、少なくとも3ヶ所以上の異なる距離から拡散光を照射する照明手段と、被計測物体を撮影する手段と、画像データの記録手段と、画像データの演算手段を有し、請求項5の方法に従って動作する。
【0033】
請求項6の装置の動作について説明する。少なくとも3ヶ所以上の異なる距離から拡散光を照射する照明手段と、被計測物体を撮影する手段と、画像データの記録手段を用いて第1のステップと第2のステップを実行する。次に、画像データの演算手段を用いて第3のステップと第4のステップを実行する。
【0034】
請求項5の方法または請求項6の装置を用いることによって、計測分解能を向上した計測方法および装置を実現することができ課題3を解決できる。
【0035】
【発明の実施の形態】
本発明請求項1の方法および請求項2の装置の一実施形態を図5および図6を用いて説明する。図5は請求項2の装置の構成図、図6は図5の装置を用いて行う請求項1の方法のフローチャートである。図5において、51は遠方から拡散光を照射するライト、52は手前から拡散光を照射するライト、53は被計測物体、54は撮影カメラであり、本実施例では画像データをデジタルデータとして出力するカメラを使用する。55は画像データの格納メモリ、56は画像の演算器、57は形状データの格納メモリ、58は全体の制御装置である。なお、55から58はパソコンやワークステーションで構成し、56と58にはCPUを使用し、55と57はメモリまたは磁気記録媒体等の記憶領域を区分して使用しても良い。
【0036】
請求項2の装置を用いて請求項1の方法を実行する動作を図6のフローチャートに従って説明する。ステップ61において、制御装置58は遠方のライト51を点灯させ、撮影カメラ54に被計測物体53を撮影させて得られた画像データ1を画像メモリ55に格納後、遠方のライト51を消灯する。ステップ62において、制御装置58は手前のライト52を点灯させ、撮影カメラ54に被計測物体53を撮影させて得られた画像データ2を画像メモリ55に格納後、手前のライト52を消灯する。ステップ63において、撮影カメラ54に被計測物体53を撮影させて得られた画像データ3を画像メモリ55に格納する。ステップ64において、制御装置58は画像演算器56に座標値(i,j)を与えて、該座標値の画素の輝度値から距離データの算出を命令する。ステップ65において、画像演算器56は座標値(i,j)の画素の輝度値を画像1、画像2、画像3から取り出す。この輝度値をそれぞれV1、V2、V3とする。ステップ66において、画像演算器56は以下の式で示される演算を行って座標値(i,j)における距離データx(i,j)を算出し形状データメモリ57に格納する。
(式8)x(i,j)=x0/〔1−√{(V1−V3)/(V2−V3)}〕
【0037】
なお、遠方のライト51と手前のライト52間の距離x0は既知であり画像演算器56に予め与えられているものとする。ステップ67において、制御装置58は画像の全座標において算出処理が終了したか判定し、算出処理されていれば終了する。そうでなければ、ステップ68にて未算出の座標値(i,j)を決定してステップ64に戻る。なお、画像を左上から順次走査して座標値(i,j)を決定し、右下の座標値に到達したことを終了の判定条件とすれば容易に座標値(i,j)決定や終了判定が実現できることは言うまでもない。
【0038】
本発明請求項3の方法および請求項4の装置の一実施形態を図7および図8を用いて説明する。図7は請求項4の装置の構成図、図8は図7の装置を用いて行う請求項3の方法のフローチャートである。図7において、71は指定された光量の拡散光を照射する遠方のライト、72は指定された光量の拡散光を照射する手前のライト、73は被計測物体、74は撮影カメラであり、本実施例では画像データをデジタルデータとして出力するカメラを使用する。75は画像データの格納メモリ、76は画像の演算器、77は形状データの格納メモリ、78は全体の制御装置、79は計測済みフラグデータの格納メモリである。なお、75から79はパソコンやワークステーションで構成し、76と78にはCPUを使用し、75と77と79はメモリまたは磁気記録媒体等の記憶領域を区分して使用しても良い。
【0039】
また、遠方のライト71や手前のライト72の光量を制御する代わりに、撮影カメラ74のシャッタ解放時間を制御することによって、光量を制御するのと同等の作用を行っても良い。
【0040】
請求項4の装置を用いて請求項3の方法を実行する動作を図8のフローチャートに従って説明する。ステップ81において照明の初期強度Lを設定する。次第に照明強度を下げながら計測する場合には、Lは十分大きな値とし、次第に照明強度を上げながら計測する場合には、Lは十分小さな値とする。次に、形状データメモリ77に格納された画像全画素に対応して設けられた計測済みフラグFを全て0にリセットする。ステップ82において、制御装置78は遠方のライト71を強度Lで点灯させ、撮影カメラ74に被計測物体73を撮影させて得られた画像データ1を画像メモリ75に格納後、遠方のライト71を消灯する。ステップ83において、制御装置78は手前のライト72を強度Lで点灯させ、撮影カメラ74に被計測物体73を撮影させて得られた画像データ2を画像メモリ75に格納後、手前のライト72を消灯する。ステップ84において、撮影カメラ74に被計測物体73を撮影させて得られた画像データ3を画像メモリ75に格納する。ステップ85において、制御装置78は計測済みフラグ格納メモリ79に格納された全フラグを1画素毎に順次読み出し、座標値(i,j)のF=0ならば座標値(i,j)を画像演算器76に与えて該座標値の画素の距離データの算出を命令する。初期状態は全フラグF=0なので、初めに実行するステップ85は全画素について命令することになる。ステップ86において、画像演算器76は座標値(i,j)の画素の輝度値を画像1、画像2、画像3から取り出す。この輝度値をそれぞれV1、V2、V3とする。ステップ87において、オーバーフローまたはアンダーフローの状態であるか調べる。予め設定された最大輝度値Vmaxに対してV1>VmaxまたはV2>Vmaxであった時にオーバーフローとみなし、予め設定されたVminに対してVmin>|V1−V2|であった時にアンダーフローとみなす。どちらの状態であっても画像演算器76はステップ88の処理を行わない。どちらの状態にもない時は、計測可能と見なしてステップ88に進む。ステップ88において、画像演算器76は以下の式で示される演算を行って座標値(i,j)における距離データx(i,j)を算出し77に格納し、座標値(i,j)のフラグFを1にセットする。
(式8)x(i,j)=x0/〔1−√{(V1−V3)/(V2−V3)}〕
【0041】
なお、遠方のライト71と手前のライト72間の距離x0は既知であり画像演算器76に予め与えられているものとする。ステップ89において制御装置78は計測済みフラグ格納メモリ79の全フラグを調べ全てのフラグF=1ならば終了する。そうでなければ、ステップ810からステップ82〜88を反復して繰り返すが、反復回数が一定以上になった場合にも終了する。ステップ810において、次第に照明強度を下げながら計測する場合にはLを小さくし、次第に照明強度を上げながら計測する場合にはLを大きくしてステップ82に戻る。
【0042】
本実施例ではどの画素の距離も一回の計測で求めることになるが、実際には数回計測できる場合もある。そこで、計測できる場合には距離を算出して全て形状データメモリ77に書き込んでおき、計測終了後に複数回計測した距離の平均または加重平均を取ることによって最終的な距離としても良い。この場合、計算コストは増大するが、計測データのSN比を向上できる利点がある。本実施形態では、照明強度を単調に減少または増加させながら計測を行う例を示した。しかし、本発明の方法では、照明強度は各撮影において互いに異なるように設定しさえすればよく、必ずしも単調に変化させなくてもよい。
【0043】
本発明請求項5の方法および請求項6の装置の一実施形態を図9および図10を用いて説明する。図9は請求項6の装置の構成図、図10は図9の装置を用いて行う請求項5の方法のフローチャートである。図9において、91は拡散光を照射するライト、92はライトの距離を変える移動装置、93は被計測物体、94は撮影カメラであり、本実施例では画像データをデジタルデータとして出力するカメラを使用する。95は撮影回数分の画像データの格納メモリ、96は画像の演算器、97は複数枚分の形状データの格納メモリ、98は全体の制御装置、99は最終形状データの格納メモリである。なお、95から99はパソコンやワークステーションで構成し、96と98にはCPUを使用し、95と97と99はメモリまたは磁気記録媒体等の記憶領域を区分して使用しても良い。また、91と92を組み合わせる代わりに、異なる距離に複数のライトを用意して切り替えて使っても良い。
【0044】
図9の装置を用いて請求項5の方法を実行する動作を図10のフローチャートに従って説明する。ステップ101において、制御装置98は、移動装置92に指令して、ライト91を所定の位置に移動させ、ステップ102においてライト91を点灯させ、撮影カメラ94に被計測物体93を撮影させて得られた画像データを画像メモリ95に格納後、ライト91を消灯する。ステップ103において、ステップ101とステップ102を所定の回数N繰り返す。なお、各繰り返し毎にライト91は被計測物体93との距離が小さくなるように移動させる。ステップ104において、撮影カメラ94に被計測物体93を撮影させて得られた画像データを画像メモリ95に格納する。ステップ105において制御装置98は形状データ算出に使う画像データiと画像データj(i≠j)を画像演算器96に与えて形状データの算出を命令する。ステップ106において、画像演算器96は画像メモリ95から画像データiと画像データjと画像データN+1を取り出し、請求項1の方法に基づいて3次元形状データを算出し形状データメモリ97に格納する。なお、オーバーフローやアンダーフローによって計測不能であった領域は計測不能の印をつけておく。これは該領域では距離に0や負数を書き込むことによって容易に実現できる。ステップ107にて、制御装置98はステップ105とステップ106をM回繰り返す。なお、繰り返し毎に画像演算器96に与えるiとjは変えるものとする。例えば、照明下で撮影した画像がN枚得られている場合、iとjの組み合わせは最大でN(N−1)/2通りあるので、全ての組み合わせを実行するならM=(N−1)/2となる。ただし、常に全部の組み合わせを計算させる必要はない。ステップ108にて形状データ1から形状データMの平均値を求めて最終形状データメモリ99に最終的な形状データを書き込む。各画素毎に距離の平均を求める際に、計測不能だった画素が含まれていた場合は、該画素を除いて平均を求める。
【0045】
なお、本実施例では請求項1の方法を用いたが、計測不能領域を除去するため請求項3の方法を用いることができる。
また、特にアンダーフローは照明の距離差が小さい時に生成しやすいので、距離差の小さい撮影データの全組み合わせは除外して形状データを求めても良い。また、距離差が大きい画像を用いて算出した形状データほどノイズの影響の少ないデータとなるので、ステップ108において、単なる平均ではなく距離差に応じた重み付けをした加重平均を用いても良い。
【0046】
以上、本発明者によってなされた発明を、前記実施例に基づき具体的に説明したが、本発明は、前記実施例に限定されるものではなく、その要旨を逸脱しない範囲において種々変更可能であることは勿論である。
【0047】
【発明の効果】
請求項1の方法および請求項2の装置を用いることによって、外光の存在する条件下でも形状計測が可能となる。
請求項3の方法または請求項4の装置を用いることによって、被計測物体の白黒の濃淡や照明からの遠近に関わらず全体の3次元形状が計測可能となる。
請求項5の方法または請求項6の装置を用いることによって、計測分解能を向上した計測方法および装置を実現することができる。
【図面の簡単な説明】
【図1】従来の装置の構成を示した図である。
【図2】本発明請求項1の方法を示した図である。
【図3】オーバーフロー領域やアンダーフロー領域の発生を示した図である。
【図4】実際の距離と計測された距離の対応を示すグラフである。
【図5】本発明請求項2の装置の実施例の構成図である。
【図6】本発明請求項1の方法の実施例のフローチャートである。
【図7】本発明請求項4の装置の実施例の構成図である。
【図8】本発明請求項3の方法の実施例のフローチャートである。
【図9】本発明請求項6の装置の実施例の構成図である。
【図10】本発明請求項5の方法の実施例のフローチャートである。
【符号の説明】
11…遠方の光源、12…近方の光源、13…被計測物体、14…カメラ、35…オーバーフローで計測できなかった領域、36…アンダーフローで計測できなかった領域、45〜411…実際の距離と計測の結果得られる距離との関係を表したグラフ、51、71…遠方のライト、52、72…手前のライト、53、73、93…被計測物体、54、74、94…撮影カメラ、55、75、95…画像メモリ、56、76、96…画像演算器、57、77、97…形状データメモリ、58、78、98…制御装置、79…計測済みフラグ格納メモリ、91…ライト、92…移動装置、99…最終形状データメモリ
[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention is a method and an apparatus for measuring a three-dimensional shape or a three-dimensional shape and color of an object to be measured, and is mainly used in the fields of the measurement industry, the communication industry, and the video industry.
[0002]
[Prior art]
Various measurement methods for acquiring a three-dimensional shape of an object to be measured using a camera have been proposed. These methods can be classified into a passive measurement method, which does not irradiate a special illumination to the object to be measured, represented by a stereo method, and an active measurement method, which irradiates a special illumination to the object to be measured.
[0003]
The passive measurement method is very low cost and versatile because it can be performed with two cameras, and has been studied vigorously for a long time. However, the measurement reliability is still low and it has reached the practical stage as a versatile method. Not in.
[0004]
On the other hand, the measurement accuracy, resolution, and measurement reliability of the active measurement method have reached practical levels, and moving image measurement has become possible in recent years. However, there is a problem that the apparatus is generally large and expensive, and it is difficult to reduce the apparatus to a size that can be portable.
[0005]
In some cases, the measurement accuracy and resolution may be low depending on the application. However, the conventional active measurement method cannot efficiently reduce the price and size of the apparatus even if these specifications are reduced.
[0006]
On the other hand, there is a device that obtains a distance by irradiating an object to be measured with diffused light from different distances and photographing the object, and calculating a ratio of luminance values of the images (Patent Document 1).
FIG. 1 shows the configuration of this device. 11 is a distant light source, 12 is a near light source, 13 is an object to be measured, and 14 is a camera. Although this device is not very high in measurement accuracy and resolution, it can basically be constructed simply by preparing two light sources and a camera. Can be used.
[0007]
The operation principle of this device will be described by using mathematical expressions.
The distance between the distant light source 11 and the object 13 to be measured is x, and the light amounts of the distant light source 11 and the near light source 12 are L. If the relative intensity ratio between 11 and 12 is known, the light amounts may be different.) And the luminance V1 of a certain point on the measured object 13 illuminated by the distant light source 11 is the distant light source 11 And k is the reflectivity of reflecting the irradiation light from the light source 12 in the vicinity toward the camera.
(Equation 1) V1 = kL / 4πx2
The image is shot at a brightness of. Assuming that the near light source 12 is closer to the measured object 13 by a distance x0 than the far light source 11, the brightness V2 of the point illuminated by the near light source 12 is:
(Equation 2) V2 = kL / 4π (x−x0)2
The image is shot at a brightness of. By taking the ratio of Equation 1 and Equation 2, the distance x becomes
(Equation 3) x = x0 / {1-{(V1 / V2)}}
Is obtained as
[0008]
Although Patent Document 1 does not specify whether the measurement is a distance measurement of one point or the measurement of the entire three-dimensional shape, an invention explicitly showing the three-dimensional shape measurement with the same measurement principle is described in the claim of Patent Document 2. Has been described. Further, the same invention as in Patent Document 2 changes the expression of the mathematical expression, and claims 1 and 2 of Patent Document 3, Claim 1 of Patent Document 4, Claim 1 of Patent Document 5, and Claim 1 of Patent Document 6. It is described in.
[0009]
[Patent Document 1]
JP-A-61-155909
[Patent Document 2]
Japanese Patent Publication No. 6-0768888
[Patent Document 3]
JP-A-2002-077944
[Patent Document 4]
JP-A-2002-065581
[Patent Document 5]
JP-A-2002-095625
[Patent Document 6]
JP 2002-065585 A
[0010]
[Problems to be solved by the invention]
However, this conventional measuring method has the following problems.
1. If external light is present, the correct distance cannot be obtained.
In the case where external light exists, assuming that the external light amount is La and the reflectance for reflecting the external light in the direction of the photographing camera is k ′, Expressions 1 and 2 are replaced by Expressions 4 and 5 below.
(Equation 4) V1 = k'La + kL / 4πx2
(Equation 5) V2 = k′La + kL / 4π (x−x0)2
Even if the ratios of these equations are taken, the distances x 'cannot be obtained because the unknown quantities k' and La remain. Therefore, the conventional measuring method can operate only in an environment without external light such as a dark room or an endoscope. It is a first object of the present invention to provide a measuring method and an apparatus capable of measuring a correct distance even when external light is present.
[0011]
2. It is difficult to simultaneously measure a black region or a region far from the illumination and a white region or a region near the illumination of the measured object.
When the light amount is increased so that the black (low reflectance) area of the measured object or the area far from the illumination can be measured, the brightness of the white (high reflectance) area of the measured object or the area near the illumination overflows and the image is captured. become unable. On the other hand, if the amount of light is reduced to avoid overflow, the luminance of a black area of the measured object or an area far from the illumination becomes extremely small. In this measurement method, the distance is calculated using a slight difference between the luminance values V1 and V2. Therefore, if the value of V1 or V2 itself is small, the difference becomes less than the luminance gradation that can be photographed by the TV camera, and the measurement becomes impossible. Problems occur. This unmeasurable state is called an underflow here. It is a second object of the present invention to provide a measuring method and apparatus capable of measuring the whole of an object to be measured irrespective of black and white shading of the object to be measured and distance from illumination.
[0012]
3. Poor measurement resolution.
The captured image has a wide range of luminance distribution due to the difference in reflectance on the measured object and the distance from illumination. In comparison, the difference between V1 and V2 is only a small value. For example, if the difference between V1 and V2 is only a few gradations, the measurement resolution is also only a few gradations. In this case, only rough distance information enough to know the position of the object can be obtained. It is a third object of the present invention to provide a measurement method and an apparatus with improved measurement resolution.
[0013]
[Means for Solving the Problems]
In order to solve the problem 1, the method according to the first aspect of the present invention performs processing in steps shown in FIG. In a first step 21, the object to be measured is irradiated with diffused light from a certain distance, and an image 1 is obtained by photographing and recording the object to be measured. In a second step 22, a distance closer by x0 than the first step is obtained. The object 2 is irradiated with diffused light from the object, and the image 2 is obtained by photographing and recording the object to be measured. In the third step 23, no illumination or the first step 21 or the second step 22 is performed. The object 3 is irradiated by changing the amount of diffused light from the distance, and the object 3 is photographed and recorded to obtain the image 3. In the fourth step 24, the same position of the image 1, the image 2, and the image 3 is obtained. By calculating the luminance value recorded in the pixel of, the distance to the object to be measured reflected in the pixel is calculated, and in the fifth step 25, the processing of the fourth step is performed on all the pixels. Obtaining the three-dimensional shape of the measurement subject by Ukoto.
[0014]
The operation performed for each step will be described. In a first step 21, an image 1 is obtained by irradiating diffuse light to a measured object from a certain distance, and photographing and recording the measured object. At this time, the luminance V1 at a certain point on the measured object is L, the intensity of the diffused light is L, the distance between the point and the illuminating means is x, the reflectance for reflecting the illuminating light in the direction of the photographing means is k, Assuming that the light amount is La and the reflectivity for reflecting external light in the direction of the photographing means is k ′,
(Equation 4) V1 = k'La + kL / 4πx2
An image is taken at a luminance value of
[0015]
Next, in a second step 22, diffused light is irradiated on the measured object from a distance closer to the distance x0 than in the first step 21, and the measured object is photographed and recorded to obtain the image 2. At this time, the brightness V2 of the point on the measured object is
(Equation 5) V2 = k′La + kL / 4π (x−x0)2
An image is taken at a luminance value of
[0016]
Next, in a third step 23, the object to be measured is illuminated without illumination, or the amount of diffused light is changed from the distance in the first step 21 or the second step 22, and the object to be measured is photographed and recorded. Thus, an image 3 is obtained. If there is no illumination here, the luminance V3 at the same position in the measured object illuminated by the light source is
(Equation 6) V3 = k′La
And irradiating the amount of diffused light at 1 / n times from the position of the first step 21,
(Equation 61) V3 = k′La + kL / 4nπx2
And irradiating the amount of diffused light at 1 / n times from the position of the second step 22,
(Equation 62) V3 = k′La + kL / 4nπ (x−x0)2
Becomes
[0017]
Next, in a fourth step 24, the distance of the measured object shown in the pixel is calculated by calculating the luminance value recorded in the pixel at the same position in the image 1, the image 2 and the image 3. For example, in the case where the image 3 is an image taken without lighting, by simultaneously combining Expressions 4, 5, and 6,
(Equation 7) x = x0 / [1-{(V1-V3) / (V2-V3)}]
Calculates the distance x.
[0018]
It should be noted that x can be calculated as long as n is known, even if Equations 61 and 62 are used instead of Equation 6. When there is external light but the amount of light is smaller than that of the illumination light, the method of Expressions 61 and 62 for auxiliary illumination is advantageous in increasing the measurement accuracy.
[0019]
Finally, in a fifth step 25, the three-dimensional shape of the measured object shown in the image is calculated by applying the pixel calculation processing of the fourth step 24 to the entire image.
[0020]
According to a second aspect of the present invention, there is provided an apparatus having illumination means for irradiating diffused light from different distances, means for photographing an object to be measured, image data recording means, and image data calculation means. Work according to the method.
[0021]
First, the first step 21, the second step 22, and the third step 23 are executed using illumination means for irradiating diffused light from different distances and means for photographing an object to be measured, and the captured image data Is recorded using recording means. Next, the fourth step 24 and the fifth step 25 are executed using the image data calculation means.
[0022]
By using the method according to claim 1 and the device according to claim 2, shape measurement can be performed even under conditions where external light is present, and thus problem 1 can be solved.
[0023]
In order to solve the problem 2, the method according to claim 3 of the present invention performs the following steps. In the sixth step, a sufficiently strong (weak) amount of diffused light is irradiated, and the three-dimensional shape of the measured object is measured by the method of claim 1. In the seventh step, the amount of light is reduced (increased) in an area where the luminance value overflowed (underflow) and could not be measured in the image acquired in the sixth step, and the sixth step is executed again. Re-measure the area that could not be measured. In the eighth step, the seventh step is repeated until there is no unmeasurable region or a predetermined number of repetitions is reached.
[0024]
The operation performed in each step will be described with an example in which measurement is started from a sufficiently strong light amount and the light amount is gradually decreased. First, in the sixth step, a sufficiently strong amount of diffused light is irradiated, and the three-dimensional shape of the measured object is measured by the method of claim 1. Then, as shown in FIG. 3A, an area 35 in which the luminance of a white area or an area close to the illumination of the measured object overflows in photographing and cannot be measured has occurred.
[0025]
Next, in a seventh step, the light amount is reduced, and the sixth step is repeated. Then, as shown in FIG. 3B, a part of the area which could not be measured due to the previous overflow can be measured again. On the other hand, an area 36 that cannot be measured due to underflow occurs in a black area of the measured object or an area far from the illumination, but this area has already been measured in the previous measurement. In the eighth step, the seventh step is repeated until there is no unmeasurable region or a predetermined number of repetitions is reached. Then, as shown in FIG. 3 (C), all the areas where the overflow has occurred can be re-measured, and all the measured areas from FIGS. 3 (A) to 3 (C) can be measured together. become.
When starting from a sufficiently weak light amount, the measurement starts from FIG. 3 (C) and ends the measurement in FIG. 3 (A).
[0026]
The apparatus according to claim 4 of the present invention includes an illuminating unit that irradiates diffused light from different distances with variable light amounts, a unit that captures an object to be measured, a recording unit for image data, and a computing unit for image data. It operates according to the method of claim 3.
[0027]
First, the sixth step is executed by using an illuminating unit that changes the amount of light and irradiates diffused light from different distances and a unit that captures an image of an object to be measured, and records a measurement result only in a region where measurement was possible. Next, the seventh step is executed to additionally record the measurement result for the newly measurable area. Then, the three-dimensional shape of the object to be measured is obtained by repeating the seventh step until there is no unmeasurable region or a predetermined number of repetitions is reached.
[0028]
By using the method of the third aspect or the apparatus of the fourth aspect, the entire three-dimensional shape of the object to be measured can be measured irrespective of the black and white shading of the object or the distance from the illumination, so that the problem 2 can be solved.
[0029]
In order to solve the problem 3, the method according to claim 5 of the present invention performs the following steps. In the first step, the object to be measured is irradiated with diffused light from a distance obtained by gradually changing the distance to the object to be measured N times, and an image of the object to be measured is photographed and recorded for each irradiation, whereby N sheets are obtained. Images 1 to N are acquired. In the second step, an image N + 1 is obtained by photographing and recording an object to be measured without illumination. In the third step, the distance of the measured object shown in the pixel from the image 1 to the image N + 1 is calculated by calculating the luminance value recorded in the pixel at the same position.
[0030]
As an example, a method of calculating a distance by combining the method of claim 1 will be described. In order to calculate the distance by using the method of claim 1, two images and an image N + 1 photographed by diffused lights having different distances are required, so that, for example, photographing of N = 4 (image 1 to image 4) is performed. If performed, a set of image 1 and image 2, image 2 and image 3, image 3 and image 4, image 1 and image 3, image 2 and image 4, image 1 and image 4, and image 5 (N + 1) By calculating with, six distances can be calculated. The average of these values is used as the final distance. In the fourth step, the three-dimensional shape of the measured object is calculated by performing the third step on all pixels.
[0031]
The operation of claim 5 will be described. FIG. 4 is a diagram showing a graph representing a relationship between an actual distance and a distance obtained as a result of measurement for each combination of images. When images 4 are obtained from four images 1 by irradiating diffused light from four distances x1, x2, x3, x4 (where x1> x2> x3> x4), a graph obtained by combining these images is obtained. 45 to 410. Originally, graphs should ideally be diagonal lines, but all graphs have stepwise broken lines due to poor resolution. However, when the average value of these graphs is calculated, 411 is obtained, and it can be seen that the stairs become finer, that is, the measurement resolution is improved and approaches the oblique line.
[0032]
The apparatus according to claim 6 of the present invention has illumination means for irradiating diffused light from at least three or more different distances, means for photographing an object to be measured, means for recording image data, and means for calculating image data. , According to the method of claim 5.
[0033]
The operation of the device according to claim 6 will be described. The first step and the second step are executed by using illumination means for irradiating diffused light from at least three or more different distances, means for photographing an object to be measured, and means for recording image data. Next, the third step and the fourth step are executed by using image data calculation means.
[0034]
By using the method of claim 5 or the device of claim 6, a measuring method and device with improved measurement resolution can be realized, and the problem 3 can be solved.
[0035]
BEST MODE FOR CARRYING OUT THE INVENTION
One embodiment of the method of the present invention and the apparatus of the present invention will be described with reference to FIGS. FIG. 5 is a block diagram of the device of the second embodiment, and FIG. 6 is a flowchart of the method of the first embodiment performed by using the device of FIG. In FIG. 5, reference numeral 51 denotes a light for irradiating diffused light from a distance, 52 denotes a light for irradiating diffused light from this side, 53 denotes an object to be measured, and 54 denotes a photographing camera. In this embodiment, image data is output as digital data. Use a camera to Reference numeral 55 denotes a storage memory for image data, 56 denotes an arithmetic unit for an image, 57 denotes a storage memory for shape data, and 58 denotes an overall control device. Incidentally, 55 to 58 may be constituted by personal computers or workstations, CPUs may be used for 56 and 58, and 55 and 57 may be used by dividing a storage area such as a memory or a magnetic recording medium.
[0036]
The operation of executing the method of claim 1 using the device of claim 2 will be described with reference to the flowchart of FIG. In step 61, the control device 58 turns on the distant light 51, stores the image data 1 obtained by causing the photographing camera 54 to photograph the measured object 53 in the image memory 55, and then turns off the distant light 51. In step 62, the control device 58 turns on the front light 52, stores the image data 2 obtained by causing the photographing camera 54 to photograph the measured object 53 in the image memory 55, and then turns off the front light 52. In step 63, the image data 3 obtained by causing the photographing camera 54 to photograph the measured object 53 is stored in the image memory 55. In step 64, the control device 58 gives the coordinate value (i, j) to the image calculator 56, and instructs calculation of distance data from the luminance value of the pixel having the coordinate value. In step 65, the image calculator 56 extracts the luminance value of the pixel having the coordinate value (i, j) from the image 1, the image 2, and the image 3. These luminance values are denoted by V1, V2, and V3, respectively. In step 66, the image calculator 56 calculates the distance data x (i, j) at the coordinate value (i, j) by performing the calculation represented by the following equation, and stores the distance data x (i, j) in the shape data memory 57.
(Equation 8) x (i, j) = x0 / [1-{(V1-V3) / (V2-V3)}]
[0037]
It is assumed that the distance x0 between the far light 51 and the near light 52 is known and given to the image calculator 56 in advance. In step 67, the control device 58 determines whether the calculation processing has been completed for all the coordinates of the image, and ends if the calculation processing has been performed. Otherwise, the uncalculated coordinate value (i, j) is determined in step 68, and the process returns to step 64. The image is sequentially scanned from the upper left to determine the coordinate value (i, j), and the arrival at the lower right coordinate value is used as a determination condition of the end. It goes without saying that the determination can be realized.
[0038]
One embodiment of the method of the present invention and the apparatus of the present invention will be described with reference to FIGS. FIG. 7 is a block diagram of the apparatus according to claim 4, and FIG. 8 is a flowchart of a method according to claim 3 performed using the apparatus of FIG. 7, reference numeral 71 denotes a distant light for irradiating a specified amount of diffused light, 72 denotes a light in front of irradiating a specified amount of diffused light, 73 denotes an object to be measured, and 74 denotes a photographing camera. In the embodiment, a camera that outputs image data as digital data is used. 75 is an image data storage memory, 76 is an image arithmetic unit, 77 is shape data storage memory, 78 is an overall control device, and 79 is measured flag data storage memory. Incidentally, 75 to 79 may be constituted by a personal computer or a workstation, CPUs may be used for 76 and 78, and 75, 77 and 79 may be used by dividing a storage area such as a memory or a magnetic recording medium.
[0039]
Further, instead of controlling the light amounts of the distant light 71 and the near light 72, the same operation as controlling the light amount may be performed by controlling the shutter release time of the photographing camera 74.
[0040]
The operation of executing the method of claim 3 using the device of claim 4 will be described with reference to the flowchart of FIG. In step 81, an initial illumination intensity L is set. L is set to a sufficiently large value when the measurement is performed while gradually decreasing the illumination intensity, and L is set to a sufficiently small value when the measurement is performed while the illumination intensity is gradually increased. Next, all the measured flags F provided for all the pixels of the image stored in the shape data memory 77 are reset to zero. In step 82, the control device 78 turns on the distant light 71 after turning on the distant light 71 at the intensity L and storing the image data 1 obtained by causing the photographing camera 74 to photograph the object 73 to be measured in the image memory 75. Turn off the light. In step 83, the control device 78 turns on the front light 72 at the intensity L, stores the image data 2 obtained by causing the photographing camera 74 to photograph the object 73 to be measured in the image memory 75, and then turns on the front light 72. Turn off the light. In step 84, the image data 3 obtained by causing the photographing camera 74 to photograph the measured object 73 is stored in the image memory 75. In step 85, the control device 78 sequentially reads out all the flags stored in the measured flag storage memory 79 for each pixel, and if F = 0 of the coordinate value (i, j), the coordinate value (i, j) is displayed in the image. It is given to the arithmetic unit 76 to instruct the calculation of the distance data of the pixel having the coordinate value. Since the initial state is all flags F = 0, step 85 to be executed first instructs all pixels. In step 86, the image calculator 76 extracts the luminance value of the pixel having the coordinate value (i, j) from the image 1, the image 2, and the image 3. These luminance values are denoted by V1, V2, and V3, respectively. In step 87, it is checked whether an overflow or underflow condition exists. When V1> Vmax or V2> Vmax with respect to a preset maximum luminance value Vmax, it is regarded as an overflow, and when Vmin> | V1-V2 | with respect to a preset Vmin, it is regarded as an underflow. In either state, the image calculator 76 does not perform the process of step 88. If neither state exists, it is considered that measurement is possible, and the routine proceeds to step 88. In step 88, the image calculator 76 calculates the distance data x (i, j) at the coordinate value (i, j) by performing the calculation represented by the following equation, stores the distance data x (i, j) in 77, and stores the coordinate value (i, j) Is set to 1.
(Equation 8) x (i, j) = x0 / [1-{(V1-V3) / (V2-V3)}]
[0041]
It is assumed that the distance x0 between the far light 71 and the near light 72 is known and given to the image calculator 76 in advance. In step 89, the control device 78 checks all the flags in the measured flag storage memory 79, and ends if all the flags F = 1. Otherwise, steps 810 to 82 to 88 are repeated and repeated, but also ends when the number of repetitions has exceeded a certain value. In step 810, L is decreased when the measurement is performed while the illumination intensity is gradually reduced, and L is increased when the measurement is performed while the illumination intensity is gradually increased, and the process returns to step 82.
[0042]
In the present embodiment, the distance of any pixel is obtained by one measurement, but actually, it may be measured several times. Therefore, when the measurement can be performed, the distance may be calculated and written in the shape data memory 77, and an average or a weighted average of the distances measured a plurality of times after the measurement is completed may be used as a final distance. In this case, although the calculation cost increases, there is an advantage that the SN ratio of the measurement data can be improved. In the present embodiment, an example has been described in which measurement is performed while the illumination intensity is monotonously reduced or increased. However, in the method of the present invention, the illumination intensity need only be set to be different from each other in each photographing, and does not necessarily need to be changed monotonically.
[0043]
One embodiment of the method according to claim 5 and the apparatus according to claim 6 will be described with reference to FIGS. 9 and 10. FIG. 9 is a block diagram of the apparatus of claim 6, and FIG. 10 is a flowchart of a method of claim 5 performed using the apparatus of FIG. 9, reference numeral 91 denotes a light for irradiating diffused light; 92, a moving device for changing the distance of the light; 93, an object to be measured; and 94, a photographing camera. In this embodiment, a camera for outputting image data as digital data is used. use. Reference numeral 95 denotes a memory for storing image data corresponding to the number of times of image capturing, 96 denotes an image calculator, 97 denotes a memory for storing shape data for a plurality of images, 98 denotes an overall control device, and 99 denotes a memory for storing final shape data. Note that 95 to 99 may be constituted by personal computers or workstations, CPUs may be used for 96 and 98, and 95, 97 and 99 may be used by dividing storage areas such as memories or magnetic recording media. Instead of combining 91 and 92, a plurality of lights may be prepared at different distances and used by switching.
[0044]
The operation of executing the method of claim 5 using the apparatus of FIG. 9 will be described with reference to the flowchart of FIG. In step 101, the control device 98 instructs the moving device 92 to move the light 91 to a predetermined position, turns on the light 91 in step 102, and causes the photographing camera 94 to photograph the object 93 to be measured. After the stored image data is stored in the image memory 95, the light 91 is turned off. In step 103, steps 101 and 102 are repeated a predetermined number of times N. It should be noted that the light 91 is moved so that the distance from the measured object 93 becomes smaller at each repetition. In step 104, image data obtained by causing the photographing camera 94 to photograph the measured object 93 is stored in the image memory 95. In step 105, the control device 98 gives the image data i and the image data j (i ≠ j) to be used for calculating the shape data to the image calculator 96 to instruct the calculation of the shape data. In step 106, the image calculator 96 extracts the image data i, the image data j, and the image data N + 1 from the image memory 95, calculates three-dimensional shape data based on the method of claim 1, and stores it in the shape data memory 97. Note that a region that cannot be measured due to overflow or underflow is marked as unmeasurable. This can be easily realized in the area by writing 0 or a negative number in the distance. In step 107, control device 98 repeats steps 105 and 106 M times. It should be noted that i and j given to the image computing unit 96 are changed each time it is repeated. For example, when N images captured under illumination are obtained, the combinations of i and j are N (N-1) / 2 at the maximum, so if all the combinations are executed, M = (N-1) ) / 2. However, it is not always necessary to calculate all combinations. In step 108, the average value of the shape data M is obtained from the shape data 1, and the final shape data is written in the final shape data memory 99. When calculating the average of the distance for each pixel, if a pixel that cannot be measured is included, the average is calculated excluding the pixel.
[0045]
In this embodiment, the method according to claim 1 is used, but the method according to claim 3 can be used to remove an unmeasurable region.
In particular, since underflow is easily generated when the difference in illumination distance is small, shape data may be obtained by excluding all combinations of photographing data having small distance differences. In addition, since the shape data calculated using an image having a large distance difference has less influence of noise, a weighted average weighted according to the distance difference may be used in step 108 instead of a simple average.
[0046]
As described above, the invention made by the inventor has been specifically described based on the embodiment. However, the present invention is not limited to the embodiment, and can be variously modified without departing from the gist of the invention. Of course.
[0047]
【The invention's effect】
By using the method according to claim 1 and the device according to claim 2, shape measurement can be performed even under conditions where external light exists.
By using the method according to the third aspect or the apparatus according to the fourth aspect, it is possible to measure the entire three-dimensional shape of the object to be measured irrespective of the density of black and white or the distance from illumination.
By using the method of claim 5 or the device of claim 6, a measurement method and device with improved measurement resolution can be realized.
[Brief description of the drawings]
FIG. 1 is a diagram showing a configuration of a conventional device.
FIG. 2 shows a method according to claim 1 of the present invention.
FIG. 3 is a diagram showing occurrence of an overflow area and an underflow area.
FIG. 4 is a graph showing a correspondence between an actual distance and a measured distance.
FIG. 5 is a block diagram of an embodiment of the apparatus according to claim 2 of the present invention.
FIG. 6 is a flow chart of an embodiment of the method of claim 1 of the present invention.
FIG. 7 is a block diagram of an embodiment of the apparatus according to claim 4 of the present invention.
FIG. 8 is a flowchart of an embodiment of the method according to claim 3 of the present invention.
FIG. 9 is a block diagram of an embodiment of the apparatus according to claim 6 of the present invention.
FIG. 10 is a flowchart of an embodiment of the method according to claim 5 of the present invention.
[Explanation of symbols]
11: distant light source, 12: near light source, 13: measured object, 14: camera, 35: area that could not be measured due to overflow, 36: area that could not be measured due to underflow, 45 to 411: actual A graph showing the relationship between the distance and the distance obtained as a result of the measurement, 51, 71: far lights, 52, 72: front lights, 53, 73, 93: measured object, 54, 74, 94: photographing camera ..., 55, 75, 95 ... image memory, 56, 76, 96 ... image calculator, 57, 77, 97 ... shape data memory, 58, 78, 98 ... controller, 79 ... measured flag storage memory, 91 ... write , 92: moving device, 99: final shape data memory

Claims (6)

ある距離から拡散光を被計測物体に照射し、被計測物体を撮影、記録することによって画像1を取得する第1のステップと、
第1のステップとは異なる距離から拡散光を被計測物体に照射し、被計測物体を撮影、記録することによって画像2を取得する第2のステップと、
無照明で、または、第1のステップまたは第2のステップの距離から拡散光の光量を変えて被計測物体に照射して、被計測物体を撮影、記録することによって画像3を取得する第3のステップと、
画像1と画像2と画像3の同位置の画素に記録された輝度値を演算することによって該画素に写っている被計測物体までの距離を算出する第4のステップと、第4のステップを全画素に行うことによって被計測物体の3次元形状を求める第5のステップ
を有することを特徴とする3次元形状計測方法。
A first step of irradiating the object to be measured with diffused light from a certain distance, photographing and recording the object to be measured, and acquiring an image 1;
A second step of irradiating the object to be measured with diffused light from a distance different from that of the first step, and capturing and recording the object to be measured to obtain an image 2;
Irradiating the object to be measured with no light or changing the amount of diffused light from the distance of the first step or the second step, and photographing and recording the object to obtain the third image 3 Steps and
A fourth step of calculating a distance to an object to be measured in the pixel by calculating a luminance value recorded at a pixel at the same position in the image 1, the image 2, and the image 3; A method for measuring a three-dimensional shape, comprising: a fifth step of obtaining a three-dimensional shape of an object to be measured by performing the process on all pixels.
異なる距離から拡散光を照射する照明手段と、被計測物体を撮影する手段と、画像データの記録手段と、画像データの演算手段を有し、請求項1の方法で動作することを特徴とする3次元形状計測装置。An illumination unit for irradiating diffused light from different distances, a unit for photographing an object to be measured, a unit for recording image data, and a unit for calculating image data, and are operated by the method according to claim 1. 3D shape measuring device. ある光量の拡散光を用いて、請求項1の方法で被計測物体の3次元形状を計測する第6のステップと、第6のステップにて取得したいずれかの画像内で輝度値が所定の値より大きいか、または、画像1と画像2の同位置の画素間の輝度値の差の絶対値が所定の値より小さい領域について、拡散光の光量を変えて再度第6のステップを実行することにより再計測する第7のステップと、
前記領域がなくなるか、または、所定の反復回数に達するまで第7のステップを繰り返す第8のステップ
を有することを特徴とする3次元形状計測方法。
A sixth step of measuring the three-dimensional shape of the object to be measured by the method according to claim 1 using a certain amount of diffused light; For a region that is larger than the value or the absolute value of the difference in luminance value between pixels at the same position in the image 1 and the image 2 is smaller than a predetermined value, the sixth step is executed again by changing the amount of diffused light. A seventh step of re-measurement by
The method of measuring a three-dimensional shape according to claim 8, further comprising an eighth step of repeating the seventh step until the region disappears or a predetermined number of repetitions is reached.
光量を変えられ異なる距離から拡散光を照射する照明手段と、該照明手段で照明された被計測物体を撮影する手段と、画像データの記録手段と、画像データの演算手段を有し、請求項3の方法で動作することを特徴とする3次元形状計測装置。An illumination unit that changes the amount of light and emits diffused light from different distances, a unit that captures an image of the object to be measured illuminated by the illumination unit, an image data recording unit, and an image data calculation unit. 3. A three-dimensional shape measuring apparatus which operates by the method according to 3. 被計測物体までの距離を少なくとも3ヶ所以上互いに換えた拡散光で被計測物体を照射し、各照射毎に被計測物体の画像を撮影することによってN枚の画像1から画像Nまでを撮影、記録する第1のステップと、
無照明で被計測物体を撮影、記録することによって画像N+1を取得する第2のステップと、
画像1から画像N+1の同座標値の画素に記録された輝度値を演算することによって該画素に写っている被計測物体の距離を算出する第3のステップと、
第3のステップを全画素に行うことによって被計測物体の3次元形状を求める第4のステップ
を有することを特徴とする3次元形状計測方法。
By irradiating the object to be measured with diffused light whose distance to the object to be measured is changed at least three places or more, and taking images of the object to be measured for each irradiation, N images 1 to N are taken, A first step of recording;
A second step of acquiring an image N + 1 by photographing and recording an object to be measured without illumination;
A third step of calculating a distance of an object to be measured reflected on the pixel by calculating a luminance value recorded on a pixel having the same coordinate value of the image 1 from the image 1;
A method for measuring a three-dimensional shape, comprising: a fourth step of obtaining a three-dimensional shape of an object to be measured by performing a third step on all pixels.
少なくとも3ヶ所以上の互いに異なる距離から拡散光を照射する照射手段と、被計測物体を撮影する手段と、画像データの記録手段と、画像データの演算手段を有し、請求項5の方法で動作することを特徴とする3次元形状計測装置。6. An apparatus according to claim 5, comprising: irradiating means for irradiating diffused light from at least three or more different distances, means for photographing an object to be measured, means for recording image data, and means for calculating image data. A three-dimensional shape measuring apparatus.
JP2002282512A 2002-09-27 2002-09-27 3D shape measuring method and 3D shape measuring apparatus Expired - Fee Related JP3825383B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002282512A JP3825383B2 (en) 2002-09-27 2002-09-27 3D shape measuring method and 3D shape measuring apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002282512A JP3825383B2 (en) 2002-09-27 2002-09-27 3D shape measuring method and 3D shape measuring apparatus

Publications (2)

Publication Number Publication Date
JP2004117235A true JP2004117235A (en) 2004-04-15
JP3825383B2 JP3825383B2 (en) 2006-09-27

Family

ID=32276643

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002282512A Expired - Fee Related JP3825383B2 (en) 2002-09-27 2002-09-27 3D shape measuring method and 3D shape measuring apparatus

Country Status (1)

Country Link
JP (1) JP3825383B2 (en)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006349490A (en) * 2005-06-15 2006-12-28 Matsushita Electric Ind Co Ltd Component teaching data creating method
JP2008152380A (en) * 2006-12-14 2008-07-03 Toyohashi Univ Of Technology Conveyance method of overhead crane using laser pointer and overhead crane system
JP2010060494A (en) * 2008-09-05 2010-03-18 Fujitsu Ltd Posture measurement device
JP2011239224A (en) * 2010-05-11 2011-11-24 Sea Phone Co Ltd Stereoscopic image creation device and stereoscopic image creation method
WO2014046325A1 (en) * 2012-09-24 2014-03-27 위프코 주식회사 Three-dimensional measuring system and method thereof
WO2014174779A1 (en) * 2013-04-26 2014-10-30 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ Motion sensor apparatus having a plurality of light sources
WO2014208087A1 (en) * 2013-06-27 2014-12-31 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ Motion sensor device having plurality of light sources
WO2015001770A1 (en) * 2013-07-01 2015-01-08 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ Motion sensor device having plurality of light sources
JP2017146753A (en) * 2016-02-17 2017-08-24 セイコーエプソン株式会社 Position detection device, and contrast adjustment method for the same

Cited By (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006349490A (en) * 2005-06-15 2006-12-28 Matsushita Electric Ind Co Ltd Component teaching data creating method
JP4580824B2 (en) * 2005-06-15 2010-11-17 パナソニック株式会社 Parts teaching data creation method
JP2008152380A (en) * 2006-12-14 2008-07-03 Toyohashi Univ Of Technology Conveyance method of overhead crane using laser pointer and overhead crane system
JP4574609B2 (en) * 2006-12-14 2010-11-04 国立大学法人豊橋技術科学大学 Transport method by overhead crane using laser pointer and overhead crane system
JP2010060494A (en) * 2008-09-05 2010-03-18 Fujitsu Ltd Posture measurement device
JP2011239224A (en) * 2010-05-11 2011-11-24 Sea Phone Co Ltd Stereoscopic image creation device and stereoscopic image creation method
WO2014046325A1 (en) * 2012-09-24 2014-03-27 위프코 주식회사 Three-dimensional measuring system and method thereof
US9342889B2 (en) 2012-09-24 2016-05-17 Chang-Suk Cho Three-dimensional measurement system and method therefor
CN104395694A (en) * 2013-04-26 2015-03-04 松下电器(美国)知识产权公司 Motion sensor apparatus having a plurality of light sources
WO2014174779A1 (en) * 2013-04-26 2014-10-30 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ Motion sensor apparatus having a plurality of light sources
US9978148B2 (en) 2013-04-26 2018-05-22 Panasonic Intellectual Property Corporation Of America Motion sensor apparatus having a plurality of light sources
JPWO2014174779A1 (en) * 2013-04-26 2017-02-23 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカPanasonic Intellectual Property Corporation of America Motion sensor device having a plurality of light sources
JPWO2014208087A1 (en) * 2013-06-27 2017-02-23 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカPanasonic Intellectual Property Corporation of America Motion sensor device having a plurality of light sources
CN104685318A (en) * 2013-06-27 2015-06-03 松下电器(美国)知识产权公司 Motion sensor device having plurality of light sources
US9863767B2 (en) 2013-06-27 2018-01-09 Panasonic Intellectual Property Corporation Of America Motion sensor device having plurality of light sources
CN104685318B (en) * 2013-06-27 2018-01-26 松下电器(美国)知识产权公司 Motion sensor device, circuit, recording medium and image processing apparatus
WO2014208087A1 (en) * 2013-06-27 2014-12-31 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ Motion sensor device having plurality of light sources
CN104603574A (en) * 2013-07-01 2015-05-06 松下电器(美国)知识产权公司 Motion sensor device having plurality of light sources
WO2015001770A1 (en) * 2013-07-01 2015-01-08 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ Motion sensor device having plurality of light sources
JPWO2015001770A1 (en) * 2013-07-01 2017-02-23 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカPanasonic Intellectual Property Corporation of America Motion sensor device having a plurality of light sources
CN104603574B (en) * 2013-07-01 2017-10-13 松下电器(美国)知识产权公司 Motion sensor device with multiple light sources
US10313599B2 (en) 2013-07-01 2019-06-04 Panasonic Intellectual Property Corporation Of America Motion sensor device having plurality of light sources
JP2017146753A (en) * 2016-02-17 2017-08-24 セイコーエプソン株式会社 Position detection device, and contrast adjustment method for the same

Also Published As

Publication number Publication date
JP3825383B2 (en) 2006-09-27

Similar Documents

Publication Publication Date Title
JP5907596B2 (en) Three-dimensional measuring apparatus, three-dimensional measuring method and program
US7359547B2 (en) Pseudo three dimensional image generating apparatus
US9047514B2 (en) Apparatus, system and method for projecting images onto predefined portions of objects
JP5633058B1 (en) 3D measuring apparatus and 3D measuring method
JP7333467B2 (en) Learning-Based Lens Flare Removal
TWI512270B (en) Optical distance measurement system with dynamicexposure time
Drew et al. Robust estimation of surface properties and interpolation of shadow/specularity components
JPWO2015102057A1 (en) Image processing method, image processing system, and program
JP6869652B2 (en) Image processing device, imaging device, image processing method, image processing program, and storage medium
JP2004117235A (en) 3-dimensional form measuring method and 3-dimensional form measuring apparatus
JP3988879B2 (en) Stereo image generation method, stereo image generation apparatus, stereo image generation program, and recording medium
JP6126519B2 (en) Spatial projection apparatus, spatial projection method, spatial projection program, and recording medium
JP2009294170A (en) Apparatus, method, and program for defect detection and recording medium
JPH02148279A (en) Mark detecting system
JP2004133919A (en) Device and method for generating pseudo three-dimensional image, and program and recording medium therefor
JP2020004085A (en) Image processor, image processing method and program
EP2866432A1 (en) Automatic image compositing device
CN114758111A (en) Self-adaptive light supplementing method, system, device and medium
Koch et al. Hardware Design and Accurate Simulation of Structured-Light Scanning for Benchmarking of 3D Reconstruction Algorithms
CN114915734B (en) Method and device for automatically controlling starting of HDR mode
Wen et al. A low-cost, user-friendly, and real-time operating 3D camera
US20230127730A1 (en) System and method for projection mapping
JP2020122662A (en) Illumination device for surface inspection and surface inspection device
JP2023073003A (en) Rendering apparatus and program thereof
JP2019080258A (en) Image processing method, image processing program using the same, image processing apparatus, and imaging apparatus

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20040707

A977 Report on retrieval

Effective date: 20051220

Free format text: JAPANESE INTERMEDIATE CODE: A971007

A131 Notification of reasons for refusal

Effective date: 20060214

Free format text: JAPANESE INTERMEDIATE CODE: A131

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20060405

A131 Notification of reasons for refusal

Effective date: 20060509

Free format text: JAPANESE INTERMEDIATE CODE: A131

A521 Written amendment

Effective date: 20060601

Free format text: JAPANESE INTERMEDIATE CODE: A523

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Effective date: 20060627

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20060629

R150 Certificate of patent (=grant) or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20090707

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20100707

Year of fee payment: 4

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

Year of fee payment: 5

Free format text: PAYMENT UNTIL: 20110707

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

Year of fee payment: 6

Free format text: PAYMENT UNTIL: 20120707

LAPS Cancellation because of no payment of annual fees