JP2015035755A - Luminosity adjusting device, luminosity adjusting method, and program - Google Patents

Luminosity adjusting device, luminosity adjusting method, and program Download PDF

Info

Publication number
JP2015035755A
JP2015035755A JP2013166535A JP2013166535A JP2015035755A JP 2015035755 A JP2015035755 A JP 2015035755A JP 2013166535 A JP2013166535 A JP 2013166535A JP 2013166535 A JP2013166535 A JP 2013166535A JP 2015035755 A JP2015035755 A JP 2015035755A
Authority
JP
Japan
Prior art keywords
image
brightness
color space
feature amount
input image
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.)
Pending
Application number
JP2013166535A
Other languages
Japanese (ja)
Inventor
ひとみ 日向
Hitomi Hyuga
ひとみ 日向
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.)
Dai Nippon Printing Co Ltd
Original Assignee
Dai Nippon Printing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Dai Nippon Printing Co Ltd filed Critical Dai Nippon Printing Co Ltd
Priority to JP2013166535A priority Critical patent/JP2015035755A/en
Publication of JP2015035755A publication Critical patent/JP2015035755A/en
Pending legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To provide a luminosity adjusting device and the like which can adjust brightness of an image while retaining visual saturation for a user.SOLUTION: A feature amount acquisition part 25 acquires as a feature amount A a luminance value that averages all pixels by a moving average filter with respect to an input image, an image in an RGB color space of adjusted luminance, and an image in a YCbCr color space respectively. The feature amount acquisition part 25 acquires as a feature amount B a ratio of a luminance value of an attention pixel to the feature amount A of a peripheral pixel with respect to the input image, the image in the RGB color space of adjusted luminance, and the image in the YCbCr color space respectively. A luminosity adjustment part 26 determines an output pixel value of each pixel by using a first determination condition to adopt a pixel value of an image in a color space of small feature amount difference from the feature amount B of the input image, a second determination condition to adopt a pixel value of an image in a color space of large feature amount difference from the feature amount A of the input image, and a third determination condition to adopt a pixel value of an image in the color space that is not adopted in the second determination condition.

Description

本発明は、画像の編集や補正などの画像処理に関し、特に画像の明度を調整するための明度調整装置等に関するものである。   The present invention relates to image processing such as image editing and correction, and more particularly to a brightness adjusting device for adjusting the brightness of an image.

画像を編集、補正する際に、暗い画像なら明るく、明るい画像なら暗くする処理が行われる。一般的な画像処理ソフトウエアでは、画像のRGB値を輝度としたトーンカーブやLab色空間(L*a*b*色空間)のL(明度)のみのトーンカーブを操作して、画像の明るさを調整する。しかし、RGB値を輝度としたトーンカーブの場合は、画像を明るくすると彩度が低くなり、暗くすると彩度が上がり、また、画像の明暗だけでなく色味も変わって、利用者が意図しない画像の仕上がりになってしまうことがある。   When editing or correcting an image, a process is performed in which a dark image is bright and a bright image is dark. In general image processing software, the brightness of an image is controlled by manipulating a tone curve using the RGB value of the image as luminance or a tone curve only for L (brightness) in the Lab color space (L * a * b * color space). Adjust the height. However, in the case of a tone curve with RGB values as luminance, the saturation is lowered when the image is brightened, and the saturation is increased when the image is darkened. Also, not only the lightness and darkness of the image changes, but also the user does not intend. The image may end up.

Lab色空間のL(明度)のみのトーンカーブの場合は、彩度に影響を与えずに明るさの調整を行うことができる。例えば、特許文献1には、L(明度)の調整を行った後、L値を固定してab平面上で色バランス調整を行う画像処理装置などが記載されている。   In the case of a tone curve having only L (brightness) in the Lab color space, the brightness can be adjusted without affecting the saturation. For example, Patent Document 1 describes an image processing apparatus that adjusts L (brightness) and then performs color balance adjustment on the ab plane with the L value fixed.

特開2007−228322号公報JP 2007-228322 A

しかしながら、特許文献1に記載の技術では、L(明度)の調整によっては部分的に所望の彩度は得られるが、明るさが不足している領域が発生してしまう課題があった。   However, the technique described in Patent Document 1 has a problem that a desired saturation is partially obtained by adjusting L (brightness), but a region with insufficient brightness is generated.

また、RGB値を輝度としたトーンカーブを操作して画像の明るさを調整する場合、部分的に所望の明るさは得られるが、彩度が不足する領域が発生してしまう課題があった。   In addition, when adjusting the brightness of an image by operating a tone curve with RGB values as luminance, there is a problem that a desired brightness can be partially obtained but a region with insufficient saturation is generated. .

本発明は、前述した問題点に鑑みてなされたもので、その目的とすることは、利用者によっての見た目の彩度を保持しつつ、画像の明るさを調整できる明度調整装置等を提供することである。   The present invention has been made in view of the above-described problems, and an object of the present invention is to provide a brightness adjustment device and the like that can adjust the brightness of an image while maintaining the saturation of the appearance of the user. That is.

前述した目的を達成するための第1の発明は、所定の色空間で表された入力画像の明度調整を行う明度調整装置であって、前記入力画像に対する出力画像の明度の変化量を画像処理強度として決定する画像処理強度決定手段と、前記所定の色空間で表された画像を、輝度情報を含む他の色空間の画像に変換する色空間変換手段と、決定された前記画像処理強度に応じて、前記入力画像、及び、当該入力画像を前記色空間変換手段によって変換した前記他の色空間の画像のそれぞれに対して、輝度調整を行う輝度調整手段と、輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれに対して、特徴量を取得する特徴量取得手段と、取得された前記特徴量に基づいて、前記入力画像の明度調整を行う明度調整手段と、を備えることを特徴とする明度調整装置である。
ここで「所定の色空間」とは、例えば、RGB色空間である。「輝度情報を含む他の色空間」とは、例えば、YCbCr色空間やLab色空間である。
第1の発明によって、利用者によっての見た目の彩度を保持しつつ、画像の明るさを調整することが可能となる。
A first invention for achieving the above-described object is a lightness adjusting device for adjusting the lightness of an input image represented in a predetermined color space, wherein the amount of change in the lightness of the output image with respect to the input image is subjected to image processing. Image processing intensity determining means for determining the intensity, color space converting means for converting the image represented in the predetermined color space into an image of another color space including luminance information, and the determined image processing intensity. In response to the input image and the other color space image obtained by converting the input image by the color space conversion unit, a luminance adjustment unit that performs luminance adjustment, and the input that is not luminance-adjusted For each of the image, the brightness-adjusted input image, and the brightness-adjusted image in the other color space, a feature amount acquisition unit that acquires a feature amount, and based on the acquired feature amount, The input , And brightness adjusting means for performing brightness adjustment of the image is the brightness adjusting device, characterized in that it comprises a.
Here, the “predetermined color space” is, for example, an RGB color space. “Another color space including luminance information” is, for example, a YCbCr color space or a Lab color space.
According to the first invention, it is possible to adjust the brightness of the image while maintaining the apparent saturation of the user.

前記特徴量取得手段は、それぞれの画像について、前記色空間変換手段によって輝度情報を取得し、全画素に対して、注目画素の近傍の明るさを示す特徴量と、注目画素の近傍の明るさに対する比率を示す特徴量とを取得することが望ましい。
これによって、輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれの画像に対して、注目画素における近傍の画素の明るさに関係する特徴量を取得することができる。
The feature amount acquisition unit acquires luminance information for each image by the color space conversion unit, and for all pixels, a feature amount indicating brightness in the vicinity of the target pixel and brightness in the vicinity of the target pixel. It is desirable to acquire a feature amount indicating a ratio to
Thereby, the brightness of the neighboring pixels in the target pixel with respect to each of the input image that has not been brightness adjusted, the input image that has been brightness adjusted, and the image of the other color space that has been brightness adjusted. It is possible to acquire a feature quantity related to.

前記特徴量取得手段は、それぞれの画像について、前記色空間変換手段によって輝度情報を取得し、全画素に対して、注目画素と周辺画素とから平均の輝度値を算出して、注目画素の位置の輝度値とした特徴量A(それぞれの画像について、特徴量AA、AB、ACという。)を取得するとともに、注目画素の輝度値と、特徴量Aの注目画素の位置の輝度値との比を、注目画素の位置の画素値とした特徴量B(それぞれの画像について、特徴量BA、BB、BCという。)を取得することが望ましい。
これによって、輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれの画像に対して、注目画素における近傍の画素の輝度値に関係する特徴量を取得することができる。
The feature amount acquisition unit acquires luminance information for each image by the color space conversion unit, calculates an average luminance value from the target pixel and peripheral pixels for all pixels, and calculates the position of the target pixel. The feature value A (referred to as feature values AA, AB, and AC for each image) is acquired and the ratio between the brightness value of the target pixel and the brightness value at the position of the target pixel of the feature amount A is acquired. It is desirable to acquire a feature amount B (referred to as feature amounts BA, BB, and BC for each image) as a pixel value at the position of the target pixel.
Accordingly, the luminance value of the pixel in the vicinity of the target pixel with respect to each of the input image that has not been adjusted in luminance, the input image that has been adjusted in luminance, and the image in the other color space that has been adjusted in luminance. It is possible to acquire a feature quantity related to.

