JP5800970B2 - Image processing apparatus, imaging apparatus, image processing method, and image processing program - Google Patents

Image processing apparatus, imaging apparatus, image processing method, and image processing program Download PDF

Info

Publication number
JP5800970B2
JP5800970B2 JP2014175411A JP2014175411A JP5800970B2 JP 5800970 B2 JP5800970 B2 JP 5800970B2 JP 2014175411 A JP2014175411 A JP 2014175411A JP 2014175411 A JP2014175411 A JP 2014175411A JP 5800970 B2 JP5800970 B2 JP 5800970B2
Authority
JP
Japan
Prior art keywords
processing
edge enhancement
image
reduction
image data
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
JP2014175411A
Other languages
Japanese (ja)
Other versions
JP2015008523A (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.)
Olympus Corp
Original Assignee
Olympus 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 Olympus Corp filed Critical Olympus Corp
Priority to JP2014175411A priority Critical patent/JP5800970B2/en
Publication of JP2015008523A publication Critical patent/JP2015008523A/en
Application granted granted Critical
Publication of JP5800970B2 publication Critical patent/JP5800970B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Processing (AREA)
  • Facsimile Image Signal Circuits (AREA)
  • Studio Devices (AREA)

Description

本発明は、画像データに対して歪補正を行う技術に関する。   The present invention relates to a technique for performing distortion correction on image data.

デジタルカメラでは、撮影により得られたRAWデータに対して色再現やエッジ強調といった画像処理を行うことによって、見た目の印象に近い画像が撮影できる。また、レンズの光学特性に起因する歪や色収差を補正するための画像処理を行うことによって、歪や色収差の少ない画像を撮影できるカメラが知られている。特許文献1には、レンズの特性に合わせて画像データを部分的に拡大・縮小することによって、歪補正を行う画像処理装置が開示されている。   With a digital camera, an image close to the visual impression can be taken by performing image processing such as color reproduction and edge enhancement on the RAW data obtained by photographing. In addition, there is known a camera that can capture an image with less distortion and chromatic aberration by performing image processing for correcting distortion and chromatic aberration caused by optical characteristics of the lens. Patent Document 1 discloses an image processing apparatus that performs distortion correction by partially enlarging / reducing image data in accordance with lens characteristics.

特開2009−3953号公報JP 2009-3953 A

しかしながら、歪補正後の画像では、部分的に拡大された箇所のコントラストが他の箇所のコントラストに比べて低下するという問題があった。   However, the image after distortion correction has a problem that the contrast of a partially enlarged portion is lower than the contrast of other portions.

本発明は、上述した問題に鑑みてなされたものであり、レンズの光学歪特性に応じた歪を補正するとともに、歪補正後の画像における部分的なコントラストの低下を抑制する技術を提供することを目的とする。   The present invention has been made in view of the above-described problems, and provides a technique for correcting distortion according to the optical distortion characteristics of a lens and suppressing partial reduction in contrast in an image after distortion correction. With the goal.

本発明のある態様に係る画像処理装置は、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、前記画像データに対して、エッジ強調処理を施すエッジ強調部と、前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更する制御部と、を備え、前記制御部は、前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わない
本発明の別の態様に係る撮像装置は、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、前記画像データに対して、エッジ強調処理を施すエッジ強調部と、前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更する制御部と、を備え、前記制御部は、前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御する画像処理装置と、撮影レンズの周波数に応じたコントラスト特性を記憶する記憶部と、を備えた撮像装置であって、前記制御部は、前記記憶部に記憶されているコントラスト特性に応じて、前記エッジ強調処理を施す周波数帯域を変更し、静止画撮影時は、前記エッジ強調処理を施す周波数帯域とともに、エッジを強調する度合いを示すエッジ強調度を変更する処理を行い、動画撮影時は、前記エッジ強調処理を施す周波数帯域を変更する処理および前記エッジ強調度を変更する処理のうちのいずれか一方の処理を行う。
An image processing apparatus according to an aspect of the present invention performs distortion correction processing for correcting distortion by performing local enlargement processing or reduction processing according to the optical distortion characteristics of a lens used at the time of photographing on image data. A distortion correcting unit that performs edge enhancement on the image data, and a control unit that changes edge enhancement on the image data in accordance with the local enlargement or reduction process. The control unit emphasizes edges in the same frequency band in the image after the distortion correction processing and the edge enhancement processing according to the local enlargement processing or reduction processing, and provides partial contrast. and a reduction of suppression to control so as to approach uniform contrast, the local magnification and reduction ratio in the local enlargement processing or reduction processing, and finally If the maximum value of the product of the resizing ratio when enlarging or reducing the image data to an image size that is essential is less than a predetermined threshold, the process of changing the edge enhancement process is not performed.
An imaging apparatus according to another aspect of the present invention performs distortion correction processing for correcting distortion by performing local enlargement processing or reduction processing according to the optical distortion characteristics of a lens used at the time of imaging on image data. A distortion correcting unit that performs edge enhancement on the image data, and a control unit that changes edge enhancement on the image data in accordance with the local enlargement or reduction process. The control unit emphasizes edges in the same frequency band in the image after the distortion correction processing and the edge enhancement processing according to the local enlargement processing or reduction processing, and provides partial contrast. An image processing apparatus that controls the contrast so that the contrast is made close to uniform, and a storage unit that stores contrast characteristics according to the frequency of the photographing lens In the imaging apparatus, the control unit changes a frequency band on which the edge enhancement processing is performed according to a contrast characteristic stored in the storage unit, and the frequency at which the edge enhancement processing is performed during still image shooting. In addition to the band, a process for changing the edge enhancement degree indicating the degree of edge enhancement is performed. Either of these processes is performed.

本発明の別の態様に係る画像処理装置は、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、前記歪補正処理後の画像データに対して、エッジ強調処理を施すエッジ強調部と、前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更する制御部と、を備え、前記制御部は、前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わない
本発明の別の態様に係る撮像装置は、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、前記歪補正処理後の画像データに対して、エッジ強調処理を施すエッジ強調部と、前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更する制御部と、を備え、前記制御部は、前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御する画像処理装置と、撮影レンズの周波数に応じたコントラスト特性を記憶する記憶部と、を備えた撮像装置であって、前記制御部は、前記記憶部に記憶されているコントラスト特性に応じて、前記エッジ強調処理を施す周波数帯域を変更し、静止画撮影時は、前記エッジ強調処理を施す周波数帯域とともに、エッジを強調する度合いを示すエッジ強調度を変更する処理を行い、動画撮影時は、前記エッジ強調処理を施す周波数帯域を変更する処理および前記エッジ強調度を変更する処理のうちのいずれか一方の処理を行う。
An image processing apparatus according to another aspect of the present invention is a distortion correction that corrects distortion by performing local enlargement processing or reduction processing on image data according to the optical distortion characteristics of a lens used at the time of shooting. A distortion correction unit that performs processing, an edge enhancement unit that performs edge enhancement processing on the image data after the distortion correction processing, and the distortion correction processing according to the local enlargement processing or reduction processing A control unit that changes edge enhancement processing on the image data, and the control unit reduces a partial contrast in the image after the distortion correction processing according to the local enlargement processing or reduction processing. by suppressing, controlled to close uniformly contrast, image and local magnification and reduction ratio in the local enlargement processing or reduction processing, to the image size eventually needed If the maximum value of the product of the resizing ratio when enlarging or reducing the data is less than a predetermined threshold value, it does not perform the process for changing the edge enhancement processing.
An imaging apparatus according to another aspect of the present invention performs distortion correction processing for correcting distortion by performing local enlargement processing or reduction processing according to the optical distortion characteristics of a lens used at the time of imaging on image data. A distortion correction unit that performs image processing, an edge enhancement unit that performs edge enhancement processing on the image data after the distortion correction processing, and an image that has undergone the distortion correction processing according to the local enlargement processing or reduction processing A control unit that changes edge enhancement processing on data, and the control unit suppresses partial reduction in contrast in the image after the distortion correction processing according to the local enlargement processing or reduction processing. An image processing apparatus including an image processing apparatus that controls the contrast so as to approach the uniform and a storage unit that stores a contrast characteristic according to the frequency of the photographing lens. The unit changes the frequency band to which the edge enhancement processing is performed according to the contrast characteristics stored in the storage unit, and the degree of edge enhancement together with the frequency band to which the edge enhancement processing is performed during still image shooting In the moving image shooting, one of a process for changing the frequency band to which the edge enhancement process is performed and a process for changing the edge enhancement degree are performed.

本発明のさらに別の態様に係る画像処理方法は、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、前記画像データに対して、エッジ強調処理を施すステップと、前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更するステップと、を備え、前記エッジ強調処理を変更するステップでは、前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わないAccording to still another aspect of the present invention, there is provided an image processing method in which distortion is corrected by performing local enlargement processing or reduction processing on image data according to the optical distortion characteristics of a lens used during shooting. Performing a correction process; performing an edge enhancement process on the image data; and changing an edge enhancement process on the image data in accordance with the local enlargement process or reduction process. In the step of changing the edge enhancement processing, in the image after the distortion correction processing and the edge enhancement processing, edges in the same frequency band are emphasized according to the local enlargement processing or reduction processing, and are partially and suppressing a decrease in a contrast control so as to approach a uniform contrast, local in the local enlargement processing or reduction processing When the maximum value of the product of the enlargement ratio and the reduction ratio and the resizing ratio when the image data is enlarged or reduced to the finally required image size is equal to or smaller than a predetermined threshold value, the edge enhancement processing The process of changing is not performed .

本発明のさらに別の態様に係る画像処理方法は、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、前記歪補正処理後の画像データに対して、エッジ強調処理を施すステップと、前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更するステップと、を備え、前記エッジ強調処理を変更するステップでは、前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わない。 According to still another aspect of the present invention, there is provided an image processing method in which distortion is corrected by performing local enlargement processing or reduction processing on image data according to the optical distortion characteristics of a lens used during shooting. Performing a correction process; performing an edge enhancement process on the image data after the distortion correction process; and applying the distortion correction process to the image data subjected to the distortion correction process according to the local enlargement process or reduction process A step of changing an edge enhancement process, and in the step of changing the edge enhancement process, in the image after the distortion correction process, a partial reduction in contrast according to the local enlargement process or reduction process by suppressing, controlled to close uniformly contrast, a local magnification and reduction ratio in the local enlargement processing or reduction processing, the outermost Maximum value of the product of the resizing ratio when enlarging or reducing the image data to an image size that is to require in the case of less than a predetermined threshold value, does not perform the process for changing the edge enhancement processing.

本発明のさらに別の態様に係る画像処理プログラムは、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、前記画像データに対して、エッジ強調処理を施すステップと、前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更するステップと、をコンピュータに実行させる。前記エッジ強調処理を変更するステップでは、前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わない。 An image processing program according to still another aspect of the present invention is a distortion correcting image by performing local enlargement processing or reduction processing according to the optical distortion characteristics of a lens used at the time of photographing on image data. Performing a correction process; performing an edge enhancement process on the image data; and changing an edge enhancement process on the image data in accordance with the local enlargement process or reduction process. To run. In the step of changing the edge enhancement process, in the image after the distortion correction process and the edge enhancement process, an edge of the same frequency band is emphasized according to the local enlargement process or reduction process, Suppressing the decrease in contrast and controlling the contrast to be uniform, the image data to the local enlargement / reduction ratio in the local enlargement / reduction process, and finally to the required image size If the maximum value of the product with the resizing ratio when enlarging or reducing the size is equal to or smaller than a predetermined threshold value, the processing for changing the edge enhancement processing is not performed.

本発明のさらに別の態様に係る画像処理プログラムは、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、前記歪補正処理後の画像データに対して、エッジ強調処理を施すステップと、前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更するステップと、をコンピュータに実行させる。前記エッジ強調処理を変更するステップでは、前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わない。 An image processing program according to still another aspect of the present invention is a distortion correcting image by performing local enlargement processing or reduction processing according to the optical distortion characteristics of a lens used at the time of photographing on image data. Performing a correction process; performing an edge enhancement process on the image data after the distortion correction process; and applying the distortion correction process to the image data subjected to the distortion correction process according to the local enlargement process or reduction process And causing the computer to execute the step of changing the edge enhancement processing. In the step of changing the edge enhancement processing, in the image after the distortion correction processing, a reduction in partial contrast is suppressed in accordance with the local enlargement processing or reduction processing so that the contrast is made closer to uniform. The maximum value of the product of the local enlargement ratio and reduction ratio in the local enlargement process or reduction process and the resizing ratio when the image data is enlarged or reduced to the finally required image size. If is less than or equal to a predetermined threshold value, the edge enhancement process is not changed.

本発明によれば、歪補正後の画像における部分的なコントラストの低下を抑制することができる。   According to the present invention, a partial reduction in contrast in an image after distortion correction can be suppressed.

第1の実施形態における画像処理装置を適用したデジタルスチルカメラの構成を示すブロック図である。It is a block diagram which shows the structure of the digital still camera to which the image processing apparatus in 1st Embodiment is applied. 第1の実施形態に係る画像処理装置を適用したデジタルスチルカメラで行われるメインの処理フローを示すフローチャートである。6 is a flowchart illustrating a main processing flow performed by the digital still camera to which the image processing apparatus according to the first embodiment is applied. 静止画撮影・画像処理の詳細を示すフローチャートである。It is a flowchart which shows the detail of still image photography and image processing. 動画撮影・画像処理の詳細を示すフローチャートである。It is a flowchart which shows the detail of video recording and image processing. 現像処理の詳細を示すフローチャートである。It is a flowchart which shows the detail of a developing process. エッジ強調処理の詳細を示すフローチャートである。It is a flowchart which shows the detail of an edge emphasis process. 交換式レンズの歪特性の一例を示す図である。It is a figure which shows an example of the distortion characteristic of an interchangeable lens. 交換式レンズのMTF特性の一例、および、MTF特性に基づいて算出したコントラスト特性の一例を示す図である。It is a figure which shows an example of the MTF characteristic of an interchangeable lens, and an example of the contrast characteristic calculated based on the MTF characteristic. エッジ抽出帯域の補正方法を説明するための図である。It is a figure for demonstrating the correction method of an edge extraction zone | band. 歪補正後のコントラスト特性の算出方法を説明するための図である。It is a figure for demonstrating the calculation method of the contrast characteristic after distortion correction. 第2の実施形態における画像処理装置を適用したデジタルスチルカメラの構成を示すブロック図である。It is a block diagram which shows the structure of the digital still camera to which the image processing apparatus in 2nd Embodiment is applied. 第2の実施形態における画像処理装置による現像処理の詳細を示すフローチャートである。12 is a flowchart illustrating details of development processing by the image processing apparatus according to the second embodiment. 第2の実施形態において、エッジ強調処理の詳細を示すフローチャートである。12 is a flowchart illustrating details of edge enhancement processing in the second embodiment. 求めたコントラストが所定のコントラスト下限値未満の場合におけるエッジ抽出帯域の算出方法を説明するための図である。It is a figure for demonstrating the calculation method of the edge extraction zone | band when the calculated | required contrast is less than a predetermined contrast lower limit. 求めたコントラストが所定のコントラスト上限値よりも大きい場合におけるエッジ抽出帯域の算出方法を説明するための図である。It is a figure for demonstrating the calculation method of the edge extraction zone | band when the calculated | required contrast is larger than a predetermined contrast upper limit. 拡大率に応じて歪補正を行った後のコントラスト特性に基づいて、エッジ強調度を算出する方法を説明するための図である。It is a figure for demonstrating the method of calculating an edge emphasis degree based on the contrast characteristic after performing distortion correction according to an enlarging rate. 縮小率に応じて歪補正を行った後のコントラスト特性に基づいて、エッジ強調度を算出する方法を説明するための図である。It is a figure for demonstrating the method of calculating an edge emphasis degree based on the contrast characteristic after performing distortion correction according to the reduction rate. 第3の実施形態において、エッジ強調処理の詳細を示すフローチャートである。12 is a flowchart illustrating details of edge enhancement processing in the third embodiment. 第4の実施形態において、エッジ強調処理の詳細を示すフローチャートである。14 is a flowchart illustrating details of edge enhancement processing in the fourth embodiment.

<第1の実施形態>
図1は、第1の実施形態における画像処理装置を適用したデジタルスチルカメラの構成を示すブロック図である。図1に示すデジタルスチルカメラは、カメラ本体1と交換式レンズ2から構成される。
<First Embodiment>
FIG. 1 is a block diagram illustrating a configuration of a digital still camera to which the image processing apparatus according to the first embodiment is applied. The digital still camera shown in FIG. 1 includes a camera body 1 and an interchangeable lens 2.

交換式レンズ2は、レンズ1010と、Flashメモリ1011と、マイクロコンピュータ1012と、ドライバ1013と、絞り1014と、を有している。交換式レンズ2は、I/F999を介して、カメラ本体1と通信可能に接続されている。   The interchangeable lens 2 includes a lens 1010, a flash memory 1011, a microcomputer 1012, a driver 1013, and a diaphragm 1014. The interchangeable lens 2 is communicably connected to the camera body 1 via the I / F 999.

カメラ本体1は、メカシャッター101と、撮像素子102と、アナログ処理部103と、アナログ/デジタル変換部104(以下、A/D変換部104)と、バス105と、SDRAM106と、画像処理部107と、AE処理部108と、AF処理部109と、画像圧縮展開部110と、メモリインターフェース111(以下、メモリI/F111)と、記録媒体112と、LCDドライバ113と、LCD114と、マイクロコンピュータ115と、操作部116と、Flashメモリ117と、を有している。   The camera body 1 includes a mechanical shutter 101, an image sensor 102, an analog processing unit 103, an analog / digital conversion unit 104 (hereinafter referred to as A / D conversion unit 104), a bus 105, an SDRAM 106, and an image processing unit 107. An AE processing unit 108, an AF processing unit 109, an image compression / decompression unit 110, a memory interface 111 (hereinafter referred to as a memory I / F 111), a recording medium 112, an LCD driver 113, an LCD 114, and a microcomputer 115. And an operation unit 116 and a flash memory 117.

レンズ1010は、被写体の光学像を撮像素子102に集光させる。レンズ1010は、単焦点レンズであってもよいし、ズームレンズであってもよい。   The lens 1010 focuses the optical image of the subject on the image sensor 102. The lens 1010 may be a single focus lens or a zoom lens.

マイクロコンピュータ1012は、I/F999、Flashメモリ1011、および、ドライバ1013と接続されていて、Flashメモリ1011に記憶されている情報の読み込み・書き込みを行うとともに、ドライバ1013を制御する。Flashメモリ1011に記憶されている情報には、交換式レンズ2の焦点距離およびフォーカス位置に応じた歪特性のデータ、および、交換式レンズ2のMTF(Modulation Transfer Function)特性のデータなどが含まれる。   The microcomputer 1012 is connected to the I / F 999, the flash memory 1011 and the driver 1013. The microcomputer 1012 reads and writes information stored in the flash memory 1011 and controls the driver 1013. The information stored in the flash memory 1011 includes data on distortion characteristics corresponding to the focal length and focus position of the interchangeable lens 2, data on MTF (Modulation Transfer Function) characteristics of the interchangeable lens 2, and the like. .

マイクロコンピュータ1012は、さらに、I/F999を介して、マイクロコンピュータ115と通信することができ、様々な情報をマイクロコンピュータ115へ送信し、また、マイクロコンピュータ115から絞り値等の情報を受信する。   The microcomputer 1012 can further communicate with the microcomputer 115 via the I / F 999, transmits various information to the microcomputer 115, and receives information such as an aperture value from the microcomputer 115.

ドライバ1013は、マイクロコンピュータ1012の指示を受けて、レンズ1010を駆動させて、焦点距離やフォーカス位置の変更を行うとともに、絞り1014を駆動する。絞り1014は、レンズ1010の近傍に設けられ、被写体の光量を調節する。   In response to an instruction from the microcomputer 1012, the driver 1013 drives the lens 1010 to change the focal length and focus position, and drives the aperture 1014. The aperture 1014 is provided in the vicinity of the lens 1010 and adjusts the amount of light of the subject.

メカシャッター101は、マイクロコンピュータ115の指示を受けて駆動し、撮像素子102に被写体を露光する時間を制御する。   The mechanical shutter 101 is driven in response to an instruction from the microcomputer 115 to control the time for exposing the subject to the image sensor 102.

撮像素子102は、各画素を構成するフォトダイオードの前面に、ベイヤー配列のカラーフィルタが配置された撮像素子である。ベイヤー配列は、水平方向にR画素とG(Gr)画素が交互に配置されたラインと、G(Gb)画素とB画素が交互に配置されたラインとを有し、さらにその2つのラインを垂直方向にも交互に配置することで構成されている。この撮像素子102は、レンズ1010により集光された光を、画素を構成するフォトダイオードで受光して光電変換することで、光の量を電荷量としてアナログ処理部103へ出力する。なお、撮像素子102は、CMOS方式のものでもCCD方式のものでも良い。   The image sensor 102 is an image sensor in which a Bayer array color filter is arranged in front of a photodiode constituting each pixel. The Bayer array has a line in which R pixels and G (Gr) pixels are alternately arranged in a horizontal direction, and a line in which G (Gb) pixels and B pixels are alternately arranged, and the two lines are further divided. It is configured by alternately arranging in the vertical direction. The imaging element 102 receives the light collected by the lens 1010 by a photodiode that constitutes a pixel and performs photoelectric conversion, and outputs the amount of light to the analog processing unit 103 as a charge amount. The image sensor 102 may be a CMOS type or a CCD type.

アナログ処理部103は、撮像素子102から読み出された電気信号(アナログ画像信号)に対し、リセットノイズ等を低減した上で波形整形を行い、さらに目的の明るさとなるように、ゲインアップを行う。A/D変換部104は、アナログ処理部103から出力されたアナログ画像信号をデジタル画像信号(以後、画像データという)に変換する。   The analog processing unit 103 performs waveform shaping on the electrical signal (analog image signal) read from the image sensor 102 while reducing reset noise and the like, and further increases the gain so that the target brightness is obtained. . The A / D conversion unit 104 converts the analog image signal output from the analog processing unit 103 into a digital image signal (hereinafter referred to as image data).

バス105は、デジタルカメラ内部で発生した各種データをデジタルカメラ内の各部に転送するための転送路である。バス105は、A/D変換部104と、SDRAM106と、画像処理部107と、AE処理部108と、AF処理部109と、画像圧縮展開部110と、メモリI/F111と、LCDドライバ113と、マイクロコンピュータ115に接続されている。   A bus 105 is a transfer path for transferring various data generated in the digital camera to each unit in the digital camera. The bus 105 includes an A / D conversion unit 104, an SDRAM 106, an image processing unit 107, an AE processing unit 108, an AF processing unit 109, an image compression / decompression unit 110, a memory I / F 111, an LCD driver 113, and the like. Are connected to the microcomputer 115.

A/D変換部104から出力される画像データは、バス105を介して一旦SDRAM106に記憶される。SDRAM106は、A/D変換部104において得られた画像データや、画像処理部107、画像圧縮展開部110において処理された画像データ等の各種データが一時的に記憶される記憶部である。   The image data output from the A / D conversion unit 104 is temporarily stored in the SDRAM 106 via the bus 105. The SDRAM 106 is a storage unit that temporarily stores various data such as image data obtained by the A / D conversion unit 104 and image data processed by the image processing unit 107 and the image compression / decompression unit 110.

画像処理部107は、オプティカルブラック減算部1071(以下、OB減算部1071)、ホワイトバランス補正部1072(以下、WB補正部1072)、同時化処理部1073、カラーマトリクス演算部1074、ガンマ・色再現処理部1075、エッジ強調処理部1076、ノイズ低減処理部1077(以下、NR処理部1077)、および、歪補正部1078を含み、SDRAM106から読み出した画像データに対して様々な画像処理を施す。   The image processing unit 107 includes an optical black subtraction unit 1071 (hereinafter referred to as OB subtraction unit 1071), a white balance correction unit 1072 (hereinafter referred to as WB correction unit 1072), a synchronization processing unit 1073, a color matrix calculation unit 1074, a gamma / color reproduction. A processing unit 1075, an edge enhancement processing unit 1076, a noise reduction processing unit 1077 (hereinafter referred to as NR processing unit 1077), and a distortion correction unit 1078 are included, and various image processing is performed on the image data read from the SDRAM 106.

OB減算部1071は、画像データに対して、オプティカルブラック減算処理(以下、OB減算処理)を行う。OB減算処理は、画像データを構成する各画素の画素値から、撮像素子102の暗電流等に起因するオプティカルブラック値(以下、OB値)を減算する処理である。   The OB subtraction unit 1071 performs optical black subtraction processing (hereinafter referred to as OB subtraction processing) on the image data. The OB subtraction process is a process of subtracting an optical black value (hereinafter referred to as an OB value) caused by a dark current of the image sensor 102 from a pixel value of each pixel constituting image data.

WB補正部1072は、画像データに対して、ホワイトバランスモードに応じたホワイトバランスゲインを乗じて、ホワイトバランスを補正する処理を行う。ホワイトバランスモードは、晴天、曇天、電球、蛍光灯などの光源に応じて、ユーザが設定可能である。   The WB correction unit 1072 performs a process of correcting the white balance by multiplying the image data by a white balance gain corresponding to the white balance mode. The white balance mode can be set by the user in accordance with a light source such as sunny weather, cloudy weather, a light bulb, and a fluorescent light.

同時化処理部1073は、ベイヤー配列による画像データから、1画素あたりR、G、Bの情報からなる画像データへ同時化する処理を行う。カラーマトリクス演算部1074は、画像データに対して、カラーマトリクス係数を乗じる線形変換を行って、画像データの色を補正する。ガンマ・色再現処理部1075は、ガンマ補正処理、および、画像の色味を変化させる色再現処理を行う。   The synchronization processing unit 1073 performs a process of synchronizing image data based on the Bayer array into image data including R, G, and B information per pixel. The color matrix calculation unit 1074 corrects the color of the image data by performing linear conversion on the image data by multiplying the color matrix coefficient. The gamma / color reproduction processing unit 1075 performs gamma correction processing and color reproduction processing for changing the color of an image.

エッジ強調処理部1076は、バンドパスフィルタを用いて、画像データからエッジ成分を抽出し、抽出したエッジ成分のデータに、エッジ強調度に応じた係数を乗じてから、画像データに加算することにより、画像データのエッジを強調する処理を行う。   The edge enhancement processing unit 1076 uses a bandpass filter to extract edge components from the image data, multiply the extracted edge component data by a coefficient corresponding to the degree of edge enhancement, and then add it to the image data. Then, processing for enhancing the edge of the image data is performed.

NR処理部1077は、高周波を低減するフィルタを用いた処理や、コアリング処理等により、ノイズを低減する処理を行う。   The NR processing unit 1077 performs processing for reducing noise by processing using a filter that reduces high frequency, coring processing, and the like.

歪補正部1078は、交換式レンズ2の歪特性に基づいて、画像を部分的に拡大・縮小することによって、歪を補正する処理を行う。なお、レンズの歪特性に基づいて、画像を部分的に拡大・縮小することによって歪を補正する処理は、公知の処理である。   The distortion correction unit 1078 performs a process of correcting the distortion by partially enlarging / reducing the image based on the distortion characteristics of the interchangeable lens 2. The process for correcting the distortion by partially enlarging / reducing the image based on the distortion characteristics of the lens is a known process.

画像処理部107によって各処理が行われた後の画像データは、SDRAM106に記憶される。   The image data after each processing is performed by the image processing unit 107 is stored in the SDRAM 106.

