JP6200220B2 - Image processing apparatus, encoding apparatus, decoding apparatus, and program - Google Patents
Image processing apparatus, encoding apparatus, decoding apparatus, and program Download PDFInfo
- Publication number
- JP6200220B2 JP6200220B2 JP2013132070A JP2013132070A JP6200220B2 JP 6200220 B2 JP6200220 B2 JP 6200220B2 JP 2013132070 A JP2013132070 A JP 2013132070A JP 2013132070 A JP2013132070 A JP 2013132070A JP 6200220 B2 JP6200220 B2 JP 6200220B2
- Authority
- JP
- Japan
- Prior art keywords
- unit
- depth
- image
- block
- information
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000012545 processing Methods 0.000 title claims description 99
- 238000013139 quantization Methods 0.000 claims description 160
- 239000011159 matrix material Substances 0.000 claims description 88
- 238000007906 compression Methods 0.000 claims description 68
- 230000006835 compression Effects 0.000 claims description 67
- 238000012937 correction Methods 0.000 claims description 39
- 238000000034 method Methods 0.000 description 30
- 238000007781 pre-processing Methods 0.000 description 21
- 230000008569 process Effects 0.000 description 17
- 238000010586 diagram Methods 0.000 description 10
- 230000009466 transformation Effects 0.000 description 10
- 238000004364 calculation method Methods 0.000 description 8
- 230000006870 function Effects 0.000 description 6
- 230000010354 integration Effects 0.000 description 6
- 238000012986 modification Methods 0.000 description 6
- 230000004048 modification Effects 0.000 description 6
- 230000007274 generation of a signal involved in cell-cell signaling Effects 0.000 description 5
- 230000015556 catabolic process Effects 0.000 description 4
- 238000006731 degradation reaction Methods 0.000 description 4
- 230000006866 deterioration Effects 0.000 description 4
- 230000002093 peripheral effect Effects 0.000 description 3
- 230000005540 biological transmission Effects 0.000 description 2
- 238000006243 chemical reaction Methods 0.000 description 2
- 230000001131 transforming effect Effects 0.000 description 2
- 238000012935 Averaging Methods 0.000 description 1
- 241000282412 Homo Species 0.000 description 1
- 238000009825 accumulation Methods 0.000 description 1
- 230000003044 adaptive effect Effects 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 230000008094 contradictory effect Effects 0.000 description 1
- 230000007423 decrease Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000012447 hatching Effects 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000004321 preservation Methods 0.000 description 1
- 238000001454 recorded image Methods 0.000 description 1
- 230000004044 response Effects 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Images
Landscapes
- Compression Or Coding Systems Of Tv Signals (AREA)
Description
本発明は、画像の奥行き情報を用いて量子化ステップを調整する画像処理装置、符号化装置、復号装置、及びプログラムに関する。 The present invention relates to an image processing apparatus, an encoding apparatus, a decoding apparatus, and a program that adjust a quantization step using depth information of an image.
近年、奥行き情報を取得できる深度センサを搭載したカメラが盛んに研究開発されている。例えば、RGBにD(奥行き)を加えた画像情報を取得するRGB―Dセンサを搭載したカメラの一例として、Microsoft社のKinect(登録商標)がある。このような背景から、2次元の画像信号と、奥行き情報とを有する動画像情報の利用が増加することが予想される。 In recent years, a camera equipped with a depth sensor capable of acquiring depth information has been actively researched and developed. For example, there is Microsoft's Kinect (registered trademark) as an example of a camera equipped with an RGB-D sensor for acquiring image information obtained by adding D (depth) to RGB. From such a background, it is expected that the use of moving image information having a two-dimensional image signal and depth information will increase.
また、動画情報を効率的に処理する規格であるH.264/AVC(Advanced Video Coding)やH.265/HEVC(High Efficiency Video Coding)の映像の圧縮符号化方式では、映像の各フレームをブロックと呼ばれる矩形領域に分割して符号化が行われる。 In addition, H.264, which is a standard for efficiently processing moving image information. H.264 / AVC (Advanced Video Coding) and H.264. In the H.265 / HEVC (High Efficiency Video Coding) video compression encoding method, each frame of the video is divided into rectangular areas called blocks, and encoding is performed.
この映像の圧縮の手法の1つとして、画像の符号化の際に量子化の処理が行われる。量子化とは、元々持っているデータの細かさを粗く分け直す処理である。すなわち、直交変換した各周波数成分に対して、所定の量子化ステップで除算した結果を整数値に丸める処理を「量子化」と呼んでいる。逆に、この量子化で得られた整数値に量子化ステップを乗算して直交変換した成分に戻す処理を「逆量子化」と呼ぶ。 As one of the video compression methods, quantization processing is performed when an image is encoded. Quantization is a process of roughly re-dividing the fineness of data originally possessed. That is, the process of rounding the result obtained by dividing each frequency component subjected to orthogonal transformation by a predetermined quantization step to an integer value is called “quantization”. Conversely, the process of multiplying the integer value obtained by this quantization by a quantization step and returning it to the orthogonally transformed component is called “inverse quantization”.
量子化によって、直交変換した成分よりも小さな整数値と少ないバリエーションとなった量子化値を符号化することで、直交変換した成分を直接符号化するよりも符号化に必要なビット数を少なくすることができる(例えば非特許文献1、及び非特許文献2参照)。
Quantization reduces the number of bits required for encoding compared to direct encoding of orthogonally transformed components by encoding smaller integer values and smaller variations of quantized values than orthogonally transformed components (For example, see Non-Patent
図1は、H.264/AVCにおける、インターブロック(画面間符号化ブロック)の量子化マトリクスの例を示す図である。図1(a)は、4×4の16個のインターブロックの量子化マトリクス110を示している。図1(b)は、8×8の64個のインターブロックの量子化マトリクス120を示している。
FIG. 2 is a diagram illustrating an example of a quantization matrix of an inter block (inter-coded block) in H.264 / AVC. FIG. 1A shows a 4 × 4 16
例えば、図1(b)における量子化マトリクス120のブロック101の量子化ステップ値は、「9」を示している。画像をDCT(離散コサイン変換)した場合、このブロック101に対応するDCT係数は、DC(直流)成分に該当する。したがって、DCTの直流成分を9で除算し、余りを切り捨てた商の値が、DC成分の量子化後の値となる。
For example, the quantization step value of the
量子化ステップが小さい場合には、DCT係数の周波数成分を量子化ステップで割り、切り捨てられる余りは一般に小さくなる。このため、量子化された値を逆量子化して戻した値と、量子化前の値との誤差は小さくなり、量子化による画像の品質の劣化は少ない。しかしながら、商の値は一般に大きくなるとともに商の値がとり得るバリエーションが多くなるため、符号化効率(圧縮率)は低下する。したがって、量子化ステップを変えることで、圧縮率、画像の品質等を調整することが可能である。 When the quantization step is small, the frequency component of the DCT coefficient is divided by the quantization step, and the remainder that is discarded is generally small. For this reason, an error between a value obtained by dequantizing the quantized value and a value before quantization is small, and deterioration in image quality due to quantization is small. However, since the value of the quotient generally increases and the variation that the value of the quotient can take increases, the coding efficiency (compression rate) decreases. Therefore, it is possible to adjust the compression rate, the image quality, and the like by changing the quantization step.
一般に、量子化ステップは、人間の目に認識されやすい低周波成分(図1の量子化マトリクスの左上部分)に対して、小さな値とする。そして、人間の目に対して画像の劣化が認識されにくい高周波成分(図1の量子化マトリクスの右下部分)に対して、大きな値とすることが多い。 In general, the quantization step is set to a small value with respect to a low-frequency component (upper left portion of the quantization matrix in FIG. 1) that is easily recognized by human eyes. In many cases, a large value is set for a high-frequency component (lower right portion of the quantization matrix in FIG. 1) in which image degradation is difficult to be recognized by human eyes.
上述のように、量子化ステップを大きくすれば、画像の符号化効率を高めることができる。しかしながら、空間周波数の低い画像の領域において、等高線のような擬似輪郭が発生する傾向が高くなる。 As described above, if the quantization step is increased, the encoding efficiency of the image can be increased. However, there is a high tendency for pseudo contours such as contour lines to occur in an image region having a low spatial frequency.
逆に、量子化ステップを小さくすれば、画像の圧縮率は低下するが、画像表現及び精細度が向上した画像を再現することができる。しかしながら、例えば被写界深度外のような、一般的に人間によって重要視されない画像領域においても、低圧縮の処理が施されるため、全体的な圧縮率を低下させることになる。 Conversely, if the quantization step is reduced, the compression ratio of the image is reduced, but an image with improved image expression and definition can be reproduced. However, for example, even in an image region that is generally not important by humans, such as outside the depth of field, the low compression process is performed, so that the overall compression rate is reduced.
したがって、互いに相反する画像の品質の担保と圧縮率の確保を得るためには、画像の性質に応じて、量子化ステップの値を適切に選ぶことが重要である、 Therefore, it is important to appropriately select the value of the quantization step according to the nature of the image in order to ensure the quality of the mutually contradictory image and ensure the compression rate.
上述のように、量子化ステップは、擬似輪郭の発生などの画像品質、及び画像データの圧縮率に密接に関連している。そして、被写界深度内にある画像領域は、注視領域である可能性が高いため、擬似輪郭による視覚的な画像の劣化が目立ちやすい。 As described above, the quantization step is closely related to the image quality such as the generation of pseudo contours and the compression rate of the image data. Since the image area within the depth of field is likely to be a gaze area, visual image degradation due to pseudo contours is easily noticeable.
また、CMOS等の撮像素子で生じるノイズは、被写界深度内/外で一様に含まれ、符号化効率を低下させる。しかしながら、ノイズは画像表現及び精細度向上のために重要であり、被写界深度内/外で一様に除去すればよいというものではない。 In addition, noise generated in an image pickup device such as a CMOS is uniformly included in / out of the depth of field, which reduces the encoding efficiency. However, noise is important for improving the image expression and definition, and it does not have to be removed uniformly within / out of the depth of field.
そこで、本発明は、奥行き情報を用いて、画像の被写界深度内/外の情報を求めると共に、この情報を用いて量子化ステップの値を調整することで、画像劣化を抑制し、或いは符号化効率を向上させることを目的とする。 Therefore, the present invention uses the depth information to obtain information inside / outside the depth of field of the image, and adjusts the value of the quantization step using this information, thereby suppressing image degradation, or The purpose is to improve the coding efficiency.
本発明の一態様における画像処理装置は、画像の奥行きの情報を用いて画像の量子化ステップを調整する画像処理装置であって、前記画像に含まれる複数のブロックの各々の空間周波数のパワーを取得する空間周波数取得部と、前記画像における各画素位置又は各所定領域の奥行きの情報をクラスタリングし、当該クラスタリングの結果に基づいて、前記複数のブロックの各々のクラスタを決定する奥行き情報クラスタリング部と、所定のクラスタに属する1つ以上のブロックの空間周波数のパワーと、前記所定のクラスタ以外に属する複数のブロックの空間周波数のパワーとに基づいて、前記所定のクラスタに属する前記1つ以上のブロックを被写界深度内に属すると判定する、被写界深度判定部と、前記被写界深度判定部の判定結果と、前記画像の圧縮率とに基づいて、前記複数のブロックのうち所定のブロックに対して、直交変換された複数の周波数成分の各々の量子化ステップを含む量子化マトリクスの値を修正する、量子化マトリクス修正部と、を有する。 An image processing apparatus according to an aspect of the present invention is an image processing apparatus that adjusts a quantization step of an image by using information on the depth of the image, and calculates a spatial frequency power of each of a plurality of blocks included in the image. A spatial frequency acquisition unit to acquire, and a depth information clustering unit that clusters information on the depth of each pixel position or each predetermined region in the image and determines each cluster of the plurality of blocks based on the result of the clustering; a power of one or more spatial frequencies of the block belonging to a given cluster, based on the power of the spatial frequency of a plurality of blocks belonging to other than the given cluster, the one or more blocks belonging to the given cluster And a determination result of the depth of field determination unit, the determination result of the depth of field determination unit, A quantization matrix including a quantization step including a quantization step for each of a plurality of frequency components orthogonally transformed with respect to a predetermined block of the plurality of blocks based on a compression rate of the recorded image; A matrix correction unit.
前記画像の圧縮率が所定の第1の圧縮率より高い場合を高圧縮率と判定する圧縮率判定部を有し、前記被写界深度判定部は、前記所定のクラスタに属する1つ以上のブロックの空間周波数のうち所定の空間周波数を越える空間周波数のパワーの割合が、前記所定のクラスタ以外に属する複数のブロックの空間周波数のうち前記所定の空間周波数を越える空間周波数のパワーの割合より高い場合、前記所定のクラスタに属する前記1つ以上のブロックを被写界深度内に属すると判定し、前記量子化マトリクス修正部は、前記圧縮率が、高圧縮率である場合、被写界深度内に属すると判定された前記1つ以上のブロックのうち、空間周波数の低周波成分のパワーの割合が所定の割合より高いブロックに対して、前記量子化マトリクスの所定の領域を、より小さい値に修正してもよい。
A compression rate determination unit that determines that the compression rate of the image is higher than a predetermined first compression rate as a high compression rate, wherein the depth-of-field determination unit includes at least one of the predetermined clusters The proportion of the spatial frequency power exceeding the predetermined spatial frequency among the spatial frequencies of the blocks is higher than the proportion of the power of the spatial frequency exceeding the predetermined spatial frequency among the spatial frequencies of the plurality of blocks belonging to other than the predetermined cluster. The one or more blocks belonging to the predetermined cluster are determined to belong to a depth of field, and the quantization matrix correction unit determines the depth of field when the compression rate is a high compression rate. Among the one or more blocks determined to belong to, a predetermined area of the quantization matrix for a block in which the power ratio of the low frequency component of the spatial frequency is higher than a predetermined ratio , It may be modified to a smaller value.
また、前記量子化マトリクス修正部は、前記圧縮率が、所定の第2の圧縮率より低い場合、被写界深度内に属すると判定された前記1つ以上のブロック以外のブロックに対して、前記量子化マトリクスの値を、より大きい値に修正してもよい。 In addition, the quantization matrix correction unit, for the blocks other than the one or more blocks determined to belong within the depth of field when the compression rate is lower than a predetermined second compression rate, The value of the quantization matrix may be modified to a larger value.
また、前記空間周波数の低周波成分のパワーの割合が所定の割合より高いブロックは、第1の閾値以下の空間周波数のパワーを前記第1の閾値を超える空間周波数のパワーで除した値が、第2の閾値を越えるブロックであってもよい。 Further, in the block in which the ratio of the power of the low frequency component of the spatial frequency is higher than a predetermined ratio, the value obtained by dividing the power of the spatial frequency below the first threshold by the power of the spatial frequency exceeding the first threshold is: The block may exceed the second threshold.
また、本発明の他の態様における符号化装置は、上記画像処理装置を備えてもよい。 An encoding apparatus according to another aspect of the present invention may include the image processing apparatus.
また、本発明の他の態様におけるプログラムは、コンピュータを、上記符号化装置として機能させる。 A program according to another aspect of the present invention causes a computer to function as the encoding device.
本発明によれば、奥行き情報を用いて、画像内の被写界深度内/外判定を行って量子化ステップを調整するので、画像劣化を抑制し、又は符号化効率を向上させることができる。 According to the present invention, since the quantization step is adjusted by performing the inside / outside determination of the depth of field in the image using the depth information, it is possible to suppress the image deterioration or improve the encoding efficiency. .
以下、実施例について図面を参照しながら説明する。 Hereinafter, embodiments will be described with reference to the drawings.
[実施例1]
実施例1における画像処理装置10は、修正された量子化マトリクスを決定する装置である。この画像処理装置は、プログラムが実行されることで機能してもよいし、集積回路などにより実装されてもよい。
[Example 1]
The
<実施例1の概要及び位置づけ>
実施例1は、修正された量子化マトリクス(又は量子化パラメータ)を決定するために、画像の奥行き情報に基づく被写界深度の情報を用いる。この量子化マトリクス(又は量子化パラメータ)は、既に述べたように、画像の符号化の過程において、情報の圧縮を行うために用いられる。したがって、以下に詳述する実施例1は、例えば、画像符号化装置の中で用いることができる。なお、画像符号化装置については、実施例2において、その具体例を示すこととする。
<Outline and Position of Example 1>
Example 1 uses depth-of-field information based on image depth information to determine a modified quantization matrix (or quantization parameter). As already described, this quantization matrix (or quantization parameter) is used to compress information in the process of image encoding. Therefore, Example 1 described in detail below can be used in, for example, an image encoding device. A specific example of the image encoding device will be described in the second embodiment.
なお、実施例1で用いる被写界深度の情報を得るためには、分割された各ブロックにおける奥行き情報と、空間周波数の情報に関して画像の1フレーム分の情報を取得することが望ましい。このため、以下に説明する実施例1においては、1フレームの画像処理を2パスで行う具体例を示す。 In order to obtain information on the depth of field used in the first embodiment, it is desirable to acquire information for one frame of the image regarding the depth information in each divided block and the spatial frequency information. For this reason, the first embodiment described below shows a specific example in which image processing for one frame is performed in two passes.
すなわち、1パス目において、1フレーム内の各ブロックの被写界深度情報が得られる。そして、2パス目において、この被写界深度情報を用いて、1フレーム内の各ブロックの量子化マトリクス(又は量子化パラメータ)を修正する処理が施される。 That is, in the first pass, depth-of-field information of each block in one frame is obtained. In the second pass, processing for correcting the quantization matrix (or quantization parameter) of each block in one frame is performed using this depth of field information.
したがって、1パス目及び2パス目のいずれのパスにおいても、実施例1を含む画像符号化装置全体が動作することは、当業者であれば理解されるところである。なお、1パス目におけるブロック分割情報を、そのまま2パス目で用いることが望ましい。このため、1パス目におけるブロック分割情報が保存され、2パス目の処理において、その保存されたブロック分割情報が利用される。なお、実施例1は2パスの処理に限定されるものではない。 Therefore, those skilled in the art will understand that the entire image encoding apparatus including the first embodiment operates in both the first pass and the second pass. It is desirable to use the block division information in the first pass as it is in the second pass. For this reason, the block division information in the first pass is saved, and the saved block division information is used in the process of the second pass. The first embodiment is not limited to the two-pass process.
なお、実施例1においては、画像符号化装置における前処理部、エントロピー符号化部、予測誤差信号、ブロック直交変換後情報、量子化後情報等にも言及している。これらの詳細は、画像符号化装置の具体例を示す実施例2において詳述するが、実施例1の理解を助けるために、これらの概略を以下に簡潔に述べることとする。 In the first embodiment, reference is also made to a preprocessing unit, an entropy coding unit, a prediction error signal, post-block orthogonal transform information, post-quantization information, and the like in the image coding apparatus. These details will be described in detail in a second embodiment showing a specific example of an image encoding device. In order to facilitate understanding of the first embodiment, the outline thereof will be briefly described below.
前処理部は、原画像のピクチャタイプに合わせてピクチャを並べ替え、ピクチャタイプ及びフレーム毎のフレーム画像等を順次出力する。また、前処理部は、ブロック分割なども行う。 The preprocessing unit rearranges the pictures in accordance with the picture type of the original image, and sequentially outputs the picture type and the frame image for each frame. The preprocessing unit also performs block division and the like.
エントロピー符号化部は、シンボルの出現頻度に応じて可変長の符号を割り当てるものであり、量子化された信号出力等を符号化する。 The entropy encoding unit assigns a variable-length code according to the appearance frequency of the symbol, and encodes the quantized signal output and the like.
予測誤差信号とは、原画像のブロックのデータと、予測画像のブロックのデータの差分値を意味する。他のフレームの情報又は同一フレーム内の周辺の情報から、画像を予測し、原画像との差分を得て、予測誤差信号を得ることによって、符号化すべき画像の情報量を圧縮することができる。 The prediction error signal means a difference value between block data of the original image and block data of the prediction image. The amount of information of an image to be encoded can be compressed by predicting an image from other frame information or peripheral information in the same frame, obtaining a difference from the original image, and obtaining a prediction error signal. .
ブロック直交変換後情報とは、予測誤差信号を直交変換することによって得られた情報を意味する。直交変換の手法としては、例えばDCT(離散コサイン変換)が用いられる。予測誤差信号を直交変換することによって、更に情報の圧縮が可能である。 The post-block orthogonal transformation information means information obtained by orthogonal transformation of the prediction error signal. For example, DCT (Discrete Cosine Transform) is used as the orthogonal transform method. Information can be further compressed by orthogonally transforming the prediction error signal.
量子化後情報とは、直交変換後の情報を量子化した情報を意味する。直交変換後の情報を量子化することによって出力信号の符号量を低減することができる。 The post-quantization information means information obtained by quantizing information after orthogonal transformation. By quantizing the information after the orthogonal transformation, the code amount of the output signal can be reduced.
以上の前提に基づいて、以下、実施例1の構成及び動作について詳述する。なお、実施例1は、これらの前提に限定されるものではない。
<実施例1の構成>
実施例1における1つのフレームに対する処理は、大きく1パス目と2パス目に分けられる。特定のフレームに対する1パス目の処理が終了すると、その特定のフレームに対する2パス目の処理が実行される。
Based on the above assumptions, the configuration and operation of the first embodiment will be described in detail below. The first embodiment is not limited to these assumptions.
<Configuration of Example 1>
The processing for one frame in the first embodiment is roughly divided into the first pass and the second pass. When the first pass processing for the specific frame is completed, the second pass processing for the specific frame is executed.
図2は、実施例1における画像処理装置10の概略ブロック図である。図2に示す画像処理装置は、1パス目動作部140と、1パス・2パス切替指示部130と、量子化マトリクス修正部160とを有する。1パス・2パス切替指示部130が、1パス目動作指示信号132を活性化させ、1パス目動作部140を動作させる。また、1パス・2パス切替指示部130は、1パス・2パス切替指示162を前処理部200に与え、前処理部200が1パス目の処理であることを認識させる。なお、前処理部の動作については、後述する。また、1パス・2パス切替指示部130は、2パス目動作指示信号184を活性化させ、量子化マトリクス修正部160を動作させる。また、1パス・2パス切替指示部130は、2パス目動作指示信号184を活性化させ、後述するエントロピー符号化部を動作させる。
FIG. 2 is a schematic block diagram of the
1パス目動作部140は、ブロック分割情報保存部111と、予測誤差信号情報量積算部112と、奥行き情報クラスタリング部113と、被写界深度判定部114と、空間周波数取得部115と、量子化後情報量積算部116と、圧縮率判定部117とを有する。また、被写界深度判定部114は被写界深度保存部118を含む。
The first-
1パス目動作部140は、1パス目において動作を行い、2パス目は、必用な情報を他の処理部に提供する能力を有する。
The first
ブロック分割情報保存部111は、前処理部200からのブロック分割情報164を取得し、順次保存する。ブロック分割情報保存部111は、少なくとも1フレーム分のブロック分割情報を保存することができる。1フレーム分のブロック分割情報は、被写界深度保存部118に提供される。また、1フレーム分のブロック分割情報164は、前処理部に提供され、前処理部が、2パス目において、1パス目と同じブロック分割を行うことができるようにする。
The block division
予測誤差信号情報量積算部112は、1フレーム分の予測誤差信号168の情報量の積算値aを取得する。
The prediction error signal information
量子化後情報量積算部116は、1フレーム分の、量子化後情報182を積算し、積算値bを取得する。
The post-quantization information amount integration unit 116 integrates
圧縮率判定部117は、b/a=cを計算することにより、直交変換と量子化により達成される1フレーム分の情報量の圧縮率cを取得する。圧縮率cが所定の第1の圧縮率より高い場合を「高圧縮率」と判定し、圧縮率cが所定の第2の圧縮率より低い場合、「低圧縮率」と判定する。この判定の結果は、2パス目において量子化マトリクス修正部160に提供される。
The compression
奥行き情報クラスタリング部113は、例えば、1フレーム分の奥行き情報のヒストグラムを求め、このヒストグラムが取る値の範囲をクラスタ数n(例えばn=2)に等分割し、奥行き情報を分類する。奥行き情報クラスタリング部113は、各画素位置又は各所定領域の奥行き情報のクラスタリング結果として、奥行き降順に番号(例えば、クラスタ番号=1、0)を付与して、このクラスタリング結果を得る。クラスタリングの手法としては、K−means法を用いることができる。
For example, the depth
K-means法は,あらかじめ固定された数(例えば,n個)のクラスタの各々にその代表であるプロトタイプを与え,それぞれのデータを最も近いプロトタイプに割り当てることでクラスタリングを行う手法である。なお、実施例1は、特定のクラスタリング手法に限定されるものではない。 The K-means method is a technique for performing clustering by giving a prototype that is a representative to each of a predetermined number of clusters (for example, n) and assigning each data to the nearest prototype. The first embodiment is not limited to a specific clustering method.
被写界深度判定部114は、クラスタリング結果、及び空間周波数のパワーの情報として例えばブロック直交変換後情報172を用いる。ブロック直交変換後情報172は、空間周波数取得部115を介して取得される。
The depth of field determination unit 114 uses, for example, post-block
なお、図2において空間周波数取得部115は、ブロック直交変換後情報172の代わりに、原画像から空間周波数のパワーを直接求めてもよい。この場合には、空間周波数取得部115に、原画像を与える。そして、空間周波数取得部115において、該当するブロックについて空間周波数のパワーを計算する。空間周波数のパワーを取得する手法としては、DCT(離散コサイン変換)、アダマール変換、離散フーリエ変換などを用いることができる。
In FIG. 2, the spatial
まず、被写界深度判定部114は、同じクラスタにクラスタリングされた直交変換ブロックの空間周波数のうち、高い帯域のパワーの割合を算出する。なお、パワーではなく、空間周波数のレベルの絶対値、空間周波数の成分毎の強度等を用いてもよい。 First, the depth-of-field determination unit 114 calculates a ratio of power in a high band among spatial frequencies of orthogonal transform blocks clustered in the same cluster. Instead of power, the absolute value of the spatial frequency level, the intensity of each spatial frequency component, or the like may be used.
なお、本明細書においては、「空間周波数のパワー」の語を用いるが、この語は、「空間周波数のレベルの絶対値」、「空間周波数の成分毎の強度」等をも意味する語として用いる。 In this specification, the term “spatial frequency power” is used, but this term also means “absolute value of spatial frequency level”, “intensity for each component of spatial frequency”, and the like. Use.
図3は、画像の1つのブロックを直交変換して得られた直交変換係数(空間周波数)をブロック状に並べた例を示している。空間周波数成分300は、1つの直交変換ブロック(8画素×8ライン)の64画素をDCT変換した64個のDCT係数を、水平成分及び垂直成分に並べたものである。
FIG. 3 shows an example in which orthogonal transform coefficients (spatial frequencies) obtained by orthogonal transform of one block of an image are arranged in blocks. The
例えば、空間高周波成分の領域は、斜線で示した周波数領域390である。周波数領域390は、水平方向、及び垂直方向、それぞれの空間最大周波数の1/2を超える領域である。周波数領域390の空間周波数のパワーをH1、全体の空間周波数成分300の空間周波数のパワーをW1とすれば、周波数領域390の空間高周波数のパワーの割合α1は、以下の式で求まる。
For example, the region of the spatial high frequency component is a
α1=H1/W1
クラスタ数を2個とし、ここで求めたα1を、クラスタ0に属する複数のブロックの各々に対して求めて、空間高周波数のパワーの割合の平均値αを求める。同様にクラスタ1に属する複数のブロック全体に対して求めた空間高周波数のパワーの割合の平均値をβとする。
α 1 = H 1 / W 1
The number of clusters is set to two, and α 1 obtained here is obtained for each of a plurality of blocks belonging to
そして、αとβを比較し、α>βであれば、αが導かれたクラスタ0に属する複数のブロックが、被写界深度の領域内であると判断することができる。その理由は、被写界深度内の領域は、ぼけのない鮮明な画像が多いため、空間高周波数のパワーの割合が大きくなるという経験則に基づいているからである。以上のようにして、被写界深度内/外の領域を特定することができる。 Then, α and β are compared, and if α> β, it can be determined that a plurality of blocks belonging to cluster 0 from which α is derived are within the depth of field region. The reason is that the region within the depth of field is based on an empirical rule that the ratio of the power of the spatial high frequency is large because there are many clear images without blur. As described above, it is possible to specify a region within / out of the depth of field.
なお、図3に示す空間高周波数成分の領域の取り方は、一例に過ぎず、実施例1は、これに限定されない。また、上記の例では、クラスタ数を2としたが、3以上のクラスタに分けて、空間高周波数のパワーの割合が最も大きくなるクラスタに属する複数のブロックで構成される領域を、被写界深度内の領域と判定してもよい。 In addition, the method of taking the area | region of the spatial high frequency component shown in FIG. 3 is only an example, and Example 1 is not limited to this. In the above example, the number of clusters is 2. However, an area composed of a plurality of blocks belonging to a cluster having the highest spatial high frequency power ratio is divided into three or more clusters. You may determine with the area | region within the depth.
また、上述の例では、図3の空間周波数成分300の左上(0,0)の位置のDCT係数の直流(DC)成分をも、全体の空間周波数のパワーの平均値を求める際に利用した。しかしながら、DC成分は、ブロックの明るさに関連する係数であるため、空間周波数のパワーの平均値を求める際に、計算から除外してもよい。DC成分を除外することによって、画像の明るさに左右されずに、空間高周波数のパワーの割合α1を求めることができる。
In the above example, the direct current (DC) component of the DCT coefficient at the upper left (0, 0) position of the
被写界深度判定部114に含まれる被写界深度保存部118は、ブロック分割情報保存部111からの情報と、被写界深度判定部114での情報とを用いて、1フレームに含まれる各ブロックの被写界深度の内/外の情報を保存する。
The depth of
以上の処理によって、1パス目動作部140は、現在処理しているフレームが、高圧縮率、低圧縮率、あるいはそれ以外かの特定を行う。加えて、1パス目動作部140は、1フレームの各ブロックに対して、被写界深度の内/外の特定を行う。
Through the above processing, the first-
1パス・2パス切替指示部130は、前処理部200に対し、2パス目の処理であることを伝達する。前処理部200は、この伝達に応答して、ブロック分割情報保存部111から得られたブロック分割情報に従って、ブロック分割を行い、各ブロックが処理されるよう、ブロックに関する情報を順次出力する。また、1パス・2パス切替指示部130は、2パス目動作指示信号184を、量子化マトリクス修正部160及びエントロピー符号化部204に与える。なお、エントロピー符号化部204については、図7を用いて後述する。
The 1-pass / 2-pass
量子化マトリクス修正部160は、符号化のために一旦作成された量子化マトリクス又は量子化パラメータであるQp値174、被写界深度判定部114からの情報、空間周波数取得部115からの情報、及び圧縮率判定部117からの情報を受け取る。量子化マトリクス修正部160は、符号化のために一旦作成された量子化マトリクス又は量子化パラメータであるQp値174を修正することができる。
The quantization
まず、圧縮率判定部117が、高圧縮であると判定した場合を説明する。この場合には、量子化マトリクス修正部160は、被写界深度内に属するブロックに対して、擬似輪郭の発生を抑制する処理を施す。
First, a case where the compression
量子化マトリクス修正部160は、被写界深度内に属するブロックのうち、空間低周波数のパワーの割合が、例えば所定の閾値より高いブロックを特定する。一般に、被写界深度内のブロックは、鮮明度が高いため、空間低周波数のパワーよりも空間高周波数のパワーの割合が高い場合が多い。しかしながら、オブジェクトのテクスチャ自体が空間低周波数を持つような場合には、被写界深度内においても、空間低周波数のパワーの割合が高いブロックが存在する場合がある。このようなブロックでは、上述のように擬似輪郭が発生する確率が高い。しかも被写界深度内にそのブロックが存在するために、この擬似輪郭が目立ちやすいと判断される。
The quantization matrix correction |
したがって、量子化マトリクス修正部160は、このようなブロックに対して、擬似輪郭の発生を抑制するために、量子化マトリクスの値を、より小さくすることが望ましい。このため、量子化マトリクス修正部160は、このようなブロックを特定する。
Therefore, it is desirable that the quantization
量子化マトリクス修正部160は、特定されたブロックの量子化ステップを、より小さな値にして修正する。たとえば、量子化マトリクス修正部160は、量子化マトリクスの各要素の値を1/2にした値に修正してもよい。或いは、量子化マトリクス修正部160は、Qp値を、例えば6減算してもよい。Qp値が6減算されると、量子化マトリクスの値の各々は、1/2に設定されることになる。
The quantization
或いは、例えば、図3に周波数領域390で示した量子化マトリクスの空間高周波成分の領域に対応する量子化マトリクスの値のみを1/2にした値に修正してもよい。あるいは、図3において、行番号が4以上、列番号が4以上の周波数領域に対応する量子化マトリクスの値のみを1/2にした値に修正してもよい。なお、修正のための係数1/2の値は例であり、その他の計数値を掛けても良いことは言うまでもない。また、空間高周波成分としてどの空間周波数の帯域を採用するかは、上記の例に限定されない。
Alternatively, for example, only the value of the quantization matrix corresponding to the spatial high frequency component region of the quantization matrix indicated by the
上述のように、空間高周波成分に対応する量子化マトリクスの値を小さくする理由は、擬似輪郭が縞模様を呈するため、縞模様の部分で、高周波数成分が増加しているためである。したがって、擬似輪郭を抑制するためには、高周波成分の量子化誤差を小さくすることが効果的である場合が多い。 As described above, the reason for reducing the value of the quantization matrix corresponding to the spatial high-frequency component is that the high-frequency component is increased in the striped pattern because the pseudo contour exhibits a striped pattern. Therefore, in order to suppress the pseudo contour, it is often effective to reduce the quantization error of the high frequency component.
或いは、量子化マトリクス修正部160は、量子化マトリクスの値の各々を個別に修正し、新たな値を有する量子化マトリクスを生成する。
Alternatively, the quantization
次に、圧縮率判定部117が、低圧縮であると判定した場合を説明する。この場合には、符号化効率を高める処理を行うことができる。量子化マトリクス修正部160は、被写界深度判定部114で、被写界深度外であると判定された直交変換ブロックに対する量子化マトリクスの値を、より大きな値にして修正する。この理由は、被写界深度外の領域は、注視領域でない場合が多いため、この領域における圧縮率を高めても、画像の劣化が認識されにくいことが経験側として存在するからである。量子化マトリクス修正部160は、被写界深度判定部114で、被写界深度外であると判定された直交変換ブロックに対する量子化マトリクスの値を、例えば2倍の値に修正してもよい。なお、実施例1は、2倍に限定されるものではない。
Next, a case where the compression
或いは、上記の場合には、量子化マトリクス修正部160は、Qp値に、例えば6を加算してもよい。上述のように、Qp値に6を加算すると、量子化マトリクスの値の各々は、2倍される。或いは、量子化マトリクス修正部160は、量子化マトリクスの値の各々を個別に修正し、新たな値を有する修正された量子化マトリクス186を生成してもよい。
Alternatively, in the above case, the quantization
以上のようにして、量子化マトリクス修正部160によって修正された量子化マトリクスの情報は、エントロピー符号化を経て復号側に伝送される(186)。また、併せて、被写界深度内/外の情報も復号側に伝送されてもよい。
The quantization matrix information modified by the quantization
なお、上述の説明において、Qp値を修正した場合には、修正されたQp値を復号側に伝送すればよい。例えば、H.264/AVCの規格では、規格上Qp値を復号側に送ることになっている。このため、修正されたQp値が復号側に送られれば、復号側は、量子化マトリクスの修正に係る追加的な復号化の機能を新たに設ける必要はない。 In the above description, when the Qp value is corrected, the corrected Qp value may be transmitted to the decoding side. For example, H.M. In the H.264 / AVC standard, the Qp value is to be sent to the decoding side according to the standard. For this reason, if the corrected Qp value is sent to the decoding side, the decoding side does not need to newly provide an additional decoding function related to the correction of the quantization matrix.
<動作>
次に、実施例1における画像処理装置10の動作について説明する。図4は、画像処理装置10の処理の一例を示す図である。図4に示すステップS410で、空間周波数取得部115は、ブロック直交変換後情報172を取得する。なお、上述のように、空間周波数取得部115は、原画像のフレーム(画像)に対して、直交変換が行われるブロック(直交変換ブロック)領域毎に、空間周波数解析を独自に行ってもよい。
<Operation>
Next, the operation of the
ステップS420で、被写界深度判定部114は、画像のブロック毎の被写界深度の内/外判定を行う。判定では、例えば画素毎、又は所定の領域毎に取得された256段階の奥行き情報をK-means法などによりクラスタ化を行ってもよい。クラスタ数nとしては、例えば、n=2とする。動作の詳細については、図5で述べる。ブロック毎の被写界深度の情報は、ブロック分割情報保存部111のブロック分割の情報に対応付けて、被写界深度保存部118に保存される。
In step S420, the depth-of-field determination unit 114 performs inner / outer determination of the depth of field for each block of the image. In the determination, for example, 256-step depth information acquired for each pixel or for each predetermined region may be clustered by the K-means method or the like. As the number of clusters n, for example, n = 2. Details of the operation will be described with reference to FIG. The information on the depth of field for each block is stored in the depth of
ステップS430で、圧縮率判定部117は、画像全体の圧縮率の高低を判定する。圧縮率判定部117は、例えば、フレームの圧縮率を、上述のように予測誤差信号情報量積算部112の情報と、量子化後情報量積算部116の情報との比を計算することによって求めることができる。
In step S430, the compression
ステップS440で、量子化マトリクス修正部160は、符号化のために一旦作成された量子化マトリクス又はQp値174を修正し、修正された量子化マトリクス又はQp値186を得る。この動作の詳細については、図6を用いて説明する。
In step S440, the quantization
図5は、実施例1における被写界深度の判定の例を示すフローチャートである。 FIG. 5 is a flowchart illustrating an example of determination of the depth of field in the first embodiment.
ステップS510で、1フレーム分の奥行き情報170に基づいて、奥行き情報クラスタリング部113は、各ブロックをクラスタ化する。クラスタ化の一例を以下に示す。
In step S510, based on the
まず、奥行き情報クラスタリング部113は、奥行き情報のヒストグラムを求め、このヒストグラムが取る値の範囲をクラスタ数n(例えばn=2)に等分割し、奥行き情報を分類する。
First, the depth
奥行き情報クラスタリング部113は、各画素位置又は各所定領域の奥行き情報のクラスタリング結果として、奥行き降順に番号(クラスタ番号=1、0)を付与して、このクラスタリング結果を得る。
The depth
奥行き情報クラスタリング部113は、ブロック毎に、クラスタリング情報の代表値を取得する。例えば、奥行き情報クラスタリング部113は、ブロック毎にクラスタリング情報を平均化し、端数を四捨五入する整数化を行うことで、ブロック毎に1つの奥行き情報(クラスタ番号の代表値=1又は0)を取得する。例えば、上述の整数化を行った値が1であれば、クラスタ番号の代表値=1とする。また、整数化を行った値が0であれば、クラスタ番号の代表値=0とすればよい。なお、奥行き情報クラスタリング部113は、ブロック毎に、クラスタリング情報の中央値や最頻値をクラスタ番号の代表値としてもよい。
The depth
ステップS520で、被写界深度判定部114は、奥行き情報クラスタリング部113からの情報を用いて、同じクラスタに属するブロック毎に空間高周波数のパワーの割合を算出する。ブロックにおける空間高周波数のパワーの割合の計算の例については、図3を用いて既に説明したので、説明は省略する。
In step S520, the depth-of-field determination unit 114 uses the information from the depth
ステップS530で、被写界深度判定部114は、空間高周波数のパワーの割合が最も高いクラスタを特定する。この特定されたクラスタに属する複数のブロックが被写界深度内に存在する可能性の高いブロックであると推定できる。 In step S530, the depth-of-field determining unit 114 identifies the cluster having the highest spatial high frequency power ratio. It can be estimated that a plurality of blocks belonging to the specified cluster are highly likely to exist within the depth of field.
ステップS540で、被写界深度判定部114は、特定されたクラスタに属するブロックの情報を、被写界深度保存部118に送る。被写界深度保存部118に保存された情報は、2パス目において、量子化マトリクス修正部160において用いられる。
In step S <b> 540, the depth of field determination unit 114 sends information on the blocks belonging to the identified cluster to the depth of
図6は、量子化マトリクス修正部160が、量子化マトリクスの値を修正する例を示したフローチャートである。
FIG. 6 is a flowchart illustrating an example in which the quantization
ステップS610で、量子化マトリクス修正部160は、圧縮率判定部117からの圧縮率の情報(高圧縮率であるか低圧縮率であるかの情報)を基に、処理の分岐のための判定を行う。判定結果が「はい」であれば、高圧縮であるためステップS620に進む。判定結果が「いいえ」であれば、ステップS611に進む。
In step S <b> 610, the quantization
ステップS611で、量子化マトリクス修正部160は、圧縮率判定部117からの圧縮率の情報(高圧縮率であるか低圧縮率であるかの情報)を基に、処理の分岐のための判定を行う。判定結果が「はい」であれば低圧縮であるためステップS640に進む。判定結果が「いいえ」であれば、高圧縮でも低圧縮でもないため、終了する。
In step S611, the quantization
ステップS620で、量子化マトリクス修正部160は、被写界深度内に属するブロックのうち、空間低周波数のパワーの割合が、例えば所定の閾値より高いブロックを特定する。一般に、被写界深度内のブロックは、鮮明度が高いため、空間低周波数のパワーよりも空間高周波数のパワーの割合が高い場合が多い。しかしながら、オブジェクトのテクスチャ自体が空間低周波数を持つような場合には、被写界深度内においても、空間低周波数のパワーの割合が高いブロックが存在する場合がある。このようなブロックでは、上述のように擬似輪郭が発生する確率が高い。しかも被写界深度内にそのブロックが存在するために、この擬似輪郭が目立ちやすいと判断される。このようなブロックは、例えば、ブロック内における第1の閾値以下の空間周波数のパワーを第1の閾値を超える空間周波数のパワーで除した値が、第2の閾値を越えるブロックを見出せばよい。なお、第1の閾値、及び第2の閾値は、本実施例を実装する際に、当業者が適宜設定することができる。
In step S620, the quantization
したがって、量子化マトリクス修正部160は、このようなブロックに対して、擬似輪郭の発生を抑制するために、量子化マトリクスの値を、より小さくすることが望ましい。このため、量子化マトリクス修正部160は、このようなブロックを特定する。
Therefore, it is desirable that the quantization
ステップS630で、量子化マトリクス修正部160は、特定されたブロックの量子化ステップを、より小さい値に設定する。量子化マトリクスの値の設定の例については、既に量子化マトリクス修正部160の説明の部分で詳述したので、ここでは省略する。
In step S630, the quantization
ステップS640で、量子化マトリクス修正部160は、被写界深度外のブロックを特定する。被写界深度外のブロックは、経験則上、目に止まりにくいと判断される。したがって、被写界深度外のブロックの圧縮率を上げても、画像の劣化は目立ちにくいと予測される。このような理由から、量子化マトリクス修正部160は、被写界深度外のブロックの圧縮率を上げるように、被写界深度外のブロックに対応する量子化マトリクスの値を、より大きくする。量子化マトリクスの値の設定の例については、既に量子化マトリクス修正部160の説明の部分で詳述したので、ここでは省略する。
In step S640, the quantization
以上、実施例1では、奥行き情報から、被写界深度に関する情報を取得することができる。加えて、この被写界深度の情報を用いて、画質の向上、又は圧縮率の増加を図ることができる。より詳細には、高圧縮時においては、被写界深度内に発生し得る擬似輪郭の発生を充分に抑制することができる。また、低圧縮時においては、被写界深度外の領域の量子化ステップを増加させることで、画像の劣化がなるべく目立たないように、圧縮率を上げることができる。 As described above, in the first embodiment, information on the depth of field can be acquired from the depth information. In addition, it is possible to improve the image quality or increase the compression rate using the information on the depth of field. More specifically, during high compression, it is possible to sufficiently suppress the occurrence of pseudo contours that can occur within the depth of field. Further, at the time of low compression, the compression rate can be increased by increasing the quantization step in the region outside the depth of field so that the deterioration of the image is not as conspicuous as possible.
[実施例2]
実施例2では、実施例1における画像処理装置10を画像処理部(1)11に含む画像処理装置(画像符号化装置)について説明する。
[Example 2]
In the second embodiment, an image processing apparatus (image encoding apparatus) including the
<構成>
図7は、実施例2における画像処理装置20の概略構成の一例を示すブロック図である。図7に示す例では、画像処理装置20は、前処理部200と、予測誤差信号生成部201と、直交変換部202と、量子化部203と、エントロピー符号化部204と、逆量子化部205と、逆直交変換部206と、復号画像生成部207と、ループフィルタ部209と、復号画像記憶部210と、イントラ予測部211と、インター予測部212と、動きベクトル計算部213と、予測画像選択部215と、画像処理部(1)11とを有する。各部についての概略を以下に説明する。
<Configuration>
FIG. 7 is a block diagram illustrating an example of a schematic configuration of the
前処理部200は、ピクチャタイプに合わせてピクチャを並べ替え、ピクチャタイプ及びフレーム毎のフレーム画像等を順次出力する。また、前処理部200は、ブロック分割なども行い、ブロック分割の境界情報を、画像処理部(1)11、及びループフィルタ部209に出力する。前処理部200は、画像処理部(1)11から、1パス・2パス切替指示162を取得する。また、前処理部200は、画像処理部(1)11との間で、ブロック分割情報を、信号線164を介して交換する。前処理部200は、1パス目で、ブロック分割情報を画像処理部(1)11に与える。そして、前処理部200は、2パス目で、ブロック分割情報を画像処理部(1)11から取得する。このようにすることによって、前処理部200は、1パス目のブロック分割と同じブロック分割を、2パス目で用いることができる。
The
予測誤差信号生成部201は、入力された原画像データの符号化対象画像が、例えば32×32、16×16、8×8画素などのブロックに分割されたブロックデータを取得する。
The prediction error
予測誤差信号生成部201は、そのブロックデータと、予測画像選択部215から出力される予測画像のブロックデータとにより、予測誤差信号を生成する。予測誤差信号生成部201は、生成された予測誤差信号を、画像処理部(1)11、及び直交変換部202に出力する。
The prediction error
直交変換部202は、入力された予測誤差信号を直交変換処理する。直交変換部202は、変換された係数値を示す信号を、画像処理部(1)11、及び量子化部203に出力する。
The
量子化部203は、直交変換部202からの出力信号を量子化する。量子化部203は、量子化することによって出力信号の符号量を低減し、この出力信号を画像処理部(1)11、エントロピー符号化部204、及び逆量子化部205に出力する。
The
画像処理部(1)11は、実施例1で説明した画像処理装置10を含み得る。なお、画像処理部(1)11は、量子化部203から信号線174により量子化パラメータ等を受け取る。そして、画像処理部(1)11によって修正された量子化パラメータの情報が、信号線186によって、量子化部203に返される。量子化部203は、この修正された量子化パラメータを使用して、量子化を実行する。なお、画像処理部(1)11は、量子化パラメータの代わりに、量子化マトリクス自体を修正して、量子化部203に与えてもよい。画像処理部(1)11には、信号線170を介して、前処理部200から奥行き情報が入力されている。なお、前処理部200は、上述のように原画像を画像処理部(1)11に提供してもよい。原画像は、図2示す空間周波数取得部115で利用され得る。また、奥行き情報は、図2示す奥行き情報クラスタリング部113で利用される。また、画像処理部(1)11には、直交変換部202から信号線710を介して、直交変換係数が入力される。この直交変換係数は、図2に示す空間周波数取得部115が利用する。
The image processing unit (1) 11 can include the
エントロピー符号化部204は、画像処理部(1)11から2パス目動作指示信号184を受け取ることにより、2パス目であることを認識し動作する。エントロピー符号化部204は、量子化部203からの出力信号や、動きベクトル計算部213から出力された動きベクトル情報やループフィルタ部209からのフィルタ係数などをエントロピー符号化して出力する。
The
また、エントロピー符号化部204は、イントラ予測部211から取得したイントラ予測方向の差分値や、インター予測部212から取得した動きベクトルと予測ベクトルの差分値などをエントロピー符号化する。
Also, the
また、エントロピー符号化部204は、画像処理部(1)11で修正された量子化マトリクスの情報を符号化する。エントロピー符号化とは、シンボルの出現頻度に応じて可変長の符号を割り当てる方式をいう。
The
逆量子化部205は、量子化部203からの出力信号を逆量子化してから逆直交変換部206に出力する。逆直交変換部206は、逆量子化部205からの出力信号を逆直交変換処理してから復号画像生成部207に出力する。これら逆量子化部205及び逆直交変換部206によって復号処理が行われることにより、符号化前の予測誤差信号と同程度の信号が得られる。
The
復号画像生成部207は、イントラ予測部211で画面内予測された画像或いはインター予測部212で動き補償された画像のブロックデータと、逆量子化部205及び逆直交変換部206により復号処理された予測誤差信号とを加算する。復号画像生成部207は、加算して生成した復号画像のブロックデータを、ループフィルタ部209に出力する。
The decoded
ループフィルタ部209は、例えばALF(Adaptive Loop Filter)やデブロッキングフィルタである。ループフィルタ部209は、フィルタ処理結果を復号画像記憶部210に出力し、蓄積された1画像分のフィルタ処理結果を参照画像として記憶させる。
The
復号画像記憶部210は、入力した復号画像のブロックデータを新たな参照画像のデータとして記憶し、イントラ予測部211、インター予測部212及び動きベクトル計算部213に出力する。
The decoded
イントラ予測部211は、符号化対象画像の処理対象ブロックに対して、既に符号化された参照画素から予測画像のブロックデータを生成する。イントラ予測部211は、複数の予測方向を用いて予測を行い、最適な予測方向を決定する。予測方向については、符号化済みブロックの予測方向との差分値をビットストリームに含めるために、差分値がエントロピー符号化部204に出力される。
The
インター予測部212は、復号画像記憶部210から取得した参照画像のデータを動きベクトル計算部213から提供される動きベクトルで動き補償する。これにより、動き補償された参照画像としてのブロックデータが生成される。動きベクトルについては、符号化済みブロックの動きベクトル(予測ベクトル)との差分値をビットストリームに含めるために、差分値がエントロピー符号化部204に出力される。
The
動きベクトル計算部213は、符号化対象画像におけるブロックデータと、復号画像記憶部210から取得する参照画像とを用いて、動きベクトルを求める。
The motion vector calculation unit 213 obtains a motion vector using the block data in the encoding target image and the reference image acquired from the decoded
動きベクトル計算部213は、求めた動きベクトルをインター予測部212に出力し、参照画像を示す情報を含む動きベクトル情報をエントロピー符号化部204に出力する。
The motion vector calculation unit 213 outputs the obtained motion vector to the
イントラ予測部211とインター予測部212から出力されたブロックデータは、予測画像選択部215に入力される。
The block data output from the
予測画像選択部215は、イントラ予測部211とインター予測部212から取得したブロックデータのうち、どちらか一方のブロックデータを予測画像として選択する。選択された予測画像は、予測誤差信号生成部201に出力される。
The predicted
なお、図7に示す画像処理装置20の構成は一例であり、必要に応じて各構成を組み合わせたり、各構成を適宜変更したりしてもよい。
The configuration of the
以上、実施例2によれば、画像符号化時に、奥行き情報を得て、得られた奥行き情報に基づいて、高圧縮時には擬似輪郭の抑制又は、低圧縮時には圧縮率の向上を図ることができる。 As described above, according to the second embodiment, depth information is obtained at the time of image coding, and based on the obtained depth information, pseudo contour can be suppressed at the time of high compression or the compression rate can be improved at the time of low compression. .
[実施例3]
実施例3における画像処理装置(画像復号装置)は、実施例2における画像処理装置20で符号化されたビットストリームを復号する装置である。
[Example 3]
The image processing device (image decoding device) according to the third embodiment is a device that decodes the bitstream encoded by the
<構成>
図8は、実施例3における画像処理装置30の概略構成の一例を示すブロック図である。図8に示すように、画像処理装置30は、エントロピー復号部301と、逆量子化部302と、逆直交変換部303と、イントラ予測部304と、復号情報記憶部305と、インター予測部306と、予測画像選択部307と、復号画像生成部308と、ループフィルタ部310と、フレームメモリ311とを有する。各部についての概略を以下に説明する。
<Configuration>
FIG. 8 is a block diagram illustrating an example of a schematic configuration of the
エントロピー復号部301は、ビットストリームが入力されると、画像処理装置20のエントロピー符号化に対応するエントロピー復号を行う。エントロピー復号部301により復号された予測誤差信号などは逆量子化部302に出力される。また、実施例1又は2において利用された量子化マトリクスの修正に関する情報、及びインター予測されている場合の、復号された動きベクトルの差分値などは復号情報記憶部305に出力される。
When a bit stream is input, the
また、エントロピー復号部301は、イントラ予測の場合、イントラ予測部304にその旨通知する。また、エントロピー復号部301は、復号対象画像がインター予測されているか、イントラ予測されているかを予測画像選択部307に通知する。
In the case of intra prediction, the
逆量子化部302は、エントロピー復号部301からの出力信号に対して、必要に応じて実施例1又は2において利用された量子化マトリクスの修正に関する情報を考慮して、逆量子化処理を行う。逆量子化された出力信号は逆直交変換部303に出力される。
The
逆直交変換部303は、逆量子化部302からの出力信号の復号ブロックに対して逆直交変換処理を行い、残差信号を生成する。残差信号は復号画像生成部308に出力される。
The inverse
イントラ予測部304は、フレームメモリ311から取得する復号対象画像の既に復号化された周辺画素から、複数の予測方向を用いて予測画像を生成する。
The
復号情報記憶部305は、分割モードなどの復号情報を記憶する。
The decoding
インター予測部306は、フレームメモリ311から取得した参照画像のデータを復号情報記憶部305から動きベクトルの差分値などを取得する。インター予測部306は、予測ベクトルを決定し、決定した予測ベクトルと、動きベクトルの差分値とを加算し、動きベクトルを生成する。インター予測部306は、生成した動きベクトルを用いて動き補償を行う。これにより、動き補償された参照画像としてのブロックデータが生成される。
The
予測画像選択部307は、イントラ予測画像、又はインター予測画像のどちらか一方の予測画像を選択する。選択されたブロックデータは、復号画像生成部308に出力される。
The predicted
復号画像生成部308は、予測画像選択部307から出力される予測画像と、逆直交変換部303から出力される残差信号とを加算し、復号画像を生成する。生成された復号画像はループフィルタ部310に出力される。
The decoded
ループフィルタ部310は、復号画像生成部308から出力された復号画像に対し、ブロック歪を低減するためのフィルタをかけ、ループフィルタ処理後の復号画像をフレームメモリ311に出力する。
The
なお、ループフィルタ後の復号画像は表示装置などに出力される。 Note that the decoded image after the loop filter is output to a display device or the like.
フレームメモリ311は、参照画像となる復号画像などを記憶する。なお、復号情報記憶部305とフレームメモリ311は、分けた構成にしているが、同じ記憶部であってもよい。
The
以上、実施例3によれば、実施例2の符号時に使用された量子化マトリクスに係る修正の情報を用いて、画像処理装置20で符号化されたビットストリームを、適切に復号することができる。
As described above, according to the third embodiment, it is possible to appropriately decode the bitstream encoded by the
[実施例4]
図9は、実施例4における画像処理装置40の概略構成の一例を示すブロック図である。図9に示す画像処理装置40は、上述した実施例1〜3で説明した画像処理をソフトウェアで実装した装置の一例である。
[Example 4]
FIG. 9 is a block diagram illustrating an example of a schematic configuration of the
図9に示すように、画像処理装置40は、制御部401と、主記憶部402と、補助記憶部403と、ドライブ装置404と、ネットワークI/F部406と、入力部407と、表示部408とを有する。これら各構成は、バスを介して相互にデータ送受信可能に接続されている。
As shown in FIG. 9, the
制御部401は、コンピュータの中で、各装置の制御やデータの演算、加工を行うCPU(Central Processing Unit)である。また、制御部401は、主記憶部402又は補助記憶部403に記憶された画像処理のプログラムを実行する演算装置である。制御部401は、入力部407や記憶装置からデータを受け取り、演算、加工した上で、表示部408や記憶装置などに出力する。
The
また、制御部401は、画像処理のプログラムを実行することで、実施例1〜4で説明した処理を実現することができる。
Also, the
主記憶部402は、ROM(Read Only Memory)やRAM(Random Access Memory)などである。主記憶部402は、制御部401が実行する基本ソフトウェアであるOS(Operating System)やアプリケーションソフトウェアなどのプログラムやデータを記憶又は一時保存する記憶装置である。
The
補助記憶部403は、HDD(Hard Disk Drive)などであり、アプリケーションソフトウェアなどに関連するデータを記憶する記憶装置である。
The
ドライブ装置404は、記録媒体405、例えばフレキシブルディスクからプログラムを読み出し、記憶部にインストールする。
The
また、記録媒体405に、所定のプログラムを格納し、この記録媒体405に格納されたプログラムはドライブ装置404を介して画像処理装置40にインストールされる。インストールされた所定のプログラムは、画像処理装置40により実行可能となる。
A predetermined program is stored in the
ネットワークI/F部406は、有線及び/又は無線回線などのデータ伝送路により構築されたLAN(Local Area Network)、WAN(Wide Area Network)などのネットワークを介して接続された通信機能を有する周辺機器と画像処理装置40とのインターフェースである。
The network I /
入力部407は、カーソルキー、数字入力及び各種機能キー等を備えたキーボード、表示部408の表示画面上でキーの選択等を行うためのマウスやスライドパット等を有する。表示部408は、LCD(Liquid Crystal Display)等により構成され、制御部401から入力される表示データに応じた表示が行われる。
The
なお、図2の画像処理装置10、図7の画像処理装置20、及び図8の画像処理装置30の各部は、例えば制御部401及びワークメモリとしての主記憶部402により実現されうる。
The units of the
また、図7に示す復号画像記憶部210は、例えば主記憶部402又は補助記憶部403により実現され、図7に示す復号画像記憶部210以外の構成は、例えば制御部401及びワークメモリとしての主記憶部402により実現されうる。
Further, the decoded
また、図8に示す復号情報記憶部305及びフレームメモリ311は、例えば主記憶部402又は補助記憶部403により実現されうる。図8に示す復号情報記憶部305及びフレームメモリ311以外の構成は、例えば制御部401及びワークメモリとしての主記憶部402により実現されうる。
Further, the decoded
画像処理装置40で実行されるプログラムは、実施例1〜3で説明した各部を含むモジュール構成となっている。実際のハードウェアとしては、制御部401が補助記憶部403からプログラムを読み出して実行することにより上記各部のうち1又は複数の各部が主記憶部402上にロードされ、1又は複数の各部が主記憶部402上に生成されるようになっている。
The program executed by the
このように、上述した実施例1〜3で説明した画像処理は、コンピュータに実行させるためのプログラムとして実現することができる。このプログラムをサーバ等からインストールしてコンピュータに実行させることで、実施例1〜3で説明した処理を実現することができる。 As described above, the image processing described in the first to third embodiments can be realized as a program for causing a computer to execute the image processing. The processing described in the first to third embodiments can be realized by installing this program from a server or the like and causing the computer to execute the program.
また、このプログラムを記録媒体405に記録し、このプログラムが記録された記録媒体405をコンピュータや携帯端末などの処理装置に読み取らせて、前述した画像処理を実現させることも可能である。
It is also possible to record the program in the
なお、記録媒体405は、CD−ROM、フレキシブルディスク、光磁気ディスク等のように情報を光学的,電気的或いは磁気的に記録する記録媒体、ROM、フラッシュメモリ等のように情報を電気的に記録する半導体メモリ等、様々なタイプの記録媒体を用いることができる。
Note that the
また、上述した各実施例で説明した画像処理は、1つ又は複数の集積回路に実装され得る。なお、実施例4における画像処理装置40は、上記の通り、画像処理装置10、20、30の少なくとも1つの装置としての機能を有する。
In addition, the image processing described in each embodiment described above can be implemented in one or a plurality of integrated circuits. Note that the
また、上述した各実施例における画像処理装置は、奥行き情報を用いて被写界深度情報を出力し、または量子化マトリクスを修正する符号化技術に対して適用可能であり、H.264/AVCやH.265/HEVCだけに限られるものではない。 Further, the image processing apparatus in each of the embodiments described above can be applied to an encoding technique that outputs depth-of-field information using depth information or modifies a quantization matrix. H.264 / AVC and H.264 It is not limited to 265 / HEVC.
以上、各実施例について詳述したが、特定の実施例に限定されるものではなく、特許請求の範囲に記載された範囲内において、上記変形例以外にも種々の変形及び変更が可能である。 Each embodiment has been described in detail above. However, the present invention is not limited to the specific embodiment, and various modifications and changes other than the above-described modification are possible within the scope described in the claims. .
10、20、30、40 画像処理装置
11 画像処理部(1)
111 ブロック分割情報保存部
112 予測誤差信号情報量積算部
113 奥行き情報クラスタリング部
114 被写界深度判定部
115 空間周波数取得部
116 量子化後情報量積算部
117 圧縮率判定部
118 被写界深度保存部
130 1パス・2パス切替指示部
160 量子化マトリクス修正部
10, 20, 30, 40
111 Block division
Claims (6)
前記画像に含まれる複数のブロックの各々の空間周波数のパワーを取得する空間周波数取得部と、
前記画像における各画素位置又は各所定領域の奥行きの情報をクラスタリングし、当該クラスタリングの結果に基づいて、前記複数のブロックの各々のクラスタを決定する奥行き情報クラスタリング部と、
所定のクラスタに属する1つ以上のブロックの空間周波数のパワーと、前記所定のクラスタ以外に属する複数のブロックの空間周波数のパワーとに基づいて、前記所定のクラスタに属する前記1つ以上のブロックを被写界深度内に属すると判定する、被写界深度判定部と、
前記被写界深度判定部の判定結果と、前記画像の圧縮率とに基づいて、前記複数のブロックのうち所定のブロックに対して、直交変換された複数の周波数成分の各々の量子化ステップを含む量子化マトリクスの値を修正する、量子化マトリクス修正部と、
を有する画像処理装置。 An image processing apparatus that adjusts the quantization step of an image using information on the depth of the image,
A spatial frequency acquisition unit that acquires the power of each spatial frequency of the plurality of blocks included in the image;
A depth information clustering unit that clusters information on the depth of each pixel position or each predetermined region in the image, and determines each cluster of the plurality of blocks based on a result of the clustering;
The power of one or more spatial frequencies of the block belonging to a given cluster, based on the power of the spatial frequency of a plurality of blocks belonging to other than the given cluster, the one or more blocks belonging to the given cluster A depth-of-field determination unit that determines to belong to the depth of field;
Based on the determination result of the depth-of-field determination unit and the compression rate of the image, each quantization step of the plurality of frequency components orthogonally transformed with respect to a predetermined block among the plurality of blocks is performed. A quantization matrix correction unit that corrects the value of the quantization matrix including,
An image processing apparatus.
前記被写界深度判定部は、
前記所定のクラスタに属する1つ以上のブロックの空間周波数のうち所定の空間周波数を越える空間周波数のパワーの割合が、前記所定のクラスタ以外に属する複数のブロックの空間周波数のうち前記所定の空間周波数を越える空間周波数のパワーの割合より高い場合、前記所定のクラスタに属する前記1つ以上のブロックを被写界深度内に属すると判定し、
前記量子化マトリクス修正部は、前記圧縮率が、高圧縮率である場合、被写界深度内に属すると判定された前記1つ以上のブロックのうち、空間周波数の低周波成分のパワーの割合が所定の割合より高いブロックに対して、前記量子化マトリクスの所定の領域を、より小さい値に修正する、
請求項1記載の画像処理装置。 A compression rate determination unit that determines a high compression rate when the compression rate of the image is higher than a predetermined first compression rate;
The depth of field determination unit
The ratio of the power of the spatial frequency exceeding a predetermined spatial frequency among the spatial frequencies of one or more blocks belonging to the predetermined cluster is the predetermined spatial frequency among the spatial frequencies of a plurality of blocks belonging to other than the predetermined cluster. Determining that the one or more blocks belonging to the predetermined cluster belong within a depth of field if the power ratio is higher than a spatial frequency power ratio exceeding
The quantization matrix correction unit, when the compression ratio is a high compression ratio, among the one or more blocks determined to belong to the depth of field, the ratio of the power of the low frequency component of the spatial frequency For a block that is higher than a predetermined percentage, the predetermined region of the quantization matrix is modified to a smaller value.
The image processing apparatus according to claim 1.
請求項2記載の画像処理装置。 The quantization matrix correcting unit applies the quantization to a block other than the one or more blocks determined to belong to the depth of field when the compression rate is lower than a predetermined second compression rate. Modify the value of the quantization matrix to a larger value,
The image processing apparatus according to claim 2.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013132070A JP6200220B2 (en) | 2013-06-24 | 2013-06-24 | Image processing apparatus, encoding apparatus, decoding apparatus, and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013132070A JP6200220B2 (en) | 2013-06-24 | 2013-06-24 | Image processing apparatus, encoding apparatus, decoding apparatus, and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2015008367A JP2015008367A (en) | 2015-01-15 |
JP6200220B2 true JP6200220B2 (en) | 2017-09-20 |
Family
ID=52338394
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2013132070A Active JP6200220B2 (en) | 2013-06-24 | 2013-06-24 | Image processing apparatus, encoding apparatus, decoding apparatus, and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6200220B2 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111107377A (en) * | 2018-10-26 | 2020-05-05 | 曜科智能科技(上海)有限公司 | Depth image compression method, device, equipment and storage medium |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH03230691A (en) * | 1990-02-05 | 1991-10-14 | Minolta Camera Co Ltd | Digital electronic still camera |
JPH06284449A (en) * | 1993-03-25 | 1994-10-07 | Kyocera Corp | Band compressing circuit and picture encoder for video signal using parallax |
JP2000209581A (en) * | 1999-01-14 | 2000-07-28 | Hitachi Ltd | Image recording device |
JP4799438B2 (en) * | 2007-02-06 | 2011-10-26 | キヤノン株式会社 | Image recording apparatus, image recording method, image encoding apparatus, and program |
RU2009135396A (en) * | 2007-04-16 | 2011-04-10 | Кабусики Кайся Тосиба (Jp) | METHOD AND DEVICE FOR VIDEO CODING AND DECODING |
JP2011254393A (en) * | 2010-06-03 | 2011-12-15 | Canon Inc | Encoding apparatus, encoding method and program |
-
2013
- 2013-06-24 JP JP2013132070A patent/JP6200220B2/en active Active
Also Published As
Publication number | Publication date |
---|---|
JP2015008367A (en) | 2015-01-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR102469145B1 (en) | Method and device for encoding or decoding image | |
US10382757B2 (en) | Image coding apparatus, image coding method, and program, and image decoding apparatus, image decoding method, and program | |
KR101298389B1 (en) | Method and system for video coder and decoder joint optimization | |
JP4747975B2 (en) | Image processing apparatus and method, program, and recording medium | |
US10291925B2 (en) | Techniques for hardware video encoding | |
KR102393178B1 (en) | Method and apparatus for generating reconstruction block | |
US10887365B2 (en) | System and methods for bit rate control | |
WO2014139396A1 (en) | Video coding method using at least evaluated visual quality and related video coding apparatus | |
US8903184B2 (en) | Image-encoding method, image-encoding device, and computer-readable recording medium storing image-encoding program | |
JP2014082639A (en) | Image encoder and method of the same | |
US20150146776A1 (en) | Video image encoding device, video image encoding method | |
JP2023512898A (en) | Method and apparatus for offset in video filtering | |
US9930352B2 (en) | Reducing noise in an intraframe appearance cycle | |
US8442338B2 (en) | Visually optimized quantization | |
JP6200220B2 (en) | Image processing apparatus, encoding apparatus, decoding apparatus, and program | |
JP2019102861A (en) | Moving image encoding device, moving image encoding method, and moving image encoding program | |
JP5937926B2 (en) | Image encoding device, image decoding device, image encoding program, and image decoding program | |
JP2013138502A (en) | Coding apparatus, control method of the same, and computer program | |
JP5789172B2 (en) | Image processing apparatus and program | |
JP2008177916A (en) | Apparatus and method for image encoding | |
US10034011B2 (en) | Video coding apparatus | |
JP2014143515A (en) | Image processing apparatus and image processing program | |
JP2015076866A (en) | Image encoder, image decoder, and program | |
JP2011166357A (en) | Image encoding device | |
JP2013223149A (en) | Image encoding device, image decoding device, image encoding program, and image decoding program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20160425 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20170227 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20170307 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20170425 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20170523 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20170714 |
|
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: 20170801 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20170825 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 6200220 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |