JP3660548B2 - Image encoding method and image decoding method, image encoding device and image decoding device, and medium storing these programs - Google Patents

Image encoding method and image decoding method, image encoding device and image decoding device, and medium storing these programs Download PDF

Info

Publication number
JP3660548B2
JP3660548B2 JP2000023890A JP2000023890A JP3660548B2 JP 3660548 B2 JP3660548 B2 JP 3660548B2 JP 2000023890 A JP2000023890 A JP 2000023890A JP 2000023890 A JP2000023890 A JP 2000023890A JP 3660548 B2 JP3660548 B2 JP 3660548B2
Authority
JP
Japan
Prior art keywords
coefficient
sibling
coefficients
zero
tree
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.)
Expired - Fee Related
Application number
JP2000023890A
Other languages
Japanese (ja)
Other versions
JP2001218209A (en
Inventor
淳 嵯峨田
由幸 八島
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2000023890A priority Critical patent/JP3660548B2/en
Publication of JP2001218209A publication Critical patent/JP2001218209A/en
Application granted granted Critical
Publication of JP3660548B2 publication Critical patent/JP3660548B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T9/00Image coding
    • G06T9/40Tree coding, e.g. quadtree, octree

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression Of Band Width Or Redundancy In Fax (AREA)

Description

【0001】
【発明の属する技術分野】
本発明は、画像符号化方法及び画像復号方法、画像符号化装置及び画像復号装置、並びにそれらのプログラムを記憶した媒体に関するものである。
【0002】
【従来の技術】
従来、静止画像又は動画像の圧縮符号化にはDCT(離散コサイン変換)が広く用いられてきた。しかしながら、DCTによる画像符号化は、ある程度以上の圧縮率では、変換処理の単位であるブロックの境界が不連続になるブロック歪みや、急峻なエッジ部周辺に発生するモスキートノイズ等の特有の画質劣化が主観画質上問題となっていた。これらの問題点を回避する符号化方法として、離散ウェーブレット変換(I.Daubechies,”Orthonormal bases of compactly supported wavelets”,Comm.Pure Appl.Math,vol.41,pp.909−996,1988)を利用した符号化方法が種々検討されている。
【0003】
離散ウェーブレット変換は、階層的なサブバンド分割と同様に、画像を解像度の異なる周波数帯域成分に分解する。分解された変換係数の総数は原画像の画素数と同じであるが、一般的に、より低い周波数成分に信号エネルギーが集中したものになる。
【0004】
ウェーブレット変換係数は、1次元のフィルタバンクとサブサンプリング処理によって求められる。図1(a)に示すように、画像X(z)の水平方向について低域フィルタHl(z)及び高域フィルタHh(z)出力を求め、その出力を1/2(↓2)に間引く。さらに、同様の処理を垂直方向に適用することにより、4成分LL1,LH1,HL1,HH1に分解される。
【0005】
このうち、最も低い周波数成分LL1をLL2,LH2,HL2,HH2に再分解する。この処理を必要なレベル数繰り返すことにより、図2に示すような画像のオクターブ分割を求めることができる。再生過程においては、図1(b)に示すように、帯域成分LLi+1、LHi+1の垂直方向の各係数間にゼロ値を挿入(↑2)し、その垂直方向にそれぞれ合成フィルタFl(z),Fh(z)をかけ、それらの出力の和を求める。同様の処理を水平方向にHLi+1,HHi+1成分に行う。即ち得られた2成分に、水平方向に同様のフィルタ処理を行うことによりLLi成分が合成される。
【0006】
この合成処理を必要なレベル数だけ繰り返すことにより、画像の再生値が得られる。画像が完全再構成されるためには、分解・合成フィルタは
l(z)Hh(−z)+Hl(−z)Hh(z)=c ……(1)
l(z)=(2/c)Hh(−z) ……(2)
h(z)=(2/c)Hl(−z) ……(3)
という条件を満たしていなければならない。ここで、分解・合成フィルタのタップ長は奇数であり、cは任意の定数である。また、分解及び合成フィルタ係数の相互関係を図3に示す。
【0007】
入力画像信号に水平・垂直ウェーブレット変換を施して得られたウェーブレット変換係数は量子化され、符号化される。一般に、同レベルの高周波数帯域(HLm,LHm,HHm,m∈自然数)内の変換係数を同じ量子化ステップで量子化を行い、量子化後のウェーブレット変換係数をRun−Length符号化、Run−Level符号化等を用いて可変長符号化し、発生符号量を低減する。
【0008】
この時、最低周波数帯域LLを除く他の高周波数帯域内のウェーブレット変換係数値は、ゼロ近傍に集中するラプラス分布で近似可能なため、後述のゼロツリー符号化の効率改善を考慮し、一般的にセンターデッドゾーン付きスカラー量子化が用いられる。なお、LL帯域は粗く、量子化すると復号画像に視覚的に妨害な歪みが目立つため、量子化を行わずにDPCMを用いて可逆符号化する手法が一般的である。
【0009】
また、ウェーブレット変換係数の符号化方法に関しては、各周波数帯域の相似な位置の係数間で相関を持つことを利用した符号化方法も提案されている。ウェーブレットを用いた二次元オクターブ分割では、1レベルの分解によりLL,LH,HL,HHの4成分に分解され、Mレベルの分割を行うと、最低周波数帯域であるLLM成分から、LH1,HL1,HH1成分までの(3M+1)個の成分に分解される。図4はM=3の時の周波数帯域分割例である。
【0010】
分割された周波数帯域信号には、図4に示すようにLL,LH,HL,HHの各周波数帯域がある。
【0011】
LL帯域は水平・垂直方向に低域側の信号であり、画像に2次元の低域フィルタ(LPF)をかけた信号である(以下、「低域成分」あるいは「最低周波数帯域」と呼ぶことがある。)。HL帯域は水平方向に高域フィルタ(HPF)、垂直方向に低域フィルタをかけた信号であり、垂直方向のエッジ成分が現れる(以下、「水平成分」と呼ぶことがある。)。LH帯域は水平方向に低域フィルタ、垂直方向に高域フィルタをかけた信号であり、水平方向のエッジ成分が現れる(以下、「垂直成分」と呼ぶことがある。)。HH帯域は水平、垂直方向ともに高域フィルタをかけた信号で、斜め方向のエッジ成分が現れる(以下、「対角成分」と呼ぶことがある。)。
【0012】
先に述べた自己相似性によるデータの冗長性を除くため、iレベルの分割で得られたLHi,HLi,HHiの3つの高周波成分内の各変換係数と、(i−1)レベルのLHi-1,HLi-1,HHi-1内において、前記各変換係数とそれぞれ空間的に相似な位置の変換係数間で親子関係を定義する。この高周波成分間の前記親子関係は、一つの係数(親,親係数)に対し4つの係数(子供,子供係数)が対応する。また、最低周波数帯域LLM帯域内の変換係数に対しては、例外的にLHM,HLM,HHM帯域内において該変換係数と同位置の3つの変換係数が3つの子として対応する。従って、この親子関係は最低周波数帯域LL内の各変換係数を幹(以下、「ルート」と呼ぶことがある。)とし、解像度の粗い低周波側から解像度の密な高周波側に向かって、相似な位置の変換係数に対して枝(以下、「ノード」と呼ぶことがある。)が生成され、図4に示すような木構造(以下、「ツリー」と呼ぶことがある。)が生成される。
【0013】
先に、各変換係数の逆方向、即ちルート方向へのノードに対応する変換係数のことを親あるいは親係数と呼び、各変換係数の順方向のノードに対応する変換係数のことを子あるいは子供あるいは子供係数と呼ぶと定義したが、ここで、親子関係に基づくツリー構造に関し、以下、いくつかの言葉について定義を行う。
【0014】
各変換係数の親係数の子供係数のことを兄弟あるいは兄弟係数と呼ぶ。例えば、図4中のHH2帯域内にハッチングで示した4係数のうち、任意の1係数から見て該4係数は兄弟係数である。各変換係数の子供及び該子供の子供等、各変換係数から順方向に最後のノードまでの各変換係数を子孫と呼ぶ。
【0015】
例えば、HH3帯域内にハッチングで示した係数から見て、HH2帯域内のハッチングで示した4係数及びHH1帯域内のハッチングで示した16係数は子孫である。また、あるツリー中の任意の変換係数及び該変換係数以下の全ての変換係数によって構成される係数群をサブツリーと定義する。サブツリーとは、即ち”変換係数+該変換係数の子孫”である。
【0016】
以上定義した周波数帯域間の係数ツリーを用いて、ウェーブレット変換係数に対しエントロピー符号化を行う方式として、ゼロツリー符号化(J.M.Shapiro,”Embedded image coding using zerotrees of wavelet coefficients”,IEEE Trans.Signal Processing,vol.41,pp.3445−3462,Dec.1993)が提案されている。
【0017】
ゼロツリー符号化では、あるサブツリー中の各変換係数を量子化した結果、量子化後の係数が全てゼロとなる場合、該サブツリーをゼロツリーと呼び、該サブツリーを1つのゼロツリールート(Zero Tree Root:ZTR)符号に置き換えて符号化することでデータ圧縮を行う。
【0018】
ZTR符号で置換されたサブツリーはこの時点で既に符号化済みであり、該ZTR符号の子孫を後に符号化する必要はない。また、ZTR符号とは逆に、ある変換係数自体の量子化後の値はゼロであるものの、該変換係数の子孫の係数に一つでも有意係数がある場合は、該変換係数を孤立ゼロ(Isolated Zero:IZ)符号として符号化データに出力する。また、符号化対象の変換係数が有意係数である場合は、ZTR符号・IZ符号のいずれの条件にも合わない。この場合は、該変換係数が有意係数であることを示す符号(LEVEL符号)を出力し、該有意係数の値を符号化データに出力する。
【0019】
従って、ゼロツリー符号化において実際に可変長符号化を行うシンボルは、
・ZTR符号
・IZ符号
・LEVEL符号+量子化後係数値
の3種額の符号となる。
【0020】
図5に、ゼロツリー符号化を用いて、LL3帯域内のある変換係数をルートとするツリーを符号化する例を示す。図中の各変換係数はウェーブレット変換係数の量子化後の値であり、それぞれサブツリー(a)はLH帯域、サブツリー(b)はHL帯域、サブツリー(c)はHH帯域内でのサブツリーである。
【0021】
まず、LL3の係数に関し、該係数は”+3”であるため、LEVEL符号を出力し、値”+3”を出力、即ち
・LL3帯域 (LEVEL,3)
を出力する。
【0022】
LH帯域のサブツリーであるサブツリー(a)を符号化する場合は、以下のステップで符号化を行う。
【0023】
・LH3帯域内の係数
量子化後係数は”3”であり、有意係数であるため、LEVEL符号と”+3”を符号化する。
【0024】
・LH2帯域内の係数
−左上の量子化後係数は”−1”であり有意係数であるため、LEVEL符号と”−1”を符号化する。
【0025】
−右上の量子化後係数は”0”であるが、該係数の4つの子供の係数に有意係数”−2”が含まれている。従って、IZ符号を符号化データに出力する。
【0026】
−左下の量子化後係数は”0”であるが、該係数の4つの子供の係数に有意係数”−1,3,1”が含まれている。従って、同様にIZ符号を符号化データに出力する。
【0027】
−右下の量子化後係数は”0”であり、該係数以下のサブツリー内には有意係数が存在しないので、ZTR符号を符号化データに出力する。
【0028】
・LH1帯域内の係数
16個の係数のうち、右下の4つの係数は上位のZTR符号により既に符号化済みであるため、その他の12個の係数を順に符号化する。
【0029】
実際に、以上の手順でサブツリー(a)を符号化した場合、結果として以下の符号、即ち

Figure 0003660548
を可変長符号あるいは算術符号にて符号化データに出力することとなる。
【0030】
同様な方法によりHL帯域のサブツリーであるサブツリー(b)を符号化すると、HL2帯域内の二つの係数をZTR符号で符号化することとなり、結果として以下の符号、即ち
Figure 0003660548
を可変長符号あるいは算術符号にて符号化データに出力することとなる。
【0031】
さらに、同様な方法でHH帯域のサブツリーであるサブツリー(c)を符号化する。HH3帯域内の量子化後係数は”0”であり、該量子化後係数の4つの子は全て”0”であり、さらに該4つの子に派生するサブツリーも全て”0”であるため、サブツリー(c)は一つのゼロツリー符号で置換することができる。故に、
・HH3帯域 (ZTR)
の符号のみを符号化データに出力すれば良い。
【0032】
以上の例では、LH内のサブツリー、HL内のサブツリー、HH内のサブツリーと、順に各サブツリー毎に符号化データに出力したが、実際には多様な解像度及び画質を段階的に出力する機能(スケーラビリティ)を有する符号化データを生成するために、これらを図6に示すように、インターリーブさせて符号化データに出力するのが一般的である。なお、水平方向の周波数帯域であるHL帯域は先に述べたように縦方向の係数間に冗長性があるため、スキャンを縦方向に行うのが一般的である。
【0033】
【発明が解決しようとする課題】
以上説明したゼロツリー符号化はそれなりの符号化効率を有する方式であるが、ゼロツリー符号化の符号体系には幾つかの冗長性があると考えられる。
【0034】
(a)IZ符号とその子供の係数
IZ符号は、(1)符号化対象量子化後係数がゼロであり、(2)符号化対象量子化後係数以下のサブツリー中の係数の中に一つ以上有意係数が存在することを示す符号である。従って、IZ符号の4つの子供が全てZTRである可能性はない。しかし、実際にはIZ符号の4つの子供が全てZTRとなっている符号化データを復号器で復号することが可能である。符号化器から出力されることのあり得ない符号を復号器が復号可能と言うことは、符号体系に冗長性があることとなる。
【0035】
(b)親係数の絶対値の大きさに関係なく4つの子供の係数を符号化する
ゼロツリー符号化では、ある符号化対象の量子化後係数がゼロである場合、該量子化後係数以下のサブツリー中の量子化後係数が全てゼロである可能性が高くなる性質を利用して、これを一つのZTR符号に置き換えることで圧縮を行う。
【0036】
しかし、実際にはゼロの場合だけではなく、量子化後係数の絶対値(|LEVEL|)が小さければ小さい程、該量子化後係数の4つの子供をルートとするサブツリーがそれぞれZTRである可能性が高くなり、逆に量子化後係数の絶対値が大きい程、該量子化後係数の4つの子供がZTRである可能性か低くなる。しかし、従来のゼロツリー符号化ではこの性質を利用することが困難である。
【0037】
(c)符号化対象のシンボル数が少ない
先に示したように、ゼロツリー符号化において実際に可変長符号化を行うシンボルは、わずか3つである。これら3つのシンボルの発生頻度が各々2の階乗分の1で近似できる場合は良いが、実際にはそうではない。このため、該3つのシンボルを可変長符号化する際の平均符号長が、3つのシンボルのエントロピーと比較して著しく大きくなってしまう。
【0038】
以上述べたように、ウェーブレット変換係数をエントロピー符号化する際に、ゼロツリールート符号、孤立ゼロ符号、レベル符号を用いてゼロツリー符号化を行う方法が一般に利用されている。しかし、従来のゼロツリー符号化にはその符号体系に冗長性があるという問題があった。また、可変長符号化を用いてゼロツリー符号化を行う場合には親の係数のレベルの大きさに応じて、子供のZTR符号の発生確率を動的に変更することは極めて困難であるという問題があった。
【0039】
本発明の目的は、入力画像信号を、サブバンド分割あるいはウェーブレット変換を用いて周波数帯域に分割し、算出された変換係数をエントロピー符号化する際に、上記問題点を解決し、符号化効率を改善できる画像符号化方法及び画像復号方法、画像符号化装置及び画像復号装置、並びにそれらのプログラムを記憶した媒体を提案することにある。
【0040】
【課題を解決するための手段】
上記の問題点を解決するため、本発明の請求項1では、入力画像あるいは動き補償予測差分画像を符号化対象信号として符号化する画像符号化方法において、符号化対象信号を、水平及び垂直の両方向について高域と低域に周波数帯域分割し、水平及び垂直の両方向に対しての低域成分を同様に再分割し、該再分割処理を再帰的にそれぞれ指定された回数繰り返すことで符号化対象信号変換係数を算出するステップと、該符号化対象信号変換係数をそれぞれ量子化して量子化後変換係数を算出するステップと、前記各周波数帯域間で空間的に相似な位置として対応する量子化後変換係数間で、垂直成分・水平成分・対角成分の各成分毎に、最低周波数帯域の係数を幹に持つ階層的な4分木構造であるツリーを形成するステップと、該ツリー中の各量子化後変換係数について、該量子化後変換係数及び該量子化後変換係数の全ての子孫が有意係数を持たない部分木であるゼロツリーを探索するステップと、前記ツリー内のある量子化後変換係数を符号化するに当たり、該量子化後変換係数の直接の子供係数のうち、該子供係数を幹とする部分木がゼロツリーである個数を示すZカウントを算出するステップと、該量子化後変換係数の絶対値及びZカウントからなる二次元可変長符号を符号化データに出力するステップとを有する画像符号化方法を提案する。
【0041】
また、本発明の請求項2では、上記請求項1記載の画像符号化方法において、ある量子化後変換係数を符号化するに当たり、該量子化後変換係数の絶対値がゼロでない場合は、前記二次元可変長符号を符号化データに出力した直後に、該量子化後変換係数の正負の符号を符号化データに出力する画像符号化方法を提案する。
【0042】
また、本発明の請求項3では、上記請求項1記載の画像符号化方法において、ツリーの幹以外の量子化後変換係数を符号化するに当たり、該量子化後変換係数の親係数の子供の係数を示す兄弟係数を検査し、該兄弟係数それぞれに対応する前記二次元可変長符号を符号化データに出力する前に、該兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を符号化データに出力する画像符号化方法を提案する。
【0043】
また、本発明の請求項4では、上記請求項3記載の画像符号化方法において、該兄弟係数のマップ符号を出力するに当たり、該兄弟係数の親係数を符号化した際に符号化データに出力済みの該兄弟係数のZカウントを参照し、該Zカウントの値が、該兄弟係数が全てゼロツリーの幹であるか、あるいは全てゼロツリーの幹ではないことを示している値である場合には前記マップ符号を符号化データに出力せず、該兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には前記マップ符号を符号化データに出力する画像符号化方法を提案する。
【0044】
また、本発明の請求項5では、上記請求項4記載の画像符号化方法において、親係数を符号化した際に符号化データに出力済みのZカウントが、兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合、Zカウントの値に対応するマップ符号用の可変長符号テーブルを用意しておき、前記親係数のZカウントに応じて該マップ符号用の可変長符号テーブルを切り替えて符号化する画像符号化方法を提案する。
【0045】
また、本発明の請求項6では、上記請求項3または4記載の画像符号化方法において、マップ符号を符号化データに出力した後に、前記親係数を符号化した際に符号化データに出力済みの兄弟係数のうちのゼロツリーの幹ではない係数の数だけ、該ゼロツリーの幹ではない係数の二次元可変長符号及び請求項2記載の条件に応じて前記正負の符号を符号化データに出力する画像符号化方法を提案する。
【0046】
また、本発明の請求項7では、上記請求項3記載の画像符号化方法において、該4つの兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を生成するに当たり、該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に該4つの兄弟係数がゼロツリーの幹であるかどうかを調べる画像符号化方法を提案する。
【0047】
また、本発明の請求項8では、上記請求項1乃至7いずれか記載の画像符号化方法による符号化データを復号する方法であって、
ある係数を復号対象係数として復号するに当たり、該復号対象係数の親係数を復号した際に復号済みの該復号対象係数の兄弟係数のZカウントを取り出すステップと、該兄弟係数のZカウントが、該兄弟係数の全てがゼロツリーの幹ではないかあるいは全てがゼロツリーの幹であることを示す場合は、マップ符号を復号せず、兄弟係数のうちのいくつかはゼロツリーの幹でいくつかはゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のZカウントの値に応じて可変長符号化テーブルを切り替えてマップ符号を復号するステップと、該マップ符号によりゼロツリーの幹ではないと示されている兄弟係数について、それぞれ、該兄弟係数の子供係数のZカウント及び復号対象係数の絶対値からなる二次元可変長符号を復号し、復号された該絶対値がゼロでない場合は該復号対象係数の正負の符号を復号し、該絶対値及び該正負の符号より復号係数値を算出し、同時に該兄弟係数の子供係数を復号する際に利用するために該Zカウントを記録するステップと、該マップ符号によりゼロツリーの幹であると示されている兄弟係数については、ゼロツリーの幹の場所情報を記録するステップと、それぞれ算出された兄弟係数の該復号係数値を該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に復号係数メモリに記録するステップとを有する画像復号方法を提案する。
【0048】
また、本発明の請求項9では、入力画像あるいは動き補償予測差分画像を符号化対象信号として符号化する画像符号化装置において、符号化対象信号を、水平及び垂直の両方向について高域と低域に周波数帯域分割し、水平及び垂直の両方向に対しての低域成分を同様に再分割し、該再分割処理を再帰的にそれぞれ指定された回数繰り返すことで符号化対象信号変換係数を算出する手段と、該符号化対象信号変換係数をそれぞれ量子化して量子化後変換係数を算出する手段と、前記各周波数帯域間で空間的に相似な位置として対応する量子化後変換係数間で、垂直成分・水平成分・対角成分の各成分毎に、最低周波数帯域の係数を幹に持つ階層的な4分木構造であるツリーを形成する手段と、該ツリー中の各量子化後変換係数について、該量子化後変換係数及び該量子化後変換係数の全ての子孫が有意係数を持たない部分木であるゼロツリーを探索する手段と、前記ツリー内のツリーの幹以外のある量子化後変換係数及び該量子化後変換係数の親係数の子供の係数を示す兄弟係数を符号化するに当たり、該兄弟係数を幹とする部分木がゼロツリーである個数を示すZカウントが、該兄弟係数が全てゼロツリーの幹であるかあるいは全てゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を符号化データに出力せず、該兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に該4つの兄弟係数がゼロツリーの幹であるかどうかを調べて、該兄弟係数のZカウントに応じて可変長符号化テーブルを切り替えつつ、該兄弟係数に対応するマップ符号を符号化データに出力する手段と、該兄弟係数のうちのゼロツリーの幹ではない変換係数に関し、該変換係数の直接の子供係数のZカウントを算出し、該変換係数の絶対値及びZカウントからなる二次元可変長符号を符号化データに出力する手段と、 該絶対値がゼロでない場合は、該二次元可変長符号の後に該変換係数の正負の符号を符号化データに出力する手段とを有する画像符号化装置を提案する。
【0049】
また、本発明の請求項10では、請求項9記載の画像符号化装置による符号化データを復号する装置であって、
ある係数を復号対象係数として復号するに当たり、該復号対象係数の親係数を復号した際に復号済みの該復号対象係数の兄弟係数のZカウントを取り出す手段と、該兄弟係数のZカウントが、該兄弟係数の全てがゼロツリーの幹ではないかあるいは全てがゼロツリーの幹であることを示す場合は、マップ符号を復号せず、兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のZカウントの値に応じて可変長符号化テーブルを切り替えてマップ符号を復号する手段と、該マップ符号によりゼロツリーの幹ではないと示されている兄弟係数について、それぞれ、該兄弟係数の子供係数のZカウント及び復号対象係数の絶対値からなる二次元可変長符号を復号し、復号された該絶対値がゼロでない場合は該復号対象係数の正負の符号を復号し、該絶対値及び該正負の符号より復号係数値を算出し、同時に該兄弟係数の子供係数を復号する際に利用するために該Zカウントを記録する手段と、該マップ符号によりゼロツリーの幹であると示されている兄弟係数については、ゼロツリーの幹の場所情報を記録する手段と、それぞれ算出された兄弟係数の該復号係数値を該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に復号係数メモリに記録する手段とを有する画像復号装置を提案する。
【0050】
また、本発明の請求項11では、入力画像あるいは動き補償予測差分画像を符号化対象信号として符号化する画像符号化プログラムを記憶した媒体であって、
前記プログラムはコンピュータに読み取られた際、該コンピュータ上に、
符号化対象信号を、水平及び垂直の両方向について高域と低域に周波数帯域分割し、水平及び垂直の両方向に対しての低域成分を同様に再分割し、該再分割処理を再帰的にそれぞれ指定された回数繰り返すことで符号化対象信号変換係数を算出する手段と、該符号化対象信号変換係数をそれぞれ量子化して量子化後変換係数を算出する手段と、前記各周波数帯域間で空間的に相似な位置として対応する量子化後変換係数間で、垂直成分・水平成分・対角成分の各成分毎に、最低周波数帯域の係数を幹に持つ階層的な4分木構造であるツリーを形成する手段と、該ツリー中の各量子化後変換係数について、該量子化後変換係数及び該量子化後変換係数の全ての子孫が有意係数を持たない部分木であるゼロツリーを探索する手段と、前記ツリー内のツリーの幹以外のある量子化後変換係数及び該量子化後変換係数の親係数の子供の係数を示す兄弟係数を符号化するに当たり、該兄弟係数を幹とする部分木がゼロツリーである個数を示すZカウントが、該兄弟係数が全てゼロツリーの幹であるかあるいは全てゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を符号化データに出力せず、該兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に該4つの兄弟係数がゼロツリーの幹であるかどうかを調べて、該兄弟係数のZカウントに応じて可変長符号化テーブルを切り替えつつ、該兄弟係数に対応するマップ符号を符号化データに出力する手段と、該兄弟係数のうちのゼロツリーの幹ではない変換係数に関し、該変換係数の直接の子供係数のZカウントを算出し、該変換係数の絶対値及びZカウントからなる二次元可変長符号を符号化データに出力する手段と、該絶対値がゼロでない場合は、該二次元可変長符号の後に該変換係数の正負の符号を符号化データに出力する手段とを構成する画像符号化プログラムを記憶した媒体を提案する。
【0051】
また、本発明の請求項12では、請求項9記載の画像符号化装置もしくはコンピュータ及び請求項11記載の画像符号化プログラムを記憶した媒体によって実現される画像符号化装置による符号化データを復号する画像復号プログラムを記憶した媒体であって、
前記プログラムはコンピュータに読み取られた際、該コンピュータ上に、
ある係数を復号対象係数として復号するに当たり、該復号対象係数の親係数を復号した際に復号済みの該復号対象係数の兄弟係数のZカウントを取り出す手段と、該兄弟係数のZカウントが、該兄弟係数の全てがゼロツリーの幹ではないかあるいは全てがゼロツリーの幹であることを示す場合は、マップ符号を復号せず、兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のZカウントの値に応じて可変長符号化テーブルを切り替えてマップ符号を復号する手段と、該マップ符号によりゼロツリーの幹ではないと示されている兄弟係数について、それぞれ、該兄弟係数の子供係数のZカウント及び復号対象係数の絶対値からなる二次元可変長符号を復号し、復号された該絶対値がゼロでない場合は該復号対象係数の正負の符号を復号し、該絶対値及び該正負の符号より復号係数値を算出し、同時に該兄弟係数の子供係数を復号する際に利用するために該Zカウントを記録する手段と、該マップ符号によりゼロツリーの幹であると示されている兄弟係数については、ゼロツリーの幹の場所情報を記録する手段と、それぞれ算出された兄弟係数の該復号係数値を該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に復号係数メモリに記録する手段とを構成する画像復号プログラムを記憶した媒体を提案する。
【0052】
本発明によれば、符号化対象係数の絶対値と、該符号化対象係数の子供係数を幹とするゼロツリーの個数を用いた二次元可変長符号化を用いて、ウェーブレット変換係数をエントロピー符号化することにより、符号体系に冗長性がない状態で符号化することができる。さらに、子供係数を幹とするサブツリーがZTRである場合、親係数の値の大きさに応じて、子供係数以下のサブツリーを効率的に打ち切ることが可能となり、エントロピー符号化の符号化効率を改善することが可能となる。
【0053】
【発明の実施の形態】
以下、本発明の実施の形態について説明する。
【0054】
図7は本発明に関わる画像符号化方法及び装置の全体を示すもので、図中、1はウェーブレット変換部、2は量子化部、3は係数符号化部、4はスキャン部である。
【0055】
入力画像あるいは動き補償予測差分画像等の符号化対象信号5は、ウェーブレット変換部1にて、水平及び垂直の両方向について高域と低域に周波数帯域分割され、水平及び垂直の両方向に対しての低域成分が同様に再分割され、該再分割処理が再帰的にそれぞれ指定された回数繰り返されることで符号化対象信号変換係数6として出力される。符号化対象信号変換係数6は、量子化部2にて量子化され、量子化後変換係数7として係数符号化部3に出力される。
【0056】
スキャン部4では最低周波数帯域LLから順に、高周波数帯域HL1,LH1,HH1の方向にスキャンを行い、そのスキャンの過程でその係数位置を符号化対象係数位置8として同様に係数符号化部3に出力する。各周波数帯域内での係数スキャンの順番は、以下の4つの条件を満たしてスキャンを行う。
【0057】
1.各周波数帯域内では、最低周波数帯域LL内の変換係数をルートとする同一のツリーに属する係数群を一単位としてスキャンする。
【0058】
2.該同一ツリー内の係数の中でも、各4つの兄弟係数をひとまとめにしてスキャンする。
【0059】
3.該4つの兄弟係数内の中では、
・垂直方向の周波数帯域では、左上、右上、左下、右下の順
・水平方向の周波数帯域では、左上、左下、右上、右下の順
・対角方向の周波数帯域では、左上、右下、右上、左下あるいは左上、右下、左下、右上の順
に係数をスキャンする。
【0060】
4.各4つの兄弟係数間及び同一ツリーに属する係数群間は、
・垂直方向の周波数帯域では、水平方向に
・水平方向の周波数帯域では、垂直方向に
優先してスキャンを行う。
【0061】
スキャンの一例を、図8に示す。厳密に図8に示す順に係数をスキャンする必要はないが、少なくとも先に示したスキャンの条件を満たし、かつ画像符号化装置及び画像復号装置で同じ順にスキャンを行えば良い。
【0062】
係数符号化部3では、入力された量子化後変換係数7を、符号化対象係数位置8に示される順にスキャンしながら符号化し、符号化データ9として出力する。
【0063】
本発明における符号化処理は、係数符号化処理を行う係数符号化部3に関わるものであり、ウェーブレット変換部1及び量子化部2は、従来と同様の手法で良い。従って、以下、係数符号化部3について説明する。なお、ウェーブレット変換による周波数帯域の再帰分割処理を3回行う場合を想定して説明するが、一般に、帯域分割の回数をN回とした場合も本発明を同様に適用できることは明白である。
【0064】
図9は本発明による係数符号化処理及び係数符号化部の実施の形態の一例を示すもので、図中、11はゼロツリー生成部、12はゼロツリーメモリ、13は絶対値・符号分離部、14は二次元可変長符号化部、15は選択器、16は子供係数位置算出部、17は子供係数検査部、18はマップ符号生成部、19は遅延器、20は多重化部である。
【0065】
前述した量子化後変換係数7は、ゼロツリー生成部11に入力される。ゼロツリー生成部11では、まず、各周波数帯域間で空間的に相似な位置として対応する量子化後変換係数間で、垂直成分・水平成分・対角成分の各成分毎に、図4に示したような最低周波数帯域の係数をルートに持つ階層的なツリーをそれぞれ形成する。そして、該ツリー中の任意の変換係数について、該変換係数をルートとするサブツリーが全てゼロであるサブツリーを探索する。この探索処理を最低周波数帯域の係数をルートに持つ全てのツリー中の全変換係数に関して行い、どの変換係数がゼロツリーのルート係数(ゼロツリールート)であるか、あるいは既にゼロツリーにより打ち切られている係数であるかを示す情報をゼロツリー情報21として、ゼロツリーメモリ12に出力する。
【0066】
同時に、量子化後変換係数7及びスキャン部4より与えられる符号化対象係数位置8が、絶対値・符号分離部13に入力される。絶対値・符号分離部13では、量子化後変換係数7のうちの符号化対象係数位置8の位置にある変換係数が取り出され、これを符号化対象係数として符号化するに当たり、該符号化対象係数の絶対値が絶対値22として二次元可変長符号化部14に、該符号化対象係数の正負の符号が符号23として選択器15に出力される。
【0067】
符号化対象係数位置8は、子供係数位置算出部16にも入力され、ここで該符号化対象係数の子供係数の位置が算出され、子供係数位置24は子供係数検査部17に出力される。該符号化対象係数の属する周波数帯域毎に異なるが、一つの親に対し子供係数位置24としては3つあるいは4つの係数位置が示される。
【0068】
同様に、子供係数検査部17には、ゼロツリーメモリ12より、量子化後変換係数7のゼロツリーの情報であるゼロツリー情報25が入力され、該ゼロツリー情報25のうち、該子供係数位置24により示される位置にあるゼロツリー情報を子供係数ゼロツリー情報として取り出す。そして、該子供係数ゼロツリー情報のうち、ゼロツリールートである個数をZカウント26として二次元可変長符号化部14に出力し、同時にどの子供係数がゼロツリールートで、どの子供係数がゼロツリールートでないか等の情報を、子供係数マップ情報27としてマップ符号生成部18に出力する。
【0069】
この時、該子供係数のスキャンの順は、各水平・垂直・対角方向の周波数帯域内の係数間の特性を利用するため、該子供係数が、垂直方向の周波数帯域内の時は左上、右上、左下、右下の順、水平方向の周波数帯域内の時は左上、左下、右上、右下の順、対角方向の周波数帯域内の時は左上、右下、右上、左下あるいは左上、右下、左下、右上の順とする。
【0070】
マップ符号生成部18では、入力された子供係数マップ情報27を元に子供係数の符号化の際に出力するマップ符号28を生成する。表1はマップ符号の符号化テーブルの一例を示すもので、子供係数が4つある帯域に対応する。マップ符号の符号化テーブルは、Zカウントの値毎に用意されており、該符号化対象係数の兄弟係数のZカウントに応じて、該兄弟係数のZカウントに対応する符号化テーブルを切り替えて用いてマップ符号を生成する。また、Zカウントが2の場合は兄弟係数のスキャン順を水平方向・垂直方向・対角方向の周波数帯域毎に各周波数帯域の特性を利用したスキャンを行っているため、マップ符号map4[0,0,1,1]、map4[1,1,0,0]には短い符号長の符号を割り当てることができる。また、Zカウントが”0”、即ち兄弟係数の全てがゼロツリールートではない場合、あるいはZカウントが“4”、即ち兄弟係数の全てがゼロツリールートである場合は、マップ符号を出力する必要はなく、マップ符号31として空の符号を出力する。表1では”符号化不要”と表した。
【0071】
【表1】
Figure 0003660548
【0072】
該符号化テーブルを用いて算出されたマップ符号28は、該符号化対象係数の子供係数を符号化する時に多重化して符号化データに出力するため、遅延器19に出力しておく。
【0073】
二次元可変長符号化部14では、絶対値・符号分離部13より入力された絶対値22及び子供係数検査部17より入力されたZカウント26を二次元可変長符号化データ29として符号化し、多重化部20に出力する。LH1,2,HL1,2,HH1,2帯域等、子供係数が4つある帯域を符号化する際に用いる二次元可変長符号(TDVLC4)の例を表2に示す。表2には、絶対値がゼロでZカウントが4つ、即ちゼロツリールートの場合の二次元可変長符号を示していない。しかし、ゼロツリーの場所は、親係数を符号化した際のZカウントと、該二次元可変長符号の前に符号化するマップ符号により一意に特定可能であるため、ゼロツリールートの符号を用意する必要がないためである。
【0074】
【表2】
Figure 0003660548
【0075】
選択器15では、絶対値22により示される該符号化対象係数の絶対値がゼロではない場合、符号23により示される該符号化対象係数の正負の符号を、正負符号データ30として多重化部20に出力する。
【0076】
多重化部20では、遅延器19より入力されるマップ符号31、二次元可変長符号化データ29、そして正負符号データ30を多重化して符号化データ9として出力する。遅延器19を介して入力されるマップ符号31は該符号化係数を含む兄弟符号のゼロツリー情報が含まれており、二次元可変長符号化データ29及び正負符号データ30は該符号化係数を含む兄弟符号毎の符号化データである。
【0077】
多重化部20では、以下の手順で多重化を行う。
【0078】
・符号化対象係数の親係数を符号化する際に算出されたマップ符号31を符号化データに出力。(親係数のZカウントの値が、兄弟係数の全てがゼロツリールートであるか、あるいは全てがゼロツリールートでないことを示す値である場合には、先に述べたようにマップ符号31には何も入っていない)
・マップ符号31により、ゼロツリールートではないと判断される各兄弟係数毎に以下の2つの符号化データを順に符号化データに出力。(符号化対象係数の絶対値がゼロである場合には、選択器15により正負符号データ30には何も入っていない)
−二次元可変長符号化データ29
−正負符号データ30
従って、以下の4係数からなる、垂直方向の周波数帯域内のある兄弟係数を符号化すると、図10に示す多重化された符号を符号化データとして出力することとなる。
【0079】
1.左上がZTR、
2.右上の量子化後変換係数が−1で、子供係数のZカウントが4つ、
3.左下の量子化後変換係数が3で、子供係数のZカウントが0、
4.右下の量子化後変換係数が0で、子供係数のZカウントが3つ
この例では、表1及び表2に示した符号化テーブルを用いている。
【0080】
以下、本発明を用いて図5に示した変換係数ツリーを符号化する例を示す。
【0081】
・LL3帯域内の係数
LL帯域内の符号化対象である量子化後変換係数は”+3”であり、3つの子供係数のうち、HH3帯域内の子供係数がZTRである。本方式では、量子化後変換係数の絶対値と、該量子化後変換係数の子供の係数のうちの該子供係数が幹となるゼロツリーである個数、即ちZカウントからなる、二次元可変長符号(TDVLC3[変換係数の絶対値,Zカウント])を符号化データに出力する。TDVLC3は兄弟係数が3つの場合の二次元可変長符号であり、表2に示したTDVLC4とは別に画像符号化装置/画像復号装置に用意しておく。但し、LL係数には親係数が存在しないため、親係数でZカウントを符号化していない。従って、TDVLC4とは異なり、TDVLC3は絶対値が0で、3つの子供が全てゼロツリールートである符号も用意しておく必要がある。
【0082】
また、該二次元可変長符号を符号化データに出力した後に、該量子化後変換係数の正負の符号を出力する。”+3”の符号は正であるため、正の符号を出力する。以下、正の符号をPOS、負の符号をNEGと記載する。従って、本例では、LL帯域の符号化に当たり、
(TDVLC3[3,1])(POS)
という符号を出力する。
【0083】
・LH3,HL3,HH3帯域内の係数
LH3帯域内の符号化対象である量子化後変換係数は”+3”である。HL3帯域内の符号化対象である量子化後変換係数は”0”である。HH3帯域内の符号化対象である量子化後変換係数は”0”であり、また、ゼロツリールートである。
【0084】
また、LL3帯域内にある上記3係数の親係数を符号化する際に出力したZカウントは1である。従って、マップ符号としてmap3[0,0,1]を出力する。表3はマップ符号用map3[]の符号化テーブルの一例を示しており、兄弟係数が互いに3つあるLH3,HL3,HH3帯域を符号化する際に用いる。
【0085】
なお、該Zカウントが3の時は3つの兄弟係数が全てゼロツリールートであることを示し、また、該Zカウントが0の時は3つの兄弟係数が全てゼロツリールートでないことを示すため、マップ符号を符号化データに出力する必要はない。
【0086】
【表3】
Figure 0003660548
【0087】
次に、LH3,HL3,HH3帯域内の3係数に対応する二次元可変長符号を出力する。
【0088】
LH3内の符号化対象係数は”+3”であり、4つの子供のうち、ZTRは一つであるため、TDVLC4[3,1]及び正の符号POSを出力する。
【0089】
HL3内の符号化対象係数は”0”であり、4つの子供のうち、ZTRは二つであるため、TDVLC4[0,2]を出力する。該符号化対象係数の絶対値はゼロであるため、正負の符号を出力する必要はない。
【0090】
HH3内の符号化対象係数は、親係数を符号化した際のZカウント及び先に出力したマップ符号により、既に符号化済みである。
【0091】
従って、本例では、LH3,HL3,HH3帯域の符号化に当たり、
map3[0,0,1]
(TDVLC4[3,1])(POS)
(TDVLC4[0,2])
という符号を出力する。なお、二次元可変長符号TDVLC4として、表2に示した符号化テーブルを用いる。
【0092】
・LH2,HL2,HH2帯域内の係数
LH2帯域内の係数を符号化するに当たり、LH3帯域内に存在する親係数を符号化した際に出力したZカウントは”1”であり、また、LH2帯域内の兄弟係数のうちのゼロツリールートは右下の係数である。また、LH3周波数帯域は垂直方向の周波数帯域であるため、左上、右上、左下、右下の順に兄弟係数をスキャンする。さらに、左上の係数の子供係数のZカウントは2、右上の係数の子供係数のZカウントは3、左下の係数の子供係数のZカウントは1である。
【0093】
同様にHL2帯域については、HL3帯域内に存在する親係数を符号化した際に出力したZカウントは”2”であり、また、HL2帯域内の兄弟係数のうちのゼロツリールートは左上及び右上の係数である。HL3周波数帯域は水平方向の周波数帯域であるため、左上、左下、右上、右下の順に兄弟係数をスキャンする。さらに、左下の係数の子供係数のZカウントは1、右下の係数の子供係数のZカウントは3である。
【0094】
同様にHH2帯域については、HH3帯域の時と同様、既にゼロツリーにより打ち切られているため、符号化不要である。
【0095】
従って、本例では、LH2,HL2,HH2帯域の符号化に当たり、
map4[0,0,0,1]
(TDVLC4[1,2])(NEG)
(TDVLC4[0,3])
(TDVLC4[0,1])
map4[1,0,1,0]
(TDVLC4[1,1])(NEG)
(TDVLC4[0,3])
という符号を出力する。マップmap4[]は、表1に示した符号化テーブルを用いる。
【0096】
・LH1,HL1,HH1帯域内の係数
LH1,HL1,HH1帯域内の係数には子供係数が存在しないため、絶対値と子供係数のZカウントの二次元可変長を用いる本発明を適用して符号化を行うことはできない。従って、従来のゼロツリー符号化と同様の絶対値を入力シンボルとする一次元可変長符号を用いて符号化を行う。但し、ゼロツリー符号化とは異なり、親係数の符号化の際に兄弟係数のゼロツリーの数は符号化データに記述済みであるため、マップ符号と前記一次元可変長符号を用いて符号化すれば良い。
【0097】
具体的には、
・LH1帯域
map4[1,0,0,1],
(LEVEL,1),(LEVEL,2),
map4[0,1,1,1],
(LEVEL,-2),
map4[1,0,0,0],
(LEVEL,-1),(LEVEL,3),(LEVEL,1)
・HL1帯域
map4[1,0,0,0],
(LEVEL,-2),(LEVEL,-1),(LEVEL,1),
map4[0,1,1,1],
(LEVEL,-1)
・HH1帯域
符号化不要
という符号を出力する。
【0098】
次に、本発明による画像復号処理について詳細に説明する。
【0099】
図11は本発明に関わる画像復号方法及び装置の全体を示すもので、図中、41は係数復号部、42は逆量子化部、43はウェーブレット逆変換部である。
【0100】
画像復号装置では、まず、始めに符号化データ44が係数復号部41に入力され、復号処理が行われて、量子化後変換係数45が出力される。量子化後変換係数45は逆量子化部42に入力され、画像符号化装置の量子化部2での処理に対応する逆量子化が行われ、復号変換係数46がウェーブレット逆変換部43に出力される。
【0101】
ウェーブレット逆変換部43では、ウェーブレット最大分割回数47により示される回数に従って、復号変換係数46に対して逆ウェーブレット変換が再帰的に行われ、復号信号48が出力される。ウェーブレット再帰分割回数47は、画像符号化装置・画像復号装置において前もって回数を決定しておくことで、符号化データ44に記載する必要はなくなる。
【0102】
本発明における復号処理は、係数復号処理を行う係数復号部41に関わるものであり、逆量子化部42及びウェーブレット逆変換部43は、従来と同様の手法で良い。従って、以下、係数復号部41について説明する。
【0103】
図12は本発明による係数復号処理及び係数復号部の実施の形態の一例を示すもので、図中、51は分離部、52は選択器、53はゼロツリーメモリ、54は二次元可変長復号部、55は遅延器、56は絶対値・符号合成部、57は選択器、58は係数メモリ、59はスキャン部、60はマップ符号復号部、61は子供係数位置算出部である。
【0104】
入力された符号化データ44は分離部51に入力され、マップ符号データ71、絶対値データ72及び正負の符号73に分離される。
【0105】
絶対値データ72は選択器52に入力される。選択器52では、ゼロツリーメモリ53より入力されるゼロツリー情報74により、ゼロツリーにより既に符号済みの係数でない場合は絶対値データ72を二次元可変長復号部54に出力する。
【0106】
二次元可変長復号部54では、表2等の画像符号化装置と共通の二次元可変長符号の符号化テーブルを用いて復号を行い、Zカウント75を遅延器55に、絶対値76を絶対値・符号合成部56に出力する。
【0107】
正負の符号73は選択器57に入力される。選択器57は、ゼロツリー情報74により現在復号している係数がゼロツリーにより既に符号化済みではなく、かつ絶対値76がゼロでない場合は、正負の符号73を絶対値・符号合成部56に出力する。
【0108】
絶対値・符号合成部56では、絶対値76及び正負の符号73より復号係数77を算出し、これを係数メモリ58に出力する。
【0109】
係数メモリ58では、スキャン部59より出力される復号係数位置78により示される位置に復号係数77を記録し、復号が全ての係数について終了した後に、量子化後変換係数45として出力する。
【0110】
スキャン部59は画像符号化装置におけるスキャン部4と同様な順でスキャン位置を算出する回路であり、スキャン部59より出力される復号係数位置78は画像符号化装置における符号化対象係数位置8と同様の種類の値である。
【0111】
マップ符号データ71は、マップ符号復号部60に入力され、Zカウント79に応じて可変長符号化テーブルを切り替えて用いてマップ符号80を復号する。ここにおいてZカウント79は遅延器55より入力されており、先に親係数を二次元可変長復号部54にて復号した際の子供係数のZカウント、即ち現在復号している係数の兄弟係数のZカウントである。
【0112】
マップ符号復号部60では、係数符号化部におけるマップ符号生成部18における処理に対応する処理を行う。Zカウント79が”0”、即ち兄弟係数の全てがゼロツリールートではない場合、あるいはZカウント79が兄弟係数の全てがゼロツリールートであることを示す場合は、マップ符号データ71を復号することなくマップ符号80を生成し、ゼロツリーメモリ53に出力する。それ以外の場合、即ちZカウント79が兄弟係数のうちのいくつかはゼロツリールートで、いくつかはゼロツリールートではないことを示している値である場合には、マップ符号データ71を復号し、マップ符号80をゼロツリーメモリ53に出力する。
【0113】
また、復号係数位置78は同時に子供係数位置算出部61に入力され、ここで係数符号化部における子供係数位置算出部16と同様に子供係数の位置が算出され、子供係数位置81としてゼロツリーメモリ53に出力する。
【0114】
ゼロツリーメモリ53では、子供係数位置81の位置にマップ符号80に従いゼロツリー情報を記録し、後に子供係数を復号する際に用いる。この時、該兄弟係数が属する周波数帯域が垂直方向の周波数帯域の時は左上、右上、左下、右下の順、水平方向の周波数帯域の時は左上、左下、右上、右下の順、対角方向の周波数帯域の時は左上、右下、右上、左下あるいは左上、右下、左下、右上の順に前記ゼロツリー情報をゼロツリーメモリ53に記録する。さらに、ゼロツリールートである係数の子孫には、既に符号化済みであるという情報を記録しておく。
【0115】
なお、本発明は、コンピュータ読み取り可能な媒体であって、コンピュータに読み取られた時、該コンピュータ上に、図7及び図9並びに図10及び図11に示した装置を構成するプログラム(ソフトウェア)を記憶した媒体によっても実現可能である。
【0116】
【発明の効果】
J.M.Shapiroらによる従来のゼロツリー符号化では、その符号体系に冗長性があり、親の係数のレベルの大きさに応じて、子供のZTR符号の発生確率を動的に変更することは、極めて困難である。
【0117】
これに対して、本発明によれば、その存在自体が冗長である孤立ゼロ符号を用いる必要がなく、また、親係数の絶対値に応じて子供係数にゼロツリールートが発生する確率が変動する特性を効率的に利用して符号化を行えるため、符号化効率を改善することが可能となる。
【図面の簡単な説明】
【図1】離散ウェーブレット変換の概要を示す説明図
【図2】画像のオクターブ分割のようすを示す説明図
【図3】分解フィルタ及び合成フィルタの係数の相互関係を示す説明図
【図4】画像の二次元オクターブ分割のようすを示す説明図
【図5】ゼロツリー符号化を用いた符号化の一例を示す説明図
【図6】スケーラビリティを有する符号化データの生成のようすを示す説明図
【図7】本発明に関わる画像符号化方法及び装置全体の実施の形態の一例を示す構成図
【図8】本発明によるスキャンの一例を示す説明図
【図9】本発明の係数符号化部の実施の形態の一例を示す構成図
【図10】符号化データ出力の一例を示す説明図
【図11】本発明に関わる画像復号方法及び装置全体の実施の形態の一例を示す構成図
【図12】本発明の係数復号部の実施の形態の一例を示す構成図
【符号の説明】
1:ウェーブレット変換部、2:量子化部、3:係数符号化部、4:スキャン部、11:ゼロツリー生成部、12:ゼロツリーメモリ、13:絶対値・符号分離部、14:二次元可変長符号化部、15:選択器、16:子供係数位置算出部、17:子供係数検査部、18:マップ符号生成部、19:遅延器、20:多重化部、41:係数復号部、42:逆量子化部、43:ウェーブレット逆変換部、51:分離部、52:選択器、53:ゼロツリーメモリ、54:二次元可変長復号部、55:遅延器、56:絶対値・符号合成部、57:選択器、58:係数メモリ、59:スキャン部、60:マップ符号復号部、61:子供係数位置算出部。[0001]
BACKGROUND OF THE INVENTION
The present invention relates to an image encoding method and an image decoding method, an image encoding device and an image decoding device, and a medium storing those programs.
[0002]
[Prior art]
Conventionally, DCT (discrete cosine transform) has been widely used for compression coding of still images or moving images. However, image coding by DCT has a certain image quality degradation such as block distortion in which the boundary of the block, which is a unit of conversion processing, becomes discontinuous, and mosquito noise generated around a steep edge portion at a compression rate of a certain level or more. Was a problem in subjective image quality. As an encoding method for avoiding these problems, a discrete wavelet transform (I. Daubechies, “Orthonormal bases of compatible supported waves”, Comm. Pure Appl. Math, vol. 41, pp. 909-996, 1988) is used. Various encoding methods have been studied.
[0003]
The discrete wavelet transform decomposes an image into frequency band components having different resolutions, similar to hierarchical subband division. The total number of decomposed transform coefficients is the same as the number of pixels of the original image, but generally the signal energy is concentrated on lower frequency components.
[0004]
The wavelet transform coefficient is obtained by a one-dimensional filter bank and subsampling processing. As shown in FIG. 1A, the low-pass filter H in the horizontal direction of the image X (z) l (Z) and high-pass filter H h (Z) The output is obtained and the output is thinned out to 1/2 (↓ 2). Furthermore, by applying the same processing in the vertical direction, the four component LL 1 , LH 1 , HL 1 , HH 1 Is broken down into
[0005]
Of these, the lowest frequency component LL 1 LL 2 , LH 2 , HL 2 , HH 2 Re-disassemble into By repeating this process for the required number of levels, the octave division of the image as shown in FIG. 2 can be obtained. In the reproduction process, as shown in FIG. i + 1 , LH i + 1 A zero value is inserted (↑ 2) between each coefficient in the vertical direction, and the synthesis filter F is respectively inserted in the vertical direction. l (Z), F h Multiply (z) to find the sum of their outputs. Similar processing in the horizontal direction HL i + 1 , HH i + 1 To ingredients. That is, by performing the same filtering process in the horizontal direction on the obtained two components, LL i The ingredients are synthesized.
[0006]
By repeating this synthesis process for the required number of levels, the reproduction value of the image can be obtained. In order for the image to be completely reconstructed,
H l (Z) H h (−z) + H l (−z) H h (Z) = c (1)
F l (Z) = (2 / c) H h (-Z) (2)
F h (Z) = (2 / c) H l (-Z) (3)
It must meet the condition. Here, the tap length of the decomposition / synthesis filter is an odd number, and c is an arbitrary constant. FIG. 3 shows the mutual relationship between the decomposition and synthesis filter coefficients.
[0007]
Wavelet transform coefficients obtained by applying horizontal / vertical wavelet transform to the input image signal are quantized and encoded. Generally, the same level of high frequency band (HL m , LH m , HH m , M ∈ natural number) is quantized by the same quantization step, and the wavelet transform coefficient after quantization is variable-length coded using Run-Length coding, Run-Level coding, etc., and the generated code Reduce the amount.
[0008]
At this time, wavelet transform coefficient values in other high frequency bands except the lowest frequency band LL can be approximated by a Laplace distribution concentrated in the vicinity of zero. Scalar quantization with center dead zone is used. Note that the LL band is rough, and when the quantization is performed, visually disturbing distortion is conspicuous in the decoded image. Therefore, a method of performing lossless encoding using DPCM without performing quantization is common.
[0009]
As for the encoding method of wavelet transform coefficients, an encoding method using the fact that there is a correlation between coefficients at similar positions in each frequency band has been proposed. In the two-dimensional octave division using the wavelet, it is decomposed into four components of LL, LH, HL, and HH by one level decomposition, and when M level division is performed, the lowest frequency band LL is obtained. M From the ingredients, LH 1 , HL 1 , HH 1 It is decomposed into (3M + 1) components up to components. FIG. 4 shows an example of frequency band division when M = 3.
[0010]
The divided frequency band signals include LL, LH, HL, and HH frequency bands as shown in FIG.
[0011]
The LL band is a low-frequency signal in the horizontal and vertical directions, and is a signal obtained by applying a two-dimensional low-pass filter (LPF) to an image (hereinafter referred to as “low-frequency component” or “lowest frequency band”). There is.) The HL band is a signal obtained by applying a high-pass filter (HPF) in the horizontal direction and a low-pass filter in the vertical direction, and an edge component in the vertical direction appears (hereinafter sometimes referred to as “horizontal component”). The LH band is a signal obtained by applying a low-pass filter in the horizontal direction and a high-pass filter in the vertical direction, and an edge component in the horizontal direction appears (hereinafter sometimes referred to as “vertical component”). The HH band is a signal obtained by applying a high-pass filter in both the horizontal and vertical directions, and an edge component in an oblique direction appears (hereinafter sometimes referred to as “diagonal component”).
[0012]
In order to eliminate the data redundancy due to the self-similarity described above, the LH obtained by the i-level division i , HL i , HH i And (i-1) level LH i-1 , HL i-1 , HH i-1 The parent-child relationship is defined between the transform coefficients at spatially similar positions to the respective transform coefficients. In the parent-child relationship between the high-frequency components, four coefficients (children and child coefficients) correspond to one coefficient (parent, parent coefficient). In addition, the lowest frequency band LL M Exceptionally LH for in-band conversion coefficients M , HL M , HH M Three transform coefficients at the same position as the transform coefficient in the band correspond to three children. Accordingly, in this parent-child relationship, each conversion coefficient in the lowest frequency band LL is a trunk (hereinafter sometimes referred to as “root”), and the similarity is similar from the low-frequency side with a coarse resolution toward the high-frequency side with a fine resolution. Branches (hereinafter sometimes referred to as “nodes”) are generated for transform coefficients at various positions, and a tree structure (hereinafter also referred to as “tree”) as shown in FIG. 4 is generated. The
[0013]
First, the transform coefficient corresponding to the node in the reverse direction of each transform coefficient, that is, the node in the root direction is called a parent or parent coefficient, and the transform coefficient corresponding to the forward node of each transform coefficient is a child or child. Alternatively, it is defined as a child coefficient, but here, some words are defined below regarding the tree structure based on the parent-child relationship.
[0014]
The child coefficient of the parent coefficient of each transform coefficient is called a sibling or sibling coefficient. For example, HH in FIG. 2 Of the four coefficients indicated by hatching in the band, the four coefficients are sibling coefficients when viewed from an arbitrary coefficient. Each transform coefficient from the transform coefficient to the last node in the forward direction, such as the child of each transform coefficient and the child of the child, is called a descendant.
[0015]
For example, HH Three HH from the coefficient indicated by hatching in the band 2 4 coefficients indicated by hatching in the band and HH 1 The 16 coefficients indicated by hatching within the band are descendants. Further, a coefficient group constituted by an arbitrary transform coefficient in a certain tree and all transform coefficients below the transform coefficient is defined as a subtree. The sub-tree is “transformation coefficient + descendant of the transform coefficient”.
[0016]
As a method for performing entropy coding on wavelet transform coefficients using the coefficient tree between the frequency bands defined above, zero tree coding (J. M. Shapiro, “Embedded image coding using wavelet coefficients”, IEEE Trans. Signal Processing, vol. 41, pp. 3445-3462, Dec. 1993) has been proposed.
[0017]
In the zero tree coding, when quantizing each transform coefficient in a certain subtree results in all the quantized coefficients being zero, the subtree is referred to as a zero tree, and the subtree is referred to as one zero tree root (Zero Tree Root: Data compression is performed by substituting for the ZTR code.
[0018]
The subtree replaced with the ZTR code is already encoded at this point, and the descendants of the ZTR code need not be encoded later. Contrary to the ZTR code, if a quantized value of a certain transform coefficient itself is zero, but there is one significant coefficient as a descendant coefficient of the transform coefficient, the transform coefficient is set to an isolated zero ( It outputs to encoded data as an Isolated Zero (IZ) code. In addition, when the transform coefficient to be encoded is a significant coefficient, neither of the conditions of the ZTR code and the IZ code is met. In this case, a code (LEVEL code) indicating that the transform coefficient is a significant coefficient is output, and the value of the significant coefficient is output as encoded data.
[0019]
Therefore, the symbols that actually perform variable length coding in zero tree coding are:
・ ZTR code
・ IZ code
-LEVEL code + quantized coefficient value
It is a code of three kinds of amount.
[0020]
In FIG. 5, using zero tree coding, LL Three An example of encoding a tree rooted at a certain transform coefficient in the band is shown. Each transform coefficient in the figure is a value after the wavelet transform coefficient is quantized, and subtree (a) is an LH band, subtree (b) is an HL band, and subtree (c) is a subtree in the HH band.
[0021]
First, LL Three Since the coefficient is “+3”, the LEVEL code is output and the value “+3” is output, that is,
・ LL3 band (LEVEL, 3)
Is output.
[0022]
When encoding the subtree (a) which is a subtree of the LH band, encoding is performed by the following steps.
[0023]
・ LH Three In-band coefficient
Since the quantized coefficient is “3” and is a significant coefficient, the LEVEL code and “+3” are encoded.
[0024]
・ LH 2 In-band coefficient
-Since the quantized coefficient at the upper left is "-1" and is a significant coefficient, the LEVEL code and "-1" are encoded.
[0025]
-The quantized coefficient in the upper right is "0", but the significant coefficient "-2" is included in the coefficients of the four children of the coefficient. Therefore, the IZ code is output as encoded data.
[0026]
-The quantized coefficient in the lower left is "0", but the significant coefficients "-1, 3, 1" are included in the coefficients of the four children of the coefficient. Accordingly, the IZ code is similarly output to the encoded data.
[0027]
-The quantized coefficient in the lower right is "0", and there is no significant coefficient in the sub-tree below the coefficient, so the ZTR code is output to the encoded data.
[0028]
・ LH 1 In-band coefficient
Of the 16 coefficients, the four lower-right coefficients have already been encoded by the higher-order ZTR code, so the other 12 coefficients are encoded in order.
[0029]
Actually, when subtree (a) is encoded by the above procedure, the following code is obtained as a result:
Figure 0003660548
Is output to the encoded data by a variable length code or an arithmetic code.
[0030]
When subtree (b), which is a subtree of the HL band, is encoded in a similar manner, HL 2 The two coefficients in the band will be encoded with the ZTR code, resulting in the following code:
Figure 0003660548
Is output to the encoded data by a variable length code or an arithmetic code.
[0031]
Further, the subtree (c), which is a subtree of the HH band, is encoded by the same method. HH Three Since the quantized coefficients in the band are “0”, the four children of the quantized coefficients are all “0”, and the subtrees derived from the four children are all “0”. (C) can be replaced with one zerotree code. Therefore,
・ HH3 band (ZTR)
It is sufficient to output only the code of (1) to the encoded data.
[0032]
In the above example, the sub-tree in the LH, the sub-tree in the HL, the sub-tree in the HH, and the encoded data are output in order for each sub-tree. In order to generate encoded data having scalability, these are generally interleaved and output as encoded data as shown in FIG. Since the HL band, which is a frequency band in the horizontal direction, has redundancy between the coefficients in the vertical direction as described above, scanning is generally performed in the vertical direction.
[0033]
[Problems to be solved by the invention]
The zero tree coding described above is a method having a certain coding efficiency, but it is considered that there is some redundancy in the coding system of the zero tree coding.
[0034]
(A) IZ code and its child coefficient
The IZ code is a code indicating that (1) a coefficient to be encoded is zero and (2) one or more significant coefficients are present in coefficients in a subtree below the coefficient to be encoded. It is. Therefore, all four children of the IZ code are not likely to be ZTR. However, in practice, it is possible to decode the encoded data in which all four children of the IZ code are ZTR by the decoder. That the decoder can decode a code that cannot be output from the encoder means that the coding system has redundancy.
[0035]
(B) Encode the coefficients of four children regardless of the absolute value of the parent coefficient
In zero tree coding, when the quantized coefficient of a certain coding target is zero, using the property that the possibility that all the quantized coefficients in the sub-tree below the quantized coefficient are all zero is high, The compression is performed by replacing this with one ZTR code.
[0036]
However, not only in the case of zero, but the smaller the absolute value (| LEVEL |) of the quantized coefficient is, the smaller the subtree rooted at the four children of the quantized coefficient may be the ZTR. The higher the absolute value of the quantized coefficient, the lower the possibility that the four children of the quantized coefficient are ZTR. However, it is difficult to use this property with conventional zero tree coding.
[0037]
(C) The number of symbols to be encoded is small
As previously indicated, only three symbols are actually subjected to variable length coding in zero tree coding. It is good if the frequency of occurrence of these three symbols can be approximated by one factorial of 2, but this is not the case. For this reason, the average code length when the three symbols are subjected to variable-length coding becomes significantly larger than the entropy of the three symbols.
[0038]
As described above, when entropy encoding wavelet transform coefficients, a method of performing zero tree encoding using a zero tree root code, an isolated zero code, and a level code is generally used. However, the conventional zero tree coding has a problem that the coding system has redundancy. In addition, when zero-tree coding is performed using variable-length coding, it is extremely difficult to dynamically change the generation probability of a child's ZTR code according to the level of the coefficient of the parent. was there.
[0039]
An object of the present invention is to solve the above-described problems and improve the coding efficiency when an input image signal is divided into frequency bands using subband division or wavelet transformation and entropy coding is performed on the calculated transform coefficient. An object of the present invention is to propose an image encoding method and an image decoding method that can be improved, an image encoding device and an image decoding device, and a medium storing these programs.
[0040]
[Means for Solving the Problems]
In order to solve the above problems, according to claim 1 of the present invention, in an image encoding method for encoding an input image or a motion compensated prediction difference image as an encoding target signal, the encoding target signal is divided into horizontal and vertical signals. The frequency band is divided into high and low frequencies in both directions, and the low frequency components in both the horizontal and vertical directions are subdivided in the same way, and the subdivision process is recursively repeated for each specified number of times. A step of calculating a target signal transform coefficient, a step of quantizing each of the encoding target signal transform coefficients to calculate a post-quantization transform coefficient, and a quantization corresponding to a spatially similar position between the frequency bands Forming a tree having a hierarchical quadtree structure having a coefficient of the lowest frequency band as a trunk for each component of the vertical component, the horizontal component, and the diagonal component among the post-transform coefficients; For each post-quantization transform coefficient, searching for a zero tree that is a subtree in which all the descendants of the post-quantization transform coefficient and the post-quantization transform coefficient have no significant coefficient, and after a certain quantization in the tree In encoding the transform coefficient, a step of calculating a Z count indicating the number of sub-trees whose root is the child coefficient among the direct child coefficients of the quantized transform coefficient, The present invention proposes an image encoding method including a step of outputting a two-dimensional variable length code comprising an absolute value of a transform coefficient and a Z count to encoded data.
[0041]
According to claim 2 of the present invention, in the image coding method according to claim 1, when encoding a certain quantized transform coefficient, when the absolute value of the quantized transform coefficient is not zero, An image encoding method is proposed in which immediately after a two-dimensional variable length code is output as encoded data, a positive / negative code of the quantized transform coefficient is output as encoded data.
[0042]
According to claim 3 of the present invention, in the image encoding method according to claim 1, in encoding the quantized transform coefficient other than the trunk of the tree, the child coefficient of the parent coefficient of the quantized transform coefficient is encoded. A map indicating which of the sibling coefficients is the trunk of the zero tree before examining the sibling coefficients indicating the coefficients and outputting the two-dimensional variable length code corresponding to each sibling coefficient to the encoded data An image encoding method for outputting a code to encoded data is proposed.
[0043]
According to a fourth aspect of the present invention, in the image coding method according to the third aspect, when outputting the map code of the sibling coefficient, the parent coefficient of the sibling coefficient is output as encoded data. If the Z count value is a value indicating that the sibling coefficients are all zero tree trunks or not all zero tree trunks, the Z count of the sibling coefficients is referred to. The map code is not output to the encoded data, and the map code is encoded when some of the sibling coefficients are values indicating that they are zero tree trunks and some are not zero tree trunks. We propose an image coding method to output data.
[0044]
Further, according to claim 5 of the present invention, in the image encoding method according to claim 4, when the parent coefficient is encoded, the Z count that has been output to the encoded data is such that some of the sibling coefficients are zero trees. If there are some values indicating that they are not zero tree trunks, a variable length code table for the map code corresponding to the Z count value is prepared, and the Z count of the parent coefficient is set. Accordingly, an image encoding method is proposed in which the variable length code table for the map code is switched and encoded.
[0045]
According to claim 6 of the present invention, in the image encoding method according to claim 3 or 4, after the map code is output to the encoded data, the parent coefficient is encoded, and then the encoded data has already been output. 3. The two-dimensional variable length code of the coefficient that is not the trunk of the zero tree among the sibling coefficients of the zero tree, and the positive and negative codes are output to the encoded data according to the condition according to claim 2. An image coding method is proposed.
[0046]
According to claim 7 of the present invention, in the image encoding method according to claim 3, when generating a map code indicating which of the four sibling coefficients is a trunk of a zero tree, When two sibling coefficients are in the vertical band, the upper left, upper right, lower left, and lower right are ordered, and when the horizontal coefficient is in the horizontal band, the upper left, lower left, upper right, and lower right are ordered in the diagonal direction. An image encoding method is proposed for checking whether the four sibling coefficients are the trunks of the zero tree in the order of upper left, lower right, upper right, lower left or upper left, lower right, lower left, and upper right when they are within the band.
[0047]
According to claim 8 of the present invention, there is provided a method for decoding encoded data by the image encoding method according to any one of claims 1 to 7,
In decoding a certain coefficient as a decoding target coefficient, a step of taking out a Z count of a sibling coefficient of the decoding target coefficient that has been decoded when decoding a parent coefficient of the decoding target coefficient; If all of the sibling coefficients are not zero-tree trunks or indicate that all are zero-tree trunks, the map code is not decoded and some of the sibling coefficients are zero-tree trunks and some are zero-tree trunks. If it is a value indicating that it is not, the step of switching the variable length coding table according to the value of the Z count of the sibling coefficient and decoding the map code, and the map code is not the trunk of the zero tree For each sibling coefficient indicated as, a two-dimensional variable length code consisting of the Z count of the child coefficient of the sibling coefficient and the absolute value of the coefficient to be decoded is decoded. If the decoded absolute value is not zero, the sign of the decoding target coefficient is decoded, the decoding coefficient value is calculated from the absolute value and the sign of the sign, and the child coefficient of the sibling coefficient is decoded at the same time. A step of recording the Z count for use at the time, a step of recording the location information of the trunk of the zero tree for the sibling coefficient indicated by the map code as the trunk of the zero tree, respectively The decoding coefficient values of the sibling coefficients are the upper left, upper right, lower left, and lower right when the four sibling coefficients are within the vertical band, and the upper left, lower left, and upper right when within the horizontal band. An image decoding method including the steps of recording in the decoding coefficient memory in the order of upper left, lower right, upper right, lower left or upper left, lower left, lower left, and upper right in the case of being in the diagonal band in the order of lower right. suggest.
[0048]
According to claim 9 of the present invention, in an image encoding device that encodes an input image or a motion compensated prediction difference image as an encoding target signal, the encoding target signal is divided into a high frequency region and a low frequency region in both horizontal and vertical directions. Frequency band division, low frequency components in both the horizontal and vertical directions are similarly subdivided, and the re-division processing is recursively repeated a specified number of times to calculate the encoding target signal transform coefficient. Means for quantizing the encoding target signal transform coefficients to calculate quantized transform coefficients, and between the quantized transform coefficients corresponding as spatially similar positions between the frequency bands, Means for forming a tree which is a hierarchical quadtree structure having a coefficient of the lowest frequency band for each component of the component, horizontal component, and diagonal component, and each quantized transform coefficient in the tree The amount Means for searching for a zero tree, which is a subtree in which all descendants of the post-quantization transform coefficient and all descendants of the post-quantization transform coefficient do not have a significant coefficient, a post-quantization transform coefficient other than the trunk of the tree in the tree, and the quantum In encoding the sibling coefficient indicating the child coefficient of the parent coefficient of the transform coefficient after conversion, the Z count indicating the number of subtrees whose trunk tree is the zero tree is the zero count, and the sibling coefficients are all zero tree trunks. If there is a value indicating that it is not the trunk of the zero tree or not, a map code indicating which of the sibling coefficients is the trunk of the zero tree is not output to the encoded data, and If some of the sibling coefficients are zero-tree trunks and some are values indicating that they are not zero-tree trunks, then the upper left if the four sibling coefficients are in the vertical band In the order of upper right, lower left, lower right, if in the horizontal band, upper left, lower left, upper right, lower right, and in the diagonal band, upper left, lower right, upper right, lower left or Check whether the four sibling coefficients are the trunk of the zero tree in the order of upper left, lower right, lower left, upper right, and correspond to the sibling coefficients while switching the variable length coding table according to the Z count of the sibling coefficients Calculating a Z count of a direct child coefficient of the transform coefficient with respect to a transform coefficient that is not a trunk of a zero tree of the sibling coefficient, Means for outputting a two-dimensional variable length code comprising a Z count to the encoded data, and if the absolute value is not zero, outputs a positive or negative code of the transform coefficient to the encoded data after the two-dimensional variable length code Image with means Suggest Goka equipment.
[0049]
According to claim 10 of the present invention, there is provided an apparatus for decoding encoded data by the image encoding apparatus according to claim 9,
In decoding a certain coefficient as a decoding target coefficient, means for taking out the Z count of the sibling coefficient of the decoding target coefficient that has been decoded when decoding the parent coefficient of the decoding target coefficient, and the Z count of the sibling coefficient If all of the sibling coefficients are not zero-tree trunks or indicate that all are zero-tree trunks, the map code is not decoded and some of the sibling coefficients are zero-tree trunks and some are zero-tree trunks. In the case of a value indicating that it is not a trunk, a means for decoding a map code by switching a variable-length coding table in accordance with the Z count value of the sibling coefficient, For the sibling coefficient indicated as “not”, a two-dimensional variable length code consisting of the Z count of the child coefficient of the sibling coefficient and the absolute value of the decoding target coefficient is decoded, When the absolute value is not zero, the sign of the decoding target coefficient is decoded, the decoding coefficient value is calculated from the absolute value and the sign of the sign, and simultaneously the child coefficient of the sibling coefficient is decoded. Means for recording the Z count for use, and for the sibling coefficient indicated by the map code as being the trunk of the zero tree, means for recording the location information of the trunk of the zero tree, and the calculated sibling coefficient, respectively. The decoding coefficient values of the four sibling coefficients are in the order of upper left, upper right, lower left and lower right when the four sibling coefficients are in the vertical band, and upper left, lower left, upper right and right when in the horizontal band. Proposed is an image decoding apparatus having means for recording in a decoding coefficient memory in the order of upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right when in the diagonal direction in the lower order. .
[0050]
In claim 11 of the present invention, there is provided a medium storing an image encoding program for encoding an input image or a motion compensated prediction difference image as an encoding target signal,
When the program is read by a computer,
The signal to be encoded is divided into a high frequency band and a low frequency band in both the horizontal and vertical directions, and the low frequency components in both the horizontal and vertical directions are subdivided in the same manner, and the subdivision processing is recursively performed. Means for calculating an encoding target signal transform coefficient by repeating each specified number of times; means for quantizing the encoding target signal transform coefficient to calculate a quantized transform coefficient; and a space between the frequency bands. A tree having a hierarchical quadtree structure having a coefficient of the lowest frequency band as a trunk for each component of the vertical component, horizontal component, and diagonal component among the quantized transform coefficients corresponding to similar positions. And for each quantized transform coefficient in the tree, a means for searching for a zero tree that is a subtree in which the quantized transform coefficient and all descendants of the quantized transform coefficient have no significant coefficient And in the tree When coding a certain quantized transform coefficient other than the trunk of the tree and a sibling coefficient indicating a child coefficient of the parent coefficient of the quantized transform coefficient, the number of subtrees whose trunk is the sibling coefficient is a zero tree is calculated. If the indicated Z count is a value indicating that the sibling coefficients are all zero-tree trunks or not all zero-tree trunks, which of the sibling coefficients is the zero-tree trunk Are output to the encoded data, and some of the sibling coefficients are values indicating that they are zero-tree trunks and some are not zero-tree trunks. If the sibling coefficient is in the vertical band, the upper left, upper right, lower left, lower right, in the order, and if it is in the horizontal band, the upper left, lower left, upper right, lower right, in the diagonal direction. Upper left if inside Check whether the four sibling coefficients are the trunk of the zero tree in the order of lower right, upper right, lower left or upper left, lower right, lower left, upper right, and switch the variable length coding table according to the Z count of the sibling coefficients Meanwhile, with respect to a transform coefficient that is not a trunk of a zero tree among the sibling coefficients, a Z count of a direct child coefficient of the transform coefficient is calculated with respect to a transform coefficient that is not a trunk of a zero tree among the sibling coefficients. Means for outputting a two-dimensional variable length code comprising the absolute value of the transform coefficient and the Z count to the encoded data; and, if the absolute value is not zero, a sign of the transform coefficient after the two-dimensional variable length code This invention proposes a medium storing an image encoding program that constitutes a means for outputting the data as encoded data.
[0051]
According to a twelfth aspect of the present invention, encoded data is decoded by an image encoding apparatus realized by the image encoding apparatus or computer according to the ninth aspect and a medium storing the image encoding program according to the eleventh aspect. A medium storing an image decoding program,
When the program is read by a computer,
In decoding a certain coefficient as a decoding target coefficient, means for taking out the Z count of the sibling coefficient of the decoding target coefficient that has been decoded when decoding the parent coefficient of the decoding target coefficient, and the Z count of the sibling coefficient If all of the sibling coefficients are not zero-tree trunks or indicate that all are zero-tree trunks, the map code is not decoded and some of the sibling coefficients are zero-tree trunks and some are zero-tree trunks. In the case of a value indicating that it is not a trunk, a means for decoding a map code by switching a variable-length coding table in accordance with the Z count value of the sibling coefficient, For the sibling coefficients indicated as “not”, a two-dimensional variable length code consisting of the Z count of the child coefficient of the sibling coefficient and the absolute value of the coefficient to be decoded is decoded and restored. When the absolute value is not zero, the sign of the decoding target coefficient is decoded, the decoding coefficient value is calculated from the absolute value and the sign of the sign, and simultaneously the child coefficient of the sibling coefficient is decoded. Means for recording the Z count for use, and for the sibling coefficient indicated by the map code as being the trunk of the zero tree, means for recording the location information of the trunk of the zero tree, and the calculated sibling coefficient, respectively. The decoding coefficient values of the four sibling coefficients are in the order of upper left, upper right, lower left and lower right when the four sibling coefficients are in the vertical band, and upper left, lower left, upper right and right when in the horizontal band. Stores an image decoding program that constitutes means for recording in the decoding coefficient memory in the order of upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right when in the diagonal direction. Suggest media
[0052]
According to the present invention, the wavelet transform coefficient is entropy-encoded using two-dimensional variable length coding using the absolute value of the encoding target coefficient and the number of zero trees based on the child coefficient of the encoding target coefficient. By doing so, it is possible to perform encoding with no redundancy in the encoding system. In addition, if the sub-tree with the child coefficient as the trunk is ZTR, it is possible to efficiently cut off the sub-tree below the child coefficient according to the value of the parent coefficient, improving the encoding efficiency of entropy coding It becomes possible to do.
[0053]
DETAILED DESCRIPTION OF THE INVENTION
Embodiments of the present invention will be described below.
[0054]
FIG. 7 shows the entire image coding method and apparatus according to the present invention. In the figure, 1 is a wavelet transform unit, 2 is a quantization unit, 3 is a coefficient coding unit, and 4 is a scan unit.
[0055]
An encoding target signal 5 such as an input image or a motion compensated prediction difference image is frequency band-divided into a high frequency region and a low frequency region in both the horizontal and vertical directions in the wavelet transform unit 1, The low-frequency components are similarly subdivided, and the subdivision processing is recursively repeated a specified number of times to be output as the encoding target signal transform coefficient 6. The encoding target signal transform coefficient 6 is quantized by the quantizing unit 2 and output to the coefficient coding unit 3 as a quantized transform coefficient 7.
[0056]
In the scanning unit 4, the high frequency band HL is sequentially started from the lowest frequency band LL. 1 , LH 1 , HH 1 In the scanning process, the coefficient position is output to the coefficient encoding unit 3 in the same manner as the encoding target coefficient position 8. The order of coefficient scanning within each frequency band satisfies the following four conditions and performs scanning.
[0057]
1. Within each frequency band, a group of coefficients belonging to the same tree with the transform coefficient in the lowest frequency band LL as a root is scanned as a unit.
[0058]
2. Among the coefficients in the same tree, each four sibling coefficients are scanned together.
[0059]
3. Within the four sibling coefficients,
・ In the vertical frequency band, upper left, upper right, lower left, lower right
In the horizontal frequency band, upper left, lower left, upper right, lower right
In the diagonal frequency band, upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right
Scan coefficients.
[0060]
4). Between each of the four sibling coefficients and between coefficient groups belonging to the same tree,
・ In the vertical frequency band, horizontally
・ In the horizontal frequency band, in the vertical direction
Prioritize scanning.
[0061]
An example of scanning is shown in FIG. Strictly, it is not necessary to scan the coefficients in the order shown in FIG. 8, but it is sufficient that at least the scanning conditions described above are satisfied and the image coding apparatus and the image decoding apparatus scan in the same order.
[0062]
The coefficient encoding unit 3 encodes the input post-quantization transform coefficient 7 while scanning in the order indicated by the encoding target coefficient position 8 and outputs the encoded data 9.
[0063]
The encoding process according to the present invention relates to the coefficient encoding unit 3 that performs the coefficient encoding process, and the wavelet transform unit 1 and the quantization unit 2 may be the same as the conventional method. Therefore, the coefficient encoding unit 3 will be described below. In addition, although the case where the frequency band recursive division processing by the wavelet transform is performed three times will be described, it is apparent that the present invention can be similarly applied to the case where the number of times of band division is N times.
[0064]
FIG. 9 shows an example of an embodiment of a coefficient encoding process and coefficient encoding unit according to the present invention. In the figure, 11 is a zero tree generation unit, 12 is a zero tree memory, 13 is an absolute value / code separation unit, Reference numeral 14 denotes a two-dimensional variable length encoding unit, 15 denotes a selector, 16 denotes a child coefficient position calculation unit, 17 denotes a child coefficient inspection unit, 18 denotes a map code generation unit, 19 denotes a delay unit, and 20 denotes a multiplexing unit.
[0065]
The quantized transform coefficient 7 described above is input to the zero tree generation unit 11. In the zero tree generation unit 11, first, for each component of the vertical component, the horizontal component, and the diagonal component between the quantized transform coefficients corresponding as spatially similar positions between the frequency bands, the components shown in FIG. 4 are shown. A hierarchical tree having the lowest frequency band coefficient at the root is formed. Then, for any transform coefficient in the tree, a search is made for a subtree in which all subtrees having the transform coefficient as a root are zero. This search process is performed for all transform coefficients in all trees whose root is the coefficient of the lowest frequency band, and which transform coefficient is the zero tree root coefficient (zero tree root), or a coefficient that has already been censored by the zero tree. Is output as zero tree information 21 to the zero tree memory 12.
[0066]
At the same time, the quantized transform coefficient 7 and the encoding target coefficient position 8 given from the scanning unit 4 are input to the absolute value / code separation unit 13. The absolute value / code separation unit 13 extracts the transform coefficient at the position of the encoding target coefficient position 8 from the post-quantization conversion coefficient 7 and encodes this as the encoding target coefficient. The absolute value of the coefficient is output as an absolute value 22 to the two-dimensional variable length encoding unit 14, and the positive / negative code of the encoding target coefficient is output as a code 23 to the selector 15.
[0067]
The encoding target coefficient position 8 is also input to the child coefficient position calculation unit 16, where the position of the child coefficient of the encoding target coefficient is calculated, and the child coefficient position 24 is output to the child coefficient inspection unit 17. Although different depending on the frequency band to which the coefficient to be encoded belongs, three or four coefficient positions are shown as the child coefficient position 24 for one parent.
[0068]
Similarly, the zero coefficient information 17 which is the zero tree information of the quantized transform coefficient 7 is input from the zero tree memory 12 to the child coefficient inspection unit 17, and is indicated by the child coefficient position 24 in the zero tree information 25. The zero tree information at the position to be taken out is extracted as child coefficient zero tree information. The number of zero tree roots in the child coefficient zero tree information is output to the two-dimensional variable length encoding unit 14 as a Z count 26, and at the same time, which child coefficient is the zero tree root and which child coefficient is the zero tree root. Is output to the map code generation unit 18 as child coefficient map information 27.
[0069]
At this time, the child coefficient scan order uses the characteristics between the coefficients in the horizontal, vertical, and diagonal frequency bands, so when the child coefficient is in the vertical frequency band, Top right, bottom left, bottom right, top left when in horizontal frequency band, bottom left, top right, bottom right order, top left, bottom right, top right, bottom left or top left when in diagonal frequency band, Lower right, lower left, upper right.
[0070]
The map code generation unit 18 generates a map code 28 that is output when the child coefficient is encoded based on the input child coefficient map information 27. Table 1 shows an example of a map code coding table, which corresponds to a band having four child coefficients. A map code encoding table is prepared for each Z count value, and the encoding table corresponding to the Z count of the sibling coefficient is switched and used in accordance with the Z count of the sibling coefficient of the encoding target coefficient. To generate a map code. When the Z count is 2, since the scan using the characteristics of each frequency band is performed for each frequency band in the horizontal direction, the vertical direction, and the diagonal direction as the scan order of the sibling coefficients, the map code map4 [0, A code having a short code length can be assigned to 0,1,1] and map4 [1,1,0,0]. If the Z count is “0”, that is, all of the sibling coefficients are not zero tree roots, or if the Z count is “4”, that is, all of the sibling coefficients are zero tree roots, it is necessary to output a map code. Instead, an empty code is output as the map code 31. In Table 1, “encoding unnecessary” is indicated.
[0071]
[Table 1]
Figure 0003660548
[0072]
The map code 28 calculated using the coding table is output to the delay unit 19 in order to multiplex and output the encoded child data of the coding target coefficient to the encoded data.
[0073]
The two-dimensional variable length encoding unit 14 encodes the absolute value 22 input from the absolute value / code separation unit 13 and the Z count 26 input from the child coefficient test unit 17 as two-dimensional variable length encoded data 29, The data is output to the multiplexing unit 20. LH 1,2 , HL 1,2 , HH 1,2 Table 2 shows an example of a two-dimensional variable length code (TDVLC4) used when coding a band having four child coefficients such as a band. Table 2 does not show a two-dimensional variable length code for an absolute value of zero and a Z count of 4, that is, a zero tree root. However, since the location of the zero tree can be uniquely specified by the Z count when the parent coefficient is encoded and the map code encoded before the two-dimensional variable length code, the code of the zero tree root is prepared. This is because there is no need.
[0074]
[Table 2]
Figure 0003660548
[0075]
In the selector 15, when the absolute value of the encoding target coefficient indicated by the absolute value 22 is not zero, the multiplexing unit 20 uses the positive / negative sign of the encoding target coefficient indicated by the reference numeral 23 as the positive / negative code data 30. Output to.
[0076]
In the multiplexing unit 20, the map code 31, the two-dimensional variable length encoded data 29, and the positive / negative code data 30 input from the delay unit 19 are multiplexed and output as encoded data 9. The map code 31 input via the delay unit 19 includes zero tree information of sibling codes including the encoding coefficient, and the two-dimensional variable length encoded data 29 and the positive / negative code data 30 include the encoding coefficient. This is encoded data for each sibling code.
[0077]
The multiplexing unit 20 performs multiplexing according to the following procedure.
[0078]
The map code 31 calculated when the parent coefficient of the encoding target coefficient is encoded is output as encoded data. (If the value of the Z count of the parent coefficient is a value indicating that all of the sibling coefficients are zero tree roots or not all of them are zero tree roots, as described above, the map code 31 includes Nothing)
The map code 31 outputs the following two encoded data to the encoded data in order for each sibling coefficient determined not to be the zero tree root. (When the absolute value of the encoding target coefficient is zero, the selector 15 does not enter anything in the positive / negative code data 30)
-Two-dimensional variable length encoded data 29
-Sign data 30
Accordingly, when a certain sibling coefficient consisting of the following four coefficients in the vertical frequency band is encoded, the multiplexed code shown in FIG. 10 is output as encoded data.
[0079]
1. Upper left is ZTR,
2. Upper right post-quantization transform coefficient is -1, child coefficient Z count is 4,
3. The lower left quantized transform coefficient is 3, the child coefficient Z count is 0,
4). The lower right quantized transform coefficient is 0 and the child coefficient has 3 Z counts
In this example, the encoding table shown in Table 1 and Table 2 is used.
[0080]
Hereinafter, an example of encoding the transform coefficient tree shown in FIG. 5 using the present invention will be described.
[0081]
・ LL Three In-band coefficient
The post-quantization transform coefficient to be encoded in the LL band is “+3”, and among the three child coefficients, HH Three The child coefficient in the band is ZTR. In this method, a two-dimensional variable length code consisting of the absolute value of the quantized transform coefficient and the number of child trees of the quantized transform coefficient that are the root zero tree, that is, the Z count. (TDVLC3 [absolute value of transform coefficient, Z count]) is output as encoded data. TDVLC3 is a two-dimensional variable length code when there are three sibling coefficients, and is prepared in an image encoding device / image decoding device separately from TDVLC4 shown in Table 2. However, since there is no parent coefficient in the LL coefficient, the Z count is not encoded with the parent coefficient. Therefore, unlike TDVLC4, TDVLC3 must have a code whose absolute value is 0 and all three children are zero tree roots.
[0082]
Further, after the two-dimensional variable length code is output as encoded data, the positive and negative codes of the quantized transform coefficients are output. Since the sign of “+3” is positive, a positive sign is output. Hereinafter, the positive sign is described as POS and the negative sign is described as NEG. Therefore, in this example, when encoding the LL band,
(TDVLC3 [3,1]) (POS)
Is output.
[0083]
・ LH Three , HL Three , HH Three In-band coefficient
LH Three The post-quantization transform coefficient to be encoded in the band is “+3”. HL Three The post-quantization transform coefficient to be encoded in the band is “0”. HH Three The post-quantization transform coefficient to be encoded in the band is “0” and is a zero tree root.
[0084]
LL Three The Z count output when the parent coefficient of the three coefficients in the band is encoded is 1. Therefore, map3 [0, 0, 1] is output as the map code. Table 3 shows an example of an encoding table of map code map3 [], which is an LH having three sibling coefficients. Three , HL Three , HH Three Used when coding a band.
[0085]
In addition, when the Z count is 3, it indicates that all three sibling coefficients are zero tree roots, and when the Z count is 0, it indicates that all three sibling coefficients are not zero tree roots. There is no need to output the map code as encoded data.
[0086]
[Table 3]
Figure 0003660548
[0087]
Next, LH Three , HL Three , HH Three A two-dimensional variable length code corresponding to the three coefficients in the band is output.
[0088]
LH Three The encoding target coefficient is “+3”, and since there is one ZTR among the four children, TDVLC4 [3, 1] and the positive code POS are output.
[0089]
HL Three The encoding target coefficient is “0”, and among the four children, there are two ZTRs, so TDVLC4 [0, 2] is output. Since the absolute value of the encoding target coefficient is zero, it is not necessary to output a positive or negative sign.
[0090]
HH Three The encoding target coefficients are already encoded by the Z count when the parent coefficient is encoded and the previously output map code.
[0091]
Therefore, in this example, LH Three , HL Three , HH Three In band coding,
map3 [0,0,1]
(TDVLC4 [3,1]) (POS)
(TDVLC4 [0, 2])
Is output. Note that the encoding table shown in Table 2 is used as the two-dimensional variable length code TDVLC4.
[0092]
・ LH 2 , HL 2 , HH 2 In-band coefficient
LH 2 In encoding the in-band coefficients, LH Three The Z count output when the parent coefficient existing in the band is encoded is “1”, and LH 2 Of the sibling coefficients in the band, the zero tree root is the lower right coefficient. LH Three Since the frequency band is a vertical frequency band, the sibling coefficients are scanned in the order of upper left, upper right, lower left, and lower right. Furthermore, the child coefficient Z count of the upper left coefficient is 2, the child coefficient Z count of the upper right coefficient is 3, and the child coefficient Z count of the lower left coefficient is 1.
[0093]
Similarly HL 2 For bandwidth, HL Three The Z count output when the parent coefficient existing in the band is encoded is “2”, and HL 2 The zero tree root of the in-band sibling coefficients is the upper left and upper right coefficients. HL Three Since the frequency band is a horizontal frequency band, the sibling coefficients are scanned in the order of upper left, lower left, upper right, and lower right. Furthermore, the Z count of the child coefficient of the lower left coefficient is 1, and the Z count of the child coefficient of the lower right coefficient is 3.
[0094]
Similarly HH 2 For bandwidth, HH Three As in the case of the band, encoding is not necessary because it has already been truncated by the zero tree.
[0095]
Therefore, in this example, LH 2 , HL 2 , HH 2 In band coding,
map4 [0,0,0,1]
(TDVLC4 [1,2]) (NEG)
(TDVLC4 [0,3])
(TDVLC4 [0, 1])
map4 [1,0,1,0]
(TDVLC4 [1,1]) (NEG)
(TDVLC4 [0,3])
Is output. The map map4 [] uses the encoding table shown in Table 1.
[0096]
・ LH 1 , HL 1 , HH 1 In-band coefficient
LH 1 , HL 1 , HH 1 Since there are no child coefficients among the coefficients in the band, it is impossible to apply the present invention using the two-dimensional variable length of the absolute value and the Z count of the child coefficient. Therefore, encoding is performed using a one-dimensional variable length code having the same absolute value as that of the conventional zero tree encoding as an input symbol. However, unlike the zero tree coding, since the number of sibling coefficient zero trees is already described in the coded data when the parent coefficient is coded, the map code and the one-dimensional variable length code are used for coding. good.
[0097]
In particular,
・ LH1 band
map4 [1, 0, 0, 1],
(LEVEL, 1), (LEVEL, 2),
map4 [0,1,1,1],
(LEVEL, -2),
map4 [1, 0, 0, 0],
(LEVEL, -1), (LEVEL, 3), (LEVEL, 1)
・ HL1 bandwidth
map4 [1, 0, 0, 0],
(LEVEL, -2), (LEVEL, -1), (LEVEL, 1),
map4 [0,1,1,1],
(LEVEL, -1)
・ HH1 band
No encoding required
Is output.
[0098]
Next, the image decoding process according to the present invention will be described in detail.
[0099]
FIG. 11 shows the entire image decoding method and apparatus according to the present invention, in which 41 is a coefficient decoding unit, 42 is an inverse quantization unit, and 43 is a wavelet inverse transform unit.
[0100]
In the image decoding apparatus, first, the encoded data 44 is first input to the coefficient decoding unit 41, the decoding process is performed, and the quantized transform coefficient 45 is output. The post-quantization transform coefficient 45 is input to the inverse quantization unit 42, the inverse quantization corresponding to the processing in the quantization unit 2 of the image encoding device is performed, and the decoded transform coefficient 46 is output to the wavelet inverse transform unit 43. Is done.
[0101]
In the wavelet inverse transform unit 43, the inverse wavelet transform is recursively performed on the decoded transform coefficient 46 according to the number of times indicated by the maximum wavelet division number 47, and a decoded signal 48 is output. The wavelet recursive division number 47 is not required to be described in the encoded data 44 by determining the number of times in advance in the image encoding device / image decoding device.
[0102]
The decoding process in the present invention is related to the coefficient decoding unit 41 that performs the coefficient decoding process, and the inverse quantization unit 42 and the wavelet inverse transformation unit 43 may be the same as the conventional method. Therefore, the coefficient decoding unit 41 will be described below.
[0103]
FIG. 12 shows an example of an embodiment of the coefficient decoding process and coefficient decoding unit according to the present invention. In the figure, 51 is a separation unit, 52 is a selector, 53 is a zero tree memory, and 54 is a two-dimensional variable length decoding. , 55 is a delay unit, 56 is an absolute value / code synthesis unit, 57 is a selector, 58 is a coefficient memory, 59 is a scan unit, 60 is a map code decoding unit, and 61 is a child coefficient position calculation unit.
[0104]
The input encoded data 44 is input to the separation unit 51 and separated into map code data 71, absolute value data 72, and positive / negative code 73.
[0105]
The absolute value data 72 is input to the selector 52. The selector 52 outputs the absolute value data 72 to the two-dimensional variable length decoding unit 54 when the coefficient is not already coded by the zero tree based on the zero tree information 74 input from the zero tree memory 53.
[0106]
The two-dimensional variable length decoding unit 54 performs decoding using a common two-dimensional variable length code encoding table such as Table 2 and the like, and the Z count 75 is set to the delay unit 55 and the absolute value 76 is set to the absolute value 76. The data is output to the value / sign synthesis unit 56.
[0107]
The positive / negative sign 73 is input to the selector 57. The selector 57 outputs a positive / negative sign 73 to the absolute value / code combining unit 56 when the coefficient currently decoded by the zero tree information 74 is not already encoded by the zero tree and the absolute value 76 is not zero. .
[0108]
The absolute value / code combining unit 56 calculates a decoding coefficient 77 from the absolute value 76 and the positive / negative code 73, and outputs this to the coefficient memory 58.
[0109]
In the coefficient memory 58, the decoding coefficient 77 is recorded at the position indicated by the decoding coefficient position 78 output from the scanning unit 59, and after decoding is completed for all the coefficients, it is output as the quantized transform coefficient 45.
[0110]
The scan unit 59 is a circuit that calculates the scan position in the same order as the scan unit 4 in the image encoding device. The decoding coefficient position 78 output from the scan unit 59 is the same as the encoding target coefficient position 8 in the image encoding device. Similar types of values.
[0111]
The map code data 71 is input to the map code decoding unit 60, and the map code 80 is decoded using the variable length coding table by switching according to the Z count 79. Here, the Z count 79 is input from the delay unit 55, and the Z count of the child coefficient when the parent coefficient is first decoded by the two-dimensional variable length decoding unit 54, that is, the sibling coefficient of the currently decoded coefficient. Z count.
[0112]
The map code decoding unit 60 performs processing corresponding to the processing in the map code generation unit 18 in the coefficient encoding unit. When the Z count 79 is “0”, that is, when all of the sibling coefficients are not zero tree root, or when the Z count 79 indicates that all of the sibling coefficients are zero tree root, the map code data 71 is decoded. Instead, a map code 80 is generated and output to the zero tree memory 53. Otherwise, if the Z count 79 is a value indicating that some of the sibling coefficients are zero tree roots and some are not zero tree roots, the map code data 71 is decoded. The map code 80 is output to the zero tree memory 53.
[0113]
The decoded coefficient position 78 is simultaneously input to the child coefficient position calculation unit 61, where the position of the child coefficient is calculated in the same manner as the child coefficient position calculation unit 16 in the coefficient encoding unit, To 53.
[0114]
In the zero tree memory 53, zero tree information is recorded at the position of the child coefficient position 81 in accordance with the map code 80, and used later when decoding the child coefficient. At this time, when the frequency band to which the sibling coefficient belongs is in the vertical frequency band, the order is upper left, upper right, lower left, lower right. When the frequency band is in the angular direction, the zero tree information is recorded in the zero tree memory 53 in the order of upper left, lower right, upper right, lower left or upper left, lower right, lower left, and upper right. Furthermore, information indicating that the coding has already been performed is recorded in the descendants of the coefficient that is the zero tree root.
[0115]
The present invention is a computer-readable medium, and when read by a computer, a program (software) that constitutes the apparatus shown in FIGS. 7, 9, 10, and 11 is executed on the computer. It can also be realized by a stored medium.
[0116]
【The invention's effect】
J. et al. M.M. In conventional zero tree coding by Shapiro et al., The coding system is redundant, and it is extremely difficult to dynamically change the probability of child ZTR code generation according to the level of the parent coefficient level. is there.
[0117]
On the other hand, according to the present invention, it is not necessary to use an isolated zero code whose existence itself is redundant, and the probability of occurrence of a zero tree root in the child coefficient varies depending on the absolute value of the parent coefficient. Since the encoding can be performed by efficiently using the characteristics, the encoding efficiency can be improved.
[Brief description of the drawings]
FIG. 1 is an explanatory diagram showing an outline of discrete wavelet transform
FIG. 2 is an explanatory diagram showing how the image is divided into octaves.
FIG. 3 is an explanatory diagram showing the mutual relationship between coefficients of a decomposition filter and a synthesis filter.
FIG. 4 is an explanatory diagram showing a state of two-dimensional octave division of an image.
FIG. 5 is an explanatory diagram illustrating an example of encoding using zero-tree encoding.
FIG. 6 is an explanatory diagram showing how encoded data is generated with scalability.
FIG. 7 is a block diagram showing an example of an embodiment of an image encoding method and apparatus as a whole according to the present invention.
FIG. 8 is an explanatory diagram showing an example of scanning according to the present invention.
FIG. 9 is a block diagram showing an example of an embodiment of a coefficient encoding unit of the present invention.
FIG. 10 is an explanatory diagram showing an example of encoded data output
FIG. 11 is a block diagram showing an example of an embodiment of an image decoding method and apparatus as a whole according to the present invention.
FIG. 12 is a block diagram showing an example of an embodiment of a coefficient decoding unit of the present invention.
[Explanation of symbols]
1: Wavelet transform unit, 2: Quantization unit, 3: Coefficient coding unit, 4: Scan unit, 11: Zero tree generation unit, 12: Zero tree memory, 13: Absolute value / code separation unit, 14: Two-dimensional variable Long encoding unit, 15: selector, 16: child coefficient position calculation unit, 17: child coefficient inspection unit, 18: map code generation unit, 19: delay unit, 20: multiplexing unit, 41: coefficient decoding unit, 42 : Inverse quantization unit, 43: wavelet inverse transform unit, 51: separation unit, 52: selector, 53: zero tree memory, 54: two-dimensional variable length decoding unit, 55: delay unit, 56: absolute value / code synthesis Unit: 57: selector, 58: coefficient memory, 59: scan unit, 60: map code decoding unit, 61: child coefficient position calculation unit.