前記明度調整手段は、前記入力画像の全画素に対して、前記特徴量BB又は前記特徴量BCのうち、前記特徴量BAと差の小さい特徴量に係る画像の画素値を採用する第1の条件、前記特徴量AB又は前記特徴量ACのうち、前記特徴量AAとの差が大きい特徴量に係る画像の画素値を採用する第2の条件、及び、前記特徴量AB又は前記特徴量ACのうち、前記特徴量AAとの差が小さい特徴量に係る画像の画素値を採用する第3の条件を用いて、画素ごとの出力画素値を算出することが望ましい。
これによって、複数の色空間の特徴量に基づいて、自然な明るさの調整を実現することができる。
The brightness adjustment unit employs, for all the pixels of the input image, a pixel value of an image related to a feature quantity having a small difference from the feature quantity BA among the feature quantity BB or the feature quantity BC. A second condition that employs a pixel value of an image relating to a feature quantity having a large difference from the feature quantity AA among the condition, the feature quantity AB or the feature quantity AC, and the feature quantity AB or the feature quantity AC Among them, it is desirable to calculate the output pixel value for each pixel using the third condition that employs the pixel value of the image relating to the feature amount having a small difference from the feature amount AA.
Thus, natural brightness adjustment can be realized based on the feature quantities of a plurality of color spaces.

前記明度調整手段は、K、α、βをK+α+β=1を満たす定数として、出力画素値を式(1)で算出することが望ましい。
これによって、複数の色空間の特徴量に基づいて採用された画素値を、目的の画質に応じて調整して使用することができる。
It is desirable that the lightness adjusting means calculates K, α, and β as constants satisfying K + α + β = 1, and calculates an output pixel value by the equation (1).
Accordingly, the pixel values adopted based on the feature amounts of the plurality of color spaces can be used after being adjusted according to the target image quality.

前記明度調整手段は、前記第1の判定条件において、前記特徴量の差が許容範囲より大きい場合、輝度調整していない前記入力画像の画素値を採用することが望ましい。
これによって、見た目に自然な明るさの調整を実現することが可能となる。
It is desirable that the brightness adjustment unit adopts a pixel value of the input image that has not been subjected to luminance adjustment when the difference in the feature amount is larger than an allowable range in the first determination condition.
This makes it possible to realize natural brightness adjustment.

前記画像処理強度は、前記入力画像の明度に対する出力画像の明度の対応関係を表すトーンカーブであることが望ましい。
これによって、トーンカーブにより見た目に分かりやすく明度調整を行うことができる。
The image processing intensity is preferably a tone curve representing a correspondence relationship between the brightness of the input image and the brightness of the output image.
This makes it possible to adjust the brightness with a tone curve that is easy to understand visually.

前記明度調整手段により明度調整された前記入力画像を出力画像として出力する出力手段をさらに備えることが望ましい。
これによって、明るさが調整された画像を外部に出力したり、表示部に表示したりすることができる。
It is desirable to further include output means for outputting the input image whose brightness has been adjusted by the brightness adjustment means as an output image.
As a result, an image whose brightness has been adjusted can be output to the outside or displayed on the display unit.

第2の発明は、所定の色空間で表された入力画像の明度調整を行う明度調整方法であって、前記入力画像に対する出力画像の明度の変化量を画像処理強度として決定する画像処理強度決定ステップと、前記所定の色空間で表された画像を、輝度情報を含む他の色空間の画像に変換する色空間変換ステップと、決定された前記画像処理強度に応じて、前記入力画像、及び、当該入力画像を前記色空間変換ステップによって変換した前記他の色空間の画像のそれぞれに対して、輝度調整を行う輝度調整ステップと、輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれに対して、特徴量を取得する特徴量取得ステップと、取得された前記特徴量に基づいて、前記入力画像の明度調整を行う明度調整ステップと、を含むことを特徴とする明度調整方法である。
第2の発明によって、利用者によっての見た目の彩度を保持しつつ、画像の明るさを調整することが可能となる。
A second invention is a lightness adjustment method for adjusting the lightness of an input image represented in a predetermined color space, and determining an image processing intensity that determines an amount of change in lightness of an output image with respect to the input image as an image processing intensity. A color space conversion step of converting the image represented in the predetermined color space into an image of another color space including luminance information, the input image according to the determined image processing intensity, and A luminance adjustment step for performing luminance adjustment on each of the images of the other color spaces obtained by converting the input image by the color space conversion step; the input image that has not been subjected to luminance adjustment; and the input that has undergone luminance adjustment A feature amount acquisition step of acquiring a feature amount for each of the image and the image of the other color space whose brightness has been adjusted, and the input image based on the acquired feature amount. And brightness adjusting step of adjusting a brightness adjusting method characterized in that it comprises a.
According to the second invention, it is possible to adjust the brightness of the image while maintaining the apparent saturation of the user.

第3の発明は、コンピュータを、所定の色空間で表された入力画像の明度調整を行う明度調整装置として機能させるためのプログラムであって、前記コンピュータを、前記入力画像に対する出力画像の明度の変化量を画像処理強度として決定する画像処理強度決定手段、前記所定の色空間で表された画像を、輝度情報を含む他の色空間の画像に変換する色空間変換手段、決定された前記画像処理強度に応じて、前記入力画像、及び、当該入力画像を前記色空間変換手段によって変換した前記他の色空間の画像のそれぞれに対して、輝度調整を行う輝度調整手段、輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれに対して、特徴量を取得する特徴量取得手段、取得された前記特徴量に基づいて、前記入力画像の明度調整を行う明度調整手段、として機能させるためのプログラムである。
第3の発明のプログラムを汎用のコンピュータにインストールすることによって、第1の発明の明度調整装置を得て、第2の発明の明度調整方法を実行することができる。
A third invention is a program for causing a computer to function as a brightness adjustment device for adjusting the brightness of an input image represented in a predetermined color space, the computer controlling the brightness of an output image with respect to the input image. Image processing intensity determining means for determining the amount of change as image processing intensity, color space converting means for converting an image represented in the predetermined color space into an image of another color space including luminance information, and the determined image In accordance with the processing intensity, a luminance adjustment unit that performs luminance adjustment for each of the input image and the image of the other color space obtained by converting the input image by the color space conversion unit, the luminance is not adjusted Feature quantity acquisition means for acquiring a feature quantity for each of the input image, the brightness-adjusted input image, and the brightness-adjusted image of the other color space, Based on the feature quantity, a program for causing the brightness adjusting means for performing brightness adjustment of the input image function as a.
By installing the program of the third invention in a general-purpose computer, the brightness adjustment device of the first invention can be obtained and the brightness adjustment method of the second invention can be executed.

本発明により、利用者にとっての見た目の彩度を保持しつつ、画像の明るさを調整することが可能となる。   According to the present invention, it is possible to adjust the brightness of an image while maintaining the apparent saturation for the user.

本発明の実施の形態に係る明度調整装置のハードウェアの構成例を示す図である。It is a figure which shows the structural example of the hardware of the brightness adjustment apparatus which concerns on embodiment of this invention. 明度調整装置の機能構成例を示すブロック図である。It is a block diagram which shows the function structural example of a brightness adjustment apparatus. トーンカーブの例を説明する図である。It is a figure explaining the example of a tone curve. 明度調整処理を説明するフローチャートである。It is a flowchart explaining a brightness adjustment process. 入力画像の一例を示す図である。It is a figure which shows an example of an input image. 従来技術を用いたRGB色空間による明度調整画像の一例を示す図である。It is a figure which shows an example of the brightness adjustment image by RGB color space using a prior art. YCbCr色空間のY(輝度)チャンネルによる明度調整画像の一例を示す図である。It is a figure which shows an example of the brightness adjustment image by the Y (luminance) channel of YCbCr color space. 本実施の形態による明度調整画像の一例を示す図である。It is a figure which shows an example of the brightness adjustment image by this Embodiment.

以下、図面に基づいて、本発明の実施の形態を詳細に説明する。   Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.

[本発明の実施の形態]
図1は、本発明の実施の形態に係る明度調整装置1のハードウェアの構成例を示す図である。尚、図1のハードウェア構成は一例であり、用途、目的に応じて様々な構成を採ることが可能である。
[Embodiments of the present invention]
FIG. 1 is a diagram illustrating a hardware configuration example of a brightness adjustment apparatus 1 according to an embodiment of the present invention. Note that the hardware configuration in FIG. 1 is an example, and various configurations can be adopted depending on the application and purpose.