AE処理部108は、画像データから被写体輝度を算出する。被写体輝度を算出するためのデータは、専用の測光センサの出力であってもよい。AF処理部109は、画像データから高周波成分の信号を取り出し、AF(Auto Focus)積算処理により、合焦評価値を取得する。   The AE processing unit 108 calculates subject luminance from the image data. The data for calculating the subject brightness may be an output of a dedicated photometric sensor. The AF processing unit 109 extracts a high-frequency component signal from the image data, and acquires a focus evaluation value by AF (Auto Focus) integration processing.

画像圧縮展開部110は、静止画像データの記録時には、SDRAM106から画像データを読み出し、読み出した画像データをJPEG圧縮方式に従って圧縮して、圧縮したJPEG画像データを、SDRAM106に一旦記憶する。マイクロコンピュータ115は、SDRAM106に記憶されたJPEG画像データに対して、JPEGファイルを構成するために必要なJPEGヘッダを付加してJPEGファイルを作成し、作成したJPEGファイルを、メモリI/F111を介して記録媒体112に記録する。   When still image data is recorded, the image compression / decompression unit 110 reads the image data from the SDRAM 106, compresses the read image data according to the JPEG compression method, and temporarily stores the compressed JPEG image data in the SDRAM 106. The microcomputer 115 creates a JPEG file by adding a JPEG header necessary for constructing a JPEG file to the JPEG image data stored in the SDRAM 106, and sends the created JPEG file via the memory I / F 111. To the recording medium 112.

画像圧縮展開部110は、また、動画データの記録時には、SDRAM106から動画データを読み出し、読み出した動画データを、例えば、H.264方式に従って圧縮して、圧縮した動画データをSDRAM106に一旦記憶する。画像圧縮展開部110は、さらに、マイクロコンピュータ115からの指令に基づいて、圧縮データを展開(伸長)する処理を行う。   The image compressing / decompressing unit 110 also reads out the moving image data from the SDRAM 106 when recording the moving image data. The compressed moving image data is temporarily stored in the SDRAM 106 after being compressed according to the H.264 system. The image compression / decompression unit 110 further performs a process of decompressing (decompressing) the compressed data based on a command from the microcomputer 115.

記録媒体112は、例えばカメラ本体1に着脱可能なメモリカードからなる記録媒体であるが、これに限定されるものではない。   The recording medium 112 is, for example, a recording medium including a memory card that can be attached to and detached from the camera body 1, but is not limited thereto.

LCDドライバ113は、LCD114に画像を表示させる。画像の表示には、撮影直後の画像データを短時間だけ表示するレックビュー表示、記録媒体112に記録されたJPEGファイルの再生表示、および、ライブビュー表示等の動画の表示が含まれる。記録媒体112に記録された圧縮データを再生する場合、画像圧縮展開部110は、記録媒体112に記録されている圧縮データを読み出して展開(伸長)処理を施した上で、展開したデータを一旦SDRAM106に記憶させる。LCDドライバ113は、伸張されたデータをSDRAM106から読み出し、読み出したデータを映像信号へ変換した後でLCD114へ出力して表示を行う。   The LCD driver 113 displays an image on the LCD 114. Display of images includes display of moving images such as REC view display that displays image data immediately after shooting for a short time, playback display of a JPEG file recorded on the recording medium 112, and live view display. When reproducing the compressed data recorded on the recording medium 112, the image compression / decompression unit 110 reads out the compressed data recorded on the recording medium 112, performs decompression (decompression) processing, and then temporarily decompresses the decompressed data. It is stored in the SDRAM 106. The LCD driver 113 reads the decompressed data from the SDRAM 106, converts the read data into a video signal, and then outputs it to the LCD 114 for display.

制御部としての機能を有するマイクロコンピュータ115は、デジタルカメラ本体1の各種シーケンスを統括的に制御する。マイクロコンピュータ115には、操作部116およびFlashメモリ117が接続されている。   The microcomputer 115 having a function as a control unit comprehensively controls various sequences of the digital camera body 1. An operation unit 116 and a flash memory 117 are connected to the microcomputer 115.

操作部116は、電源ボタン、レリーズボタン、動画ボタン、各種入力キー等の操作部材である。ユーザによって、操作部116の何れかの操作部材が操作されることにより、マイクロコンピュータ115は、ユーザの操作に応じた各種シーケンスを実行する。電源ボタンは、当該デジタルカメラの電源のオン/オフ指示を行うための操作部材である。電源ボタンが押されると、当該デジタルカメラの電源がオンとなる。再度、電源ボタンが押されると当該デジタルカメラの電源はオフとなる。レリーズボタンは、ファーストレリーズスイッチとセカンドレリーズスイッチの2段スイッチを有して構成されている。レリーズボタンが半押しされて、ファーストレリーズスイッチがオンされた場合に、マイクロコンピュータ115は、AE処理やAF処理等の撮影準備シーケンスを行う。また、レリーズボタンが全押しされて、セカンドレリーズスイッチがオンされた場合に、マイクロコンピュータ115は、撮影シーケンスを実行して撮影を行う。   The operation unit 116 is an operation member such as a power button, a release button, a moving image button, and various input keys. When one of the operation members of the operation unit 116 is operated by the user, the microcomputer 115 executes various sequences according to the user's operation. The power button is an operation member for instructing power on / off of the digital camera. When the power button is pressed, the power of the digital camera is turned on. When the power button is pressed again, the digital camera is turned off. The release button has a two-stage switch of a first release switch and a second release switch. When the release button is pressed halfway and the first release switch is turned on, the microcomputer 115 performs a shooting preparation sequence such as AE processing and AF processing. Further, when the release button is fully pressed and the second release switch is turned on, the microcomputer 115 performs shooting by executing a shooting sequence.

動画ボタンは、動画の撮影を開始させ、また終了させるためのボタンである。初期状態では動画未撮影状態であるので、この状態で動画ボタンを押すと動画の撮影を開始し、動画撮影中に動画ボタンを押すと、動画の撮影を終了する。従って、動画ボタンを押すたびに、動画の撮影開始と終了を交互に繰り返す。   The movie button is a button for starting and ending movie shooting. Since the moving image is not yet shot in the initial state, when the moving image button is pressed in this state, moving image shooting starts. When the moving image button is pressed during moving image shooting, moving image shooting ends. Therefore, each time the moving image button is pressed, the start and end of moving image shooting are repeated alternately.

Flashメモリ117は、ホワイトバランスモードに応じたホワイトバランスゲインやカラーマトリクス係数、ローパスフィルタ係数等のデジタルカメラの動作に必要な各種パラメータ、および、デジタルスチルカメラを特定するための製造番号などを記憶している。また、Flashメモリ117は、マイクロコンピュータ115にて実行する各種プログラムも記憶している。マイクロコンピュータ115は、Flashメモリ117に記憶されているプログラムに従い、またFlashメモリ117から各種シーケンスに必要なパラメータを読み込み、各処理を実行する。   The flash memory 117 stores various parameters necessary for the operation of the digital camera such as a white balance gain, a color matrix coefficient, and a low-pass filter coefficient according to the white balance mode, and a manufacturing number for specifying the digital still camera. ing. The flash memory 117 also stores various programs executed by the microcomputer 115. The microcomputer 115 reads parameters necessary for various sequences from the flash memory 117 according to a program stored in the flash memory 117, and executes each process.

図2は、第1の実施形態に係る画像処理装置を適用したデジタルスチルカメラで行われるメインの処理フローを示すフローチャートである。ユーザにより電源ボタンが押されて、デジタルスチルカメラの電源がオンになると、マイクロコンピュータ115は、ステップS201の処理を開始する。   FIG. 2 is a flowchart illustrating a main processing flow performed by the digital still camera to which the image processing apparatus according to the first embodiment is applied. When the user presses the power button to turn on the digital still camera, the microcomputer 115 starts the process of step S201.

ステップS201では、記録中フラグをオフに初期化する。記録中フラグは、動画撮影中にオン、動画を撮影していない時にオフとなるフラグである。   In step S201, the recording flag is initialized to off. The recording flag is a flag that is turned on during moving image shooting and turned off when no moving image is shot.

ステップS202では、ユーザによって、動画ボタンが操作されたか否かを判定する。動画ボタンが操作されたと判定するとステップS203に進み、操作されていないと判定すると、ステップS204に進む。   In step S202, it is determined whether or not the moving image button has been operated by the user. If it is determined that the movie button has been operated, the process proceeds to step S203. If it is determined that the movie button has not been operated, the process proceeds to step S204.

ステップS203では、記録中フラグを反転させて、ステップS204に進む。前述したように、動画ボタンは押されるたびに、動画撮影開始と終了を交互に繰り返すので、このステップでは、記録中フラグがオフであった場合にはオンに、またオンであった場合にはオフに、記録中フラグを反転させる。   In step S203, the recording flag is reversed, and the process proceeds to step S204. As described above, every time the video button is pressed, the video recording start and end are alternately repeated. Therefore, in this step, if the recording flag is off, it is on, and if it is on, Turn off and invert the recording flag.

ステップS204では、記録中フラグがオンであるか否かを判定する。記録中フラグがオンであると判定すると、ステップS209に進む。ステップS209では、動画記録中であると判定すると、撮像素子102からの画像信号に基づく動画の画像データについて画像処理および画像圧縮を行った後、記録媒体112に記録する。また、動画記録中ではないと判定すると、静止画撮影における被写体構図やシャッタタイミングの決定を行うためのライブビュー表示を行う。ステップS209のライブビュー表示・動画撮影・画像処理の詳細については、図4を用いて後述する。   In step S204, it is determined whether the recording flag is on. If it is determined that the recording flag is on, the process proceeds to step S209. If it is determined in step S209 that a moving image is being recorded, the image data of the moving image based on the image signal from the image sensor 102 is subjected to image processing and image compression, and then recorded on the recording medium 112. If it is determined that the moving image recording is not in progress, a live view display for determining a subject composition and shutter timing in still image shooting is performed. Details of live view display, moving image shooting, and image processing in step S209 will be described later with reference to FIG.

一方、ステップS204において、記録中フラグがオフであると判定すると、ステップS205に進む。ステップS205では、ユーザによってレリーズボタンが半押しされて、ファーストレリーズスイッチがオンされたか否かを判定する。ファーストレリーズスイッチがオンされたと判定すると、ステップS206に進む。   On the other hand, if it is determined in step S204 that the recording flag is off, the process proceeds to step S205. In step S205, it is determined whether or not the user has pressed the release button halfway to turn on the first release switch. If it is determined that the first release switch is turned on, the process proceeds to step S206.

ステップS206では、AF処理を行う。具体的には、まず、AF処理部109において、合焦評価値を算出する。マイクロコンピュータ115は、合焦評価値に基づいて、レンズ1010を駆動させる指令をドライバ1013に出す。ドライバ1013は、この指令に基づいて、レンズ1010を駆動させて、焦点距離やフォーカス位置の変更を行う。   In step S206, AF processing is performed. Specifically, first, the AF processing unit 109 calculates a focus evaluation value. The microcomputer 115 issues a command for driving the lens 1010 to the driver 1013 based on the focus evaluation value. Based on this command, the driver 1013 drives the lens 1010 to change the focal length and the focus position.

ステップS205において、ファーストレリーズスイッチがオンされなかった場合、または、ファーストレリーズスイッチがオンされたままの状態の場合には、ステップS207に進む。ステップS207では、ユーザによってレリーズボタンが全押しされて、セカンドレリーズスイッチがオンされたか否かを判定する。セカンドレリーズスイッチがオンされたと判定するとステップS208に進み、セカンドレリーズスイッチがオンされないと判定すると、ステップS209に進む。   If the first release switch is not turned on in step S205, or if the first release switch remains on, the process proceeds to step S207. In step S207, it is determined whether or not the user has fully pressed the release button to turn on the second release switch. If it is determined that the second release switch is turned on, the process proceeds to step S208. If it is determined that the second release switch is not turned on, the process proceeds to step S209.

ステップS208では、静止画撮影・画像処理を行う。静止画撮影・画像処理の詳細については、図3を用いて後述する。   In step S208, still image shooting and image processing are performed. Details of the still image shooting / image processing will be described later with reference to FIG.

ステップS210では、デジタルスチルカメラの電源がオフされたか否かを判定する。電源がオフされていないと判定すると、ステップS202に戻り、上述した処理を行う。一方、ユーザにより電源ボタンが押されて、電源がオフされると、フローチャートの処理を終了する。   In step S210, it is determined whether the power of the digital still camera is turned off. If it is determined that the power is not turned off, the process returns to step S202, and the above-described processing is performed. On the other hand, when the power button is pressed by the user and the power is turned off, the process of the flowchart is ended.

このように、本実施形態におけるメインフローでは、初期設定では静止画撮影モードになっており、この状態では、ステップS202→S204→S205→S207→S209→S210→S202を順次実行し、この間ライブビュー表示を行う。ライブビュー表示中に、レリーズボタンが半押しされると、ステップS206においてAF動作を行い、またレリーズボタンが全押しされると、ステップS208において静止画の撮影を行う。また、動画ボタンを押すと、ステップS203において記録中フラグをオンとし、ステップS204→S209→S210→S202→S204を繰り返し実行することにより、動画撮影を継続する。この状態で再度、動画ボタンを押すと、ステップS203において記録中フラグがオフとなることから、前述の静止画のフローに戻る。   As described above, in the main flow in the present embodiment, the still image shooting mode is set in the initial setting, and in this state, steps S202 → S204 → S205 → S207 → S209 → S210 → S202 are sequentially executed during this time. Display. If the release button is pressed halfway during live view display, an AF operation is performed in step S206, and if the release button is fully pressed, a still image is shot in step S208. When the moving image button is pressed, the recording flag is turned on in step S203, and moving image shooting is continued by repeatedly executing steps S204 → S209 → S210 → S202 → S204. If the moving image button is pressed again in this state, the recording flag is turned off in step S203, and the flow returns to the still image flow described above.

図3は、図2に示すフローチャートのステップS208の処理、すなわち、静止画撮影・画像処理の詳細を示すフローチャートである。   FIG. 3 is a flowchart showing details of the process in step S208 of the flowchart shown in FIG. 2, that is, the still image shooting / image processing.

ステップS310では、AE処理を行う。具体的には、AE処理部108において、被写体輝度を算出し、算出した被写体輝度に基づいて、Flashメモリ117に記憶されている露出条件決定テーブルを参照することにより、撮影時のISO感度、絞り、およびシャッター速を決定する。   In step S310, AE processing is performed. Specifically, the AE processing unit 108 calculates subject brightness, and refers to the exposure condition determination table stored in the flash memory 117 based on the calculated subject brightness, so that the ISO sensitivity at the time of shooting, the aperture , And determine the shutter speed.

ステップS320では、撮影を行う。撮影(静止画撮影)に関しては、従来から用いられている手法と同様である。ドライバ1013は、マイクロコンピュータ1012の指示に基づいて、設定された絞り値になるように絞り1014を駆動させる。そして、決定したシャッター速に基づいて、メカシャッター101を制御して撮影を行い、決定したISO感度に応じた画像データを得る。   In step S320, shooting is performed. The shooting (still image shooting) is the same as a conventionally used method. The driver 1013 drives the aperture 1014 so as to achieve a set aperture value based on an instruction from the microcomputer 1012. Then, based on the determined shutter speed, shooting is performed by controlling the mechanical shutter 101 to obtain image data corresponding to the determined ISO sensitivity.

ステップS330では、ステップS320の撮影で得られた画像データ(ベイヤーデータ)に対して様々な画像処理を施して、輝度(Y)および色差(Cb、Cr)信号データに変換する現像処理を行う。現像処理の詳細については、図5を用いて後述する。   In step S330, various image processes are performed on the image data (Bayer data) obtained in step S320 to perform development processing for conversion into luminance (Y) and color difference (Cb, Cr) signal data. Details of the development processing will be described later with reference to FIG.

ステップS340では、画像圧縮展開部110において、画像データに対して、JPEG圧縮を行い、画像サイズや撮影条件などのヘッダ情報を付加して、JPEGファイルを生成する。   In step S340, the image compression / decompression unit 110 performs JPEG compression on the image data, adds header information such as the image size and shooting conditions, and generates a JPEG file.

ステップS350では、ステップS340で生成したJPEGファイルを、メモリI/F111を介して記録媒体112に記録する。   In step S350, the JPEG file generated in step S340 is recorded on the recording medium 112 via the memory I / F 111.

図4は、図2に示すフローチャートのステップS209の処理、すなわち、ライブビュー表示・動画撮影・画像処理の詳細を示すフローチャートである。   FIG. 4 is a flowchart showing details of the process in step S209 of the flowchart shown in FIG. 2, that is, details of live view display / moving image capturing / image processing.

ステップS410では、AE処理を行う。この処理は、図3に示すフローチャートのステップS310の処理と同じである。   In step S410, an AE process is performed. This process is the same as the process of step S310 in the flowchart shown in FIG.

ステップS420では、撮影を行う。撮影(動画撮影)に関しては、従来から用いられている手法と同様である。すなわち、決定した絞り、シャッター速、ISO感度に基づいて、いわゆる電子シャッターを制御して撮影を行う。   In step S420, shooting is performed. The shooting (moving image shooting) is the same as a conventionally used method. That is, shooting is performed by controlling a so-called electronic shutter based on the determined aperture, shutter speed, and ISO sensitivity.

ステップS430では、ステップS420の撮影で得られた画像データ(ベイヤーデータ)に対して様々な画像処理を施して、輝度(Y)および色差(Cb、Cr)信号データに変換する現像処理を行う。現像処理の詳細については、図5を用いて後述する。   In step S430, various image processing is performed on the image data (Bayer data) obtained in step S420 to perform development processing for conversion into luminance (Y) and color difference (Cb, Cr) signal data. Details of the development processing will be described later with reference to FIG.

ステップS440では、LCDドライバ113により、画像データをLCD114に表示させる。この表示は、いわゆるライブビュー表示である。   In step S440, the LCD driver 113 displays image data on the LCD 114. This display is a so-called live view display.

ステップS450では、動画が記録中であるか否かを判定する。記録中フラグがオフの場合には、動画記録中ではないと判定して、本フローチャートの処理を終了し、記録中フラグがオンの場合には、動画記録中であると判定して、ステップS460に進む。   In step S450, it is determined whether a moving image is being recorded. If the recording flag is off, it is determined that the moving image is not being recorded, and the processing of this flowchart is terminated. If the recording flag is on, it is determined that the moving image is being recorded, and step S460 is performed. Proceed to

ステップS460では、動画ファイルを生成して、記録媒体112に記録する。すなわち、画像圧縮展開部110において、画像データに対して、動画ファイルの形式に応じた圧縮を行い、所定のヘッダ情報を付加して、動画ファイルを生成する。動画ファイルの圧縮形式には、「H.264」、「Motion JPEG」、「MPEG」などがある。そして、生成した動画ファイルを、メモリI/F111を介して記録媒体112に記録する。   In step S460, a moving image file is generated and recorded on the recording medium 112. That is, the image compression / decompression unit 110 compresses the image data according to the format of the moving image file, adds predetermined header information, and generates a moving image file. The compression format of the moving image file includes “H.264”, “Motion JPEG”, “MPEG”, and the like. Then, the generated moving image file is recorded on the recording medium 112 via the memory I / F 111.

図5は、図3に示すフローチャートのステップS330の処理、および、図4に示すフローチャートのステップS430の処理、すなわち、現像処理の詳細を示すフローチャートである。   FIG. 5 is a flowchart showing details of the process in step S330 in the flowchart shown in FIG. 3 and the process in step S430 in the flowchart shown in FIG. 4, that is, the development process.

ステップS510では、OB減算部1071により、撮影により得られた画像データから、撮像時に得られたOB値を減算するOB減算処理を施す。   In step S510, the OB subtraction unit 1071 performs OB subtraction processing for subtracting the OB value obtained at the time of imaging from the image data obtained by imaging.

ステップS520では、WB補正部1072により、OB減算処理が施された画像データに対して、ホワイトバランスモードに応じたホワイトバランスゲインを乗じて、ホワイトバランスを補正する処理を行う。なお、ホワイトバランスモードは、ユーザが操作部116に含まれる入力キーを操作することによって、1回の撮影ごとに設定することができる。マイクロコンピュータ115は、ユーザによる操作部116の操作に基づいて、ホワイトバランスモードを設定する。また、デジタルスチルカメラがホワイトバランスを自動的に調整するオートホワイトバランス機能を備えている場合、マイクロコンピュータ115は、撮影時の光源に応じたホワイトバランスモードを自動的に設定する。   In step S520, the WB correction unit 1072 performs a process of correcting the white balance by multiplying the image data subjected to the OB subtraction process by a white balance gain according to the white balance mode. Note that the white balance mode can be set for each shooting by the user operating an input key included in the operation unit 116. The microcomputer 115 sets the white balance mode based on the operation of the operation unit 116 by the user. When the digital still camera has an auto white balance function that automatically adjusts the white balance, the microcomputer 115 automatically sets a white balance mode in accordance with the light source at the time of shooting.

ステップS530では、同時化処理部1073により、ホワイトバランス補正処理が施された画像データに対して、同時化処理を施す。ステップS540では、カラーマトリクス演算部1075により、同時化処理が施された画像データに対して、ホワイトバランスモードに応じたカラーマトリクス係数を乗じるカラーマトリクス演算を行う。   In step S530, the synchronization processing unit 1073 performs synchronization processing on the image data on which the white balance correction processing has been performed. In step S540, the color matrix calculation unit 1075 performs color matrix calculation by multiplying the image data subjected to the synchronization processing by a color matrix coefficient corresponding to the white balance mode.

ステップS550では、ガンマ・色再現処理部1074により、カラーマトリクス演算が行われた画像データに対して、ガンマ補正処理、および、画像の色味を変化させる色再現処理を行う。   In step S550, the gamma / color reproduction processing unit 1074 performs gamma correction processing and color reproduction processing for changing the color of the image on the image data on which the color matrix calculation has been performed.

ステップS560では、エッジ強調処理部1076により、ガンマ補正処理および色再現処理が行われた画像データに対して、エッジ強調処理を行う。エッジ強調処理の詳細については後述する。   In step S560, the edge enhancement processing unit 1076 performs edge enhancement processing on the image data that has been subjected to gamma correction processing and color reproduction processing. Details of the edge enhancement processing will be described later.

ステップS570では、NR処理部1077により、エッジ強調処理が行われた画像データに対して、ノイズを低減する処理を行う。ノイズ低減処理は、コアリングパラメータに基づいたコアリング処理、または、ノイズ低減パラメータ(以下、NRパラメータ)に基づいて、高周波を低減するフィルタを用いた処理を行う。   In step S570, the NR processing unit 1077 performs noise reduction processing on the image data on which the edge enhancement processing has been performed. In the noise reduction process, a coring process based on the coring parameter or a process using a filter that reduces high frequency is performed based on the noise reduction parameter (hereinafter referred to as NR parameter).

ステップS580では、歪補正部1078により、ノイズ低減処理後の画像データに対して、交換式レンズ2の歪特性に応じた歪補正処理を行う。このため、マイクロコンピュータ1012は、交換式レンズ2の焦点距離およびフォーカス位置に応じた歪特性のデータをFlashメモリ1011から読み出し、撮影時の焦点距離およびフォーカス位置に基づいて、読み出した歪特性のデータを参照することにより、撮影時の歪特性を求める。マイクロコンピュータ115は、撮影時の歪特性の情報をI/F999を介してマイクロコンピュータ1012から取得し、取得した歪特性に基づいて、画像を部分的に拡大・縮小することによって、歪を補正する処理を行う。   In step S580, the distortion correction unit 1078 performs distortion correction processing according to the distortion characteristics of the interchangeable lens 2 on the image data after the noise reduction processing. Therefore, the microcomputer 1012 reads out distortion characteristic data corresponding to the focal length and focus position of the interchangeable lens 2 from the flash memory 1011 and reads out the distortion characteristic data read out based on the focal length and focus position at the time of shooting. By referring to, the distortion characteristics at the time of shooting are obtained. The microcomputer 115 acquires information on distortion characteristics at the time of shooting from the microcomputer 1012 via the I / F 999, and corrects distortion by partially enlarging / reducing the image based on the acquired distortion characteristics. Process.

ステップS590では、歪補正後の画像データを、記録または表示するための画像サイズに縮小または拡大するリサイズ処理を行う。この処理は、画像処理部107で行ってもよいし、マイクロコンピュータ115で行ってもよい。   In step S590, resize processing is performed to reduce or enlarge the image data after distortion correction to an image size for recording or display. This processing may be performed by the image processing unit 107 or the microcomputer 115.

図6は、図5に示すフローチャートのステップS560の処理、すなわち、エッジ強調処理の詳細を示すフローチャートである。   FIG. 6 is a flowchart showing details of the process in step S560 of the flowchart shown in FIG. 5, that is, the edge enhancement process.

ステップ610では、交換式レンズ2の歪特性を取得する。この処理は、図5に示すフローチャートのステップS580における歪特性情報の取得方法と同じであるため、詳しい説明は省略する。   In step 610, the distortion characteristic of the interchangeable lens 2 is acquired. This process is the same as the method for acquiring distortion characteristic information in step S580 of the flowchart shown in FIG.

図7は、交換式レンズ2の歪特性の一例を示す図である。実線71が交換式レンズ2の歪特性(糸巻き型歪特性)を示し、一点鎖線72は、歪が無い場合の特性を示している。図7において、横軸は理想像高、縦軸は実像高である。理想像高とは、歪のない理想的な画像上の像高のことであり、実像高とは、実際の撮影により得られた画像上の像高のことである。また、像高とは、画像の中心からの距離であり、ここでは、画像の中心を0、画像の四隅を1とする。   FIG. 7 is a diagram illustrating an example of distortion characteristics of the interchangeable lens 2. A solid line 71 indicates the distortion characteristic (pincushion distortion characteristic) of the interchangeable lens 2, and a one-dot chain line 72 indicates the characteristic when there is no distortion. In FIG. 7, the horizontal axis represents the ideal image height, and the vertical axis represents the real image height. The imaginary height is an image height on an ideal image without distortion, and the real image height is an image height on an image obtained by actual photographing. The image height is a distance from the center of the image. Here, the center of the image is 0, and the four corners of the image are 1.

図6のステップS620では、画像データの各画素について、歪補正部1078によって、局所的な拡大・縮小処理を行う際の拡大率または縮小率を算出する。ここではまず、各画素について、像高(実像高)を算出する。そして、ステップS610で取得した歪特性に基づいて、算出した像高位置における歪特性の傾きを求める。算出した像高位置における歪特性の傾きとは、図7に示す歪特性の曲線に接する接線の傾きである。例えば、図7を参照すると、像高h1の位置における歪特性の傾きは、接線73の傾きとなる。この傾きが1未満の場合は、画像を拡大する歪補正処理を行い、1以上の場合は、画像を縮小する歪補正処理を行う。ここでは、歪特性の傾きと拡大率または縮小率との関係を定めたデータを予め用意しておき、求めた傾きに基づいて、上記データを参照することにより、拡大率または縮小率を算出する。   In step S620 of FIG. 6, the distortion correction unit 1078 calculates the enlargement ratio or reduction ratio when performing local enlargement / reduction processing for each pixel of the image data. Here, first, the image height (real image height) is calculated for each pixel. Then, based on the distortion characteristic acquired in step S610, the inclination of the distortion characteristic at the calculated image height position is obtained. The calculated inclination of the distortion characteristic at the image height position is an inclination of a tangent line that is in contact with the distortion characteristic curve shown in FIG. For example, referring to FIG. 7, the inclination of the distortion characteristic at the position of the image height h 1 is the inclination of the tangent 73. When the inclination is less than 1, a distortion correction process for enlarging the image is performed. When the inclination is 1 or more, a distortion correction process for reducing the image is performed. Here, data defining the relationship between the slope of the distortion characteristic and the enlargement ratio or reduction ratio is prepared in advance, and the enlargement ratio or reduction ratio is calculated by referring to the data based on the obtained inclination. .

ステップS630では、画像からエッジを抽出する周波数帯域(以下、エッジ抽出帯域と呼ぶ)を算出する。ここでは、基準となるエッジ抽出帯域(以下、基準エッジ抽出帯域と呼ぶ)を予め求めておき、各画素ごとに、ステップS620で求めた拡大率が大きいほど、基準エッジ抽出帯域に対して高周波側の周波数帯域をエッジ抽出帯域とする。これは、拡大後の画像では、拡大前の画像に対して、コントラスト成分が低周波側に寄るからである。また、縮小率が大きいほど、基準エッジ抽出帯域に対して低周波側の周波数帯域をエッジ抽出帯域とする。すなわち、画像が拡大された場合、および、縮小された場合のいずれの場合でも、拡大・縮小後の画像において、同一の周波数帯域のエッジが強調されるようにする。拡大率または縮小率と、基準エッジ抽出帯域からの周波数帯域の変更量との関係は、予め定めておけばよい。   In step S630, a frequency band for extracting an edge from the image (hereinafter referred to as an edge extraction band) is calculated. Here, a reference edge extraction band (hereinafter referred to as a reference edge extraction band) is obtained in advance, and for each pixel, the higher the enlargement ratio obtained in step S620, the higher the frequency of the reference edge extraction band. Is the edge extraction band. This is because in the image after enlargement, the contrast component is closer to the low frequency side than the image before enlargement. Further, the higher the reduction ratio, the lower the frequency band with respect to the reference edge extraction band is set as the edge extraction band. That is, the edge of the same frequency band is emphasized in the enlarged / reduced image regardless of whether the image is enlarged or reduced. The relationship between the enlargement ratio or reduction ratio and the amount of change in the frequency band from the reference edge extraction band may be determined in advance.

ステップS640では、Flashメモリ1011から、交換式レンズ2のMTF特性を取得し、撮像素子102の画素ピッチや画素数、光学ローパスフィルタの特性を考慮して、撮像画像の周波数に応じたコントラスト特性を算出する。   In step S640, the MTF characteristics of the interchangeable lens 2 are acquired from the flash memory 1011, and the contrast characteristics corresponding to the frequency of the captured image are obtained in consideration of the pixel pitch and the number of pixels of the image sensor 102 and the characteristics of the optical low-pass filter. calculate.

図8の点線は、Flashメモリ1011から取得した交換式レンズ2のMTF特性の一例を示す図であり、実線は、取得したMTF特性に基づいて算出したコントラスト特性の一例を示す図である。図8の横軸は周波数、縦軸はコントラストを表している。   A dotted line in FIG. 8 is a diagram illustrating an example of the MTF characteristic of the interchangeable lens 2 acquired from the flash memory 1011, and a solid line is a diagram illustrating an example of the contrast characteristic calculated based on the acquired MTF characteristic. In FIG. 8, the horizontal axis represents frequency and the vertical axis represents contrast.

ステップS650では、ステップS630で算出したエッジ抽出帯域を補正する。ここでは、ステップS640で算出したコントラスト特性に基づいて、エッジ抽出帯域の周波数に対応するコントラストが所定のコントラスト下限値未満の画素が存在する場合に、その画素のエッジ抽出帯域を、所定のコントラスト下限値に対応する周波数に補正する。   In step S650, the edge extraction band calculated in step S630 is corrected. Here, based on the contrast characteristics calculated in step S640, when there is a pixel whose contrast corresponding to the frequency of the edge extraction band is less than the predetermined contrast lower limit value, the edge extraction band of the pixel is set as the predetermined contrast lower limit. Correct to the frequency corresponding to the value.

図9は、エッジ抽出帯域の補正方法を説明するための図である。図9に示す曲線は、図8に示す曲線と同じ曲線、すなわち、交換式レンズ2のMTF特性に基づいて算出したコントラスト特性を示している。図9を参照すると、ある画素のエッジ抽出帯域(周波数)がf2である場合、対応するコントラストが所定のコントラスト下限値未満であるため、この画素のエッジ抽出帯域を、コントラスト下限値に対応するエッジ抽出帯域(周波数)f1とする。   FIG. 9 is a diagram for explaining a method of correcting the edge extraction band. The curve shown in FIG. 9 shows the same curve as the curve shown in FIG. 8, that is, the contrast characteristic calculated based on the MTF characteristic of the interchangeable lens 2. Referring to FIG. 9, when the edge extraction band (frequency) of a certain pixel is f2, the corresponding contrast is less than the predetermined contrast lower limit value, so that the edge extraction band of this pixel is the edge corresponding to the contrast lower limit value. The extraction band (frequency) is f1.

ステップS660では、画像データの各画素について、ステップS620で算出した拡大率または縮小率に応じて歪補正を行った後のコントラスト特性を求める。ただし、歪補正は、エッジ強調処理の後に行われる処理であるため、歪補正を行った後のコントラスト特性とは、歪補正を行ったと仮定した場合のコントラスト特性を意味している。具体的には、拡大率が大きいほど、コントラスト特性を低周波数側に、また、縮小率が大きいほど、コントラスト特性を高周波数側にコントラスト成分が寄るように変更する。   In step S660, contrast characteristics after performing distortion correction for each pixel of the image data according to the enlargement ratio or reduction ratio calculated in step S620 are obtained. However, since the distortion correction is a process performed after the edge enhancement process, the contrast characteristic after the distortion correction means a contrast characteristic when it is assumed that the distortion correction is performed. Specifically, the contrast characteristic is changed so that the contrast component is closer to the lower frequency side as the enlargement ratio is larger, and the contrast characteristic is closer to the higher frequency side as the reduction ratio is larger.

図10は、歪補正後のコントラスト特性の算出方法を説明するための図である。実線91は、ステップS640で算出したコントラスト特性を示している。点線92は、拡大率に応じて、低周波数側に圧縮されたコントラスト特性の一例を、点線93は、縮小率に応じて、高周波数側に引き伸ばされたコントラスト特性の一例をそれぞれ示している。   FIG. 10 is a diagram for explaining a method of calculating contrast characteristics after distortion correction. A solid line 91 indicates the contrast characteristic calculated in step S640. A dotted line 92 shows an example of the contrast characteristic compressed to the low frequency side according to the enlargement ratio, and a dotted line 93 shows an example of the contrast characteristic stretched to the high frequency side according to the reduction ratio.

ステップS670では、画像データの各画素について、エッジ強調度を求める。まず初めに、ステップS640で取得したコントラスト特性、および、ステップS660で算出したコントラスト特性に基づいて、歪補正後のコントラスト特性に応じたエッジ抽出帯域を求める。このため、各画素ごとに、ステップS640で算出したコントラスト特性(実線91)を参照して、ステップS630で求めたエッジ抽出帯域に対応するコントラストを求める。続いて、求めたコントラストに対応するエッジ抽出帯域を、ステップS660で算出したコントラスト特性(点線92,93)に基づいて求める(図10のI参照)。最後に、求めたエッジ抽出帯域において、基準となるコントラストとの差(図10のII参照)に基づいて、基準となるコントラストを得るために必要なエッジ強調度を求める。基準となるコントラスト特性(以下、基準コントラスト特性と呼ぶ)は、予め定めておく。また、基準となるコントラストとの差と、エッジ強調度との関係も予め定めておく。   In step S670, an edge enhancement degree is obtained for each pixel of the image data. First, based on the contrast characteristic acquired in step S640 and the contrast characteristic calculated in step S660, an edge extraction band corresponding to the contrast characteristic after distortion correction is obtained. Therefore, for each pixel, the contrast corresponding to the edge extraction band obtained in step S630 is obtained with reference to the contrast characteristic (solid line 91) calculated in step S640. Subsequently, an edge extraction band corresponding to the obtained contrast is obtained based on the contrast characteristics (dotted lines 92 and 93) calculated in step S660 (see I in FIG. 10). Finally, in the obtained edge extraction band, the degree of edge enhancement necessary for obtaining the reference contrast is obtained based on the difference from the reference contrast (see II in FIG. 10). A reference contrast characteristic (hereinafter referred to as a reference contrast characteristic) is determined in advance. Also, the relationship between the difference from the reference contrast and the edge enhancement degree is determined in advance.

上述したように、歪補正後のコントラスト特性は、歪補正時の拡大率が大きいほど、低周波数側に圧縮される。従って、歪補正時の拡大率が大きいほど、基準となるコントラストとの差(図10のII)が大きくなり、エッジ強調度が大きくなる。また、歪補正後のコントラスト特性は、歪補正時の縮小率が大きいほど、高周波数側に引き伸ばされた特性となるので、基準となるコントラストとの差が小さくなり、エッジ強調度は小さくなる。   As described above, the contrast characteristic after distortion correction is compressed to the lower frequency side as the enlargement ratio at the time of distortion correction is larger. Therefore, the larger the magnification at the time of distortion correction, the greater the difference from the reference contrast (II in FIG. 10), and the greater the edge enhancement. Further, since the contrast characteristic after distortion correction becomes a characteristic stretched to the higher frequency side as the reduction ratio at the time of distortion correction is larger, the difference from the reference contrast becomes smaller and the edge enhancement degree becomes smaller.

図6のフローチャートのステップS680では、ステップS650で補正を行ったエッジ抽出帯域、および、ステップS670で算出したエッジ強調度に基づいて、エッジ強調処理を行う。ここでは、複数のバンドパスフィルタ係数とエッジ強調帯域との関係を定めたデータを予め用意しておき、このデータを参照して、算出したエッジ抽出帯域に最も近いエッジ強調帯域に対応するバンドパスフィルタ係数を求める。このバンドパスフィルタ係数に基づいてエッジ成分を抽出し、抽出したエッジ成分にエッジ強調度を乗じた値を、画像データの輝度(Y)信号データに加算することによって、エッジを強調する。   In step S680 in the flowchart of FIG. 6, edge enhancement processing is performed based on the edge extraction band corrected in step S650 and the edge enhancement degree calculated in step S670. Here, data that defines the relationship between a plurality of bandpass filter coefficients and edge enhancement bands is prepared in advance, and the bandpass corresponding to the edge enhancement band that is closest to the calculated edge extraction band by referring to this data Find the filter coefficients. An edge component is extracted based on the bandpass filter coefficient, and the edge is enhanced by adding a value obtained by multiplying the extracted edge component by the edge enhancement degree to the luminance (Y) signal data of the image data.

第1の実施形態における画像処理装置によれば、エッジ強調処理後の画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する処理を行う。この時、歪補正処理を施さない画像データに対するエッジ強調処理を基準として、局所的な拡大処理または縮小処理に応じて、歪補正処理を施す対象の画像データに対するエッジ強調処理を変更する。これにより、歪補正後の画像における部分的なコントラストの低下を抑制して、画像上のコントラストを均一に近づけることができる。   According to the image processing apparatus in the first embodiment, distortion is obtained by performing local enlargement processing or reduction processing according to the optical distortion characteristics of the lens used at the time of photographing on the image data after the edge enhancement processing. The process which correct | amends is performed. At this time, the edge enhancement processing for the image data to be subjected to the distortion correction processing is changed according to the local enlargement processing or reduction processing based on the edge enhancement processing for the image data not subjected to the distortion correction processing. As a result, it is possible to suppress the partial reduction in contrast in the image after distortion correction and to bring the contrast on the image closer to uniform.

<第2の実施形態>
図11は、第2の実施形態における画像処理装置を適用したデジタルスチルカメラの構成を示すブロック図である。図1に示すデジタルスチルカメラと異なるのは、画像処理部107の内部の構成である。すなわち、ガンマ・色再現処理部1075の後段に、NR処理部1077が接続されており、歪補正部1078の後段に、エッジ強調処理部1076が接続されている。各処理部1071〜1078の内部で行われる処理内容は同じである。
<Second Embodiment>
FIG. 11 is a block diagram illustrating a configuration of a digital still camera to which the image processing apparatus according to the second embodiment is applied. A difference from the digital still camera shown in FIG. 1 is an internal configuration of the image processing unit 107. That is, the NR processing unit 1077 is connected to the subsequent stage of the gamma / color reproduction processing unit 1075, and the edge enhancement processing unit 1076 is connected to the subsequent stage of the distortion correction unit 1078. The processing content performed in each of the processing units 1071 to 1078 is the same.

図12は、第2の実施形態における画像処理装置による現像処理の詳細を示すフローチャートである。図5に示すフローチャートの処理と同一の処理を行うステップについては、同一の符号を付して詳しい説明は省略する。   FIG. 12 is a flowchart showing details of development processing by the image processing apparatus according to the second embodiment. Steps for performing the same processes as those in the flowchart shown in FIG. 5 are denoted by the same reference numerals, and detailed description thereof is omitted.

第2の実施形態における画像処理装置による現像処理では、ガンマ・色再現処理部1074によるガンマ補正処理および色再現処理(S550)が行われると、NR処理部1077によるノイズ低減処理(S570)、および、歪補正部1078による歪補正処理(S580)が行われる。その後、エッジ強調処理部1076によるエッジ強調処理(S1200)が行われ、最後に、リサイズ処理(S590)が行われる。すなわち、歪補正処理が行われた後に、エッジ強調処理が行われる。   In the development processing by the image processing apparatus in the second embodiment, when gamma correction processing and color reproduction processing (S550) are performed by the gamma / color reproduction processing unit 1074, noise reduction processing (S570) by the NR processing unit 1077, and Then, distortion correction processing (S580) by the distortion correction unit 1078 is performed. Thereafter, edge enhancement processing (S1200) is performed by the edge enhancement processing unit 1076, and finally resizing processing (S590) is performed. That is, after the distortion correction process is performed, the edge enhancement process is performed.

図13は、図12に示すフローチャートのステップS1200の処理、すなわち、エッジ強調処理の詳細を示すフローチャートである。図6に示すフローチャートの処理と同一の処理を行うステップについては、同一の符号を付して詳しい説明は省略する。   FIG. 13 is a flowchart showing details of the process in step S1200 of the flowchart shown in FIG. 12, that is, the edge enhancement process. Steps for performing the same processing as the processing in the flowchart shown in FIG.

ステップS610Aでは、交換式レンズ2の歪特性を取得する。エッジ強調処理の前に歪補正処理(図12のステップS580)が行われて、歪特性を既に取得済みであるため、ここでは、歪補正処理で取得して、SDRAM106に格納しておいた歪特性を読み出す。なお、再度、同様の方法によって、交換式レンズ2の歪特性を求めてもよい。   In step S610A, the distortion characteristics of the interchangeable lens 2 are acquired. Since the distortion correction processing (step S580 in FIG. 12) has been performed before the edge enhancement processing and the distortion characteristics have already been acquired, here, the distortion acquired by the distortion correction processing and stored in the SDRAM 106 is used. Read characteristics. Note that the distortion characteristics of the interchangeable lens 2 may be obtained again by the same method.

ステップS620Aでは、画像データの各画素について、歪補正部1078によって、局所的な拡大・縮小処理を行う際の拡大率または縮小率を算出する。ここでも、歪補正処理で算出済みの拡大率または縮小率を歪補正時にSDRAM106に記憶しておき、SDRAM106から読み出して用いる。なお、再度、同様の方法によって、拡大率または縮小率を算出するようにしてもよい。   In step S620A, for each pixel of the image data, the distortion correction unit 1078 calculates an enlargement ratio or reduction ratio when performing local enlargement / reduction processing. Also here, the enlargement ratio or reduction ratio calculated in the distortion correction process is stored in the SDRAM 106 at the time of distortion correction, and is read out from the SDRAM 106 and used. Note that the enlargement ratio or the reduction ratio may be calculated again by a similar method.

ステップS640では、Flashメモリ1011から、交換式レンズ2のMTF特性を取得し、撮像素子102の画素ピッチや画素数を考慮して、撮像画像の周波数に応じたコントラスト特性を算出する。ステップS650では、画像データの各画素について、ステップS620Aで求めた拡大率または縮小率に応じて歪補正を行った後のコントラスト特性を求める。   In step S640, the MTF characteristics of the interchangeable lens 2 are acquired from the flash memory 1011, and the contrast characteristics corresponding to the frequency of the captured image are calculated in consideration of the pixel pitch and the number of pixels of the image sensor 102. In step S650, for each pixel of the image data, a contrast characteristic after performing distortion correction according to the enlargement ratio or reduction ratio obtained in step S620A is obtained.

ステップS1300では、画像データの各画素について、エッジ抽出帯域を算出する。このため、まず、ステップS650で求めたコントラスト特性に基づいて、予め設定した基準エッジ抽出帯域に対応するコントラストを求める。求めたコントラストが所定のコントラスト下限値未満の場合には、所定のコントラスト下限値に対応する周波数を、エッジ抽出帯域とする。また、求めたコントラストが所定のコントラスト上限値より大きい場合には、所定のコントラスト上限値に対応する周波数を、エッジ抽出帯域とする。求めたコントラストが所定のコントラスト下限値以上、所定のコントラスト以下の場合には、基準エッジ抽出帯域をエッジ抽出帯域とする。   In step S1300, an edge extraction band is calculated for each pixel of the image data. Therefore, first, the contrast corresponding to the preset reference edge extraction band is obtained based on the contrast characteristic obtained in step S650. When the obtained contrast is less than the predetermined contrast lower limit value, the frequency corresponding to the predetermined contrast lower limit value is set as the edge extraction band. Further, when the obtained contrast is larger than the predetermined contrast upper limit value, the frequency corresponding to the predetermined contrast upper limit value is set as the edge extraction band. When the obtained contrast is not less than the predetermined contrast lower limit value and not more than the predetermined contrast, the reference edge extraction band is set as the edge extraction band.

図14は、求めたコントラストが所定のコントラスト下限値未満の場合におけるエッジ抽出帯域の算出方法を説明するための図である。コントラスト特性1400は、拡大率に応じて歪補正を行った後のコントラスト特性である。この場合、基準エッジ抽出帯域に対応するコントラストは、所定のコントラスト下限値未満であるため、所定のコントラスト下限値に対応する周波数をエッジ抽出帯域とする。すなわち、エッジ抽出帯域は、基準エッジ抽出帯域よりも低周波数側にずらされる。これにより、画像上でエッジ抽出することができない周波数帯域に基づいたエッジ抽出処理が行われるのを防ぐことができる。   FIG. 14 is a diagram for explaining a method of calculating an edge extraction band when the obtained contrast is less than a predetermined contrast lower limit value. A contrast characteristic 1400 is a contrast characteristic after performing distortion correction according to the enlargement ratio. In this case, since the contrast corresponding to the reference edge extraction band is less than the predetermined contrast lower limit value, the frequency corresponding to the predetermined contrast lower limit value is set as the edge extraction band. That is, the edge extraction band is shifted to a lower frequency side than the reference edge extraction band. Thereby, it is possible to prevent the edge extraction processing based on the frequency band where the edge cannot be extracted on the image from being performed.

図15は、求めたコントラストが所定のコントラスト上限値よりも大きい場合におけるエッジ抽出帯域の算出方法を説明するための図である。コントラスト特性1500は、縮小率に応じて歪補正を行った後のコントラスト特性である。この場合、基準エッジ抽出帯域に対応するコントラストは、所定のコントラスト上限値よりも大きいため、所定のコントラスト上限値に対応する周波数をエッジ抽出帯域とする。すなわち、エッジ抽出帯域は、基準エッジ抽出帯域よりも高周波数側にずらされる。これにより、より高周波数側のエッジを強調することができる。   FIG. 15 is a diagram for explaining a method of calculating an edge extraction band when the obtained contrast is larger than a predetermined contrast upper limit value. A contrast characteristic 1500 is a contrast characteristic after performing distortion correction according to the reduction ratio. In this case, since the contrast corresponding to the reference edge extraction band is larger than the predetermined contrast upper limit value, the frequency corresponding to the predetermined contrast upper limit value is set as the edge extraction band. That is, the edge extraction band is shifted to a higher frequency side than the reference edge extraction band. Thereby, the higher frequency side edge can be emphasized.

なお、コントラスト下限値を高めに設定しておいて、歪補正処理にて拡大処理を行った場合には常に、エッジ抽出帯域を、基準エッジ抽出帯域よりも低周波数側にずらすようにしてもよい。また、コントラスト上限値を低めに設定しておいて、歪補正処理にて縮小処理を行った場合には常に、エッジ抽出帯域を、基準エッジ抽出帯域よりも高周波数側にずらすようにしてもよい。   Note that the edge extraction band may be shifted to the lower frequency side than the reference edge extraction band whenever the contrast lower limit value is set higher and the enlargement process is performed in the distortion correction process. . In addition, when the contrast upper limit value is set low and the reduction process is performed in the distortion correction process, the edge extraction band may be shifted to the higher frequency side than the reference edge extraction band. .

ステップS1310では、エッジ強調度を算出する。ここでは、ステップS1300で求めたエッジ抽出帯域において、ステップS650で求めた、拡大率または縮小率に応じて歪補正を行った後のコントラスト特性に応じたコントラストと、所定の基準コントラスト特性との差に基づいて、基準となるコントラストを得るために必要なエッジ強調度を求める。   In step S1310, an edge enhancement degree is calculated. Here, in the edge extraction band obtained in step S1300, the difference between the contrast according to the contrast characteristic obtained after the distortion correction according to the enlargement ratio or reduction ratio obtained in step S650 and a predetermined reference contrast characteristic. Based on the above, the edge enhancement necessary to obtain the reference contrast is obtained.

図16は、拡大率に応じて歪補正を行った後のコントラスト特性に基づいて、エッジ強調度を算出する方法を説明するための図である。コントラスト特性1400は、図14に示すコントラスト特性1400と同じく、拡大率に応じて歪補正を行った後のコントラスト特性である。ステップS1300で求めたエッジ抽出帯域において、コントラスト特性1400に対応するコントラストと、基準コントラスト特性1610に対応するコントラストとの差1620を求め、コントラスト差1620に基づいて、エッジ強調度を求める。第1の実施形態と同様に、コントラスト差とエッジ強調度との関係については、予め定めておく。   FIG. 16 is a diagram for explaining a method of calculating the edge enhancement degree based on the contrast characteristics after performing distortion correction according to the enlargement ratio. A contrast characteristic 1400 is a contrast characteristic after distortion correction is performed in accordance with the enlargement ratio, like the contrast characteristic 1400 shown in FIG. In the edge extraction band obtained in step S1300, a difference 1620 between the contrast corresponding to the contrast characteristic 1400 and the contrast corresponding to the reference contrast characteristic 1610 is obtained, and the edge enhancement degree is obtained based on the contrast difference 1620. As in the first embodiment, the relationship between the contrast difference and the edge enhancement degree is determined in advance.

図17は、縮小率に応じて歪補正を行った後のコントラスト特性に基づいて、エッジ強調度を算出する方法を説明するための図である。コントラスト特性1500は、縮小率に応じて歪補正を行った後のコントラスト特性である。コントラスト特性1500は、図15に示すコントラスト特性1500と同じく、縮小率に応じて歪補正を行った後のコントラスト特性である。ステップS1300で求めたエッジ抽出帯域において、コントラスト特性1500に対応するコントラストと、基準コントラスト特性1610に対応するコントラストとの差1720を求め、コントラスト差1720に基づいて、エッジ強調度を求める。上述したように、コントラスト差とエッジ強調度との関係については、予め定めておく。   FIG. 17 is a diagram for explaining a method of calculating the edge enhancement degree based on the contrast characteristics after performing distortion correction according to the reduction ratio. A contrast characteristic 1500 is a contrast characteristic after performing distortion correction according to the reduction ratio. Contrast characteristic 1500 is the contrast characteristic after distortion correction is performed in accordance with the reduction ratio, similar to contrast characteristic 1500 shown in FIG. In the edge extraction band obtained in step S1300, the difference 1720 between the contrast corresponding to the contrast characteristic 1500 and the contrast corresponding to the reference contrast characteristic 1610 is obtained, and the edge enhancement degree is obtained based on the contrast difference 1720. As described above, the relationship between the contrast difference and the edge enhancement degree is determined in advance.

図13のフローチャートのステップS680では、ステップS1300で算出したエッジ抽出帯域、および、ステップS1310で算出したエッジ強調度に基づいて、エッジ強調処理を行う。   In step S680 of the flowchart of FIG. 13, edge enhancement processing is performed based on the edge extraction band calculated in step S1300 and the edge enhancement degree calculated in step S1310.

以上、第2の実施形態における画像処理装置によれば、画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する処理を行った後、エッジ強調処理を行う。このとき、局所的な拡大処理または縮小処理に応じて、歪補正処理を施した画像データに対するエッジ強調処理を変更するので、歪補正後の画像における部分的なコントラストの低下を抑制して、画像上のコントラストを均一に近づけることができる。   As described above, according to the image processing apparatus of the second embodiment, distortion is corrected by performing local enlargement or reduction processing on the image data according to the optical distortion characteristics of the lens used during shooting. After performing the processing, edge enhancement processing is performed. At this time, since the edge enhancement processing for the image data subjected to the distortion correction processing is changed according to the local enlargement processing or reduction processing, the partial contrast decrease in the image after the distortion correction is suppressed, and the image The upper contrast can be made uniform.

<第3の実施形態>
第3の実施形態における画像処理装置を適用したデジタルスチルカメラの構成は、図1に示す第1の実施の形態における画像処理装置を適用したデジタルスチルカメラの構成と同じである。
<Third Embodiment>
The configuration of the digital still camera to which the image processing apparatus in the third embodiment is applied is the same as the configuration of the digital still camera to which the image processing apparatus in the first embodiment shown in FIG. 1 is applied.

図18は、図5に示すフローチャートのステップS560の処理、すなわち、エッジ強調処理の詳細を示すフローチャートである。図6に示すフローチャートの処理と同一の処理を行うステップについては、同一の符号を付して詳しい説明は省略する。   FIG. 18 is a flowchart showing details of the process in step S560 of the flowchart shown in FIG. 5, that is, the edge enhancement process. Steps for performing the same processing as the processing in the flowchart shown in FIG.

ステップS620に続くステップS1800では、リサイズ処理を行う際のリサイズ率を取得する。リサイズ処理は、画像データを記録または表示するための画像サイズに縮小または拡大する処理(図5のステップS590)である。   In step S1800 following step S620, a resizing rate for performing the resizing process is acquired. The resizing process is a process for reducing or enlarging the image data to an image size for recording or displaying (step S590 in FIG. 5).

ステップS1810では、画像データの各画素に対して、ステップS620で算出した拡大率または縮小率に、ステップS1800で取得したリサイズ率を乗算することによって、縮尺率を算出する。   In step S1810, for each pixel of the image data, the scale ratio is calculated by multiplying the enlargement ratio or reduction ratio calculated in step S620 by the resizing ratio acquired in step S1800.

ステップS1820では、ステップS1810で各画素ごとに算出した縮尺率のうち、最大の縮尺率が1より大きいか否かを判定する。最大縮尺率が1より大きい場合、画像上で局所的な拡大処理が行われるため、拡大処理が行われる箇所のコントラストが低下する。従って、最大縮尺率が1より大きいと判定すると、エッジ強調制御を行うために、ステップS630に進む。ステップS630からステップS680までの処理は、図6に示すフローチャートの処理と同じである。   In step S1820, it is determined whether the maximum scale ratio among the scale ratios calculated for each pixel in step S1810 is greater than one. When the maximum scale ratio is larger than 1, since the local enlargement process is performed on the image, the contrast of the portion where the enlargement process is performed is lowered. Therefore, if it is determined that the maximum scale ratio is greater than 1, the process proceeds to step S630 to perform edge enhancement control. The processing from step S630 to step S680 is the same as the processing of the flowchart shown in FIG.

一方、最大縮尺率が1以下である場合、画像全体において拡大処理は行われないため、コントラストの局所的な低下は生じない。従って、ステップS1820において、最大縮尺率が1以下であると判定すると、ステップS1830に進み、所定のエッジ強調度を設定する。所定のエッジ強調度は、予め設計により定めた、各画素について同一の値とする。   On the other hand, when the maximum scale ratio is 1 or less, the enlargement process is not performed on the entire image, and thus a local reduction in contrast does not occur. Therefore, if it is determined in step S1820 that the maximum scale ratio is 1 or less, the process advances to step S1830 to set a predetermined edge enhancement level. The predetermined edge enhancement degree is set to the same value for each pixel, which is predetermined by design.

以上、第3の実施形態における画像処理装置によれば、歪補正処理を行う際の局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、エッジ強調処理を変更する処理は行わない。これにより、コントラストの局所的な低下が生じない場合には、エッジ強調処理を変更する処理を行わないので、処理負荷を軽減するとともに、処理時間を短縮することができる。   As described above, according to the image processing apparatus of the third embodiment, when the image data is enlarged or reduced to the local enlargement ratio and reduction ratio when performing the distortion correction process and the finally required image size. When the maximum value of the product of the resizing rate is equal to or smaller than a predetermined threshold value, the process for changing the edge enhancement process is not performed. As a result, when there is no local decrease in contrast, the processing for changing the edge enhancement processing is not performed, so that the processing load can be reduced and the processing time can be shortened.

<第4の実施形態>
第4の実施形態における画像処理装置を適用したデジタルスチルカメラの構成は、図1に示す第1の実施の形態における画像処理装置を適用したデジタルスチルカメラの構成と同じである。
<Fourth Embodiment>
The configuration of the digital still camera to which the image processing apparatus in the fourth embodiment is applied is the same as that of the digital still camera to which the image processing apparatus in the first embodiment shown in FIG. 1 is applied.

図19は、図5に示すフローチャートのステップS560の処理、すなわち、エッジ強調処理の詳細を示すフローチャートである。図6に示すフローチャートの処理と同一の処理を行うステップについては、同一の符号を付して詳しい説明は省略する。   FIG. 19 is a flowchart showing details of the process in step S560 of the flowchart shown in FIG. 5, that is, the edge enhancement process. Steps for performing the same processing as the processing in the flowchart shown in FIG.

ステップS620において、画像データの各画素について、局所的な拡大・縮小処理を行う際の拡大率または縮小率を算出すると、ステップS640に進む。ステップS640では、撮像画像の周波数に応じたコントラスト特性を算出する。   In step S620, when the enlargement ratio or reduction ratio when performing local enlargement / reduction processing is calculated for each pixel of the image data, the process proceeds to step S640. In step S640, contrast characteristics corresponding to the frequency of the captured image are calculated.

ステップS660では、画像データの各画素について、ステップS620で算出した拡大率または縮小率に応じて歪補正を行った後のコントラスト特性を求める。   In step S660, contrast characteristics after performing distortion correction for each pixel of the image data according to the enlargement ratio or reduction ratio calculated in step S620 are obtained.

ステップS1900では、処理対象の画像データが静止画データであるか、または動画データであるかを判定する。この判定は、静止画の撮影であるか、または、動画の撮影であるかに基づいて行うことができる。ユーザが動画を見る場合、画像の細かな解像感はそれほど気にならない。従って、処理対象の画像データが動画データであると判定すると、歪補正を考慮したエッジ強調処理を簡易的に行うために、ステップS1910に進む。   In step S1900, it is determined whether the image data to be processed is still image data or moving image data. This determination can be made based on whether a still image is taken or a moving image is taken. When a user views a moving image, the fine resolution of the image is not so much of concern. Accordingly, if it is determined that the image data to be processed is moving image data, the process advances to step S1910 in order to easily perform edge enhancement processing considering distortion correction.

ステップS1910では、所定のエッジ抽出帯域を設定する。所定のエッジ抽出帯域は、予め設計により定めた、各画素について同一の値とする。   In step S1910, a predetermined edge extraction band is set. The predetermined edge extraction band is set to the same value for each pixel, which is predetermined by design.

一方、ステップS1900において、処理対象の画像データが静止画データであると判定すると、ステップS630に進む。ステップS630、S650、S670、S680の処理は、図6に示すフローチャートの処理と同じである。   On the other hand, if it is determined in step S1900 that the image data to be processed is still image data, the process proceeds to step S630. The processes in steps S630, S650, S670, and S680 are the same as those in the flowchart shown in FIG.

なお、図19に示すフローチャートでは、動画データの処理時において、エッジ強調度は歪補正を考慮した値を算出するが、エッジ抽出帯域については、歪補正を考慮しない固定の値を用いるものとした。しかし、エッジ抽出帯域について歪補正を考慮した値を算出し、エッジ強調度について、歪補正を考慮しない固定の値を用いるようにしてもよい。   In the flowchart shown in FIG. 19, when processing moving image data, the edge enhancement degree is a value that considers distortion correction, but a fixed value that does not consider distortion correction is used for the edge extraction band. . However, a value that considers distortion correction may be calculated for the edge extraction band, and a fixed value that does not consider distortion correction may be used for the edge enhancement degree.

以上、第4の実施形態における画像処理装置によれば、静止画撮影時は、歪補正処理を考慮して、エッジ強調処理を施す周波数帯域とともにエッジ強調度を変更する処理を行い、動画撮影時は、エッジ強調処理を施す周波数帯域を変更する処理およびエッジ強調度を変更する処理のうちのいずれか一方の処理を行う。これにより、視覚上、細かな解像度が気にならない動画データの処理時には、処理速度を向上させることができる。また、静止画データの処理時には、歪補正を考慮して、エッジ強調処理を施す周波数帯域を変更する処理およびエッジ強調度を変更する処理を行うことにより、コントラストを均一に近づけた画像を生成することができる。   As described above, according to the image processing apparatus of the fourth embodiment, at the time of still image shooting, in consideration of distortion correction processing, the processing for changing the edge enhancement level is performed together with the frequency band on which the edge enhancement processing is performed. Performs any one of the process of changing the frequency band to which the edge enhancement process is performed and the process of changing the edge enhancement degree. As a result, the processing speed can be improved when processing moving image data in which a fine resolution is not a concern visually. In addition, when processing still image data, an image with a close contrast is generated by performing processing for changing the frequency band for performing edge enhancement processing and processing for changing the edge enhancement degree in consideration of distortion correction. be able to.

なお、上述した第1〜第4の実施形態の説明では、画像処理装置が行う処理としてハードウェアによる処理を前提としていたが、このような構成に限定される必要はない。例えば、別途ソフトウェアにて処理する構成も可能である。この場合、画像処理装置は、CPU、RAM等の主記憶装置、上記処理の全て或いは一部を実現させるためのプログラムが記憶されたコンピュータ読み取り可能な記憶媒体を備えている。ここでは、このプログラムを画像処理プログラムと呼ぶ。そして、CPUが上記記憶媒体に記憶されている画像処理プログラムを読み出して、情報の加工・演算処理を実行することにより、上述の画像処理装置と同様の処理を実現させる。   In the description of the first to fourth embodiments described above, hardware processing is assumed as processing performed by the image processing apparatus. However, the present invention is not limited to such a configuration. For example, a configuration in which processing is performed separately by software is also possible. In this case, the image processing apparatus includes a main storage device such as a CPU and a RAM, and a computer-readable storage medium storing a program for realizing all or part of the above processing. Here, this program is called an image processing program. The CPU reads out the image processing program stored in the storage medium and executes information processing / calculation processing, thereby realizing the same processing as that of the above-described image processing apparatus.

ここで、コンピュータ読み取り可能な記録媒体とは、磁気ディスク、光磁気ディスク、CD−ROM、DVD−ROM、半導体メモリ等をいう。また、この画像処理プログラムを通信回線によってコンピュータに配信し、この配信を受けたコンピュータが当該画像処理プログラムを実行するようにしても良い。   Here, the computer-readable recording medium refers to a magnetic disk, a magneto-optical disk, a CD-ROM, a DVD-ROM, a semiconductor memory, and the like. Alternatively, the image processing program may be distributed to a computer via a communication line, and the computer that has received the distribution may execute the image processing program.

本発明は、上述した第1〜第4の実施形態に限定されるものではなく、本発明の要旨を逸脱しない範囲内で様々な変形や応用が可能である。例えば、画像処理装置をデジタルスチルカメラに適用した例を挙げて説明したが、ビデオカメラに適用することもできるし、カメラ以外の電子機器などに適用することもできる。   The present invention is not limited to the first to fourth embodiments described above, and various modifications and applications can be made without departing from the scope of the present invention. For example, the example in which the image processing apparatus is applied to a digital still camera has been described. However, the image processing apparatus can also be applied to a video camera or an electronic device other than the camera.

上述した各実施形態では、交換式レンズ2のMTF特性に基づいて算出したコントラスト特性を参照して、エッジ強調処理を施す周波数帯域とともにエッジ強調度を求めたが、簡易的な方法により求めることもできる。例えば、交換式レンズ2の歪特性に応じた拡大率または縮小率と、エッジ抽出帯域およびエッジ強調度との関係を定めたデータを予めFlashメモリ1011に格納しておき、このデータに基づいて、エッジ抽出帯域およびエッジ強調度を求めてもよい。   In each of the above-described embodiments, the edge enhancement degree is obtained together with the frequency band to which the edge enhancement process is performed with reference to the contrast characteristic calculated based on the MTF characteristic of the interchangeable lens 2, but may be obtained by a simple method. it can. For example, data defining the relationship between the enlargement ratio or reduction ratio according to the distortion characteristics of the interchangeable lens 2 and the edge extraction band and the edge enhancement degree is stored in the flash memory 1011 in advance, and based on this data, The edge extraction band and the edge enhancement degree may be obtained.

デジタルスチルカメラは、カメラ本体1と交換式レンズ2から構成されるものとして説明したが、カメラ本体とレンズとが一体的に構成されていてもよい。この場合、レンズの焦点距離およびフォーカス位置に応じた歪特性のデータ、および、レンズのMTF特性のデータは、カメラ本体内部のメモリに記憶しておけばよい。   Although the digital still camera has been described as including the camera body 1 and the interchangeable lens 2, the camera body and the lens may be configured integrally. In this case, the distortion characteristic data corresponding to the focal length and focus position of the lens and the MTF characteristic data of the lens may be stored in a memory inside the camera body.

1…カメラ本体
2…交換式レンズ
101…メカシャッター
102…撮像素子
103…アナログ処理部
104…アナログ/デジタル変換部
106…SDRAM
107…画像処理部
108…AE処理部
109…AF処理部
110…画像圧縮展開部
112…記録媒体
114…LCD
115…マイクロコンピュータ
116…操作部
117…Flashメモリ
1010…レンズ
1011…Flashメモリ
1012…マイクロコンピュータ
1071…OB減算部
1072…ホワイトバランス補正部
1073…同時化処理部
1074…カラーマトリクス演算部
1075…ガンマ・色再現処理部
1076…エッジ強調処理部
1077…ノイズ低減処理部
1078…歪補正部
DESCRIPTION OF SYMBOLS 1 ... Camera body 2 ... Interchangeable lens 101 ... Mechanical shutter 102 ... Imaging element 103 ... Analog processing part 104 ... Analog / digital conversion part 106 ... SDRAM
107 ... Image processing unit 108 ... AE processing unit 109 ... AF processing unit 110 ... Image compression / decompression unit 112 ... Recording medium 114 ... LCD
DESCRIPTION OF SYMBOLS 115 ... Microcomputer 116 ... Operation part 117 ... Flash memory 1010 ... Lens 1011 ... Flash memory 1012 ... Microcomputer 1071 ... OB subtraction part 1072 ... White balance correction part 1073 ... Synchronization processing part 1074 ... Color matrix calculation part 1075 ... Gamma Color reproduction processing unit 1076 ... Edge enhancement processing unit 1077 ... Noise reduction processing unit 1078 ... Distortion correction unit

Claims (9)

画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、
前記画像データに対して、エッジ強調処理を施すエッジ強調部と、
前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更する制御部と、
を備え、
前記制御部は、
前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、
前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わないことを特徴とする画像処理装置。
A distortion correction unit that performs distortion correction processing for correcting distortion by performing local enlargement processing or reduction processing on the image data according to the optical distortion characteristics of the lens used at the time of shooting,
An edge enhancement unit that performs edge enhancement processing on the image data;
A control unit that changes edge enhancement processing on the image data in accordance with the local enlargement processing or reduction processing;
With
The controller is
In the image after the distortion correction processing and the edge enhancement processing, the edge of the same frequency band is enhanced in accordance with the local enlargement processing or reduction processing, and the contrast is reduced by suppressing a partial contrast decrease. Control to be close to the uniform ,
A maximum value of a product of a local enlargement ratio and reduction ratio in the local enlargement process or reduction process and a resizing ratio when image data is enlarged or reduced to a finally required image size is predetermined. The image processing apparatus according to claim 1, wherein when the threshold value is equal to or less than the threshold value, the edge enhancement process is not changed .
画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、
前記歪補正処理後の画像データに対して、エッジ強調処理を施すエッジ強調部と、
前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更する制御部と、
を備え、
前記制御部は、
前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、
前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わないことを特徴とする画像処理装置。
A distortion correction unit that performs distortion correction processing for correcting distortion by performing local enlargement processing or reduction processing on the image data according to the optical distortion characteristics of the lens used at the time of shooting,
An edge enhancement unit that performs edge enhancement processing on the image data after the distortion correction processing;
A control unit that changes edge enhancement processing on the image data subjected to the distortion correction processing according to the local enlargement processing or reduction processing;
With
The controller is
In the image after the distortion correction processing, in accordance with the local enlargement processing or reduction processing, the reduction of the partial contrast is suppressed and control is performed so as to make the contrast close to uniform ,
A maximum value of a product of a local enlargement ratio and reduction ratio in the local enlargement process or reduction process and a resizing ratio when image data is enlarged or reduced to a finally required image size is predetermined. The image processing apparatus according to claim 1, wherein when the threshold value is equal to or less than the threshold value, the edge enhancement process is not changed .
前記所定のしきい値は、1.0であることを特徴とする請求項1または2に記載の画像処理装置。The image processing apparatus according to claim 1, wherein the predetermined threshold is 1.0. 画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、前記画像データに対して、エッジ強調処理を施すエッジ強調部と、前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更する制御部と、を備え、前記制御部は、前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御する画像処理装置と、A distortion correction unit that performs distortion correction processing for correcting distortion by performing local enlargement processing or reduction processing according to the optical distortion characteristics of the lens used at the time of photographing on the image data, and the image data An edge enhancement unit that performs edge enhancement processing, and a control unit that changes edge enhancement processing on the image data in accordance with the local enlargement processing or reduction processing, and the control unit includes the distortion correction In the image after the processing and the edge enhancement processing, the edges in the same frequency band are enhanced according to the local enlargement processing or reduction processing, and the contrast is made uniform by suppressing a partial contrast decrease. An image processing apparatus for controlling
撮影レンズの周波数に応じたコントラスト特性を記憶する記憶部と、  A storage unit that stores contrast characteristics according to the frequency of the photographing lens;
を備えた撮像装置であって、An imaging device comprising:
前記制御部は、  The controller is
前記記憶部に記憶されているコントラスト特性に応じて、前記エッジ強調処理を施す周波数帯域を変更し、  In accordance with the contrast characteristics stored in the storage unit, the frequency band for performing the edge enhancement processing is changed,
静止画撮影時は、前記エッジ強調処理を施す周波数帯域とともに、エッジを強調する度合いを示すエッジ強調度を変更する処理を行い、動画撮影時は、前記エッジ強調処理を施す周波数帯域を変更する処理および前記エッジ強調度を変更する処理のうちのいずれか一方の処理を行うことを特徴とする撮像装置。  In still image shooting, a process of changing the edge enhancement degree indicating the degree of edge enhancement is performed together with a frequency band in which the edge enhancement process is performed, and in a moving image shooting, a process of changing the frequency band in which the edge enhancement process is performed. And an image processing apparatus that performs any one of the processes for changing the edge enhancement degree.
画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施す歪補正部と、前記歪補正処理後の画像データに対して、エッジ強調処理を施すエッジ強調部と、前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更する制御部と、を備え、前記制御部は、前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御する画像処理装置と、A distortion correction unit that performs distortion correction processing for correcting distortion by performing local enlargement processing or reduction processing on the image data according to the optical distortion characteristics of the lens used at the time of shooting, and after the distortion correction processing An edge enhancement unit that performs an edge enhancement process on the image data, and a control unit that changes an edge enhancement process on the image data subjected to the distortion correction process according to the local enlargement process or the reduction process, The control unit controls the contrast after the distortion correction processing so as to make the contrast close to uniform by suppressing a partial reduction in contrast according to the local enlargement processing or reduction processing. An image processing device;
撮影レンズの周波数に応じたコントラスト特性を記憶する記憶部と、  A storage unit that stores contrast characteristics according to the frequency of the photographing lens;
を備えた撮像装置であって、An imaging device comprising:
前記制御部は、  The controller is
前記記憶部に記憶されているコントラスト特性に応じて、前記エッジ強調処理を施す周波数帯域を変更し、  In accordance with the contrast characteristics stored in the storage unit, the frequency band for performing the edge enhancement processing is changed,
静止画撮影時は、前記エッジ強調処理を施す周波数帯域とともに、エッジを強調する度合いを示すエッジ強調度を変更する処理を行い、動画撮影時は、前記エッジ強調処理を施す周波数帯域を変更する処理および前記エッジ強調度を変更する処理のうちのいずれか一方の処理を行うことを特徴とする撮像装置。  In still image shooting, a process of changing the edge enhancement degree indicating the degree of edge enhancement is performed together with a frequency band in which the edge enhancement process is performed, and in a moving image shooting, a process of changing the frequency band in which the edge enhancement process is performed. And an image processing apparatus that performs any one of the processes for changing the edge enhancement degree.
画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、Applying distortion correction processing to correct distortion by performing local enlargement processing or reduction processing on the image data according to the optical distortion characteristics of the lens used at the time of shooting;
前記画像データに対して、エッジ強調処理を施すステップと、  Applying edge enhancement processing to the image data;
前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更するステップと、  Changing edge enhancement processing on the image data in accordance with the local enlargement processing or reduction processing;
を備え、With
前記エッジ強調処理を変更するステップでは、  In the step of changing the edge enhancement process,
前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、  In the image after the distortion correction processing and the edge enhancement processing, the edge of the same frequency band is enhanced in accordance with the local enlargement processing or reduction processing, and the contrast is reduced by suppressing a partial contrast decrease. Control to be close to the uniform,
前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わないことを特徴とする画像処理方法。  A maximum value of a product of a local enlargement ratio and reduction ratio in the local enlargement process or reduction process and a resizing ratio when image data is enlarged or reduced to a finally required image size is predetermined. An image processing method characterized in that, when the value is equal to or less than a threshold value, the process for changing the edge enhancement process is not performed.
画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、Applying distortion correction processing to correct distortion by performing local enlargement processing or reduction processing on the image data according to the optical distortion characteristics of the lens used at the time of shooting;
前記歪補正処理後の画像データに対して、エッジ強調処理を施すステップと、  Applying edge enhancement processing to the image data after the distortion correction processing;
前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更するステップと、  Changing edge enhancement processing on the image data subjected to the distortion correction processing according to the local enlargement processing or reduction processing;
を備え、With
前記エッジ強調処理を変更するステップでは、  In the step of changing the edge enhancement process,
前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、  In the image after the distortion correction processing, in accordance with the local enlargement processing or reduction processing, the reduction of the partial contrast is suppressed and control is performed so as to make the contrast close to uniform,
前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わないことを特徴とする画像処理方法。  A maximum value of a product of a local enlargement ratio and reduction ratio in the local enlargement process or reduction process and a resizing ratio when image data is enlarged or reduced to a finally required image size is predetermined. An image processing method characterized in that, when the value is equal to or less than a threshold value, the process for changing the edge enhancement process is not performed.
画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、
前記画像データに対して、エッジ強調処理を施すステップと、
前記局所的な拡大処理または縮小処理に応じて、前記画像データに対するエッジ強調処理を変更するステップと、
をコンピュータに実行させるための画像処理プログラムであって、
前記エッジ強調処理を変更するステップでは、
前記歪補正処理および前記エッジ強調処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、同一の周波数帯域のエッジを強調し、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、
前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わないことを特徴とする画像処理プログラム。
Applying distortion correction processing to correct distortion by performing local enlargement processing or reduction processing on the image data according to the optical distortion characteristics of the lens used at the time of shooting;
Applying edge enhancement processing to the image data;
Changing edge enhancement processing on the image data in accordance with the local enlargement processing or reduction processing;
An image processing program for causing a computer to execute
In the step of changing the edge enhancement process,
In the image after the distortion correction processing and the edge enhancement processing, the edge of the same frequency band is enhanced in accordance with the local enlargement processing or reduction processing, and the contrast is reduced by suppressing a partial contrast decrease. Control to be close to the uniform,
A maximum value of a product of a local enlargement ratio and reduction ratio in the local enlargement process or reduction process and a resizing ratio when image data is enlarged or reduced to a finally required image size is predetermined. An image processing program characterized by not performing the process of changing the edge enhancement process when the value is not more than a threshold value .
画像データに対して、撮影時に使用したレンズの光学歪特性に応じた局所的な拡大処理または縮小処理を行うことによって、歪を補正する歪補正処理を施すステップと、
前記歪補正処理後の画像データに対して、エッジ強調処理を施すステップと、
前記局所的な拡大処理または縮小処理に応じて、前記歪補正処理を施した画像データに対するエッジ強調処理を変更するステップと、
をコンピュータに実行させるための画像処理プログラムであって、
前記エッジ強調処理を変更するステップでは、
前記歪補正処理後の画像において、前記局所的な拡大処理または縮小処理に応じて、部分的なコントラストの低下を抑制して、コントラストを均一に近づけるように制御し、
前記局所的な拡大処理または縮小処理における局所的な拡大率および縮小率と、最終的に必要とされる画像サイズへ画像データを拡大または縮小する際のリサイズ率との積の最大値が所定のしきい値以下の場合には、前記エッジ強調処理を変更する処理は行わないことを特徴とする画像処理プログラム。
Applying distortion correction processing to correct distortion by performing local enlargement processing or reduction processing on the image data according to the optical distortion characteristics of the lens used at the time of shooting;
Applying edge enhancement processing to the image data after the distortion correction processing;
Changing edge enhancement processing on the image data subjected to the distortion correction processing according to the local enlargement processing or reduction processing;
An image processing program for causing a computer to execute
In the step of changing the edge enhancement process,
In the image after the distortion correction processing, in accordance with the local enlargement processing or reduction processing, the reduction of the partial contrast is suppressed and control is performed so as to make the contrast close to uniform,
A maximum value of a product of a local enlargement ratio and reduction ratio in the local enlargement process or reduction process and a resizing ratio when image data is enlarged or reduced to a finally required image size is predetermined. An image processing program characterized by not performing the process of changing the edge enhancement process when the value is not more than a threshold value .
JP2014175411A 2014-08-29 2014-08-29 Image processing apparatus, imaging apparatus, image processing method, and image processing program Active JP5800970B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014175411A JP5800970B2 (en) 2014-08-29 2014-08-29 Image processing apparatus, imaging apparatus, image processing method, and image processing program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014175411A JP5800970B2 (en) 2014-08-29 2014-08-29 Image processing apparatus, imaging apparatus, image processing method, and image processing program

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2009242185A Division JP5607911B2 (en) 2009-10-21 2009-10-21 Image processing apparatus, imaging apparatus, image processing method, and image processing program

Publications (2)

Publication Number Publication Date
JP2015008523A JP2015008523A (en) 2015-01-15
JP5800970B2 true JP5800970B2 (en) 2015-10-28

Family

ID=52338470

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014175411A Active JP5800970B2 (en) 2014-08-29 2014-08-29 Image processing apparatus, imaging apparatus, image processing method, and image processing program

Country Status (1)

Country Link
JP (1) JP5800970B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106097970B (en) 2016-08-10 2018-11-20 深圳市华星光电技术有限公司 A kind of driving method and drive system for reducing AMOLED and showing ghost
JP6858073B2 (en) * 2017-05-19 2021-04-14 キヤノン株式会社 Image processing device, image processing method, and program
JP6929711B2 (en) * 2017-06-15 2021-09-01 オリンパス株式会社 Image processing device, image processing method, image processing program
JP6987707B2 (en) 2018-06-28 2022-01-05 ルネサスエレクトロニクス株式会社 Semiconductor devices, image recognition systems

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4436626B2 (en) * 2003-06-20 2010-03-24 オリンパス株式会社 Image processing device
JP2008146155A (en) * 2006-12-06 2008-06-26 Sony Corp Image processing method and device

Also Published As

Publication number Publication date
JP2015008523A (en) 2015-01-15

Similar Documents

Publication Publication Date Title
US9769377B2 (en) Imaging apparatus and control method for handling a raw image of a moving image or a still image
JP5660341B2 (en) Imaging apparatus and imaging method
JP5592776B2 (en) Image processing apparatus, image processing method, and image processing program
US9398230B2 (en) Imaging device and imaging method
US9894270B2 (en) Image processing apparatus and image processing method for handling a raw image, of a moving image or a still image
US9723169B2 (en) Imaging apparatus and imaging apparatus control method
JP5800970B2 (en) Image processing apparatus, imaging apparatus, image processing method, and image processing program
JP5607911B2 (en) Image processing apparatus, imaging apparatus, image processing method, and image processing program
US10091415B2 (en) Image processing apparatus, method for controlling image processing apparatus, image pickup apparatus, method for controlling image pickup apparatus, and recording medium
US9282257B2 (en) Image apparatus and imaging method
US9979943B2 (en) Image processing apparatus for applying emphasis effect processing to a specific component of an image signal, image processing method and image capture apparatus
JP2011160183A (en) Imaging device and method
JP2010283504A (en) Imaging device, imaging method, and imaging program
JP5310331B2 (en) Imaging apparatus and imaging method
JP6592293B2 (en) Image processing apparatus, image processing method, and imaging apparatus
US20110050953A1 (en) Method of setting image aspect ratio according to scene recognition and digital photographing apparatus for performing the method
JP5191941B2 (en) Imaging apparatus, image processing apparatus, image processing method, and image processing program
JP5094686B2 (en) Image processing apparatus, image processing method, and image processing program
JP2009219028A (en) Image recording method and imaging unit
JP6592292B2 (en) Image processing apparatus, image processing method, and imaging apparatus
JP5849532B2 (en) Imaging apparatus and imaging method
JP5807378B2 (en) Imaging apparatus, imaging method, and imaging program
JP2010028607A (en) Image processing apparatus, image capturing apparatus and image processing mehtod
JP2011086209A (en) Moving picture processing apparatus and moving picture processing method
JP2011147012A (en) Image display device, and method of displaying image

Legal Events

Date Code Title Description
A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20150423

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20150430

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20150602

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20150715

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20150825

R151 Written notification of patent or utility model registration

Ref document number: 5800970

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250