Claims (12)

入力画像あるいは動き補償予測差分画像を符号化対象信号として符号化する画像符号化方法において、
符号化対象信号を、水平及び垂直の両方向について高域と低域に周波数帯域分割し、水平及び垂直の両方向に対しての低域成分を同様に再分割し、該再分割処理を再帰的にそれぞれ指定された回数繰り返すことで符号化対象信号変換係数を算出するステップと、
該符号化対象信号変換係数をそれぞれ量子化して量子化後変換係数を算出するステップと、
前記各周波数帯域間で空間的に相似な位置として対応する量子化後変換係数間で、垂直成分・水平成分・対角成分の各成分毎に、最低周波数帯域の係数を幹に持つ階層的な4分木構造であるツリーを形成するステップと、
該ツリー中の各量子化後変換係数について、該量子化後変換係数及び該量子化後変換係数の全ての子孫が有意係数を持たない部分木であるゼロツリーを探索するステップと、
前記ツリー内のある量子化後変換係数を符号化するに当たり、該量子化後変換係数の直接の子供係数のうち、該子供係数を幹とする部分木がゼロツリーである個数を示すZカウントを算出するステップと、
該量子化後変換係数の絶対値及びZカウントからなる二次元可変長符号を符号化データに出力するステップとを有する
ことを特徴とする画像符号化方法。
In an image encoding method for encoding an input image or a motion compensated prediction difference image as an encoding target signal,
The signal to be encoded is divided into a high frequency band and a low frequency band in both the horizontal and vertical directions, and the low frequency components in both the horizontal and vertical directions are subdivided in the same manner, and the subdivision processing is recursively performed. Calculating an encoding target signal transform coefficient by repeating each of the designated number of times, and
Quantizing the encoding target signal transform coefficients to calculate quantized transform coefficients;
Between the quantized transform coefficients corresponding as spatially similar positions between the respective frequency bands, a hierarchical structure having a coefficient of the lowest frequency band as a trunk for each of the vertical component, horizontal component, and diagonal component Forming a tree that is a quadtree structure;
For each post-quantization transform coefficient in the tree, searching for a zero tree that is a subtree in which all the descendants of the post-quantization transform coefficient and the post-quantization transform coefficient have no significant coefficient;
When coding a certain quantized transform coefficient in the tree, a Z count indicating the number of subtrees whose root is the child coefficient is a zero tree among the direct child coefficients of the quantized transform coefficient is calculated. And steps to
And a step of outputting a two-dimensional variable length code comprising the absolute value of the post-quantization transform coefficient and the Z count to the encoded data.
請求項1記載の画像符号化方法において、
ある量子化後変換係数を符号化するに当たり、該量子化後変換係数の絶対値がゼロでない場合は、前記二次元可変長符号を符号化データに出力した直後に、該量子化後変換係数の正負の符号を符号化データに出力することを特徴とする画像符号化方法。
The image encoding method according to claim 1, wherein:
When encoding a certain quantized transform coefficient, if the absolute value of the quantized transform coefficient is not zero, immediately after the two-dimensional variable length code is output as encoded data, the quantized transform coefficient An image encoding method, wherein positive and negative codes are output as encoded data.
請求項1記載の画像符号化方法において、
ツリーの幹以外の量子化後変換係数を符号化するに当たり、該量子化後変換係数の親係数の子供の係数を示す兄弟係数を検査し、該兄弟係数それぞれに対応する前記二次元可変長符号を符号化データに出力する前に、該兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を符号化データに出力することを特徴とする画像符号化方法。
The image encoding method according to claim 1, wherein:
When encoding post-quantization transform coefficients other than the trunk of the tree, the two-dimensional variable length code corresponding to each sibling coefficient is examined by examining sibling coefficients indicating the child coefficients of the parent coefficient of the post-quantization transform coefficient A map code indicating which of the sibling coefficients is a trunk of a zero tree is output to the encoded data before outputting the encoded data to the encoded data.
請求項3記載の画像符号化方法において、
兄弟係数のマップ符号を出力するに当たり、該兄弟係数の親係数を符号化した際に符号化データに出力済みの該兄弟係数のZカウントを参照し、該Zカウントの値が、該兄弟係数が全てゼロツリーの幹であるか、あるいは全てゼロツリーの幹ではないことを示している値である場合には前記マップ符号を符号化データに出力せず、該兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には前記マップ符号を符号化データに出力することを特徴とする画像符号化方法。
The image encoding method according to claim 3, wherein
When outputting the map code of the sibling coefficient, reference is made to the Z count of the sibling coefficient that has already been output to the encoded data when the parent coefficient of the sibling coefficient is encoded, If the values are all zero tree trunks or values indicating that they are not all zero tree trunks, the map code is not output to the encoded data, and some of the sibling coefficients are zero tree trunks. Then, when some of the values indicate that they are not the trunk of the zero tree, the map code is output as encoded data.
請求項4記載の画像符号化方法において、
親係数を符号化した際に符号化データに出力済みのZカウントが、兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合、Zカウントの値に対応するマップ符号用の可変長符号テーブルを用意しておき、前記親係数のZカウントに応じて該マップ符号用の可変長符号テーブルを切り替えて符号化することを特徴とする画像符号化方法。
The image encoding method according to claim 4, wherein
If the Z count already output in the encoded data when encoding the parent coefficients is a value indicating that some of the sibling coefficients are zero tree trunks and some are not zero tree trunks, A variable-length code table for map code corresponding to the value of Z count is prepared, and the variable-length code table for map code is switched and encoded according to the Z count of the parent coefficient. Image coding method.
請求項3または4記載の画像符号化方法において、
マップ符号を符号化データに出力した後に、前記親係数を符号化した際に符号化データに出力済みの兄弟係数のうちのゼロツリーの幹ではない係数の数だけ、該ゼロツリーの幹ではない係数の二次元可変長符号及び請求項2記載の条件に応じて前記正負の符号を符号化データに出力することを特徴とする画像符号化方法。
The image encoding method according to claim 3 or 4,
After outputting the map code to the encoded data, the number of coefficients that are not the trunk of the zero tree is equal to the number of coefficients that are not the trunk of the zero tree among the sibling coefficients that are output to the encoded data when the parent coefficient is encoded. An image encoding method, wherein the positive and negative codes are output as encoded data in accordance with a two-dimensional variable length code and the condition according to claim 2.
請求項3記載の画像符号化方法において、
4つの兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を生成するに当たり、該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に該4つの兄弟係数がゼロツリーの幹であるかどうかを調べることを特徴とする画像符号化方法。
The image encoding method according to claim 3, wherein
In generating a map code indicating which of the four sibling coefficients are the trunk of the zero tree, if the four sibling coefficients are in the vertical band, the upper left, upper right, lower left, lower right In the order of the upper left, lower left, upper right, and lower right when in the horizontal band, the upper left, lower right, upper right, lower left or upper left, lower right, lower left, An image coding method characterized by examining whether or not the four sibling coefficients are trunks of a zero tree in the order of the upper right.
請求項1乃至7いずれか記載の画像符号化方法による符号化データを復号する方法であって、
ある係数を復号対象係数として復号するに当たり、該復号対象係数の親係数を復号した際に復号済みの該復号対象係数の兄弟係数のZカウントを取り出すステップと、
該兄弟係数のZカウントが、該兄弟係数の全てがゼロツリーの幹ではないかあるいは全てがゼロツリーの幹であることを示す場合は、マップ符号を復号せず、兄弟係数のうちのいくつかはゼロツリーの幹でいくつかはゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のZカウントの値に応じて可変長符号化テーブルを切り替えてマップ符号を復号するステップと、
該マップ符号によりゼロツリーの幹ではないと示されている兄弟係数について、それぞれ、該兄弟係数の子供係数のZカウント及び復号対象係数の絶対値からなる二次元可変長符号を復号し、復号された該絶対値がゼロでない場合は該復号対象係数の正負の符号を復号し、該絶対値及び該正負の符号より復号係数値を算出し、同時に該兄弟係数の子供係数を復号する際に利用するために該Zカウントを記録するステップと、
該マップ符号によりゼロツリーの幹であると示されている兄弟係数については、ゼロツリーの幹の場所情報を記録するステップと、
それぞれ算出された兄弟係数の該復号係数値を該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に復号係数メモリに記録するステップとを有する
ことを特徴とする画像復号方法。
A method for decoding encoded data by the image encoding method according to claim 1, comprising:
When decoding a certain coefficient as a decoding target coefficient, extracting a Z count of a sibling coefficient of the decoding target coefficient that has been decoded when decoding a parent coefficient of the decoding target coefficient;
If the Z-count of the sibling coefficients indicates that all of the sibling coefficients are not zero tree trunks or all are zero tree trunks, then no map code is decoded and some of the sibling coefficients are zero tree A map code is decoded by switching the variable-length coding table according to the value of the Z count of the sibling coefficient;
For each sibling coefficient indicated by the map code as not being a trunk of the zero tree, a two-dimensional variable length code consisting of the Z count of the child coefficient of the sibling coefficient and the absolute value of the coefficient to be decoded is decoded and decoded. When the absolute value is not zero, the sign of the decoding target coefficient is decoded, the decoding coefficient value is calculated from the absolute value and the sign of the sign, and is used for decoding the child coefficient of the sibling coefficient at the same time. Recording the Z count for:
For sibling coefficients indicated by the map code as being a zero tree trunk, recording zero tree trunk location information;
The decoding coefficient values of the calculated sibling coefficients are the upper left, the upper right, the lower left, and the lower right when the four sibling coefficients are in the vertical band, and the upper left when the four sibling coefficients are in the horizontal band. Recording in the decoding coefficient memory in the order of upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right if they are within the diagonal band. An image decoding method characterized by the above.
入力画像あるいは動き補償予測差分画像を符号化対象信号として符号化する画像符号化装置において、
符号化対象信号を、水平及び垂直の両方向について高域と低域に周波数帯域分割し、水平及び垂直の両方向に対しての低域成分を同様に再分割し、該再分割処理を再帰的にそれぞれ指定された回数繰り返すことで符号化対象信号変換係数を算出する手段と、
該符号化対象信号変換係数をそれぞれ量子化して量子化後変換係数を算出する手段と、
前記各周波数帯域間で空間的に相似な位置として対応する量子化後変換係数間で、垂直成分・水平成分・対角成分の各成分毎に、最低周波数帯域の係数を幹に持つ階層的な4分木構造であるツリーを形成する手段と、
該ツリー中の各量子化後変換係数について、該量子化後変換係数及び該量子化後変換係数の全ての子孫が有意係数を持たない部分木であるゼロツリーを探索する手段と、
前記ツリー内のツリーの幹以外のある量子化後変換係数及び該量子化後変換係数の親係数の子供の係数を示す兄弟係数を符号化するに当たり、該兄弟係数を幹とする部分木がゼロツリーである個数を示すZカウントが、該兄弟係数が全てゼロツリーの幹であるかあるいは全てゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を符号化データに出力せず、該兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に該4つの兄弟係数がゼロツリーの幹であるかどうかを調べて、該兄弟係数のZカウントに応じて可変長符号化テーブルを切り替えつつ、該兄弟係数に対応するマップ符号を符号化データに出力する手段と、
該兄弟係数のうちのゼロツリーの幹ではない変換係数に関し、該変換係数の直接の子供係数のZカウントを算出し、該変換係数の絶対値及びZカウントからなる二次元可変長符号を符号化データに出力する手段と、
該絶対値がゼロでない場合は、該二次元可変長符号の後に該変換係数の正負の符号を符号化データに出力する手段とを有する
ことを特徴とする画像符号化装置。
In an image encoding device that encodes an input image or a motion compensated prediction difference image as an encoding target signal,
The signal to be encoded is divided into a high frequency band and a low frequency band in both the horizontal and vertical directions, and the low frequency components in both the horizontal and vertical directions are subdivided in the same manner, and the subdivision processing is recursively performed. Means for calculating a signal conversion coefficient to be encoded by repeating each specified number of times;
Means for quantizing each of the encoding target signal transform coefficients to calculate a quantized transform coefficient;
Between the quantized transform coefficients corresponding as spatially similar positions between the respective frequency bands, a hierarchical structure having a coefficient of the lowest frequency band as a trunk for each of the vertical component, horizontal component, and diagonal component Means for forming a tree that is a quadtree structure;
For each post-quantization transform coefficient in the tree, means for searching for a zero tree that is a subtree in which all the descendants of the post-quantization transform coefficient and the post-quantization transform coefficient have no significant coefficient;
In encoding a certain quantized transform coefficient other than the trunk of the tree in the tree and a sibling coefficient indicating a child coefficient of a parent coefficient of the quantized transform coefficient, a subtree whose trunk is the sibling coefficient is a zero tree. Is a value indicating that the sibling coefficients are all zero-tree trunks or not all zero-tree trunks, and which of the sibling coefficients are zero-tree If the map code indicating whether it is a trunk is not output to the encoded data and some of the sibling coefficients are zero tree trunks and some are values indicating that they are not zero tree trunks When the four sibling coefficients are within the vertical band, the upper left, upper right, lower left, and lower right are ordered. When the four sibling coefficients are within the horizontal band, the upper left, lower left, upper right, and lower right are ordered. In the angular band In the upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right, the four sibling coefficients are checked to see if they are the trunks of the zero tree, and variable length is selected according to the Z count of the sibling coefficients. Means for outputting a map code corresponding to the sibling coefficient to the encoded data while switching the encoding table;
For the transform coefficient that is not the trunk of the zero tree among the sibling coefficients, the Z count of the direct child coefficient of the transform coefficient is calculated, and a two-dimensional variable length code consisting of the absolute value of the transform coefficient and the Z count is encoded data. Means for outputting to
An image encoding apparatus comprising: means for outputting positive and negative codes of the transform coefficient to encoded data after the two-dimensional variable length code when the absolute value is not zero.
請求項9記載の画像符号化装置による符号化データを復号する装置であって、
ある係数を復号対象係数として復号するに当たり、該復号対象係数の親係数を復号した際に復号済みの該復号対象係数の兄弟係数のZカウントを取り出す手段と、
該兄弟係数のZカウントが、該兄弟係数の全てがゼロツリーの幹ではないかあるいは全てがゼロツリーの幹であることを示す場合は、マップ符号を復号せず、兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のZカウントの値に応じて可変長符号化テーブルを切り替えてマップ符号を復号する手段と、
該マップ符号によりゼロツリーの幹ではないと示されている兄弟係数について、それぞれ、該兄弟係数の子供係数のZカウント及び復号対象係数の絶対値からなる二次元可変長符号を復号し、復号された該絶対値がゼロでない場合は該復号対象係数の正負の符号を復号し、該絶対値及び該正負の符号より復号係数値を算出し、同時に該兄弟係数の子供係数を復号する際に利用するために該Zカウントを記録する手段と、
該マップ符号によりゼロツリーの幹であると示されている兄弟係数については、ゼロツリーの幹の場所情報を記録する手段と、
それぞれ算出された兄弟係数の該復号係数値を該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に復号係数メモリに記録する手段とを有する
ことを特徴とする画像復号装置。
An apparatus for decoding encoded data by the image encoding apparatus according to claim 9, comprising:
In decoding a certain coefficient as a decoding target coefficient, means for extracting the Z count of the sibling coefficient of the decoding target coefficient that has been decoded when decoding the parent coefficient of the decoding target coefficient;
If the Z-count of the sibling coefficients indicates that all of the sibling coefficients are not zero tree trunks or all are zero tree trunks, then no map code is decoded and some of the sibling coefficients are zero tree And a means for decoding the map code by switching the variable length coding table in accordance with the Z count value of the sibling coefficient, if some are values indicating that they are not zero tree trunks. ,
For each sibling coefficient indicated by the map code as not being a trunk of the zero tree, a two-dimensional variable length code consisting of the Z count of the child coefficient of the sibling coefficient and the absolute value of the coefficient to be decoded is decoded and decoded. When the absolute value is not zero, the sign of the decoding target coefficient is decoded, the decoding coefficient value is calculated from the absolute value and the sign of the sign, and is used for decoding the child coefficient of the sibling coefficient at the same time. Means for recording the Z count for:
For sibling coefficients indicated by the map code as being a zero tree trunk, means for recording the location information of the zero tree trunk;
The decoding coefficient values of the calculated sibling coefficients are the upper left, the upper right, the lower left, and the lower right when the four sibling coefficients are in the vertical band, and the upper left when the four sibling coefficients are in the horizontal band. Means for recording in the decoding coefficient memory in the order of upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right when in the diagonal band in the order of lower left, upper right, lower right. An image decoding apparatus characterized by that.
入力画像あるいは動き補償予測差分画像を符号化対象信号として符号化する画像符号化プログラムを記憶した媒体であって、
前記プログラムはコンピュータに読み取られた際、該コンピュータ上に、
符号化対象信号を、水平及び垂直の両方向について高域と低域に周波数帯域分割し、水平及び垂直の両方向に対しての低域成分を同様に再分割し、該再分割処理を再帰的にそれぞれ指定された回数繰り返すことで符号化対象信号変換係数を算出する手段と、
該符号化対象信号変換係数をそれぞれ量子化して量子化後変換係数を算出する手段と、
前記各周波数帯域間で空間的に相似な位置として対応する量子化後変換係数間で、垂直成分・水平成分・対角成分の各成分毎に、最低周波数帯域の係数を幹に持つ階層的な4分木構造であるツリーを形成する手段と、
該ツリー中の各量子化後変換係数について、該量子化後変換係数及び該量子化後変換係数の全ての子孫が有意係数を持たない部分木であるゼロツリーを探索する手段と、
前記ツリー内のツリーの幹以外のある量子化後変換係数及び該量子化後変換係数の親係数の子供の係数を示す兄弟係数を符号化するに当たり、該兄弟係数を幹とする部分木がゼロツリーである個数を示すZカウントが、該兄弟係数が全てゼロツリーの幹であるかあるいは全てゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のうちのどの係数がゼロツリーの幹であるかを示すマップ符号を符号化データに出力せず、該兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に該4つの兄弟係数がゼロツリーの幹であるかどうかを調べて、該兄弟係数のZカウントに応じて可変長符号化テーブルを切り替えつつ、該兄弟係数に対応するマップ符号を符号化データに出力する手段と、
該兄弟係数のうちのゼロツリーの幹ではない変換係数に関し、該変換係数の直接の子供係数のZカウントを算出し、該変換係数の絶対値及びZカウントからなる二次元可変長符号を符号化データに出力する手段と、
該絶対値がゼロでない場合は、該二次元可変長符号の後に該変換係数の正負の符号を符号化データに出力する手段とを構成する
ことを特徴とする画像符号化プログラムを記憶した媒体。
A medium storing an image encoding program for encoding an input image or a motion compensated prediction difference image as an encoding target signal,
When the program is read by a computer,
The signal to be encoded is divided into a high frequency band and a low frequency band in both the horizontal and vertical directions, and the low frequency components in both the horizontal and vertical directions are subdivided in the same manner, and the subdivision processing is recursively performed. Means for calculating a signal conversion coefficient to be encoded by repeating each specified number of times;
Means for quantizing each of the encoding target signal transform coefficients to calculate a quantized transform coefficient;
Between the quantized transform coefficients corresponding as spatially similar positions between the respective frequency bands, a hierarchical structure having a coefficient of the lowest frequency band as a trunk for each of the vertical component, horizontal component, and diagonal component Means for forming a tree that is a quadtree structure;
For each post-quantization transform coefficient in the tree, means for searching for a zero tree that is a subtree in which all the descendants of the post-quantization transform coefficient and the post-quantization transform coefficient have no significant coefficient;
In encoding a certain quantized transform coefficient other than the trunk of the tree in the tree and a sibling coefficient indicating a child coefficient of a parent coefficient of the quantized transform coefficient, a subtree whose trunk is the sibling coefficient is a zero tree. Is a value indicating that the sibling coefficients are all zero-tree trunks or not all zero-tree trunks, and which of the sibling coefficients are zero-tree If the map code indicating whether it is a trunk is not output to the encoded data and some of the sibling coefficients are zero tree trunks and some are values indicating that they are not zero tree trunks When the four sibling coefficients are within the vertical band, the upper left, upper right, lower left, and lower right are ordered. When the four sibling coefficients are within the horizontal band, the upper left, lower left, upper right, and lower right are ordered. In the angular band In the upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right, the four sibling coefficients are checked to see if they are the trunks of the zero tree, and variable length is selected according to the Z count of the sibling coefficients. Means for outputting a map code corresponding to the sibling coefficient to the encoded data while switching the encoding table;
For the transform coefficient that is not the trunk of the zero tree among the sibling coefficients, the Z count of the direct child coefficient of the transform coefficient is calculated, and a two-dimensional variable length code consisting of the absolute value of the transform coefficient and the Z count is encoded data. Means for outputting to
A medium storing an image encoding program, wherein, when the absolute value is not zero, means for outputting positive and negative codes of the transform coefficient to encoded data after the two-dimensional variable length code.
請求項9記載の画像符号化装置もしくはコンピュータ及び請求項11記載の画像符号化プログラムを記憶した媒体によって実現される画像符号化装置による符号化データを復号する画像復号プログラムを記憶した媒体であって、
前記プログラムはコンピュータに読み取られた際、該コンピュータ上に、
ある係数を復号対象係数として復号するに当たり、該復号対象係数の親係数を復号した際に復号済みの該復号対象係数の兄弟係数のZカウントを取り出す手段と、
該兄弟係数のZカウントが、該兄弟係数の全てがゼロツリーの幹ではないかあるいは全てがゼロツリーの幹であることを示す場合は、マップ符号を復号せず、兄弟係数のうちのいくつかはゼロツリーの幹で、いくつかはゼロツリーの幹ではないことを示している値である場合には、該兄弟係数のZカウントの値に応じて可変長符号化テーブルを切り替えてマップ符号を復号する手段と、
該マップ符号によりゼロツリーの幹ではないと示されている兄弟係数について、それぞれ、該兄弟係数の子供係数のZカウント及び復号対象係数の絶対値からなる二次元可変長符号を復号し、復号された該絶対値がゼロでない場合は該復号対象係数の正負の符号を復号し、該絶対値及び該正負の符号より復号係数値を算出し、同時に該兄弟係数の子供係数を復号する際に利用するために該Zカウントを記録する手段と、
該マップ符号によりゼロツリーの幹であると示されている兄弟係数については、ゼロツリーの幹の場所情報を記録する手段と、
それぞれ算出された兄弟係数の該復号係数値を該4つの兄弟係数が垂直方向の帯域内である場合には左上、右上、左下、右下の順に、水平方向の帯域内である場合には左上、左下、右上、右下の順に、対角方向の帯域内である場合には左上、右下、右上、左下あるいは左上、右下、左下、右上の順に復号係数メモリに記録する手段とを構成する
ことを特徴とする画像復号プログラムを記憶した媒体。
A medium storing an image decoding program for decoding encoded data by an image encoding apparatus realized by the image encoding apparatus or computer according to claim 9 and a medium storing the image encoding program according to claim 11. ,
When the program is read by a computer,
In decoding a certain coefficient as a decoding target coefficient, means for extracting the Z count of the sibling coefficient of the decoding target coefficient that has been decoded when decoding the parent coefficient of the decoding target coefficient;
If the Z-count of the sibling coefficients indicates that all of the sibling coefficients are not zero tree trunks or all are zero tree trunks, then no map code is decoded and some of the sibling coefficients are zero tree And a means for decoding the map code by switching the variable length coding table in accordance with the Z count value of the sibling coefficient, if some are values indicating that they are not zero tree trunks. ,
For each sibling coefficient indicated by the map code as not being a trunk of the zero tree, a two-dimensional variable length code consisting of the Z count of the child coefficient of the sibling coefficient and the absolute value of the coefficient to be decoded is decoded and decoded. When the absolute value is not zero, the sign of the decoding target coefficient is decoded, the decoding coefficient value is calculated from the absolute value and the sign of the sign, and is used for decoding the child coefficient of the sibling coefficient at the same time. Means for recording the Z count for:
For sibling coefficients indicated by the map code as being a zero tree trunk, means for recording the location information of the zero tree trunk;
The decoding coefficient values of the calculated sibling coefficients are the upper left, the upper right, the lower left, and the lower right when the four sibling coefficients are in the vertical band, and the upper left when the four sibling coefficients are in the horizontal band. And means for recording in the decoding coefficient memory in the order of upper left, lower right, upper right, lower left or upper left, lower right, lower left, upper right when in the diagonal band in the order of lower left, upper right, lower right A medium storing an image decoding program.
JP2000023890A 2000-02-01 2000-02-01 Image encoding method and image decoding method, image encoding device and image decoding device, and medium storing these programs Expired - Fee Related JP3660548B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2000023890A JP3660548B2 (en) 2000-02-01 2000-02-01 Image encoding method and image decoding method, image encoding device and image decoding device, and medium storing these programs

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2000023890A JP3660548B2 (en) 2000-02-01 2000-02-01 Image encoding method and image decoding method, image encoding device and image decoding device, and medium storing these programs

