JP2013084067A - Image processing system, method for controlling the same, and program - Google Patents

Image processing system, method for controlling the same, and program Download PDF

Info

Publication number
JP2013084067A
JP2013084067A JP2011222346A JP2011222346A JP2013084067A JP 2013084067 A JP2013084067 A JP 2013084067A JP 2011222346 A JP2011222346 A JP 2011222346A JP 2011222346 A JP2011222346 A JP 2011222346A JP 2013084067 A JP2013084067 A JP 2013084067A
Authority
JP
Japan
Prior art keywords
image
luminance
pixel
processing
reduction
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
JP2011222346A
Other languages
Japanese (ja)
Other versions
JP5775413B2 (en
JP2013084067A5 (en
Inventor
Daisuke Wakamiya
大輔 若宮
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.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Canon Inc filed Critical Canon Inc
Priority to JP2011222346A priority Critical patent/JP5775413B2/en
Publication of JP2013084067A publication Critical patent/JP2013084067A/en
Publication of JP2013084067A5 publication Critical patent/JP2013084067A5/en
Application granted granted Critical
Publication of JP5775413B2 publication Critical patent/JP5775413B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

PROBLEM TO BE SOLVED: To perform luminance correction processing by reducing a positional deviation between a recording image and a reference image for deciding a luminance correction coefficient.SOLUTION: A recording image having a preset number of pixels is generated from an image obtained by performing reduction processing for a processing object image. Further, a luminance image having a number of pixels less than the preset number of pixels is generated by performing the reduction processing by extracting the luminance image of an area corresponding to the recording image from the processing object image. When the area corresponding to the recording image contains the under one pixel, the corresponding area is changed into the area which does not contain the under one pixel, to extract the luminance image. Enlargement processing is performed for the luminance image after the reduction processing so as to generate the reference image for deciding the luminance correction coefficient of the recording image. When the area for extracting the luminance image is changed, a gravity center of the area corresponding to each pixel of the luminance image after the reduction processing is changed to a position where the positional deviation of a subject image becomes minimum and generates the reference image based on information on the change and magnification of the corresponding area.

Description

本発明は、画像処理装置、その制御方法、及びプログラムに関し、特に画像の輝度補正を行う技術に関する。   The present invention relates to an image processing apparatus, a control method thereof, and a program, and more particularly to a technique for correcting luminance of an image.

デジタルカメラ等の撮像装置では、撮影により撮像素子より出力された画像信号に対して様々な補正処理あるいはフィルタ処理を含む現像処理を行い、補正後の画像信号を記録用の画像として出力している。補正処理及びフィルタ処理には、画像の変倍処理や色補正処理や手ぶれ補正処理、輝度補正処理等がある。   In an imaging device such as a digital camera, development processing including various correction processing or filter processing is performed on an image signal output from an imaging device by shooting, and the corrected image signal is output as a recording image. . The correction processing and filter processing include image scaling processing, color correction processing, camera shake correction processing, luminance correction processing, and the like.

近年、撮像装置の中には、輝度の高い被写体が主被写体の背後に存在する、所謂逆光シーンであっても、輝度の高い被写体と輝度の低い主被写体とを、白飛びあるいは黒潰れさせずに、ダイナミックレンジの広い画像を撮影可能なものがある。ダイナミックレンジの広い画像の生成方法の1つに、例えば輝度の低い暗部の輝度レベルを上昇させる等、画像の輝度成分に応じて輝度補正(トーンマッピング)を行うものがある。特に、輝度の低い領域の輝度補正処理は(デジタル)覆い焼き処理と呼ばれ、逆光シーンにおいて主被写体に対して覆い焼き処理を行うことで、ダイナミックレンジの広い画像を記録する事が可能である。   In recent years, even in so-called backlight scenes where a high-luminance subject exists behind the main subject in imaging devices, the high-luminance subject and the low-luminance main subject are not blown out or blacked out. In addition, there is a camera that can take an image with a wide dynamic range. One method for generating an image with a wide dynamic range is to perform luminance correction (tone mapping) in accordance with the luminance component of the image, for example, by increasing the luminance level of a dark portion with low luminance. In particular, luminance correction processing for low-luminance regions is called (digital) dodging processing, and it is possible to record an image with a wide dynamic range by performing dodging processing on the main subject in a backlight scene. .

覆い焼き処理では、記録用の画像のうち、輝度が低くかつ低周波数成分の領域に対して輝度補正を行うため、記録用の画像の輝度成分で構成される輝度画像の低周波数成分を抽出したローパス画像(参照画像)を参照し、輝度補正係数を決定する。撮像装置において参照画像の生成を安価かつ少ないリソースで実現するために、一度輝度画像を縮小して画素数を少なくした上でローパスフィルタを適用し、フィルタリング後の縮小画像を記録用の画像大に拡大する方法が用いられることがある。このような固定の縮小率を用いる変倍処理の工程を経て参照画像を生成する場合、次のような問題が生じうる。   In the dodging process, the low-frequency component of the luminance image composed of the luminance component of the recording image is extracted in order to perform luminance correction on the low-frequency and low-frequency component region of the recording image. The brightness correction coefficient is determined with reference to the low-pass image (reference image). In order to realize the generation of the reference image with low cost and low resources in the imaging device, the luminance image is reduced once to reduce the number of pixels, and then the low-pass filter is applied, and the reduced image after filtering is made large for recording. An enlargement method may be used. When the reference image is generated through the scaling process using such a fixed reduction ratio, the following problem may occur.

記録用の画像は、撮像装置の設定により様々な画素数及びアスペクト比で記録可能であるため、記録用の画像の画素数によっては固定の縮小率で縮小処理した場合に、計算上、縮小後のライン数が整数値にならない場合がある。画像データの構造上、単位画素について画素値の情報が保持されるため縮小後に整数値とならない端数のラインに対応する、1画素未満の情報については縮小処理時に失われることになる。このようにして得られた縮小後の画像に対しての拡大処理を経て生成された参照画像は、記録用の画像と同サイズに拡大されたとしても、縮小処理時に失われた情報があるため、参照画像と記録用の画像とで画素ごとの対応がとれていないことになる。即ち、このような参照画像を参照して決定された輝度補正係数で覆い焼き処理を行った場合、好適な補正結果が得られなかった。   Since the image for recording can be recorded with various pixel numbers and aspect ratios depending on the settings of the image pickup device, depending on the number of pixels of the image for recording, when it is reduced at a fixed reduction ratio, it is calculated and reduced. The number of lines may not be an integer value. Because of the structure of the image data, pixel value information is held for the unit pixel, information less than one pixel corresponding to a fractional line that does not become an integer value after reduction is lost during the reduction process. Since the reference image generated through the enlargement process on the reduced image obtained in this way is enlarged to the same size as the recording image, there is information lost during the reduction process. Therefore, the reference image and the recording image are not matched for each pixel. That is, when the dodging process is performed with the luminance correction coefficient determined with reference to such a reference image, a suitable correction result cannot be obtained.

特許文献1には、縮小処理において変換できない端数の領域が存在する場合に、該領域を排除せずに画素として縮小処理し、拡大時に記録用の画像より多くなった余剰画素を除外することで、記録用の画像と同サイズの参照画像を生成することが開示されている。   In Patent Document 1, when there is a fractional area that cannot be converted in the reduction process, the reduction process is performed as a pixel without excluding the area, and excess pixels that are larger than the recording image at the time of enlargement are excluded. It is disclosed that a reference image having the same size as a recording image is generated.

特開2010−21952号公報JP 2010-215192 A

しかしながら、特許文献1では記録用の画像に対して変倍処理が適用されることが考慮されていなかった。所望の画素数の画像を記録するために、撮像素子から出力された画像(原画像)に対して縮小処理を適用した後、種々のフィルタ処理を行なって記録用の画像を生成する場合、以下のような問題が生じる。   However, Patent Document 1 does not consider that scaling processing is applied to a recording image. In order to record an image with a desired number of pixels, a reduction process is applied to an image (original image) output from an image sensor, and then various filter processes are performed to generate an image for recording. The following problems arise.

例えば、撮像素子から出力された原画像が、図5(a)に示されるように800pixel×600pixelで構成される場合を考える。原画像500は、画像処理において参照されるOB(Optical Black)領域501と、被写体に対応した画素値を有する有効画素領域502とで構成されている。有効画素領域502の全体を用いて記録用の画像を生成する場合、原画像500の縮小処理後に適用されるフィルタ処理では、フィルタのタップ数に応じて縮小処理後の有効画素領域502よりも少ない画素数の画像が出力されることになる。このため、記録用の画像を所望の画素数とするためには、フィルタのタップ数を考慮して縮小処理の縮小率を決定することになる。例えばフィルタのタップ数が垂直方向及び水平方向ともに20である場合、即ち垂直方向あるいは水平方向の20画素を参照して1画素の画素値を算出する場合、180pixel×160pixelの画像を記録用の画像として生成するためには、原画像500に対して縮小率3/10の縮小処理が行われる。縮小処理の結果、原画像500は図5(b)に示されるような240pixel×180pixelの縮小画像510に変換され、該画像に対してフィルタ処理を行うことで、180pixel×160pixelの記録用の画像511が得られる。図の例では、記録用の画像511の位置は、縮小画像510の左上端を原点とする座標系において記録用の画像511の左上端の座標が(50,10)であるものとして規定されている。   For example, consider a case where the original image output from the image sensor is composed of 800 pixels × 600 pixels as shown in FIG. The original image 500 includes an OB (Optical Black) region 501 that is referred to in image processing, and an effective pixel region 502 having a pixel value corresponding to the subject. When an image for recording is generated using the entire effective pixel area 502, the filter process applied after the reduction process of the original image 500 is smaller than the effective pixel area 502 after the reduction process depending on the number of taps of the filter. An image having the number of pixels is output. Therefore, in order to make the recording image have the desired number of pixels, the reduction ratio of the reduction process is determined in consideration of the number of filter taps. For example, when the number of filter taps is 20 in both the vertical and horizontal directions, that is, when calculating the pixel value of one pixel with reference to 20 pixels in the vertical or horizontal direction, an image of 180 pixels × 160 pixels is recorded. Is generated, the original image 500 is subjected to reduction processing with a reduction ratio of 3/10. As a result of the reduction processing, the original image 500 is converted into a 240 pixel × 180 pixel reduced image 510 as shown in FIG. 5B, and the image for recording is 180 pixel × 160 pixel by performing filter processing on the image. 511 is obtained. In the example of the figure, the position of the recording image 511 is defined as the coordinate of the upper left end of the recording image 511 being (50, 10) in the coordinate system with the upper left end of the reduced image 510 as the origin. Yes.

一方、このような記録用の画像511に対する輝度補正係数決定用の参照画像は、補正効果を良好にするために原画像500から、記録用の画像511に対応する領域の輝度画像から生成されることが好ましい。原画像500において記録用の画像511に対応する領域は、図5(a)において領域503として示さる。このとき、原画像500の左上端を原点とする座標系における領域503の左上端の座標は、縮小処理における縮小率が3/10であったことから計算上、
x=50÷(3/10)=166.666・・・
y=10÷(3/10)= 33.333・・・
のように小数値となる。上述したように画像データの構造上、該座標は四捨五入等により整数値に変換される。このような変換後の座標に応じて領域503から抽出した画像を用いて参照画像を生成した場合、抽出した画像がそもそも記録用の画像と厳密に同一の被写体像を含んでいない。つまり、このような参照画像に基づいて決定された輝度補正係数で覆い焼き処理を行った場合、好適な補正結果が得られないことになる。即ち、参照画像と記録用の画像との位置ずれを修正し、画素ごとの対応がとれた参照画像を生成する必要がある。
On the other hand, a reference image for determining a luminance correction coefficient for such a recording image 511 is generated from a luminance image in an area corresponding to the recording image 511 from the original image 500 in order to improve the correction effect. It is preferable. An area corresponding to the recording image 511 in the original image 500 is shown as an area 503 in FIG. At this time, the coordinates of the upper left corner of the region 503 in the coordinate system with the upper left corner of the original image 500 as the origin are calculated as the reduction ratio in the reduction processing is 3/10.
x = 50 ÷ (3/10) = 166.666...
y = 10 ÷ (3/10) = 33.333
It becomes a decimal value like As described above, due to the structure of the image data, the coordinates are converted into integer values by rounding off. When a reference image is generated using an image extracted from the region 503 in accordance with the coordinates after such conversion, the extracted image does not include exactly the same subject image as the recording image. That is, when the dodging process is performed with the luminance correction coefficient determined based on such a reference image, a suitable correction result cannot be obtained. In other words, it is necessary to correct a positional deviation between the reference image and the recording image and generate a reference image in which correspondence for each pixel is taken.

本発明は、上述の問題点に鑑みてなされたものであり、記録用の画像と輝度補正係数決定用の参照画像間の位置ずれを低減し、好適な輝度補正処理を行う画像処理装置、その制御方法、及びプログラムを提供することを目的とする。   The present invention has been made in view of the above-described problems, and an image processing apparatus that reduces a positional deviation between a recording image and a reference image for determining a luminance correction coefficient and performs a suitable luminance correction process, It is an object to provide a control method and a program.

前述の目的を達成するために、本発明の画像処理装置は、以下の構成を備える。
処理対象の画像を取得する取得手段と、取得手段により取得された処理対象の画像に対して第1の縮小率の縮小処理を行なって得られた画像から、予め設定された画素数を有する記録用の画像を生成する生成手段と、取得手段により取得された処理対象の画像から、生成手段により生成される記録用の画像に対応する領域の輝度画像を抽出する抽出手段と、抽出手段により抽出された対応する領域の輝度画像に対して第1の縮小率とは異なる第2の縮小率の縮小処理を行い、予め設定された画素数よりも少ない画素数を有する輝度画像を生成する縮小手段と、縮小手段により生成された縮小処理後の輝度画像に対して、第1の縮小率を第2の縮小率で除した値の拡大率で拡大処理を行い、予め設定された画素数を有する、記録用の画像の輝度補正係数決定用の参照画像を生成する拡大手段と、記録用の画像の各画素について、参照画像の同一座標の画素の輝度値から決定された輝度補正係数で輝度補正を行う補正手段と、を有し、抽出手段は、対応する領域が1画素未満の画素を含む場合、対応する領域を1画素未満の画素を含まない領域に変更して対応する領域の輝度画像を抽出し、拡大手段は、抽出手段による対応する領域の変更がなされた場合に、縮小処理後の輝度画像の各画素に対応する参照画像における領域の重心を、抽出手段による対応する領域の変更の情報及び拡大率に基づいて、参照画像と記録用の画像間における被写体像の位置ずれ量が最小となる位置に変更して参照画像を生成することを特徴とする。
In order to achieve the above object, an image processing apparatus of the present invention comprises the following arrangement.
An acquisition unit that acquires an image to be processed, and a recording having a preset number of pixels from an image obtained by performing a reduction process at a first reduction ratio on the image to be processed acquired by the acquisition unit Generating means for generating an image for use, extracting means for extracting a luminance image of an area corresponding to the recording image generated by the generating means from the processing target image acquired by the acquiring means, and extracting by the extracting means A reduction unit that performs a reduction process with a second reduction ratio different from the first reduction ratio on the luminance image of the corresponding area, and generates a luminance image having a smaller number of pixels than a preset number of pixels Then, the luminance image after the reduction process generated by the reduction unit is subjected to the enlargement process at a value obtained by dividing the first reduction ratio by the second reduction ratio, and has a preset number of pixels. , Brightness of the image for recording An enlarging unit that generates a reference image for determining a positive coefficient, and a correcting unit that performs luminance correction with a luminance correction coefficient determined from the luminance value of a pixel at the same coordinate of the reference image for each pixel of the image for recording. And when the corresponding area includes pixels less than one pixel, the extraction means changes the corresponding area to an area not including pixels less than one pixel, extracts the luminance image of the corresponding area, and the enlargement means When the corresponding region is changed by the extracting unit, the center of gravity of the region in the reference image corresponding to each pixel of the luminance image after the reduction process is based on the information on the change of the corresponding region by the extracting unit and the enlargement ratio. Thus, the reference image is generated by changing the position of the subject image between the reference image and the recording image so that the amount of positional deviation is minimized.

このような構成により本発明によれば、記録用の画像と輝度補正係数決定用の参照画像間の位置ずれを低減し、好適な輝度補正処理を行うことが可能となる。   With such a configuration, according to the present invention, it is possible to reduce the positional deviation between the recording image and the reference image for determining the luminance correction coefficient, and perform a suitable luminance correction process.

本発明の実施形態に係る画像処理ユニット100の機能構成を示したブロック図1 is a block diagram showing a functional configuration of an image processing unit 100 according to an embodiment of the present invention. 本発明の実施形態に係る覆い焼きゲイン生成処理を示したフローチャートThe flowchart which showed the dodging gain production | generation process which concerns on embodiment of this invention 本発明の実施形態に係る、入力画像データ、記録用の画像データ、及び輝度補正係数決定用の輝度画像データの関係を示した図The figure which showed the relationship between the input image data, the image data for recording, and the luminance image data for determining the luminance correction coefficient according to the embodiment of the present invention 本発明の実施形態に係る、拡大処理前の画像データの画素に対応する拡大処理後の画像データにおける領域の重心を説明するための図The figure for demonstrating the gravity center of the area | region in the image data after the expansion process corresponding to the pixel of the image data before the expansion process based on embodiment of this invention 従来技術の問題点を説明するための図Illustration for explaining the problems of the prior art

[実施形態]
以下、本発明の例示的な実施形態について、図面を参照して詳細に説明する。なお、以下に説明する一実施形態は、画像処理装置の一例としての、現像画像に対して覆い焼き処理を行う画像処理ユニットを備えるデジタルカメラに、本発明を適用した例を説明する。しかし、本発明は、入力された画像に対して輝度値に応じた輝度補正処理を行うことが可能な任意の機器に適用可能である。
[Embodiment]
Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the drawings. In the following embodiment, an example in which the present invention is applied to a digital camera including an image processing unit that performs dodging processing on a developed image will be described as an example of an image processing apparatus. However, the present invention can be applied to any device capable of performing luminance correction processing according to the luminance value on the input image.

<画像処理ユニット100の構成>
図1は、本発明の実施形態に係る画像処理ユニット100の機能構成を示すブロック図である。なお、画像処理ユニット100は、本実施形態のデジタルカメラが有する不図示の制御部によって制御されるものとする。画像処理ユニット100には、該制御部の制御のもと、不図示の撮像部より撮像された入力画像データ、記録用の画像データの画素数を示す情報、及び現像処理に係る各種画像処理の補正パラメータが入力されるものとする。
<Configuration of Image Processing Unit 100>
FIG. 1 is a block diagram showing a functional configuration of an image processing unit 100 according to an embodiment of the present invention. The image processing unit 100 is controlled by a control unit (not shown) included in the digital camera of the present embodiment. In the image processing unit 100, under the control of the control unit, input image data picked up by an image pickup unit (not shown), information indicating the number of pixels of image data for recording, and various image processing related to development processing are performed. It is assumed that correction parameters are input.

信号補正部101は、入力画像データに対してシェーディング補正、黒引きノイズ補正、フリッカー補正等の所定の信号処理を行う。なお、本実施形態の入力画像データは、ベイヤ配列の撮像素子より出力されたR、G、及びB(赤、緑、及び青)の3種類のデータで構成されるカラー画像データである。入力画像データは、ベイヤ配列の撮像素子より出力された画像データであるため、単位画素についてR、G、Bのいずれかの色の画素データが一定規則で配列されている。例えば入力画像データのうち、水平方向の奇数ラインにはR、G、R、G、・・・の順で画素データが並び、偶数ラインにはG、B、G、B、・・・の順で画素データが並んでいる。信号補正部101は、所定の信号処理を行なって得られた画像データを後述する現像画像縮小部102及びウィンドウ領域算出部105に出力する。   The signal correction unit 101 performs predetermined signal processing such as shading correction, blackening noise correction, and flicker correction on the input image data. Note that the input image data of this embodiment is color image data composed of three types of data R, G, and B (red, green, and blue) output from the Bayer array image sensor. Since the input image data is image data output from the Bayer array image sensor, pixel data of any color of R, G, and B is arranged in a regular rule for the unit pixel. For example, in the input image data, pixel data is arranged in the order of R, G, R, G,... On the odd lines in the horizontal direction, and the order of G, B, G, B,. Pixel data is lined up. The signal correction unit 101 outputs image data obtained by performing predetermined signal processing to a developed image reduction unit 102 and a window area calculation unit 105 described later.

現像画像縮小部102は、入力された画像データに対して記録用の画像データの画素数に応じて縮小処理を行い、得られた画像データを現像処理部103に出力する。具体的には現像画像縮小部102は、入力された画像データのうち現像処理に必要な領域(有効画素領域)をウィンドウ処理によって切り出し、該領域の画像データに対してローパスフィルタを適用した後、間引き処理を行うことにより画像データの縮小を行う。現像画像縮小部102において適用されるローパスフィルタの係数は、例えば[1 2 1]等、縮小率に応じて折り返し歪みが生じないように設定された適切な係数が用いられる。なお、現像画像縮小部102における縮小率(第1の縮小率)は、画像処理ユニット100に入力された記録用の画像データの画素数に応じて決定される。   The developed image reduction unit 102 performs reduction processing on the input image data in accordance with the number of pixels of the recording image data, and outputs the obtained image data to the development processing unit 103. Specifically, the developed image reduction unit 102 cuts out an area (effective pixel area) necessary for the development process from the input image data by window processing, and applies a low-pass filter to the image data in the area. Image data is reduced by performing a thinning process. As a coefficient of the low-pass filter applied in the developed image reduction unit 102, an appropriate coefficient that is set so as not to cause aliasing distortion according to the reduction ratio, such as [1 2 1], is used. Note that the reduction ratio (first reduction ratio) in the developed image reduction unit 102 is determined according to the number of pixels of image data for recording input to the image processing unit 100.

現像処理部103は、現像画像縮小部102における縮小処理後のベイヤ形式の画像データに対して公知の同時化処理を行い、各画素が輝度及び色差信号の情報を有する画像データへの変換を行う。また現像処理部103は、変換した画像データに対して、ホワイトバランス調整等の所定の画像処理を画像処理ユニット100に入力された補正パラメータに基づいて実行し、補正後の画像データを後述する覆い焼き処理部104に出力する。   The development processing unit 103 performs known synchronization processing on the Bayer-format image data after the reduction processing in the development image reduction unit 102, and converts each pixel into image data having information on luminance and color difference signals. . The development processing unit 103 performs predetermined image processing such as white balance adjustment on the converted image data based on the correction parameters input to the image processing unit 100, and covers the corrected image data described later. The data is output to the baking processing unit 104.

輝度画像抽出部105は、信号補正部101において信号処理が適用されて入力された画像データのうち、輝度成分のみを抽出した輝度画像データを生成する。具体的には輝度画像抽出部105は、ベイヤ形式の画像データに対して、各色の色データから輝度値への変換処理を行う。このとき輝度値への変換に用いられる算出式は、RGB形式からYCbCr形式への変換式や、RGB形式からHSV形式への変換式等、任意の輝度値への変換式が用いられてよい。そして輝度画像抽出部105は、得られた輝度画像データをウィンドウ領域抽出部106に出力する。   The luminance image extraction unit 105 generates luminance image data in which only the luminance component is extracted from the image data input by applying signal processing in the signal correction unit 101. Specifically, the luminance image extraction unit 105 performs conversion processing from color data of each color into luminance values for Bayer-format image data. The calculation formula used for conversion to the luminance value at this time may be a conversion formula for converting to an arbitrary luminance value such as a conversion formula from the RGB format to the YCbCr format or a conversion formula from the RGB format to the HSV format. Then, the luminance image extraction unit 105 outputs the obtained luminance image data to the window area extraction unit 106.

ウィンドウ領域抽出部106は、入力された輝度画像データから、後述する覆い焼き処理部104における覆い焼き処理の処理対象の画像データ、即ち記録用の画像データに対応する領域に含まれる画像データを、ウィンドウ処理によって切り出す。なお、該ウィンドウ処理によって抽出される領域は、輝度画像データの画素単位で抽出されるものとする。輝度画像データにおける記録用の画像データに対応する領域は、第1の縮小率によっては1画素未満の画素を含むことがある。このような場合、ウィンドウ領域抽出部106は1画素未満の画素を含まないよう、抽出する領域を変更するものとする。ウィンドウ領域抽出部106は、記録用の画像データに対応する領域の輝度画像データを抽出した後、抽出した輝度画像データを第1輝度画像縮小部107及び第2輝度画像縮小部111に出力する。   The window area extraction unit 106 extracts image data included in an area corresponding to image data to be subjected to dodging processing in the dodging processing unit 104 described later, that is, image data included in the image data for recording, from the input luminance image data. Cut out by window processing. Note that the region extracted by the window processing is extracted in units of pixels of luminance image data. The area corresponding to the image data for recording in the luminance image data may include pixels less than one pixel depending on the first reduction ratio. In such a case, the window region extraction unit 106 changes the region to be extracted so as not to include pixels less than one pixel. The window area extraction unit 106 extracts the luminance image data of the area corresponding to the recording image data, and then outputs the extracted luminance image data to the first luminance image reduction unit 107 and the second luminance image reduction unit 111.

第1輝度画像縮小部107は、入力された、記録用の画像データに対応する輝度画像データに対して縮小処理を行う。本実施形態において、第1輝度画像縮小部107はビットシフト演算を正規化する方法を用いて縮小処理を実行する。具体的には第1輝度画像縮小部107は、例えば縮小率(第2の縮小率)が垂直方向及び水平方向ともに1/10である場合、まず入力された輝度画像データをそれぞれの方向に10画素ずつ、計100画素の画素値を取得して積分する。さらに予め設定されたゲイン係数として10を積分値に乗じた後、10ビット右シフトさせることにより、第1輝度画像縮小部107は縮小処理を行う。なお、第1輝度画像縮小部107における縮小処理の手法はこれに限られず、任意の手法が用いられても良いことは容易に想像されよう。第1輝度画像縮小部107は、縮小処理後の輝度画像データを第1LPF108に出力する。   The first luminance image reduction unit 107 performs a reduction process on the input luminance image data corresponding to the recording image data. In the present embodiment, the first luminance image reduction unit 107 performs a reduction process using a method for normalizing a bit shift operation. Specifically, for example, when the reduction ratio (second reduction ratio) is 1/10 in both the vertical direction and the horizontal direction, the first luminance image reduction unit 107 first converts the input luminance image data to 10 in each direction. A pixel value of a total of 100 pixels is acquired and integrated for each pixel. Further, the first luminance image reducing unit 107 performs a reduction process by multiplying the integral value by 10 as a preset gain coefficient and then shifting it to the right by 10 bits. Note that the reduction processing method in the first luminance image reduction unit 107 is not limited to this, and it can be easily imagined that any method may be used. The first luminance image reduction unit 107 outputs the luminance image data after the reduction process to the first LPF 108.

第1LPF108は、輝度画像の低周波数成分を抽出するローパスフィルタである。第1LPF108に入力された縮小処理後の輝度画像データは、フィルタリング処理によって低周波数成分のみの輝度画像データとなる。第1LPF108は、フィルタ処理後の輝度画像データを第1輝度画像拡大部109に出力する。   The first LPF 108 is a low-pass filter that extracts a low-frequency component of the luminance image. The reduced luminance image data input to the first LPF 108 becomes luminance image data of only a low frequency component by the filtering process. The first LPF 108 outputs the filtered luminance image data to the first luminance image enlargement unit 109.

第1輝度画像拡大部109は、入力されたフィルタ処理後の輝度画像データに対して拡大処理を行い、記録用の画像データと同じ画素数を有する輝度画像データを生成する。具体的には第1輝度画像拡大部109は、第1の縮小率を第2の縮小率で除した値を拡大率として、フィルタ処理後の輝度画像データの拡大処理を行う。そして第1輝度画像拡大部109は、得られたフィルタ処理後の輝度画像データを第1輝度補正係数決定部110に出力する。   The first luminance image enlargement unit 109 performs an enlargement process on the input luminance image data after the filter process, and generates luminance image data having the same number of pixels as the recording image data. Specifically, the first luminance image enlargement unit 109 performs the enlargement process of the luminance image data after the filter processing, using a value obtained by dividing the first reduction rate by the second reduction rate as an enlargement rate. Then, the first luminance image enlargement unit 109 outputs the obtained luminance image data after the filter processing to the first luminance correction coefficient determination unit 110.

該拡大処理では、フィルタ処理後の輝度画像データの各画素を単純に拡大するのではなく、拡大処理により増加する画素の画素値は補間処理や外挿処理等によって算出するものとする。拡大対象の輝度画像データの各画素は、第1輝度画像縮小部107における縮小処理により複数の画素で構成される領域の画素値の積分によって生成されている。このため、拡大対象の輝度画像データの各画素の画素値は、該画素の生成時に参照された領域に対応する、拡大処理後の輝度画像データの領域の重心位置の画素の画素値に相当する。つまり、拡大処理後の輝度画像データにおいて、拡大対象の輝度画像データの画素に相当する画素(以下、単に「相当する画素」とする)に挟まれる画素(重心間の画素)の画素値は、該画素の周辺の相当する画素の画素値及びその距離を用いた補間処理によって生成される。また、相当する画素には挟まれない、即ち拡大処理後の輝度画像データの外周部分の画素については、外挿処理によって画素値を算出するものとする。   In the enlargement process, each pixel of the luminance image data after the filter process is not simply enlarged, but the pixel value of the pixel increased by the enlargement process is calculated by an interpolation process, an extrapolation process, or the like. Each pixel of the luminance image data to be enlarged is generated by integration of pixel values of an area composed of a plurality of pixels by the reduction process in the first luminance image reduction unit 107. For this reason, the pixel value of each pixel of the luminance image data to be enlarged corresponds to the pixel value of the pixel at the center of gravity of the area of the luminance image data after the enlargement process corresponding to the area referred to when the pixel is generated. . That is, in the luminance image data after the enlargement process, the pixel value of a pixel (pixel between the centers of gravity) sandwiched between pixels corresponding to the pixel of the luminance image data to be enlarged (hereinafter simply referred to as “corresponding pixel”) is: It is generated by interpolation processing using the pixel value of the corresponding pixel around the pixel and its distance. In addition, pixel values are calculated by extrapolation processing for pixels that are not sandwiched between corresponding pixels, that is, pixels in the outer peripheral portion of the luminance image data after enlargement processing.

なお、拡大処理後の輝度画像データは、後述する覆い焼き処理部104で行われる覆い焼き処理において用いられる輝度補正係数を決定するために、第1輝度補正係数決定部110で参照される。即ち、第1輝度画像拡大部109で生成される拡大処理後の輝度画像データは、輝度補正係数決定用の参照画像データである。記録用の画像データと参照画像データとは同数の画素を有しており、互いの画像データの同一座標にある画素は1対1で対応付けられる。つまり、参照画像データの1つの画素について決定された輝度補正係数は、記録用の画像データにおける該画素と同一座標の画素の補正係数である。このため、第1輝度画像拡大部109における拡大処理では、記録用の画像データと参照画像データとで、被写体像の位置ずれ量が最小となるように補間処理及び外挿処理が実行される。   The luminance image data after the enlargement process is referred to by the first luminance correction coefficient determination unit 110 in order to determine a luminance correction coefficient used in the dodging process performed by the dodging processing unit 104 described later. That is, the enlarged luminance image data generated by the first luminance image enlargement unit 109 is reference image data for determining a luminance correction coefficient. The image data for recording and the reference image data have the same number of pixels, and the pixels at the same coordinates of each other's image data are associated one-to-one. That is, the luminance correction coefficient determined for one pixel of the reference image data is a correction coefficient of a pixel having the same coordinate as the pixel in the recording image data. For this reason, in the enlargement process in the first luminance image enlargement unit 109, the interpolation process and the extrapolation process are performed so that the positional deviation amount of the subject image is minimized between the recording image data and the reference image data.

第1輝度補正係数決定部110は、入力された参照画像データの画素の各々について、該画素の輝度値から輝度補正係数を決定する。輝度補正係数は、例えばガンマ関数を用いて輝度値ごとに決定される値であり、本実施形態では、画像処理ユニット100内に設けられた不図示の不揮発性メモリにルックアップテーブルとして、輝度値ごとの輝度補正係数が格納されているものとする。第1輝度補正係数決定部110は、不揮発性メモリよりルックアップテーブルを読み出し、参照画像データの画素の各々について輝度補正係数を決定した後、画素の座標情報に該画素の輝度補正係数が関連付けられた輝度補正データを覆い焼き処理部104に出力する。   The first luminance correction coefficient determination unit 110 determines a luminance correction coefficient for each pixel of the input reference image data from the luminance value of the pixel. The luminance correction coefficient is a value determined for each luminance value using, for example, a gamma function. In the present embodiment, the luminance value is used as a lookup table in a non-illustrated non-volatile memory provided in the image processing unit 100. It is assumed that the brightness correction coefficient for each is stored. The first luminance correction coefficient determination unit 110 reads the lookup table from the nonvolatile memory, determines the luminance correction coefficient for each pixel of the reference image data, and then associates the luminance correction coefficient of the pixel with the coordinate information of the pixel. The brightness correction data is output to the dodging processor 104.

なお、本実施形態の画像処理ユニット100は、記録用の画像データの輝度補正係数を決定するラインとして、第1輝度画像縮小部107乃至第1輝度補正係数決定部110と、第2輝度画像縮小部111乃至第2輝度補正係数決定部114の2ライン設ける。しかしながら、本発明の実施はこれに限られるものではない。第2輝度画像縮小部111乃至第2輝度補正係数決定部114のブロックで行われる処理は、基本的には第1輝度画像縮小部107乃至第1輝度補正係数決定部110の処理と同様であるため、各ブロックで行われる処理の説明は省略する。両ラインは、第2輝度画像縮小部111及び第2輝度画像拡大部113で行われる、縮小処理の縮小率及び拡大処理の拡大率のみが異なる。本実施形態では、第1輝度画像縮小部107において垂直方向及び水平方向ともに1/10の縮小率の縮小処理を行うのに対し、第2輝度画像縮小部111では、垂直方向及び水平方向ともに1/100の縮小率の縮小処理を行うものとする。なお、第2輝度画像拡大部113における拡大処理の拡大率は、出力する輝度画像データの画素数は第1輝度画像拡大部109と同数であるため、該縮小率によって拡大率が変化することは容易に理解されよう。   Note that the image processing unit 100 according to the present embodiment uses the first luminance image reduction unit 107 to the first luminance correction coefficient determination unit 110 and the second luminance image reduction as lines for determining the luminance correction coefficient of image data for recording. Two lines of the unit 111 to the second luminance correction coefficient determination unit 114 are provided. However, the implementation of the present invention is not limited to this. The processing performed by the blocks of the second luminance image reduction unit 111 to the second luminance correction coefficient determination unit 114 is basically the same as the processing of the first luminance image reduction unit 107 to the first luminance correction coefficient determination unit 110. Therefore, description of processing performed in each block is omitted. Both lines differ only in the reduction rate of the reduction process and the enlargement rate of the enlargement process performed by the second luminance image reduction unit 111 and the second luminance image enlargement unit 113. In the present embodiment, the first luminance image reduction unit 107 performs a reduction process with a reduction ratio of 1/10 in both the vertical direction and the horizontal direction, whereas the second luminance image reduction unit 111 has 1 in both the vertical direction and the horizontal direction. It is assumed that a reduction process with a reduction rate of / 100 is performed. Note that the enlargement rate of the enlargement process in the second luminance image enlargement unit 113 is the same as the first luminance image enlargement unit 109 in the number of pixels of the output luminance image data, and therefore the enlargement rate varies depending on the reduction rate. Easy to understand.

また、本実施形態では、信号補正部101により信号処理された画像データから、覆い焼き処理部104で用いられる輝度補正データを出力する構成を覆い焼きゲイン生成部120と称して、以下説明するものとする。なお、覆い焼きゲイン生成部120は、輝度画像抽出部105乃至第2輝度補正係数決定部114で構成される。   In the present embodiment, a configuration for outputting brightness correction data used in the dodging processing unit 104 from image data signal-processed by the signal correction unit 101 is referred to as a dodging gain generation unit 120 and will be described below. And The dodging gain generation unit 120 includes a luminance image extraction unit 105 to a second luminance correction coefficient determination unit 114.

覆い焼き処理部104は、第1輝度補正係数決定部110及び第2輝度補正係数決定部114から入力された、輝度補正データに基づいて、記録用の画像データの対応する画素の輝度補正処理(覆い焼き処理)を行う。具体的には覆い焼き処理部104は、第1輝度補正係数決定部110及び第2輝度補正係数決定部114から入力された2種類の輝度補正データの各々を用いて輝度補正処理を行なう。そして各々の輝度補正処理の結果得られた輝度補正後の画像データを加算平均処理することにより、覆い焼き処理部104は最終的に記録する画像データ(出力画像データ)を生成する。   Based on the luminance correction data input from the first luminance correction coefficient determination unit 110 and the second luminance correction coefficient determination unit 114, the dodging processing unit 104 performs luminance correction processing (for pixels corresponding to recording image data). Dodging process). Specifically, the dodging processor 104 performs a luminance correction process using each of the two types of luminance correction data input from the first luminance correction coefficient determination unit 110 and the second luminance correction coefficient determination unit 114. The dodging processing unit 104 finally generates image data (output image data) to be recorded by subjecting the image data after luminance correction obtained as a result of the respective luminance correction processing to addition averaging processing.

なお、本実施形態ではハードウェアとして画像処理ユニット100が備える各ブロックにおいて処理が実現されるものとして説明するが、本発明の実施はこれに限らず、各ブロックの処理は該各ブロックと同様の処理を行うプログラムで実現されてもよい。   In the present embodiment, description will be made assuming that processing is realized in each block included in the image processing unit 100 as hardware. However, the embodiment of the present invention is not limited to this, and processing of each block is the same as that of each block. It may be realized by a program that performs processing.

<覆い焼きゲイン生成処理>
このような構成をもつ本実施形態の画像処理ユニット100の覆い焼きゲイン生成部120における覆い焼きゲイン生成処理について、図2のフローチャートを用いて具体的な処理を説明する。該フローチャートに対応する処理は、デジタルカメラが備える不図示の制御部が、例えばROMに記憶されている対応する処理プログラムを読み出し、RAMに展開して実行することにより画像処理ユニット100を制御することで実現できる。なお、本覆い焼きゲイン生成処理は、例えば画像処理ユニット100に入力された入力画像データについての、信号補正部101における信号処理が完了した際に開始されるものとして説明する。
<Dodge gain generation processing>
A specific process of the dodging gain generation process in the dodging gain generation unit 120 of the image processing unit 100 of the present embodiment having such a configuration will be described with reference to the flowchart of FIG. In the processing corresponding to the flowchart, a control unit (not shown) included in the digital camera reads the corresponding processing program stored in the ROM, for example, and controls the image processing unit 100 by developing it in the RAM and executing it. Can be realized. Note that the dodging gain generation process will be described as being started when the signal processing in the signal correction unit 101 for the input image data input to the image processing unit 100 is completed, for example.

なお、以下の説明では図5と同様に、入力画像データの画像サイズが800pixel×600pixel、第1の縮小率が水平方向及び垂直方向ともに3/10、記録用の画像データの画像サイズが240pixel×180pixelである場合を例に説明する。また、以下の説明では簡単のため、第1輝度画像縮小部107乃至第1輝度補正係数決定部110のラインのみを用いて補正係数データを生成する方法について説明する。なお、第1輝度画像縮小部107における縮小処理の第2の縮小率は、上述したように水平方向及び垂直方向ともに1/10であるものとする。   In the following description, as in FIG. 5, the image size of the input image data is 800 pixels × 600 pixels, the first reduction ratio is 3/10 in both the horizontal and vertical directions, and the image size of the image data for recording is 240 pixels × A case where the pixel is 180 pixels will be described as an example. For the sake of simplicity in the following description, a method for generating correction coefficient data using only the lines of the first luminance image reduction unit 107 to the first luminance correction coefficient determination unit 110 will be described. Note that the second reduction rate of the reduction processing in the first luminance image reduction unit 107 is 1/10 in both the horizontal direction and the vertical direction as described above.

また以下では、ウィンドウ処理や位置変更の処理の説明は、簡単のため処理対象となる領域あるいは画像データの左上端の座標の算出方法についてのみ説明するが、実際は左上端に加え、例えば右下端の座標の算出等の処理が同様に行われることは理解されよう。   In the following description, the window processing and position change processing will be described only for the calculation method of the coordinates of the upper left corner of the region to be processed or the image data for the sake of simplicity. It will be understood that processing such as coordinate calculation is performed in the same manner.

S201で、輝度画像抽出部105は、入力された信号補正部101における信号処理後の入力画像データから、輝度画像データを生成する。そして輝度画像抽出部105は、生成した輝度画像データをウィンドウ領域抽出部106に出力する。   In step S <b> 201, the luminance image extraction unit 105 generates luminance image data from the input image data after signal processing in the input signal correction unit 101. Then, the luminance image extraction unit 105 outputs the generated luminance image data to the window area extraction unit 106.

S202で、ウィンドウ領域抽出部106は、現像画像縮小部102における縮小処理後の画像データ(現像縮小画像データ)の左上端を原点とする座標系(x’,y’)における、記録用の画像データに対応する領域の左上端の座標を算出する。具体的にはウィンドウ領域抽出部106は、現像画像縮小部102で行われる縮小処理の第1の縮小率を、画像処理ユニット100に入力された記録用の画像データの画素数の情報及び現像処理部103において適用される画像処理のタップ数の情報とから算出する。そしてウィンドウ領域抽出部106は、入力画像データの画像サイズと第1の縮小率とから現像縮小画像データの画像サイズを把握し、現像処理部103において適用される画像処理のタップ数とから、記録用の画像データに対応する領域の左上端の座標を算出する。このとき、「現像縮小画像データにおける記録用の画像データに対応する領域の左上端の座標」は図3に示すように
(x’,y’)=(50,10)
であるものとする。
In step S <b> 202, the window area extraction unit 106 records an image for recording in the coordinate system (x ′, y ′) having the origin at the upper left corner of the image data (development reduced image data) after the reduction processing in the development image reduction unit 102. The coordinates of the upper left corner of the area corresponding to the data are calculated. Specifically, the window area extraction unit 106 uses the first reduction rate of the reduction processing performed by the development image reduction unit 102 as information on the number of pixels of the recording image data input to the image processing unit 100 and the development processing. It is calculated from information on the number of taps of image processing applied in the unit 103. Then, the window area extraction unit 106 grasps the image size of the development reduced image data from the image size of the input image data and the first reduction rate, and records it from the number of image processing taps applied in the development processing unit 103. The coordinates of the upper left corner of the area corresponding to the image data for use are calculated. At this time, “the coordinates of the upper left corner of the area corresponding to the image data for recording in the development reduced image data” is (x 0 ′, y 0 ′) = (50, 10) as shown in FIG.
Suppose that

S203で、ウィンドウ領域抽出部106は、S201で生成された輝度画像データの左上端を原点とする座標系(x,y)における、記録用の画像データに対応する領域の左上端の座標を算出する。具体的にはウィンドウ領域抽出部106は、S202で算出した「現像縮小画像データにおける記録用の画像データに対応する領域の左上端の座標」を第1の縮小率で除することにより、「輝度画像データにおける記録用の画像データに対応する領域の左上端の座標」を算出する。このとき、「輝度画像データにおける記録用の画像データに対応する領域の左上端の座標」は、
=50÷(3/10)=166.666・・・
=10÷(3/10)= 33.333・・・
となる。
In S203, the window area extraction unit 106 calculates the coordinates of the upper left corner of the area corresponding to the image data for recording in the coordinate system (x, y) with the upper left corner of the luminance image data generated in S201 as the origin. To do. Specifically, the window area extraction unit 106 divides the “coordinate of the upper left corner of the area corresponding to the image data for recording in the development reduced image data” calculated in S202 by the first reduction ratio, thereby obtaining “brightness The coordinates of the upper left corner of the area corresponding to the image data for recording in the image data are calculated. At this time, "the coordinates of the upper left corner of the area corresponding to the image data for recording in the luminance image data" is
x 0 = 50 ÷ (3/10) = 166.666...
y 0 = 10 ÷ (3/10) = 33.333
It becomes.

しかしながら、例示のように第1の縮小率によっては「輝度画像データにおける記録用の画像データに対応する領域の左上端の座標」は、画像データとして処理できない1画素未満の画素を含むことがある。このためウィンドウ領域抽出部106は、「輝度画像データにおける記録用の画像データに対応する領域の左上端の座標」が整数とならない場合は、小数点以下を四捨五入することにより該座標を整数値に変換する。即ち、上記の例では座標は、
(x0changed,y0changed)=(167,33)
に変換される。
However, as illustrated, depending on the first reduction ratio, “the coordinates of the upper left corner of the area corresponding to the image data for recording in the luminance image data” may include pixels less than one pixel that cannot be processed as image data. . For this reason, the window area extraction unit 106 converts the coordinates to an integer value by rounding off the decimal point when “the coordinates of the upper left corner of the area corresponding to the image data for recording in the luminance image data” is not an integer. To do. That is, in the above example, the coordinates are
( X0changed , y0changed ) = (167, 33)
Is converted to

S204で、ウィンドウ領域抽出部106は、S203で得られた「輝度画像データにおける記録用の画像データに対応する領域の左上端の座標」の情報に従って、記録用の画像データに対応する領域の輝度画像データを抽出する。そしてウィンドウ領域抽出部106は、抽出した輝度画像データを第1輝度画像縮小部107に出力する。   In S204, the window area extraction unit 106 determines the luminance of the area corresponding to the recording image data according to the information of “the upper left coordinates of the area corresponding to the recording image data in the luminance image data” obtained in S203. Extract image data. Then, the window area extraction unit 106 outputs the extracted luminance image data to the first luminance image reduction unit 107.

S205で、第1輝度画像縮小部107は、入力された輝度画像データに対して、第2の縮小率での縮小処理を行う。そして第1輝度画像縮小部107は、得られた縮小処理後の輝度画像データを第1LPF108に出力する。さらに第1LPF108は、入力された縮小処理後の輝度画像データに対して低周波領域成分のみを通過させるフィルタリング処理を行い、得られたフィルタ処理後の輝度画像データを第1輝度画像拡大部109に出力する。   In step S <b> 205, the first luminance image reduction unit 107 performs a reduction process with the second reduction ratio on the input luminance image data. Then, the first luminance image reduction unit 107 outputs the obtained luminance image data after the reduction process to the first LPF 108. Further, the first LPF 108 performs a filtering process that allows only the low frequency region component to pass through the input luminance image data after the reduction process, and sends the obtained luminance image data after the filtering process to the first luminance image enlargement unit 109. Output.

S206で、第1輝度画像拡大部109は、入力されたフィルタ処理後の輝度画像データに対して、第1の縮小率を第2の縮小率で除した値の拡大率rで拡大処理を行う。本実施形態の例では拡大率rは
r=(3/10)÷(1/10)=3倍
となる。
In step S <b> 206, the first luminance image enlargement unit 109 performs an enlargement process on the input luminance image data after the filtering process with an enlargement ratio r that is a value obtained by dividing the first reduction ratio by the second reduction ratio. . In the example of the present embodiment, the enlargement ratio r is r = (3/10) ÷ (1/10) = 3 times.

(拡大処理の詳細)
ここで、第1輝度画像拡大部109が行う拡大処理について、具体的な処理の内容をいかに説明する。上述したように第1輝度画像拡大部109において拡大処理を行なって出力される参照画像データは、記録用の画像データと同数の画素数を有する。また参照画像データは、参照画像データと記録用の画像データとを同一座標の画素が重なるように重ねた場合、画像間における被写体像の位置ずれ量が最小となるように生成される。
(Details of enlargement processing)
Here, the details of the enlargement process performed by the first luminance image enlargement unit 109 will be described. As described above, the reference image data output by performing the enlargement process in the first luminance image enlargement unit 109 has the same number of pixels as the image data for recording. Further, when the reference image data and the recording image data are overlapped so that pixels having the same coordinates overlap, the reference image data is generated so that the amount of positional deviation of the subject image between the images is minimized.

第1輝度画像拡大部109はまず、ウィンドウ領域抽出部106における輝度画像データの抽出時に、記録用の画像データに対応する領域の変更が行われたか否かを判断する。記録用の画像データに対応する領域の変更が行われていた場合、第1輝度画像拡大部109は、変更後の領域の左上端の座標と、現像縮小画像データの座標系において、実際の記録用の画像データ領域の左上端の座標との位置ずれ量Δf=(Δf,Δf)を算出する。上述の例の場合、変更後の領域の左上端の座標は167であるため、第1の縮小率を用いて現像縮小画像データの座標系に変換すると該座標は
0changed’=167×(3/10)=50.1
0changed’= 33×(3/10)= 9.9
となる。即ち、ウィンドウ領域抽出部106において抽出された輝度画像データは、その時点で記録用の画像データと左上端の座標が
Δf=x0changed’−x’=50.1−50=+0.1
Δf=y0changed’−y’= 9.9−10=−0.1
の位置ずれを生じていることになる。
The first luminance image enlarging unit 109 first determines whether or not the region corresponding to the recording image data has been changed when the luminance image data is extracted by the window region extracting unit 106. When the area corresponding to the image data for recording has been changed, the first luminance image enlarging unit 109 performs the actual recording in the coordinate of the upper left corner of the area after the change and the coordinate system of the development reduced image data. A positional deviation amount Δf = (Δf x , Δf y ) with respect to the coordinates of the upper left corner of the image data area for use is calculated. In the case of the above example, since the coordinate of the upper left corner of the area after the change is 167, when converted into the coordinate system of the development reduced image data using the first reduction ratio, the coordinate is x 0changed '= 167 × (3 /10)=50.1
y 0changed '= 33 × (3/10) = 9.9
It becomes. In other words, the luminance image data extracted by the window area extraction unit 106 has the image data for recording and the coordinates of the upper left corner at that time: Δf x = x 0 changed '−x 0 ' = 50.1−50 = + 0.1
Δf y = y 0 changed '−y 0 ' = 9.9−10 = −0.1
That is, the positional deviation is caused.

また第1輝度画像拡大部109は、生成する参照画像データにおける、フィルタ処理後の輝度画像データの各画素に対応する領域の重心位置を算出する。具体的には第1輝度画像拡大部109は最初に、単に拡大率rで拡大処理を行なって得られる拡大処理後の輝度画像データにおいて、フィルタ処理後の輝度画像データの各画素に対応する領域の重心位置の、該領域の左上端からの位置ずれ量を取得する。図4は、単に拡大率rの拡大処理を行なった場合に得られる拡大処理後の輝度画像データの左上端部を示している。図示されるように、フィルタ処理後の輝度画像データの左上端の画素に対応する領域400の中央に重心401が存在している。このとき、領域400の左上端からの重心401の位置ずれ量Δg=(Δg,Δg)は、拡大率(r=3倍)を用いて
Δg=r×(1/2)=3×(1/2)=1.5
Δg=r×(1/2)=3×(1/2)=1.5
と表せる。即ち、単に拡大率rの拡大処理を行う場合、補間処理あるいは外挿処理の基準となる、フィルタ処理後の輝度画像データの各画素に対応する領域の重心は、各領域の左上端から算出した重心位置ずれ量Δg分離れた位置にある。
Further, the first luminance image enlargement unit 109 calculates the barycentric position of the region corresponding to each pixel of the luminance image data after the filtering process in the reference image data to be generated. Specifically, the first luminance image enlargement unit 109 firstly, in the luminance image data after the enlargement process obtained by simply performing the enlargement process with the enlargement ratio r, the area corresponding to each pixel of the luminance image data after the filter process The amount of displacement of the center of gravity position of the region from the upper left end of the region is acquired. FIG. 4 shows the upper left end portion of the luminance image data after the enlargement process obtained when the enlargement process with the enlargement ratio r is simply performed. As shown in the figure, the center of gravity 401 exists in the center of the region 400 corresponding to the upper left pixel of the luminance image data after the filtering process. At this time, the positional deviation amount Δg = (Δg x , Δg y ) of the center of gravity 401 from the upper left end of the region 400 is expressed by Δg x = r × (1/2) = 3 using an enlargement ratio (r = 3 times). × (1/2) = 1.5
Δg y = r × (1/2) = 3 × (1/2) = 1.5
It can be expressed. That is, when the enlargement process of the enlargement ratio r is simply performed, the center of gravity of the area corresponding to each pixel of the luminance image data after the filter process, which is a reference for the interpolation process or the extrapolation process, is calculated from the upper left end of each area. It is in a position separated by the gravity center position deviation amount Δg.

しかしながら、先にも述べたとおり画像データの構造上、移動は画素単位で行われる必要がある。このため、算出した重心位置ずれ量Δgと、輝度画像データの抽出時に生じた位置ずれ量Δfとの和(移動基準値Δf+Δg:該重心の記録用の画像データに対する実際の位置ずれ量)が1画素未満の値を含む場合、算出した該移動基準値を整数値に丸める必要がある。このとき第1輝度画像拡大部109は、補間処理及び外挿処理を伴う拡大処理の結果得られる参照画像データと、記録用の画像データとを同一座標の画素が一致するように重ねた際に、両画像データの被写体像の位置ずれ量が最小となるように移動基準値を丸める。具体的には第1輝度画像拡大部109は、移動基準値の小数点以下の値を切り上げた場合と切り捨てた場合とについて、移動基準値からの変化量を比較し、該変化量が最小となる方法で移動基準値を丸める。   However, as described above, due to the structure of the image data, the movement needs to be performed in units of pixels. Therefore, the sum of the calculated center-of-gravity position shift amount Δg and the position shift amount Δf generated when extracting the luminance image data (movement reference value Δf + Δg: actual position shift amount of the center-of-gravity with respect to image data for recording) is 1. When a value less than a pixel is included, it is necessary to round the calculated movement reference value to an integer value. At this time, the first luminance image enlarging unit 109 overlaps the reference image data obtained as a result of the enlarging process including the interpolation process and the extrapolation process, and the image data for recording so that the pixels having the same coordinates coincide. The movement reference value is rounded so that the positional deviation amount of the subject image of both image data is minimized. Specifically, the first luminance image enlarging unit 109 compares the amount of change from the movement reference value when the value after the decimal point of the movement reference value is rounded up and when the value is rounded down, and the amount of change is minimized. The movement reference value is rounded by the method.

具体的には第1輝度画像拡大部109は、切り上げた場合の移動基準値の増加分(A)、及び切り捨てた場合の移動基準値の減少分(B)について絶対値をとる。第1輝度画像拡大部109は、この結果の絶対値の値が小さい(0に近い)値がAである場合は切り上げにより移動基準値を丸め、Bである場合は切り捨てを行うことで移動基準値を丸めることで、移動基準値を整数値に変更する。上述の数値例では、切り上げた場合の移動基準値の増加分及び切り捨てた場合の移動基準値の減少分それぞれの絶対値は、
・x座標
=ABS(ROUNDUP(Δf+Δg)−(Δf+Δg))
=ABS(ROUNDUP( 0.1+1.5)−( 0.1+1.5))
=ABS(2−1.6)=0.4
=ABS(ROUNDDOWN(Δf+Δg)−(Δf+Δg))
=ABS(ROUNDDOWN( 0.1+1.5)−( 0.1+1.5))
=ABS(1−1.6)=0.6
・y座標
=ABS(ROUNDUP(Δf+Δg)−(Δf+Δg))
=ABS(ROUNDUP(−0.1+1.5)−(−0.1+1.5))
=ABS(2−1.4)=0.6
=ABS(ROUNDDOWN(Δf+Δg)−(Δf+Δg))
=ABS(ROUNDDOWN(−0.1+1.5)−(−0.1+1.5))
=ABS(1−1.4)=0.4
(ただし、ABSは絶対値、ROUNDUPは切り上げ値、ROUNDDOWNは切り下げ値をそれぞれ出力する関数である)
となり、x成分はA<Bであるから移動基準値を切り上げによって整数値に変更し、y成分はB<Aであるから移動基準値を切り捨てによって整数値に変更する。このため、拡大処理によって生成される参照画像データのうち、フィルタ処理後の輝度画像データの左上端の画素に対応する領域の重心の、記録用の画像データの左上端からの最終的な位置ずれ量(Δgxfinal,Δgyfinal)は、
Δgxfinal=ROUNDUP(Δf+Δg)=2
Δgyfinal=ROUNDOWN(Δf+Δg)=1
となる。
Specifically, the first luminance image enlarging unit 109 takes absolute values for the increment (A) of the movement reference value when rounded up and the decrease (B) of the movement reference value when rounded down. The first luminance image enlarging unit 109 rounds the movement reference value by rounding up when the absolute value of the result is small (close to 0) is A, and rounds down the movement reference value when the absolute value is B. The movement reference value is changed to an integer value by rounding the value. In the above numerical example, the absolute value of the increment of the movement reference value when rounded up and the decrease of the movement reference value when rounded down are respectively
X coordinate A x = ABS (ROUNDUP (Δf x + Δg x ) − (Δf x + Δg x ))
= ABS (ROUNDUP (0.1 + 1.5)-(0.1 + 1.5))
= ABS (2-1.6) = 0.4
B x = ABS (ROUNDDOWN (Δf x + Δg x ) − (Δf x + Δg x ))
= ABS (ROUNDDOWN (0.1 + 1.5)-(0.1 + 1.5))
= ABS (1-1.6) = 0.6
Y coordinate A y = ABS (ROUNDUP (Δf y + Δg y ) − (Δf y + Δg y ))
= ABS (ROUNDUP (-0.1 + 1.5)-(-0.1 + 1.5))
= ABS (2-1.4) = 0.6
B y = ABS (ROUNDDOWN (Δf x + Δg y ) − (Δf x + Δg y ))
= ABS (ROUNDDOWN (-0.1 + 1.5)-(-0.1 + 1.5))
= ABS (1-1.4) = 0.4
(However, ABS is a function that outputs an absolute value, ROUNDUP is a round-up value, and ROUNDDOWN is a function that outputs a round-down value.)
Since the x component is A <B, the movement reference value is changed to an integer value by rounding up, and since the y component is B <A, the movement reference value is changed to an integer value by rounding down. For this reason, among the reference image data generated by the enlargement process, the final position deviation of the center of gravity of the area corresponding to the pixel at the upper left end of the filtered luminance image data from the upper left end of the image data for recording The quantity ( Δg xfinal , Δg yfinal ) is
Δg xfinal = ROUNDUP (Δf x + Δg x ) = 2
Δg yfinal = ROUNDDOWN (Δf x + Δg y ) = 1
It becomes.

即ち、第1輝度画像拡大部109は、生成する参照画像データの左上端から最終的な位置ずれ量分移動した位置に、フィルタ処理後の輝度画像データの左上の画素に対応する領域の重心が移動するように調整する。つまり、フィルタ処理後の輝度画像データの左上端以外の画素に対応する領域の重心は、左上端の画素に対応する領域の重心に合わせて位置が変更されることになる。   That is, the first luminance image enlargement unit 109 has the center of gravity of the region corresponding to the upper left pixel of the luminance image data after the filtering process at a position shifted by the final positional deviation amount from the upper left end of the reference image data to be generated. Adjust to move. That is, the position of the center of gravity of the region corresponding to the pixels other than the upper left corner of the luminance image data after the filter processing is changed according to the center of gravity of the region corresponding to the upper left upper pixel.

第1輝度画像拡大部109は、このようにフィルタ処理後の輝度画像データの各画素に対応する領域の重心の、参照画像データにおける位置を決定した後、補間処理及び外挿処理を行なって、記録用の画像データと同数の画素数を有する参照画像データを生成する。そして第1輝度画像拡大部109は、生成した参照画像データを第1輝度補正係数決定部110に出力する。   The first luminance image enlarging unit 109 determines the position in the reference image data of the center of gravity of the region corresponding to each pixel of the luminance image data after the filter processing in this way, and then performs interpolation processing and extrapolation processing, Reference image data having the same number of pixels as the image data for recording is generated. Then, the first luminance image enlargement unit 109 outputs the generated reference image data to the first luminance correction coefficient determination unit 110.

S207で、第1輝度補正係数決定部110は、入力された参照画像データの画素の各々の輝度値に基づいて輝度補正係数を決定し、画素の座標情報に関連付けて輝度補正データとして出力する。具体的には第1輝度補正係数決定部110は、画像処理ユニット100が有する不図示の不揮発性メモリから、輝度補正係数決定用のルックアップテーブルを読み出し、対象画素の輝度値に応じたきど補正係数の情報を取得する。そして第1輝度補正係数決定部110は、対象画素の座標情報に、該画素の輝度補正係数を関連付けて、輝度補正データとして覆い焼き処理部104に出力し、覆い焼きゲイン生成処理を完了する。   In S207, the first luminance correction coefficient determination unit 110 determines a luminance correction coefficient based on the luminance value of each pixel of the input reference image data, and outputs the luminance correction data in association with the pixel coordinate information. Specifically, the first luminance correction coefficient determination unit 110 reads a look-up table for determining the luminance correction coefficient from a non-illustrated nonvolatile memory included in the image processing unit 100, and corrects the threshold according to the luminance value of the target pixel. Get coefficient information. Then, the first luminance correction coefficient determination unit 110 associates the luminance correction coefficient of the pixel with the coordinate information of the target pixel, and outputs the luminance correction data to the dodging processing unit 104 to complete the dodging gain generation process.

このようにすることで、輝度補正係数決定用の参照画像データを生成する際に、輝度画像の抽出時に生じた位置ずれを加味して、記録用の画像データと参照画像データとの間の被写体像の位置ずれを最小にすることができる。   In this way, when generating the reference image data for determining the luminance correction coefficient, the subject between the recording image data and the reference image data is taken into account, taking into account the positional deviation that occurred during the extraction of the luminance image. The positional deviation of the image can be minimized.

以上説明したように、本実施形態の画像処理装置は、記録用の画像と輝度補正係数決定用の参照画像間の位置ずれを低減し、好適な輝度補正処理を行うことができる。具体的には画像処理装置は、取得した処理対象の画像に対して縮小処理を行なって得られた画像から、予め設定された画素数を有する記録用の画像を生成する。また処理対象の画像から、記録用の画像に対応する領域の輝度画像を抽出して縮小処理を行い、予め設定された画素数よりも少ない画素数を有する輝度画像を生成する。なお、記録用の画像に対応する領域が1画素未満の画素を含む場合は、該対応する領域を1画素未満の画素を含まない領域に変更して輝度画像を抽出する。さらに画像処理装置は縮小処理後の輝度画像に対して拡大処理を行い、予め設定された画素数を有する、記録用の画像の輝度補正係数決定用の参照画像を生成する。このとき、輝度画像を抽出する領域の変更がなされた場合は、縮小処理後の輝度画像の各画素に対応する領域の重心を、該対応する領域の変更の情報及び拡大率に基づいて、参照画像と記録用の画像間における被写体像の位置ずれ量が最小となる位置に変更して参照画像を生成する。   As described above, the image processing apparatus according to the present embodiment can reduce the positional deviation between the recording image and the reference image for determining the luminance correction coefficient, and perform a suitable luminance correction process. Specifically, the image processing apparatus generates a recording image having a preset number of pixels from an image obtained by performing reduction processing on the acquired processing target image. In addition, a luminance image in an area corresponding to the image to be recorded is extracted from the processing target image and subjected to a reduction process to generate a luminance image having a smaller number of pixels than a preset number of pixels. If the area corresponding to the recording image includes pixels less than one pixel, the corresponding area is changed to an area not including pixels less than one pixel, and a luminance image is extracted. Furthermore, the image processing apparatus performs an enlargement process on the luminance image after the reduction process, and generates a reference image for determining the luminance correction coefficient of the image for recording having a preset number of pixels. At this time, when the area for extracting the luminance image is changed, the center of gravity of the area corresponding to each pixel of the luminance image after the reduction process is referred to based on the information on the change of the corresponding area and the enlargement ratio. The reference image is generated by changing the position of the subject image between the image and the recording image to a position where the amount of positional deviation is minimized.

[変形例]
上述した実施形態では、単位画素ごとに画像処理が行われるため、画素単位で輝度画像を抽出する領域を変更するものとして説明した。本変形例では、画像処理に係る回路が複数(所定数)の画素を同時処理する場合に、画像処理ユニット100の各ブロックで行われる処理について説明する。
[Modification]
In the above-described embodiment, since image processing is performed for each unit pixel, it has been described that the region for extracting the luminance image is changed in units of pixels. In this modification, processing performed in each block of the image processing unit 100 when a circuit related to image processing simultaneously processes a plurality (a predetermined number) of pixels will be described.

本変形例では、画像処理ユニット100のうち、信号補正部101、現像画像縮小部102、輝度画像抽出部105、及びウィンドウ領域抽出部106が、4画素を同時に処理する構成であるものとする。なお、他のブロックについては、4画素の同時処理を行わず、1画素ずつの処理を行うものとする。また、複数画素を同時処理可能なブロックで処理した後、1画素ずつ出力する回路は、公知の技術を用いればよい。例えば輝度画像抽出部105では、入力された複数画素に対して重み付け加算を行うことで、1サイクルあたりの出力画素数を削減すればよい。   In this modification, the signal correction unit 101, the developed image reduction unit 102, the luminance image extraction unit 105, and the window area extraction unit 106 of the image processing unit 100 are configured to process four pixels simultaneously. For the other blocks, it is assumed that four pixels are not simultaneously processed and one pixel is processed at a time. A circuit that outputs pixels one by one after processing a plurality of pixels in a block that can be processed simultaneously may use a known technique. For example, the luminance image extraction unit 105 may reduce the number of output pixels per cycle by performing weighted addition on a plurality of input pixels.

このような構成の場合、ウィンドウ領域抽出部106で行われる、輝度画像データから記録用の画像データに対応する領域を抽出する際の処理が、上述の実施形態とは異なる。即ち、ウィンドウ処理における入力ウィンドウの設定が、4画素単位、即ち垂直方向及び水平方向の各々の画素数が4の倍数となる必要がある。このため、上述の実施形態のように記録用の画像データに対応する領域の左上端の座標が
=50÷(3/10)=166.666・・・
=10÷(3/10)= 33.333・・・
である場合、対応する領域の変更は、変更後の左上端の座標が4の倍数となるように行われる。この場合、変更後の左上端の座標は
(x0changed,y0changed)=(168,32)
となる。
In such a configuration, the processing performed by the window region extraction unit 106 when extracting the region corresponding to the recording image data from the luminance image data is different from that of the above-described embodiment. That is, the setting of the input window in the window processing needs to be a unit of 4 pixels, that is, the number of pixels in the vertical and horizontal directions is a multiple of 4. Therefore, as in the above-described embodiment, the coordinates of the upper left corner of the area corresponding to the image data for recording is x 0 = 50 ÷ (3/10) = 166.666.
y 0 = 10 ÷ (3/10) = 33.333
In the case of, the corresponding region is changed so that the upper left coordinate after the change is a multiple of four. In this case, the coordinates of the upper left corner after the change are (x 0changed , y 0changed ) = (168, 32)
It becomes.

本変形例では、このように輝度画像データから記録用の画像データに対応する領域を抽出する際に、上述の実施形態とは異なる方法で領域の変更がなされる。しかしながら、該変更により生じた位置ずれの情報は、第1輝度画像拡大部109において加味されて位置ずれが補正されるため、上述の実施形態と同様に、記録用の画像データと参照画像データとの間の被写体像の位置ずれを最小にすることができる。   In this modification, when extracting the region corresponding to the recording image data from the luminance image data in this way, the region is changed by a method different from the above-described embodiment. However, since the positional deviation information generated by the change is added and corrected in the first luminance image enlargement unit 109, the recording image data, the reference image data, and the like, as in the above-described embodiment. The positional deviation of the subject image during the interval can be minimized.

[その他の実施形態]
また、本発明は、以下の処理を実行することによっても実現される。即ち、上述した実施形態の機能を実現するソフトウェア(プログラム)を、ネットワーク又は各種記憶媒体を介してシステム或いは装置に供給し、そのシステム或いは装置のコンピュータ(またはCPUやMPU等)がプログラムを読み出して実行する処理である。
[Other Embodiments]
The present invention can also be realized by executing the following processing. That is, software (program) that realizes the functions of the above-described embodiments is supplied to a system or apparatus via a network or various storage media, and a computer (or CPU, MPU, or the like) of the system or apparatus reads the program. It is a process to be executed.

Claims (7)

処理対象の画像を取得する取得手段と、
前記取得手段により取得された前記処理対象の画像に対して第1の縮小率の縮小処理を行なって得られた画像から、予め設定された画素数を有する記録用の画像を生成する生成手段と、
前記取得手段により取得された前記処理対象の画像から、前記生成手段により生成される前記記録用の画像に対応する領域の輝度画像を抽出する抽出手段と、
前記抽出手段により抽出された前記対応する領域の輝度画像に対して前記第1の縮小率とは異なる第2の縮小率の縮小処理を行い、前記予め設定された画素数よりも少ない画素数を有する輝度画像を生成する縮小手段と、
前記縮小手段により生成された前記縮小処理後の輝度画像に対して、前記第1の縮小率を前記第2の縮小率で除した値の拡大率で拡大処理を行い、前記予め設定された画素数を有する、前記記録用の画像の輝度補正係数決定用の参照画像を生成する拡大手段と、
前記記録用の画像の各画素について、前記参照画像の同一座標の画素の輝度値から決定された輝度補正係数で輝度補正を行う補正手段と、を有し、
前記抽出手段は、前記対応する領域が1画素未満の画素を含む場合、前記対応する領域を1画素未満の画素を含まない領域に変更して前記対応する領域の輝度画像を抽出し、
前記拡大手段は、前記抽出手段による前記対応する領域の変更がなされた場合に、前記縮小処理後の輝度画像の各画素に対応する前記参照画像における領域の重心を、前記抽出手段による前記対応する領域の変更の情報及び前記拡大率に基づいて、前記参照画像と前記記録用の画像間における被写体像の位置ずれ量が最小となる位置に変更して前記参照画像を生成する
ことを特徴とする画像処理装置。
An acquisition means for acquiring an image to be processed;
Generating means for generating a recording image having a preset number of pixels from an image obtained by performing reduction processing at a first reduction ratio on the processing target image acquired by the acquiring means; ,
Extracting means for extracting a luminance image of an area corresponding to the recording image generated by the generating means from the processing target image acquired by the acquiring means;
The luminance image of the corresponding area extracted by the extraction unit is subjected to a reduction process with a second reduction ratio different from the first reduction ratio, and the number of pixels smaller than the preset number of pixels is set. Reduction means for generating a luminance image having;
The luminance image after the reduction processing generated by the reduction means is subjected to enlargement processing at an enlargement rate obtained by dividing the first reduction rate by the second reduction rate, and the preset pixel A magnifying means for generating a reference image for determining a luminance correction coefficient of the image for recording having a number;
Correction means for performing luminance correction on each pixel of the image for recording with a luminance correction coefficient determined from the luminance value of the pixel at the same coordinate of the reference image;
When the corresponding area includes pixels less than one pixel, the extraction unit changes the corresponding area to an area not including pixels less than one pixel, and extracts a luminance image of the corresponding area.
The enlargement unit, when the corresponding region is changed by the extraction unit, displays the center of gravity of the region in the reference image corresponding to each pixel of the luminance image after the reduction process, by the corresponding extraction unit. Based on the area change information and the enlargement ratio, the reference image is generated by changing to a position where the amount of positional deviation of the subject image between the reference image and the recording image is minimized. Image processing device.
前記生成手段が、所定数の画素単位で前記記録用の画像を生成する処理を行う場合に、
前記抽出手段は、前記対応する領域が前記所定数の画素単位で処理した際に前記所定数に満たない画素での処理が行われると判断した場合に、前記対応する領域を前記所定数に満たない画素についての処理が行われない画素数の領域に変更して前記対応する領域の輝度画像を抽出する
ことを特徴とする請求項1に記載の画像処理装置。
When the generation unit performs a process of generating the recording image in a predetermined number of pixels,
When the extraction unit determines that processing is performed on pixels that are less than the predetermined number when the corresponding region is processed in units of the predetermined number of pixels, the extraction unit satisfies the predetermined number of the corresponding regions. The image processing apparatus according to claim 1, wherein a luminance image of the corresponding area is extracted by changing to an area having a number of pixels in which processing is not performed for a non-existing pixel.
前記拡大手段は、前記抽出手段による前記対応する領域の変更がなされた場合に、前記第1の縮小率の縮小処理を行なって得られた画像における、前記変更がなされた前記対応する領域と前記記録用の画像との位置ずれ量に、前記縮小処理後の輝度画像の各画素に対応する前記参照画像における領域の重心と該領域の左上端との位置ずれ量とを加えて得られる移動基準値を算出し、該移動基準値の小数点以下を切り上げた値から該移動基準値を減じた値、及び該移動基準値の小数点以下を切り捨てた値から該移動基準値を減じた値のうち、0に近い値に対して前記移動基準値を加算した値だけ移動した位置に、前記縮小処理後の輝度画像の各画素に対応する前記参照画像における領域の重心を変更することを特徴とする請求項1または2に記載の画像処理装置。   The enlargement means, when the corresponding area is changed by the extraction means, in the image obtained by performing the reduction process of the first reduction ratio and the corresponding area changed Movement standard obtained by adding the positional deviation amount between the center of gravity of the region in the reference image corresponding to each pixel of the luminance image after the reduction processing and the upper left end of the region to the positional deviation amount from the image for recording A value obtained by subtracting the movement reference value from a value obtained by rounding up the decimal point of the movement reference value, and a value obtained by subtracting the movement reference value from a value obtained by rounding down the decimal point of the movement reference value. The center of gravity of a region in the reference image corresponding to each pixel of the luminance image after the reduction processing is changed to a position moved by a value obtained by adding the movement reference value to a value close to 0. Item 1 or 2 The image processing apparatus. 前記拡大手段は、前記縮小処理後の輝度画像の各画素の画素値を、該画素に対応する前記参照画像における領域の重心の画素値とし、前記参照画像の該重心間の画素については周辺の重心の画素値からの補間処理で算出し、前記参照画像のそれ以外の画素の画素値は外挿処理により算出することを特徴とする請求項1乃至3のいずれか1項に記載の画像処理装置。   The enlargement means uses the pixel value of each pixel of the luminance image after the reduction processing as a pixel value of the center of gravity of the region in the reference image corresponding to the pixel, and the pixels between the centers of gravity of the reference image 4. The image processing according to claim 1, wherein the pixel value is calculated by interpolation processing from a pixel value of the center of gravity, and the pixel values of other pixels of the reference image are calculated by extrapolation processing. 5. apparatus. 前記拡大処理による前記縮小処理後の輝度画像の各画素に対応する前記参照画像における領域の重心の位置の変更は、垂直方向及び水平方向について行うことを特徴とする請求項1乃至4のいずれか1項に記載の画像処理装置。   The change in the position of the center of gravity of the region in the reference image corresponding to each pixel of the luminance image after the reduction processing by the enlargement processing is performed in the vertical direction and the horizontal direction. The image processing apparatus according to item 1. 画像処理装置の取得手段が、処理対象の画像を取得する取得工程と、
前記画像処理装置の生成手段が、前記取得工程において取得された前記処理対象の画像に対して第1の縮小率の縮小処理を行なって得られた画像から、予め設定された画素数を有する記録用の画像を生成する生成工程と、
前記画像処理装置の生成手段が、前記取得工程において取得された前記処理対象の画像から、前記生成工程において生成される前記記録用の画像に対応する領域の輝度画像を抽出する抽出工程と、
前記画像処理装置の生成手段が、前記抽出工程において抽出された前記対応する領域の輝度画像に対して前記第1の縮小率とは異なる第2の縮小率の縮小処理を行い、前記予め設定された画素数よりも少ない画素数を有する輝度画像を生成する縮小工程と、
前記画像処理装置の生成手段が、前記縮小工程において生成された前記縮小処理後の輝度画像に対して、前記第1の縮小率を前記第2の縮小率で除した値の拡大率で拡大処理を行い、前記予め設定された画素数を有する、前記記録用の画像の輝度補正係数決定用の参照画像を生成する拡大工程と、
前記画像処理装置の生成手段が、前記記録用の画像の各画素について、前記参照画像の同一座標の画素の輝度値から決定された輝度補正係数で輝度補正を行う補正工程と、を有し、
前記抽出手段は前記抽出工程において、前記対応する領域が1画素未満の画素を含む場合、前記対応する領域を1画素未満の画素を含まない領域に変更して前記対応する領域の輝度画像を抽出し、
前記拡大手段は前記拡大工程においては、前記抽出工程における前記対応する領域の変更がなされた場合に、前記縮小処理後の輝度画像の各画素に対応する前記参照画像における領域の重心を、前記抽出工程における前記対応する領域の変更の情報及び前記拡大率に基づいて、前記参照画像と前記記録用の画像間における被写体像の位置ずれ量が最小となる位置に変更して前記参照画像を生成する
ことを特徴とする画像処理装置の制御方法。
An acquisition step in which an acquisition unit of the image processing apparatus acquires an image to be processed;
A recording having a preset number of pixels from an image obtained by performing generation processing of the first reduction ratio on the processing target image acquired in the acquisition step by the generation unit of the image processing apparatus. A generation process for generating an image for
An extraction step in which a generation unit of the image processing apparatus extracts a luminance image of an area corresponding to the recording image generated in the generation step from the processing target image acquired in the acquisition step;
The generation unit of the image processing device performs a reduction process of a second reduction rate different from the first reduction rate on the luminance image of the corresponding region extracted in the extraction step, and the preset A reduction process for generating a luminance image having a smaller number of pixels than the number of pixels,
The generation unit of the image processing apparatus performs an enlargement process on the luminance image after the reduction process generated in the reduction process with an enlargement ratio of a value obtained by dividing the first reduction ratio by the second reduction ratio. Performing an enlargement step of generating a reference image for determining a luminance correction coefficient of the image for recording having the preset number of pixels;
A correction step in which the generation unit of the image processing device performs luminance correction on each pixel of the image for recording with a luminance correction coefficient determined from a luminance value of a pixel at the same coordinate of the reference image,
In the extraction step, when the corresponding area includes pixels less than one pixel, the extraction unit changes the corresponding area to an area not including pixels less than one pixel, and extracts a luminance image of the corresponding area And
In the enlargement step, the enlargement unit extracts the center of gravity of the region in the reference image corresponding to each pixel of the luminance image after the reduction process when the corresponding region is changed in the extraction step. Based on the information on the change of the corresponding area in the process and the enlargement ratio, the reference image is generated by changing the position of the subject image between the reference image and the recording image to a position where the amount of positional deviation is minimized. And a control method for the image processing apparatus.
コンピュータを、請求項1乃至5のいずれか1項に記載の画像処理装置の各手段として機能させるためのプログラム。   The program for functioning a computer as each means of the image processing apparatus of any one of Claims 1 thru | or 5.
JP2011222346A 2011-10-06 2011-10-06 Image processing apparatus, image processing method, and program Expired - Fee Related JP5775413B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011222346A JP5775413B2 (en) 2011-10-06 2011-10-06 Image processing apparatus, image processing method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011222346A JP5775413B2 (en) 2011-10-06 2011-10-06 Image processing apparatus, image processing method, and program

Publications (3)

Publication Number Publication Date
JP2013084067A true JP2013084067A (en) 2013-05-09
JP2013084067A5 JP2013084067A5 (en) 2014-11-13
JP5775413B2 JP5775413B2 (en) 2015-09-09

Family

ID=48529214

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011222346A Expired - Fee Related JP5775413B2 (en) 2011-10-06 2011-10-06 Image processing apparatus, image processing method, and program

Country Status (1)

Country Link
JP (1) JP5775413B2 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060045377A1 (en) * 2004-08-27 2006-03-02 Tomoaki Kawai Image processing apparatus and method
JP2010021753A (en) * 2008-07-10 2010-01-28 Ricoh Co Ltd Image processor, image apparatus processing the same and digital still camera
JP2010021952A (en) * 2008-07-14 2010-01-28 Canon Inc Apparatus and method for image processing and program

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060045377A1 (en) * 2004-08-27 2006-03-02 Tomoaki Kawai Image processing apparatus and method
JP2006065676A (en) * 2004-08-27 2006-03-09 Canon Inc Image processor and image processing method
JP2010021753A (en) * 2008-07-10 2010-01-28 Ricoh Co Ltd Image processor, image apparatus processing the same and digital still camera
JP2010021952A (en) * 2008-07-14 2010-01-28 Canon Inc Apparatus and method for image processing and program

Also Published As

Publication number Publication date
JP5775413B2 (en) 2015-09-09

Similar Documents

Publication Publication Date Title
US11849224B2 (en) Global tone mapping
JP6381215B2 (en) Image processing apparatus, image processing method, display apparatus, display apparatus control method, and program
US20160364848A1 (en) Global tone mapping
US8965120B2 (en) Image processing apparatus and method of controlling the same
KR101099401B1 (en) Image processing apparatus and computer-readable medium
TWI519151B (en) Image processing method and image processing apparatus
JP2006134157A (en) Shading correction device, shading correction value computation device and imaging device
JP2017108211A (en) Imaging apparatus, imaging control method, and program
JP2011003048A (en) Image processing apparatus and image processing program
JP2013218487A (en) Image processing apparatus, imaging apparatus, image processing method, and program
JP6087612B2 (en) Image processing apparatus and image processing method
WO2019104047A1 (en) Global tone mapping
JP2014010776A (en) Image processing apparatus, image processing method, and program
US20170257548A1 (en) Image signal processor apparatus and image signal processing method
US20140064605A1 (en) Image processing apparatus, image processing method, and program
JP2008033592A (en) Image processing apparatus, image processing method, and program
JP5631769B2 (en) Image processing device
JP5775413B2 (en) Image processing apparatus, image processing method, and program
JP5952573B2 (en) Image processing apparatus and control method thereof
US20140064606A1 (en) Image processing apparatus and image processing method
WO2016200480A1 (en) Color filter array scaler
JP2012044560A (en) Image processing apparatus, image processing method, and imaging apparatus
KR20110095556A (en) Image projection apparatus and image correcting method thereof
US20140327695A1 (en) Image processing apparatus and control method therefor
JP2014110507A (en) Image processing device and image processing method

Legal Events

Date Code Title Description
A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140930

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20140930

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20150529

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: 20150605

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20150703

R151 Written notification of patent or utility model registration

Ref document number: 5775413

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

LAPS Cancellation because of no payment of annual fees