JP2005184525A - Image processor - Google Patents
Image processor Download PDFInfo
- Publication number
- JP2005184525A JP2005184525A JP2003423156A JP2003423156A JP2005184525A JP 2005184525 A JP2005184525 A JP 2005184525A JP 2003423156 A JP2003423156 A JP 2003423156A JP 2003423156 A JP2003423156 A JP 2003423156A JP 2005184525 A JP2005184525 A JP 2005184525A
- Authority
- JP
- Japan
- Prior art keywords
- pixel
- value
- block
- hadamard
- sub
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Abstract
Description
本発明は、動画像の圧縮及び伸張を行う前段階の画像データ(画像圧縮を効率よく行うためのデータ構成)を作成する画像処理を行う画像処理装置に関するものである。 The present invention relates to an image processing apparatus that performs image processing for creating image data (data structure for efficiently performing image compression) at a previous stage for compressing and expanding a moving image.
動画像 、音声を圧縮 する方式として、非特許文献1に規定されている動画像 、音声圧縮 規格H.262(通称「MPEG2」方式)がある。
上記MPEG2による動画像の圧縮においては、画像をマクロブロックと呼ばれる16画素×16画素の矩形ブロック群に分割し、時間的に前後の画像の中から、圧縮するマクロブロックに対し高い相関を有する領域(以下、参照領域)を抽出し、上記参照領域との空間的な距離、方位(動きベクトル)と、参照領域と圧縮 しようとする領域の差分情報を計算し、これらの情報を、DCT(離散コサイン変換)、可変長符号化を用いてビットストリームに圧縮する。
As a method for compressing moving images and sounds, there is a moving image and sound compression standard H.262 (commonly called “MPEG2” method) defined in Non-Patent
In the moving picture compression by MPEG2, the image is divided into 16 × 16 pixel rectangular block groups called macroblocks, and is a region having a high correlation with the macroblock to be compressed from the temporally preceding and following images. (Hereinafter referred to as a reference region), the spatial distance and orientation (motion vector) from the reference region and the difference information between the reference region and the region to be compressed are calculated, and these information are converted into DCT (discrete). Cosine transform) and variable length coding to compress the bit stream.
上述したような動きベクトルと差分情報だけを圧縮する手法は、原画像そのものを圧縮する手法よりも、はるかに高能率な圧縮が実現可能である。
つまり、同じ程度の圧縮歪みを許容するならば、より少ない情報量に圧縮することが可能である。
しかし、差分情報によって圧縮された画像は、参照する画像がないと伸長できない。
このため、ビットストリームの途中から伸長するような用途(以下、「ランダムアクセス」と称する。)に対処するためには、他の画像を参照しない画像を周期的に設ける必要がある。
The method of compressing only the motion vector and the difference information as described above can achieve much more efficient compression than the method of compressing the original image itself.
In other words, if the same degree of compression distortion is allowed, the information can be compressed to a smaller amount of information.
However, an image compressed with the difference information cannot be expanded without an image to be referenced.
For this reason, in order to cope with an application that extends from the middle of the bitstream (hereinafter referred to as “random access”), it is necessary to periodically provide images that do not refer to other images.
この画像を「I画像」(Intra Picture)と称し、このI画像を参照画像として、次のB及びP画像を圧縮していく。
参照画像を用いて圧縮する画像の中には、時間的に前の画像のみを参照画像とする「P画像 (Predictive-coded Picture)」と、時間的に前後の画像を参照画像とする「B画像 (Bidirectionally predictive-coded Picture)」がある。P画像は、I画像と同様に、他の画像、すなわち「B画像」の参照画像となりうる。
Among the images to be compressed using the reference image, a “P image (Predictive-coded Picture)” in which only a temporally previous image is used as a reference image, and a “B image” in which temporally preceding and succeeding images are used as reference images. There is “Image (Bidirectionally predictive-coded Picture)”. Similarly to the I image, the P image can be a reference image of another image, that is, a “B image”.
しかしながら、上述したMPEG2は、画像圧縮が16画素×16画素の矩形ブロック単位で独立して行われる。
すなわち、I画像であれば矩形ブロック単位で独立して画像圧縮を行うため、圧縮効率の向上には、限界がある。
また、B及びP画像も参照画像との差分データを利用し、動き補償を行いデータ量を低下させているが、参照画像が使用できない矩形ブロックは、I画像の矩形ブロックと同様に矩形ブロック単位で独立して画像圧縮を行うため、圧縮効率の向上には、限界がある。
However, in MPEG2 described above, image compression is performed independently in units of 16 × 16 pixel rectangular blocks.
That is, since the image compression is performed independently for each rectangular block in the case of an I image, there is a limit to improving the compression efficiency.
In addition, the B and P images also use difference data from the reference image and perform motion compensation to reduce the data amount. However, the rectangular block in which the reference image cannot be used is a rectangular block unit like the rectangular block of the I image. Therefore, there is a limit to improving the compression efficiency.
本発明の目的は、このような背景の下になされたもので、圧縮した画像データの容量を低下させ、かつ、MPEGと同等以上の伸張後の画像品質を得る圧縮・伸張処理を行うことが可能な動画像の符号化及び復号機能を有する画像処理装置を提供する事にある。 An object of the present invention is made under such a background, and is to perform compression / decompression processing for reducing the capacity of compressed image data and obtaining image quality after decompression equivalent to or higher than that of MPEG. An object of the present invention is to provide an image processing apparatus having a function of encoding and decoding a possible moving image.
本願発明の画像処理装置は、Iピクチャ,Pピクチャ及びBピクチャを用いた動画像の符号化を行う画像処理装置において、入力される原画像がIピクチャであるとき、この原画像を4×4画素単位の画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接する画素ブロックとの間において交流成分予測を行い、各画素ブロックを4分割した2×2画素のサブ画素ブロック毎に、第1のDC画素値を求め、この第1のDC画素値と、対応する位置の原画像のサブ画素ブロックとの差分を第1の差分値として求め、この第1の差分値を第1のアダマール係数として符号化し、前記DC値と第1のアダマール係数とを符号化データとして出力する第1の交流予測符号化部と、前記画素ブロックを2×2画素単位のサブ画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接するサブ画素ブロック間において交流成分予測を行い、各サブ画素ブロックにおける各画素毎に、第2のDC画素値を求め、この第2のDC画素値と、対応する位置の原画像のサブ画素ブロックにおける画素との差分を第2の差分値として求め、この第2の差分値を第2のアダマール係数として符号化し、第2のアダマール係数を符号化データとして出力する第2の交流予測符号化部と、入力される原画像がBまたはPピクチャであるとき、この原画像を分割して、8×8画素のマクロブロック単位とし、所定の他ピクチャから最も高い相関を有する参照ブロックを抽出し、この参照ブロックを用いた、このマクロブロックの動き補償の符号化データが所定のデータ容量範囲であるかの判定を行う動き推定部と、マクロブロックの動き補償の符号化データが前記所定の範囲内である場合、このマクロブロックに対して、動き補償に基づくインター符号化を行うインター符号化部と、マクロブロックの動き補償の符号化データが前記所定の範囲内でない場合、このマクロブロックに対してイントラ符号化を行うイントラ符号化部とを有することを特徴とする。 The image processing apparatus according to the present invention is an image processing apparatus that encodes a moving image using an I picture, a P picture, and a B picture. When an input original image is an I picture, the original image is converted to 4 × 4. A 2 × 2 pixel sub-pixel block obtained by dividing the pixel block into pixel blocks, obtaining a DC value that is an average value of pixel values, performing AC component prediction between adjacent pixel blocks, and dividing each pixel block into four Each time, a first DC pixel value is obtained, and a difference between the first DC pixel value and a sub-pixel block of the original image at the corresponding position is obtained as a first difference value, and the first difference value is obtained. A first AC prediction encoding unit that encodes the first Hadamard coefficient and outputs the DC value and the first Hadamard coefficient as encoded data; and the pixel block is converted into a sub-pixel block in units of 2 × 2 pixels. Split Then, a DC value that is an average value of pixel values is obtained, AC component prediction is performed between adjacent sub-pixel blocks, a second DC pixel value is obtained for each pixel in each sub-pixel block, and the second DC The difference between the pixel value and the pixel in the sub-pixel block of the original image at the corresponding position is obtained as a second difference value, the second difference value is encoded as a second Hadamard coefficient, and the second Hadamard coefficient is When the input AC is a B or P picture, and the second AC predictive encoding unit that is output as encoded data, the original image is divided into macro block units of 8 × 8 pixels, A reference block having the highest correlation is extracted from another picture, and it is determined whether the encoded data for motion compensation of the macroblock using this reference block is within a predetermined data capacity range. A motion estimator, an inter coding unit that performs inter coding based on motion compensation for the macroblock when the coded data for motion compensation of the macroblock is within the predetermined range, and motion of the macroblock And an intra encoding unit that performs intra encoding on the macroblock when the compensation encoded data is not within the predetermined range.
本願発明の画像処理装置は、前記インター符号化部が、動き予測により抽出した8×8画素の参照画像(参照ブロック)と、符号化対象のマクロブロックとの差分値を求め、この差分値による差分ブロックを4×4の画素ブロック(残差ブロック)単位に分割し、各画素ブロック毎に、前記差分値を平均化してDC値を求めて、このDC値と差分ブロックの差分値との差をアダマール係数として符号化し、前記DC値とアダマール係数とを符号化データとして出力することを特徴とする。 In the image processing apparatus of the present invention, the inter coding unit obtains a difference value between an 8 × 8 pixel reference image (reference block) extracted by motion prediction and a macroblock to be coded, and uses the difference value. The difference block is divided into 4 × 4 pixel blocks (residual blocks), the difference value is averaged for each pixel block to obtain a DC value, and the difference between the DC value and the difference value of the difference block is calculated. Are encoded as Hadamard coefficients, and the DC value and Hadamard coefficients are output as encoded data.
本願発明の画像処理装置は、前記イントラ符号化部が、符号化対象のマクロブロックを4×4画素単位の画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接する画素ブロックとの間において交流成分予測を行い、各画素ブロックを4分割した2×2画素のサブ画素ブロック毎に、第1のDC画素値を求め、この第1のDC画素値と、マクロブロックにおいて、対応する位置のサブ画素ブロックとの差分を第1の差分値として求め、この第1の差分値を第1のアダマール係数として符号化し、前記DC値と第1のアダマール係数とを符号化データとして出力する第3の交流予測符号化部と、前記画素ブロックを2×2画素単位のサブ画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接するサブ画素ブロック間において交流成分予測を行い、各サブ画素ブロックにおける各画素毎に、第2のDC画素値を求め、この第2のDC画素値と、対応する位置の原画像のサブ画素ブロックにおける画素との差分を第2の差分値として求め、この第2の差分値を第2のアダマール係数として符号化し、第2のアダマール係数を符号化データとして出力する第4の交流予測符号化部とを有することを特徴とする。 In the image processing apparatus of the present invention, the intra encoding unit divides a macroblock to be encoded into pixel blocks of 4 × 4 pixel units, obtains a DC value that is an average value of pixel values, and sets adjacent pixel blocks The first DC pixel value is obtained for each 2 × 2 pixel sub-pixel block obtained by dividing each pixel block into four, and the first DC pixel value and the macro block are The difference from the sub-pixel block at the corresponding position is obtained as a first difference value, the first difference value is encoded as a first Hadamard coefficient, and the DC value and the first Hadamard coefficient are used as encoded data. A third AC predictive encoding unit for output and the pixel block are divided into sub-pixel blocks in units of 2 × 2 pixels, and a DC value that is an average value of the pixel values is obtained and placed between adjacent sub-pixel blocks. AC component prediction is performed to obtain a second DC pixel value for each pixel in each sub-pixel block, and a difference between the second DC pixel value and a pixel in the sub-pixel block of the original image at the corresponding position is calculated. And a fourth AC predictive encoding unit that obtains the second difference value, encodes the second difference value as a second Hadamard coefficient, and outputs the second Hadamard coefficient as encoded data. And
本願発明の画像処理装置は、交流予測符号化部が、符号化対象のマクロブロックを4×4画素単位の画素ブロックに分割し、また2×2画素のサブ画素ブロックに分割して交流予測符号化を行う際に、隣接した対象画素ブロックがインター符号化された画素ブロックの場合、その復号結果のマクロブロックを用いて交流成分予測を行うことを特徴とする。 In the image processing apparatus according to the present invention, the AC prediction encoding unit divides the macroblock to be encoded into pixel blocks of 4 × 4 pixel units, and further divides the macroblocks into 2 × 2 pixel sub-pixel blocks. When performing the conversion, if the adjacent target pixel block is an inter-coded pixel block, the AC component prediction is performed using the macroblock of the decoding result.
本願発明の画像処理装置は、Iピクチャ,Pピクチャ及びBピクチャを用いた動画像の復号を行う画像処理装置において、入力される符号化された画像データがIピクチャであるとき、入力される復号対象の対象画素ブロックのDC値と、この対象画素ブロックに隣接する画素ブロックのDC値との間において交流成分予測を行い、各画素ブロックを4分割した2×2画素のサブ画素ブロック毎に、第1のDC画素値を求め、この第1のDC画素値に対して、入力される第1のアダマール係数の逆アダマール変換を行い、このサブ画素ブロックの第1のDC画素値と、対応する位置の原画像のサブ画素ブロックとの差分を第1の差分値として求め、この第1の差分値を、交流成分予測により復号された第1のDC画素値に加算して、加算結果を復号データとして出力する第1の交流予測復号部と、前記第1のDC画素値とこの第1のDC画素値に隣接するサブ画素ブロックの第1のDC画素値との間において交流成分予測を行い、画素毎に、第2のDC画素値を求め、この画素の第2のDC画素値に対して、入力される第2のアダマール係数の逆アダマール変換を行い、この画素の第2のDC画素値と、対応する位置の原画像の画素との差分を第2の差分値として求め、この第2の差分値を、交流成分予測により復号された第2のDC画素値に加算して、加算結果を復号データとして出力する第2の交流予測復号部と、入力される符号化された画像データがBまたはPピクチャであるとき、復号対象の8×8画素のマクロブロックがイントラ符号化されたものかインター符号化されたものかの判定を行う判定部と、復号対象のマクロブロックがインター符号化されたものであるとき、参照ブロックとマクロブロックとの各画素の差分による差分ブロックを4×4の画素ブロックに分割して、画素ブロック毎に求められた残差の平均値である残差DC値と、4×4画素ブロック毎に得られた第1及び第2のアダマール係数とにおいて、残差DC値と第1及び第2のアダマール係数を逆アダマール変換して求めた残差の差分値とを加算し、この加算結果に参照ブロックの画素値を加算することにより、マクロブロックの復号を行うインター復号部と、復号対象のマクロブロックがインター符号化されたものであるとき、参照ブロックとマクロブロックとの各画素の残差の平均値である残差DC値と、復号対象のマクロブロックがイントラ符号化されたものであるとき、入力されるマクロブロックから4×4画素の画素ブロックのDC値を求め、このDC値によりマクロブロックの復号を行うイントラ復号部とを有することを特徴とする。 The image processing apparatus according to the present invention is an image processing apparatus that performs decoding of a moving image using an I picture, a P picture, and a B picture. When the input encoded image data is an I picture, the input decoding is performed. For each 2 × 2 pixel sub-pixel block obtained by performing AC component prediction between the DC value of the target pixel block of interest and the DC value of the pixel block adjacent to the target pixel block, and dividing each pixel block into four, A first DC pixel value is obtained, an inverse Hadamard transform of the input first Hadamard coefficient is performed on the first DC pixel value, and the first DC pixel value corresponding to the first DC pixel value of the sub-pixel block is obtained. The difference from the sub-pixel block of the original image at the position is obtained as a first difference value, and this first difference value is added to the first DC pixel value decoded by the AC component prediction, and the addition result AC component prediction is performed between the first AC prediction decoding unit that outputs the decoded data, and the first DC pixel value and the first DC pixel value of the sub-pixel block adjacent to the first DC pixel value. For each pixel, a second DC pixel value is obtained, an inverse Hadamard transform of the input second Hadamard coefficient is performed on the second DC pixel value of this pixel, and a second DC of this pixel is obtained. The difference between the pixel value and the pixel of the original image at the corresponding position is obtained as a second difference value, and this second difference value is added to the second DC pixel value decoded by the AC component prediction, The second AC predictive decoding unit that outputs the addition result as decoded data, and when the encoded image data to be input is a B or P picture, a macro block of 8 × 8 pixels to be decoded is intra-coded. Or inter-coded When the decoding unit and the decoding target macroblock are inter-coded, the difference block based on the difference between each pixel of the reference block and the macroblock is divided into 4 × 4 pixel blocks. The residual DC value, which is the average value of the residuals obtained for each pixel block, and the first and second Hadamard coefficients obtained for each 4 × 4 pixel block, An inter decoding unit that decodes the macroblock by adding the difference value of the residual obtained by inverse Hadamard transform of the second Hadamard coefficient and adding the pixel value of the reference block to the addition result; and decoding When the target macroblock is inter-coded, the residual DC value, which is the average of the residuals of the pixels of the reference block and the macroblock, and the macroblock to be decoded are An intra-decoding unit that obtains a DC value of a pixel block of 4 × 4 pixels from an input macroblock and decodes the macroblock based on the DC value when it is a tra-coded one .
本願発明の画像処理装置は、前記イントラ復号部が、復号対象のマクロブロックを4×4画素単位の画素ブロックに分割し、また2×2画素のサブ画素ブロックに分割して交流予測符号化による復号を行う際に、隣接した対象画素ブロックがインター符号化された画素ブロックの場合、その復号結果のマクロブロックを用いて交流成分予測を行うことを特徴とする。 In the image processing apparatus according to the present invention, the intra decoding unit divides a macroblock to be decoded into pixel blocks of 4 × 4 pixel units, and further divides the macroblocks into 2 × 2 pixel sub-pixel blocks. When performing decoding, if the adjacent target pixel block is an inter-coded pixel block, AC component prediction is performed using a macroblock of the decoding result.
本発明による画像処理装置によれば、元画像の画素値とサブ画素ブロック第1のDC画素値との第1の差分値をアダマール変換して、差分値としての情報量の多い低周波成分(画素ブロックに対応する第1のアダマール係数)を抽出した後に、この第1の差分値を復号し第1のDC画素値に加えて、サブ画素ブロックの各画素の第2のDC画素値を求めた後に、第2のアダマール変換により残り高周波側のアダマール係数(サブ画素ブロックに対応する第2のアダマール係数)を求めるので、残りの第2のアダマール係数の情報量を削減することが出来るため、ACP処理及びアダマール変換を1回ずつ行う1段階処理に比較して、第2の差分値のデータ量を減少させることが可能となり、1段階の差分値から全てのアダマール係数を求める場合に比較して、アダマール係数のデータ量を少なくし、MPEGと同等以上の画像品質により、画像の圧縮及び復号を行うことができる。 According to the image processing apparatus of the present invention, the first difference value between the pixel value of the original image and the first DC pixel value of the sub-pixel block is subjected to Hadamard transform, and a low-frequency component having a large amount of information as the difference value ( After extracting the first Hadamard coefficient corresponding to the pixel block, the first difference value is decoded and added to the first DC pixel value to obtain the second DC pixel value of each pixel of the sub-pixel block. Since the Hadamard coefficient (second Hadamard coefficient corresponding to the sub-pixel block) on the remaining high frequency side is obtained by the second Hadamard transform, the information amount of the remaining second Hadamard coefficient can be reduced. Compared with the one-stage process in which the ACP process and the Hadamard transform are performed once, the data amount of the second difference value can be reduced, and all Hadamard coefficients are obtained from the one-stage difference value. Compared to the case, to reduce the data amount of the Hadamard coefficients, the image quality of MPEG and more equal, it is possible to perform the compression and decoding of the image.
また、本発明による画像処理装置によれば、アダマール変換だけでなくACP法による符号化処理も加わっているため、アダマール変換をブロック単位で行うために現れやすいブロックノイズを削減することができる。
さらに、本発明による画像処理装置によれば、符号化の時点において、インターの復号を行い、このインターの復号結果をイントラ符号化の処理、すなわち符号化のための差分値を求めることに使用しているため、比較する画像との差分値を圧縮する上述した画像圧縮の手法を動画に効果的に適用することができ、大幅に圧縮効率を向上させることが可能となり、動画の画像情報として伝送する符号化データのデータ量を削減することができ、画像情報の転送効率を向上させることができ、符号化データの復号によりMPEGと同等の画像品質により画像を再生することができる。
Also, according to the image processing apparatus of the present invention, not only Hadamard transform but also encoding processing by ACP method is added, so that block noise that tends to appear because Hadamard transform is performed in units of blocks can be reduced.
Furthermore, according to the image processing device of the present invention, at the time of encoding, inter decoding is performed, and the decoding result of inter is used for intra encoding processing, that is, to obtain a difference value for encoding. Therefore, the above-described image compression method for compressing the difference value with the image to be compared can be effectively applied to the moving image, and the compression efficiency can be greatly improved and transmitted as moving image information. The amount of encoded data to be reduced can be reduced, the transfer efficiency of image information can be improved, and an image can be reproduced with an image quality equivalent to MPEG by decoding the encoded data.
一般に、画像データの容量は非常に大きいが、多くの冗長度(相関の高い部分)を内在している。
静止画像においては、隣接する画素は非常に似通った値をとることが多い(空間的な相関が高い)。
また、動画像においても、多少の違いはあるが、同じような画像が連続して現れる(時間的な相関が高い)。
上述した空間的及び時間的な冗長度を効率的に取り除くことにより、大幅な画像の情報圧縮が可能となる。
In general, the capacity of image data is very large, but it has a lot of redundancy (a highly correlated part).
In still images, adjacent pixels often take very similar values (high spatial correlation).
Further, similar images appear in succession in moving images, although there are some differences (the temporal correlation is high).
By effectively removing the spatial and temporal redundancy described above, it is possible to significantly compress image information.
・空間的相関を用いる場合
隣接する画素ブロックに、符号化対象ブロックとの相関が高いものが検出された場合、すでに符号化された、隣接する画素ブロックから次に符号化する画素ブロックの値をある程度予測でき、上記隣接する画素ブロックの画素値と、符号化する画素ブロックの画素値との差分を符号化することにより、情報圧縮が行える。
When spatial correlation is used If an adjacent pixel block having a high correlation with the encoding target block is detected, the value of the pixel block to be encoded next from the adjacent pixel block that has already been encoded is set. Information compression can be performed by encoding the difference between the pixel value of the adjacent pixel block and the pixel value of the pixel block to be encoded.
・時間的相関を用いる場合
動画像においては、連続する画像同士は非常に高い相関を有する場合、すなわち時間定な変化が限られている場合が多い。
冗長度削減の最も簡易な手法は、直前に符号化された画像(A)の各画素と、これから符号化しようとする画像(B)の各画素との差分(B−A)をとり、差分を符号化するフレーム間差分符号化がある。
このフレーム間差分符号化の手法は、動きが小さい場合には効果的であるが、フレーム間の変化が大きい場合にはそのまま符号化した場合より符号量が増加する場合がある。
この符号量が所定の設定値より増加する場合、すでに符号化している画像から、これから符号化しようとする画像内の画素ブロックに最も似通ったブロックを、最小の誤差を有するブロックを検索するなどして抽出して切り出し、その切り出された位置及び、切り出された画素ブロックと符号化しようとする画素ブロックとの差分を符号化する動き補償がある。
本発明の画像処理装置においては、上述した空間的相関及び時間的相関(動き補償の手法)を効果的に用いて、動画像の符号化を行っている。
When using temporal correlation In a moving image, continuous images often have a very high correlation, that is, time-dependent changes are often limited.
The simplest technique for reducing redundancy is to take the difference (B−A) between each pixel of the image (A) encoded immediately before and each pixel of the image (B) to be encoded. There is an interframe differential encoding that encodes.
This inter-frame difference encoding method is effective when the motion is small, but when the change between frames is large, the code amount may increase as compared to the case of encoding as it is.
When the amount of code increases from a predetermined set value, the block having the smallest error is searched for the block most similar to the pixel block in the image to be encoded from the already encoded image. There is motion compensation that encodes the extracted position and the difference between the extracted position and the pixel block to be encoded.
In the image processing apparatus of the present invention, a moving image is encoded by effectively using the above-described spatial correlation and temporal correlation (motion compensation method).
また、動き補償は、上述したように、符号化対象画像を上記画素ブロックの矩形上の8×8画素のマクロブロックに分割し、符号化対象ブロック毎に、最も相関の高いマクロブロックを参照ブロックとして検出し、符号化対象ブロックと参照ブロックとの差分を求め、この差分を符号化する。
しかしながら、画像のシーンが変化した場合や、新しい物体が画像内に現れた場合、この動き補償を用いることができないため、画素ブロックを静止画と同様に符号化したほうが符号化効率が上昇する。
In addition, as described above, the motion compensation divides the encoding target image into 8 × 8 pixel macroblocks on the rectangle of the pixel block, and the macroblock with the highest correlation is referred to as the reference block for each encoding target block. The difference between the block to be encoded and the reference block is obtained, and this difference is encoded.
However, when the scene of the image changes or when a new object appears in the image, this motion compensation cannot be used. Therefore, encoding efficiency increases when the pixel block is encoded in the same manner as a still image.
このため、画素ブロックは、次の2種類に分類されて符号化処理が行われる。
・インターブロック(インター符号化されたマクロブロック)
参照画像において相関の高い参照ブロックがあり、この参照ブロックとの差分が符号化されるブロック。
・イントラブロック(イントラ符号化されたマクロブロック)
参照画像において相関の高い参照ブロックが無く、静止画像のように符号化されるブロック。
For this reason, pixel blocks are classified into the following two types and subjected to encoding processing.
・ Inter block (inter-coded macro block)
A block in which there is a reference block having a high correlation in the reference image, and a difference from this reference block is encoded.
Intra block (intra-coded macro block)
A block that is encoded like a still image without a reference block having a high correlation in the reference image.
動き補償は、動画像の高圧縮符号化に必要不可欠な技術であるが、動き補償された画像フレームの復号には、動き予測に使用した参照画像がすでに復号されている必要がある。
参照画像数が多くなるほど、これを保存するバッファや表示されるまでの時間の遅延などの取り扱いが煩雑となり、この煩雑さを解消するため、本発明は、MPEGと同様に、以下に示す3つのピクチャタイプに画像を分類している。
Motion compensation is an indispensable technique for high-compression coding of moving images. However, in order to decode a motion-compensated image frame, it is necessary that a reference image used for motion prediction has already been decoded.
As the number of reference images increases, handling of the buffer for storing the images and the delay of time until display becomes more complicated, and in order to eliminate this complexity, the present invention, like MPEG, has the following three types. Images are classified into picture types.
Iピクチャ(Intra-coded Picture)は、全ての画素ブロックがイントラブロックとして符号化されている。このため、Iピクチャは、他の画像と関連しておらず、単体で復号処理が可能であり、復号後、以降のP及びBピクチャの復元に使用される。
P(Predictive-coded Picture)は、過去のIピクチャもしくはPピクチャを参照ピクチャとして、時間軸上において前向き動き動き補償により復元される。このため、Pピクチャは過去のIまたはPピクチャにしか依存(関連)しておらず、復号後に、以降のP及びBピクチャの復元に使用される。
B(Bidirectional-coded Picture)は、過去のI及びPピクチャのみでなく、未来のI及びPピクチャをも参照ピクチャとして参照して、時間軸上において前向き及び後ろ向き動き補償により復元される。
In an I-picture (Intra-coded Picture), all pixel blocks are encoded as intra blocks. For this reason, the I picture is not related to other images, can be decoded alone, and is used to restore the subsequent P and B pictures after decoding.
P (Predictive-coded Picture) is restored by forward motion compensation on the time axis using a past I picture or P picture as a reference picture. For this reason, the P picture depends only on (related to) the past I or P picture, and is used to restore the subsequent P and B pictures after decoding.
B (Bidirectional-coded picture) is restored by forward and backward motion compensation on the time axis by referring not only to past I and P pictures but also to future I and P pictures as reference pictures.
<<符号化部>>
以下、図面を参照して、本願発明の画像処理装置の説明を行う。図1は本発明の一実施形態による符号化を行う画像処理装置の構成例を示すブロック図である。
この画像処理装置は、ピクチャ並べ換え部1,D-RAPIC符号化部2,ピクチャ蓄積用メモリ3,動き推定部4,インター符号部5,イントラ符号化部6,可変長符号化部7を有している。
ピクチャ並べ換え部1は、外部装置から時系列にフレーム単位で入力される原画像(フレーム画像)を、3種類のI,P及びBピクチャに分類して、I,P及びBピクチャ各々に分類された画像を図2に示すように、各画像にI,P及びBピクチャのいずれであるかを示す識別子を付し、この識別子に応じて符号化する順番に並び替える(エンコード処理)。ここで、ピクチャの上記並べ替えは、ピクチャBが符号化に際して、表示される時系列の並びにおいて、自身より未来に存在するPピクチャを参照する必要があるために行われる
本実施形態の説明においては、原画像のI,P及びBピクチャへの分類規則の一例として、Iピクチャの周期Nを9フレーム毎、Pピクチャの周期Mを3フレーム毎とした。ここで、例えば、周期Mは通常「3」に設定され、周期Nは周期Mの倍数の必要があり、30fps(frames/sec)の場合、周期Nは「15」であり、25fpsの場合、周期Nは「12」である。また、原画像のI,P及びBピクチャへの分類規則は、上記組み合わせに限定されるものではなく、適時、設定されるものである。
<< Encoding Unit >>
The image processing apparatus of the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram illustrating a configuration example of an image processing apparatus that performs encoding according to an embodiment of the present invention.
This image processing apparatus has a
The
図1の構成において、ピクチャ並べ換え部1は、原画像の入力順列[0(I),1(B),2(B),3(P),4(B),5(B),6(P),7(B),8(B),9(I),10(B),11(B),12(P)]を、上記識別に応じて、符号化する順番である符号化順列[0(I),3(P),1(B),2(B),6(P),4(B),5(B),9(I),7(B),8(B),12(B),10(B),11(B)]の順番へ並べ替え、識別子によりピクチャの種類を判定し、原画像がIピクチャであると判定した場合、このIピクチャとされた原画像をD-RAPIC符号化部2へ出力し、原画像がBまたはPピクチャであると判定した場合、このBまたはPピクチャとされた原画像を動き推定部4へ出力する。
In the configuration of FIG. 1, the
D-RAPIC符号化部2は、後に詳細な説明を行うが、ACP(交流成分予測)法に基づく演算により、Iピクチャの符号化を行い、符号化されたデータを可変長符号化部7へ出力する。
動き推定部4は、P,Bピクチャをマクロブロック(8×8画素のブロック)に、上左端部から順次分解し、マクロブロック単位各々に対して動きベクトルが計算される。
ここで、動き推定部4は、Pピクチャに対して参照画像としてIピクチャ及びPピクチャを用い、Pピクチャにおける符号化対象のマクロブロック(以下、符号化対象ブロック)と空間的相関の高い参照領域をIピクチャ及びPピクチャから検索し、IピクチャまたはPピクチャのいずれかより最も空間的相関の高い参照領域を抽出する。
The D-
The
Here, the
また、動き推定部4は、Bピクチャに対して参照画像としてI及びPピクチャを用い、Bピクチャにおける符号化対象の画素ブロック(以下、符号化対象ブロック)と、空間的相関の高い参照領域をI及びPピクチャから検索し、IまたはPピクチャのいずれかより最も空間的相関の高い参照領域を抽出する。
検索方法としては、一般的な方法と同様に、所定の画素範囲内で水平及び垂直にずらして、予測算差信号の最小値を求める。
In addition, the
As a search method, as in the general method, the minimum value of the prediction calculation difference signal is obtained by shifting horizontally and vertically within a predetermined pixel range.
このとき、動き推定部4は、抽出した参照領域と、符号化対象ブロックとの予測残差信号を最小(絶対値和や2乗和の数値が最小)にする動きベクトルの計算を行い、この求められた最小の予測算差信号が予め決められた残差閾値以下(所定のデータ容量範囲内)であるか否かの判定を行い、この判定結果に基づいて、以下に示す符号化方法のいずれかを用いるかの選択を行い、各符号化対象ブロックに対して、いずれの符号化方法(インター符号化またはイントラ符号化)で処理されるかを示すマクロブロック符号化情報(MCB符号化情報)を添付する。
At this time, the
このとき、動き推定部4は、予測残差信号が上記残差閾値以下である場合、動きベクトルを用いた動き補償ブロックとして符号化したほうが効率が高い符号化ができる、すなわち、静止画として符号化したものより、符号化されたデータ量が少なくなると判定し、この符号化対象ブロックをインターブロックとし、インター符号化部5へ出力するとともに、インターブロックであることを示すマクロブロック符号化情報を、可変長符号化部7へ出力する。
このとき、動き推定部4は、動きベクトルを可変長符号化部7へ出力する。
At this time, if the prediction residual signal is equal to or less than the residual threshold, the
At this time, the
一方、動き推定部4は、予測残差信号が上記残差閾値を超える場合、静止画として符号化したほうが効率が高い符号化ができる、すなわち、静止画として符号化したものより、符号化されたデータ量が多くなると判定し、この符号化対象ブロックをイントラブロックとし、イントラ符号化部6へ出力するとともに、イントラブロックであることを示すマクロブロック符号化情報を、可変長符号化部7へ出力する。
ここで、動き推定部4は、マクロブロック符号化情報を、以下の3つの場合を区別する値に設定する。
・イントラ符号化された(イントラブロックである)場合
・過去のピクチャを参照してインター符号化された場合
・未来のピクチャを参照してインター符号化された場合
On the other hand, when the prediction residual signal exceeds the residual threshold, the
Here, the
-Intra-coded (intra-block)-When inter-coded with reference to past pictures-When inter-coded with reference to future pictures
以下、順次、図を用いて、本発明の実施形態による、D-RAPIC符号化部2,インター符号化5及びイントラ符号化部6の構成及び動作例について説明する。
Hereinafter, the configuration and operation examples of the D-
<D-RAPIC符号化部2>
図3は本発明の一実施形態によるD-RAPIC符号化部2の構成例を示すブロック図である。
初めに、D-RAPIC符号化部2における処理の概要を説明すると、本発明の画像処理装置は、元画像を複数の画素(n×n画素)からなる画素ブロックに分割し、例えば4×4の画素からなる画素ブロックに分割する。
そして、この画素ブロック毎に各画素の画素値の平均値を計算し、この画素ブロックにおいて、各画素の平均化された画素値として各DC画像のDC値(すなわち、画素ブロック内にある画素の画素値の平均値)を求める。
そして、本発明による画像処理装置は、このDC値に基づいて、第1段階目のACP(交流成分予測)法に基づく演算から、サブ画素ブロック(2×2画素のブロック)毎の第1のDC画素値を求め、各々のサブ画素ブロックにおける元画像の画素の画素値の平均値からこの第1のDC画素値を減算して第1の差分値を求めて、この第1の差分値に対してアダマール変換を行い、アダマール係数の一部を求めて量子化して出力する。
<D-
FIG. 3 is a block diagram showing a configuration example of the D-
First, the outline of the processing in the D-
Then, the average value of the pixel values of each pixel is calculated for each pixel block, and in this pixel block, the DC value of each DC image (that is, the pixel value in the pixel block) is calculated as the averaged pixel value of each pixel. An average value of pixel values) is obtained.
Then, the image processing apparatus according to the present invention uses the first value for each sub-pixel block (block of 2 × 2 pixels) from the calculation based on the first-stage ACP (AC component prediction) method based on the DC value. A DC pixel value is obtained, and the first difference value is obtained by subtracting the first DC pixel value from the average value of the pixel values of the pixels of the original image in each sub-pixel block, and the first difference value is obtained. Then, Hadamard transform is performed, a part of the Hadamard coefficient is obtained, quantized, and output.
次に、D-RAPIC符号化部2は、この第1アダマール係数を逆量子化して、逆アダマール変換を行い、上記第1の差分値を再生する(量子化により再生された情報は劣化している)。
そして、D-RAPIC符号化部2は、この第1の差分値を対応するサブ画素ロックの画素値(すなわち第1のDC画素値)に加算して、上記サブDC画像の新たな第1のDC画素値として出力する。
次に、D-RAPIC符号化部2は、DC画像の上記新たな第1のDC画素値に基づいて、第2段階目のACP法に基づく演算を行い、各画素毎の第2のDC画素値を求める。
Next, the D-
Then, the D-
Next, the D-
そして、D-RAPIC符号化部2は、元画像の各画素の画素値と上記第2のDC画素値との第2の差分値を求めて(画素の画素値から第2のDC画素値を減算)、第2のアダマール変換を行い、上記第1のアダマール係数(AC符号)を除いた残りのアダマール係数を第2のアダマール係数(AC符号)として求める。
上述したように、D-RAPIC符号化部2は、上記2段階におけるACP法により求めた画素値と元画像の画素値との差分値を、同様に対応する2段階に分けてアダマール係数を求める演算を行っている。
Then, the D-
As described above, the D-
このようにすることで、D-RAPIC符号化部2は、16個の画素に対してDC画像処理を行った時点でDC値を生成し、第1段階のアダマール変換において、低周波数成分を3個の第1のアダマール係数として求め、第2段階のアダマール変換において、高周波成分を4つサブ画素ブロック毎に3個ずつ、計12個の第2のアダマール係数として求めている。
そして、D-RAPIC符号化部2は、求めた15個のアダマール係数及びDC値とを、量子化した後にエントロピー符号化(例えば、ハフマン等)を行い、データ圧縮を行った後出力する。
In this way, the D-
Then, the D-
これにより、D-RAPIC符号化部2は、第1のアダマール変換において、サブ画素ブロック範囲内における元画像の画素値の平均値と、第1のDC画素値との第1の差分値をアダマール変換して、差分値として情報量の多い低周波成分を抽出し、アダマール変換により第1のアダマール係数として符号化し、さらに量子化によりデータ圧縮して符号化した後に、この第1の差分値を逆量子化して復号し、さらに逆アダマール変換することで復号し、第1のDC画素値に加えて新たな第1のDC画素値とし、この新たな第1のDC画素値から第2のDC画素値を求めた後に、第2のアダマール変換により、第2のアダマール係数として符号化し、残りの高周波側のアダマール係数を求めている。
Thereby, in the first Hadamard transform, the D-
一方、D-RAPIC符号化部2は、矩形関数を基底関数とするアダマール変換により画像データの符号化を行うため、隣接する画素の画素値が滑らかに変化する画像を前提とした場合、正弦関数を基底関数とするDCTと比較して、滑らかな変化に関する情報を効率よく符号化することができない。
On the other hand, since the D-
また、D-RAPIC符号化部2は、その後圧縮の観点から量子化が必要であり、画像復号時において逆量子化の後に逆アダマール変換を行った際、DCTがなめらかに近似して復元できるのに対し、アダマール変換では方形波ゆえにエッジが鋭く画素間の画素値の差が開きやすくなる。
Further, the D-
しかしながら、D-RAPIC符号化部2は、第1段階アダマール変換により低周波成分に関する第1のアダマール係数を抽出後、その係数値を第1のDC画素値に加えて新たな第1のDC画素値として符号化に反映させ、この第1のDC画素値に対してACPで周辺ブロックとの差異を補い、元画像の画素値との差を求め、その第2の差分値に対して第2段階のアダマール変換を施すことにより、DCTと同等以上の画質で画像を復元するとともに、元画像の画素値との差分値を取っているため、第2段階の処理(第2段階ACP及び第2段階アダマール変換)において精度の高い符号化が可能となる。
However, the D-
また、D-RAPIC符号化部2は、第1段階の処理(第1段階ACP及び第1段階アダマール変換)の結果を反映し、第2段階の処理(第2段階ACP及び第2段階アダマール変換)で符号化する情報量を抑えることができ、DCT等で高圧縮し復元する時に現れるモスキートノイズは、ACP処理により大幅に軽減できる。
さらに、DCTにおいては実数精度の負荷が大きい演算が必要となるが、D-RAPIC符号化部2は、ACPとアダマール変換との併用方式であり、整数値に対する加減算ビットシフトにより、符号化に必要な演算が実現できるため、DCTと比較して高速に圧縮伸張を行うことができる。
Further, the D-
Furthermore, in DCT, a computation with a large load of real number accuracy is required, but the D-
また、D-RAPIC符号化部2は、ACP処理を行うためのDC値と、このDC値に対してACP処理を行った後の第1及び第2のDC画素値と元画像におけるサブ画素ブロックのDC値及び画素値各々との差分値をアダマール変換した情報のアダマール係数と、を符号化して出力するので、上述したように画像の再生処理に必要な情報量を少なくし、なにより、元画像との差分値をアダマール係数として出力するため、符号化データの精度(復号時の画質、すなわち再生の精度)を高めることができ、かつMPEG等で使用されているDCT処理に比較して少ない情報量で元画像に対して高い再現性を持たせることが可能である。
また、第1のDC値及び第2のDC値とは、DC値(DC画像)があれば、すでに述べたように、各々画素を平均値することで、容易に求めることができるので、符号としては出力しない。
The D-
The first DC value and the second DC value can be easily obtained by averaging each pixel as described above if there is a DC value (DC image). Is not output.
次に、図3により、D-RAPIC符号化部2の構成及び動作について説明する。
D-RAPIC符号化部2は、元画像を左上端から順に画素ブロック(4×4画素)に分解し、この画素ブロックからDC画像を生成するDC画像作成部103と、このDC画像に基づき第1段階のACP処理を行い、画素ブロックを分解(4分割)してサブ画素ブロック(2×2画素)を作成し、サブ画素ブロック毎の第1のDC画素値を求める第1段階交流予測成分予測部104と、この第1のDC画素値と、サブ画素ブロック範囲内における元画像の画素値の平均値との第1の差分値を求め、この第1の差分値に対して第1段階のアダマール変換を行い、第1のアダマール係数(AC符号)を求めて出力し、かつ第1のDC画素値と第1の差分値とを加算し、新たな第1のDC画素値を生成して出力する第1段階アダマール符号化部105と、この新たな第1のDC画素値に基づいて第2段階のACP処理を行い、元画像の各画素に対応した第2のDC画素値を演算する第2段階交流成分予測部106と、元画像の各画素の画素値と第2のDC画素値との第2の差分値を求め、この第2の差分値に対して第2段階のアダマール変換を行い、第2のアダマール係数(AC符号)を求める第2段階アダマール符号化部107から構成されている。
Next, the configuration and operation of the D-
The D-
次に、図3を用いて、本発明の一実施形態によるD-RAPIC符号化部2の動作例を説明する。
本発明のD-RAPIC符号化部2は、元画像(図3の2a)を左上端部から順に、例えば4×4画素から構成される画素ブロックに分割して、この画素ブロック内の画素の画素値の平均値をDC値として求め、量子化後にDC符号として出力する。
Next, an operation example of the D-
The D-
このDC値で画素値が示される画素ブロックはDC画像として定義される。
すなわち、図4(a)に示すように、4×4画素を画素ブロックとし、図4(b)に示すように、DC値を求めることで各画素ブロックはDC画像となる。
ここで、画素ブロックSは、画素d(0,0)〜画素d(3,3)(これらの画素は各々、図4(d)において画素値d00〜d33に対応している)の16の各画素の画素値の平均値であるDC値を画素値としている。
A pixel block whose pixel value is indicated by this DC value is defined as a DC image.
That is, as shown in FIG. 4A, 4 × 4 pixels are used as pixel blocks, and as shown in FIG. 4B, each pixel block becomes a DC image by obtaining a DC value.
Here, the pixel block S includes 16 pixels d (0,0) to d (3,3) (these pixels respectively correspond to the pixel values d00 to d33 in FIG. 4D). A DC value that is an average value of pixel values of each pixel is used as the pixel value.
第1段階交流成分予測部104は、交流成分予測法に基づき、DC画像からサブ画素ブロックを生成する。
すなわち、第1段階交流成分予測部104は、図5(a)において、画素ブロックSから、左上端部から順に、2×2画素で構成されるサブ画素ブロックS1,S2,S3,S4(第1段階ACP適用後画像2c)のDC値(サブ画素ブロックとしての画素値、すなわち第1のDC画素値)を後に示す演算により予測する(生成する)場合、これら各サブ画素ブロックのDC値として第1のDC画素値を、画素ブロックSのDC値とともに、画素ブロックSに対して、上下左右に隣接する画素ブロック(DC画像)U,L,R,BのDC値(このDC値として画素ブロックと同一の符号を使用している)を用いて以下の式により求める。
すなわち、交流成分予測法において、Sがサブ画素ブロックS1〜S4までを含む画素ブロックとすると、サブ画素ブロックS1,S2,S3,S4各々の第1のDC画素値は、予測を行うサブ画素ブロックを有する画素ブロックSと隣接する、すなわち画素ブロックSの上部画素ブロックU,下部画素ブロックB,左側部画素ブロックL,右側部画素ブロックRにより、以下の式により求められる。
S1 = S+(U+L−B−R)/8
S2 = S+(U+R−B−L)/8
S3 = S+(B+L−U−R)/8
S4 = S+(B+R−U−L)/8
The first stage AC
That is, in FIG. 5A, the first-stage AC
That is, in the AC component prediction method, when S is a pixel block including sub-pixel blocks S1 to S4, the first DC pixel value of each of the sub-pixel blocks S1, S2, S3, and S4 is a sub-pixel block that performs prediction. Is obtained by the following equation using an upper pixel block U, a lower pixel block B, a left pixel block L, and a right pixel block R adjacent to the pixel block S having
S1 = S + (U + L-B-R) / 8
S2 = S + (U + R-B-L) / 8
S3 = S + (B + L-U-R) / 8
S4 = S + (B + R-UL) / 8
第1段階アダマール符号化部105は、サブ画素ブロックS1,S2,S3,S4の各々に各々対応させて、元画像の画素d(0,0),d(0,1),d(1,0),d(1,1)と、画素d(0,2),d(0,3),d(1,2),d(1,3)と、画素d(2,0),d(2,1),d(3,0),d(3,1)と、画素d(2,2),d(2,3),d(3,2),d(3,3)との、各4つの画素の画素値の平均値を演算する。
そして、第1段階アダマール符号化部105は、サブ画素ブロックS1,S2,S3,S4の各第1のDC画素値から、対応する画素の上記平均画素値を減算して、各サブ画素ブロック各々における第1の差分値を演算し、この第1の差分値に対して第1段階のアダマール変換を行う。
The first-stage
The first-stage
第1段階アダマール符号化部105は、以下の(1)式に示すようにサブ画素ブロックの構成を2×2画素と見なして、2×2サブ画素ブロックに対応する第1の差分値のアダマール変換を行う。
そして、αは求められるアダマール係数の行列を示し、fは2×2画素に対応する以下に説明する各画素の差分値(すなわち、各サブ画素ブロックの第1の差分値)に対応している。
αの行列の各要素αu,vは、以下の(3)式により求められる。
Each element αu, v of the matrix of α is obtained by the following equation (3).
そして、2×2サブ画素ブロックにおけるアダマール変換における変換係数hu,v(x,y)は、図6(a)に示す変換係数に対応している(白が「−1」であり、黒が「+1」である)。ここで、サブ画素ブロックS1,S2,S3,S4各々に対応する変換係数hu,v(x,y)の位置関係(図6(a)に示す変換係数における)は、図4(c)に示しているs(x,y)のx,yの示す位置関係に対応している(ここでは、変換係数hu,v(x,y)の位置関係のみを示している)。 The transform coefficient hu, v (x, y) in the Hadamard transform in the 2 × 2 subpixel block corresponds to the transform coefficient shown in FIG. 6A (white is “−1”, black is "+1"). Here, the positional relationship (in the conversion coefficient shown in FIG. 6A) of the conversion coefficients hu, v (x, y) corresponding to each of the sub-pixel blocks S1, S2, S3, and S4 is shown in FIG. This corresponds to the positional relationship indicated by x, y of s (x, y) shown (only the positional relationship of the conversion coefficients hu, v (x, y) is shown here).
また、fの行列は、以下の(4)式の構造をしている。
このとき、第1段階アダマール符号化部105は、DC値及び第2段階アダマール変換で生成する第2のアダマール係数を除く、アダマール係数α01,α02,α03を求めるため、サブ画素ブロックS1,S2,S3,S4各々に対応する第1の差分値(s(0,0),s(0,1),s(1,0),s(1,1))を、元画像の画素d(0,0),d(0,1),d(1,0),d(1,1)の平均画素値からサブ画素ブロックS1のDC値を減算し、元画像の画素d(0,2),d(0,3),d(1,2),d(1,3)の平均画素値からサブ画素ブロックS2のDC値を減算し、元画像の画素d(2,0),d(2,1),d(3,0),d(3,1)の平均画素値からサブ画素ブロックS3のDC値を減算し、元画像の画素d(2,2),d(2,3),d(3,2),d(3,3)の平均画素値からサブ画素ブロックS4のDC値を減算して求める。
At this time, the first-stage
すなわち、サブ画素ブロックS1,S2,S3,S4の2×2サブ画素ブロックにおいて、サブ画素ブロックを1つの画素と見なして、サブ画素ブロックの第1の差分値に対する2×2のアダマール変換を行う。 That is, in the 2 × 2 subpixel blocks of the subpixel blocks S1, S2, S3, and S4, the subpixel block is regarded as one pixel, and 2 × 2 Hadamard transform is performed on the first difference value of the subpixel block. .
(3)式で求められるアダマール係数α01,α10,α11は、第1段階アダマール符号化部105において量子化され、第1のアダマール係数として出力される。
さらに、第1段階アダマール符号化部105は、量子化された第1のアダマール係数の逆量子化を行い、さらに逆アダマール変換を行い第1の差分値を再生し、再生した第1の差分値を、各画素に対応する第1のDC画素値に加算して、第1段階Hdm(アダマール変換)適用後画像(図3の2d)における新たな第1のDC画素値として出力する。
この再生される第1の差分値は、量子化されたときに情報が劣化している。
The Hadamard coefficients α01, α10, and α11 obtained by Expression (3) are quantized by the first-stage
Further, the first-stage
The information of the first difference value to be reproduced is deteriorated when quantized.
第2段階交流成分予測部106は、入力される第1段階Hdm適用後画像のサブ画素ブロックS1、S2,S3,S4の各々の第1のDC画素値と、各サブ画素ブロックと上下左右において隣接するサブ画素ブロックの第1のDC画素値とに基づき、交流成分予測の演算を行い、各画素d(0,0),…,d(3,3)各々の第2のDC画素値dd00〜dd33を求めて、第2段階ACP適用後画像(図3の2e)を出力する。
ここで、第2段階交流成分予測部106は、例えば、図5(b)に示すサブ画素ブロックS1における画素d(0,0)〜d(1,1)各々の第2のDC画素値dd00,dd01,dd10,dd11を、以下に示す式により演算して求める。
すなわち、交流成分予測法において、S1が画素d(0,0)〜d(1,1)までに関する第1のDC画素値とすると、上記画素各々の第2のDC画素値dd00,dd01,dd10,dd11は、上部サブ画素ブロックU3,下部サブ画素ブロックS3,左側部サブ画素ブロックL2,右側部サブ画素ブロックS2各々の第1の画素値を用いて、以下の式により求められる。
dd00 = S1+(U3+L2−S3−S2)/8
dd01 = S1+(U3+S2−S3−L2)/8
dd10 = S1+(S3+L2−U3−S2)/8
dd11 = S1+(S3+S2−U3−L2)/8
同様に、第2段階交流成分予測部106は、他の残りのサブ画素ブロックS2〜S4における各画素の第2のDC画素値を演算し、サブ画素ブロックS1〜S4までの各画素の第2のDC画素値を、第2段階ACP適用後画像として出力する。
The second-stage AC
Here, the second-stage AC
That is, in the AC component prediction method, when S1 is the first DC pixel value relating to the pixels d (0,0) to d (1,1), the second DC pixel values dd00, dd01, and dd10 of the respective pixels. , dd11 is obtained by the following equation using the first pixel values of the upper subpixel block U3, the lower subpixel block S3, the left subpixel block L2, and the right subpixel block S2.
dd00 = S1 + (U3 + L2-S3-S2) / 8
dd01 = S1 + (U3 + S2-S3-L2) / 8
dd10 = S1 + (S3 + L2-U3-S2) / 8
dd11 = S1 + (S3 + S2-U3-L2) / 8
Similarly, the second-stage AC
第2段階アダマール符号化部107は、サブ画素ブロックS1,S2,S3,S4の各画素の第2のDC画素値から、対応する画素の画素値を減算して、各画素毎に対応した第2の差分値を演算し、この第2の差分値に対して第2段階のアダマール変換を行う。
The second-stage
第2段階アダマール符号化部107は、以下に示す(5)式において4×4画素として、各サブ画素ブロック内の画素毎の第2の差分値に対してアダマール変換を行う。
そして、βnは求められるアダマール係数の行列を示し、下記の(7)式に示すように、gnは2×2画素に対応する以下に説明する、サブ画素ブロック毎の各画素の差分値(すなわち、各サブ画素ブロック内の画素毎の第2の差分値)の行列に対応している。
すなわち、画素d(0,0)〜d(3,3)の画素値は、以下に示すように、対応するサブ画素ブロックS1,S2,S3,S4における各画素値の第2のDC画素値に対応している。
Βn represents a matrix of the obtained Hadamard coefficients, and gn represents a difference value (that is, a difference value of each pixel for each sub pixel block corresponding to 2 × 2 pixels, as shown in the following equation (7)). , Corresponding to a matrix of second difference values for each pixel in each sub-pixel block).
That is, the pixel values of the pixels d (0,0) to d (3,3) are the second DC pixel values of the respective pixel values in the corresponding sub-pixel blocks S1, S2, S3, and S4 as shown below. It corresponds to.
このとき、第2段階アダマール符号化部107は、サブ画素ブロックS1,S2,S3,S4それぞれにおいて、各画素d(0,0),d(0,1),d(1,0),d(1,1)、画素d(0,2),d(0,3),d(1,2),d(1,3)、画素d(2,0),d(2,1),d(3,0),d(3,1)、画素d(2,2),d(2,3),d(3,2),d(3,3)の各第2のDC画素値と、元画像の画素d(0,0),d(0,1),d(1,0),d(1,1)、画素d(0,2),d(0,3),d(1,2),d(1,3)、画素d(2,0),d(2,1),d(3,0),d(3,1)、画素d(2,2),d(2,3),d(3,2),d(3,3)の各々の画素値との差分を演算(元画像の画素値(d00〜d33)から、対応する各画素の第2のDC画素値(dd00〜dd33)を減算、例えば、画素d(0,0)において元画像の画素値d00から第2のDC画素値dd00を減算、これをd(0,0)〜d(3,3)までの画素に対して行う)し、演算結果を第2の差分値として、図4(e)における様に、それぞれサブ画素ブロック(S1〜S4)毎に対して、各画素毎にen(0,0),en(0,1),en(1,0),en(1,1),n∈[0,3]として求め、この第2の差分値を用いて、以下に示す(8)式により第2段階目のアダマール変換を行う。
ここで、kn,βn,gn,en(x,y)各々の添え字「n」は、各サブ画素ブロックの位置に対応している。例えば、図4(e)を例として示すと、「n=0」がサブ画素ブロックS1に対応し、「n=1」がサブ画素ブロックS2に対応し、「n=2」がサブ画素ブロックS3に対応し、「n=3」がサブ画素ブロックS4に対応している。
At this time, the second-stage Hadamard encoding unit 107 uses the pixels d (0,0), d (0,1), d (1,0), d in each of the sub-pixel blocks S1, S2, S3, and S4. (1,1), pixels d (0,2), d (0,3), d (1,2), d (1,3), pixels d (2,0), d (2,1), Each second DC pixel value of d (3,0), d (3,1), pixel d (2,2), d (2,3), d (3,2), d (3,3) And pixels d (0,0), d (0,1), d (1,0), d (1,1), pixels d (0,2), d (0,3), d of the original image (1,2), d (1,3), pixel d (2,0), d (2,1), d (3,0), d (3,1), pixel d (2,2), The difference between each pixel value of d (2,3), d (3,2), and d (3,3) is calculated (from the pixel value (d00 to d33) of the original image, the second value of each corresponding pixel is calculated. For example, the second DC pixel value dd00 is subtracted from the pixel value d00 of the original image at the pixel d (0,0), and this is d (0,0) -d ( 3), and the calculation result is set as the second difference value as shown in FIG. As shown, for each sub-pixel block (S1 to S4), en (0,0), en (0,1), en (1,0), en (1,1), n∈ [0,3] is obtained, and the second-stage Hadamard transform is performed by the following equation (8) using the second difference value.
Here, the subscript “n” of kn, βn, gn, en (x, y) corresponds to the position of each sub-pixel block. For example, referring to FIG. 4E, “n = 0” corresponds to the sub-pixel block S1, “n = 1” corresponds to the sub-pixel block S2, and “n = 2” corresponds to the sub-pixel block. Corresponding to S3, “n = 3” corresponds to the sub-pixel block S4.
そして、βnの行列の各要素βn(u,v)は、以下の(8)式により求められる。
また、図6(a)に示す本発明のアダマール変換係数において、すでに述べた第1段階目のアダマール変換に対応した変換係数部分は従来の構成と同様なものの、第2段階目のアダマール変換に対応した部分はサブ画素ブロック(S1,S2,S3,S4)毎に対応するように構成されている。
すなわち、4×4画素からなる画素ブロックにおいて、図6(a)におけるグループAの4つ(A1〜A4において、A1がh0,0(x,y)、A2がh0,1(x,y),A3がh1,0(x,y)、A4がh1,1(x,y))である。
ここで、アダマール変換係数h0,0(x,y)は、図6(a)に示すように全て黒であり、変換係数として全て「1」であり、全てのサブ画素ブロック差分値を加算したもの、すなわち元画像ブロックの各画素の画素値の平均値と、DC値との差分値に対応したものである。
この全てのサブ画素ブロック差分値を加算したものは、誤差を除いて「0」に等しいため、数値自身がD-RAPIC符号化部2内部に保存されていない。
Further, in the Hadamard transform coefficient of the present invention shown in FIG. 6A, the transform coefficient portion corresponding to the first-stage Hadamard transform described above is the same as the conventional configuration, but the second-stage Hadamard transform is used. The corresponding part is configured to correspond to each sub-pixel block (S1, S2, S3, S4).
That is, in a pixel block composed of 4 × 4 pixels, four groups A in FIG. 6A (in A1 to A4, A1 is h0,0 (x, y) and A2 is h0,1 (x, y). , A3 is h1,0 (x, y), and A4 is h1,1 (x, y)).
Here, the Hadamard transform coefficients h0,0 (x, y) are all black as shown in FIG. 6A, and are all “1” as transform coefficients, and all sub-pixel block difference values are added. Corresponding to the difference value between the average value of the pixel values of each pixel of the original image block and the DC value.
Since the sum of all the sub-pixel block difference values is equal to “0” except for the error, the numerical value itself is not stored in the D-
また、図6(b)に示すn=0〜3の各図は、画素ブロックにおける各々のサブ画素ブロック(2×2画素)に対応した、アダマール変換係数の組み合わせとなっている。
例えば、図4(b)の画素ブロックSにおいて、各画素に対する(8)式における変換係数の対応関係を確認すると、n=0(サブ画素ブロックS1)においてk0(u,v)(x,y),u,v,x,y∈[0,1]となり、n=1(サブ画素ブロックS2)においてk1(u,v)(x,y),u,v,x,y∈[0,1]となり、n=2(サブ画素ブロックS3)においてk2(u,v)(x,y),u,v,x,y∈[0,1]となり、n=3(サブ画素ブロックS4)においてk3(u,v)(x,y)、ここでu,v,x,y∈[0,1]となり、添え字「n」を除くと、各サブ画素ブロックにおいて、図6(a)におけるA1〜A4の対応と同様となる。
ここで、アダマール変換係数k0(0,0)(x,y),k1(0,0)(x,y),k2(0,0)(x,y),k3(0,0)(x,y)、x,y∈[0,1]各々は、図6(b)で示されているように、全て黒であり、変換係数として全て「1」であり、全ての画素の差分値を加算したもの、すなわち、各サブ画素ブロックにおける画素値の平均値と、新たな第1のDC画素値との差分値に対応したものである。
この全ての画素の差分値を加算したものは、誤差を除いて「0」に等しいため、数値自身が符号化部2内部に保存されていない。
Each diagram of n = 0 to 3 shown in FIG. 6B is a combination of Hadamard transform coefficients corresponding to each sub-pixel block (2 × 2 pixels) in the pixel block.
For example, in the pixel block S of FIG. 4B, when the correspondence relationship of the conversion coefficient in the equation (8) for each pixel is confirmed, k0 (u, v) (x, y) at n = 0 (sub-pixel block S1). ), U, v, x, y ∈ [0, 1], and when n = 1 (sub-pixel block S2), k 1 (u, v) (x, y), u, v, x, y ∈ [0, 1], and n = 2 (subpixel block S3), k2 (u, v) (x, y), u, v, x, y∈ [0,1], and n = 3 (subpixel block S4) K3 (u, v) (x, y), where u, v, x, y∈ [0,1], and when subscript “n” is removed, in each sub-pixel block, FIG. This is the same as the correspondence of A1 to A4.
Here, Hadamard transform coefficients k0 (0,0) (x, y), k1 (0,0) (x, y), k2 (0,0) (x, y), k3 (0,0) (x , y), x, y∈ [0, 1], as shown in FIG. 6B, all are black, all are “1” as conversion coefficients, and the difference values of all pixels In other words, corresponding to the difference value between the average value of the pixel values in each sub-pixel block and the new first DC pixel value.
Since the sum of the difference values of all the pixels is equal to “0” except for the error, the numerical value itself is not stored in the
上述した(8)式において、画素d(0,0)〜d(3,3)に対応する差分値を、対応する画素の符号に対応させて、差分値en(0,0)〜en(1,1)により表している(この対応関係は、図4(e)と図5(b)とにおけるブロックSの比較により対応づけられる)。
ここで、第2段階アダマール符号化部107は、サブ画素ブロックS1,S2,S3,S4各々に対応して、すでに(7)式で示したgnと、(8)式とによりアダマール係数の演算を行う。
このgnの添え字「n」も、図4(e)と同様に、各サブ画素ブロック(S1〜S4)の位置に対応している。
In the above equation (8), the difference values corresponding to the pixels d (0,0) to d (3,3) are made to correspond to the codes of the corresponding pixels, and the difference values en (0,0) to en ( 1, 1) (this correspondence is associated by comparing the block S in FIG. 4 (e) and FIG. 5 (b)).
Here, the second-stage
The subscript “n” of gn also corresponds to the position of each sub-pixel block (S1 to S4), as in FIG.
また、第2段階アダマール符号化部107は、(8)式により、画素ブロック(例えば、S)に含まれる各サブ画素ブロック(例えば、S1,S2,S3,S4)の12個のアダマール係数、すなわちβn(0,1),βn(1,0),βn(1,1)、ここでn∈[0,3]を、第2のアダマール係数として演算し、量子化処理を行って出力する。
例えば、第2段階アダマール符号化部107は、量子化された第2のアダマール係数の逆量子化を行い、第2の差分値を再生し、再生した第2の差分値を、各部分に対応する第2のDC画素値に加算して、第2段階Hdm(アダマール変換)適用後画像(図3の2f)として、後に述べるD-RPIC復号部13復号部2で復号されて出力されるIピクチャと同一な画像を再生して、ピクチャ蓄積用メモリ3へ記憶させる。
In addition, the second-stage
For example, the second-stage
<インター符号化部5>
次に、図7は本発明の一実施形態によるインター符号化部5の構成例を示すブロック図である。
インター符号化部5は、各ピクチャの符号化対象ブロック(8×8画素のマクロブロック)と、参照画像の参照ブロック(8×8画素のマクロブロック)との対応する画素の各画素値の差をとり、残差として出力する減算部201と、アダマール変換を行うために、マクロブロック(8×8画素)を分割し、画素ブロック(4×4画素)及びサブ画素ブロック(2×2画素)を生成、すなわち、低周波成分である第1のアダマール係数を得る処理単位である画素ブロック(4×4画素)を生成(分割)に分解し、この画素ブロックから、後に行う高周波成分である第2のアダマール係数を得る処理単位であるサブ画素ブロック(2×2画素)を生成(分割)するマクロブロック分離部202と、画素ブロックのDC値を作成するDC値作成部203と、第1のアダマール係数を生成する第1段階アダマール符号化部204と、第2のアダマール係数を生成する第2段階アダマール符号化部205と、DC値(DC係数),第1のアダマール係数及び第2のアダマール係数により合成された画素ブロック(復号サブ残差画素ブロック)を、分割前のマクロブロックにおける位置に対応するように合成する(まとめる)マクロブロック合成部207と、この合成されたマクロブロックと参照ブロックとの対応する位置の画素値を加算する加算部208とを有している。
<
Next, FIG. 7 is a block diagram illustrating a configuration example of the
The
減算部201は、符号化対象ブロックと、動き推定部により参照画像から切り出された、この符号化対象ブロックとの残差を最小とする参照ブロックとが入力され、この参照ブロックから符号化対象ブロックを減算し、参照ブロックと符号化対象ブロックとの差(対応する画素値の差分の残差画素値)である残差マクロブロックを求める。
マクロブロック分離部202は、8×8画素で構成される残差マクロブロックを、後段においてアダマール変換するため、低周波成分抽出用の4×4画素の画素ブロック単位の残差ブロックに分割し、さらに高周波成分抽出用の2×2画素のサブ画素ブロック単位のサブ残差画素ブロックに分割する。
図8に示すように、マクロブロックは4つの4×4画素の画素ブロックから構成されており、画素ブロックは4つの2×2画素のサブ画素ブロックから構成されている。
The
The
As shown in FIG. 8, the macro block is composed of four 4 × 4 pixel block, and the pixel block is composed of four 2 × 2 pixel sub-pixel blocks.
DC値作成部203は、上記残差画素ブロック毎の残差DC値、すなわち残差画素ブロック毎に、この残差画素ブロックに含まれる画素値(残差画素値)の平均値を演算して、次段の第1段階アダマール符号化部204へ出力するとともに、この残差DC値に対して量子化後に可変長符号部7へ出力する。
第1段階アダマール符号化部204は、残差画素ブロック毎に、残差DC値と残差画素ブロックとから、すなわち、残差画素ブロックと残差DC値との第1の差分値(対応する画素毎の残差画素値の差分値)を減算して求め、この第1の差分値に対して、所定のシーケンシーの低い基底ベクトルにより第1のアダマール係数を演算して出力するとともに、この第1のアダマール係数と上記残差DC値とを用いて残差画素ブロックを復号、すなわち、第1のアダマール係数から復号された第1の差分値と残差DC値とを加算して、復号残差画素ブロック(第1段階アダマール適用後ブロック)として出力する。
ここで、第1段階アダマール符号化部204は、例えば、図6(a)に示す基底ベクトルを用いて、D-RAPIC符号化部2における第1段階アダマール符号化部5と同様の処理を行い、上記第1のアダマール係数の演算を行い、得られた第1のアダマール係数を可変長符号部7へ出力する。
The DC
For each residual pixel block, the first-stage
Here, the first stage
第2段階アダマール符号化部205は、サブ残差画素ブロック毎に、復号残差画素ブロックと残差画素ブロックとから、すなわち、残差画素ブロックと復号残差画素ブロックとの第2の差分値(対応する画素毎の画素値の差分値)を減算して求め、この第2の差分値に対して、所定のシーケンシーの高い基底ベクトルにより第2のアダマール係数を演算して出力するとともに、この第2のアダマール係数と上記復号残差画素ブロックとを用いてサブ残差画素ブロックを復号、すなわち、第2のアダマール係数から復号された第2の差分値と上記復号残差画素ブロックとを加算して、復号サブ残差画素ブロック(第2段階アダマール適用後ブロック)として出力する。
For each sub residual pixel block, the second-stage
また、第2段階アダマール符号化部205は、第2のアダマール係数と、第1段階アダマール符号化部204で生成された第1のアダマール係数とを、まとめて量子化を行った後に、この符号化結果を可変長符号部7へ出力する。
ここで、第2段階アダマール符号化部205は、例えば、図6(b)に示す基底ベクトルを用いて、D-RAPIC符号化部2における第2段階アダマール符号化部7と同様の処理を行い、上記第2のアダマール係数の演算を行い、得られた第2のアダマール係数を可変長符号部7へ出力する。
The second-stage
Here, the second stage
マクロブロック合成部207は、マクロブロック分離部202による分割前のマクロブロックの位置に対応するように、復号サブ残差画素ブロックをマクロブロック単位に合成し、復号残差マクロブロックとして出力する。加算部208は、上記復号残差マクロブロックと参照マクロブロックとを加算し(対応する位置の画素の画素値を各々加算し)、加算結果を復号されたマクロブロックとして、ピクチャ蓄積用メモリ3へ、ピクチャに対応して記憶させる。
The
<イントラ符号化部6>
次に、図9は本発明の一実施形態によるイントラ符号化部6の構成例を示すブロック図である。
DC画像作成部301は、原画像においてイントラブロックと判定された符号化対象ブロックを、4×4画素の画素ブロック単位に分割し、各画素ブロック毎に含まれる画素の画素値の平均を計算して、DC値を求めてDC画像を生成し、このDC値を量子化後に第1段階インター部分補完部302へ出力するとともに、可変長符号化部7へ出力される。
第1段階インター部分補完部302は、イントラブロックをACP法により再生するため、必要となる隣接するマクロブロックがインターブロックである場合(図8参照)、ピクチャ蓄積用メモリ3からインター符号化部5が復号した復号マクロブロック(インターブロック)から、隣接する全てのインターブロックを呼び出し、4×4画素の画素ブロック単位に分割し、イントラブロックと隣接する画素ブロックのDC値の演算を行い、このDC値を第1段階交流成分予測部303へ出力する。
<
Next, FIG. 9 is a block diagram illustrating a configuration example of the
The DC
Since the first-stage inter
第1段階交流成分予測部303は、図3の関係において、D-RAPIC符号化部2の第1段階交流成分予測部104と同様の動作を行い、イントラブロック内のサブ画素ブロック各々の第1のDC画素値を求め、第1段階交流成分予測適用後画像として出力する。
第1段階アダマール符号化部304は、D-RAPIC符号化部2の第1段階アダマール符号化部105と同様の動作を行い、原画像のイントラブロックのサブ画素ブロックの第1のDC画素値から、イントラブロックにおける対応する位置の各画素ブロックのDC値を減算して、第1のDC画素値とDC値との差分である第1の差分値を演算し、この第1の差分値に対して、図6(a)の基底ベクトルを適用し、第1のアダマール係数を求める。
また、第1段階アダマール符号化部304は、上記DC値と第1のアダマール係数とから第1のDC画素値の復号を行い、第1の復号DC値(第1段階アダマール適用後画像:イントラブロック単位の画像データ)として第2段階インター部分補完部305へ出力する。
The first-stage AC
The first stage
Further, the first stage
第2段階インター部分補完部305は、ピクチャ蓄積用メモリ3からインター符号化部5が復号した復号マクロブロック(インターブロック)から、隣接する全てのインターブロックを呼び出し、イントラブロックと隣接するサブ画素ブロックにおいて、含まれる画素の画素値の平均を求め、第1の画素値として出力する。
第2段階交流成分予測部306は、D-RAPIC符号化部2の第2段階交流成分予測部106と同様の動作を行い、上記第1の復号DC値と、イントラブロックから求めた第1の画素値とから、各サブ画素ブロックの画素単位の第2のDC画素値を復号して求め、この第2のDC画素値を第2段階交流成分予測適用後画像(イントラブロック単位の画像データ)として、第2段階アダマール符号化部307へ出力する。
The second-stage inter
The second-stage AC
第2段階アダマール符号化部307は、D-RAPIC符号化部2の第2段階アダマール符号化部107と同様の動作を行い、原画像のマクロブロックに対応するサブ画素ブロックの各画素の画素値から、上記第2のDC画素値を減算して、画素値と第2のDC画素値との差分である第2の差分値を求め、この第2の差分値に対して、図6(b)に示す高いシーケンシーの基底ベクトルを適用し、第2のアダマール係数を求める。
また、第2段階アダマール符号化部307は、上記第2のアダマール係数と、第1段階アダマール符号化部304の生成した第1のアダマール係数とをまとめて、量子化を行った後、イントラ符号化データを可変長符号化部7へ出力する。
The second stage
Further, the second stage
さらに、第2段階アダマール符号化部307は、第2のDC画素値と第2のアダマール係数とに基づき、サブ画素ブロックにおける各画素の画素値を復号して求め、この復号画素値を第2段階アダマール適用後画像(イントラブロック単位の画像データ)として、ピクチャ蓄積用メモリ3へ記憶する。
Further, the second-stage
<<復号部>>
次に、図面を参照して、本願発明の画像処理装置の説明を行う。図10は本発明の一実施形態による復号を行う画像処理装置の構成例を示すブロック図である。
この画像処理装置は、判定部10,可変長復号部11,可変長復号部12,D-RAPIC復号部13,インター復号部14,イントラ復号部15,ピクチャ蓄積用メモリ16,ピクチャ並べ換え部17を有している。
判定部10は、すでに述べた符号化部から符号化されたデータを入力し、この入力された符号化データがIピクチャまたはP,Bピクチャのいずれかであるかの判定を行う。
<< Decoding Unit >>
Next, the image processing apparatus of the present invention will be described with reference to the drawings. FIG. 10 is a block diagram illustrating a configuration example of an image processing apparatus that performs decoding according to an embodiment of the present invention.
The image processing apparatus includes a
The
そして、判定部10は、入力された符号化データをIピクチャと判定すれば、このデータを可変長復号部11へ出力し、一方P,Bピクチャと判定すれば、可変長復号部12へ出力する。
可変長復号部11は、符号化データを復号し、DC値,第1のアダマール係数,第2のアダマール係数として、復号後にD-RAPIC復号部13へ出力する。
If the
The variable
可変長復号部12は、入力される符号化データをDC画素値,第1のアダマール係数,第2のアダマール係数,MCB符号化情報,動きベクトル情報の各データとして、復号後にインター復号部14またはイントラ復号部15のいずれかへ出力する。
このとき、可変長復号部12は、入力される符号化データ各々が、MCB符号化情報により、イントラ符号化されているか、またはインター符号化されているかを判定して、インター符号化されていると判定した場合、DC値(残差DC値),第1及び第2のアダマール係数,動きベクトル情報をインター復号部14へ出力する。
一方、可変長復号部12は、入力される符号化データ各々が、イントラ符号化されていると判定した場合、DC値,第1及び第2のアダマール係数をイントラ復号部15へ出力する。
The variable
At this time, the variable
On the other hand, the variable
D-RAPIC復号部13は、後に詳細な説明を行うが、ACP(交流成分予測)法に基づく演算により、Iピクチャの復号を行い、復号されたデータをピクチャ蓄積用メモリ16へ書き込む。
ピクチャ蓄積用メモリ16は、D-RAPIC復号部により復号されたIピクチャが書き込まれ、インター復号部14及びイントラ復号部15各々により、復号されたP及びBピクチャが書き込まれて、各々を記憶している。
ピクチャ並べ換え部17は、ピクチャ並べ換え部1により図2に示すように変換された符号化順列[0(I),3(P),1(B),2(B),6(P),4(B),5(B),9(I),7(B),8(B),12(B),10(B),11(B)]を、ピクチャ蓄積用メモリ16から読み出し、原画像の入力順列[0(I),1(B),2(B),3(P),4(B),5(B),6(P),7(B),8(B),9(I),10(B),11(B),12(P)]へ並べ換え(デコード処理し)、順次、時系列に出力することで動画像の再生を行う。
As will be described in detail later, the D-
In the
The
インター復号部14は、動きベクトル情報,DC値(残差DC値),第1のアダマール係数,第2のアダマール係数,MCB符号化情報等に基づき、インター符号化されたP及びBピクチャの復号を行う。
同様に、イントラ復号部15は、インター復号部14により復号されたマクロブロック,DC値,第1のアダマール係数,第2のアダマール係数,MCB符号化情報等に基づき、イントラ符号化されたP及びBピクチャの復号を行う。
The
Similarly, the
以下、順次、図を用いて、本発明の実施形態による、D-RAPIC復号部13,インター復号部14及びイントラ復号部15の構成及び動作例について説明する。
<D-RAPIC復号部13>
まず、D-RAPIC復号部13の構成及び動作の概要について説明する。
本発明によるD-RAPIC復号部13は、上述したD-RAPIC符号化部2と同様に、復号時において、入力されるDC画像のDC値に基づき、第1段階ACP処理を行い、第1のDC画素値を求める。
次に、D-RAPIC復号部13は、入力される上記第1アダマール係数を逆量子化して、第1段階アダマール復号(逆アダマール変換)を行い第1の差分値を求め、この第1の差分値を、対応するサブ画素ブロックの上記第1のDC画素値に加算して、新たな第1のDC画素値を生成する。
Hereinafter, the configuration and operation examples of the D-
<D-
First, the outline of the configuration and operation of the D-
Similar to the D-
Next, the D-
次に、D-RAPIC復号部13は、上記第1のDC画素値を用いて、第2段階ACP処理を行い、各画素毎の第2のDC画素値を求める。
そして、D-RAPIC復号部13は、本発明の画像処理装置は、入力される第2アダマール係数を逆量子化して、第2段階アダマール復号を行い第2の差分値を求め、この第2の差分値を、対応する各画素の上記第2のDC画素値に加算して、新たな第2のDC画素値を生成し、再生画素値として出力する。
Next, the D-
Then, the D-
上述したように、D-RAPIC復号部13は、アダマール変換だけでなくACP法による周辺の画素ブロックまたはサブ画素ブロックからの成分予測処理も加わっているため、モスキートノイズだけでなく、アダマール変換をブロック単位で行うために現れやすいブロックノイズをも削減することができる。
As described above, since the D-
また、D-RAPIC復号部13は、符号化及び復号が加減算とビットシフトとの演算のみにより、上述した処理を行うことが可能なため、コンパクトな処理構成で実現でき、加えて、画素値の大きさの違いに伴う分岐処理もなく、所定の周期で連続して処理を行うことが可能なため、高速な符号化及び復号(符号化の逆の操作)の処理が行える。
In addition, the D-
次に、図11は本発明の一実施形態によるD-RAPIC復号部13の構成例を示すブロック図である。
DC画像復号部151は、入力されるDC符号を逆量子化及び復号を行いDC値を求め、DC画像(図11の4b)を再生する。
第1段階交流成分予測部152は、第1段階交流成分予測部104と同様に、サブ画素ブロックS1〜S4各々の第1のDC画素値を求め、このサブ画素ブロックS1〜S4からなる第1段階ACP適用画像(図11の4c)として出力する。
第1段階アダマール復号部153は、入力される符号化された第1のアダマール係数を逆量子化及びエントロピー復号し、アダマール係数α'01,α'10,α'11として復号(再生)し、この第1のアダマール係数に対して、以下に示す(9)式を用いて、逆アダマール変換を行うことにより、第1の差分値を復号(再生)する。
The DC
Similarly to the first-stage AC
The first stage
すなわち、第1段階アダマール復号部153は、再生されるサブ画素ブロックの各部分に対応する第1の差分値を、以下に示す(10)式を用いて演算して求める。
そして、(9)式のf'は下記に示す(11)式として求められる。
And f 'of (9) Formula is calculated | required as (11) Formula shown below.
また、第1段階アダマール復号部153は、第1段階交流成分予測部152から入力されるサブ画素ブロックS1〜S4の各々の第1のDC画素値に対して、復号した第1の差分値を、対応するサブ画素ブロック毎に加算することにより、加算結果をサブ画素ブロックS1〜S4各々の新たな第1のDC画素値とし、このサブ画素ブロックS1〜S4を第1段階Hdm適用後画像(図11の4d)として出力する。
In addition, the first-stage
次に、第2段階交流成分予測部156は、入力される第1段階Hdm適用後画像4dにおける各サブ画素ブロックの第1段階Hdm適用後画像(図11の4d)に基づき、第2段階交流成分予測部106と同様な式を用いた演算により、サブ画素ブロックの各画素毎の第2のDC画素値を求め、第2段階ACP適用後画像(図11の4e)として出力する。
また、第2段階アダマール復号部157は、入力される第2のアダマール係数により、以下に示す(12)式に基づいて、各画素単位の差分値を求める。
The second-stage
ここで、第2段階アダマール復号部157は、(13)式において、入力される第2のアダマール係数βn(u,v)、ここでn∈[0,3],u,v∈[0,1]と、アダマール変換係数とを用いて各画素に対応する第2の差分値を演算する。
そして、各サブ画素ブロックの画素を求めるアダマール変換係数は、n=0(サブ画素ブロックS1)においてk0(u,v)(x,y),u,v,x,y∈[0,1]であり、n=1(サブ画素ブロックS2)においてk1(u,v)(x,y),u,v,x,y∈[0,1]であり、n=2(サブ画素ブロックS3)においてk2(u,v)(x,y),u,v,x,y∈[0,1]であり、n=3(サブ画素ブロックS4)においてk3(u,v)(x,y),u,v,x,y∈[0,1]である。
さらに、第2段階アダマール復号部157は、各画素単位で得られた第2の差分値を、対応する位置の画素の第2のDC画素値に加算して、第2段階Hdm適用後画像(図11の4q)におけるサブ画素ブロックの新たな第2のDC画素値として、すなわち、復号処理画像であるIピクチャとして、ピクチャ蓄積メモリ16へ出力して記憶させる。
Here, the second-stage
The Hadamard transform coefficient for obtaining the pixel of each sub-pixel block is k0 (u, v) (x, y), u, v, x, y∈ [0,1] at n = 0 (sub-pixel block S1). N = 1 (subpixel block S2), k1 (u, v) (x, y), u, v, x, y∈ [0,1], and n = 2 (subpixel block S3) K2 (u, v) (x, y), u, v, x, y∈ [0,1], and k = 3 (u, v) (x, y) at n = 3 (sub-pixel block S4) , U, v, x, y∈ [0, 1].
Further, the second stage
これにより、(12)式のg'nは、以下に示す(14)式として求められる。
上述したように、本発明による画像処理装置は、16個の画素の周波数成分として出力される15個のアダマール係数の内、第1のアダマール変換において、情報量の多い低周波成分(第1のアダマール係数)の3個を抽出した後に、これを復号し第1のDC画素値に加えて、サブ画素ブロックの各画素の第2のDC画素値を求めた後に、第2のアダマール変換において高周波成分(第2のアダマール係数)を4つのサブ画素ブロック毎に3個ずつ、計12個のアダマール係数として求めている。
このため、ACP処理及びアダマール変換を1回ずつ行う1段階処理と比較して、第2のアダマール係数のデータ量を少なくすることができる。
As described above, the image processing apparatus according to the present invention has a low frequency component (first frequency) with a large amount of information in the first Hadamard transform among the 15 Hadamard coefficients output as frequency components of 16 pixels. After extracting three of the Hadamard coefficients), this is decoded and added to the first DC pixel value to obtain the second DC pixel value of each pixel of the sub-pixel block, and then the second Hadamard transform performs high frequency Three components (second Hadamard coefficients) are obtained for each of the four sub-pixel blocks, and a total of 12 Hadamard coefficients are obtained.
For this reason, the data amount of the second Hadamard coefficient can be reduced as compared with the one-step process in which the ACP process and the Hadamard transform are performed once.
<インター復号部14>
図12は本発明の一実施形態によるインター復号部14の構成例を示すブロック図である。
第1段階アダマール復号部402は、入力される残差マクロブロックの画素ブロック単位のDC値(残差DC値)、及び第1及び第2のアダマール係数と(復号対象のマクロブロックに対して、入力されるDC値及び第1及び第2のアダマール係数は4つ(1マクロブロック内に4×4画素のサブ画素ブロックがある)あるため)により、D-RAPIC復号部13における第1段階アダマール復号部153と同様の演算処理により、画素ブロック単位の第1の差分値を求め、各画素ブロック毎に、この第1の差分値を対応するサブ画素ブロック毎の画素値に加算し、加算結果を第1段階アダマール適用後ブロックとして第2段階アダマール復号部403へ出力する。
<
FIG. 12 is a block diagram showing a configuration example of the
The first-stage
第2段階アダマール復号部403は、入力される残差画素ブロックをサブ画素ブロック単位に分割し、各サブ画素ブロック(残差サブ画素ブロック)ごとの第2のアダマール係数と、第1段階アダマール適用後ブロックとにより、D-RAPIC復号部13における第2段階アダマール復号部157と同様の演算処理により、サブ画素ブロックにおける画素単位の第2の差分値を求め、各サブ画素ブロックの対応する画素毎に、この第2の差分値を加算し、加算結果を第2段階アダマール適用後ブロックとしてマクロブロック合成部404へ出力する。
The second-stage
マクロブロック合成部404は、第2段階アダマール復号部403により、サブ画素ブロック毎に復号された、DC値(DC係数),第1のアダマール係数及び第2のアダマール係数により合成された2×2画素の画素ブロック(復号サブ残差画素ブロック)を、分割(分離される前)前の8×8画素のマクロブロックにおける位置に対応するように合成する(まとめる)。
加算部405は、上記合成された残差マクロブロックと、参照ブロックとの対応する画素各々において、差分値(残差画素値)と画素値とを加算し、符号化対象ブロックが復号されたマクロブロックに基づくピクチャ、すなわち、PまたはBピクチャとしてピクチャ蓄積用メモリ16へ出力し、記憶させる。
The
The
<イントラ復号部15>
図13は本発明の一実施形態によるイントラ復号部15の構成例を示すブロック図である。
第1段階インター部分補間部502は、入力されるマクロブロック内の各4×4画素ブロックのDC値を、第1段階交流予測成分予測器503へ出力すると共に、復号するマクロブロックに隣接し、インター符号化を行ったマクロブロックの画素値を、ピクチャ蓄積用メモリ16から読み出し、イントラ符号化部6の第1段階インター部分補間部302と同様に、隣接するマクロブロックにおける各画素ブロックごとに、含まれる画素値の平均を計算して、インター復号されたマクロブロックにおける各画素ブロックのDC値を求める。
<
FIG. 13 is a block diagram illustrating a configuration example of the
The first stage inter
第1段階交流成分予測部503は、可変長符号復号部12で復号されたDC画素値及び第1段階インター部分補間部502各々において求められたDC画素値を用い、D-RAPIC復号部13における第1段階交流成分予測部152と同様に、ACP法によりサブ画素ブロックごとの第1のDC画素値を算出し、第1段階交流成分予測適用後画像として第1段階アダマール復号部504へ出力する。
The first-stage AC
第1段階アダマール復号部504は、入力される各画素ブロックごとの第1のアダマール係数により、D-RAPIC復号部13における第1段階アダマール復号部153と同様の演算処理により、画素ブロック単位の第1の差分値を求め、各画素ブロック毎に、この第1の差分値を対応するサブ画素ブロック毎の画素値に加算し、加算結果を第1段階アダマール適用後ブロックとして第2段階インター部分補間部505へ出力する。
The first-stage
第2段階インター部分補間部505は、復号するマクロブロックに隣接し、インター符号化を行ったマクロブロックの画素値を、ピクチャ蓄積用メモリ16から読み出し、イントラ符号化部6の第2段階インター部分補間部302と同様に、隣接するマクロブロックの各画素ブロックにおけるサブ画素ブロックごとに、含まれる画素値の平均を計算して、インター復号されたマクロブロックの各画素ブロックにおけるサブ画素ブロックの第1のDC画素値を求め、第2段階交流成分予測部506へ出力する。
The second-stage
第2段階交流成分予測部506は、第1段階交流成分予測部503及び第2段階インター部分補間部505各々において求められた第1のDC画素値を用い、D-RAPIC復号部13における第2段階交流成分予測部306と同様に、ACP法によりサブ画素ブロックにおける各画素の第2のDC画素値を算出し、第2段階交流成分予測適用後画像として第2段階アダマール復号部507へ出力する。
The second-stage AC
第2段階アダマール復号部507は、入力される各画素ブロックごとの第2のアダマール係数により、D-RAPIC復号部13における第2段階アダマール復号部157と同様の演算処理により、各サブ画素ブロックにおける画素単位の第2の差分値を求め、各画素ブロック毎に、この第2の差分値を対応するサブ画素ブロックにおける画素毎の画素値に加算し、加算結果を第2段階アダマール適用後ブロック、すなわち復号画像としてピクチャ蓄積用メモリ16へ出力し、この復号画像を記憶させる。
The second-stage
上述してきた画像の圧縮及び復号の処理は、デジタル動画に用いられるY,U,V(輝度=Y、赤の色差=U、青の色差=V)の画像データにより行うものである。
RGB(Red=赤、Green=緑、Blue=青の階調を用いて画像を表現)形式の画像データに対しては、YUV形式の画像データに変換する必要がある。
また、本発明の画像処理装置は、 Y,U,Vに対して同様の処理を行い、画像の圧縮及び復号を行う。
The above-described image compression and decoding processes are performed using image data of Y, U, and V (luminance = Y, red color difference = U, blue color difference = V) used for digital moving images.
For RGB (Red = red, Green = green, Blue = blue) image data, it is necessary to convert the image data into YUV format image data.
The image processing apparatus of the present invention performs similar processing on Y, U, and V, and compresses and decodes images.
上述したように、本発明による画像処理装置は、D-RAPIC符号化部2,インター符号化部5及びイントラ符号化部6において、16個の画素の周波数成分として出力される15個のアダマール係数の内、第1のアダマール変換において、情報量の多い低周波成分の3個を抽出した後に、これを復号し第1のDC画素値に加えて、サブ画素ブロックの各画素の第2のDC画素値を求めた後に、第2のアダマール変換において高周波成分を4つのサブ画素ブロック毎に3個ずつ、計12個のアダマール係数として求めている。
このため、ACP処理及びアダマール変換を1回ずつ行う1段階処理と比較して、第2のアダマール係数のデータ量を少なくすることができる。
As described above, the image processing apparatus according to the present invention has 15 Hadamard coefficients output as frequency components of 16 pixels in the D-
For this reason, the data amount of the second Hadamard coefficient can be reduced as compared with the one-step process in which the ACP process and the Hadamard transform are performed once.
また、本発明による画像処理装置は、イントラ符号部6において、符号化対象マクロブロックを符号化する場合、このイントラ符号化する符号化対象マクロブロックに隣接するインター符号化した部分のマクロブロックを用いて、画素ブロック及びサブ画素ブロック各々のDC値,第1のDC画素値を求め、これらを用いて第1及び第2の差分値を求め、ACP処理に用いるDC値と、アダマール変換された差分値とを求めて符号化するため、イントラ符号化するマクロブロックのACP処理が可能となり、画像の再生処理に必要な情報量を少なくすることができ、かつ、イントラ符号化したマクロブロックとインター符号化したマクロブロックとの境界部分の符号化効率を向上させることができる。
Further, in the image processing apparatus according to the present invention, when the encoding target macroblock is encoded in the
加えて、本発明による画像処理装置は、D-RAPIC符号化部2及びイントラ符号化部6において、ACP処理を行うためのDC値と、このDC値に対してACP処理を行った後の第1及び第2のDC画素値と元画像との差分値をアダマール係数として圧縮情報として出力し、また、インター符号化部5において、参照画像データと符号化対象ブロックとの差分値をアダマール係数として圧縮情報として出力するので、画像の再生処理に必要な情報量を少なくし、なにより、元画像との差分値をアダマール係数として出力するため、元画像に対して高い再現性を持たせることが可能である。
In addition, in the image processing apparatus according to the present invention, the D-
さらに、本発明による画像処理装置は、D-RAPIC符号化部2及びイントラ符号化部6において、上述したアダマール変換だけでなく、各々第1段階交流成分予測部104,303及び第2段階交流成分予測部106,306において、ACP法による画像処理も加わっているため、隣接する画素ブロックまたはサブ画素ブロック間での急激な階調度の変化、すなわち画像内における高い空間周波数の変化を低減させて、復号処理後の画像のブロックノイズを削減できるので、画像全体を滑らかに自然に復号することができ、画素ブロックまたはサブ画素ブロックに対するアダマール変換による符号化に起因するブロックノイズを削減することができる。
Further, in the image processing apparatus according to the present invention, in the D-
また、さらに、本発明による画像処理装置は、第1段階交流成分予測部104,152,303,503,第2段階交流成分予測部106,156,306,506,第1段階アダマール符号化部105,204,304,第2段階アダマール符号化部107,205,307,第1段階アダマール復号部153,402,504,第2段階アダマール復号部157,403,507により、各々(3)式,(8)式,(10)式,(13)式を用いて、加減算とビットシフトとの演算のみにより、上述した処理を行うことが可能なため、コンパクトな回路構成で実現でき、加えて、画素値の大きさに伴う圧縮または伸張における分岐処理もなく、所定の周期で連続して処理を行うことが可能なため、高速な符号化及び復号の処理が行える。
Furthermore, the image processing apparatus according to the present invention includes the first-stage AC
加えて、本発明による画像処理装置は、符号化部及び復号部において、各々の部単位で、第1段階交流成分予測部(例えば、104及び303を共通化また152及び503を共通化)、及び第2段階交流成分予測部(例えば、106及び306を共通化また156及び506を共通化)を共通化させることが可能であり、同様に、第1段階アダマール符号化部、第2段階アダマール符号化部、第1段階アダマール復号部、第2段階アダマール復号部をも共通化することができるため、処理構成のコンパクト化を向上させることが可能である。 In addition, in the image processing apparatus according to the present invention, in the encoding unit and the decoding unit, the first-stage AC component prediction unit (for example, 104 and 303 are shared or 152 and 503 are shared) for each unit, And the second-stage AC component prediction unit (for example, 106 and 306 are shared and 156 and 506 are shared), and similarly, the first-stage Hadamard encoding unit and the second-stage Hadamard Since the encoding unit, the first stage Hadamard decoding unit, and the second stage Hadamard decoding unit can be shared, it is possible to improve the compactness of the processing configuration.
ここで、アダマール変換係数が「1」または「−1」であるので、(3),(8),(10),(13)式における画素値やアダマール係数に対してのアダマール変換係数の積は、乗算ではなく符号の付加として計算する。
その他の演算において、基本となる演算は式から判るように加算であり、また量子化に対してはビットシフトにより演算を行う。
Here, since the Hadamard transform coefficient is “1” or “−1”, the product of the Hadamard transform coefficient with respect to the pixel value and the Hadamard coefficient in the expressions (3), (8), (10), and (13). Is calculated as a sign addition rather than a multiplication.
In other operations, the basic operation is addition as can be seen from the equation, and the quantization is performed by bit shift.
次に、本発明の圧縮及び復号方法を用いた場合と、MPEG2を用いた場合との比較を行った結果を説明する。
図14は、横軸がピクセルあたりのビット量(BPP:Bit per Pixel)を示し、縦軸がPNSR(ピーク値対誤差比)を示しており、圧縮率に対する画質の程度を示すグラフである。
ここで、圧縮率とは、画像ファイルの圧縮前と圧縮後とのバイト数の比であり、数値が低いほど圧縮率が高いことを示している。
実線が本発明の画像処理装置を使用した場合のファイルサイズとPNSRとの関係を示すものであり、破線がMPEG2を使用した場合のファイルサイズとPNSRとの関係を示すものである。
Next, the results of comparison between the case of using the compression and decoding method of the present invention and the case of using MPEG2 will be described.
FIG. 14 is a graph showing the degree of image quality with respect to the compression rate, with the horizontal axis indicating the bit amount per pixel (BPP: Bit per Pixel) and the vertical axis indicating PNSR (peak value to error ratio).
Here, the compression rate is the ratio of the number of bytes before and after compression of the image file, and the lower the value, the higher the compression rate.
The solid line indicates the relationship between the file size and PNSR when the image processing apparatus of the present invention is used, and the broken line indicates the relationship between the file size and PNSR when MPEG2 is used.
本発明の画像処理装置とMPEG2との比較から、同一の圧縮率から復号した場合、本発明においては、ファイルのビット数の高い領域においてPNSRによる数値的な画質の向上が見られる。
上述の画像データとしては、本発明及びMPEG2双方において、画素の処理数が「Y:U:V=4:1:1」の割合で処理されている。
また、サンプルとして使用した画像は、1画素における各RGB毎に8ビットのカラー情報を有している。
From the comparison between the image processing apparatus of the present invention and MPEG2, when decoding is performed from the same compression rate, in the present invention, the numerical image quality is improved by PNSR in the region where the number of bits of the file is high.
The above-described image data is processed at a ratio of “Y: U: V = 4: 1: 1” as the number of processed pixels in both the present invention and MPEG2.
An image used as a sample has 8-bit color information for each RGB in one pixel.
以上、本発明の一実施形態を図面を参照して詳述してきたが、具体的な構成はこの実施形態に限られるものではなく、本発明の要旨を逸脱しない範囲の設計変更等があっても本発明に含まれる。 As mentioned above, although one embodiment of the present invention has been described in detail with reference to the drawings, the specific configuration is not limited to this embodiment, and there are design changes and the like without departing from the gist of the present invention. Are also included in the present invention.
次に、本発明の実施の形態によるコンピュータが実行するためのプログラムについて説明する。
図1及び図10における画像処理装置(画像処理システム)の動作におけるコンピュータシステムのCPUが実行するためのプログラムは、本発明によるプログラムを構成する。
このプログラムを格納するための記録媒体としては、光磁気ディスク、光ディスク、半導体メモリ、磁気記録媒体等を用いることができ、これらをROM、RAM、CD−ROM、フレキシブルディスク、メモリカード等に構成して用いてよい。
Next, a program executed by the computer according to the embodiment of the present invention will be described.
The program executed by the CPU of the computer system in the operation of the image processing apparatus (image processing system) in FIGS. 1 and 10 constitutes a program according to the present invention.
As a recording medium for storing this program, a magneto-optical disk, an optical disk, a semiconductor memory, a magnetic recording medium, and the like can be used, and these are configured as a ROM, a RAM, a CD-ROM, a flexible disk, a memory card, and the like. May be used.
また上記記録媒体は、インターネット等のネットワークや電話回線等の通信回線を介してプログラムが送信された場合のサーバやクライアントとなるコンピュータシステム内部のRAM等の揮発性メモリのように、一定時間プログラムを保持するものも含まれる。
また上記プログラムは、このプログラムを記憶装置等に格納したコンピュータシステムから伝送媒体を介して、あるいは伝送媒体中の伝送波により他のコンピュータシステムに伝送されるものであってもよい。上記伝送媒体とは、インターネット等のネットワーク(通信網)や電話回線等の通信回線(通信線)のように情報を伝送する機能を有する媒体をいうものとする。
In addition, the recording medium can store a program for a certain period of time, such as a volatile memory such as a RAM in a computer system serving as a server or a client when the program is transmitted via a network such as the Internet or a communication line such as a telephone line. The thing to hold is also included.
The program may be transmitted from a computer system storing the program in a storage device or the like to another computer system via a transmission medium or by a transmission wave in the transmission medium. The transmission medium refers to a medium having a function of transmitting information, such as a network (communication network) such as the Internet or a communication line (communication line) such as a telephone line.
また、上記プログラムは、前述した機能の一部を実現するためであってもよい。さらに、前述した機能をコンピュータシステムに既に記録されているプログラムとの組み合わせで実現できるもの、いわゆる差分ファイル(差分プログラム)であってもよい。 The program may be for realizing a part of the functions described above. Furthermore, what can implement | achieve the function mentioned above in combination with the program already recorded on the computer system, what is called a difference file (difference program) may be sufficient.
従って、このプログラムを図1及び図10のシステム又は装置とは異なるシステム又は装置において用い、そのシステム又は装置のコンピュータがこのプログラムを実行することによっても、上記実施の形態で説明した機能及び効果と同等の機能及び効果を得ることができ、本発明の目的を達成することができる。 Therefore, even when this program is used in a system or apparatus different from the system or apparatus shown in FIGS. 1 and 10 and the computer of the system or apparatus executes the program, the functions and effects described in the above embodiments can be obtained. Equivalent functions and effects can be obtained, and the object of the present invention can be achieved.
1,17 ピクチャ並べ換え部
2 D-RAPIC符号化部
3,16 ピクチャ蓄積用メモリ
4 動き推定部
5 インター符号化部
6 イントラ符号化部
7 可変長符号化部
10 判定部
11,12 可変長復号部
13 D-RAPIC復号部
14 インター復号部
15 イントラ復号部
103,301 DC画像作成部
104,152,303,503 第1段階交流成分予測部
105,204,304 第1段階アダマール符号化部
106,156,306,506 第2段階交流成分予測部
107,205,307 第2段階アダマール符号化部
151 DC画像復号部
153,402,504 第1段階アダマール復号部
157,403,507 第2段階アダマール復号部
201 減算部
202 マクロブロック分離部
203 DC値作成部
207,404 マクロブロック合成部
208,405 加算部
302,502 第1段階インター部分補間器
305,505 第2段階インター部分補間器
DESCRIPTION OF
Claims (6)
入力される原画像がIピクチャであるとき、この原画像を4×4画素単位の画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接する画素ブロックとの間において交流成分予測を行い、各画素ブロックを4分割した2×2画素のサブ画素ブロック毎に、第1のDC画素値を求め、この第1のDC画素値と、対応する位置の原画像のサブ画素ブロックとの差分を第1の差分値として求め、この第1の差分値を第1のアダマール係数として符号化し、前記DC値と第1のアダマール係数とを符号化データとして出力する第1の交流予測符号化部と、
前記画素ブロックを2×2画素単位のサブ画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接するサブ画素ブロック間において交流成分予測を行い、各サブ画素ブロックにおける各画素毎に、第2のDC画素値を求め、この第2のDC画素値と、対応する位置の原画像のサブ画素ブロックにおける画素との差分を第2の差分値として求め、この第2の差分値を第2のアダマール係数として符号化し、第2のアダマール係数を符号化データとして出力する第2の交流予測符号化部と、
入力される原画像がBまたはPピクチャであるとき、この原画像を分割して、8×8画素のマクロブロック単位とし、所定の他ピクチャから最も高い相関を有する参照ブロックを抽出し、この参照ブロックを用いた、このマクロブロックの動き補償の符号化データが所定のデータ容量範囲であるかの判定を行う動き推定部と、
マクロブロックの動き補償の符号化データが前記所定の範囲内である場合、このマクロブロックに対して、動き補償に基づくインター符号化を行うインター符号化部と、
マクロブロックの動き補償の符号化データが前記所定の範囲内でない場合、このマクロブロックに対してイントラ符号化を行うイントラ符号化部と
を有することを特徴とする画像処理装置。 In an image processing apparatus for encoding a moving image using an I picture, a P picture, and a B picture,
When the input original image is an I picture, the original image is divided into pixel blocks of 4 × 4 pixel units, a DC value that is an average value of the pixel values is obtained, and an AC component between adjacent pixel blocks For each 2 × 2 pixel sub-pixel block obtained by performing prediction and dividing each pixel block into four, a first DC pixel value is obtained, and the first DC pixel value and the sub-pixel block of the original image at the corresponding position Is obtained as a first difference value, the first difference value is encoded as a first Hadamard coefficient, and the DC value and the first Hadamard coefficient are output as encoded data. An encoding unit;
The pixel block is divided into sub-pixel blocks of 2 × 2 pixel units, a DC value that is an average value of pixel values is obtained, AC component prediction is performed between adjacent sub-pixel blocks, and each pixel in each sub-pixel block is determined. Then, a second DC pixel value is obtained, a difference between the second DC pixel value and a pixel in the sub-pixel block of the original image at the corresponding position is obtained as a second difference value, and the second difference value is obtained. Is encoded as a second Hadamard coefficient, and the second AC prediction encoding unit that outputs the second Hadamard coefficient as encoded data;
When the input original image is a B or P picture, the original image is divided into macro block units of 8 × 8 pixels, and a reference block having the highest correlation is extracted from a predetermined other picture. Using a block, a motion estimation unit for determining whether the encoded data for motion compensation of the macroblock is within a predetermined data capacity range;
When the coded data for motion compensation of the macroblock is within the predetermined range, an inter coding unit that performs inter coding based on motion compensation for the macroblock;
An image processing apparatus comprising: an intra coding unit that performs intra coding on a macroblock when coded data for motion compensation of a macroblock is not within the predetermined range.
符号化対象のマクロブロックを4×4画素単位の画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接する画素ブロックとの間において交流成分予測を行い、各画素ブロックを4分割した2×2画素のサブ画素ブロック毎に、第1のDC画素値を求め、この第1のDC画素値と、マクロブロックにおいて、対応する位置のサブ画素ブロックとの差分を第1の差分値として求め、この第1の差分値を第1のアダマール係数として符号化し、前記DC値と第1のアダマール係数とを符号化データとして出力する第3の交流予測符号化部と、
前記画素ブロックを2×2画素単位のサブ画素ブロックに分割し、画素値の平均値であるDC値を求め、隣接するサブ画素ブロック間において交流成分予測を行い、各サブ画素ブロックにおける各画素毎に、第2のDC画素値を求め、この第2のDC画素値と、対応する位置の原画像のサブ画素ブロックにおける画素との差分を第2の差分値として求め、この第2の差分値を第2のアダマール係数として符号化し、第2のアダマール係数を符号化データとして出力する第4の交流予測符号化部と
を有することを特徴とする請求項1または請求項2に記載の画像処理装置。 The intra encoding unit is
The macroblock to be encoded is divided into pixel blocks of 4 × 4 pixel units, a DC value that is an average value of pixel values is obtained, AC component prediction is performed between adjacent pixel blocks, and each pixel block is divided into 4 A first DC pixel value is obtained for each divided 2 × 2 pixel sub-pixel block, and a difference between the first DC pixel value and a sub-pixel block at a corresponding position in the macro block is determined as a first difference. A third AC predictive encoding unit that obtains the first difference value as a first Hadamard coefficient and outputs the DC value and the first Hadamard coefficient as encoded data;
The pixel block is divided into sub-pixel blocks of 2 × 2 pixel units, a DC value that is an average value of pixel values is obtained, AC component prediction is performed between adjacent sub-pixel blocks, and each pixel in each sub-pixel block Then, a second DC pixel value is obtained, a difference between the second DC pixel value and a pixel in the sub-pixel block of the original image at the corresponding position is obtained as a second difference value, and the second difference value is obtained. 4. The image processing according to claim 1, further comprising: a fourth AC prediction encoding unit that encodes the second Hadamard coefficient as encoded data and outputs the second Hadamard coefficient as encoded data. apparatus.
入力される符号化された画像データがIピクチャであるとき、入力される復号対象の対象画素ブロックのDC値と、この対象画素ブロックに隣接する画素ブロックのDC値との間において交流成分予測を行い、各画素ブロックを4分割した2×2画素のサブ画素ブロック毎に、第1のDC画素値を求め、この第1のDC画素値に対して、入力される第1のアダマール係数の逆アダマール変換を行い、このサブ画素ブロックの第1のDC画素値と、対応する位置の原画像のサブ画素ブロックとの差分を第1の差分値として求め、この第1の差分値を、交流成分予測により復号された第1のDC画素値に加算して、加算結果を新たな第1のDC画素値として出力する第1の交流予測復号部と、
前記第1のDC画素値とこの第1のDC画素値に隣接するサブ画素ブロックの第1のDC画素値との間において交流成分予測を行い、画素毎に、第2のDC画素値を求め、この画素の第2のDC画素値に対して、入力される第2のアダマール係数の逆アダマール変換を行い、この画素の第2のDC画素値と、対応する位置の原画像の画素との差分を第2の差分値として求め、この第2の差分値を、交流成分予測により復号された第2のDC画素値に加算して、加算結果を復号データとして出力する第2の交流予測復号部と、
入力される符号化された画像データがBまたはPピクチャであるとき、復号対象の8×8画素のマクロブロックがイントラ符号化されたものかインター符号化されたものかの判定を行う判定部と、
復号対象のマクロブロックがインター符号化されたものであるとき、参照ブロックとマクロブロックとの各画素の差分による差分ブロックを4×4の画素ブロックに分割して、画素ブロック毎に求められた残差の平均値である残差DC値と、4×4画素ブロック毎に得られた第1及び第2のアダマール係数とにおいて、残差DC値と第1及び第2のアダマール係数を逆アダマール変換して求めた残差の差分値とを加算し、この加算結果に参照ブロックの画素値を加算することにより、マクロブロックの復号を行うインター復号部と、
復号対象のマクロブロックがイントラ符号化されたものであるとき、入力される4×4画素の画素ブロックのDC値とアダマール係数とにより、マクロブロックの復号を行うイントラ復号部と
を有することを特徴とする画像処理装置。 In an image processing apparatus for decoding a moving image using an I picture, a P picture, and a B picture,
When the encoded image data to be input is an I picture, AC component prediction is performed between the DC value of the input target pixel block to be decoded and the DC value of the pixel block adjacent to the target pixel block. The first DC pixel value is obtained for each 2 × 2 pixel sub-pixel block obtained by dividing each pixel block into four, and the inverse of the input first Hadamard coefficient is obtained with respect to the first DC pixel value. Hadamard transform is performed, a difference between the first DC pixel value of the sub-pixel block and the sub-pixel block of the original image at the corresponding position is obtained as a first difference value, and the first difference value is obtained as an AC component. A first AC predictive decoding unit that adds to the first DC pixel value decoded by prediction and outputs the addition result as a new first DC pixel value;
AC component prediction is performed between the first DC pixel value and the first DC pixel value of the sub-pixel block adjacent to the first DC pixel value, and a second DC pixel value is obtained for each pixel. The inverse Hadamard transform of the input second Hadamard coefficient is performed on the second DC pixel value of the pixel, and the second DC pixel value of the pixel and the pixel of the original image at the corresponding position are Second AC predictive decoding that obtains the difference as a second difference value, adds the second difference value to the second DC pixel value decoded by the AC component prediction, and outputs the addition result as decoded data And
A determination unit that determines whether an 8 × 8 pixel macroblock to be decoded is intra-coded or inter-coded when the input encoded image data is a B or P picture; ,
When the macroblock to be decoded is inter-coded, the difference block based on the difference between each pixel of the reference block and the macroblock is divided into 4 × 4 pixel blocks, and the remaining number obtained for each pixel block is divided. In the residual DC value that is the average value of the differences and the first and second Hadamard coefficients obtained for each 4 × 4 pixel block, the residual DC value and the first and second Hadamard coefficients are inverse Hadamard transformed. An inter decoding unit that decodes the macroblock by adding the difference value of the residual obtained in this way and adding the pixel value of the reference block to the addition result;
An intra-decoding unit that decodes a macroblock based on a DC value and a Hadamard coefficient of an input 4 × 4 pixel block when the macroblock to be decoded is intra-coded. An image processing apparatus.
When the intra decoding unit divides a macroblock to be decoded into pixel blocks of 4 × 4 pixel units, and further divides into 2 × 2 pixel sub-pixel blocks and performs decoding by AC predictive coding, 6. The image processing apparatus according to claim 5, wherein when the target pixel block is an inter-encoded pixel block, AC component prediction is performed using a macroblock obtained as a result of decoding.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2003423156A JP2005184525A (en) | 2003-12-19 | 2003-12-19 | Image processor |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2003423156A JP2005184525A (en) | 2003-12-19 | 2003-12-19 | Image processor |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2005184525A true JP2005184525A (en) | 2005-07-07 |
Family
ID=34783780
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2003423156A Pending JP2005184525A (en) | 2003-12-19 | 2003-12-19 | Image processor |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2005184525A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2008004768A1 (en) * | 2006-07-04 | 2008-01-10 | Samsung Electronics Co., Ltd. | Image encoding/decoding method and apparatus |
WO2015099488A1 (en) * | 2013-12-26 | 2015-07-02 | 삼성전자 주식회사 | Depth encoding method and apparatus, decoding method and apparatus |
JP2018206016A (en) * | 2017-06-02 | 2018-12-27 | 株式会社日立製作所 | Machine learning system and machine learning method |
CN112422986A (en) * | 2020-10-26 | 2021-02-26 | 眸芯科技(上海)有限公司 | Hardware decoder pipeline optimization method and application |
-
2003
- 2003-12-19 JP JP2003423156A patent/JP2005184525A/en active Pending
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2008004768A1 (en) * | 2006-07-04 | 2008-01-10 | Samsung Electronics Co., Ltd. | Image encoding/decoding method and apparatus |
US8553768B2 (en) | 2006-07-04 | 2013-10-08 | Samsung Electronics Co., Ltd. | Image encoding/decoding method and apparatus |
WO2015099488A1 (en) * | 2013-12-26 | 2015-07-02 | 삼성전자 주식회사 | Depth encoding method and apparatus, decoding method and apparatus |
JP2018206016A (en) * | 2017-06-02 | 2018-12-27 | 株式会社日立製作所 | Machine learning system and machine learning method |
CN112422986A (en) * | 2020-10-26 | 2021-02-26 | 眸芯科技(上海)有限公司 | Hardware decoder pipeline optimization method and application |
CN112422986B (en) * | 2020-10-26 | 2023-12-22 | 眸芯科技(上海)有限公司 | Hardware decoder pipeline optimization method and application |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4855418B2 (en) | Color video encoding and decoding method and apparatus using correlation of color difference components | |
JP4673758B2 (en) | Image data decoding method and computer-readable medium having recorded program therefor | |
KR100723403B1 (en) | A prediction image generating method and apparatus using using single coding mode among color components, and an image and video encoding/decoding method and apparatus using it | |
JP5878551B2 (en) | Method, computer program and system for tone mapping a high dynamic range (HDR) video data stream | |
JP5296547B2 (en) | Video encoding / decoding method and apparatus using single encoding mode | |
JP5421408B2 (en) | Alpha channel video decoding apparatus, alpha channel decoding method, and recording medium | |
JP5133135B2 (en) | Video encoding method and apparatus, decoding method and apparatus using inter-color compensation | |
WO2010137323A1 (en) | Video encoder, video decoder, video encoding method, and video decoding method | |
US20110211757A1 (en) | Color image encoding and decoding method and apparatus using a correlation between chrominance components | |
JP2009518940A (en) | Image encoding method and apparatus, decoding method and apparatus | |
KR20070090700A (en) | Method of and apparatus for video intraprediction encoding/decoding | |
KR20070096737A (en) | An video encoding/decoding method and apparatus | |
JP2009543423A (en) | Video encoding / decoding method and apparatus | |
KR20070096736A (en) | An video encoding/decoding method and apparatus | |
KR100738075B1 (en) | Apparatus and method for encoding and decoding image | |
JP3696490B2 (en) | Method and video decoder for reducing video memory requirements of a decoder | |
JP2005184525A (en) | Image processor | |
TW201404167A (en) | Video prediction encoding device, video prediction encoding method, video prediction encoding program, video prediction decoding device, video prediction decoding method, and video prediction decoding program | |
JP3935667B2 (en) | Measuring video image activity by filtering DCT and prediction error coefficients | |
JP5533885B2 (en) | Moving picture encoding apparatus and moving picture decoding apparatus | |
JPH10150665A (en) | Method for generating predictive image, and method and device for image encoding | |
JP2004312689A (en) | Mpeg video decoding method and mpeg video decoder | |
JP4513856B2 (en) | Digital signal conversion method and digital signal conversion apparatus | |
JP2002064826A (en) | Apparatus and method for converting resolution of compressed image | |
JP2004120620A (en) | Coded motion picture conversion apparatus |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20060828 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20060911 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20061101 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20070704 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20070831 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20080221 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20080619 |