Publications (2)

Publication Number Publication Date
JP2001218209A JP2001218209A (en) 2001-08-10
JP3660548B2 true JP3660548B2 (en) 2005-06-15

Family

ID=18549975

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2000023890A Expired - Fee Related JP3660548B2 (en) 2000-02-01 2000-02-01 Image encoding method and image decoding method, image encoding device and image decoding device, and medium storing these programs

Country Status (1)

Country Link
JP (1) JP3660548B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6885774B2 (en) * 1999-10-28 2005-04-26 Lucent Technologies Inc. Coefficient computation in image compression using set partitioning in hierarchical trees
DE102004041664A1 (en) * 2004-08-27 2006-03-09 Siemens Ag Method for coding and decoding, as well as coding and decoding apparatus for video coding
US8331444B2 (en) * 2007-06-26 2012-12-11 Qualcomm Incorporated Sub-band scanning techniques for entropy coding of sub-bands
KR20190000920A (en) 2009-07-02 2019-01-03 톰슨 라이센싱 Methods and apparatus for video encoding and decoding binary sets using adaptive tree selection

Also Published As

Publication number Publication date
JP2001218209A (en) 2001-08-10

Similar Documents

Publication Publication Date Title
JP3970521B2 (en) Embedded quadtree wavelet in image compression
US6519284B1 (en) Encoding method for the compression of a video sequence
JP4111644B2 (en) Embedded encoding / decoding method and system
JP3108808B2 (en) Data compression system
JPH11163733A (en) Encoding method and device
JPH11191153A (en) Encoding method for wavelet transformation coefficient
JP2005218124A (en) Data compression system
Boujelbene et al. A comparative study of recent improvements in wavelet-based image coding schemes
CN1197381C (en) Video encoding method using wavelet decomposition
KR20040023606A (en) Method and apparatus for three-dimensional wavelet transform
Raja et al. Image compression using WDR & ASWDR techniques with different wavelet codecs
EP1705924A1 (en) Moving picture encoding method and device, and moving picture decoding method and device
US20090034624A1 (en) Method and Apparatus For a Multidimensional Discrete Multiwavelet Transform
JP3660558B2 (en) Image encoding method, image encoding device, and medium storing image encoding program
JP3660548B2 (en) Image encoding method and image decoding method, image encoding device and image decoding device, and medium storing these programs
George et al. A novel approach for image compression using zero tree coding
JP2000201353A (en) Image encoding method, image encoder and storage medium in which image encoding program is stored
Singh et al. Performance comparison of arithmetic and huffman coder applied to ezw codec
JP2000295622A (en) Moving picture coding method, moving picture coder, moving picture decoding method, moving picture decoder and storage medium storing program for them
Strutz et al. Predictive image-coding with adaptive wavelet transform
Corona et al. Efficient random access high resolution region-of-interest (ROI) image retrieval using backward coding of wavelet trees (BCWT)
Mueller et al. Embedded Laplacian pyramid still image coding using zerotrees
JP2002135781A (en) Image encoding apparatus, image decoding apparatus methods for them and recording medium
Talukder et al. An Improved Concurrent Multi-Threaded Wavelet Transform Based Image Compression and Transmission Over Internet
JPH11103460A (en) Image processor, method and storage medium

Legal Events

Date Code Title Description
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: 20050315

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20050317

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080325

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090325

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090325

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100325

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110325

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees