JP7081635B2 - Image processing equipment - Google Patents

Image processing equipment Download PDF

Info

Publication number
JP7081635B2
JP7081635B2 JP2020159608A JP2020159608A JP7081635B2 JP 7081635 B2 JP7081635 B2 JP 7081635B2 JP 2020159608 A JP2020159608 A JP 2020159608A JP 2020159608 A JP2020159608 A JP 2020159608A JP 7081635 B2 JP7081635 B2 JP 7081635B2
Authority
JP
Japan
Prior art keywords
image data
image
exposure
unit
sensitivity
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.)
Active
Application number
JP2020159608A
Other languages
Japanese (ja)
Other versions
JP2021002866A (en
Inventor
義史 笹井
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nikon Corp
Original Assignee
Nikon 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 Nikon Corp filed Critical Nikon Corp
Priority to JP2020159608A priority Critical patent/JP7081635B2/en
Publication of JP2021002866A publication Critical patent/JP2021002866A/en
Priority to JP2022086021A priority patent/JP2022105715A/en
Application granted granted Critical
Publication of JP7081635B2 publication Critical patent/JP7081635B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、複数回の撮像により取得した複数枚の画像を合成して1枚の合成画像を得る画像処理装置に関するものである。 The present invention relates to an image processing apparatus that obtains one composite image by synthesizing a plurality of images acquired by a plurality of imaging.

従来、ダイナミックレンジの広い画像(以下「広ダイナミックレンジ画像」と称す)を生成するために、露光量を変えて撮像した同一被写体の複数の画像を、例えば加算平均による合成をして1枚の合成画像を得る撮像装置が知られている(特許文献1)。この撮像装置の画像合成手段は、標準より多い露光量で得られた画像データを低輝度側のデータとし、標準の露光量で得られた画像データを高輝度側のデータとし、標準より少ない露光量で得られた画像データを超高輝度側のデータとして、全てもしくは任意の組み合わせで画像データを合成している。 Conventionally, in order to generate an image having a wide dynamic range (hereinafter referred to as "wide dynamic range image"), a plurality of images of the same subject taken by changing the exposure amount are combined, for example, by addition averaging to obtain one image. An image pickup device for obtaining a composite image is known (Patent Document 1). The image synthesizing means of this image pickup apparatus uses the image data obtained with an exposure amount higher than the standard as the data on the low brightness side, and the image data obtained with the standard exposure amount as the data on the high brightness side, and exposes less than the standard. The image data obtained by the amount is used as the data on the ultra-high brightness side, and the image data is synthesized by all or any combination.

特開平7-135599号公報Japanese Unexamined Patent Publication No. 7-135599

ところで、CCDやCMOSイメージセンサ等の撮像素子は、高出力(低ISO感度)のときに固定パターンノイズが生じやすく、また、低出力(高ISO感度)のときには光ショットノイズ等のランダムノイズが生じやすい。固定パターンノイズは、ある程度条件が同じであれば値が推測できるノイズであるため、画像処理等で軽減することができるのに対し、ランダムノイズは不特定の位置に発生するため画像処理等での軽減が難しい。 By the way, image sensors such as CCDs and CMOS image sensors tend to generate fixed pattern noise at high output (low ISO sensitivity), and random noise such as optical shot noise at low output (high ISO sensitivity). Cheap. Fixed pattern noise is noise whose value can be estimated if the conditions are the same to some extent, so it can be reduced by image processing, etc., whereas random noise is generated at unspecified positions, so it is used in image processing, etc. Difficult to mitigate.

本発明は、上記課題を解決するために、広ダイナミックレンジ画像に生じるランダムノイズを低減するように工夫した画像処理装置を提供することを目的とする。 An object of the present invention is to provide an image processing apparatus devised to reduce random noise generated in a wide dynamic range image in order to solve the above problems.

本発明の一態様では、画像処理装置は、第1の露光条件による撮像部の撮像動作により生成された第1の画像データと、前記第1の露光条件による露光時間よりも短い露光時間である第2の露光条件による前記撮像部の撮像動作により生成された第2の画像データと、が入力される入力部と、前記撮像部の感度が所定値よりも低い場合、前記第1の画像データと、複数の前記第2の画像データとを合成した合成画像データを生成し、前記撮像部の感度が前記所定値よりも高い場合、複数の前記第1の画像データと、複数の前記第2の画像データとを合成した合成画像データを生成する生成部と、を備える。 In one aspect of the present invention, the image processing apparatus has a first image data generated by the image pickup operation of the image pickup unit under the first exposure condition and an exposure time shorter than the exposure time under the first exposure condition. When the sensitivity of the input unit to which the second image data generated by the image pickup operation of the image pickup unit under the second exposure condition is input and the sensitivity of the image pickup unit is lower than a predetermined value, the first image data And a composite image data obtained by synthesizing the plurality of the second image data, and when the sensitivity of the imaging unit is higher than the predetermined value, the plurality of the first image data and the plurality of the second image data are generated. It is provided with a generation unit for generating a composite image data obtained by synthesizing the image data of the above.

前記生成部は、前記撮像部の感度が所定値よりも低い場合に合成する前記第2の画像データの数を、前記撮像部の感度が低いほど多くしてもよい。 The generation unit may increase the number of the second image data to be synthesized when the sensitivity of the image pickup unit is lower than a predetermined value, as the sensitivity of the image pickup unit is lower.

本発明では、本処理用画像データのうちの最も露光量が低い露光条件で撮像した画像データを、複数回撮像して得た前処理用画像データを合成して作るので、ランダムノイズを確実に軽減することができる。 In the present invention, the image data captured under the exposure condition with the lowest exposure amount among the image data for the present processing is combined with the preprocessing image data obtained by imaging the image data a plurality of times, so that random noise is surely generated. Can be mitigated.

本発明を用いた電子カメラの電気的概略を示すブロック図である。It is a block diagram which shows the electrical outline of the electronic camera which used this invention. 画像処理回路の詳しい構成を示すブロック図である。It is a block diagram which shows the detailed structure of an image processing circuit. 位置合わせ処理の構成を示すブロック部である。It is a block part which shows the structure of the alignment process. 合成撮影モードの動作手順を示すフローチャートである。It is a flowchart which shows the operation procedure of the composite shooting mode. 高感度時の動作手順を示すフローチャート図である。It is a flowchart which shows the operation procedure at the time of high sensitivity. 図5で説明した動作手順の続きを示すフローチャート図である。It is a flowchart which shows the continuation of the operation procedure described with FIG. 低感度の範囲における短時間露光画像データの取得枚数を変えた例を示す説明図である。It is explanatory drawing which shows the example which changed the acquisition number of short-time exposure image data in a low-sensitivity range. 高感度の範囲における短時間露光、標準露光、及び長時間露光との各画像データの取得枚数をそれぞれ変えた例を示す説明図である。It is explanatory drawing which shows the example which changed the acquisition number of each image data for short time exposure, standard exposure, and long time exposure in the range of high sensitivity.

本発明の画像処理装置の一実施形態として電子カメラを説明する。電子カメラは、1回のシャッタレリーズに応答して、撮像素子により異なる露光量で撮像して得た複数枚の画像データを合成して1枚の広ダイナミックレンジ画像データを生成する合成撮影モードを有する。 An electronic camera will be described as an embodiment of the image processing apparatus of the present invention. The electronic camera has a composite shooting mode in which a single wide dynamic range image data is generated by synthesizing a plurality of image data obtained by imaging with different exposure amounts by an image sensor in response to one shutter release. Have.

電子カメラ10は、図1に示すうに、レンズ光学系11、絞り12,メカシャッタ13、撮像素子14、AFETG(アナログフロントエンド・タイミングジェネレータ)15、レンズ駆動部16、絞り駆動部17、シャッタ駆動部18、AE・AF回路19、制御部20、操作部21、LCD22、画像処理回路23、RAM24、ROM25、VRAM26、不揮発性メモリ27、メモリスロット28、及び外部メモリ29等で構成される。 As shown in FIG. 1, the electronic camera 10 includes a lens optical system 11, an aperture 12, a mechanical shutter 13, an image sensor 14, an AFETG (analog front-end timing generator) 15, a lens drive unit 16, an aperture drive unit 17, and a shutter drive unit. It is composed of 18, an AE / AF circuit 19, a control unit 20, an operation unit 21, an LCD 22, an image processing circuit 23, a RAM 24, a ROM 25, a VRAM 26, a non-volatile memory 27, a memory slot 28, an external memory 29, and the like.

レンズ駆動部16は、レンズ光学系11の変倍及び合焦動作を行う。絞り駆動部17は、絞り12を駆動する。シャッタ駆動部18は、メカシャッタ13を駆動する。撮像素子14は、レンズ光学系11、及び絞り12を介して結像される被写体像を光電変換するCCDやCMOS等のイメージセンサである。 The lens driving unit 16 performs scaling and focusing operations of the lens optical system 11. The aperture drive unit 17 drives the aperture 12. The shutter drive unit 18 drives the mechanical shutter 13. The image sensor 14 is an image sensor such as a CCD or CMOS that photoelectrically converts a subject image imaged via the lens optical system 11 and the diaphragm 12.

AFETG15は、TG(タイミングジェネレータ)30、V-driver(垂直駆動部)31、及びAFE(アナログフロントエンド)32で構成される。 The AFETG15 is composed of a TG (timing generator) 30, a V-driver (vertical drive unit) 31, and an AFE (analog front end) 32.

TG30は、V-driver31を介して画像信号の読み出しタイミングを撮像素子14に与える。AFE32は、撮像素子14から読み出されるアナログの画像信号のノイズ除去やアナログゲインアップにより増幅を行った後、A/D変換してデジタルの画像データに変換し、変換した画像データをAE・AF回路19と画像処理回路23に出力する。 The TG 30 gives the image pickup device 14 the read timing of the image signal via the V-drive 31. The AFE 32 amplifies the analog image signal read from the image sensor 14 by removing noise and increasing the analog gain, and then performs A / D conversion to convert it into digital image data, and the converted image data is converted into an AE / AF circuit. It is output to 19 and the image processing circuit 23.

AE・AF回路19は、画像データのコントラスト情報に基づいてフォーカスを制御するAF(オートフォーカス)情報、及び画像データに基づいて最適なAE(オートエクスポージャ)情報やホワイトバランス情報をそれぞれ取り出して制御部20に送る。制御部20は、AF情報、AE情報、及びホワイトバランス情報に基づいてレンズ駆動部16、絞り駆動部17、及び画像処理回路23等を制御する。 The AE / AF circuit 19 extracts and controls AF (autofocus) information that controls focus based on contrast information of image data, and optimal AE (autoexposure) information and white balance information based on image data. Send to department 20. The control unit 20 controls the lens drive unit 16, the aperture drive unit 17, the image processing circuit 23, and the like based on the AF information, the AE information, and the white balance information.

画像処理回路23は、ホワイトバランス処理、圧縮符号化、復号処理、画像合成処理等が含まれる。VRAM26は、LCD22に表示するための画像メモリである。LCD22には、撮像された画像の表示、カメラの各種設定のメニューや撮影モードの表示が行われる。 The image processing circuit 23 includes white balance processing, compression coding, decoding processing, image composition processing, and the like. The VRAM 26 is an image memory for displaying on the LCD 22. The LCD 22 displays the captured image, menus for various settings of the camera, and a shooting mode.

メモリスロット28には、外部メモリ29が着脱自在に接続される。外部メモリ29には、画像処理回路23で生成される圧縮符号化された画像データが保存される。 An external memory 29 is detachably connected to the memory slot 28. The compression-encoded image data generated by the image processing circuit 23 is stored in the external memory 29.

RAM24は、制御部20や画像処理回路23のワークエリアとして使用される。ROM25には、制御部20が実行するプログラムが格納されている。不揮発性メモリ27は、電子カメラ10の各種の調整データや、ユーザによって設定された撮影モードや感度(ISO感度)等を格納する。 The RAM 24 is used as a work area for the control unit 20 and the image processing circuit 23. The ROM 25 stores a program executed by the control unit 20. The non-volatile memory 27 stores various adjustment data of the electronic camera 10, a shooting mode set by the user, a sensitivity (ISO sensitivity), and the like.

制御部20は、ROM25に記憶されているプログラムに従って動作するCPU(中央演算処理部)を中心に構成され、電子カメラ10の各部を制御する。例えば、制御部20は、撮像素子14の画像信号を読み出す指示をAFETG15のTG30に与え、撮像素子14から読み出した画像信号を、AFE32を介して画像処理回路23に入力し、画像処理回路23でその時点の撮影モードに対応する処理等を実行した後に、処理済みの画像データを、バス33を介して外部メモリ29に記録するように制御する。 The control unit 20 is configured around a CPU (central processing unit) that operates according to a program stored in the ROM 25, and controls each unit of the electronic camera 10. For example, the control unit 20 gives an instruction to read the image signal of the image sensor 14 to the TG 30 of the AFET G15, inputs the image signal read from the image sensor 14 to the image processing circuit 23 via the AFE 32, and causes the image processing circuit 23 to read the image signal. After executing the processing corresponding to the shooting mode at that time, the processed image data is controlled to be recorded in the external memory 29 via the bus 33.

操作部21は、感度設定部、モード設定部、シャッタボタン、及び電源ボタン等で構成されており、これらは制御部20に操作信号や設定信号を送る。感度設定部は、撮像素子14の感度(ISO感度)を複数段階に変更するための操作部である。感度は、予め任意の感度に定められている。 The operation unit 21 includes a sensitivity setting unit, a mode setting unit, a shutter button, a power button, and the like, and these send an operation signal and a setting signal to the control unit 20. The sensitivity setting unit is an operation unit for changing the sensitivity (ISO sensitivity) of the image pickup device 14 in a plurality of stages. The sensitivity is predetermined to be arbitrary.

制御部20は、AE・AF回路19から被写体輝度情報を得ると、感度と被写体輝度とで決まる適正露出に近づくように、その時点に設定されている感度に対応したプログラム線図に従って標準の露光量(絞り値とシャッター速度値で求まる露光量)を決定する。 When the control unit 20 obtains the subject brightness information from the AE / AF circuit 19, the control unit 20 obtains the standard exposure according to the program diagram corresponding to the sensitivity set at that time so as to approach the appropriate exposure determined by the sensitivity and the subject brightness. Determine the amount (exposure amount obtained by the aperture value and shutter speed value).

モード設定部は、合成撮影モード、通常撮影モード、及び再生モードのうちのいずれか一つを択一的に選択する操作部である。合成撮影モードは、撮像素子14により同一被写体を、異なる露光量で撮像して生成した複数枚の本処理用画像データを合成して1枚の広ダイナミックレンジ画像データを得るモードである。 The mode setting unit is an operation unit that selectively selects any one of the composite shooting mode, the normal shooting mode, and the reproduction mode. The composite shooting mode is a mode in which a plurality of images for this processing generated by imaging the same subject with different exposure amounts by the image sensor 14 are combined to obtain one wide dynamic range image data.

合成撮影モードの時には、撮像素子14の蓄積時間を可変する電子シャッタと絞り12の組み合わせで露光量を制御する。なお、シャッタ速度としては、電子シャッタの代わりに、例えばメカシャッタ13の開閉で決定してもよいし、露光の最初のタイミングを電子シャッタで取り、露光終了をメカシャッタ13で決定してもよい。 In the composite shooting mode, the exposure amount is controlled by the combination of the electronic shutter and the aperture 12 that change the accumulation time of the image sensor 14. The shutter speed may be determined by, for example, opening and closing the mechanical shutter 13 instead of the electronic shutter, or the first timing of exposure may be determined by the electronic shutter and the end of exposure may be determined by the mechanical shutter 13.

通常撮影モードは、標準の露出量で撮像素子14により1回撮像して1枚の画像データを生成するモードである。再生モードは、外部メモリ29に記録した画像データをLCD22に再生するモードである。 The normal shooting mode is a mode in which a single image data is generated by taking an image once with the image sensor 14 with a standard exposure amount. The reproduction mode is a mode in which the image data recorded in the external memory 29 is reproduced on the LCD 22.

制御部20は、図2に示すように、感度判定部35、及びカウンタ36を有する。感度判定部35は、撮影時に感度設定部に設定されている設定感度を認識するとともに、認識した感度を予め決められている閾値とを比較して高感度か低感度かを判定する。カウンタ36は、画像データの取り込み回数をカウントする。制御部20は、感度判定部35で判定した感度に応じて、アナログの画像データをAFE32のアナログゲインアップで増幅するときの度合いを変更する。 As shown in FIG. 2, the control unit 20 includes a sensitivity determination unit 35 and a counter 36. The sensitivity determination unit 35 recognizes the set sensitivity set in the sensitivity setting unit at the time of shooting, and compares the recognized sensitivity with a predetermined threshold value to determine whether the sensitivity is high or low. The counter 36 counts the number of times the image data is captured. The control unit 20 changes the degree of amplification of the analog image data by increasing the analog gain of the AFE 32 according to the sensitivity determined by the sensitivity determination unit 35.

画像処理回路23は、振分け部37、前処理合成部38、及び本処理合成部39を備えている。振分け部37は、画像データを前処理合成部38と本処理合成部39に振り分けるものであり、この振り分け処理は、高感度又は低感度の時の前処理用の画像データか本処理用の画像データかに基づいて制御部20により制御される。 The image processing circuit 23 includes a distribution unit 37, a pre-processing synthesis unit 38, and a main processing composition unit 39. The distribution unit 37 distributes the image data to the pre-processing synthesis unit 38 and the main processing synthesis unit 39, and this distribution processing is the image data for pre-processing or the image for main processing at the time of high sensitivity or low sensitivity. It is controlled by the control unit 20 based on the data.

本処理合成部39は、合成撮影モードの時に、異なる露光量で撮像した複数枚の本処理用画像データを合成して1枚の広ダイナミックレンジ画像データを生成する処理を行う。本処理用画像データは、例えば、短時間露光画像データ、標準露光画像データ、及び長時間露光画像データで構成されている。短時間露光画像データは、撮像素子14により標準より少ない露光量で撮像して生成した画像データである。標準露光画像データは、撮像素子14により標準の露光量で撮像して生成した画像データである。長時間露光画像データは、撮像素子14により標準よりも多い露光量で撮像して生成した画像データである。 The processing synthesis unit 39 performs processing to generate one wide dynamic range image data by synthesizing a plurality of images for this processing captured at different exposure amounts in the composite shooting mode. The image data for this processing is composed of, for example, short-time exposure image data, standard exposure image data, and long-time exposure image data. The short-time exposure image data is image data generated by taking an image with an image sensor 14 with an exposure amount smaller than the standard. The standard exposure image data is image data generated by taking an image with a standard exposure amount by the image sensor 14. The long-time exposure image data is image data generated by taking an image with an image pickup element 14 with an exposure amount larger than the standard.

前処理合成部38は、合成撮影モードの時に低感度と判定した場合、ランダムノイズを軽減するために、撮像素子14により標準よりも少ない露光量で撮像して生成した複数枚の前処理用画像データを合成して1枚のノイズ軽減用画像データを生成し、ノイズ軽減用画像データを本処理用画像データのうちの短時間露光画像データとして本処理合成部39に出力する。 When the pre-processing compositing unit 38 determines that the sensitivity is low in the compositing shooting mode, a plurality of pre-processing images generated by taking an image with an image pickup element 14 with an exposure amount smaller than the standard in order to reduce random noise. The data is combined to generate one noise reduction image data, and the noise reduction image data is output to the processing synthesis unit 39 as short-time exposure image data among the processing image data.

また、前処理合成部38は、合成撮影モードの時に高感度と判定した場合、撮像素子14により標準よりも少ない露光量で撮像して生成した複数枚の画像データを1枚の画像データに合成したものを短時間露光画像データとし、また、標準の露光量で撮像して生成した複数枚の画像データを1枚の画像データに合成したものを標準露光画像データとし、さらに、標準よりも多い露光量で撮像して生成した複数枚の画像データを1枚の画像データに合成したものを長時間露光画像データとしてそれぞれ本処理合成部39に出力する。 Further, when the preprocessing and synthesizing unit 38 determines that the sensitivity is high in the composite shooting mode, the preprocessing and synthesizing unit 38 combines a plurality of image data generated by taking an image with an exposure amount smaller than the standard by the image pickup element 14 into one image data. The short-time exposure image data is used as the short-time exposure image data, and the standard exposure image data is obtained by synthesizing a plurality of image data generated by imaging with a standard exposure amount into one image data, which is more than the standard. A combination of a plurality of image data generated by imaging with an exposure amount into one image data is output to the processing and synthesizing unit 39 as long-time exposure image data.

前処理及び本処理合成部38,39は、バッファメモリ40,44、位置合わせ処理41,45、及び画像合成43,47をそれぞれ備えている。バッファメモリ40,44は、複数の画像データを一時的に記憶する。位置合わせ処理41,45は、各画像データを比較して、各画像データの位置が一致するように座標を修正する処理を行う。画像合成43,47は、修正した座標の情報に基づいて各画像データを加算した後に、画像データの枚数で除算する平均化処理を行って1枚の画像データを生成する。 The pre-processing and main processing synthesis units 38 and 39 include buffer memories 40 and 44, alignment processing 41 and 45, and image composition 43 and 47, respectively. The buffer memories 40 and 44 temporarily store a plurality of image data. The alignment processes 41 and 45 compare the image data and correct the coordinates so that the positions of the image data match. In the image composition 43 and 47, after adding each image data based on the corrected coordinate information, an averaging process of dividing by the number of image data is performed to generate one image data.

位置合わせ処理41,45は、図3に示すように、評価部48、決定部49、及び位置合わせ部50で構成されている。評価部48は、所定の条件、例えば画像データのレベル(明るさ)、コントラスト、及び空間周波数の高周波成分とのうちの少なくとも1つを求めて各画像データを評価する。この場合、画像データの白黒レベルが飽和レベルに達していない画像データのうちの最も明るい画像データほど、又は最もコントラスト値が高い画像データほど、あるいは最も高周波成分が多い画像データほど評価値を高くする。 As shown in FIG. 3, the alignment processes 41 and 45 are composed of an evaluation unit 48, a determination unit 49, and an alignment unit 50. The evaluation unit 48 evaluates each image data by obtaining at least one of predetermined conditions, for example, the level (brightness) of the image data, the contrast, and the high frequency component of the spatial frequency. In this case, the brightest image data among the image data whose black-and-white level of the image data has not reached the saturation level, the image data having the highest contrast value, or the image data having the highest high-frequency component has a higher evaluation value. ..

なお、代わりに、各画像データから主要被写体を検出し、検出した主要被写体の動き量が小さい程評価値を高くする条件や、フォーカス状態、主要被写体の変形度合い等の評価で基準の画像データを決めても良い。 Instead, the main subject is detected from each image data, and the standard image data is used for evaluation such as the condition that the evaluation value is higher as the amount of movement of the detected main subject is smaller, the focus state, and the degree of deformation of the main subject. You may decide.

決定部49は、評価部48で求めた各画像データの評価値に基づいて最も合成に適した画像データを基準画像データとして決定する。位置合わせ部50は、基準画像データを基準として残りの画像データに対して座標位置が一致するように位置合わせ処理を行う。これにより、画像合成43,47で合成される画像データは、画質が向上する。なお、評価部48で、各画像データの評価をした後に、評価値が予め決めた閾値よりも低い場合には、その画像データを合成に使用しないように選択する処理を行うようにしてもよい。 The determination unit 49 determines the image data most suitable for composition as the reference image data based on the evaluation value of each image data obtained by the evaluation unit 48. The alignment unit 50 performs alignment processing so that the coordinate positions match the remaining image data with reference to the reference image data. As a result, the image quality of the image data synthesized by the image synthesis 43 and 47 is improved. After evaluating each image data, the evaluation unit 48 may perform a process of selecting not to use the image data for compositing if the evaluation value is lower than a predetermined threshold value. ..

次に上記構成の作用を、図4を参照しながら説明する。撮像素子14の感度は、初期値、例えばISO感度「400」に予め設定されている。撮影者は、広ダイナミックレンジ画像を撮影する場合には、合成撮影モードを選択する。 Next, the operation of the above configuration will be described with reference to FIG. The sensitivity of the image sensor 14 is preset to an initial value, for example, the ISO sensitivity "400". The photographer selects a composite shooting mode when shooting a wide dynamic range image.

制御部20は、1回のシャッタレリーズに応答して、その時点の標準露光量を決定し(S-1)、また、その時点の撮影モードを確認し(S-2)、さらに、合成撮影モードの場合には、その時点で設定されている感度が閾値未満か否かを判定する(S-3)。例えば、設定感度がISO感度「50」で、閾値がISO感度「600」である場合には設定感度が低感度であると判定する。 The control unit 20 determines the standard exposure amount at that time in response to one shutter release (S-1), confirms the shooting mode at that time (S-2), and further performs composite shooting. In the case of the mode, it is determined whether or not the sensitivity set at that time is less than the threshold value (S-3). For example, when the set sensitivity is ISO sensitivity "50" and the threshold value is ISO sensitivity "600", it is determined that the set sensitivity is low.

制御部20は、低感度と判定した場合、標準より少ない露光量、例えば「-1EV」の露光補正をした露光量に設定して撮像素子14で連写的に撮像することで複数枚、例えば5枚の前処理用画像データを取得し(S-4)、振分け部37を制御して5枚の前処理用画像データを前処理合成部38のバッファメモリ40に取り込む。 When the control unit 20 determines that the sensitivity is low, the control unit 20 sets an exposure amount smaller than the standard, for example, an exposure amount corrected for exposure of "-1EV", and continuously shoots images with the image sensor 14, for example. The five pre-processing image data are acquired (S-4), and the distribution unit 37 is controlled to take the five pre-processing image data into the buffer memory 40 of the pre-processing synthesis unit 38.

前処理合成部38は、制御部20からカウントアップに応答する信号を受け取ることで、バッファメモリ40から5枚の前処理用画像データを順に読み出し、各前処理用画像データについて評価部48で予め決めた条件に基づいて評価を行い、評価結果に基づいて基準の画像データを決定部49で決定し(S-5)、位置合わせ部50で基準の画像データに基づいて残りの画像データに対して位置合わせ処理を行い(S-6)、その後に画像合成43で、基準画像データに対して位置合わせ処理済みの画像データを順に加算平均化処理により合成をして本処理用の短時間露光画像データを生成し(S-7)、短時間露光画像データを本処理合成部39のバッファメモリ44に出力する。 By receiving a signal in response to the count-up from the control unit 20, the preprocessing synthesis unit 38 reads out five preprocessing image data in order from the buffer memory 40, and the evaluation unit 48 preliminarily reads each preprocessing image data. Evaluation is performed based on the determined conditions, the reference image data is determined by the determination unit 49 based on the evaluation result (S-5), and the alignment unit 50 determines the remaining image data based on the reference image data. After the alignment process (S-6), the image data that has been aligned with the reference image data is combined in order by the addition averaging process in the image composition 43, and the short-time exposure for this process is performed. Image data is generated (S-7), and the short-time exposure image data is output to the buffer memory 44 of the processing synthesis unit 39.

なお、5枚の前処理用画像データを取得する時には、制御部20は、カウンタ36を初期化し(S-8)、カウンタ36で短時間露光での撮像回数をカウントし(S-9)、その撮像回数が予め決められた回数に達したか否かを判定する(S-10)。 When acquiring the five preprocessing image data, the control unit 20 initializes the counter 36 (S-8), and the counter 36 counts the number of times of imaging in a short exposure (S-9). It is determined whether or not the number of times of imaging has reached a predetermined number of times (S-10).

引き続き制御部20は、標準の露光量に変えて1枚撮像して本処理用の標準露光画像データを生成し(S-11)、振分け部37を制御して標準露光画像データを本処理合成部39のバッファメモリ44に取り込み、引き続き、標準より多い露光量、例えば「+1EV」の露光補正をした露光量に設定して1枚撮像して本処理用の長時間露光画像データを生成し(S-12)、長時間露光画像データをバッファメモリ44に取り込む。 Subsequently, the control unit 20 changes the exposure amount to a standard exposure amount and captures one image to generate standard exposure image data for this processing (S-11), and controls the distribution unit 37 to synthesize the standard exposure image data in this processing. The data is taken into the buffer memory 44 of the unit 39, and subsequently, the exposure amount is set to a larger exposure amount than the standard, for example, the exposure amount is adjusted to "+1 EV", and one image is taken to generate long-exposure image data for this processing ( S-12), the long exposure image data is taken into the buffer memory 44.

本処理合成部39は、短時間露光画像データ、標準露光画像データ、及び長時間露光画像データとの3つの本処理用画像データがバッファメモリ44に取り込まれることに応答して、位置合わせ処理45で前述した位置合わせ処理41と同じ処理を行って基準の画像データを決定し(S-13)、基準の画像データに対して残りの画像データについてそれぞれ位置合わせ処理を行って(S-14)、基準の画像データに対して位置合わせ処理済みの画像データを加算平均化処理により順に合成をして広ダイナミックレンジ画像データを生成し(S-15)、広ダイナミックレンジ画像データを外部メモリ29に記録する。低感度判定での合成撮影モードで得られる広ダイナミックレンジ画像は、白とびや黒つぶれの発生を抑えることに加えて、低感度撮影で生じ易いランダムノイズを低減した画像になる。 The processing synthesis unit 39 responds to the three image data for the present processing, that is, the short-time exposure image data, the standard exposure image data, and the long-time exposure image data, being taken into the buffer memory 44, and the alignment processing 45 The same process as the alignment process 41 described above is performed to determine the reference image data (S-13), and the remaining image data is aligned with respect to the reference image data (S-14). , Image data that has been aligned with respect to the reference image data is combined in order by addition averaging processing to generate wide dynamic range image data (S-15), and the wide dynamic range image data is stored in the external memory 29. Record. The wide dynamic range image obtained in the composite shooting mode in the low-sensitivity determination is an image in which the random noise that tends to occur in the low-sensitivity shooting is reduced in addition to suppressing the occurrence of overexposure and underexposure.

次に、感度判定部35が図4(S―3)の判定において例えば設定感度がISO[800]の場合、設定感度が閾値を超えるため、高感度であると判定する。この場合、図5に示すように、制御部20は、標準より少ない露光量、例えば「-1EV」の露光補正をした露光量に設定して撮像素子14で連写的に撮像することで複数枚、例えば6枚の前処理用画像データを取得し(S-16)、振分け部37を制御して6枚の前処理用画像データを前処理合成部38のバッファメモリ40に取り込む。 Next, in the determination of FIG. 4 (S-3), the sensitivity determination unit 35 determines that the set sensitivity is high because the set sensitivity exceeds the threshold value, for example, when the set sensitivity is ISO [800]. In this case, as shown in FIG. 5, a plurality of control units 20 are set to an exposure amount smaller than the standard, for example, an exposure amount corrected for exposure of "-1EV", and continuously imaged by the image sensor 14. The image data for preprocessing, for example, 6 images is acquired (S-16), and the distribution unit 37 is controlled to take in the image data for preprocessing of 6 images into the buffer memory 40 of the preprocessing synthesis unit 38.

前処理合成部38は、制御部20から短時間露光での撮影回数がカウントアップすることに応答して、バッファメモリ40から6枚の前処理用画像データを順に読み出し、前述した同じ処理を位置合わせ処理41、及び画像合成43で行って(S-17)、本処理用の短時間露光画像データを生成し(S-18)、短時間露光画像データを本処理合成部39のバッファメモリ44に出力する。 The pre-processing synthesis unit 38 reads out six pre-processing image data in order from the buffer memory 40 in response to the count-up of the number of shots taken in the short-time exposure from the control unit 20, and positions the same processing described above. Performed by the matching process 41 and the image composition 43 (S-17), the short-time exposure image data for the main process is generated (S-18), and the short-time exposure image data is stored in the buffer memory 44 of the main process synthesis unit 39. Output to.

引き続き制御部20は、標準の露光量に設定して撮像素子14で連写的に撮像することで、短時間露光で撮像する枚数よりも少ない複数枚、例えば4枚の前処理用画像データを取得し(S-19)、振分け部37を制御して4枚の前処理用画像データを前処理合成部38のバッファメモリ40に取り込む。 Subsequently, the control unit 20 sets the standard exposure amount and continuously shoots images with the image sensor 14, so that a plurality of images, for example, four images for preprocessing, which are smaller than the number of images captured by the short exposure, are captured. Acquired (S-19), the distribution unit 37 is controlled, and the four pre-processing image data are taken into the buffer memory 40 of the pre-processing synthesis unit 38.

前処理合成部38は、制御部20から標準露光での撮影回数がカウントアップすることに応答して、バッファメモリ40から4枚の前処理用画像データを順に読み出し、前述した同じ処理を位置合わせ処理41、及び画像合成43で行って(S-20)、本処理用の標準露光画像データを生成し(S-21)、標準露光画像データを本処理合成部39のバッファメモリ44に出力する。 The preprocessing synthesis unit 38 reads out four preprocessing image data in order from the buffer memory 40 in response to the count-up of the number of shots taken in the standard exposure from the control unit 20, and aligns the same processing described above. Performed in the process 41 and the image composition 43 (S-20), the standard exposure image data for this process is generated (S-21), and the standard exposure image data is output to the buffer memory 44 of the process synthesis unit 39. ..

引き続き制御部20は、図6に示すように、標準よりも多い露光量、例えば「+1EV」の露出補正をした露光量に設定して撮像素子14で連写的に撮像することで、標準露光で撮像する枚数よりも少ない複数枚、例えば2枚の前処理用画像データを取得し(S-22)、振分け部37を制御して2枚の前処理用画像データを前処理合成部38のバッファメモリ40に取り込む。 Subsequently, as shown in FIG. 6, the control unit 20 sets an exposure amount higher than the standard, for example, an exposure amount with an exposure compensation of "+1 EV", and continuously takes an image with the image sensor 14, thereby performing standard exposure. Acquires a plurality of images for preprocessing, for example, two images for preprocessing (S-22), which is smaller than the number of images captured by It is taken into the buffer memory 40.

前処理合成部38は、制御部20から標準露光での撮影回数がカウントアップすることに応答して、バッファメモリ40から2枚の前処理用画像データを順に読み出し、前述した同じ処理を位置合わせ処理41、及び画像合成43で行って(S-23)、本処理用の長時間露光画像データを生成し(S-24)、長時間露光画像データを本処理合成部39のバッファメモリ44に出力する。 The preprocessing synthesis unit 38 reads out two preprocessing image data in order from the buffer memory 40 in response to the count-up of the number of shots taken in the standard exposure from the control unit 20, and aligns the same processing described above. The process 41 and the image composition 43 are performed (S-23) to generate the long-exposure image data for the main process (S-24), and the long-exposure image data is transferred to the buffer memory 44 of the process synthesis unit 39. Output.

そして、図4(S-13~S-15)で説明したように、本処理合成部39は、3つの本処理用画像データがバッファメモリ44に取り込まれることに応答して、位置合わせ処理45で基準の画像データを決定し(S-25)、基準の画像データに対して残りの画像データについてそれぞれ位置合わせ処理を行って(S-26)、基準の画像データに対して位置合わせ処理済みの画像データを加算平均化処理により順に合成をして広ダイナミックレンジ画像データを生成し(S-27)、広ダイナミックレンジ画像データを外部メモリ29に記録する。高感度判定で生成した広ダイナミックレンジ画像は、白とびや黒つぶれの発生を抑えることに加えて、高感度撮影時に生じ易いランダムノイズを低減した画像になる。 Then, as described with reference to FIGS. 4 (S-13 to S-15), the processing synthesis unit 39 responds to the three image data for the processing being taken into the buffer memory 44, and the alignment processing 45 Determines the reference image data in (S-25), aligns the remaining image data with respect to the reference image data (S-26), and aligns the reference image data. The image data of the above is combined in order by the addition averaging process to generate a wide dynamic range image data (S-27), and the wide dynamic range image data is recorded in the external memory 29. The wide dynamic range image generated by the high-sensitivity determination is an image in which the random noise that tends to occur during high-sensitivity shooting is reduced in addition to suppressing the occurrence of overexposure and underexposure.

なお、制御部20は、広ダイナミックレンジ画像データを記録した後に、バッファメモリ40,44をクリアする制御を行うことが望ましい。 It is desirable that the control unit 20 controls to clear the buffer memories 40 and 44 after recording the wide dynamic range image data.

また、上記実施形態では、感度に応じて決められた撮影枚数、露出補正値は、前述した数値に限らないことはいうまでもない。例えば図7に示すように、設定感度が閾値未満の範囲において、設定感度が低感度程、短時間露光画像データの取得枚数を増やすのが好適である。また、例えば図8に示すように、設定感度が閾値を超える範囲において設定感度が高感度程、短時間露光、標準露光、及び長時間露光との各画像データの取得枚数をそれぞれ増やすのが好適である。なお、短時間露光、標準露光、及び長時間露光との各画像データの取得枚数を順にA、B、Cとすると、A>B>Cの関係を保つように、各画像データの取得枚数を変更するのが好適である。 Further, in the above embodiment, it goes without saying that the number of shots and the exposure compensation value determined according to the sensitivity are not limited to the above-mentioned numerical values. For example, as shown in FIG. 7, in the range where the set sensitivity is less than the threshold value, it is preferable to increase the number of acquired short-time exposure image data as the set sensitivity is lower. Further, for example, as shown in FIG. 8, it is preferable to increase the number of acquired image data for each of the short exposure, the standard exposure, and the long exposure as the set sensitivity becomes higher in the range where the set sensitivity exceeds the threshold value. Is. Assuming that the number of acquired image data for short-time exposure, standard exposure, and long-time exposure is A, B, and C in order, the number of acquired image data is set so as to maintain the relationship of A> B> C. It is preferable to change it.

手動で設定する場合には、操作部にカーソルボタンやOKボタン等の変更操作部を設け、これら操作部を用いて、例えば低感度と判定した時における短時間露光での撮影枚数、及び高感度における短時間露光での撮影枚数、標準露光での撮影枚数、長時間露光での撮影枚数を各々設定すればよい。 When setting manually, a change operation unit such as a cursor button or an OK button is provided in the operation unit, and using these operation units, for example, the number of shots taken in a short exposure when it is determined to be low sensitivity, and high sensitivity. The number of shots taken with a short exposure, the number of shots with a standard exposure, and the number of shots with a long exposure may be set respectively.

上記実施形態では、短時間露光、標準露光、及び長時間露光との3つの画像データを合成して広ダイナミックレンジ画像を生成しているが、本発明ではこれに限らず、露光の異なる2つの画像データを合成して、又は超低時間露光や超長時間露光の画像データを追加した4つ以上の画像データを合成して広ダイナミックレンジ画像を生成してもよい。 In the above embodiment, three image data of short-time exposure, standard exposure, and long-time exposure are combined to generate a wide dynamic range image, but the present invention is not limited to this, and two different exposures are generated. A wide dynamic range image may be generated by synthesizing image data or synthesizing four or more image data to which image data of ultra-low time exposure or ultra-long exposure is added.

上記実施形態では、低感度と判定した時には、最初に前処理用画像を短時間露光で複数回撮像し、次に標準露光での撮像、最後に長時間露光での撮像の順としているが、本発明ではその順に限らず、例えば逆の順、あるいは最初に標準露光での撮像し、次に短時間露光で複数回撮像、最後に長時間露光での撮像の順にしてもよい。 In the above embodiment, when it is determined that the sensitivity is low, the preprocessing image is first imaged a plurality of times with a short exposure, then with a standard exposure, and finally with a long exposure. In the present invention, the order is not limited to this, and for example, the image may be taken in the reverse order, first with standard exposure, then multiple times with short exposure, and finally with long exposure.

また、高感度と判定した時も同様に、短時間露光画像データ用の前処理用画像データを取得するために撮像する期間、標準露光画像データ用の前処理用画像データを取得するための撮像期間、及び長時間露光データ用の前処理用画像データを取得するための撮像期間の順はいずれの順でもよい。 Similarly, when it is determined that the sensitivity is high, the imaging period for acquiring the preprocessing image data for the short-time exposure image data and the imaging for acquiring the preprocessing image data for the standard exposure image data are taken. The order of the period and the imaging period for acquiring the preprocessing image data for the long exposure data may be any order.

上記実施形態では、画像データを取得する毎に位置合わせ処理をして合成しているが、先に全ての撮像を行って画像データをRAMに記録しておき、撮影完了後にRAMから合成対象の画像データを読み出して合成していくように構成してもよい。また、先に全ての撮像を行って画像データをフラッシュメモリ等に記録しておき、予め画像処理ソフトを電子カメラ等にインストールしておき、撮影後にそのソフトを実行して撮像した複数枚の画像データを合成するようにしてもよい。 In the above embodiment, the image data is aligned and synthesized every time the image data is acquired. However, all the images are first captured and the image data is recorded in the RAM, and the image data is to be synthesized from the RAM after the shooting is completed. The image data may be read out and combined. In addition, all images are first captured and image data is recorded in a flash memory or the like, image processing software is installed in an electronic camera or the like in advance, and the software is executed after shooting to capture a plurality of images. The data may be combined.

さらに、上記実施形態では本発明を電子カメラ10に使用して説明しているが、本発明ではこれに限らず、ビデオカメラやテレビカメラ等に使用することができる。 Further, although the present invention is described using the electronic camera 10 in the above embodiment, the present invention is not limited to this and can be used for a video camera, a television camera, or the like.

14 撮像素子
12 絞り
13 メカシャッタ
15 AFETG
23 画像処理回路
38 前処理合成部
39 本処理合成部
14 Image sensor 12 Aperture 13 Mechanical shutter 15 AFETG
23 Image processing circuit 38 Pre-processing synthesis unit 39 Main processing composition unit

Claims (2)

第1の露光条件による撮像部の撮像動作により生成された第1の画像データと、前記第1の露光条件による露光時間よりも短い露光時間である第2の露光条件による前記撮像部の撮像動作により生成された第2の画像データと、が入力される入力部と、
前記撮像部の感度が所定値よりも低い場合、前記第1の画像データと、複数の前記第2の画像データとを合成した合成画像データを生成し、前記撮像部の感度が前記所定値よりも高い場合、複数の前記第1の画像データと、複数の前記第2の画像データとを合成した合成画像データを生成する生成部と、
を備える画像処理装置。
The first image data generated by the imaging operation of the imaging unit under the first exposure condition and the imaging operation of the imaging unit under the second exposure condition, which is shorter than the exposure time under the first exposure condition. The second image data generated by, the input unit to which is input, and
When the sensitivity of the image pickup unit is lower than the predetermined value, a composite image data obtained by combining the first image data and a plurality of the second image data is generated, and the sensitivity of the image pickup unit is higher than the predetermined value. If it is also high, a generator that generates a composite image data obtained by synthesizing the plurality of the first image data and the plurality of the second image data, and a generation unit.
An image processing device comprising.
前記生成部は、前記撮像部の感度が所定値よりも低い場合に合成する前記第2の画像データの数を、前記撮像部の感度が低いほど多くする請求項1に記載の画像処理装置。 The image processing apparatus according to claim 1, wherein the generation unit increases the number of the second image data to be synthesized when the sensitivity of the image pickup unit is lower than a predetermined value, as the sensitivity of the image pickup unit becomes lower.
JP2020159608A 2020-09-24 2020-09-24 Image processing equipment Active JP7081635B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2020159608A JP7081635B2 (en) 2020-09-24 2020-09-24 Image processing equipment
JP2022086021A JP2022105715A (en) 2020-09-24 2022-05-26 Image processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2020159608A JP7081635B2 (en) 2020-09-24 2020-09-24 Image processing equipment

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2019084222A Division JP6769519B2 (en) 2019-04-25 2019-04-25 Imaging device

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2022086021A Division JP2022105715A (en) 2020-09-24 2022-05-26 Image processor

Publications (2)

Publication Number Publication Date
JP2021002866A JP2021002866A (en) 2021-01-07
JP7081635B2 true JP7081635B2 (en) 2022-06-07

Family

ID=73995191

Family Applications (2)

Application Number Title Priority Date Filing Date
JP2020159608A Active JP7081635B2 (en) 2020-09-24 2020-09-24 Image processing equipment
JP2022086021A Pending JP2022105715A (en) 2020-09-24 2022-05-26 Image processor

Family Applications After (1)

Application Number Title Priority Date Filing Date
JP2022086021A Pending JP2022105715A (en) 2020-09-24 2022-05-26 Image processor

Country Status (1)

Country Link
JP (2) JP7081635B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2022105715A (en) * 2020-09-24 2022-07-14 株式会社ニコン Image processor

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007049227A (en) 2005-08-05 2007-02-22 Canon Inc Image processing apparatus and method thereof
US20080253758A1 (en) 2007-04-13 2008-10-16 Choon Hwee Yap Image processing method
JP2010062785A (en) 2008-09-03 2010-03-18 Sony Corp Image processing apparatus, imaging apparatus, solid state imaging element, image processing method, and program

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7081635B2 (en) * 2020-09-24 2022-06-07 株式会社ニコン Image processing equipment

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007049227A (en) 2005-08-05 2007-02-22 Canon Inc Image processing apparatus and method thereof
US20080253758A1 (en) 2007-04-13 2008-10-16 Choon Hwee Yap Image processing method
JP2010062785A (en) 2008-09-03 2010-03-18 Sony Corp Image processing apparatus, imaging apparatus, solid state imaging element, image processing method, and program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2022105715A (en) * 2020-09-24 2022-07-14 株式会社ニコン Image processor

Also Published As

Publication number Publication date
JP2022105715A (en) 2022-07-14
JP2021002866A (en) 2021-01-07

Similar Documents

Publication Publication Date Title
JP5857444B2 (en) Imaging device
US8368771B2 (en) Generating a synthesized image from a plurality of images
JP2007060449A (en) Imaging apparatus
US7245318B2 (en) Imaging apparatus that corrects an imbalance in output levels of image data
US9277135B2 (en) Image-pickup apparatus, control method for the same, and non-transitory computer-readable storage medium
US8514323B2 (en) Imaging apparatus and imaging method
JP2013258444A (en) Image processing device, image processing method, and program
US9892497B2 (en) Image processing apparatus, imaging apparatus, and image processing method
JP2010136224A (en) Imaging apparatus and imaging method
JP2006262220A (en) Imaging apparatus
JP7081635B2 (en) Image processing equipment
JP6261397B2 (en) Imaging apparatus and control method thereof
JP6519625B2 (en) Imaging device
JP6769519B2 (en) Imaging device
JP2012239076A (en) Imaging device and method
JP3553999B2 (en) Imaging device and image processing method thereof
JP2009213032A (en) Wide dynamic range image formation processing apparatus
KR101396439B1 (en) Apparatus and method for capturing image
JP6222335B2 (en) Imaging device
JP6052379B2 (en) Imaging device
JP2015056758A (en) Imaging apparatus, its control method and control program
JP2009194728A (en) Imaging system, image processing method and image processing program
JP2001352552A (en) Video signal processing unit and video signal processing method
JP6990988B2 (en) Control method of image pickup device and image sensor
JP2014027460A (en) Imaging apparatus, camera system, control method of imaging apparatus, program and storage medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20200928

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20210714

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20210810

A601 Written request for extension of time

Free format text: JAPANESE INTERMEDIATE CODE: A601

Effective date: 20211008

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20211209

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20220426

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20220509

R150 Certificate of patent or registration of utility model

Ref document number: 7081635

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150