明度調整装置1は、制御部11、記憶部12、メディア入出力部13、通信制御部14、入力部15、表示部16、周辺機器I/F部17等が、バス18を介して接続される。   In the brightness adjustment device 1, a control unit 11, a storage unit 12, a media input / output unit 13, a communication control unit 14, an input unit 15, a display unit 16, a peripheral device I / F unit 17 and the like are connected via a bus 18. The

制御部11は、CPU(Central Processing Unit)、ROM(Read Only Memory)、RAM(Random Access Memory)等で構成される。CPUは、記憶部12、ROM、記録媒体等に格納されるプログラムをRAM上のワークメモリ領域に呼び出して実行し、バス18を介して接続された各装置を駆動制御し、明度調整装置1が行う後述する処理を実現する。ROMは、不揮発性メモリであり、明度調整装置1のブートプログラムやBIOS(Basic Input/Output System)等のプログラム、データ等を恒久的に保持している。RAMは、揮発性メモリであり、記憶部12、ROM、記録媒体等からロードしたプログラム、データ等を一時的に保持するとともに、制御部11が各種処理を行う為に使用するワークエリアを備える。   The control unit 11 includes a CPU (Central Processing Unit), a ROM (Read Only Memory), a RAM (Random Access Memory), and the like. The CPU calls and executes a program stored in the storage unit 12, ROM, recording medium, etc. to a work memory area on the RAM, drives and controls each device connected via the bus 18, and the brightness adjustment device 1 The process to be described later is realized. The ROM is a non-volatile memory, and permanently stores programs such as a boot program of the brightness adjustment device 1, a BIOS (Basic Input / Output System), data, and the like. The RAM is a volatile memory, and temporarily stores a program, data, and the like loaded from the storage unit 12, ROM, recording medium, and the like, and includes a work area used by the control unit 11 to perform various processes.

記憶部12は、HDD(ハードディスクドライブ)等であり、制御部11が実行するプログラム、プログラム実行に必要なデータ、OS(オペレーティングシステム)等が格納される。プログラムに関しては、OSに相当する制御プログラムや、後述する処理を明度調整装置1に実行させるためのアプリケーションプログラムが格納されている。これらの各プログラムコードは、制御部11により必要に応じて読み出されてRAMに移され、CPUに読み出されて各種の手段として実行される。   The storage unit 12 is an HDD (hard disk drive) or the like, and stores a program executed by the control unit 11, data necessary for program execution, an OS (operating system), and the like. As for the program, a control program corresponding to the OS and an application program for causing the brightness adjusting apparatus 1 to execute processing described later are stored. Each of these program codes is read by the control unit 11 as necessary, transferred to the RAM, read by the CPU, and executed as various means.

メディア入出力部13(ドライブ装置)は、データの入出力を行い、例えば、CDドライブ(−ROM、−R、−RW等)、DVDドライブ(−ROM、−R、−RW等)等のメディア入出力装置を有する。   The media input / output unit 13 (drive device) inputs / outputs data, for example, media such as a CD drive (-ROM, -R, -RW, etc.), DVD drive (-ROM, -R, -RW, etc.) Has input / output devices.

通信制御部14は、通信制御装置、通信ポート等を有し、明度調整装置1とネットワーク間の通信を媒介する通信インターフェイスであり、ネットワークを介して、他の装置間との通信制御を行う。ネットワークは、有線、無線を問わない。   The communication control unit 14 includes a communication control device, a communication port, and the like, and is a communication interface that mediates communication between the brightness adjustment device 1 and the network, and performs communication control between other devices via the network. The network may be wired or wireless.

入力部15は、データの入力を行い、例えば、キーボード、マウス等のポインティングデバイス、テンキー等の入力装置を有する。入力部15を介して、明度調整装置1に対して、操作指示、動作指示、データ入力等を行うことができる。   The input unit 15 inputs data and includes, for example, a keyboard, a pointing device such as a mouse, and an input device such as a numeric keypad. An operation instruction, an operation instruction, data input, and the like can be performed on the brightness adjustment device 1 via the input unit 15.

表示部16は、CRTモニタ、液晶パネル等のディスプレイ装置、ディスプレイ装置と連携して明度調整装置1のビデオ機能を実現するための論理回路等(ビデオアダプタ等)を有する。   The display unit 16 includes a display device such as a CRT monitor and a liquid crystal panel, and a logic circuit (such as a video adapter) for realizing the video function of the brightness adjustment device 1 in cooperation with the display device.

周辺機器I/F(インターフェイス)部17は、明度調整装置1に周辺機器を接続させるためのポートであり、周辺機器I/F部17を介して明度調整装置1は周辺機器とのデータの送受信を行う。周辺機器I/F部17は、USB(Universal Serial Bus)やIEEE(The Institute of Electrical and
Electronics Engineers)1394やRS−235C等で構成されており、通常複数の周辺機器I/Fを有する。周辺機器との接続形態は有線、無線を問わない。
The peripheral device I / F (interface) unit 17 is a port for connecting a peripheral device to the brightness adjustment device 1. The brightness adjustment device 1 transmits and receives data to and from the peripheral device via the peripheral device I / F unit 17. I do. The peripheral device I / F unit 17 is a USB (Universal Serial Bus) or IEEE (The Institute of Electrical and
Electronics Engineers) 1394, RS-235C, etc., and usually has a plurality of peripheral devices I / F. The connection form with the peripheral device may be wired or wireless.

バス18は、各装置間の制御信号、データ信号等の授受を媒介する経路である。   The bus 18 is a path that mediates transmission / reception of control signals, data signals, and the like between the devices.

図2は、明度調整装置1の機能構成例を示すブロック図である。
明度調整装置1の機能は、画像入力部21、画像処理強度決定部22、色空間変換部23、輝度調整部24、特徴量取得部25、明度調整部26、および画像表示部27により構成される。図2に示す機能部のうちの少なくとも一部は、図1の制御部11により明度調整処理プログラムが実行されることによって実現される。
FIG. 2 is a block diagram illustrating a functional configuration example of the brightness adjustment apparatus 1.
The function of the brightness adjustment device 1 includes an image input unit 21, an image processing intensity determination unit 22, a color space conversion unit 23, a brightness adjustment unit 24, a feature amount acquisition unit 25, a brightness adjustment unit 26, and an image display unit 27. The At least a part of the functional units shown in FIG. 2 is realized by executing a brightness adjustment processing program by the control unit 11 of FIG.

画像入力部21は、メディア入出力部13、通信制御部14、または周辺機器I/F(インターフェイス)部17を介して、記録メディアや周辺機器からRGB画像を入力したり、あるいは、予め記憶部12に記憶された画像を取得する。画像入力部21は、入力(取得)したRGB画像を、画像処理強度決定部22、輝度調整部24、および画像表示部27に出力する。また、画像入力部21は、外部から入力したRGB画像を記憶部12に記憶させる。   The image input unit 21 inputs an RGB image from a recording medium or a peripheral device via the media input / output unit 13, the communication control unit 14, or the peripheral device I / F (interface) unit 17, or stores in advance a storage unit The image stored in 12 is acquired. The image input unit 21 outputs the input (acquired) RGB image to the image processing intensity determination unit 22, the luminance adjustment unit 24, and the image display unit 27. The image input unit 21 stores an RGB image input from the outside in the storage unit 12.

画像処理強度決定部22は、画像入力部21からの入力画像を解析し、画像の特徴量を抽出し、特徴量に応じた画像処理強度(例えば、トーンカーブの形状)を決定する。   The image processing intensity determination unit 22 analyzes the input image from the image input unit 21, extracts the feature amount of the image, and determines the image processing intensity (for example, the shape of the tone curve) according to the feature amount.

また、画像処理強度決定部22は、画像入力部21からの入力画像、及び、トーンカーブを表示部16に表示して、ユーザにより入力部15からトーンカーブを操作されて、画像処理強度を決定しても良い。   The image processing intensity determination unit 22 displays the input image and tone curve from the image input unit 21 on the display unit 16, and determines the image processing intensity by operating the tone curve from the input unit 15 by the user. You may do it.

トーンカーブとは、画像の全体的な明るさやコントラストを調整する際に用いられる、入力画像の画素値と出力画像の画素値との対応関係を示すグラフである。トーンカーブは、図3に示すように、変更対象となる値が線グラフ(図中、実線)で表されており、初期状態では正比例を示す直線(図中、破線)となる。例えば、入力画像のあるピクセルについて明度調整を行うとする。このピクセルの明るさの引き上げ量または引き下げ量をΔLとする。ΔLは、一般的な画像処理ソフトのトーンカーブ調整で画像の明度を調整した場合に、入力画像に対する出力画像のL(明度)の変化量(トーンカーブでの表示は「+ΔL」または「−ΔL」)として得られる値である。   The tone curve is a graph showing the correspondence between the pixel value of the input image and the pixel value of the output image used when adjusting the overall brightness and contrast of the image. As shown in FIG. 3, the value to be changed is represented by a line graph (solid line in the figure), and the tone curve is a straight line (broken line in the figure) showing a direct proportion in the initial state. For example, assume that brightness adjustment is performed for a certain pixel of the input image. Let the amount of increase or decrease in the brightness of this pixel be ΔL. ΔL is the amount of change in L (brightness) of the output image with respect to the input image when the brightness of the image is adjusted by tone curve adjustment of general image processing software (display on the tone curve is “+ ΔL” or “−ΔL”) )).

色空間変換部23は、入力される画像を、RGB色空間からYCbCr色空間やLab色空間に変換する。以下、本実施の形態では、RGB色空間をYCbCr色空間に変換した画像を明度調整処理に用いることとする。
なお、色空間変換部23が変換する変換先の色空間は、輝度値を表す輝度信号(輝度チャンネル)が、その他の信号と分離されている色空間であれば、いずれでもよく、YCbCr色空間やLab色空間に限らない。
The color space conversion unit 23 converts the input image from the RGB color space to the YCbCr color space or the Lab color space. Hereinafter, in the present embodiment, an image obtained by converting the RGB color space to the YCbCr color space is used for the brightness adjustment processing.
Note that the color space of the conversion destination converted by the color space conversion unit 23 may be any color space as long as the luminance signal (luminance channel) representing the luminance value is separated from other signals, and the YCbCr color space. And the Lab color space.

RGB色空間からYCbCr色空間への変換及びその逆変換、ならびに、RGB色空間からLab色空間への変換及びその逆変換は、一般的な色空間の変換手法を用いて行えばよい。
例えば、RGB色空間からYCbCr色空間への変換、及び、その逆変換であるYCbCr色空間からRGB色空間への変換は、それぞれ以下の式(2)及び式(3)で行う。但し、R、G、B、Yの範囲は0〜255とし、Cb、Crの範囲は中心を128として0〜255とする。
The conversion from the RGB color space to the YCbCr color space and its reverse conversion, and the conversion from the RGB color space to the Lab color space and its reverse conversion may be performed using a general color space conversion method.
For example, the conversion from the RGB color space to the YCbCr color space and the reverse conversion from the YCbCr color space to the RGB color space are performed by the following equations (2) and (3), respectively. However, the range of R, G, B, and Y is 0 to 255, and the range of Cb and Cr is 0 to 255 with 128 as the center.

YCbCr色空間とは、輝度信号(Y)、輝度信号Yと青色成分Bの差(U:B−Y=Cb)、輝度信号Yと赤色成分Rの差(V:R−Y=Cr)の3つの情報で色を表すカラーモデルである。
Lab色空間とは、補色空間の一種で、明度(明るさ)を表わす「L」、赤(R)から緑(G)への色度を表わす「a」、青(B)から黄色(Y)への色度を表わす「b」の3つの次元を持ち、この3次元空間における変化量と、その変化によって受ける視覚の色変化の印象とが比例するよう補正された、人間が知覚できる全ての色を表すカラーモデルである。
The YCbCr color space is the luminance signal (Y), the difference between the luminance signal Y and the blue component B (U: BY = Cb), and the difference between the luminance signal Y and the red component R (V: R−Y = Cr). It is a color model that expresses color with three pieces of information.
The Lab color space is a type of complementary color space, “L” representing lightness (brightness), “a” representing chromaticity from red (R) to green (G), and blue (B) to yellow (Y 3) “b” representing the chromaticity of), and the amount of change in this three-dimensional space is corrected to be proportional to the impression of the visual color change caused by the change, all that can be perceived by humans It is a color model that represents the color of.

輝度調整部24は、画像処理強度決定部22で決定されたトーンカーブを用いて、画像のチャンネルに対して輝度調整を行う。
具体的には、輝度調整部24は、画像入力部21からの入力画像RGBに対して、RGBの各チャンネルをトーンカーブを用いて輝度調整する。
また、輝度調整部24は、画像入力部21からの入力画像RGBを色空間変換部23へ出力し、色空間変換部23によってYCbCr色空間に変換された画像を取得し、取得した画像のY(輝度)チャンネルのみをトーンカーブを用いて輝度調整する。
そして、輝度調整部24は、RGBの各チャンネルが輝度調整されたRGB色空間の画像、および、Y(輝度)チャンネルのみが輝度調整されたYCbCr色空間の画像を、特徴量取得部25に出力する。
The luminance adjustment unit 24 performs luminance adjustment on the image channel using the tone curve determined by the image processing intensity determination unit 22.
Specifically, the luminance adjustment unit 24 adjusts the luminance of each of the RGB channels with respect to the input image RGB from the image input unit 21 using a tone curve.
Further, the luminance adjustment unit 24 outputs the input image RGB from the image input unit 21 to the color space conversion unit 23, acquires the image converted into the YCbCr color space by the color space conversion unit 23, and Y of the acquired image (Luminance) Adjust the brightness of only the channel using the tone curve.
Then, the luminance adjustment unit 24 outputs to the feature amount acquisition unit 25 an image in the RGB color space in which the luminance of each RGB channel is adjusted, and an image in the YCbCr color space in which only the Y (luminance) channel is adjusted in luminance. To do.

特徴量取得部25は、各画像のY(輝度)チャンネルから、2つの特徴量を取得する。
具体的には、まず、特徴量取得部25は、画像入力部21からの入力画像(以下、元画像Aと記載する)、輝度調整部24からのRGBの各チャンネルが輝度調整されたRGB色空間の画像(以下、輝度調整画像Bと記載する)、および、Y(輝度)チャンネルのみが輝度調整されたYCbCr色空間の画像(以下、輝度調整画像Cと記載する)を入力する。
The feature amount acquisition unit 25 acquires two feature amounts from the Y (luminance) channel of each image.
Specifically, first, the feature amount acquisition unit 25 is an RGB image in which the input image from the image input unit 21 (hereinafter referred to as the original image A) and the RGB channels from the luminance adjustment unit 24 are adjusted in luminance. A space image (hereinafter referred to as a brightness adjustment image B) and a YCbCr color space image (hereinafter referred to as a brightness adjustment image C) in which only the Y (luminance) channel has been adjusted in brightness are input.

そして、特徴量取得部25は、元画像Aを色空間変換部23へ出力し、色空間変換部23によってYCbCr色空間に変換された画像のY(輝度)チャンネルを取得する(この処理は一度行っているので、色空間変換部23又は輝度調整部24から、変換済みのY(輝度)チャンネルを取得しても良い)。そして、特徴量取得部25は、元画像Aに係るY(輝度)チャンネルの全画素に対して、N×N(例えば、3×3)の移動平均フィルタにより、注目画素と周辺画素とから平均の輝度値を算出して、注目画素の位置の輝度値とした特徴量AAを取得する。すなわち、特徴量AAは、全画素に注目画素の近傍の輝度値の平均値をもつ画像である。   Then, the feature amount acquisition unit 25 outputs the original image A to the color space conversion unit 23, and acquires the Y (luminance) channel of the image converted into the YCbCr color space by the color space conversion unit 23 (this process is performed once). Therefore, the converted Y (luminance) channel may be acquired from the color space conversion unit 23 or the luminance adjustment unit 24). Then, the feature amount acquisition unit 25 calculates the average of the target pixel and the surrounding pixels with respect to all pixels of the Y (luminance) channel related to the original image A by using an N × N (for example, 3 × 3) moving average filter. The feature value AA is obtained as the brightness value at the position of the target pixel. That is, the feature amount AA is an image having an average value of luminance values in the vicinity of the target pixel for all pixels.

同様に、特徴量取得部25は、輝度調整画像Bを色空間変換部23へ出力し、色空間変換部23によってYCbCr色空間に変換された画像のY(輝度)チャンネルを取得する。そして、特徴量取得部25は、輝度調整画像Bに係るY(輝度)チャンネルの全画素に対して、N×Nの移動平均フィルタにより、注目画素と周辺画素とから平均の輝度値を算出して、注目画素の位置の輝度値とした特徴量ABを取得する。   Similarly, the feature amount acquisition unit 25 outputs the brightness adjustment image B to the color space conversion unit 23, and acquires the Y (luminance) channel of the image converted into the YCbCr color space by the color space conversion unit 23. Then, the feature amount acquisition unit 25 calculates an average luminance value from the target pixel and the surrounding pixels by using an N × N moving average filter for all pixels of the Y (luminance) channel related to the luminance adjustment image B. Thus, the feature amount AB as the luminance value at the position of the target pixel is acquired.

また、特徴量取得部25は、輝度調整画像Cに係るY(輝度)チャンネルの全画素に対して、N×Nの移動平均フィルタにより、注目画素と周辺画素とから平均の輝度値を算出して、注目画素の位置の輝度値とした特徴量ACを取得する。   Also, the feature amount acquisition unit 25 calculates an average luminance value from the target pixel and the surrounding pixels by using an N × N moving average filter for all pixels of the Y (luminance) channel related to the luminance adjustment image C. Thus, the feature amount AC is acquired as the luminance value at the position of the target pixel.

