JP2010193154A - Image processor and method - Google Patents
Image processor and method Download PDFInfo
- Publication number
- JP2010193154A JP2010193154A JP2009035209A JP2009035209A JP2010193154A JP 2010193154 A JP2010193154 A JP 2010193154A JP 2009035209 A JP2009035209 A JP 2009035209A JP 2009035209 A JP2009035209 A JP 2009035209A JP 2010193154 A JP2010193154 A JP 2010193154A
- Authority
- JP
- Japan
- Prior art keywords
- image
- unit
- magnification
- coefficient
- pixel
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims description 31
- 238000012545 processing Methods 0.000 claims abstract description 120
- 238000004364 calculation method Methods 0.000 claims abstract description 59
- 230000009467 reduction Effects 0.000 claims abstract description 47
- 230000008859 change Effects 0.000 claims description 23
- 238000000605 extraction Methods 0.000 claims description 20
- 238000001514 detection method Methods 0.000 claims description 19
- 230000008569 process Effects 0.000 claims description 13
- 238000003672 processing method Methods 0.000 claims description 6
- 239000000284 extract Substances 0.000 claims description 3
- 238000010586 diagram Methods 0.000 description 23
- 244000025254 Cannabis sativa Species 0.000 description 4
- 238000011946 reduction process Methods 0.000 description 4
- 238000007429 general method Methods 0.000 description 2
- 238000012886 linear function Methods 0.000 description 2
- 230000003044 adaptive effect Effects 0.000 description 1
- 238000013459 approach Methods 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 238000012790 confirmation Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000003384 imaging method Methods 0.000 description 1
- 239000011159 matrix material Substances 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 230000004044 response Effects 0.000 description 1
Images
Landscapes
- Image Processing (AREA)
- Editing Of Facsimile Originals (AREA)
Abstract
Description
この発明は、パソコン、携帯端末、カーナビゲーションシステム等の画像の表示や編集を行う装置において、画像の部分的な拡大又は縮小を行う画像処理装置および画像処理方法に関するものである。 The present invention relates to an image processing apparatus and an image processing method for partially enlarging or reducing an image in an apparatus for displaying and editing an image such as a personal computer, a portable terminal, and a car navigation system.
ディジタルカメラ等により撮影した画像はディジタルデータとしてメモリやハードディスクに保存される。撮影した画像の確認は一般に、その画像を、撮影機器に付属するモニタや、パソコンに接続されたモニタに表示することで行われる。画像の画素数や縦横比は、撮影機器の仕様や画像データの編集内容によって異なり、モニタ表示画面の画素数とは一致しない場合が多い。そこで、画像全体を一様に拡大又は縮小し、画素数および縦横比をできる限りモニタ表示画面に合わせる処理が行われている。 Images taken by a digital camera or the like are stored as digital data in a memory or hard disk. Confirmation of a photographed image is generally performed by displaying the image on a monitor attached to a photographing device or a monitor connected to a personal computer. The number of pixels and the aspect ratio of the image vary depending on the specifications of the photographing device and the editing content of the image data, and often do not match the number of pixels on the monitor display screen. Therefore, a process is performed in which the entire image is uniformly enlarged or reduced so that the number of pixels and the aspect ratio match the monitor display screen as much as possible.
例えば、携帯端末で撮影されるような画像サイズの小さい画像をパソコンに接続したモニタで表示する場合、表示する画像よりもモニタ表示画面の画素数が多く、モニタ表示画面に余裕があるため、画像全体を一様の倍率で拡大して表示することで画像の視認性を高めることができる。しかし拡大倍率が大きすぎるとモニタ表示画面に表示されない部分が大きくなり、画像全体の確認が困難になってしまう。 For example, when displaying an image with a small image size, such as a picture taken with a mobile terminal, on a monitor connected to a personal computer, the monitor display screen has more pixels than the image to be displayed, and there is room in the monitor display screen. The visibility of the image can be enhanced by displaying the entire image at a uniform magnification. However, if the enlargement magnification is too large, a portion that is not displayed on the monitor display screen becomes large, and it becomes difficult to confirm the entire image.
この問題の解決策として、入力装置により拡大領域を選択し、拡大領域と非拡大領域との境界での連続性を維持しつつ拡大領域のみを部分的に拡大して画像を表示する技術がある(例えば、特許文献1参照)。ユーザーにとって重要な部分だけを選択的に拡大することにより、モニタに表示されない部分をできるだけ小さく抑えながら、ユーザーにとって重要な部分の視認性を高めることができる。 As a solution to this problem, there is a technique in which an enlarged region is selected by an input device, and an image is displayed by partially enlarging only the enlarged region while maintaining continuity at the boundary between the enlarged region and the non-enlarged region. (For example, refer to Patent Document 1). By selectively enlarging only the part important for the user, it is possible to improve the visibility of the part important for the user while keeping the part not displayed on the monitor as small as possible.
また、近年のディジタルカメラの場合、撮影できる静止画の画素数はメガピクセル(100万画素)を超えるものがほとんどであるのに対し、携帯端末やカーナビゲーションシステムの表示画面の画素数は数10万画素程度にとどまるものが多い。つまり、表示したい画像の画素数が表示画面の画素数よりも多いため、画像全体を表示するには画像を縮小する必要がある。この場合、画像を一様の倍率で縮小することで画像全体を表示できるようになる。 In recent digital cameras, the number of pixels of still images that can be photographed exceeds megapixels (1 million pixels), whereas the number of pixels on the display screen of a portable terminal or a car navigation system is several tens. Many are limited to about 10,000 pixels. That is, since the number of pixels of the image to be displayed is larger than the number of pixels of the display screen, it is necessary to reduce the image in order to display the entire image. In this case, the entire image can be displayed by reducing the image at a uniform magnification.
ところで、特許文献1に記載された技術では、ユーザーが入力装置を使用して拡大したい部分を指定する必要がある。そのため、マウスやカーソルのような直感的な領域指定ができる入力装置を使用できる機器であれば容易に拡大したい重要部分を指定することができるが、携帯端末やカーナビゲーションシステム等では、一般に直感的な領域指定ができる入力装置や仕組みが設けられておらず、拡大したい部分を容易に指定できないという問題があった。
By the way, in the technique described in
また、表示したい画像の画素数が表示画面の画素数よりも多く画像を縮小する必要がある場合には、画像を一様の倍率で縮小することで画像全体を表示できるようになるが、これでは画像の視認性が悪化してしまう。そこで画像全体としては表示画面に合うように縮小しながらも重要部分については視認性を優先的に確保したいという要望があった。 In addition, if the number of pixels of the image to be displayed is larger than the number of pixels on the display screen, the entire image can be displayed by reducing the image at a uniform magnification. Then, the visibility of an image will deteriorate. Therefore, there has been a demand for preferentially ensuring the visibility of important portions while reducing the entire image to fit the display screen.
この発明は、上述のような問題を解決するためになされたもので、入力装置によって重要部分を指定しなくても、画像内の重要部分を自動で検出し、当該重要部分の視認性を優先的に確保しつつ画像を拡大又は縮小できる画像処理装置を提供することを目的とする。 The present invention has been made to solve the above-described problems. Even if an important part is not designated by an input device, the important part in the image is automatically detected and priority is given to the visibility of the important part. An object of the present invention is to provide an image processing apparatus capable of enlarging or reducing an image while ensuring it.
この発明に係る画像処理装置では、ユーザーが視認性を確保したい重要部分はエッジ強度値が大きな部分である点に着目し、画像の各画素のエッジ強度値に基づき画像を複数の部分に分け、これらの部分毎に拡大又は縮小する倍率を示す倍率係数を算出し、その倍率係数に従って部分毎に拡大又は縮小するようにした。 In the image processing apparatus according to the present invention, paying attention to the fact that the important part that the user wants to ensure visibility is a part having a large edge intensity value, the image is divided into a plurality of parts based on the edge intensity value of each pixel of the image, A magnification coefficient indicating a magnification for enlarging or reducing each of these parts was calculated, and each part was enlarged or reduced according to the magnification coefficient.
この発明に係る画像処理装置においては、重要部分を指定しなくても、重要部分の視認性を優先的に確保した画像を得ることができるという効果を奏する。 In the image processing apparatus according to the present invention, there is an effect that it is possible to obtain an image in which the visibility of the important part is preferentially secured without specifying the important part.
実施の形態1.
図1はこの発明の実施の形態1における画像処理装置の構成を示す構成図である。実施の形態1における画像処理装置は画像入力部100、係数算出部200、拡大/縮小処理部300、及び画像出力部400から構成されている。
FIG. 1 is a block diagram showing the configuration of the image processing apparatus according to
画像入力部100には、静止画を構成する画像データまたは動画を構成する映像データが入力される。例を挙げると、カメラによる撮像データ、メモリに記憶されている画像データまたは映像データ及びハードディスクで保持しているファイル形式の画像データまたは映像データ等が入力される。これらの画像データまたは映像データは、RGB(赤緑青)やYCbCr(輝度色差)といった信号データや、ビットマップ形式やJPEG形式といった画像ファイルフォーマット、また機器固有のデータフォーマット等の様々な形式で入力される。画像入力部100は、入力された画像データが例えばYCbCr形式であれば、この輝度データから輝度信号データを抜き取り、それを係数算出部200へ出力する。また、画像入力部100は、YCbCr形式である入力された画像データそのものを拡大/縮小処理部300へ出力する。なお、時間的に連続する映像データが入力される場合は、いったんフレーム単位の画像データに変換することで、画像データと同様な処理を行うことができる。
Image data constituting a still image or video data constituting a moving image is input to the
以下では、カメラでの撮像画像データをYCbCr形式で入力し、RGBデータを出力してパソコンに付属するモニタの画面に画像データを表示するシステムを例にして説明するが、この発明は特にこれに限定されるものではない。 In the following description, a system for inputting image data captured by a camera in the YCbCr format, outputting RGB data, and displaying the image data on a monitor screen attached to a personal computer will be described as an example. It is not limited.
係数算出部200は、エッジ抽出部201、特徴量算出部202、及び倍率係数判定部203からなる。エッジ抽出部201は、画像入力部100の出力である輝度信号データから、画像入力部100に入力された画像データの各画素のエッジ強度値を算出してそれを出力する。特徴量算出部202は、エッジ抽出部201が出力するエッジ強度値に対して、水平方向について画素行毎に、垂直方向について画素列毎に、エッジ強度値の総和や平均値といった特徴量を算出して出力する。倍率係数判定部203は、特徴量算出部202の出力からなる画像において、各画素について水平および垂直方向に拡大又は縮小するための倍率を表す倍率係数を決定する。
The
拡大/縮小処理部300は、画像入力部100からの画像データに対し、係数算出部200の出力である、各画素についての水平垂直方向の倍率係数に従って、画像の拡大又は縮小を行う。
The enlargement /
画像出力部400は、拡大/縮小処理部300から出力される画像データを、モニタ等に表示するために並び替えて同期信号と合わせて出力、あるいはファイル形式に変換して保存、あるいはメモリに所定のフォーマットにしたがって書き込むといった処理を必要に応じて行う。
The
図2は、図1の画像処理装置の各段階における画像の例であって、(a)は画像入力部100に入力される原画像である。一例としてここでは、原画像(a)は山と雲を背景にして人物に焦点をあわせて撮影した、水平方向の画素の数がW,垂直方向の画素の数がHの自然画である。(b)は、原画像(a)の輝度信号データから、エッジ抽出部201でエッジ強度値を算出して得られた結果画像である。ここでは、エッジ強度値の値が大きい箇所を実線で、エッジ強度値の小さい箇所を点線で示している。(c)は、画像出力部400からの出力画像である。なお、図2(a)において、座標は水平方向と垂直方向の各画素の位置を(水平方向x,垂直方向y)で表しており、画像の左上端の画素の位置が(0,0)、右下端の画素の位置が(W-1,H-1)となる。特にことわりがない場合は他の図でも同様である。
FIG. 2 is an example of an image at each stage of the image processing apparatus of FIG. 1, and (a) is an original image input to the
原画像(a)において、本実施の形態に係る画像処理装置のユーザーが視認性を確保したい重要部分は人物の部分である。この画像における人物の部分は、人物に焦点をあわせて撮影されているので、(b)に示すように、背景である山や雲の部分より相対的にエッジ強度値が大きい。このように、ユーザーが視認性を確保したい重要部分は一般にエッジ強度値が大きな部分であることが多い。本実施の形態では、相対的にエッジ強度値が大きいこの人物の部分を重要部分として検出し、この部分の視認性を優先的に確保した画像を得ることが目的である。 In the original image (a), an important part that the user of the image processing apparatus according to the present embodiment wants to ensure visibility is a person part. Since the person portion in this image is photographed while focusing on the person, the edge intensity value is relatively larger than the background mountain and cloud portions as shown in FIG. As described above, in many cases, an important portion where the user wants to ensure visibility is generally a portion having a large edge strength value. The object of the present embodiment is to detect this human part having a relatively large edge strength value as an important part and obtain an image in which the visibility of this part is secured with priority.
次に、この発明の実施の形態1における、各段階での動作について説明する。 Next, the operation at each stage in the first embodiment of the present invention will be described.
画像入力部100には、図2(a)のような画像データがYCbCr形式で入力されるものとする。これを受け、画像入力部100は、画像データから輝度信号データYのみを抜き取り、係数算出部200へと出力する。また、画像入力部100は、逆マトリクス変換によりRGBデータに変換した図2(a)に相当する画像データを拡大/縮小処理部300へと出力する。本実施の形態において画像入力部100は、係数算出部200に対しては1画素あたり8ビットの輝度信号データを、拡大/縮小処理部300に対しては1画素あたりRGB各8ビットで合計24ビットのデータを、画像を水平垂直に走査して順に出力する。
Assume that image data as shown in FIG. 2A is input to the
画像入力部100からの輝度信号データYは、エッジ抽出部201へと入力される。エッジ強度値の抽出処理には、Sobelフィルタのような一般的なフィルタを用いるものとし、フィルタの出力の絶対値を取った値をエッジ強度値として使用する。隣接する画素間の輝度の勾配差が大きいほどエッジ強度値は大きくなる。エッジ強度値は水平垂直の各方向について算出できるが、1画素あたりのエッジ強度値を1つに限定するため、水平垂直の各方向での算出値のうち、値の大きい方を選択するものとする。エッジ抽出の結果、図2(a)の画像は、図2(b)のようになる。
The luminance signal data Y from the
特徴量算出部202は、画像の水平垂直の各方向について、画素行毎および画素列毎にエッジ抽出部201で求められたエッジ強度値の和を求める。まず画像の垂直方向について、水平方向位置がx=0からx=(W−1)までの間にW列ある各画素列について、垂直方向位置y=0からy=(H−1)の画素のエッジ強度値の和である垂直方向総和Sx(x)(xは0から(W−1)までの整数)を求める。また、水平方向についても同様に、垂直方向位置がy=0からy=(H−1)までの間にH行ある各画素行について、水平方向位置x=0からx=(W−1)の画素のエッジ強度値の和である水平方向総和Sy(y)(yは0から(H−1)までの整数)を求める。
The feature
倍率係数判定部203では、特徴量算出部202で求められた垂直方向総和Sx(x)のx=0からx=(W−1)までの各値を所定の倍率係数判定閾値THxと比較する。倍率係数判定閾値THxと同じか倍率係数判定閾値THxより大きい場合にはその画素列に含まれる各画素の水平方向の倍率係数を例えばm(mは、1より大きい数)とする。また、倍率係数判定閾値THxより小さい場合にはその画素列に含まれる各画素の水平方向の倍率係数を例えば1とする。
The magnification
同様にして、水平方向総和Sy(y)のy=0からy=(H−1)までの各値についても、所定の倍率係数判定閾値THyと比較する。倍率係数判定閾値THyと同じか倍率係数判定閾値THyより大きい場合には、その画素行に含まれる画素の垂直方向の倍率係数を例えばn(nは、1より大きい数)とする。また、倍率係数判定閾値THyより小さい場合にはその画素行に含まれる各画素の垂直方向の倍率係数を例えば1とする。 Similarly, each value from y = 0 to y = (H−1) of the horizontal total sum Sy (y) is also compared with a predetermined magnification coefficient determination threshold value THy. If the magnification coefficient determination threshold THy is equal to or greater than the magnification coefficient determination threshold THy, the vertical magnification coefficient of the pixels included in the pixel row is set to, for example, n (n is a number greater than 1). If the magnification coefficient determination threshold value THy is smaller, the vertical magnification coefficient of each pixel included in the pixel row is set to 1, for example.
倍率係数は、画素の水平方向あるいは垂直方向の画素数を何倍に拡大又は縮小するかを決めるものであり、倍率係数が1であれば等倍を表す。拡大又は縮小は拡大/縮小処理部300で行われ、例えば、水平方向の倍率係数が1.5の画素が水平方向に10個並んでいる場合は、画素が水平方向に15個並ぶように拡大される。
The magnification coefficient determines how many times the number of pixels in the horizontal direction or the vertical direction of the pixel is enlarged or reduced. If the magnification coefficient is 1, it represents the same magnification. Enlargement or reduction is performed by the enlargement /
以下、図3を用いて、倍率係数判定部203における倍率係数の判定方法を説明する。図3は、倍率係数判定部203で用いる倍率係数の算出課程の説明図であり、図2(b)の画像に対する水平垂直の各方向について、エッジ強度値の総和および倍率係数の算出例を示している。
Hereinafter, a method for determining a magnification factor in the magnification
図3(a)は水平方向位置xが0から(W−1)である画素のそれぞれについて垂直方向総和Sx(x)を求めたグラフであり、縦軸に垂直方向総和Sx(x)、横軸に水平方向位置をとった。グラフの横軸である水平方向位置xは、画像の水平方向位置におよそ合わせて表示している。図3の画像では、人物の部分のエッジ強度値が大きいことから、人物が撮影されている画素の位置で垂直方向総和Sx(x)は大きな値となっている。これに対し図3(c)は、水平方向位置xが0から(W−1)の間の各画素列に含まれる画素に対する水平方向の倍率係数のグラフである。図3(c)の横軸は水平方向位置、縦軸は各水平方向位置にある画素の水平方向の倍率係数である。また、図3(b)は、図3(a)と同様に、横軸に垂直方向位置、縦軸に水平方向総和Sy(y)をとったグラフを左方向に90度回転させたものである。図3(d)は、図3(c)と同様に、横軸に垂直方向位置、縦軸に各垂直方向位置にある画素の垂直方向の倍率係数をとったグラフを左方向に90度回転させたものである。 FIG. 3A is a graph in which the vertical direction total sum Sx (x) is obtained for each of the pixels whose horizontal direction position x is 0 to (W−1), and the vertical axis indicates the vertical direction total sum Sx (x) and the horizontal direction. A horizontal position was taken on the axis. The horizontal position x, which is the horizontal axis of the graph, is displayed approximately in accordance with the horizontal position of the image. In the image of FIG. 3, since the edge intensity value of the person portion is large, the vertical direction sum Sx (x) is a large value at the pixel position where the person is photographed. On the other hand, FIG. 3C is a graph of the magnification factor in the horizontal direction for the pixels included in each pixel column where the horizontal position x is between 0 and (W−1). In FIG. 3C, the horizontal axis represents the horizontal position, and the vertical axis represents the horizontal magnification coefficient of the pixel at each horizontal position. Further, FIG. 3B is a graph obtained by rotating the graph in which the horizontal axis represents the vertical position and the vertical axis represents the horizontal sum Sy (y) 90 degrees to the left as in FIG. 3A. is there. 3D, as in FIG. 3C, the graph in which the horizontal axis represents the vertical position and the vertical axis represents the vertical magnification coefficient of the pixel at each vertical position is rotated 90 degrees to the left. It has been made.
この垂直方向総和Sx(x)に対して倍率係数判定閾値THxとして図3(a)に示したように所定の値を設定する。垂直方向総和Sx(x)のグラフが、倍率係数判定閾値THxと交差する水平方向に対応する画素および倍率係数判定閾値THxより上になる水平方向位置の画素で水平方向の倍率係数をmとし、倍率係数判定閾値THxより下になる水平方向位置の画素では水平方向の倍率係数を1とする。このようにして求めた水平方向の倍率係数は図3(c)のようになる。 As shown in FIG. 3A, a predetermined value is set as the magnification coefficient determination threshold value THx for the vertical direction sum Sx (x). In the graph of the sum total Sx (x) in the vertical direction, the horizontal magnification coefficient m is a pixel corresponding to the horizontal direction intersecting the magnification coefficient determination threshold THx and a pixel at a horizontal position above the magnification coefficient determination threshold THx. The horizontal magnification coefficient is set to 1 for the pixel in the horizontal position that is below the magnification coefficient determination threshold THx. The horizontal magnification coefficient thus obtained is as shown in FIG.
画像の垂直方向に対しても水平方向と同様な処理を行うことにより、図3(b)のような水平方向総和Sy(y)のグラフが求まる。水平方向総和Sy(y)のグラフが、倍率係数判定閾値THyと交差する画素行および倍率係数判定閾値THyより上になる垂直方向位置に含まれる画素で垂直方向の倍率係数をnとし、倍率係数判定閾値THyより下になる垂直方向位置に含まれる画素では垂直方向の倍率係数を1とする。したがって、図3(d)のように垂直方向位置yが0から(H−1)の間の画素に対する垂直方向の倍率係数のグラフが求まる。 By performing processing similar to that in the horizontal direction for the vertical direction of the image, a graph of the total sum Sy (y) in the horizontal direction as shown in FIG. 3B is obtained. The graph of the horizontal sum Sy (y) is a pixel row intersecting the magnification factor determination threshold THy and pixels included in a vertical position that is above the magnification factor determination threshold THy. For a pixel included in a vertical position below the determination threshold THy, the vertical magnification factor is set to 1. Accordingly, as shown in FIG. 3D, a graph of the magnification factor in the vertical direction is obtained for the pixels whose vertical position y is between 0 and (H−1).
次に図4を用いて、本実施の形態における倍率係数判定閾値の算出例を説明する。図4は、図3(a)のグラフをさらに詳細に説明するためのグラフであり、特徴量算出部202での倍率係数判定閾値THxの算出例の説明図である。
Next, a calculation example of the magnification coefficient determination threshold in the present embodiment will be described with reference to FIG. FIG. 4 is a graph for explaining the graph of FIG. 3A in more detail, and is an explanatory diagram of an example of calculation of the magnification coefficient determination threshold THx in the feature
まずは垂直方向総和Sx(x)について、水平方向位置xが0から(W−1)の間での最小値MINxおよび平均値AVExを求める。次に平均値AVExから最小値MINxを差し引いた値の2分の1をOFFSETxとし、平均値AVExからOFFSETxを差し引いた値を、倍率係数判定閾値THxとして設定する。エッジ強度値は絶対値を使用していることからいずれの値も0以上の値となり、倍率係数判定閾値THxは必ず平均値AVExと最小値MINxとの間の値に設定される。 First, for the vertical direction sum Sx (x), the minimum value MINx and the average value AVEx when the horizontal position x is between 0 and (W−1) are obtained. Next, half of the value obtained by subtracting the minimum value MINx from the average value AVEx is set as OFFSETx, and the value obtained by subtracting OFFSETx from the average value AVEx is set as the magnification coefficient determination threshold THx. Since the edge strength value uses an absolute value, all values are 0 or more, and the magnification coefficient determination threshold THx is always set to a value between the average value AVEx and the minimum value MINx.
倍率係数判定閾値THyについても、水平方向総和Sy(y)に対して倍率係数判定閾値THxと同様にして設定する。すなわち、水平方向位置yが0から(H−1)の間での最小値MINyおよび平均値AVEyを求める。次に平均値AVEyから最小値MINyを差し引いた値の2分の1をOFFSETyとし、平均値AVEyからOFFSETyを差し引いた値を、倍率係数判定閾値THyとして設定する。 The magnification coefficient determination threshold THy is also set for the horizontal sum Sy (y) in the same manner as the magnification coefficient determination threshold THx. That is, the minimum value MINy and the average value AVEy when the horizontal position y is between 0 and (H−1) are obtained. Next, half of the value obtained by subtracting the minimum value MINy from the average value AVEy is set as OFFSETy, and the value obtained by subtracting OFFSETy from the average value AVEy is set as the magnification coefficient determination threshold THy.
本実施の形態では、倍率係数判定閾値THxおよびTHyについて、それぞれ独立に算出する構成としているが、同じ値を設定してもよい。また、画像データから算出する構成としているが、異なる算出式を採用する、あるいは複数の算出式での結果を受け、予め用意しておいた値の中から選択するような構成としてもよい。さらに、画像によらず固定値に設定したり、あるいは画像処理装置の外部から直接指定できるような構成としてもよい。 In the present embodiment, the magnification coefficient determination thresholds THx and THy are calculated independently, but the same value may be set. In addition, although the calculation is performed from the image data, a different calculation formula may be employed, or a result obtained by a plurality of calculation formulas may be selected and selected from values prepared in advance. Furthermore, it may be configured such that it can be set to a fixed value regardless of the image, or can be directly designated from the outside of the image processing apparatus.
図5は、倍率係数判定部203で判定した水平垂直の各方向の倍率係数を画素の位置毎に表した倍率係数分布図である。この図において、括弧内の左側の値が水平方向の倍率係数、右側が垂直方向の倍率係数を示している。例えば、(m,1)と示された領域では、その領域に含まれる画素の水平方向の倍率係数がmで、垂直方向の倍率係数が1であることを表している。図5(c)及び(d)は、図3(c)及び(d)と同じグラフである。この例では、図5に示すように、画像は倍率係数に対応して9つの領域に分かれ、中央の領域では水平方向はm倍、垂直方向はn倍に拡大となり、左側上段、左側下段、右側上段、右側下段の4つの領域は水平方向及び垂直方向ともに等倍のままで、中央上段、中央下段の領域では水平方向にm倍に拡大、垂直方向は等倍のまま、左側中段と右側中段の領域では水平方向は等倍のまま、垂直方向はn倍に拡大となる。
FIG. 5 is a magnification coefficient distribution diagram showing the horizontal and vertical magnification coefficients determined by the magnification
このようにして係数算出部200では、画像の各列に1つの水平方向倍率係数および各行に1つの垂直方向倍率係数が算出され、拡大/縮小処理部300へ出力される
In this way, the
なお、上述の例では、水平方向の倍率係数をm、垂直方向の倍率係数をn(m、nはともに1より大きい数)と各方向で異なる値としたが、同じ値としてもよい。 In the above example, the horizontal magnification coefficient is m and the vertical magnification coefficient is n (m and n are both greater than 1) and different values in each direction. However, the same value may be used.
また、倍率係数は1と1より大きい数(水平方向ではm、垂直方向ではn)の2種類から選択するものとしているが、倍率係数判定閾値を複数用いることで、倍率係数を3種類以上用いるような構成としてもよい。 The magnification factor is selected from two types of 1 and a number greater than 1 (m in the horizontal direction and n in the vertical direction). By using a plurality of magnification factor determination thresholds, three or more types of magnification factors are used. It is good also as such a structure.
また、倍率係数は1と1より大きい数としているが、エッジ強度値の総和が倍率係数判定閾値より大きい画素の倍率係数が、小さい画素の倍率係数より相対的に大きな値になれば、1より小さい数にしてもよい。この場合は、次に説明する拡大/縮小処理部300で縮小処理を行うことになる。
The magnification coefficient is set to 1 and a number larger than 1. However, if the magnification coefficient of a pixel whose sum of edge intensity values is larger than the magnification coefficient determination threshold is a value relatively larger than the magnification coefficient of a small pixel, the number is 1. It may be a small number. In this case, the enlargement /
以上のことは、実施の形態2以降でも同様である。 The same applies to the second and subsequent embodiments.
次に、図1において、拡大/縮小処理部300では、係数算出部200で算出された水平垂直各方向の倍率係数に基づき、画像入力部100から入力される画像に対する拡大処理や縮小処理を行う。補間方法としては、バイリニア法やバイキュービック法などの一般的な方法を用いるものとする。倍率係数が1の部分では、1画素が入力されると1画素が出力される。倍率係数が1でない部分は、1画素入力されると倍率係数と同じ数の画素が出力される。出力される画素の値は、補間方法に依存する。
Next, in FIG. 1, an enlargement /
図2(c)は、図5に示した倍率係数に従って拡大され、画像出力部400から出力された出力画像である。この出力画像では、画像内の人物の部分は水平方向と垂直方向に拡大され、入力された画像よりも出力される画像の画素数は多くなっている。また、画像右側上部の雲は水平方向、垂直方向ともに等倍である。一方、背景の山は垂直方向又は水平方向の倍率係数が異なる複数の領域を跨っていることにより歪みが生じている。倍率係数は入力画像の内容に依存して決まるため、縦横比は保存されていない。
FIG. 2C illustrates an output image that is enlarged according to the magnification coefficient illustrated in FIG. 5 and output from the
画像出力部400は、拡大/縮小処理部300で拡大処理を実行された画像をパソコン付属のモニタの画面に表示できるよう、画像データを出力する。
The
なお、画像入力部100に入力されるデータが、時間的に連続する複数の画像データや映像データの場合、複数のフレーム間で同じ部分を拡大できるようにするために、複数のフレームを代表させてひとつのフレームの輝度データを係数算出部200へ送ってこのフレームについての倍率係数を算出し、拡大/縮小処理部300で残りのフレームについても同じ倍率係数で拡大するようにしてもよい。
In addition, when the data input to the
以上本実施の形態に係る画像処理装置では、画像の各画素のエッジ強度値に基づき画像を複数の部分に分け、エッジ強度値が大きい部分の倍率係数がエッジ強度値が小さい部分の倍率係数以上になるように前記部分毎に倍率係数を算出し、その倍率係数に従って前記部分毎に拡大又は縮小するようにしたので、重要部分を指定しなくても、重要部分の視認性を優先的に確保した画像を得ることができる。 As described above, in the image processing apparatus according to the present embodiment, the image is divided into a plurality of parts based on the edge intensity value of each pixel of the image, and the magnification coefficient of the part with the large edge intensity value is greater than the magnification coefficient of the part with the small edge intensity value. The magnification factor is calculated for each part so that it becomes, and each part is enlarged or reduced according to the magnification coefficient, so that the visibility of the important part is secured with priority without specifying the important part. Images can be obtained.
実施の形態2.
図6はこの発明の実施の形態2での画像処理装置の構成を示す構成図であって、図1に示した画像処理装置と同一の部分については同一の符号を付しており、係数算出部220のエッジ抽出部201と特徴量算出部202の間に、閾値処理部204を追加している点が異なる。
FIG. 6 is a block diagram showing the configuration of the image processing apparatus according to
以下、例として画像を拡大する場合について説明するが、縮小する場合においても本実施の形態を適用することができる。 Hereinafter, the case of enlarging an image will be described as an example, but the present embodiment can be applied even when the image is reduced.
図7は、図6の各段階での画像の例であって、(a)は画像入力部100に入力される原画像、(b)はエッジ抽出部201で得られた結果画像、(c)は閾値処理部204で得られた結果画像である。入力される原画像(a)の背景には木や草があり、実施の形態1の図2(a)の背景よりも複雑になっている。そのため、木や草の各画素でのエッジ強度値は小さいものの、垂直方向総和Sx(x)および水平方向総和Sy(y)が倍率係数判定閾値THxおよびTHyを超え、木や草の部分も拡大されてしまうことになる。
FIG. 7 is an example of an image at each stage of FIG. 6, (a) is an original image input to the
そこで本実施の形態では、閾値処理部204において、エッジ抽出部201から出力される各画素のエッジ強度値と所定の閾値とを比較していき、エッジ強度値の方が小さい画素のエッジ強度値を、エッジ強度値の総和を取る前に零に置き換える。
Therefore, in the present embodiment, the
図8は、図1の構成の実施の形態1で図7(a)の画像を処理した場合の係数算出部200での倍率係数算出課程の説明図である。図8において画像は図7(b)と同じエッジ抽出部201で得られた結果画像である。グラフの説明は図3と同様で、図8(a)は各水平方向位置にある画素列の垂直方向総和Sx(x)、図8(b)は各垂直方向位置にある画素行の水平方向総和Sy(y)、図8(c)は各水平方向位置にある画素の水平方向の倍率係数、図8(d)は各垂直方向位置にある画素の垂直方向の倍率係数を表している。
FIG. 8 is an explanatory diagram of a magnification coefficient calculation process in the
図9は、閾値処理部204を追加した本実施の形態の図6の構成で図7(a)の画像を処理した場合の係数算出部220での倍率係数算出課程の説明図であって、図9において画像は図7(c)と同じ閾値処理部204で得られた結果画像である。グラフの説明は図3および9と同様で、図9(a)は各水平方向位置にある画素列の垂直方向総和Sx(x)、図9(b)は各垂直方向位置にある画素行の水平方向総和Sy(y)、図9(c)は各水平方向位置にある画素の水平方向の倍率係数、図9(d)は各垂直方向にある画素の垂直方向の倍率係数を表している。
FIG. 9 is an explanatory diagram of a magnification coefficient calculation process in the
まず、原画像を図7(a)とした場合の、実施の形態1で倍率係数を算出する場合について述べる。図7(a)では画像の焦点は人物に合っており背景部分のエッジ強度値は概ね小さい値を取るため、エッジ抽出部201でエッジ抽出処理を行うと、図7(b)のような結果が得られる。
First, the case where the magnification coefficient is calculated in the first embodiment when the original image is shown in FIG. 7A will be described. In FIG. 7A, the image is focused on the person and the edge intensity value of the background portion is almost small. Therefore, when the edge extraction processing is performed by the
次に特徴量算出部202で画素行および画素列方向に対するエッジ強度値の総和を算出すると、背景部分の各画素でのエッジ強度値は小さいものの個々の画素でのエッジ強度値が加算され、その総和が図8(a)および(b)に示したように大きくなる。すると、人物と関係ない位置においても、垂直方向総和Sx(x)および水平方向総和Sy(y)が倍率係数判定閾値THxおよびTHyを超える。したがって図8(c)および(d)のように倍率係数がm、nと判定される画素が増えるため、人物の部分以外の拡大が必要ではない部分も拡大することになる。
Next, when the feature
次に本実施の形態で図7(a)の画像が入力された場合の閾値処理部204の動作について説明する。閾値処理部204では、順次入力される各画素のエッジ強度値と所定の閾値とを比較し、該当する画素のエッジ強度値が閾値と同じか閾値より大きい場合はその画素のエッジ強度値を保持し、閾値より小さい場合は値を零に置き換える処理を行う。一例として、閾値は、画像全体の平均値の4倍の値を使用する。図7(b)の画像では、背景の木や草の部分のエッジが弱く値が小さいため、該当する画素のエッジ強度値が零に置き換えられ、図7(c)のように人物の周辺にのみエッジ強度値が残る。
Next, the operation of the
したがって特徴量算出部202で算出されるエッジ強度値の総和Sx(x)およびSy(y)は図9(a)および(b)のように背景部分に相当する画素行および画素列での値が小さくなり、倍率係数判定部203の結果として、図9(c)および(d)のように人物に対応する部分のみ拡大するものと判定され、mまたはnの倍率係数に決定される。
Therefore, the sum Sx (x) and Sy (y) of the edge intensity values calculated by the feature
以上本実施の形態に係る画像処理装置では、閾値処理部204を追加することであらかじめ小さいエッジ強度値の影響を排除することで、重要部分のより適切な判定が行える。
As described above, in the image processing apparatus according to the present embodiment, by adding the
なお、本実施の形態の閾値処理部204で用いる閾値は、画像全体の平均値の4倍の値を使用するものとしたが、画像によって適応的な値を使用しても、画像によらず固定としてもよい。あるいは外部から直接指定できるような構成としてもよい。
Note that the threshold value used by the threshold
実施の形態3.
図10はこの発明の実施の形態3での画像処理装置の構成を示す構成図であって、図1に示した実施の形態1の画素処理装置と同一の部分については同一の番号を付しており、画像サイズ調整率決定部205、画像サイズ調整処理部500を追加している点が異なる。
Embodiment 3 FIG.
FIG. 10 is a block diagram showing the configuration of the image processing apparatus according to Embodiment 3 of the present invention. Components identical with those of the pixel processing apparatus of
画像サイズ調整率決定部205では、倍率係数判定部203で算出した水平垂直各方向の倍率係数の値から、画像出力部400から出力する画像サイズ(画素数)の仕様を満たすように画像を一様に縮小(または拡大)するための縮小率(または拡大率)を算出する。
In the image size adjustment
画像サイズ調整処理部500は、拡大/縮小処理部300から出力される画像データに対し、画像サイズ調整率決定部205で決定された倍率で縮小又は拡大を行う。
The image size
以下、図11を用いて画像サイズ調整率決定部205での倍率を決定する例を説明する。図11(a)は画像入力部への入力画像、図11(b)は拡大/縮小処理部300の出力である拡大画像、図11(c)および図11(d)は画像サイズ調整処理部500で縮小処理を行った結果の画像の例である。以下では例として、画像サイズ調整処理部500において画像を画像出力部400から出力する画像サイズ(画素数)の仕様を満たすように画像を一様に縮小する場合について説明するが、一様に拡大する場合においても本実施の形態を適用することができる。
Hereinafter, an example of determining the magnification in the image size adjustment
画像入力部100への入力画像である図11(a)の画像は、図2(a)と同じ水平方向W画素、垂直方向H画素の画像とする。拡大/縮小処理部300の出力である拡大画像のサイズは、図11(b)のように水平方向にZW画素(ZWはWより大きな数)、垂直方向にZH画素(ZHはHより大きな数)になるものとする。またここでは、例として、画像出力部400から出力する画像データをモニタに表示する場合を考え、モニタ表示画面で画像全体が欠けないようにするために、画像出力部400から出力する画像サイズを、入力画像と等しく水平方向にW画素、垂直方向にH画素としなければならないものとする。
The image in FIG. 11A, which is an input image to the
図11(b)の拡大画像をモニタ表示画面で画像全体が欠けないようにするには、2つの方法がある。一つ目の方法では、拡大画像の画像サイズZWまたはZHのうちどちらか大きい方を出力画像サイズWまたはHに合わせて拡大画像の水平垂直の各方向ともに同じ倍率で縮小する。二つ目の方法では、垂直水平の各方向について異なる倍率で縮小し入力画像および出力画像と同じ縦横比となるようにする。画像サイズ調整率決定部205及び画像サイズ調整処理部500では、どちらの方法をとってもよい。
There are two methods for preventing the entire image of the enlarged image of FIG. 11B from being lost on the monitor display screen. In the first method, the larger image size ZW or ZH of the enlarged image is reduced at the same magnification in both the horizontal and vertical directions of the enlarged image in accordance with the output image size W or H. In the second method, the vertical and horizontal directions are reduced at different magnifications so as to have the same aspect ratio as the input image and the output image. The image size adjustment
まず一つ目の方法について説明する。この場合、画像サイズ調整率決定部205は垂直水平各方向について同じ(H/ZH)の倍率を算出し、画像サイズ調整処理部500において垂直水平各方向についてこの倍率で縮小する。図11(b)の拡大画像での水平方向の拡大率はZW/W、垂直方向の拡大率はZH/Hとなるが、例えば(ZW/W)<(ZH/H)であるとすれば、垂直方向の方が水平方向よりも拡大率が大きいことになる。このとき拡大画像の垂直水平各方向について同じ(H/ZH)の倍率で縮小すると、縮小画像サイズは垂直方向の画素数がH、水平方向の画素数が(ZW×H/ZH)となる。(ZW/W)<(ZH/H)という前提条件から、W>(ZW×H/ZH)であり、画像サイズ調整処理部500において縮小された縮小画像の水平方向の画像サイズは入力画像の画像サイズWよりも小さく、図11(c)のようになる。
First, the first method will be described. In this case, the image size adjustment
図11(c)では、画像の右側に画像情報のない空白部分(図中斜線部分)が生じるが、この空白部分は左側であっても、左右両側に分かれてあってもよく、空白となる画素列の数は(W−(ZW×H/ZH))で一定である。 In FIG. 11 (c), a blank portion without image information (shaded portion in the figure) is generated on the right side of the image. This blank portion may be on the left side or divided on both the left and right sides, and is blank. The number of pixel columns is constant (W− (ZW × H / ZH)).
次に二つ目の方法について説明する。この場合、画像サイズ調整率決定部205は水平方向にはW/ZW、垂直方向にはH/ZHというように異なる倍率を算出し、画像サイズ調整処理部500において垂直水平各方向についてそれぞれの倍率で縮小する。これにより画像サイズ調整処理部500の出力である縮小画像の画像サイズは水平方向W画素、垂直方向H画素となり、縮小後の画像は図11(d)のようになる。
Next, the second method will be described. In this case, the image size adjustment
このようにして本実施の形態の画像サイズ調整率決定部205は、倍率係数判定部203での判定結果と、画像出力部400から出力する画像サイズ(画素数)とから、画像の水平および垂直の各方向でそれぞれ一様な縮小率(拡大率)を決定する。倍率係数判定部203での判定結果では、画像の画素列毎および画素行毎に倍率係数が決定されるため、画像全体で一様でないのに対し、画像サイズ調整率決定部205で決定される縮小率(拡大率)は、画像の水平および垂直の各方向についてそれぞれ画像全体で一様である。
In this way, the image size adjustment
以上本実施の形態に係る画像処理装置では、画像出力工程で出力される画像のサイズに合わせて一様に縮小又は拡大するので、出力画像の画像サイズを適切に制御することができる。 As described above, in the image processing apparatus according to the present embodiment, the image size of the output image can be appropriately controlled because it is uniformly reduced or enlarged in accordance with the size of the image output in the image output process.
また、水平および垂直の各方向での倍率を変えられる構成とすることにより、入力画像と同じ縦横比となるように出力画像を縮小することができる。その結果、部分的に拡大した画像を、入力画像と同じ画像サイズおよび縦横比で表示することができる。 Further, by adopting a configuration in which the magnification in each of the horizontal and vertical directions can be changed, the output image can be reduced so as to have the same aspect ratio as the input image. As a result, a partially enlarged image can be displayed with the same image size and aspect ratio as the input image.
なお、本実施の形態に係る画像処理装置には、実施の形態2で説明した図6の閾値処理部204を組み合わせることもできる。
Note that the image processing apparatus according to the present embodiment can be combined with the
実施の形態4.
図12はこの発明の実施の形態4での画像処理装置の構成を示す構成図であって、図1に示した画像処理装置と同一の部分については同一の符号を付しており、係数算出部240の倍率係数判定部203の後段に、倍率係数調整部206を追加している点が異なる。
FIG. 12 is a block diagram showing the configuration of the image processing apparatus according to
実施の形態1の例では、図2(c)の背景の山ように、画像出力部400から出力する画像に歪みが生じていた。そこで本実施の形態では、倍率係数調整部206において、倍率係数判定部203で判定した各画素の倍率係数の変化が急な場合、変化が緩やかになるように倍率係数の値を変更する。これにより、画像出力部400から出力する画像の歪みを軽減することができる。
In the example of the first embodiment, the image output from the
図13は倍率係数調整部206での動作を説明するための図である。図13(a)は特徴量算出部202で求めた画像に対する垂直方向総和Sx(x)のグラフ、図13(b)は図13(a)倍率係数判定部203から出力される水平方向の倍率係数のグラフ、図13(c)は倍率係数調整部206により変更された水平方向の倍率係数を示すグラフで、いずれのグラフにおいても横軸は水平方向位置を示す。
FIG. 13 is a diagram for explaining the operation of the magnification
図14は本実施の形態における、画像入力部100に入力される入力画像と拡大/縮小処理部300の出力である拡大画像の説明図である。図14(a)は本実施の形態において画像入力部100に入力される入力画像の例である。図14(b)、(c)、及び(d)は、後述するように、それぞれ異なる条件下における拡大/縮小処理部300の出力である拡大画像である。また、図14(e)は図14(d)の円で囲んだ部分を拡大した部分拡大図である。
FIG. 14 is an explanatory diagram of an input image input to the
実施の形態1で説明したように、倍率係数判定部203は、図13(a)で示すような倍率係数判定閾値THxと水平方向位置xでの垂直方向総和Sx(x)とから、水平方向位置xでの水平方向の倍率係数として1またはm(1より大きい数)のいずれかを選択し、図13(b)に示すような水平方向の倍率係数を得たとする。
As described in the first embodiment, the magnification
水平方向に拡大する部分の倍率を表す水平方向倍率係数mは、大きな値に設定するほど画像全体に対する拡大する部分の相対的な倍率が大きくなり、視認性が高まる。しかし、mの値が大きすぎると拡大画像において画像内容の変化が急峻となり、画像が歪む。 As the horizontal magnification coefficient m representing the magnification of the portion that is enlarged in the horizontal direction is set to a larger value, the relative magnification of the enlarged portion with respect to the entire image is increased, and the visibility is improved. However, if the value of m is too large, the change in the image content in the enlarged image becomes steep and the image is distorted.
倍率係数判定部203での結果は倍率係数判定閾値THxおよびTHyの値によって異なる。例えば、図14(a)の星型図形の画像に対する判定結果は、倍率係数判定閾値THxおよびTHyの値が異なると、水平方向にm倍、垂直方向にn倍に拡大すると判定される領域(以下、本実施の形態では拡大対象領域と呼ぶ)が、点線で囲まれた領域701や点線で囲まれた領域702のように異なってくる。以下、この例を詳しく説明する。
The result of the magnification
いずれの場合も、実施の形態1において図5を用いて説明したように、画像は倍率係数に対応して9つの領域に分かれ、中央の領域である点線で囲まれた領域701または点線で囲まれた領域702では、水平方向はm倍、垂直方向はn倍に拡大となり、それに対応する左側上段、左側下段、右側上段、右側下段の4つの領域は水平方向及び垂直方向ともに等倍のままで、中央上段、中央下段の領域では水平方向にm倍に拡大、垂直方向は等倍のまま、左側中段と右側中段の領域では水平方向は等倍のまま、垂直方向はn倍に拡大となる。
In any case, as described with reference to FIG. 5 in the first embodiment, the image is divided into nine regions corresponding to the magnification coefficient, and is surrounded by the
図14(a)の画像が入力された場合、倍率係数判定部203では中央の星形の図形周辺にのみ倍率係数が1より大きい値を割り当てるが、倍率係数判定閾値THxおよびTHyの値によって領域の形状は変化し、望ましい判定にならない場合がある。図14(a)の画像では、倍率係数判定閾値が適切であれば領域701が、倍率係数判定閾値の値が大きすぎる場合は領域702が拡大対象領域と判定される。いずれの場合でも倍率係数は図13(b)のような矩形状のグラフとなるが、倍率係数がmであると判定される部分の幅が異なり、領域701が拡大対象領域である場合の方が幅は広くなる。
When the image of FIG. 14A is input, the magnification
倍率係数判定部203の拡大対象領域が領域701であった場合、拡大/縮小処理部300では星形図形全体が拡大されて図14(b)のような拡大画像が結果として得られる。
When the enlargement target area of the magnification
倍率係数判定部203の拡大対象領域が領域702であった場合、星型図形の端部は拡大対象ではなくなるため、拡大/縮小処理部300では星形図形の中央付近のみ拡大され図14(c)の実線で示した星型図形ようになる。図14(c)において実線で示した星型図形の端部では倍率係数の変化により図形が歪んでいる。なお、比較のために、歪みのない星型図形を点線で示した。四角の点線で囲まれた領域703は、図14(a)に示す拡大前の画像の領域702に対応する領域を示している。
When the enlargement target area of the magnification
一方、本実施の形態では倍率係数調整部206を追加し、図13(b)のように倍率係数の変化が急な画素の周囲で、変化が緩やかになるように倍率係数を変更する。変更された倍率係数を示す図13(c)では、倍率係数の変更は一次関数的に行っている。これにより、拡大/縮小処理部300の出力の星型図形は図14(d)の実線で示したような星型図形になる。この図では、水平方向のみならず垂直方向についても同様に倍率係数の変更を行っている。なお、比較のために点線で示した星型図形は、歪みのない星型図形である。また、四角の点線で囲まれた領域704は、図14(a)に示す拡大前の画像の領域702に対応する領域を示している。四角の実線で囲まれた領域705は、水平方向又は垂直方向の倍率係数が倍率係数調整部206において倍率係数が変更される領域である。
On the other hand, in the present embodiment, a magnification
図14(e)は図14(d)の円で囲んだ部分を拡大した部分拡大図である。図14(e)において、倍率係数を倍率係数調整部206で調整した場合の星型図形の一部を実線707で、調整しない場合の星型図形の一部を破線706で示した。図14(e)に示されるように、倍率係数調整部206で倍率係数を変更した場合は、変更しない場合と比べて、星形図形の歪みを軽減できる。
FIG. 14E is a partially enlarged view in which a portion surrounded by a circle in FIG. 14D is enlarged. In FIG. 14 (e), a part of the star figure when the magnification coefficient is adjusted by the magnification
以上本実施の形態では、倍率係数調整部206により、倍率係数の変化が急な場合、変化が緩やかになるように倍率係数を変更するようにしたため、万一拡大対象領域の判定が適切でないない場合にも、拡大対象の歪みを軽減することができる。
As described above, in the present embodiment, when the change of the magnification coefficient is abrupt by the magnification
上の例では図13(b)のように倍率係数が1とmの2値しか取らない極端な例を扱った。倍率係数が3値以上を取る場合には、適当な所定値をあらかじめ設けておき、画素の位置変化に対する倍率係数の変化率がその所定値以上の画素について、変化率がもとの変化率以下になるように倍率係数を変更すればよい。 In the above example, as shown in FIG. 13 (b), an extreme example in which the magnification coefficient has only two values of 1 and m is handled. When the magnification coefficient takes three or more values, an appropriate predetermined value is set in advance, and the rate of change of the magnification coefficient with respect to the change in the position of the pixel is equal to or lower than the original change rate. What is necessary is just to change a magnification factor so that it may become.
また、図13(c)では単純に一次関数的に傾きを変化させているが、曲線的な変化としてもよい。 Further, in FIG. 13C, the slope is simply changed in a linear function, but it may be a curved change.
また、本実施の形態に係る画像処理装置は、実施の形態2で説明した図6の閾値処理部204と組み合わせることもできる。また、実施の形態3で説明した図10の画像サイズ調整率決定部205および画像サイズ調整処理部500と組み合わせることもできる。
Further, the image processing apparatus according to the present embodiment can be combined with the
実施の形態5.
図15はこの発明の実施の形態5での画像処理装置の構成を示す構成図であって、図1に示した画像処理装置と同一の部分については同一の符号を付しており、エッジ抽出部201の後段にブロック分割部207を追加している点が異なる。
Embodiment 5 FIG.
FIG. 15 is a block diagram showing the configuration of the image processing apparatus according to the fifth embodiment of the present invention. The same parts as those of the image processing apparatus shown in FIG. The difference is that a
ブロック分割部207は、入力される各画素のエッジ強度値に対し、水平垂直の各方向についていくつかの画素で1つのブロックと見なし、ブロックに含まれる各画素のエッジ強度値からブロックを代表するエッジ強度値を決定する。この値をブロックのエッジ強度値と呼ぶ。ブロックのエッジ強度値を決定する方法としては、そのブロックに含まれる画素のエッジ強度値の平均値や、最大値、最小値、中間値といった特徴的な値とする。あるいはブロック内の特定の位置に配置される画素のエッジ強度値とする方法がある。
The
ブロック分割部207以後の計算や処理において、各画素のエッジ強度値の代わりにブロックのエッジ強度値を用い、画素単位で行っていた計算や処理をブロック単位で行う。これにより、特徴量算出部202以降の計算や処理に使用されるデータ数は入力画像の総画素数からブロック分割部207で分割されるブロック数にまで削減される。
In the calculation and processing after the
具体的には、実施の形態1で説明した特徴量算出部202で行うのエッジ強度値総和の算出、実施の形態2で説明した閾値処理部204で行う閾値処理、実施の形態1で説明した倍率係数判定部203の倍率係数の判定、実施の形態1で説明した拡大/縮小処理部300で行う拡大又は縮小処理、実施の形態4で説明した倍率係数調整部206での倍率係数の変更、実施の形態3で説明した画像サイズ調整率決定部205で行う縮小又は拡大倍率の決定、実施の形態3で説明した画像サイズ調整処理部500で行う一様な縮小又は拡大処理を、画素単位ではなくブロック単位で行う。以上の計算や処理で、画素に設定されるエッジ強度値以外の値(例えば各RGBデータなど)を用いる必要がある場合は、エッジ強度値と同様にブロックの代表値を用いる。ブロックの代表値の決定する方法としては、そのブロックに含まれる画素の値の平均値や、最大値、最小値、中間値といった特徴的な値とする。あるいはブロック内の特定の位置に配置される画素の値とする方法がある。
Specifically, the calculation of the sum of edge strength values performed by the feature
以上本実施の形態では、画素単位で行っていた計算や処理をブロック単位で行うことで、係数算出部で必要な処理時間あるいは演算に必要な回路規模が削減できる。 As described above, in the present embodiment, by performing the calculation and processing performed in units of pixels in units of blocks, it is possible to reduce the processing time required for the coefficient calculation unit or the circuit scale required for calculation.
実施の形態6.
図16はこの発明の実施の形態6での画像処理装置の構成を示す構成図であって、図1に示した画像処理装置と同一の部分については同一の符号を付しており、移動体検出部600及びエッジ変更部208を追加している点と、画像入力部110が入力された画像データを移動体検出部600へ出力する点が異なる。
Embodiment 6 FIG.
FIG. 16 is a block diagram showing the configuration of the image processing apparatus according to Embodiment 6 of the present invention. The same parts as those of the image processing apparatus shown in FIG. The difference is that the
本実施の形態では、時間的に連続する複数の画像が入力される場合に、画像中の移動体部分を検出し、移動体の領域のみを重要部分として優先的に視認性を確保することを目的とする。 In the present embodiment, when a plurality of temporally continuous images are input, a moving body part in the image is detected, and only the area of the moving body is preferentially secured to ensure visibility. Objective.
移動体検出部600は、画像入力部110から時間的に連続する複数の画像を取得し、画像フレーム間で動きのある物体を検出して、その移動体に相当する領域の面積や形状や位置等の情報を得る。検出に用いる画像のフレーム数に制限はなく、検出方法にはパターンマッチングや動きベクトル検出等の一般的な方法を用いるものとする。
The moving
エッジ変更部208は、移動体検出部600で移動体部分であると検出された領域の情報と比較してエッジ抽出部201が出力するエッジ強度値を変更する。
The
次に図17および図18を用いて、本実施の形態の動作の例を説明する。図17において(a)および(b)は画像入力部110に入力される連続するふたつの画像の例である。また、(c)は(b)においてエッジ強度値が大きい領域を示す図で、(d)は(b)の移動体検出部600における移動体部分の検出結果を示す図である。(c)ではエッジ強度値の大きい領域を801および802として、(d)では移動体検出部600において移動体に相当する部分として検出された領域803を点線で囲んで示している。(e)は拡大/縮小処理部300からの出力される拡大画像である。
Next, an example of the operation of this embodiment will be described with reference to FIGS. 17A and 17B are examples of two consecutive images input to the
図18は、図17(a)および(b)の撮影時の人物と車とカメラ900を上部から見た位置関係の説明図である。この図に示したように、車はカメラに近づくように移動しており、カメラ900の視点では、奥の方から手前に向かって車が移動している。図17(a)の画像は、図18で車が位置Cにある時に、図17(b)の画像は図18で車が位置Dにある時にカメラ900により撮影された画像である。 FIG. 18 is an explanatory diagram of a positional relationship when the person, the car, and the camera 900 at the time of photographing shown in FIGS. 17A and 17B are viewed from above. As shown in this figure, the car is moving so as to approach the camera, and from the viewpoint of the camera 900, the car is moving from the back toward the front. The image of FIG. 17A is an image taken by the camera 900 when the car is at position C in FIG. 18 and the image of FIG. 17B is the image when the car is at position D in FIG.
まず、時間的に連続している複数の画像(a)および(b)が画像入力部110に入力されるものとする。図17(a)に続いて図17(b)が画像入力部110に入力される。画像入力部110は、エッジ抽出部201に輝度信号データを、拡大/縮小処理部300に画像データを出力するほか、移動体検出部600にも画像データを出力する。
First, it is assumed that a plurality of images (a) and (b) that are continuous in time are input to the
実施の形態1で説明した動作によれば、図17(b)の画像では車の部分801と人物の部分802の両方が背景と比較してエッジ強度値が大きい部分であるため、このままでは801及び802の両方が重要部分と判定される。
According to the operation described in the first embodiment, in the image of FIG. 17B, both the
一方、図17(a)および(b)を比較すると、人物は動いていないが車は手前に向かって移動しているため、移動体検出部600において図17(d)の803の部分が移動体であると検出される。
On the other hand, comparing FIGS. 17A and 17B, since the person is not moving but the car is moving toward the front, the moving
エッジ変更部208では、エッジ抽出部201の出力データと移動体検出部600の検出結果である移動体部分の面積や形状や位置などの比較を行い、図17(b)に対してはエッジ強度値が所定値以上の部分と移動体検出領域803が一致する領域801のエッジ強度値のみをそのままにして、その他の部分のエッジ強度値を零に変更する。
The
これにより、重要部分は車の部分だけとなり、拡大/縮小処理部300では車に相当する部分のみに拡大又は縮小処理が施され、図17(e)のように車だけが拡大され人物は等倍のままである画像を得る。
As a result, the important part is only the car part, and the enlargement /
以上本実施の形態では、時間的に連続する複数の画像が入力される時に画像中の移動体を検出し、移動体の領域のみを重要部分として優先的に視認性を確保することができる。 As described above, in this embodiment, when a plurality of temporally continuous images are input, a moving body in the image can be detected, and visibility can be preferentially secured with only the area of the moving body as an important part.
なお、本実施の形態では、優先的に視認性を確保する対象を移動体のみとする動作を説明したが、逆に静止物体のみを拡大するような構成とすることもできる。 In the present embodiment, the operation of preferentially securing the visibility with only the moving object being described has been described, but conversely, only a stationary object may be enlarged.
100 画像入力部
200 係数算出部
201 エッジ抽出部
202 特徴量算出部
203 倍率係数判定部
204 閾値処理部
205 画像サイズ調整率決定部
206 倍率係数調整部
207 ブロック分割部
208 倍率係数変更部
300 拡大/縮小処理部
400 画像出力部
500 画像サイズ調整処理部
600 移動体検出部
900 カメラ
DESCRIPTION OF
Claims (14)
前記画像入力部に入力された画像の各画素のエッジ強度値に基づき前記画像を複数の部分に分け、これらの部分毎に拡大又は縮小する倍率を示す倍率係数を算出して出力する係数算出部と、
前記画像入力部に入力された画像を、前記係数算出部で算出される倍率係数に基づき前記部分毎に拡大又は縮小する拡大/縮小処理部と、
前記拡大/縮小処理部で拡大又は縮小された画像を出力する画像出力部とを備えたことを特徴とする画像処理装置。 An image input unit for inputting an image;
A coefficient calculation unit that divides the image into a plurality of parts based on the edge intensity value of each pixel of the image input to the image input unit, and calculates and outputs a magnification coefficient indicating a magnification to be enlarged or reduced for each part. When,
An enlargement / reduction processing unit for enlarging or reducing the image input to the image input unit for each part based on a magnification coefficient calculated by the coefficient calculation unit;
An image processing apparatus comprising: an image output unit that outputs an image enlarged or reduced by the enlargement / reduction processing unit.
画像入力部に入力される画像の各画素のエッジ強度値を抽出して出力するエッジ抽出部と、
前記画像の各画素のエッジ強度値から各行の画素のエッジ強度値の総和と各列のエッジ強度値の総和とを算出する特徴量算出部と、
前記特徴量算出部が算出した各行の画素のエッジ強度値の総和と各列のエッジ強度値の総和に基づき前記画像を複数の部分に分け、これらの部分毎に倍率係数を判定する倍率係数判定部とを有することを特徴とする請求項1に記載の画像処理装置。 The coefficient calculator
An edge extraction unit that extracts and outputs an edge intensity value of each pixel of the image input to the image input unit;
A feature amount calculating unit that calculates the sum of the edge intensity values of the pixels in each row and the sum of the edge intensity values of each column from the edge intensity values of each pixel of the image;
A magnification coefficient determination that divides the image into a plurality of parts based on the sum of the edge intensity values of the pixels in each row and the sum of the edge intensity values of each column calculated by the feature amount calculation unit, and determines a magnification coefficient for each of these parts The image processing apparatus according to claim 1, further comprising: an image processing unit.
前記移動体検出部での検出結果に基づき拡大/縮小処理部で拡大又は縮小する部分を変更することを特徴とする請求項2ないし5のいずれか1項に記載の画像処理装置。 A moving body detection unit that detects a moving body in an image when a plurality of temporally continuous images are input;
The image processing apparatus according to claim 2, wherein a part to be enlarged or reduced by the enlargement / reduction processing unit is changed based on a detection result of the moving body detection unit.
前記画像入力部に入力された画像を複数の画素からなるブロックに分割するブロック分割部と、
前記ブロック分割部で分割された画像の各ブロックのエッジ強度値に基づき前記画像を複数の部分に分け、これらの部分毎に拡大又は縮小する倍率を示す倍率係数を算出して出力する係数算出部と、
前記画像入力部に入力された画像を、前記係数算出部で算出される倍率係数に基づき前記部分毎に拡大又は縮小する拡大/縮小処理部と、
前記拡大/縮小処理部で拡大又は縮小された画像を出力する画像出力部とを備えたことを特徴とする画像処理装置。 An image input unit for inputting an image;
A block dividing unit that divides an image input to the image input unit into blocks each including a plurality of pixels;
A coefficient calculation unit that divides the image into a plurality of parts based on the edge strength value of each block of the image divided by the block division unit, and calculates and outputs a magnification coefficient indicating a magnification to be enlarged or reduced for each part. When,
An enlargement / reduction processing unit for enlarging or reducing the image input to the image input unit for each part based on a magnification coefficient calculated by the coefficient calculation unit;
An image processing apparatus comprising: an image output unit that outputs an image enlarged or reduced by the enlargement / reduction processing unit.
前記画像入力工程で入力された画像の各画素のエッジ強度値に基づき前記画像を複数の部分に分け、これらの部分毎に拡大又は縮小する倍率を示す倍率係数を算出して出力する係数算出工程と、
前記画像入力工程で入力された画像を、前記係数算出工程で算出される倍率係数に基づき前記部分毎に拡大又は縮小する拡大/縮小処理工程と、
前記拡大/縮小処理工程で拡大又は縮小された画像を出力する画像出力工程とを有することを特徴とする画像処理方法。 An image input process in which an image is input;
A coefficient calculation step of dividing the image into a plurality of parts based on the edge intensity value of each pixel of the image input in the image input step, and calculating and outputting a magnification coefficient indicating a magnification to be enlarged or reduced for each of the parts. When,
An enlargement / reduction processing step for enlarging or reducing the image input in the image input step for each portion based on the magnification coefficient calculated in the coefficient calculation step;
An image output step of outputting the image enlarged or reduced in the enlargement / reduction processing step.
画像入力工程で入力される画像の各画素のエッジ強度値を抽出して出力するエッジ抽出工程と、
前記画像の各画素のエッジ強度値から各行の画素のエッジ強度値の総和と各列のエッジ強度値の総和とを算出する特徴量算出工程と、
前記特徴量算出工程で算出した各行の画素のエッジ強度値の総和と各列のエッジ強度値の総和に基づき前記画像を複数の部分に分け、これらの部分毎に倍率係数を判定する倍率係数判定工程とを有することを特徴とする請求項8に記載の画像処理方法。 The coefficient calculation process
An edge extraction step of extracting and outputting the edge intensity value of each pixel of the image input in the image input step;
A feature amount calculating step of calculating the sum of the edge strength values of the pixels in each row and the sum of the edge strength values of each column from the edge strength values of each pixel of the image;
A magnification coefficient determination that divides the image into a plurality of parts based on the sum of the edge intensity values of the pixels in each row and the sum of the edge intensity values of each column calculated in the feature amount calculation step, and determines a magnification coefficient for each of these parts The image processing method according to claim 8, further comprising a step.
前記移動体検出工程での検出結果に基づき拡大/縮小処理部で拡大又は縮小する部分を変更することを特徴とする請求項9ないし12のいずれか1項に記載の画像処理方法。 A moving body detecting step of detecting a moving body in the image when a plurality of temporally continuous images are input;
The image processing method according to claim 9, wherein a portion to be enlarged or reduced by the enlargement / reduction processing unit is changed based on a detection result in the moving object detection step.
前記画像入力工程で入力された画像を複数の画素からなるブロックに分割するブロック分割工程と、
前記ブロック分割工程で分割された画像の各ブロックのエッジ強度値に基づき前記画像を複数の部分に分け、これらの部分毎に拡大又は縮小する倍率を示す倍率係数を算出して出力する係数算出工程と、
前記画像入力工程で入力された画像を、前記係数算出工程で算出される倍率係数に基づき前記部分毎に拡大又は縮小する拡大/縮小処理工程と、
前記拡大/縮小処理工程で拡大又は縮小された画像を出力する画像出力工程とを有することを特徴とする画像処理方法。 An image input process in which an image is input;
A block dividing step of dividing the image input in the image input step into blocks composed of a plurality of pixels;
A coefficient calculation step of dividing the image into a plurality of parts based on the edge strength value of each block of the image divided in the block division step, and calculating and outputting a magnification coefficient indicating a magnification to be enlarged or reduced for each of the parts. When,
An enlargement / reduction processing step for enlarging or reducing the image input in the image input step for each portion based on the magnification coefficient calculated in the coefficient calculation step;
An image output step of outputting the image enlarged or reduced in the enlargement / reduction processing step.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009035209A JP5042251B2 (en) | 2009-02-18 | 2009-02-18 | Image processing apparatus and image processing method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009035209A JP5042251B2 (en) | 2009-02-18 | 2009-02-18 | Image processing apparatus and image processing method |
Publications (3)
Publication Number | Publication Date |
---|---|
JP2010193154A true JP2010193154A (en) | 2010-09-02 |
JP2010193154A5 JP2010193154A5 (en) | 2012-01-19 |
JP5042251B2 JP5042251B2 (en) | 2012-10-03 |
Family
ID=42818722
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2009035209A Expired - Fee Related JP5042251B2 (en) | 2009-02-18 | 2009-02-18 | Image processing apparatus and image processing method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5042251B2 (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5000781B1 (en) * | 2011-11-09 | 2012-08-15 | 楽天株式会社 | Image processing apparatus, image processing apparatus control method, program, and information storage medium |
JP2016511875A (en) * | 2013-12-30 | 2016-04-21 | シャオミ・インコーポレイテッド | Image thumbnail generation method, apparatus, terminal, program, and recording medium |
US9727972B2 (en) | 2013-12-30 | 2017-08-08 | Xiaomi Inc. | Method and terminal for generating thumbnail of image |
CN111563495A (en) * | 2020-05-09 | 2020-08-21 | 北京奇艺世纪科技有限公司 | Method and device for recognizing characters in image and electronic equipment |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH05181948A (en) * | 1992-01-07 | 1993-07-23 | Hitachi Ltd | Image reduction display system |
JP2002165079A (en) * | 2000-11-27 | 2002-06-07 | Minolta Co Ltd | Image processing unit and method |
JP2003087562A (en) * | 2001-09-13 | 2003-03-20 | Toshiba Corp | Image processor and image processing method |
-
2009
- 2009-02-18 JP JP2009035209A patent/JP5042251B2/en not_active Expired - Fee Related
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH05181948A (en) * | 1992-01-07 | 1993-07-23 | Hitachi Ltd | Image reduction display system |
JP2002165079A (en) * | 2000-11-27 | 2002-06-07 | Minolta Co Ltd | Image processing unit and method |
JP2003087562A (en) * | 2001-09-13 | 2003-03-20 | Toshiba Corp | Image processor and image processing method |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5000781B1 (en) * | 2011-11-09 | 2012-08-15 | 楽天株式会社 | Image processing apparatus, image processing apparatus control method, program, and information storage medium |
US9240064B2 (en) | 2011-11-09 | 2016-01-19 | Rakuten, Inc. | Image processing device, method for controlling image processing device, program, and information storage medium |
JP2016511875A (en) * | 2013-12-30 | 2016-04-21 | シャオミ・インコーポレイテッド | Image thumbnail generation method, apparatus, terminal, program, and recording medium |
US9727972B2 (en) | 2013-12-30 | 2017-08-08 | Xiaomi Inc. | Method and terminal for generating thumbnail of image |
CN111563495A (en) * | 2020-05-09 | 2020-08-21 | 北京奇艺世纪科技有限公司 | Method and device for recognizing characters in image and electronic equipment |
CN111563495B (en) * | 2020-05-09 | 2023-10-27 | 北京奇艺世纪科技有限公司 | Method and device for recognizing characters in image and electronic equipment |
Also Published As
Publication number | Publication date |
---|---|
JP5042251B2 (en) | 2012-10-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5906028B2 (en) | Image processing apparatus and image processing method | |
WO2014197154A1 (en) | Methods of image fusion for image stabilizaton | |
US9667841B2 (en) | Image processing apparatus and image processing method | |
JP6172935B2 (en) | Image processing apparatus, image processing method, and image processing program | |
JP2014215604A (en) | Image processing apparatus and image processing method | |
US10412374B2 (en) | Image processing apparatus and image processing method for imaging an image by utilization of a pseudo image | |
JP2011119974A (en) | Panoramic image synthesizer, panoramic image synthesis method, and program | |
JP5042251B2 (en) | Image processing apparatus and image processing method | |
JP2019028912A (en) | Image processing apparatus and image processing method | |
US20210012459A1 (en) | Image processing method and apparatus | |
JP4868249B2 (en) | Video signal processing device | |
JP6056511B2 (en) | Image processing apparatus, method, program, and imaging apparatus | |
JP4930304B2 (en) | Image processing apparatus, image processing method, program, and recording medium | |
KR102470242B1 (en) | Image processing device, image processing method and program | |
JP2018097310A (en) | Display control program, display control method and display control device | |
US9159118B2 (en) | Image processing apparatus, image processing system, and non-transitory computer-readable medium | |
JP2007087218A (en) | Image processor | |
KR102042131B1 (en) | Method for a video stabilization for real-time optical character recognition (OCR) | |
JP7244661B2 (en) | Imaging device and image processing method | |
JP3927979B2 (en) | Image processing apparatus and method | |
US10885348B2 (en) | Information processing device, information processing method, and storage medium | |
JP2012169735A (en) | Image processing device, image processing method, and program | |
JP6937722B2 (en) | Image processing device and image processing method | |
US20220337752A1 (en) | Image processing device, image processing method, non-transitory computer-readable storage medium | |
JP2005217902A (en) | Image processing apparatus and image processing method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD01 | Notification of change of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7421 Effective date: 20111107 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20111125 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20111125 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20120327 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20120517 |
|
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: 20120612 |
|
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20120710 |
|
R150 | Certificate of patent or registration of utility model |
Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20150720 Year of fee payment: 3 |
|
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 |
|
LAPS | Cancellation because of no payment of annual fees |