次に、特徴量取得部25は、元画像Aに係るY(輝度)チャンネルの全画素に対して、注目画素の輝度値と、特徴量AAの注目画素の位置の輝度値との比を、注目画素の位置の画素値とした特徴量BAを取得する。すなわち、特徴量BAは、全画素に、注目画素の輝度値とその近傍の輝度値の平均値との比をもつ画像である。   Next, the feature amount acquisition unit 25 calculates the ratio between the luminance value of the target pixel and the luminance value of the position of the target pixel of the feature amount AA for all pixels of the Y (luminance) channel related to the original image A. A feature amount BA is obtained as a pixel value at the position of the target pixel. That is, the feature amount BA is an image having a ratio between the luminance value of the target pixel and the average value of the luminance values in the vicinity thereof for all pixels.

同様に、特徴量取得部25は、輝度値調整画像Bに係るY(輝度)チャンネルの全画素に対して、注目画素の輝度値と、特徴量ABの注目画素の位置の輝度値との比を、注目画素の位置の画素値とした特徴量BBを取得する。   Similarly, the feature amount acquisition unit 25 compares the luminance value of the target pixel and the luminance value of the position of the target pixel of the feature amount AB with respect to all pixels of the Y (luminance) channel related to the luminance value adjusted image B. Is obtained as a pixel value at the position of the target pixel.

また、特徴量取得部25は、輝度値調整画像Cに係るY(輝度)チャンネルの全画素に対して、注目画素の輝度値と、特徴量ACの注目画素の位置の輝度値との比を、注目画素の位置の画素値とした特徴量BCを取得する。   Further, the feature amount acquisition unit 25 calculates the ratio between the luminance value of the target pixel and the luminance value at the position of the target pixel of the feature amount AC for all the pixels of the Y (luminance) channel related to the luminance value adjusted image C. Then, the feature value BC is acquired as the pixel value at the position of the target pixel.

そして、特徴量取得部25は、特徴量AA、特徴量AB、特徴量AC、特徴量BA、特徴量BB、特徴量BCを、明度調整部26に出力する。   Then, the feature amount acquisition unit 25 outputs the feature amount AA, the feature amount AB, the feature amount AC, the feature amount BA, the feature amount BB, and the feature amount BC to the brightness adjustment unit 26.

明度調整部26は、特徴量取得部25からの特徴量AA、特徴量AB、特徴量AC(以上、まとめて特徴量Aともいう)、特徴量BA、特徴量BB、特徴量BC(以上、まとめて特徴量Bともいう)に基づいて、画像の各画素ごとに、以下の3つの判定条件を適用し、明度調整を行った画像を生成する。   The brightness adjustment unit 26 includes a feature amount AA, a feature amount AB, a feature amount AC (hereinafter also referred to as a feature amount A), a feature amount BA, a feature amount BB, and a feature amount BC (and above) from the feature amount acquisition unit 25. Based on the feature amount B), the following three determination conditions are applied to each pixel of the image to generate an image with the brightness adjusted.

(第1の判定条件)
第1の判定条件では、特徴量BA、特徴量BB、特徴量BCを比較し、見た目の違和感が少なく、明るさ補正を実施する色空間を判定する。なお、特徴量Bの許容範囲は、元画像Aの輝度に近い色空間が得られるような値に予め決定される。
(First judgment condition)
In the first determination condition, the feature amount BA, the feature amount BB, and the feature amount BC are compared, and the color space in which the brightness correction is performed with less visual discomfort is determined. Note that the allowable range of the feature amount B is determined in advance so as to obtain a color space close to the luminance of the original image A.

(1−1)元画像Aの特徴量BAと輝度調整画像Bの特徴量BBの差<元画像Aの特徴量BAと輝度調整画像Cの特徴量BCの差の場合、輝度調整画像Bの色空間を採用する。
(1−2)元画像Aの特徴量BAと輝度調整画像Bの特徴量BBの差>元画像Aの特徴量BAと輝度調整画像Cの特徴量BCの差の場合、輝度調整画像Cの色空間を採用する。
(1-1) When the difference between the feature value BA of the original image A and the feature value BB of the brightness adjustment image B <the difference between the feature value BA of the original image A and the feature value BC of the brightness adjustment image C, Adopt a color space.
(1-2) If the difference between the feature amount BA of the original image A and the feature amount BB of the brightness adjustment image B> the difference between the feature amount BA of the original image A and the feature amount BC of the brightness adjustment image C, the brightness adjustment image C Adopt a color space.

(1−3)特徴量Bの許容範囲<元画像Aの特徴量BAと輝度調整画像Bの特徴量BBの差<元画像Aの特徴量BAと輝度調整画像Cの特徴量BCの差の場合、元画像Aの色空間を採用する。
(1−4)特徴量Bの許容範囲<元画像Aの特徴量BAと輝度調整画像Cの特徴量BCの差<元画像Aの特徴量BAと輝度調整画像Bの特徴量BBの差の場合、元画像Aの色空間を採用する。
(1-3) Allowable range of feature quantity B <difference between feature quantity BA of original image A and feature quantity BB of brightness adjusted image B <difference between feature quantity BA of original image A and feature quantity BC of brightness adjusted image C In this case, the color space of the original image A is adopted.
(1-4) Allowable range of feature quantity B <difference between feature quantity BA of original image A and feature quantity BC of brightness adjusted image C <difference between feature quantity BA of original image A and feature quantity BB of brightness adjusted image B In this case, the color space of the original image A is adopted.

(第2の判定条件)
第2の判定条件では、特徴量AA、特徴量AB、特徴量ACを比較し、輝度特徴量の大きい色空間を判定する。
(2−1)元画像Aの特徴量AAと輝度調整画像Bの特徴量ABの差<元画像Aの特徴量AAと輝度調整画像Cの特徴量ACの差の場合、輝度調整画像Cの色空間を採用する。
(2−2)元画像Aの特徴量AAと輝度調整画像Bの特徴量ABの差>元画像Aの特徴量AAと輝度調整画像Cの特徴量ACの差の場合、輝度調整画像Bの色空間を採用する。
(Second determination condition)
Under the second determination condition, the feature amount AA, the feature amount AB, and the feature amount AC are compared to determine a color space having a large luminance feature amount.
(2-1) When the difference between the feature amount AA of the original image A and the feature amount AB of the brightness adjustment image B <the difference between the feature amount AA of the original image A and the feature amount AC of the brightness adjustment image C, the brightness adjustment image C Adopt a color space.
(2-2) The difference between the feature amount AA of the original image A and the feature amount AB of the brightness adjustment image B> the difference between the feature amount AA of the original image A and the feature amount AC of the brightness adjustment image C, the brightness adjustment image B Adopt a color space.

(第3の判定条件)
第3の判定条件では、第2の判定条件で採用されなかった色空間、つまり輝度特徴量の小さい色空間を判定する。
(3−1)元画像Aの特徴量AAと輝度調整画像Bの特徴量ABの差<元画像Aの特徴量AAと輝度調整画像Cの特徴量ACの差の場合、輝度調整画像Bの色空間を採用する。
(3−2)元画像Aの特徴量AAと輝度調整画像Bの特徴量ABの差>元画像Aの特徴量AAと輝度調整画像Cの特徴量ACの差の場合、輝度調整画像Cの色空間を採用する。
(Third determination condition)
In the third determination condition, a color space that is not adopted in the second determination condition, that is, a color space with a small luminance feature amount is determined.
(3-1) When the difference between the feature amount AA of the original image A and the feature amount AB of the brightness adjustment image B <the difference between the feature amount AA of the original image A and the feature amount AC of the brightness adjustment image C, the brightness adjustment image B Adopt a color space.
(3-2) If the difference between the feature amount AA of the original image A and the feature amount AB of the brightness adjustment image B> the difference between the feature amount AA of the original image A and the feature amount AC of the brightness adjustment image C, the brightness adjustment image C Adopt a color space.

明度調整部26は、上記した3つの判定条件を用いて、次式(4)に従って、各画素の出力画素値を決定し、明度調整した画像を生成する。なお、係数K、α、βは、K+α+β=1(例えば、K=0.5、α=0.25、β=0.25)となるように任意に設定され、それらの値は、目的の画質に応じて、適宜変更される。例えば、画像の全体の変化を少なくしたければKを大きくし、輝度変化を重要とする場合はαを大きくする。
The brightness adjustment unit 26 determines the output pixel value of each pixel according to the following equation (4) using the above-described three determination conditions, and generates an image with the brightness adjusted. The coefficients K, α, and β are arbitrarily set such that K + α + β = 1 (for example, K = 0.5, α = 0.25, β = 0.25), and their values are It is appropriately changed according to the image quality. For example, if the change in the entire image is to be reduced, K is increased, and if the change in luminance is important, α is increased.

明度調整部26は、明度調整した画像を、画像表示部27に出力する。また、明度調整部26は、明度調整した画像を、記憶部12に出力してもよいし、外部に出力してもよい(図示しない)。   The brightness adjustment unit 26 outputs the image whose brightness has been adjusted to the image display unit 27. Further, the lightness adjusting unit 26 may output the lightness-adjusted image to the storage unit 12 or to the outside (not shown).

画像表示部27は、画像入力部21からの入力画像を表示部14に表示させる。また画像表示部27は、明度調整部26で明度調整された画像を、出力画像として表示部14に表示させる。   The image display unit 27 displays the input image from the image input unit 21 on the display unit 14. The image display unit 27 causes the display unit 14 to display the image whose brightness has been adjusted by the brightness adjustment unit 26 as an output image.

(明度調整処理)
図4は、明度調整装置1が実行する明度調整処理を流れを示すフローチャートである。
(Brightness adjustment processing)
FIG. 4 is a flowchart showing the flow of brightness adjustment processing executed by the brightness adjustment apparatus 1.

ステップS1において、明度調整装置1の制御部11(画像入力部21)は、明度調整の対象となる入力画像を、メディア入出力部13、通信制御部14、または周辺機器I/F(インターフェイス)部17を介して、記録メディアや周辺機器から入力するか、あるいは、記憶部12に予め記憶された画像を取得する。   In step S1, the control unit 11 (image input unit 21) of the brightness adjustment apparatus 1 outputs an input image to be subjected to brightness adjustment as a media input / output unit 13, a communication control unit 14, or a peripheral device I / F (interface). An image is input from a recording medium or a peripheral device via the unit 17 or an image stored in advance in the storage unit 12 is acquired.

ステップS2において、明度調整装置1の制御部11(画像処理強度決定部22)は、ステップS1の処理で入力された画像を解析し、画像の特徴量に応じたトーンカーブの形状を決定する。トーンカーブの形状は、利用者が調整して決定するか、あるいは、画像解析結果で得られた画像特徴量に応じて自動的に決定される。   In step S2, the control unit 11 (image processing intensity determination unit 22) of the brightness adjustment apparatus 1 analyzes the image input in the process of step S1, and determines the shape of the tone curve according to the feature amount of the image. The shape of the tone curve is determined by adjustment by the user, or automatically determined according to the image feature amount obtained from the image analysis result.

ステップS3において、明度調整装置1の制御部11(色空間変換部23)は、ステップS1の処理で入力された画像の色空間を、RGB色空間からYCbCr色空間(Lab色空間その他の色空間でもよいが、以下では、YCbCrとする)に変換する。色空間の変換は、一般的な色空間変換方法を用いて行う。   In step S3, the control unit 11 (color space conversion unit 23) of the brightness adjustment device 1 changes the color space of the image input in the process of step S1 from the RGB color space to the YCbCr color space (Lab color space or other color space). However, in the following, it is converted to YCbCr). The color space conversion is performed using a general color space conversion method.

ステップS4において、明度調整装置1の制御部11(輝度調整部24)は、ステップS3の処理で決定されたトーンカーブを用いて、ステップS1の処理で入力された画像のRGB各チャンネルを輝度調整するとともに、ステップS3の処理でYCbCr色空間に変換された画像のうちのY(輝度)チャンネルのみを輝度調整する。   In step S4, the control unit 11 (brightness adjustment unit 24) of the brightness adjustment device 1 uses the tone curve determined in step S3 to adjust the luminance of each RGB channel of the image input in step S1. At the same time, only the Y (luminance) channel in the image converted into the YCbCr color space in the process of step S3 is adjusted in luminance.

ステップS5において、明度調整装置1の制御部11(特徴量取得部25)は、ステップS1の処理で入力された元画像Aについて、YCbCr色空間に変換したY(輝度)チャンネルの全画素に対して、N×Nの移動平均フィルタにより、注目画素と周辺画素とから平均の輝度値を算出して、算出した輝度値を、注目画素の位置の輝度値とした特徴量AAを取得する。また、明度調整装置1の制御部11(特徴量取得部25)は、ステップS4の処理で輝度調整されたRGB色空間の輝度調整画像B、およびステップS4の処理でY(輝度)チャンネルのみが輝度調整されたYCbCr色空間の輝度調整画像Cについても、それぞれ、同様に、特徴量AB、特徴量ACを取得する(特徴量AA、特徴量AB、特徴量ACをまとめて特徴量Aという)。   In step S5, the control unit 11 (feature amount acquisition unit 25) of the brightness adjustment device 1 applies to all pixels of the Y (luminance) channel converted into the YCbCr color space for the original image A input in the process of step S1. Then, an average luminance value is calculated from the target pixel and the surrounding pixels by the N × N moving average filter, and the feature amount AA is obtained using the calculated luminance value as the luminance value at the position of the target pixel. In addition, the control unit 11 (feature amount acquisition unit 25) of the brightness adjustment apparatus 1 has only the luminance adjustment image B in the RGB color space whose luminance is adjusted in the process of step S4 and the Y (luminance) channel in the process of step S4. Similarly, the feature amount AB and the feature amount AC are acquired for the brightness adjusted image C in the YCbCr color space after the brightness adjustment (the feature amount AA, the feature amount AB, and the feature amount AC are collectively referred to as the feature amount A). .

ステップS6において、明度調整装置1の制御部11(特徴量取得部25)は、元画像Aについて、YCbCr色空間に変換したY(輝度)チャンネルの全画素に対して、注目画素の輝度値と、特徴量AAの注目画素の位置の輝度値との比を、注目画素の位置の画素値とした特徴量BAを取得する。また、明度調整装置1の制御部11(特徴量取得部25)は、輝度調整画像B、および輝度調整画像Cについても、それぞれ、特徴量AB、特徴量ACを用いて、同様に、特徴量BB、特徴量BCを取得する(特徴量BA、特徴量BB、特徴量BCをまとめて特徴量Bという)。   In step S <b> 6, the control unit 11 (feature amount acquisition unit 25) of the brightness adjustment device 1 determines the luminance value of the target pixel for all pixels of the Y (luminance) channel converted into the YCbCr color space for the original image A. Then, the feature amount BA is obtained by using the ratio of the feature amount AA to the luminance value at the position of the target pixel as the pixel value at the position of the target pixel. In addition, the control unit 11 (feature amount acquisition unit 25) of the brightness adjustment apparatus 1 similarly uses the feature amount AB and the feature amount AC for the brightness adjustment image B and the brightness adjustment image C, respectively, and the feature amount. BB and feature quantity BC are acquired (feature quantity BA, feature quantity BB, and feature quantity BC are collectively referred to as feature quantity B).

ステップS7において、明度調整装置1の制御部11(明度調整部26)は、明度調整を行う処理対象画素を選択する。一般的には、明度調整装置1の制御部11(明度調整部26)は、入力画像において、左上の画素から右下の画素まで順に選択する。   In step S <b> 7, the control unit 11 (brightness adjustment unit 26) of the brightness adjustment apparatus 1 selects a processing target pixel for performing brightness adjustment. Generally, the control unit 11 (brightness adjustment unit 26) of the brightness adjustment apparatus 1 sequentially selects from the upper left pixel to the lower right pixel in the input image.

ステップS8において、明度調整装置1の制御部11(明度調整部26)は、ステップS7の処理で選択した処理対象画素における、ステップS6の処理で取得された特徴量BA、特徴量BB、特徴量BCを比較し、前述した第1の判定条件に基づいて、見た目の違和感が少なく、明るさ補正を実施する色空間の画素値を採用する。これにより、元画像Aの特徴量BAとの差が小さい特徴量を持つ輝度調整画像の色空間の画素値が採用される。さらに、元画像Aの特徴量と選択された輝度調整画像の特徴量との差が許容範囲より大きい場合、元画像Aの色空間の画素値が採用される。   In step S8, the control unit 11 (brightness adjustment unit 26) of the brightness adjustment device 1 has the feature amount BA, the feature amount BB, and the feature amount acquired in the process of step S6 in the processing target pixel selected in the process of step S7. The BCs are compared, and based on the first determination condition described above, the pixel value of the color space in which the brightness is corrected with less visual discomfort is adopted. As a result, the pixel value of the color space of the brightness adjusted image having the feature amount with a small difference from the feature amount BA of the original image A is employed. Further, when the difference between the feature amount of the original image A and the feature amount of the selected brightness adjustment image is larger than the allowable range, the pixel value of the color space of the original image A is adopted.

ステップS9において、明度調整装置1の制御部11(明度調整部26)は、ステップS7の処理で選択した処理対象画素における、ステップS5の処理で取得された特徴量AA、特徴量AB、特徴量ACを比較し、前述した第2の判定条件に基づいて、輝度特徴量の大きい色空間の画素値を採用する。これにより、元画像Aの特徴量AAとの差が大きい特徴量を持つ輝度調整画像の色空間の画素値が採用される。   In step S9, the control unit 11 (brightness adjustment unit 26) of the brightness adjustment apparatus 1 has the feature amount AA, feature amount AB, and feature amount acquired in the process of step S5 in the processing target pixel selected in the process of step S7. AC is compared, and a pixel value in a color space having a large luminance feature amount is adopted based on the second determination condition described above. Thereby, the pixel value of the color space of the brightness adjustment image having a feature amount having a large difference from the feature amount AA of the original image A is adopted.

ステップS10において、明度調整装置1の制御部11(明度調整部26)は、前述した第3の判定条件に基づいて、ステップS7の処理で選択した処理対象画素における、ステップS9の処理で採用されなかった色空間の画素値を採用する。   In step S10, the control unit 11 (brightness adjustment unit 26) of the brightness adjustment device 1 is employed in the process of step S9 in the processing target pixel selected in the process of step S7 based on the above-described third determination condition. The pixel value of the color space that did not exist is adopted.

ステップS11において、明度調整装置1の制御部11(明度調整部26)は、ステップS8〜S10の処理で採用された色空間の各画素値から、前述の式(4)を用いて、出力画素値を決定する。   In step S11, the control unit 11 (brightness adjustment unit 26) of the brightness adjustment apparatus 1 uses the above-described equation (4) to output pixel values from the pixel values in the color space adopted in the processes in steps S8 to S10. Determine the value.

ステップS12において、明度調整部26は、全画素の明度調整処理が終了したか否かを判定し、まだ調整していない画素があると判定した場合、ステップS7に戻り、次の処理対象画素を選択し、上述した処理を繰り返し実行する。そして、ステップS11において、明度調整部26は、全画素の明度調整処理が終了したと判定した場合、処理を終了する。   In step S12, the brightness adjustment unit 26 determines whether or not the brightness adjustment processing for all the pixels has been completed. If it is determined that there is a pixel that has not been adjusted, the process returns to step S7, and the next pixel to be processed is determined. Select and repeat the process described above. In step S <b> 11, if the lightness adjustment unit 26 determines that the lightness adjustment process for all pixels has been completed, the process ends.

(結果表示例)
図5〜図8は、入力画像と、明度調整が行われた画像の一例を示す図である。
(Result display example)
5 to 8 are diagrams illustrating an example of an input image and an image on which brightness adjustment has been performed.

図5は、入力画像の例を示し、図6は、従来技術を用いたRGB色空間による明度調整画像の例を示し、図7は、YCbCr色空間のY(輝度)チャンネルによる明度調整画像の例を示し、図8は、本実施の形態による明度調整画像の一例を示している。   FIG. 5 shows an example of the input image, FIG. 6 shows an example of the brightness adjustment image in the RGB color space using the conventional technique, and FIG. 7 shows the brightness adjustment image in the Y (luminance) channel of the YCbCr color space. An example is shown, and FIG. 8 shows an example of a brightness adjustment image according to the present embodiment.

図8に示す本実施の形態による明度調整画像は、図5に示す入力画像より全体的に明るく明度調整がなされており、かつ、見た目の彩度も保持されて、自然な画像となっている。また、図8に示す明度調整画像は、図6や図7に示す明度調整画像と比べて、空や植物の鮮やかさが保持されており、見た目に自然な明るさ調整が行われている。   The brightness-adjusted image according to the present embodiment shown in FIG. 8 is a natural image in which the brightness is adjusted overall brighter than the input image shown in FIG. 5, and the apparent saturation is also maintained. . In addition, the brightness adjustment image shown in FIG. 8 retains the vividness of the sky and plants as compared to the brightness adjustment images shown in FIGS. 6 and 7, and the natural brightness adjustment is performed visually.

[本発明の実施の形態における効果]
1.以上のように、本実施の形態によれば、複数の色空間での処理結果から、見た目の変化を踏まえた上で、所望の明るさを達成する調整を行うことができ、従来と比較し、見た目に自然な明るさ調整を実現することが可能となる。
2.本実施の形態では、入力画像の元画像A、RGB色空間のRGBチャンネルを輝度調整した輝度調整画像B、YCbCr色空間のY(輝度)チャンネルのみを輝度調整した輝度調整画像Cから特徴量を取得し、それらの特徴量を明度調整処理に用いるようにしたが、これに限らず、Lab色空間のL(輝度)チャンネルを輝度調整した輝度調整画像から特徴量を取得し、その特徴量も明度調整処理に用いるようにしてもよい。
[Effects of the embodiment of the present invention]
1. As described above, according to the present embodiment, it is possible to perform adjustment to achieve desired brightness based on the change in appearance from the processing results in a plurality of color spaces, compared with the conventional case. It is possible to achieve natural brightness adjustment.
2. In the present embodiment, feature amounts are obtained from the original image A of the input image, the luminance adjustment image B obtained by adjusting the luminance of the RGB channel of the RGB color space, and the luminance adjustment image C obtained by adjusting the luminance of only the Y (luminance) channel of the YCbCr color space. The feature values are acquired and used for the brightness adjustment processing. However, the present invention is not limited to this, and the feature values are acquired from the brightness adjustment image obtained by adjusting the brightness of the L (brightness) channel of the Lab color space. You may make it use for a brightness adjustment process.

以上、添付図面を参照しながら、本発明に係る明度調整装置等の好適な実施形態について説明したが、本発明はかかる例に限定されない。当業者であれば、本願で開示した技術的思想の範疇内において、各種の変更例又は修正例に想到し得ることは明らかであり、それらについても当然に本発明の技術的範囲に属するものと了解される。   The preferred embodiments of the brightness adjustment device and the like according to the present invention have been described above with reference to the accompanying drawings, but the present invention is not limited to such examples. It will be apparent to those skilled in the art that various changes or modifications can be conceived within the scope of the technical idea disclosed in the present application, and these naturally belong to the technical scope of the present invention. Understood.

1………明度調整装置
21………画像入力部
22………画像処理強度決定部
23………色空間変換部
24………輝度調整部
25………特徴量取得部
26………明度調整部
27………画像表示部
DESCRIPTION OF SYMBOLS 1 ..... Lightness adjustment device 21 .......... Image input part 22 ....... Image processing intensity determination part 23 ........ Color space conversion part 24 ........ Luminance adjustment part 25 ........ Feature amount acquisition part 26 .......... Lightness adjustment section 27 ... …… Image display section

Claims (10)

所定の色空間で表された入力画像の明度調整を行う明度調整装置であって、
前記入力画像に対する出力画像の明度の変化量を画像処理強度として決定する画像処理強度決定手段と、
前記所定の色空間で表された画像を、輝度情報を含む他の色空間の画像に変換する色空間変換手段と、
決定された前記画像処理強度に応じて、前記入力画像、及び、当該入力画像を前記色空間変換手段によって変換した前記他の色空間の画像のそれぞれに対して、輝度調整を行う輝度調整手段と、
輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれに対して、特徴量を取得する特徴量取得手段と、
取得された前記特徴量に基づいて、前記入力画像の明度調整を行う明度調整手段と、
を備えることを特徴とする明度調整装置。
A brightness adjustment device for adjusting the brightness of an input image represented in a predetermined color space,
Image processing intensity determination means for determining the amount of change in brightness of the output image with respect to the input image as image processing intensity;
Color space conversion means for converting an image represented in the predetermined color space into an image of another color space including luminance information;
In accordance with the determined image processing intensity, a luminance adjustment unit that performs luminance adjustment on each of the input image and an image in the other color space obtained by converting the input image by the color space conversion unit; ,
A feature amount acquisition means for acquiring a feature amount for each of the input image that has not been subjected to brightness adjustment, the input image that has been subjected to brightness adjustment, and an image in the other color space that has undergone brightness adjustment;
Brightness adjustment means for adjusting the brightness of the input image based on the acquired feature quantity;
A brightness adjustment device comprising:
前記特徴量取得手段は、それぞれの画像について、前記色空間変換手段によって輝度情報を取得し、全画素に対して、注目画素の近傍の明るさを示す特徴量と、注目画素の近傍の明るさに対する比率を示す特徴量とを取得する
ことを特徴とする請求項1に記載の明度調整装置。
The feature amount acquisition unit acquires luminance information for each image by the color space conversion unit, and for all pixels, a feature amount indicating brightness in the vicinity of the target pixel and brightness in the vicinity of the target pixel. The brightness adjustment apparatus according to claim 1, wherein a feature amount indicating a ratio to is acquired.
前記特徴量取得手段は、それぞれの画像について、前記色空間変換手段によって輝度情報を取得し、全画素に対して、注目画素と周辺画素とから平均の輝度値を算出して、注目画素の位置の輝度値とした特徴量A(それぞれの画像について、特徴量AA、AB、ACという。)を取得するとともに、注目画素の輝度値と、特徴量Aの注目画素の位置の輝度値との比を、注目画素の位置の画素値とした特徴量B(それぞれの画像について、特徴量BA、BB、BCという。)を取得する
ことを特徴とする請求項1に記載の明度調整装置。
The feature amount acquisition unit acquires luminance information for each image by the color space conversion unit, calculates an average luminance value from the target pixel and peripheral pixels for all pixels, and calculates the position of the target pixel. The feature value A (referred to as feature values AA, AB, and AC for each image) is acquired and the ratio between the brightness value of the target pixel and the brightness value at the position of the target pixel of the feature amount A is acquired. The feature amount B (referred to as feature amounts BA, BB, and BC for each image) is acquired as a pixel value at the position of the pixel of interest.
前記明度調整手段は、前記入力画像の全画素に対して、前記特徴量BB又は前記特徴量BCのうち、前記特徴量BAと差の小さい特徴量に係る画像の画素値を採用する第1の条件、前記特徴量AB又は前記特徴量ACのうち、前記特徴量AAとの差が大きい特徴量に係る画像の画素値を採用する第2の条件、及び、前記特徴量AB又は前記特徴量ACのうち、前記特徴量AAとの差が小さい特徴量に係る画像の画素値を採用する第3の条件を用いて、画素ごとの出力画素値を算出する
ことを特徴とする請求項3に記載の明度調整装置。
The brightness adjustment unit employs, for all the pixels of the input image, a pixel value of an image related to a feature quantity having a small difference from the feature quantity BA among the feature quantity BB or the feature quantity BC. A second condition that employs a pixel value of an image relating to a feature quantity having a large difference from the feature quantity AA among the condition, the feature quantity AB or the feature quantity AC, and the feature quantity AB or the feature quantity AC The output pixel value for each pixel is calculated using a third condition that employs a pixel value of an image related to a feature amount having a small difference from the feature amount AA. Brightness adjustment device.
前記明度調整手段は、K、α、βをK+α+β=1を満たす定数として、出力画素値を式(1)で算出する
ことを特徴とする請求項4に記載の明度調整装置。
The brightness adjustment means calculates K, α, and β as constants satisfying K + α + β = 1, and calculates an output pixel value by Expression (1).
The brightness adjustment apparatus according to claim 4, wherein
前記明度調整手段は、前記第1の判定条件において、前記特徴量の差が許容範囲より大きい場合、輝度調整していない前記入力画像の画素値を採用する
ことを特徴とする請求項4又は請求項5に記載の明度調整装置。
5. The brightness adjustment unit employs a pixel value of the input image that has not been subjected to luminance adjustment when the difference in the feature amount is larger than an allowable range in the first determination condition. Item 6. The brightness adjustment device according to item 5.
前記画像処理強度は、前記入力画像の明度に対する出力画像の明度の対応関係を表すトーンカーブである
ことを特徴とする請求項1乃至請求項6のいずれかに記載の明度調整装置。
The brightness adjustment apparatus according to any one of claims 1 to 6, wherein the image processing intensity is a tone curve representing a correspondence relationship between the brightness of the input image and the brightness of the output image.
前記明度調整手段により明度調整された前記入力画像を出力画像として出力する出力手段をさらに備える
ことを特徴とする請求項1乃至請求項7のいずれかに記載の明度調整装置。
The lightness adjusting apparatus according to any one of claims 1 to 7, further comprising output means for outputting the input image whose lightness has been adjusted by the lightness adjusting means as an output image.
所定の色空間で表された入力画像の明度調整を行う明度調整方法であって、
前記入力画像に対する出力画像の明度の変化量を画像処理強度として決定する画像処理強度決定ステップと、
前記所定の色空間で表された画像を、輝度情報を含む他の色空間の画像に変換する色空間変換ステップと、
決定された前記画像処理強度に応じて、前記入力画像、及び、当該入力画像を前記色空間変換ステップによって変換した前記他の色空間の画像のそれぞれに対して、輝度調整を行う輝度調整ステップと、
輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれに対して、特徴量を取得する特徴量取得ステップと、
取得された前記特徴量に基づいて、前記入力画像の明度調整を行う明度調整ステップと、
を含むことを特徴とする明度調整方法。
A brightness adjustment method for adjusting the brightness of an input image represented in a predetermined color space,
An image processing intensity determination step for determining an amount of change in brightness of the output image with respect to the input image as an image processing intensity;
A color space conversion step of converting the image represented in the predetermined color space into an image of another color space including luminance information;
In accordance with the determined image processing intensity, a luminance adjustment step for performing luminance adjustment on each of the input image and the image of the other color space obtained by converting the input image by the color space conversion step; ,
A feature amount acquisition step of acquiring a feature amount for each of the input image that has not been brightness adjusted, the input image that has been brightness adjusted, and the image of the other color space that has been brightness adjusted;
A brightness adjustment step for adjusting the brightness of the input image based on the acquired feature quantity;
A brightness adjustment method comprising:
コンピュータを、所定の色空間で表された入力画像の明度調整を行う明度調整装置として機能させるためのプログラムであって、
前記コンピュータを、
前記入力画像に対する出力画像の明度の変化量を画像処理強度として決定する画像処理強度決定手段、
前記所定の色空間で表された画像を、輝度情報を含む他の色空間の画像に変換する色空間変換手段、
決定された前記画像処理強度に応じて、前記入力画像、及び、当該入力画像を前記色空間変換手段によって変換した前記他の色空間の画像のそれぞれに対して、輝度調整を行う輝度調整手段、
輝度調整されていない前記入力画像、輝度調整された前記入力画像、及び、輝度調整された前記他の色空間の画像のそれぞれに対して、特徴量を取得する特徴量取得手段、
取得された前記特徴量に基づいて、前記入力画像の明度調整を行う明度調整手段、
として機能させるためのプログラム。
A program for causing a computer to function as a brightness adjustment device for adjusting the brightness of an input image represented in a predetermined color space,
The computer,
Image processing intensity determining means for determining the amount of change in brightness of the output image with respect to the input image as image processing intensity;
Color space conversion means for converting the image represented in the predetermined color space into an image of another color space including luminance information;
In accordance with the determined image processing intensity, a luminance adjustment unit that performs luminance adjustment on each of the input image and the image of the other color space obtained by converting the input image by the color space conversion unit,
Feature amount acquisition means for acquiring a feature amount for each of the input image that has not been subjected to luminance adjustment, the input image that has been subjected to luminance adjustment, and an image in the other color space that has undergone luminance adjustment;
Brightness adjustment means for adjusting the brightness of the input image based on the acquired feature quantity;
Program to function as.
JP2013166535A 2013-08-09 2013-08-09 Luminosity adjusting device, luminosity adjusting method, and program Pending JP2015035755A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013166535A JP2015035755A (en) 2013-08-09 2013-08-09 Luminosity adjusting device, luminosity adjusting method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013166535A JP2015035755A (en) 2013-08-09 2013-08-09 Luminosity adjusting device, luminosity adjusting method, and program

Publications (1)

Publication Number Publication Date
JP2015035755A true JP2015035755A (en) 2015-02-19

Family

ID=52543975

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013166535A Pending JP2015035755A (en) 2013-08-09 2013-08-09 Luminosity adjusting device, luminosity adjusting method, and program

Country Status (1)

Country Link
JP (1) JP2015035755A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106855997A (en) * 2016-11-30 2017-06-16 努比亚技术有限公司 The processing method and processing device of picture

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106855997A (en) * 2016-11-30 2017-06-16 努比亚技术有限公司 The processing method and processing device of picture

Similar Documents

Publication Publication Date Title
JP5963933B2 (en) Signal conversion apparatus and method, program, and recording medium
JP4117284B2 (en) Color space conversion method, color image color adjustment device, color adjustment method, and computer-readable recording medium recording the program
US9236033B2 (en) Color processing apparatus and color processing method
CN106462334B (en) Controlling multiple photo adjustments using a single control
JP5897159B2 (en) Display device and control method thereof
WO2012008342A1 (en) Display device, method for controlling display device, program, and recording medium
WO2017080015A1 (en) Method and device for controlling low grayscale white balance
AU2013381285B2 (en) Color adjustment device, image display device, and color adjustment method
AU2014268148B2 (en) Image processing apparatus, and program
JP6520578B2 (en) Image processing apparatus and display determination method
JP2008522530A (en) Electronic color image saturation processing method
JP2007142983A (en) Image processor
JP5387713B2 (en) Image adjustment apparatus, image adjustment system, and program
EP2227032A1 (en) Brightness information display and method
JP6617432B2 (en) Image processing apparatus and program
US20160133229A1 (en) Signal processing device and signal processing method
US8462171B2 (en) Saturation contrast image enhancement
US10181205B2 (en) Image processing method and image processing apparatus
US20150085162A1 (en) Perceptual radiometric compensation system adaptable to a projector-camera system
JP6015359B2 (en) Color video signal processing apparatus, processing method, and processing program
JP5664261B2 (en) Image processing apparatus and image processing program
JP2015035755A (en) Luminosity adjusting device, luminosity adjusting method, and program
JP6101939B2 (en) Signal processing apparatus and signal processing method
WO2022120799A1 (en) Image processing method and apparatus, electronic device, and storage medium
JP2019118029A5 (en)