JP2011109364A - Image processing apparatus - Google Patents

Image processing apparatus Download PDF

Info

Publication number
JP2011109364A
JP2011109364A JP2009261670A JP2009261670A JP2011109364A JP 2011109364 A JP2011109364 A JP 2011109364A JP 2009261670 A JP2009261670 A JP 2009261670A JP 2009261670 A JP2009261670 A JP 2009261670A JP 2011109364 A JP2011109364 A JP 2011109364A
Authority
JP
Japan
Prior art keywords
syntax element
value
mvd
index
submb
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2009261670A
Other languages
Japanese (ja)
Inventor
Toshiyuki Kaya
俊之 加谷
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.)
Renesas Electronics Corp
Original Assignee
Renesas Electronics 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 Renesas Electronics Corp filed Critical Renesas Electronics Corp
Priority to JP2009261670A priority Critical patent/JP2011109364A/en
Publication of JP2011109364A publication Critical patent/JP2011109364A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To reduce capacity of a syntax element memory. <P>SOLUTION: In a CABAC decoder 100, an index generation part 114 determines one of an absolute value of an mvd syntax element of a reference submb stored in the syntax element memory 112, twice the absolute value, and 1/2 of the absolute value as an index value before generating a context index when a context index is generated. A syntax element replacement part 150 determines whether the index value becomes "0" irrespective of the value of the mvd syntax element when the mvd syntax element of the reference submb is stored in the syntax element memory 112, and when it is determined that the index value becomes "0", replaces the mvd syntax element of the reference submb with "0" to be stored in the syntax element memory 112. <P>COPYRIGHT: (C)2011,JPO&INPIT

Description

本発明は、画像処理、具体的にはCABAC符号化または復号化技術に関する。   The present invention relates to image processing, specifically CABAC encoding or decoding technology.

国際標準のITU−T Rec.H.264|ISO/IEC 14496−10(以下略してH.264という)で規定された動画像の符号化/復号化方式は、携帯電話などの低ビットレート用途からHDTVなどの高ビットレート用途まで幅広く利用されている(非特許文献1、特許文献1、特許文献2)。H.264では、エントロピー符号化方式として、CAVLC(Context−based Adaptive Variable Length Coding:コンテキスト適応可変長符号化)とCABAC(Context−based Adaptive Binary Arithmetic Coding:コンテキスト適応二値算術符号化)のいずれかが選択できるようになっている。符号化に際しては、シンタックスエレメントと呼ばれ、ビデオエンコーダにより動画像から得られた各種データに対して、CABACまたはCAVLCで符号化してビットストリームを得る。復号化に際しては、ビットストリームに含まれる情報が示す符号化方式(CABACまたはCAVLC)に応じてCABACデコーダまたはCAVLCデコーダによりビットストリームからシンタックスエレメントを得てビデオデコーダに出力し、ビデオデコーダによりシンタックスエレメントから動画像を得る。   International standard ITU-T Rec. H. H.264 | ISO / IEC 14496-10 (hereinafter abbreviated as H.264) is a wide range of video encoding / decoding methods from low bit rate applications such as mobile phones to high bit rate applications such as HDTV. (Non-patent Document 1, Patent Document 1, Patent Document 2). H. In H.264, as entropy coding methods, CAVLC (Context-based Adaptive Variable Length Coding) and CABAC (Context-based Adaptive Binary Arithmetic Coding) are selected. It can be done. When encoding, it is called a syntax element, and various data obtained from a moving image by a video encoder is encoded by CABAC or CAVLC to obtain a bit stream. When decoding, the CABAC decoder or CAVLC decoder obtains a syntax element from the bit stream in accordance with the encoding method (CABAC or CAVLC) indicated by the information included in the bit stream, outputs the syntax element to the video decoder, and the video decoder uses the syntax. A moving image is obtained from the element.

符号化と復号化は、互いに逆順の処理である。ここで復号時の処理を代表にして説明する。   Encoding and decoding are processes in reverse order. Here, processing at the time of decoding will be described as a representative.

図10は、H.264に準拠したビットストリームデコーダ10を示す。ビットストリームデコーダ10は、エントロピーデコーダ20とビデオデコーダ70を備える。エントロピーデコーダ20は、CABACデコーダ30とCAVLCデコーダ60を有する。   FIG. 1 shows a bit stream decoder 10 compliant with H.264. The bit stream decoder 10 includes an entropy decoder 20 and a video decoder 70. The entropy decoder 20 includes a CABAC decoder 30 and a CAVLC decoder 60.

入力されたビットストリームに対して、エントロピーデコーダ20は、CABACデコーダ30とCAVLCデコーダ60のいずれかにより復号を行って、シンタックスエレメントを得る。シンタックスエレメントは、符号化モードや、動きベクトルや、画素データなど、ビデオデコーダ70の処理に必要なデータである。   The entropy decoder 20 decodes the input bit stream by either the CABAC decoder 30 or the CAVLC decoder 60 to obtain a syntax element. The syntax element is data necessary for processing of the video decoder 70, such as an encoding mode, a motion vector, and pixel data.

ビデオデコーダ70は、シンタックスエレメントを用いてデコードし、動画像を構成する各フレームの画像を得る。   The video decoder 70 decodes using the syntax element to obtain an image of each frame constituting the moving image.

H.264では、符号化と復号化は、フレームを格子状に分割して得たマクロブロック単位に行うように規定されており、1つのマクロブロックは、輝度画素換算するとそのサイズが16画素×16画素である。例えば、フルHDサイズ(1920画素×1080画素)のフレームは、水平120マクロブロック、垂直68マクロブロックに分割されて、マクロブロック毎に順次処理される。マクロブロックの処理順序についてはnon−MBAFFとMBAFFの2つのモードが規定されている。   H. In H.264, encoding and decoding are defined to be performed in units of macroblocks obtained by dividing a frame into a lattice shape, and each macroblock has a size of 16 pixels × 16 pixels when converted to luminance pixels. It is. For example, a frame of full HD size (1920 pixels × 1080 pixels) is divided into horizontal 120 macroblocks and vertical 68 macroblocks, and sequentially processed for each macroblock. Two modes of non-MBAFF and MBAFF are defined for the processing order of macroblocks.

図11は、non−MBAFFモード時に復号化する際のマクロブロックの処理順序を示す。このモードの場合は、行毎に、上の行ほど先に処理され、同一の行においては左のマクロブロックほど先に処理される。図11に示すように、まず、1行目の左端すなわちフレームの最左端から、水平方向に1つずつ進む順にマクロブロックが処理される。該行の最右端のマクロブロックの処理が終わったら、1つ下の行に対して、再び最左端から、水平方向に1つずつ進む順にマクロブロックが処理されていく。   FIG. 11 shows the processing order of macroblocks when decoding in the non-MBAFF mode. In this mode, the upper line is processed earlier for each line, and the left macroblock is processed earlier in the same line. As shown in FIG. 11, first, macroblocks are processed in the order of progressing one by one in the horizontal direction from the left end of the first row, that is, the leftmost end of the frame. When the processing of the rightmost macroblock in the row is completed, the macroblocks are processed in the order of proceeding one by one in the horizontal direction from the leftmost again with respect to the next lower row.

図12は、MBAFFモード時に復号する際のマクロブロックの処理順序を示す。このモードの場合には、隣接する2行毎に処理される。説明上の便宜のため、この2行を以下グループという。上のグループほど先に処理され、同一のグループ内では、上の行に位置するマクロブロックほど、かつ左に位置するマイクロほど先に処理される。図12に示すように、まず、1行目の左端のマクロブロックが処理され、次に2行目の左端のマクロブロックが処理される。そして、1行目の2列目のマクロブロック、2行目の2列目のマクロブロック、1行目の3列目のマクロブロック、・・・の順に処理がなされる。   FIG. 12 shows the processing order of macroblocks when decoding in the MBAFF mode. In this mode, processing is performed every two adjacent rows. For convenience of explanation, these two lines are referred to as a group below. The upper group is processed first, and within the same group, the macroblock located in the upper row and the micro located on the left are processed earlier. As shown in FIG. 12, first, the leftmost macroblock in the first row is processed, and then the leftmost macroblock in the second row is processed. Then, the processing is performed in the order of the macroblock in the second column in the first row, the macroblock in the second column in the second row, the macroblock in the third column in the first row, and so on.

図13は、CABACデコーダ30を示す。CABACデコーダ30は、算術デコーダ40と二値デコーダ50を有する。算術デコーダ40は、ビットストリームを入力し、デコード対象のシンタックスエレメント毎に割り当てられたコンテキストを用いて算術符号化を行って「bin」と呼ばれる二値データの列を得る。二値デコーダ50は、算術デコーダ40からのbin列を入力して、シンタックスエレメントを得て出力する。二値デコーダ50により得られたシンタックスエレメントは、ビデオデコーダ70に出力されると共に、その一部は算術デコーダ40にフィードバックされる。この一部のシンタックスエレメントは、後にデコードされるマクロブロックの動きベクトルを求めるための各シンタックスエレメントが含まれている。   FIG. 13 shows the CABAC decoder 30. The CABAC decoder 30 includes an arithmetic decoder 40 and a binary decoder 50. The arithmetic decoder 40 inputs a bit stream, performs arithmetic coding using a context assigned to each syntax element to be decoded, and obtains a binary data string called “bin”. The binary decoder 50 receives the bin string from the arithmetic decoder 40, obtains a syntax element, and outputs it. The syntax element obtained by the binary decoder 50 is output to the video decoder 70 and a part thereof is fed back to the arithmetic decoder 40. This part of syntax elements includes each syntax element for obtaining a motion vector of a macroblock to be decoded later.

図14は、算術デコーダ40の構成を示す。算術デコーダ40は、シンタックスエレメントメモリ42と、インデックス生成器44と、二値算術デコーダ46と、コンテキストメモリ48を有する。   FIG. 14 shows the configuration of the arithmetic decoder 40. The arithmetic decoder 40 includes a syntax element memory 42, an index generator 44, a binary arithmetic decoder 46, and a context memory 48.

シンタックスエレメントメモリ42は、二値デコーダ50からフィードバックされた、デコード済みのマクロブロックの各シンタックスエレメントを記憶する   The syntax element memory 42 stores each syntax element of the decoded macroblock fed back from the binary decoder 50.

コンテキストメモリ48は、各種シンタックスエレメントに割り当てられたコンテキストを記憶する。コンテキストは、算術符号化で用いられる確率や出力ビット値などであり、二値算術デコーダ46による復号に必要である。コンテキストメモリ48に記憶されたコンテキストは、1つのbinを得る毎にコンテキストメモリ48からの読出し、次のbinを得るために二値算術デコーダ46での使用と更新、コンテキストメモリ48への書戻しがなされる。   The context memory 48 stores contexts assigned to various syntax elements. The context is a probability or an output bit value used in arithmetic coding, and is necessary for decoding by the binary arithmetic decoder 46. The context stored in the context memory 48 is read from the context memory 48 every time one bin is obtained, used and updated by the binary arithmetic decoder 46 to obtain the next bin, and written back to the context memory 48. Made.

インデックス生成器44は、シンタックスエレメントメモリ42に記憶されたデコード済みのマクロブロックのシンタックスエレメントを用いて、コンテキストメモリ48における、該シンタックスエレメントに対応するコンテキストのアドレスを示すコンテキストインデックス(以下単にインデックスともいう)を生成して二値算術デコーダ46に供する。   The index generator 44 uses a decoded macroblock syntax element stored in the syntax element memory 42 to use a context index (hereinafter simply referred to as a context index) indicating the address of the context corresponding to the syntax element in the context memory 48. (Also referred to as an index) is generated and provided to the binary arithmetic decoder 46.

二値算術デコーダ46は、コンテキストメモリ48から、インデックス生成器44が生成したインデックスが示すアドレスに記憶されたコンテキストを読み出して、算術復号を行ってbinを得ると共に、復号時に更新した該コンテキストをコンテキストメモリ48の上記アドレスに書き戻す。   The binary arithmetic decoder 46 reads the context stored at the address indicated by the index generated by the index generator 44 from the context memory 48, performs arithmetic decoding to obtain bin, and uses the context updated at the time of decoding as the context. Write back to the above address in the memory 48.

H.264では、図11に示すnon−MBAFFモードで復号する際に、既にデコード済みのマクロブロックのうちの、デコード対象のマクロブロックの隣接する2つのマクロブロックのシンタックスエレメントを用いることが規定されている。例えば、図11に示すマクロブロック「Ck」を復号する際に、マクロブロック「Bk」と「C(k−1)」のシンタックスエレメントが用いられる。また、マクロブロック「C(k+1)」を復号する際に、マクロブロック「B(k+1)」と「Ck」のシンタックスエレメントが用いられる。すなわち、non−MBAFFで復号する場合に、シンタックスエレメントメモリ42は、1行分のマクロブロックのシンタックスエレメントを記憶する必要がある。図11に示す例の場合には、w個のマクロブロックのシンタックスエレメントがシンタックスエレメントメモリ42に記憶されることになる。   H. H.264 specifies that syntax elements of two macroblocks adjacent to a decoding target macroblock among the already decoded macroblocks are used when decoding in the non-MBAFF mode shown in FIG. Yes. For example, when decoding the macroblock “Ck” shown in FIG. 11, the syntax elements of the macroblocks “Bk” and “C (k−1)” are used. In addition, when the macroblock “C (k + 1)” is decoded, the syntax elements of the macroblocks “B (k + 1)” and “Ck” are used. That is, when decoding by non-MBAFF, the syntax element memory 42 needs to store the syntax elements of one row of macroblocks. In the case of the example shown in FIG. 11, the syntax elements of w macroblocks are stored in the syntax element memory 42.

以下の説明において、あるマクロブロックをデコードする際に、シンタックスエレメントを参照されるマクロブロックを「参照MB」という。また、デコードされるマクロブロックを「注目マクロブロック」という。例えば図11に示す例において、注目マクロブロック「C(k+1)」に対して、マクロブロック「B(k+1)」と「Ck」は、参照MBになる。   In the following description, a macroblock to which a syntax element is referenced when a certain macroblock is decoded is referred to as a “reference MB”. A macroblock to be decoded is referred to as a “target macroblock”. For example, in the example illustrated in FIG. 11, for the target macroblock “C (k + 1)”, the macroblocks “B (k + 1)” and “Ck” are reference MBs.

図12に示すMBAFFモードで復号する際に、マクロブロック「Ck」と「Dk」の復号に、マクロブロック「Ak」、「Bk」、「C(k−1)」、「D(k−1)」のシンタックスエレメントが必要であり、マクロブロック「C(k+1)」と「D(k+1)」の復号に、マクロブロック「A(k+1)」、「B(k+1)」、「Ck」、「Dk」のシンタックスエレメントが必要である。すなわち、MBAFFモードで復号する場合には、シンタックスエレメントメモリ42は、2行分のマクロブロックのシンタックスエレメントを記憶する必要がある。図12に示す例の場合には、「2×w」個のマクロブロックのシンタックスエレメントがシンタックスエレメントメモリ42に記憶されることになる。   When decoding in the MBAFF mode shown in FIG. 12, the macroblocks “Ck” and “Dk” are decoded using the macroblocks “Ak”, “Bk”, “C (k−1)”, “D (k−1) ) ”Syntax element is required, and the macroblocks“ C (k + 1) ”,“ B (k + 1) ”,“ Ck ”,“ Ck ”, The “Dk” syntax element is required. That is, when decoding in the MBAFF mode, the syntax element memory 42 needs to store the syntax elements of macroblocks for two rows. In the case of the example illustrated in FIG. 12, “2 × w” macroblock syntax elements are stored in the syntax element memory 42.

シンタックスエレメントの種類は多数であり、1つのマクロブロックにつき、多数のシンタックスエレメントがある。ここでシンタックスエレメントの1種である動きベクトル差分(mvd)に注目してみる。   There are many types of syntax elements, and there are many syntax elements per macroblock. Here, attention is paid to a motion vector difference (mvd) which is one type of syntax element.

マクロブロックの動きベクトルを導出するために該マクロブロックの動きベクトル差分mvdを求める必要がある。動きベクトル差分mvdを表すシンタックスエレメントを以下mvdシンタックスエレメントという。mvdシンタックスエレメントは、動きベクトル差分mvdの水平成分と垂直成分をそれぞれ表すmvd「vertical」とmvd「horizontal」に分けられ、mvd「vertical」とmvd「horizontal」は、さらにmvd_l0とmvd_l1の2種類に分けられている。これら各種のmvdシンタックスエレメントは、マクロブロックを分割して得た各サブマクロブロック毎に割り当てられる。なお、H.264では、1マクロブロックにつきサブマクロブロックの最大数が16(4×4)である。以下の説明において、参照MBにおける各サブマクロブロックを参照submbという。   In order to derive the motion vector of the macroblock, it is necessary to obtain the motion vector difference mvd of the macroblock. The syntax element representing the motion vector difference mvd is hereinafter referred to as mvd syntax element. The mvd syntax element is divided into mvd “vertical” and mvd “horizontal” representing the horizontal component and vertical component of the motion vector difference mvd, respectively. mvd “vertical” and mvd “horizontal” are further divided into two types, mvd_l0 and mvd_l1. It is divided into. These various mvd syntax elements are assigned to each sub-macroblock obtained by dividing a macroblock. H. In H.264, the maximum number of sub-macroblocks per macroblock is 16 (4 × 4). In the following description, each sub macroblock in the reference MB is referred to as a reference submb.

CABACデコーダ30は、注目マクロブロックの動きベクトルをデコードするために、サブマクロブロック毎に各種mvdシンタックスエレメントを求める。図15は、CABACデコーダ30が注目マクロブロックの動きベクトルをデコードする際に、参照マクロブロック毎に必要なシンタックスエレメントを示す。図示のように、1参照ブロックにつき、各参照submbのシンタックスエレメント以外に、該参照ブロックの別の4個のシンタックスエレメント(1つのmb_skip_flag、1つのmb_type、2つのsub_mb_type)が必要である。これらのシンタックスエレメントの総ビット数は、239ビットである。   The CABAC decoder 30 obtains various mvd syntax elements for each sub macroblock in order to decode the motion vector of the target macroblock. FIG. 15 shows syntax elements required for each reference macroblock when the CABAC decoder 30 decodes the motion vector of the target macroblock. As shown in the figure, for each reference block, in addition to the syntax element of each reference submb, another four syntax elements of the reference block (one mb_skip_flag, one mb_type, and two sub_mb_types) are necessary. The total number of bits of these syntax elements is 239 bits.

算術デコーダ40は、codIRANGE(以下Rという)と、codIRangeLPS(以下Lという)と、codIOffsetの3つの変数の値の大小関係に応じてデコードを行ってbinを得る。RはCABACデコードの開始時に初期値を与えられる変数であり、Lはコンテキストメモリ48から選択されたコンテキストから規定の式で値を導かれる変数であり、codIOffsetはビットストリームにより値を与えられる変数である。デコードに際して、算術デコーダ40は、codIOffsetが「R−L」以上のときには「bin=!valMPS」を出力し、codIOffsetが「R−L」より小さいときに「bin=valMPS」を出力する。valMPSは、コンテキストメモリ48から選択されたコンテキストから導かれる変数であり、0または1を表す。また、算術デコーダ40は、コンテキストメモリ48から選択されたコンテキストから規定の式で導き出した変数Lおよび変数valMPSの値を、該コンテキストの更新された値としてコンテキストメモリ48に書き戻す。   The arithmetic decoder 40 performs decoding according to the magnitude relationship of the values of the three variables codIRANGE (hereinafter referred to as R), codIRrangeLPS (hereinafter referred to as L), and codIOoffset to obtain bin. R is a variable which is given an initial value at the start of CABAC decoding, L is a variable whose value is derived from the context selected from the context memory 48 with a specified expression, and codIOoffset is a variable whose value is given by the bitstream. is there. At the time of decoding, the arithmetic decoder 40 outputs “bin =! ValMPS” when codIOoffset is “RL” or more, and outputs “bin = valMPS” when codIOoffset is smaller than “RL”. The valMPS is a variable derived from the context selected from the context memory 48 and represents 0 or 1. In addition, the arithmetic decoder 40 writes back the values of the variable L and the variable valMPS derived from the context selected from the context memory 48 by a specified expression in the context memory 48 as updated values of the context.

図16と図17を参照して、算術デコーダ40がコンテキストメモリ48からコンテキストを選択するために用いるコンテキストインデックスを生成するインデックス生成器44の処理を説明する。インデックス生成器44は、mvdシンタックスエレメント毎にインデックスを求める。以下において、「mvd_lx」により、mvd_l0「vertical」、mvd_l1「vertical」、mvd_l0「horizontal」、mvd_l1「horizontal」のいずれかを表す。   The processing of the index generator 44 that generates a context index used by the arithmetic decoder 40 to select a context from the context memory 48 will be described with reference to FIGS. 16 and 17. The index generator 44 obtains an index for each mvd syntax element. Hereinafter, mvd_l0 “vertical”, mvd_l1 “vertical”, mvd_10 “horizontal”, and mvd_l1 “horizontal” are represented by “mvd_lx”.

図16において、実線枠はマクロブロックを示し、点線枠は、各マクロブロックを4×4に分割して得たサブマクロブロック(図中sub_mb)を示す。前述したように、マクロブロックCのデコードに際して、マクロブロックAとマクロブロックBが参照MBになる。   In FIG. 16, a solid line frame indicates a macro block, and a dotted line frame indicates a sub macro block (sub_mb in the figure) obtained by dividing each macro block into 4 × 4. As described above, when the macroblock C is decoded, the macroblock A and the macroblock B become reference MBs.

インデックス生成器44は、マクロブロックCに対して、サブマクロブロック毎にコンテキストインデックスを求める。1つのサブマクロブロックのコンテキストインデックスの算出には、2つの参照submbのシンタックスエレメントが用いられる。例えば、図16に示す例において、注目マクロブロック(マクロブロックC)のサブマクロブロックcのコンテキストインデックスを求める際に、参照MBであるマクロブロックAのサブマクロブロックaと、参照MBであるマクロブロックBのサブマクロブロックbが参照submbになり、それらのmvdシンタックスエレメントが用いられる。   The index generator 44 obtains a context index for each sub-macroblock for the macroblock C. For calculating the context index of one sub macroblock, syntax elements of two reference submbs are used. For example, in the example shown in FIG. 16, when the context index of the sub macroblock c of the target macroblock (macroblock C) is obtained, the submacroblock a of the macroblock A that is the reference MB and the macroblock that is the reference MB B's sub-macroblock b becomes the reference submb, and their mvd syntax elements are used.

図17は、インデックス生成器44がサブマクロブロックcのmvd_lxについてコンテキストインデックスを求める際のフローチャートを示す。まず、該サブマクロブロックの2つの参照submbのうちの一方(図中block a)のシンタックスエレメントを用いて指標値A(図17における「absMvdCompA」)を求める(S10)。次に、他方の参照submb(図中block b)のシンタックスエレメントを用いて指標値Bを求める(S20)。そして、指標値Aと指標値Bの和を、複数の閾値と比較することにより、サブマクロブロックcのmvd_lxのコンテキストインデックスを決定する(S30)。   FIG. 17 shows a flowchart when the index generator 44 obtains a context index for mvd_lx of the sub macroblock c. First, an index value A (“absMvdCompA” in FIG. 17) is obtained using a syntax element of one of the two reference submbs (block a in the figure) of the sub macroblock (S10). Next, the index value B is obtained using the syntax element of the other reference submb (block b in the figure) (S20). Then, the context index of mvd_lx of the sub macroblock c is determined by comparing the sum of the index value A and the index value B with a plurality of threshold values (S30).

ステップS30において、インデックス生成器44は、具体的には、指標値Aと指標値Bの和が第1の閾値(閾値TH0)未満である場合に「ctxIdxInc=0」、指標値Aと指標値Bの和が第2の閾値(閾値TH1)より大きい場合に「ctxIdxInc=2」、指標値Aと指標値Bの和が閾値TH0以上閾値TH1以下である場合に「ctxIdxInc=1」となるようにctxIdxIncの値を決定する。なお、mvd_lx毎に異なるベースアドレスが付与されており、mvd_lxのベースアドレスと、該mvd_lxに対して求められた上記ctxIdxIncとの和が、該mvd_lxのコンテキストインデックスになる。説明上の便宜のため、以下、ctxIdxIncとコンテキストインデックスとを同じ意味で用いる。   In step S30, specifically, the index generator 44 sets “ctxIdxInc = 0”, the index value A and the index value when the sum of the index value A and the index value B is less than the first threshold value (threshold value TH0). “CtxIdxInc = 2” when the sum of B is larger than the second threshold (threshold TH1), and “ctxIdxInc = 1” when the sum of the index value A and the index value B is greater than or equal to the threshold TH0 and less than or equal to the threshold TH1. Determine the value of ctxIdxInc. A different base address is assigned to each mvd_lx, and the sum of the base address of mvd_lx and the ctxIdxInc obtained for the mvd_lx is the context index of the mvd_lx. For convenience of explanation, ctxIdxInc and context index are used in the same meaning hereinafter.

図18は、図17におけるステップS10及びステップS20の詳細を示す。図18において、指標値N(absMvdCompN)は指標値Aと指標値Bに対応する。図中「block n」が参照submbを示し、図中「MB N」は、該参照submbが属するマクロブロック(すなわち参照MB)を示す。なお、図18は、H.264で定められた当該処理をフローチャートで示したものであり、ここで概要のみを説明し、詳細については規格を参照されたい。   FIG. 18 shows details of step S10 and step S20 in FIG. In FIG. 18, the index value N (absMvdCompN) corresponds to the index value A and the index value B. In the figure, “block n” indicates a reference submb, and in the figure, “MB N” indicates a macroblock (that is, a reference MB) to which the reference submb belongs. Note that FIG. The process defined in H.264 is shown in a flowchart, and only the outline will be described here, and refer to the standard for details.

図18に示すように、まず、ステップS100〜S126の処理が行われる。これらの処理は、複数の判定ステップを経て、参照submbのmvd_lxの値に関わらず、absMvdCompNが「0」になるか否かの判定結果を得る。判定ステップS126において、判定の結果が「Yes」である場合には、該参照submbの指標値N(absMvdCompN)が「0」に決定される(S128)。   As shown in FIG. 18, first, the processes of steps S100 to S126 are performed. These processes go through a plurality of determination steps to obtain a determination result as to whether or not absMvdCompN is “0” regardless of the value of mvd_lx of the reference submb. In the determination step S126, when the determination result is “Yes”, the index value N (absMvdCompN) of the reference submb is determined to be “0” (S128).

判定ステップS126において、判定の結果が「No」である場合には、処理がステップS130に移行する。そして、ステップS130〜S144の処理により、指標値Nは、参照submbのmvd_lxの絶対値(S132、S144)、参照submbのmvd_lxの絶対値の2倍(S138)、参照submbのmvd_lxの絶対値の1/2(S142)のいずれかに決定される。   In the determination step S126, when the determination result is “No”, the process proceeds to step S130. Then, through the processing of steps S130 to S144, the index value N is the absolute value of mvd_lx of the reference submb (S132, S144), twice the absolute value of mvd_lx of the reference submb (S138), and the absolute value of mvd_lx of the reference submb. 1/2 (S142) is determined.

米国特許7286710号公報US Pat. No. 7,286,710 米国特許7469070号公報US Pat. No. 7,469,070

ITU−T Rec.H.264|ISO/IEC 14496−10ITU-T Rec. H. H.264 | ISO / IEC 14496-10

前述したように、シンタックスエレメントは多種類がある。コンテキストインデックの生成のために、シンタックスエレメントメモリ42には、non−MBAFFモードとMBAFFモードの場合にそれぞれ1行分または2行分のマクロブロックのシンタックスエレメントが格納される。注目ブロックの動きベクトルをデコードするために、図15に示すように、1参照MB当たりに239ビット分のシンタックスエレメントが必要であるため、non−MBAFFモード時には「239×w」ビット(w:1行のマクロブロック数)、MBAFFモード時には「239×2×w」ビットのシンタックスエレメントがシンタックスエレメントメモリ42に格納される。動画像の1フレームのサイズが1920画素×1080画素である場合には、動きベクトルのデコードのために、シンタックスエレメントメモリ42に保存される参照ブロックのシンタックスエレメントのサイズが7170Byteになる。これでは、必要とするシンタックスエレメントメモリ42の容量が大きい。   As described above, there are many types of syntax elements. In order to generate a context index, the syntax element memory 42 stores macroblock syntax elements for one row or two rows in the non-MBAFF mode and the MBAFF mode, respectively. In order to decode the motion vector of the block of interest, as shown in FIG. 15, 239 bits of syntax elements are required for each reference MB. Therefore, in the non-MBAFF mode, “239 × w” bits (w: In the MBAFF mode, a “239 × 2 × w” -bit syntax element is stored in the syntax element memory 42. When the size of one frame of the moving image is 1920 pixels × 1080 pixels, the size of the syntax element of the reference block stored in the syntax element memory 42 is 7170 bytes for decoding the motion vector. In this case, the required capacity of the syntax element memory 42 is large.

本発明は、上記事情に鑑みてなされたものであり、参照マクロブロックのシンタックスエレメントを格納するシンタックスエレメントメモリの容量を削減することができる技術を提供する。   The present invention has been made in view of the above circumstances, and provides a technique capable of reducing the capacity of a syntax element memory that stores a syntax element of a reference macroblock.

本発明の一つの態様は、CABAC符号化またはCABAC復号化により動きベクトルの符号化または復号化をマクロブロック毎に順次行う画像処理装置である。この画像処理装置は、シンタックスエレメントメモリと、コンテキストメモリと、インデックス生成部と、シンタックスエレメント置換部を備える。   One aspect of the present invention is an image processing apparatus that sequentially encodes or decodes motion vectors for each macroblock by CABAC encoding or CABAC decoding. The image processing apparatus includes a syntax element memory, a context memory, an index generation unit, and a syntax element replacement unit.

シンタックスエレメントメモリは、参照MBの複数のシンタックスエレメントを格納する。参照MBは、注目マクロブロックの符号化または復号時に上記複数のシンタックスエレメントを参照されるマクロブロックである。これらの複数のシンタックスエレメントは、該参照MBを分割して得たサブマクロブロックである参照submb毎の各種動きベクトル差分をそれぞれ表す各種mvdシンタックスエレメントを含む。   The syntax element memory stores a plurality of syntax elements of the reference MB. The reference MB is a macroblock to which the plurality of syntax elements are referred when the target macroblock is encoded or decoded. The plurality of syntax elements include various mvd syntax elements respectively representing various motion vector differences for each reference submb that is a sub macroblock obtained by dividing the reference MB.

コンテキストメモリは、mvdシンタックスエレメント毎に割り当てられたコンテキストを格納する。   The context memory stores a context assigned to each mvd syntax element.

インデックス生成部は、注目マクロブロックの各サブマクロブロックについて、各mvdシンタックスエレメントにそれぞれ対応するコンテキストがコンテキストメモリに格納されたアドレスを示すコンテキストインデックスを生成する。その際、該サブマクロブロックに対応する2つの参照submbの指標値をそれぞれ求め、求められた2つの指標値の和に基づいてコンテキストインデックスを生成する。また、インデックス生成部は、シンタックスエレメントメモリに格納された、参照submbの該mvdシンタックスエレメントの絶対値と、該絶対値の2倍と、該絶対値の1/2のうちのいずれか1つを該参照submbの指標値として求める。   The index generation unit generates a context index indicating an address at which a context corresponding to each mvd syntax element is stored in the context memory for each sub macroblock of the target macroblock. At that time, index values of two reference submbs corresponding to the sub-macroblock are obtained, respectively, and a context index is generated based on the sum of the obtained two index values. Further, the index generation unit is any one of an absolute value of the mvd syntax element of the reference submb stored in the syntax element memory, twice the absolute value, and 1/2 of the absolute value. Are determined as index values of the reference submb.

シンタックスエレメント置換部は、参照submbのmvdシンタックスエレメントをシンタックスエレメントメモリに格納する際に、該mvdシンタックスエレメントの値に関わらず、該参照submbの上記指標値が「0」になるか否かの判定をすると共に、指標値が「0」になると判定したときに、該mvdシンタックスエレメントを「0」に置換えてシンタックスエレメントメモリに格納する。それ以外の場合には置換えをせずにmvdシンタックスエレメントをシンタックスエレメントメモリに格納する。   When the syntax element replacement unit stores the mvd syntax element of the reference submb in the syntax element memory, does the index value of the reference submb become “0” regardless of the value of the mvd syntax element? In addition to determining whether the index value is “0”, the mvd syntax element is replaced with “0” and stored in the syntax element memory. Otherwise, the mvd syntax element is stored in the syntax element memory without replacement.

本発明の別の態様も、CABAC符号化またはCABAC復号化により動きベクトルの符号化または復号化をマクロブロック毎に順次行う画像処理装置である。この画像処理装置は、シンタックスエレメントメモリと、コンテキストメモリと、インデックス生成部と、シンタックスエレメント置換部を備える。   Another aspect of the present invention is also an image processing apparatus that sequentially encodes or decodes a motion vector for each macroblock by CABAC encoding or CABAC decoding. The image processing apparatus includes a syntax element memory, a context memory, an index generation unit, and a syntax element replacement unit.

シンタックスエレメントメモリとコンテキストメモリは、上述した態様の画像処理装置におけるものと同様である。   The syntax element memory and the context memory are the same as those in the above-described image processing apparatus.

インデックス生成部は、注目マクロブロックの各サブマクロブロックについて、各mvdシンタックスエレメントのコンテキストインデックスを生成する際に、該サブマクロブロックに対応する2つの参照submbの指標値をそれぞれ求め、求められた2つの指標値の和に基づいてコンテキストインデックスを生成する。その際、該2つの指標値の和が第1の閾値未満であるときと、第2の閾値より大きいときと、他のときとにおいて異なる値のコンテキストインデックスをそれぞれ生成する。なお、第2の閾値は、第1の閾値より大きい値である。   When generating the context index of each mvd syntax element for each sub-macroblock of the target macroblock, the index generation unit obtains the index values of the two reference submbs corresponding to the sub-macroblock. A context index is generated based on the sum of two index values. At this time, context indexes having different values are generated when the sum of the two index values is less than the first threshold, when it is greater than the second threshold, and at other times. Note that the second threshold value is larger than the first threshold value.

シンタックスエレメント置換部は、式(1)が示す第3の閾値以上である参照submbのmvdシンタックスエレメントの値を、該mvdシンタックスエレメントの値より小さく、式(1)に示すP以上の任意の値に置換えてシンタックスエレメントメモリに格納する。
第3の閾値≧P=(第2の閾値+1)×2 (1)
The syntax element replacement unit has a value of the mvd syntax element of the reference submb that is equal to or greater than the third threshold indicated by the expression (1) smaller than the value of the mvd syntax element, and is equal to or greater than P indicated in the expression (1) Replace with an arbitrary value and store in the syntax element memory.
Third threshold ≧ P = (second threshold + 1) × 2 (1)

なお、上記態様の装置を方法やシステムに置換えて表現したもの、コンピュータを該装置の一部として実行せしめるプログラムなども、本発明の態様としては有効である。   Note that a representation in which the apparatus of the above aspect is replaced with a method or system, a program that causes a computer to be executed as a part of the apparatus, and the like are also effective as an aspect of the present invention.

本発明にかかる技術によれば、シンタックスエレメントメモリの容量を削減できる。   According to the technique according to the present invention, the capacity of the syntax element memory can be reduced.

本発明の技術にかかる第1の手法を説明するためのフローチャートである(その1)。It is a flowchart for demonstrating the 1st method concerning the technique of this invention (the 1). 図1に示すフローチャートの等価フローチャートである。It is an equivalent flowchart of the flowchart shown in FIG. 本発明の技術にかかる第2の手法を説明するためのフローチャートである(その2)。It is a flowchart for demonstrating the 2nd method concerning the technique of this invention (the 2). 本発明の技術にかかる第1の手法によるシンタックスエレメントメモリの容量削減を説明するための図である。It is a figure for demonstrating the capacity reduction of the syntax element memory by the 1st method concerning the technique of this invention. 本発明の技術にかかる第3の手法を説明するための図である。It is a figure for demonstrating the 3rd method concerning the technique of this invention. 本発明の実施の形態にかかるCABACデコーダを示す図である。It is a figure which shows the CABAC decoder concerning embodiment of this invention. 図6に示すCABACデコーダにおけるシンタックスエレメント置換部の処理を示すフローチャートである。7 is a flowchart showing processing of a syntax element replacement unit in the CABAC decoder shown in FIG. 6. 図6に示すCABACデコーダにおけるインデックス生成部がコンテキストインデックスを生成するための指標値Nを求める処理を示すフローチャートである。FIG. 7 is a flowchart showing a process for obtaining an index value N for the index generation unit in the CABAC decoder shown in FIG. 6 to generate a context index. 図6に示すCABACデコーダによるシンタックスエレメントメモリの容量削減を説明するための図である。FIG. 7 is a diagram for explaining capacity reduction of the syntax element memory by the CABAC decoder shown in FIG. 6. H.264に準拠したビットストリームデコーダを示す図である。H. 1 is a diagram illustrating a bitstream decoder compliant with H.264. non−MBAFFモードを説明するための図である。It is a figure for demonstrating non-MBAFF mode. MBAFFモードを説明するための図である。It is a figure for demonstrating MBAFF mode. 図10に示すビットストリームデコーダにおけるCABACデコーダを示す図である。It is a figure which shows the CABAC decoder in the bit stream decoder shown in FIG. 図13に示すCABACデコーダにおける算術デコーダを示す図である。It is a figure which shows the arithmetic decoder in the CABAC decoder shown in FIG. 動きベクトルをデコードするために1参照マクロブロック当たりに必要なシンタックスエレメントを示す図である。It is a figure which shows the syntax element required per 1 reference macroblock in order to decode a motion vector. mvdシンタックスエレメントのコンテキストインデックスの算出を説明するための図である(その1)。It is a figure for demonstrating calculation of the context index of a mvd syntax element (the 1). mvdシンタックスエレメンのコンテキストインデックスの算出を説明するための図である(その2)。It is a figure for demonstrating calculation of the context index of a mvd syntax element (the 2). 図17のステップS10とS20を詳細に示す図である。It is a figure which shows step S10 and S20 of FIG. 17 in detail.

以下、図面を参照して本発明の実施の形態について説明する。説明の明確化のため、以下の記載及び図面は、適宜、省略、及び簡略化がなされている。また、様々な処理を行う機能ブロックとして図面に記載される各要素は、ハードウェア的には、CPU、メモリ、その他の回路で構成することができ、ソフトウェア的には、メモリにロードされたプログラムなどによって実現される。なお、各図面において、同一の要素には同一の符号が付されており、必要に応じて重複説明は省略されている。   Embodiments of the present invention will be described below with reference to the drawings. For clarity of explanation, the following description and drawings are omitted and simplified as appropriate. Each element described in the drawings as a functional block for performing various processes can be configured by a CPU, a memory, and other circuits in terms of hardware, and a program loaded in the memory in terms of software. Etc. Note that, in each drawing, the same element is denoted by the same reference numeral, and redundant description is omitted as necessary.

本発明の具体的な実施の形態を説明する前に、まず、本発明にかかる技術の原理を説明する。
本願発明者は、H.264で規定された方式で動画像を符号化または復号化する際に、注目マクロブロックの動きベクトルの符号化または復号化時に複数のシンタックスエレメントを参照される参照マクロブロック(参照MB)の上記複数のシンタックスエレメントを格納するシンタックスエレメントメモリの容量の削減について鋭意研究模索した結果、複数の知見を得ると共に、これらの知見に基づいた手法を確立した。以下、動きベクトルの復号時を例にして、これらの知見と手法を説明する。
Before describing specific embodiments of the present invention, first, the principle of the technology according to the present invention will be described.
The inventor of the present application The above-mentioned reference macroblock (reference MB) to which a plurality of syntax elements are referred when encoding or decoding a motion vector of a target macroblock when a moving image is encoded or decoded by a method defined in H.264. As a result of diligent research to reduce the capacity of the syntax element memory that stores multiple syntax elements, we have obtained multiple findings and established a method based on these findings. Hereinafter, these findings and methods will be described by taking the case of motion vector decoding as an example.

<第1の知見>
前述したように、注目マクロブロックのmvd_lxのコンテキストインデックスを求めるために、図17に示すように、まず、2つの参照submbについてそれぞれ指標値(指標値Aと指標値B)が求められる。本願発明者は、図18に示す、指標値N(absMvdCompN:指標値Aまたは指標値B)を求める処理を分析した。
<First findings>
As described above, in order to obtain the context index of mvd_lx of the macro block of interest, as shown in FIG. 17, first, index values (index value A and index value B) are obtained for each of the two reference submbs. The inventor of the present application analyzed the processing for obtaining the index value N (absMvdCompN: index value A or index value B) shown in FIG.

図18に示すように、ステップS100〜S126の処理は、参照submbのmvd_lxの値に関わらず、指標値Nを「0」にするか否かを判定するための処理である。ステップS126の判定結果が「Yes」である場合に、指標値Nは「0」に決定される(S128)。   As illustrated in FIG. 18, the processes in steps S100 to S126 are processes for determining whether or not the index value N is set to “0” regardless of the value of mvd_lx of the reference submb. When the determination result of step S126 is “Yes”, the index value N is determined to be “0” (S128).

ステップS100〜S126までの処理では、最大6つの判定ステップ(S100、S102またはS104、S120、S122、S124、S126)が実行される。これらの判定ステップは、当該参照MBのデコード時に、判定結果が分かり得る処理である。   In the processing from step S100 to S126, a maximum of six determination steps (S100, S102 or S104, S120, S122, S124, S126) are executed. These determination steps are processes in which the determination result can be understood when the reference MB is decoded.

また、ステップS126の判定結果が「No」である場合には、指標値Nは、該参照submbのmvd_lxの絶対値(S132、S144)、該絶対値の2倍(S138)、該絶対値の1/2(S142)のいずれかに決定される。そのため、もし、参照submbのmvd_lxが「0」であると、ステップS126の判定結果が「No」であっても、指標値Nは、「0」に決定される。   When the determination result of step S126 is “No”, the index value N is the absolute value of mvd_lx of the reference submb (S132, S144), twice the absolute value (S138), 1/2 (S142) is determined. Therefore, if mvd_lx of the reference submb is “0”, the index value N is determined to be “0” even if the determination result in step S126 is “No”.

さらに、ステップS100〜S126に含まれる各判定ステップに用いられるmvdシンタックスエレメント(mb_skip_flag、mb_type、sub_mb_type)は、後に指標値Nを決定するための各判定スキップに用いられない。すなわち、ステップS126までの処理を、参照MBのmvdシンタックスエレメントをシンタックスエレメントメモリに格納する前に完了させておけば、mb_skip_flag、mb_type、sub_mb_typeをシンタックスエレメントメモリに格納しなくてもよい。   Furthermore, the mvd syntax elements (mb_skip_flag, mb_type, sub_mb_type) used for each determination step included in steps S100 to S126 are not used for each determination skip for determining the index value N later. That is, if the processing up to step S126 is completed before the mvd syntax element of the reference MB is stored in the syntax element memory, mb_skip_flag, mb_type, and sub_mb_type need not be stored in the syntax element memory.

上記知見に基づき、本願発明者は、動きベクトルをデコードするための参照MBのシンタックスエレメントを記憶するシンタックスエレメントメモリの容量を削減できる第1の手法を確立した。
<第1の手法>
該手法では、注目マクロブロックをデコードして得た各シンタックスエレメントを後段の処理(ビデオデコーダによる処理)に出力すると共に、後のマクロブロックの動きベクトルをデコードするための各シンタックスエレメントとして、各サブマクロブロックのmvdシンタックスエレメントのみをシンタックスエレメントメモリに出力する。また、mvdシンタックスエレメントをシンタックスエレメントメモリに出力する際に、mvdシンタックスエレメント(mvd_lx)に対して、図1に示す第1のmvd置換処理を行う。
Based on the above knowledge, the inventor of the present application has established a first method capable of reducing the capacity of a syntax element memory that stores a syntax element of a reference MB for decoding a motion vector.
<First method>
In this method, each syntax element obtained by decoding the macro block of interest is output to the subsequent processing (processing by the video decoder), and as each syntax element for decoding the motion vector of the subsequent macro block, Only the mvd syntax element of each sub macroblock is output to the syntax element memory. Further, when the mvd syntax element is output to the syntax element memory, the first mvd replacement process shown in FIG. 1 is performed on the mvd syntax element (mvd_lx).

図1は、第1のmvd置換処理のフローチャートを示す。図1において、「MB_N」は現在復号されたマクロブロックであり、「block n」は該マクロブロックに含まれるサブマクロブロックである。該処理により、当該マクロブロックのmvdシンタックスエレメントの値に関わらず、該マクロブロックの指標値Nが「0」になると判定されたmvdシンタックスエレメントは、「0」に置換えてからシンタックスエレメントメモリに出力される。   FIG. 1 shows a flowchart of the first mvd replacement process. In FIG. 1, “MB_N” is a currently decoded macroblock, and “block n” is a sub-macroblock included in the macroblock. As a result of the processing, the mvd syntax element for which the macroblock index value N is determined to be “0” is replaced with “0” regardless of the value of the mvd syntax element of the macroblock. Output to memory.

従来の手法と対比するために、図1の等価フローチャートを図2に示す。図2では、点線により囲まれたステップS100〜S126において、「MB N」が現在復号されたマクロブロックであり、「block n」が該マクロブロックに含まれるサブマクロブロックであり、該処理がblock nのmvd_lxがシンタックスエレメントメモリに格納される前に行われる点を除き、各ステップの処理は図18における同番号の処理と同一である。なお、図2において、図18におけるステップS120の処理が無い。この処理は、シンタックスエレメントメモリに格納された後のコンテキストインデックス導出時において、参照マクロブロック「MB N」が既にデコードされたか否かおよびスライス領域内に存在するか否かを判定するものであり、シンタックスエレメントメモリに格納される前においては判定不可であるためである。なお、スライスは画面を複数のマクロブロックのグループに分割したCABACの処理単位である。   For comparison with the conventional method, an equivalent flowchart of FIG. 1 is shown in FIG. In FIG. 2, in steps S100 to S126 surrounded by a dotted line, “MB N” is a currently decoded macroblock, “block n” is a sub macroblock included in the macroblock, and the processing is performed as block. The processing of each step is the same as the processing of the same number in FIG. 18 except that the processing is performed before n mvd_lx is stored in the syntax element memory. In FIG. 2, there is no processing of step S120 in FIG. This process determines whether the reference macroblock “MB N” has already been decoded and exists in the slice area when the context index is derived after being stored in the syntax element memory. This is because the determination cannot be made before it is stored in the syntax element memory. A slice is a CABAC processing unit in which a screen is divided into a plurality of macroblock groups.

ステップS126における判定結果が「Yes」である場合に、サブマクロブロック「block n」の当該mvd_lxは、「0」に置き換えられてシンタックスエレメントメモリに出力される(S126:Yes、S200、S202)。一方、ステップS126における判定結果が「No」である場合には、上記mvd_lxは、「0」への置換えがなされずにそのままシンタックスエレメントメモリに出力される(S126:No、S202)。   When the determination result in step S126 is “Yes”, the mvd_lx of the sub macroblock “block n” is replaced with “0” and output to the syntax element memory (S126: Yes, S200, S202). . On the other hand, when the determination result in step S126 is “No”, the mvd_lx is output to the syntax element memory as it is without being replaced with “0” (S126: No, S202).

また、この手法では、注目マクロブロックの動きベクトルのデコード時に、mvd_lxについてコンテキストインデックスを求める際に、図3のフローチャートが示す手順で処理を行う。なお、図3において、「MB N」は参照MBであり、「block n」は参照submbである。   Further, in this method, when the context index is obtained for mvd_lx at the time of decoding the motion vector of the macro block of interest, processing is performed according to the procedure shown in the flowchart of FIG. In FIG. 3, “MB N” is a reference MB, and “block n” is a reference submb.

図3に示すように、まず、ステップS120において、参照MBのシンタックスエレメントが存在するか否かの判定がなされる。参照MBがまだデコードされていないか、またはスライス領域外に存在するために、そのシンタックスエレメントがシンタックスエレメントメモリに格納されていない場合には、指標値Nが「0」に決定される(S120:Yes、S128)。これらは、図18における同番号の処理と同じである。   As shown in FIG. 3, first, in step S120, it is determined whether or not a syntax element of the reference MB exists. If the reference MB has not been decoded yet or exists outside the slice area and the syntax element is not stored in the syntax element memory, the index value N is determined to be “0” ( S120: Yes, S128). These are the same as the processes with the same numbers in FIG.

ステップS120において、判定の結果が「No」であり、すなわち参照MBのシンタックスエレメントが既にシンタックスエレメントメモリに格納されている場合、指標値Nは、該参照submbのmvd_lxの絶対値と、該絶対値の2倍と、該絶対値の1/2のいずれかに決定される。これらの処理は、図18における同番号の処理と同じである。   In step S120, if the result of the determination is “No”, that is, if the syntax element of the reference MB is already stored in the syntax element memory, the index value N is the absolute value of mvd_lx of the reference submb, and It is determined to be either twice the absolute value or 1/2 of the absolute value. These processes are the same as the processes with the same numbers in FIG.

すなわち、この手法は、参照MBの各参照submbのmvdシンタックスエレメント(mvd_lx)をシンタックスエレメントメモリに格納する際に、mvd_lxの値に関わらず、上記指標値Nが「0」になるべき参照submbのmvd_lxを「0」に置き換える。そのため、後に注目マクロブロックのデコード時に図2に示すフローチャートで該参照submbについて指標値Nを求める際に、mvd_lxの絶対値、絶対値の2倍、絶対値の1/2のいずれに決定されようにしても、指標値Nが「0」になるように正しく求められる。   That is, in this method, when the mvd syntax element (mvd_lx) of each reference submb of the reference MB is stored in the syntax element memory, the reference value N should be “0” regardless of the value of mvd_lx. Replace mvd_lx of submb with “0”. Therefore, when the index value N is determined for the reference submb in the flowchart shown in FIG. 2 later when the target macroblock is decoded, the absolute value of mvd_lx, twice the absolute value, or 1/2 of the absolute value may be determined. Even so, the index value N is correctly obtained so as to be “0”.

こうすることにより、mb_skip_flagと、mb_typeと、sub_mb_typeとをシンタックスエレメントメモリに格納する必要が無くなる。図4は、この手法を適用した場合に、注目マクロブロックの動きベクトルをデコードするためにシンタックスエレメントメモリに格納する参照MB毎のmvdシンタックスエレメントを示す。図示のように、本手法の適用によって、1参照MB当たりに、必要なmvdシンタックスエレメントの最大総ビット数が224ビットになり、図15に示す従来必要な239ビットより15ビットを削減することができる。そのため、シンタックスエレメントメモリの容量を削減することができる。   This eliminates the need to store mb_skip_flag, mb_type, and sub_mb_type in the syntax element memory. FIG. 4 shows mvd syntax elements for each reference MB stored in the syntax element memory in order to decode the motion vector of the macro block of interest when this method is applied. As shown in the figure, by applying this technique, the maximum total number of mvd syntax elements required per reference MB is 224 bits, which is 15 bits less than the conventionally required 239 bits shown in FIG. Can do. Therefore, the capacity of the syntax element memory can be reduced.

なお、本手法による第1のmvd置換処理の各ステップの処理のうちに、該マクロブロックのデコード時に行われるものがある。これらの処理について、マクロブロックのデコード時の処理の結果を用いるようにすれば、効率向上を図ることができる。   Among the steps of the first mvd replacement process according to the present method, there are processes performed at the time of decoding the macroblock. For these processes, if the result of the process at the time of decoding the macroblock is used, the efficiency can be improved.

<第2の知見>
本願発明者は、図17におけるステップS30の処理、すなわち2つの参照submbについてそれぞれ求めた指標値Aと指標値Bを用いてコンテキストインデックスを算出する処理を分析した。図17に示すように、指標値Aと指標値Bの和が閾値TH1より大きい場合に、コンテキストインデックスが「2」に決定される。
<Second finding>
The inventor of this application analyzed the process of step S30 in FIG. 17, that is, the process of calculating the context index using the index value A and the index value B obtained for each of the two reference submbs. As shown in FIG. 17, when the sum of the index value A and the index value B is larger than the threshold value TH1, the context index is determined to be “2”.

すなわち、指標値Aと指標値Bのいずれか一方が閾値TH1より大きければ、コンテキストインデックスが「2」に決定される。また、指標値は、参照submbのmvd_lxの絶対値、絶対値の2倍、絶対値の1/2のいずれかに決定されるので、2つの参照submbのうちの片方のmvd_lxが式(1)に示すP以上であれば、該mvd_lxの値を、該mvd_lxより小さく、P以上の任意の値に置換えても、コンテキストインデックスが正しく決定される。
第3の閾値≧P=(第2の閾値+1)×2 (1)
That is, if either one of the index value A and the index value B is larger than the threshold value TH1, the context index is determined to be “2”. Further, since the index value is determined to be one of the absolute value of mvd_lx of the reference submb, twice the absolute value, or 1/2 of the absolute value, mvd_lx of one of the two reference submbs is expressed by the formula (1). If the value of mvd_lx is equal to or greater than P shown in the above, the context index is correctly determined even if the value of mvd_lx is smaller than mvd_lx and replaced with any value greater than or equal to P.
Third threshold ≧ P = (second threshold + 1) × 2 (1)

例えば、閾値TH1が「32」であるとすると、「66」以上の参照submbのmvd_lxの値を「66」に置換えた場合に、指標値がmvd_lxの絶対値の1/2(ここでは「33」)にすべきと判定されても、コンテキストインデックスが「2」に正しく決定される。   For example, when the threshold value TH1 is “32”, when the value of mvd_lx of the reference submbb “66” or more is replaced with “66”, the index value is 1/2 of the absolute value of mvd_lx (here, “33”). )), The context index is correctly determined to be “2”.

そこで、この知見に基づき、本願発明者は、動きベクトルをデコードするための参照MBのシンタックスエレメントを記憶するシンタックスエレメントメモリの容量を削減できる第2の手法を確立した。
<第2の手法>
Therefore, based on this knowledge, the present inventor has established a second method capable of reducing the capacity of the syntax element memory for storing the syntax elements of the reference MB for decoding the motion vector.
<Second method>

この手法では、参照submbのmvdシンタックスエレメント(mvd_lx)をシンタックスエレメントメモリに格納する際に、式(1)が示す第3の閾値以上である参照submbのmvd_lxの値を、該mvd_lxの値より小さく、式(1)に示すP以上の任意の値に置換えてシンタックスエレメントメモリに格納する。   In this method, when the mvd syntax element (mvd_lx) of the reference submb is stored in the syntax element memory, the value of the mvd_lx of the reference submb that is equal to or greater than the third threshold indicated by the expression (1) is set to the value of the mvd_lx. It is smaller and is replaced with an arbitrary value equal to or larger than P shown in the expression (1) and stored in the syntax element memory.

こうすることにより、第3の閾値以上のmvd_lxが小さい値に置換えられてシンタックスエレメントメモリに格納されるため、シンタックスエレメントメモリの容量を削減することができる。
なお、第3の閾値が小さいほど、mvd_lxが置き換えられる値が小さいほど、シンタックスエレメントメモリの容量を削減する効果が大きいので、第3の閾値としてはPを用い、P以上のmvd_lxをPに置換えるようにすることが好ましい。
上述した第2の手法による置換処理を、以下「第2のmvd置換処理」という。
By doing so, since mvd_lx equal to or greater than the third threshold value is replaced with a small value and stored in the syntax element memory, the capacity of the syntax element memory can be reduced.
Note that the smaller the third threshold value and the smaller the value with which mvd_lx is replaced, the greater the effect of reducing the capacity of the syntax element memory. It is preferable to replace them.
The replacement process by the second method described above is hereinafter referred to as “second mvd replacement process”.

<第3の知見>
本願発明者は、参照submbのmvdシンタックスエレメントのビット数を削減する視点から研究模索した結果、さらに、第3の知見を得た。
<Third findings>
The inventor of the present application has obtained a third finding as a result of searching for research from the viewpoint of reducing the number of bits of the mvd syntax element of the reference submb.

シンタックスエレメントメモリがシステムバスにより接続された場合、シンタックスエレメントメモリに参照submbのmvdシンタックスエレメントを転送する際に、mvdシンタックスエレメントのビット数を削減することにより、転送回数を減らすことができ、効率よく転送することができる。また、ビット数の削減により、mvdシンタックスエレメントのデータ量も減るため、シンタックスエレメントメモリの容量削減にも功を奏することができる。   When the syntax element memory is connected by the system bus, when the mvd syntax element of the reference submb is transferred to the syntax element memory, the number of transfers can be reduced by reducing the number of bits of the mvd syntax element. Can be transferred efficiently. Further, since the data amount of the mvd syntax element is reduced by reducing the number of bits, the capacity of the syntax element memory can be reduced.

前述したように、指標値Aと指標値Bのいずれか一方が閾値TH1より大きければ、コンテキストインデックスが「2」に決定される。また、指標値は、参照submbのmvd_lxの絶対値、絶対値の2倍、絶対値の1/2のいずれかに決定される。また、絶対値の1/2に決定された場合、小数切り捨てがなされ、すなわち絶対値の1/2の整数部分のみが用いられる。   As described above, if either one of the index value A and the index value B is larger than the threshold value TH1, the context index is determined to be “2”. Also, the index value is determined as one of the absolute value of mvd_lx of the reference submb, twice the absolute value, and 1/2 of the absolute value. If it is determined to be 1/2 of the absolute value, the fractional value is rounded down, that is, only the integer part of 1/2 of the absolute value is used.

そのため、例えば、閾値TH1が32である場合、「34」以上のmvdシンタックスエレメントの値のうち、2で割った場合に整数部分が同一である2つの値が同じ値(例えば小さいほうのmvdシンタックスエレメント)に置換えられてからシンタックスエレメントメモリに格納されるようにしても、後に該参照submbのmvdシンタックスエレメントを用いてコンテキストインデックスを求める際に、コンテキストインデックスを正しく決定することができる。
この知見に基づき、本願発明者は、第3の手法を確立した。
Therefore, for example, when the threshold value TH1 is 32, two values of mvd syntax elements equal to or greater than “34” that have the same integer part when divided by 2 are the same value (for example, the smaller mvd Even if it is stored in the syntax element memory after being replaced with the syntax element), the context index can be correctly determined when the context index is obtained later using the mvd syntax element of the reference submb. .
Based on this knowledge, the present inventor has established a third method.

<第3の手法>
この手法では、参照submbのmvd_lxをシンタックスエレメントメモリに格納する際に、式(2)が示す第4の閾値以上であるmvd_lxの値を下記のエンコードルールでエンコードしてシンタックスエレメントメモリに格納する。そして、シンタックスエレメントメモリに格納された、第4の閾値以上である参照submbのmvdシンタックスエレメントを上記エンコードルールに基づいてデコードしてから該参照submbの指標値を算出する。
第4の閾値≧Q=第2の閾値+2 (2)
<Third method>
In this method, when the mvd_lx of the reference submb is stored in the syntax element memory, the value of mvd_lx that is equal to or greater than the fourth threshold indicated by the expression (2) is encoded by the following encoding rule and stored in the syntax element memory. To do. The index value of the reference submb is calculated after decoding the mvd syntax element of the reference submb stored in the syntax element memory that is equal to or greater than the fourth threshold value based on the encoding rule.
Fourth threshold ≧ Q = second threshold + 2 (2)

エンコードルールは、「エンコード後の値がエンコード前の値以下第4の閾値以上であり」、かつ、「2で割った後の整数部分が同一である2つの値が同一の値にエンコードされる」、かつ、「上記整数部分が1つ大きくなるとエンコード後の値も1つ大きくなる」である。   The encoding rule is that “the value after encoding is not less than the value before encoding and not less than the fourth threshold value” and “two values having the same integer part after dividing by 2 are encoded to the same value. And “when the integer part increases by one, the value after encoding also increases by one”.

第4の閾値は、Q以上であればよいが、Qであることが好ましい。この場合、参照submbのmvdシンタックスエレメントのビット数の削減に最も効果を発揮する。   The fourth threshold value may be Q or more, but is preferably Q. In this case, it is most effective in reducing the number of bits of the mvd syntax element of the reference submb.

図5は、第4の閾値を「60」とした場合に、上記エンコードルールに従ったエンコードテーブルとデコードテーブルの例を示す。   FIG. 5 shows an example of an encoding table and a decoding table according to the above encoding rule when the fourth threshold value is “60”.

図5に示すエンコードテーブルから分かるように、「60」より小さい値がそのまま、「60」以上の値が、元の値以下60以上の値にエンコードされる。また、2で割った後の整数部分が同一である2つの値、例えば「62」と「63」は、同一の値(61)にエンコードされる。また、上記整数部分が「30」である「60」と「61」が「60」にエンコードされ、上記整数部分が「31」である「62」と「63」が「61」にエンコードされるように、上記整数部分が1つ大きくなるとエンコード後の値も1つ大きくなるようにエンコードがなされる。参照submbのmvdシンタックスエレメントは、このようにエンコードされてシンタックスエレメントメモリに格納される。   As can be seen from the encoding table shown in FIG. 5, a value smaller than “60” is directly encoded as a value equal to or greater than “60” to a value equal to or greater than 60 than the original value. Also, two values, for example “62” and “63”, that have the same integer part after dividing by 2, are encoded to the same value (61). Also, “60” and “61” whose integer part is “30” are encoded as “60”, and “62” and “63” whose integer part is “31” are encoded as “61”. Thus, encoding is performed so that the value after encoding is increased by one when the integer part is increased by one. The mvd syntax element of the reference submb is encoded in this way and stored in the syntax element memory.

後に参照submbのmvdシンタックスエレメントを用いて指標値を算出する際に、図5に示すデコードテーブルに従ってデコードがなされる。   When the index value is calculated later using the mvd syntax element of the reference submb, the decoding is performed according to the decoding table shown in FIG.

図5の右部分は、図5の左部分に示すエンコードテーブルでエンコードされ、図5の下部に示すデコードテーブルでデコードされた後に、参照submbのmvdシンタックスエレメントの絶対値の1/2になると判定された場合に決定される指標値Nを示す。図示のように、本手法により参照submbのmvdシンタックスエレメントをエンコードしてからシンタックスエレメントメモリに格納した場合にも、後に正しい指標値Nを得ることができる。
以下の説明において、本第3の手法によるエンコードを「第3のmvd置換処理」ともいう。
The right part of FIG. 5 is encoded with the encoding table shown in the left part of FIG. 5, is decoded with the decoding table shown in the lower part of FIG. 5, and then becomes 1/2 of the absolute value of the mvd syntax element of the reference submb. The index value N determined when it is determined is shown. As shown in the figure, even when the mvd syntax element of the reference submbb is encoded by this method and then stored in the syntax element memory, the correct index value N can be obtained later.
In the following description, encoding by the third method is also referred to as “third mvd replacement process”.

なお、シンタックスエレメントメモリに格納された参照submbのmvdシンタックスエレメントを用いて指標値を算出する際に、該参照submbのmvdシンタックスエレメントの値が第4の閾値以上であり、かつ指標値が該参照submbのmvdシンタックスエレメントの絶対値の1/2になると判定した場合においてのみ、該参照submbのmvdシンタックスエレメントに対して上記エンコードルールに従ったデコードを行うことが好ましい。他の場合において、上記エンコードがなされたままのmvdシンタックスエレメントを用いても正しいコンテキストインデックスを求めることができる。こうすることにより、コンテキストインデックスを算出する処理の効率を向上させることができる。   When the index value is calculated using the mvd syntax element of the reference submb stored in the syntax element memory, the value of the mvd syntax element of the reference submb is equal to or greater than the fourth threshold, and the index value Only when it is determined that becomes 1/2 of the absolute value of the mvd syntax element of the reference submb, it is preferable to perform decoding according to the encoding rule for the mvd syntax element of the reference submb. In other cases, the correct context index can be obtained using the mvd syntax element that has been encoded. By doing so, the efficiency of the process of calculating the context index can be improved.

上述した各手法は、いずれもシンタックスエレメントメモリの容量削減に功を奏することができ、これらの手法を組み合わせることにより、シンタックスエレメントメモリの容量削減効果をより大きくすることができる。   Each of the above-described methods can be effective in reducing the capacity of the syntax element memory, and by combining these methods, the capacity reduction effect of the syntax element memory can be further increased.

以上の原理を踏まえて、本発明の具体的な実施の形態を説明する。
図6は、本発明の実施の形態にかかるCABACデコーダ100を示す。このCABACデコーダ100は、図10に示すビットストリームデコーダ10におけるCABACデコーダ30に対応し、H.264に準拠したビットストリームに対してマクロブロック毎にデコードを行って各マクロブロックのシンタックスエレメントを順次得る。
Based on the above principle, a specific embodiment of the present invention will be described.
FIG. 6 shows a CABAC decoder 100 according to an embodiment of the present invention. This CABAC decoder 100 corresponds to the CABAC decoder 30 in the bit stream decoder 10 shown in FIG. The bit stream compliant with H.264 is decoded for each macro block to sequentially obtain the syntax elements of each macro block.

CABACデコーダ100は、算術デコーダ110、二値デコーダ120、シンタックスエレメント置換部150を備える。   The CABAC decoder 100 includes an arithmetic decoder 110, a binary decoder 120, and a syntax element replacement unit 150.

算術デコーダ110は、ビットストリームを入力し、コンテキストを用いて算術符号化を行って「bin」を得る。   The arithmetic decoder 110 receives the bit stream and performs arithmetic coding using the context to obtain “bin”.

二値デコーダ120は、算術デコーダ110からのbin列を入力して、シンタックスエレメントを得て出力する。二値デコーダ120により得られたシンタックスエレメントは、後段の処理例えばビデオデコーダに出力されると共に、その一部はシンタックスエレメント置換部150に出力される。この一部のシンタックスエレメントは、後にデコードされるマクロブロックの動きベクトルを求めるための各シンタックスエレメントが含まれている。   The binary decoder 120 receives the bin string from the arithmetic decoder 110, obtains a syntax element, and outputs it. The syntax element obtained by the binary decoder 120 is output to a subsequent process such as a video decoder, and a part thereof is output to the syntax element replacement unit 150. This part of syntax elements includes each syntax element for obtaining a motion vector of a macroblock to be decoded later.

シンタックスエレメント置換部150は、マクロブロックの動きベクトルを求めるためのシンタックスエレメントの一部に対して、別の値に変換する置換えを行ってから算術デコーダ110に出力する。置換えがなされないシンタックスエレメントについては、そのまま算術デコーダ110に出力する。   The syntax element replacement unit 150 performs replacement for converting a part of the syntax element for obtaining the motion vector of the macroblock into another value, and outputs the result to the arithmetic decoder 110. The syntax elements that are not replaced are output to the arithmetic decoder 110 as they are.

算術デコーダ110は、シンタックスエレメントメモリ112、インデックス生成部114、二値算術デコーダ116、コンテキストメモリ118を有する。   The arithmetic decoder 110 includes a syntax element memory 112, an index generation unit 114, a binary arithmetic decoder 116, and a context memory 118.

シンタックスエレメントメモリ112は、シンタックスエレメント置換部150からのシンタックスエレメントを記憶する。   The syntax element memory 112 stores the syntax element from the syntax element replacement unit 150.

コンテキストメモリ118は、各種シンタックスエレメントに割り当てられたコンテキストを記憶している。コンテキストメモリ118に記憶されたコンテキストは、1つのbinを得る毎にコンテキストメモリ118からの読出し、次のbinを得るために二値算術デコーダ116での使用と更新、コンテキストメモリ118への書戻しがなされる。   The context memory 118 stores contexts assigned to various syntax elements. The context stored in the context memory 118 is read from the context memory 118 every time one bin is obtained, used and updated by the binary arithmetic decoder 116 to obtain the next bin, and written back to the context memory 118. Made.

インデックス生成部114は、デコードされるマクロブロック(注目マクロブロック)の各サブマクロブロックについて、該サブマクロブロックの各種mvdシンタックスエレメントにそれぞれ対応するコンテキストがコンテキストメモリ118に記憶されたアドレスを示すコンテキストインデックスを生成して二値算術デコーダ116に供する。   For each sub macroblock of the macro block to be decoded (target macro block), the index generating unit 114 indicates a context in which contexts corresponding to various mvd syntax elements of the sub macro block are stored in the context memory 118. An index is generated and provided to the binary arithmetic decoder 116.

二値算術デコーダ116は、コンテキストメモリ118から、シンタックスエレメントメモリ112が生成したインデックスが示すアドレスに記憶されたコンテキストを読み出して、算術復号を行ってbinを得ると共に、算術復号時に更新した該コンテキストをコンテキストメモリ118の上記アドレスに書き戻す。   The binary arithmetic decoder 116 reads the context stored at the address indicated by the index generated by the syntax element memory 112 from the context memory 118, performs arithmetic decoding to obtain bin, and updates the context updated at the time of arithmetic decoding. Is written back to the above address in the context memory 118.

CABACデコーダ100は、シンタックスエレメント置換部150を備える点と、インデックス生成部114がインデックスを生成する際の動作が、通常のCABACデコーダにおけるインデックスの生成器の動作と異なる点を除き、通常のCABACデコーダと同じである。そのため、以下において、シンタックスエレメント置換部150とインデックス生成部114についてのみ詳細に説明する。   The CABAC decoder 100 includes a normal CABAC except that it includes a syntax element replacement unit 150 and the operation when the index generation unit 114 generates an index is different from the operation of the index generator in the normal CABAC decoder. Same as decoder. Therefore, only the syntax element replacement unit 150 and the index generation unit 114 will be described in detail below.

図7は、シンタックスエレメント置換部150による処理の流れを示すフローチャートである。図示のように、シンタックスエレメント置換部150は、まず、二値デコーダ120からのmvdシンタックスエレメント(後に参照submbとなるサブマクロブロックのmvdシンタックスエレメント)に対して、第1のmvd置換処理を行う(S300)。この処理は、図1に示すフローチャートにおけるステップS200までの処理である。この処理により、該参照submbのmvdシンタックスエレメントの値に関わらず、その指標値Nが「0」になるべきと判定されたmvdシンタックスエレメントは「0」に置換えられる。他のmvdシンタックスエレメントは、置換えがなされない。   FIG. 7 is a flowchart showing the flow of processing by the syntax element replacement unit 150. As illustrated, the syntax element replacement unit 150 first performs a first mvd replacement process on the mvd syntax element from the binary decoder 120 (the mvd syntax element of the sub-macroblock that will later become the reference submb). (S300). This process is a process up to step S200 in the flowchart shown in FIG. By this process, the mvd syntax element determined to have the index value N to be “0” is replaced with “0” regardless of the value of the mvd syntax element of the reference submb. Other mvd syntax elements are not replaced.

シンタックスエレメント置換部150は、ステップS300において、「0」への置換えがなされた参照submbについて、そのmvdシンタックスエレメントとして「0」をシンタックスエレメントメモリ112に出力する(S320:Yes、S310)。   In step S300, the syntax element replacement unit 150 outputs “0” to the syntax element memory 112 as the mvd syntax element for the reference submb that has been replaced with “0” (S320: Yes, S310). .

一方、ステップS300において、「0」への置換えがなされなかった参照submbのmvdシンタックスエレメントに対しては、さらに第2のmvd置換処理を行う(S302:No、S304)。   On the other hand, in step S300, a second mvd replacement process is further performed on the mvd syntax element of the reference submb that has not been replaced with “0” (S302: No, S304).

ステップS304における第2のmvd置換処理は、式(1)が示す第3の閾値以上のmvdシンタックスエレメントの値を、該mvdシンタックスエレメントの値より小さく、式(1)に示すP以上の値例えばPに置換える処理である。ここで、第2の閾値が「32」であり、第3の閾値がPであるすると、このステップにおいて、66以上のmvdシンタックスエレメントは、全て「66」に置換えられる。
第3の閾値≧P=(第2の閾値+1)×2 (1)
In the second mvd replacement process in step S304, the value of the mvd syntax element equal to or greater than the third threshold indicated by the expression (1) is smaller than the value of the mvd syntax element and equal to or greater than P indicated in the expression (1). This is a process of replacing with a value such as P. Here, if the second threshold value is “32” and the third threshold value is P, in this step, mvd syntax elements of 66 or more are all replaced with “66”.
Third threshold ≧ P = (second threshold + 1) × 2 (1)

なお、第3の閾値ここでは66より小さい、すなわち65以下のmvdシンタックスエレメントは、上記置換えがなされず、そのままの値である。   It should be noted that the mvd syntax element whose third threshold value is smaller than 66, that is, 65 or less, is the value as it is without being replaced.

シンタックスエレメント置換部150は、次いで、ステップS304の第2のmvd置換処理がなされた後のmvdシンタックスエレメントについて、第3のmvd置換処理を施すか否かを判定する(S306)。第2のmvd置換処理を経た後のmvdシンタックスエレメントが式(2)に示す第4の閾値より小さければ(S306:No)、第3のmvd置換処理行わず、mvdシンタックスエレメントをシンタックスエレメントメモリ112に出力する(S306:No、S310)。
第4の閾値≧Q=第2の閾値+2 (2)
Next, the syntax element replacement unit 150 determines whether or not to perform the third mvd replacement process on the mvd syntax element after the second mvd replacement process of step S304 is performed (S306). If the mvd syntax element after the second mvd substitution process is smaller than the fourth threshold value shown in Expression (2) (S306: No), the third mvd substitution process is not performed and the mvd syntax element is used as the syntax. The data is output to the element memory 112 (S306: No, S310).
Fourth threshold ≧ Q = second threshold + 2 (2)

第2の閾値が「32」であり、第4の閾値が「60」であるとすると、「60」より小さいすなわち「59」以下のmvdシンタックスエレメントは、第3のmvd置換処理がなされずにシンタックスエレメントメモリ112に出力される。   Assuming that the second threshold is “32” and the fourth threshold is “60”, the mvd syntax element smaller than “60”, that is, “59” or less, is not subjected to the third mvd replacement process. Are output to the syntax element memory 112.

一方、第4の閾値(ここでは60)以上であるmvdシンタックスエレメントに対して、シンタックスエレメント置換部150は、さらに第3のmvd置換処理を行う(S306:No、S308)。   On the other hand, the syntax element replacement unit 150 further performs a third mvd replacement process for mvd syntax elements that are equal to or greater than the fourth threshold (60 in this case) (S306: No, S308).

第3のmvd置換処理は、mvdシンタックスエレメントのビット数を削減する処理であり、例えば図5に示すエンコードテーブルに従って行われる。なお、本実施の形態において、第2のmvd置換処理を経てからのmvdシンタックスエレメントに対して第3のmvd置換処理を行うので、エンコードテーブルにおいて、エンコード前の最大値が「66」である。また、第4の閾値以上のmvdシンタックスエレメントに対してのみエンコードするので、エンコードテーブルにおいて、エンコード前の最小値が「60」である。   The third mvd replacement process is a process for reducing the number of bits of the mvd syntax element, and is performed, for example, according to the encode table shown in FIG. In the present embodiment, since the third mvd substitution process is performed on the mvd syntax element after the second mvd substitution process, the maximum value before encoding is “66” in the encoding table. . In addition, since encoding is performed only for mvd syntax elements equal to or greater than the fourth threshold, the minimum value before encoding is “60” in the encoding table.

シンタックスエレメント置換部150は、第3のmvd置換処理を行って得たmvdシンタックスエレメントをシンタックスエレメントメモリ112に出力する(S308、S310)。   The syntax element replacement unit 150 outputs the mvd syntax element obtained by performing the third mvd replacement processing to the syntax element memory 112 (S308, S310).

インデックス生成部114は、注目マクロブロックのサブマクロブロックのmvdシンタックスエレメントのコンテキストを生成するために、シンタックスエレメントメモリ112に格納された2つの参照submbのmvdシンタックスエレメントを用いてそれぞれ指標値Nを求める。図8は、インデックス生成部114が指標値Nを求める処理を示すフローチャートである。このフローチャートは、ステップS330〜S332が追加された点を除き、図2のフローチャートと同様である。   The index generation unit 114 uses the mvd syntax elements of the two reference submbs stored in the syntax element memory 112 in order to generate the context of the mvd syntax element of the sub macroblock of the target macroblock, respectively. N is obtained. FIG. 8 is a flowchart illustrating a process in which the index generation unit 114 obtains the index value N. This flowchart is the same as the flowchart of FIG. 2 except that steps S330 to S332 are added.

インデックス生成部114は、参照submbのmvdシンタックスエレメントの絶対値、該絶対値の2倍、該絶対値の1/2のいずれかを指標値Nに決定する。指標値Nが参照submbの絶対値に決定されるべきと判定した場合に、シンタックスエレメントメモリ112に格納された該mvdシンタックスエレメントの絶対値を指標値Nに決定する((S130:No、S132)(S130:Yes、S134:No、S132)(S130:Yes、S134:Yes、S136:No、S140:No、S144)。また、指標値Nが該参照submbのmvdシンタックスエレメントの絶対値の2倍に決定されるべきと判定した場合に、シンタックスエレメントメモリ112に格納された該mvdシンタックスエレメントの絶対値の2倍を指標値Nに決定する(S130:Yes、S134:Yes、S136:Yes、S138)。   The index generation unit 114 determines the absolute value of the mvd syntax element of the reference submb, twice the absolute value, or 1/2 of the absolute value as the index value N. When it is determined that the index value N should be determined as the absolute value of the reference submb, the absolute value of the mvd syntax element stored in the syntax element memory 112 is determined as the index value N ((S130: No, S132) (S130: Yes, S134: No, S132) (S130: Yes, S134: Yes, S136: No, S140: No, S144) Also, the index value N is the absolute value of the mvd syntax element of the reference submb. Is determined to be twice the absolute value of the mvd syntax element stored in the syntax element memory 112 as the index value N (S130: Yes, S134: Yes, S136: Yes, S138).

一方、インデックス生成部114は、指標値Nが参照submbのmvdシンタックスエレメントの1/2に決定されるべきと判定した場合には(S130:Yes、S134:Yes、S136:No、S140:Yes)、さらに、シンタックスエレメントメモリ112に記憶された該参照submbのmvdシンタックスエレメントが第4の閾値(ここでは60)以上であるか否かを確認する(S330)。mvdシンタックスエレメントが60以上であれば、インデックス生成部114は、図5に示すデコードテーブルを参照して該mvdシンタックスエレメントをデコードし、デコード後のmvdシンタックスエレメントの絶対値の1/2を指標値Nに決定する(S330:Yes、S332、S142)。一方、ステップS330における判定の結果、mvdシンタックスエレメントが59以下であれば、インデックス生成部114は、シンタックスエレメントメモリ112に記憶されたmvdシンタックスエレメントの絶対値の1/2を指標値Nに決定する(S330:No、S142)。   On the other hand, when the index generation unit 114 determines that the index value N should be determined to be 1/2 of the mvd syntax element of the reference submb (S130: Yes, S134: Yes, S136: No, S140: Yes) Further, it is confirmed whether or not the mvd syntax element of the reference submb stored in the syntax element memory 112 is equal to or greater than a fourth threshold (60 in this case) (S330). If the mvd syntax element is 60 or more, the index generation unit 114 decodes the mvd syntax element with reference to the decoding table shown in FIG. 5, and ½ of the absolute value of the mvd syntax element after decoding. Is determined as the index value N (S330: Yes, S332, S142). On the other hand, if the result of determination in step S330 is that the mvd syntax element is 59 or less, the index generation unit 114 sets 1/2 of the absolute value of the mvd syntax element stored in the syntax element memory 112 as the index value N. (S330: No, S142).

本実施の形態のCABACデコーダ100は、本発明の原理の説明に述べた3つの手法を組み合わせたものであり、これらの手法の効果を得ることができると共に、組み合わせたことによりさらに効果を増大させることができる。   The CABAC decoder 100 according to the present embodiment is a combination of the three methods described in the explanation of the principle of the present invention. The effects of these methods can be obtained, and the effects can be further increased by the combination. be able to.

例えば、図15に示すように、従来、mvdシンタックスエレメントは、15ビットまたは13ビットで表現していた。それに対して、本実施の形態のCABACデコーダ100は、第2の手法と第3の手法を組み合わせることにより、シンタックスエレメントメモリ112に格納するmvdシンタックスエレメントの値を「63」以下に抑制しているので、mvdシンタックスエレメントを6ビットで表すことができるようになる。また、第1の手法の適用により、後の注目マクロブロックの動きベクトルをデコードするためにシンタックスエレメントメモリ112に格納する参照MBのシンタックスエレメントをmvdシンタックスエレメントのみにし、mb_skip_flagと、mb_typeと、sub_mb_typeをシンタックスエレメントメモリ112に格納する必要を無くした。   For example, as shown in FIG. 15, conventionally, the mvd syntax element has been expressed by 15 bits or 13 bits. On the other hand, the CABAC decoder 100 of the present embodiment suppresses the value of the mvd syntax element stored in the syntax element memory 112 to “63” or less by combining the second method and the third method. Therefore, the mvd syntax element can be represented by 6 bits. Further, by applying the first method, the syntax element of the reference MB stored in the syntax element memory 112 for decoding the motion vector of the later target macroblock is changed to only the mbd syntax element, and mb_skip_flag, mb_type, , Sub_mb_type need not be stored in the syntax element memory 112.

そのため、図9に示すように、本実施の形態のCABACデコーダ100において、マクロブロックの動きベクトルをデコードするために、1参照MB当たりに、シンタックスエレメントメモリ112に格納するmvdシンタックスエレメントの最大総ビット数は96ビットに抑制され、従来の239ビットより約60%の削減となっており、シンタックスエレメントメモリの容量を大きく削減することができる。   Therefore, as shown in FIG. 9, in the CABAC decoder 100 of the present embodiment, the maximum number of mvd syntax elements stored in the syntax element memory 112 for each reference MB in order to decode the motion vector of the macroblock. The total number of bits is suppressed to 96 bits, which is about 60% reduction from the conventional 239 bits, and the capacity of the syntax element memory can be greatly reduced.

また、システムバスを介してシンタックスエレメントメモリにmvdシンタックスエレメントを転送するシステムの場合、転送回数を減らすことができ、転送効率を向上させることができる。例えば、システムバスのビット幅が128ビットである場合に、従来の239ビットを転送するために、2回転送する必要がある。CABACデコーダ100によれば、1回の転送のみでできるため、転送効率を50%向上させることができる。同様に、64ビットのバス幅の場合には2転送分、32ビットバス幅の場合には5転送分を減らすことができ、それぞれ50%と62.5%の効率向上を図ることができる。   Also, in the case of a system that transfers mvd syntax elements to the syntax element memory via the system bus, the number of transfers can be reduced and transfer efficiency can be improved. For example, when the bit width of the system bus is 128 bits, it is necessary to transfer twice in order to transfer the conventional 239 bits. According to the CABAC decoder 100, the transfer efficiency can be improved by 50% because only one transfer is possible. Similarly, in the case of a 64-bit bus width, two transfers can be reduced, and in the case of a 32-bit bus width, five transfers can be reduced, thereby improving efficiency by 50% and 62.5%, respectively.

以上、実施の形態をもとに本発明を説明した。実施の形態は例示であり、本発明の主旨から逸脱しない限り、上述した各実施の形態に対してさまざまな変更、増減、組合せを行ってもよい。これらの変更、増減、組合せが行われた変形例も本発明の範囲にあることは当業者に理解されるところである。   The present invention has been described above based on the embodiment. The embodiment is an exemplification, and various modifications, increases / decreases, and combinations may be made to the above-described embodiments without departing from the gist of the present invention. It will be understood by those skilled in the art that modifications in which these changes, increases / decreases, and combinations are also within the scope of the present invention.

また、本発明の技術をCABAC復号化に適用した場合の実施の形態について説明したが、本発明の技術は、CABAC符号化時にも同様に適用することができる。また、適用することにより、復号時と同様の効果を得ることができる。   Moreover, although the embodiment in the case where the technique of the present invention is applied to CABAC decoding has been described, the technique of the present invention can be similarly applied to CABAC encoding. Moreover, by applying, the same effect as that at the time of decoding can be obtained.

10 ビットストリームデコーダ
20 エントロピーデコーダ
30 CABACデコーダ
40 算術デコーダ
42 シンタックスエレメントメモリ
44 インデックス生成器
46 二値算術デコーダ
48 コンテキストメモリ
50 二値デコーダ
60 CAVLCデコーダ
70 ビデオデコーダ
100 CABACデコーダ
110 算術デコーダ
112 シンタックスエレメントメモリ
114 インデックス生成部
116 二値算術デコーダ
118 コンテキストメモリ
120 二値デコーダ
150 シンタックスエレメント置換部
10 bitstream decoder 20 entropy decoder 30 CABAC decoder 40 arithmetic decoder 42 syntax element memory 44 index generator 46 binary arithmetic decoder 48 context memory 50 binary decoder 60 CAVLC decoder 70 video decoder 100 CABAC decoder 110 arithmetic decoder 112 syntax element Memory 114 Index generation unit 116 Binary arithmetic decoder 118 Context memory 120 Binary decoder 150 Syntax element replacement unit

Claims (12)

CABAC符号化またはCABAC復号化により動きベクトルの符号化または復号化をマクロブロック毎に順次行う画像処理装置であって、
注目マクロブロックの動きベクトルの符号化または復号化時に複数のシンタックスエレメントを参照されるマクロブロックである参照MBの前記複数のシンタックスエレメントであって、該参照MBを分割して得たサブマクロブロックである参照submb毎の各種動きベクトル差分をそれぞれ表す各種mvdシンタックスエレメントを含む前記複数のシンタックスエレメントを格納するシンタックスエレメントメモリと、
前記mvdシンタックスエレメント毎に割り当てられたコンテキストを格納するコンテキストメモリと、
前記注目マクロブロックの各サブマクロブロックについて、各mvdシンタックスエレメントにそれぞれ対応するコンテキストが前記コンテキストメモリに格納されたアドレスを示すコンテキストインデックスを生成する際に、該サブマクロブロックに対応する2つの前記参照submbの指標値をそれぞれ求め、求められた2つの前記指標値の和に基づいて前記コンテキストインデックスを生成するインデックス生成部であって、前記シンタックスエレメントメモリに格納された、前記参照submbの該mvdシンタックスエレメントの絶対値と、前記絶対値の2倍と、前記絶対値の1/2のうちのいずれか1つを前記指標値として求める前記インデックス生成部と、
前記参照submbのmvdシンタックスエレメントを前記シンタックスエレメントメモリに格納する際に、該mvdシンタックスエレメントの値に関わらず、該参照submbの前記指標値が「0」になるか否かの判定をすると共に、前記指標値が「0」になると判定したときに、前記mvdシンタックスエレメントを「0」に置換えて前記シンタックスエレメントメモリに格納し、それ以外の場合には前記mvdシンタックスエレメントを前記シンタックスエレメントメモリに格納するシンタックスエレメント置換部とを備えることを特徴とする画像処理装置。
An image processing apparatus that sequentially encodes or decodes a motion vector for each macroblock by CABAC encoding or CABAC decoding,
A plurality of syntax elements of a reference MB that is a macroblock to which a plurality of syntax elements are referred when encoding or decoding a motion vector of the target macroblock, and obtained by dividing the reference MB A syntax element memory for storing the plurality of syntax elements including various mvd syntax elements respectively representing various motion vector differences for each reference submb being a block;
A context memory for storing a context allocated for each mvd syntax element;
For each sub macroblock of the macro block of interest, when the context corresponding to each mvd syntax element generates a context index indicating the address stored in the context memory, the two macro macro blocks corresponding to the sub macro block are generated. An index generation unit that obtains an index value of each reference submb and generates the context index based on a sum of the obtained two index values, and the index subunit of the reference submb stored in the syntax element memory the index generation unit for obtaining any one of an absolute value of an mvd syntax element, twice the absolute value, and ½ of the absolute value as the index value;
When the mvd syntax element of the reference submb is stored in the syntax element memory, it is determined whether the index value of the reference submb is “0” regardless of the value of the mvd syntax element. When it is determined that the index value is “0”, the mvd syntax element is replaced with “0” and stored in the syntax element memory. Otherwise, the mvd syntax element is stored in the syntax element memory. An image processing apparatus comprising: a syntax element replacement unit for storing in the syntax element memory.
前記インデックス生成部は、前記2つの指標値の和が第1の閾値未満であるときと、前記第1の閾値より大きい第2の閾値より大きいときと、他のときとにおいて異なる値のコンテキストインデックスをそれぞれ生成し、
前記シンタックスエレメント置換部は、さらに、式(1)が示す第3の閾値以上である前記参照submbのmvdシンタックスエレメントの値を、該mvdシンタックスエレメントの値より小さく、式(1)に示すP以上の任意の値に置換えて前記シンタックスエレメントメモリに格納することを特徴とする請求項1に記載の画像処理装置。
第3の閾値≧P=(第2の閾値+1)×2 (1)
The index generation unit may be context indexes having different values when the sum of the two index values is less than a first threshold, when the sum is greater than a second threshold greater than the first threshold, and at other times. Respectively,
The syntax element replacement unit further sets the value of the mvd syntax element of the reference submb that is equal to or greater than the third threshold indicated by the formula (1) to be smaller than the value of the mvd syntax element, and sets the formula (1) to The image processing apparatus according to claim 1, wherein the value is stored in the syntax element memory in place of an arbitrary value greater than or equal to P.
Third threshold ≧ P = (second threshold + 1) × 2 (1)
前記シンタックスエレメント置換部は、式(1)に示すPを前記第3の閾値とし、P以上である前記参照submbのmvdシンタックスエレメントの値をPに置換えて前記シンタックスエレメントメモリに格納することを特徴とする請求項2に記載の画像処理装置。   The syntax element replacement unit replaces the value of the mvd syntax element of the reference submb that is equal to or greater than P with P as the third threshold value, and stores it in the syntax element memory. The image processing apparatus according to claim 2. 前記シンタックスエレメント置換部は、さらに、式(2)が示す第4の閾値以上である前記参照submbのmvdシンタックスエレメントの値を所定のルールでエンコードして前記シンタックスエレメントメモリに格納し、
前記インデックス生成部は、前記シンタックスエレメントメモリに格納された、前記第4の閾値以上である参照submbのmvdシンタックスエレメントを前記所定のルールに基づいてデコードしてから該参照submbの前記指標値を算出し、
前記所定のルールは、エンコード後の値がエンコード前の値以下前記第4の閾値以上であり、かつ、2で割った後の整数部分が同一である2つの値が同一の値にエンコードされ、かつ、前記整数部分が1つ大きくなるとエンコード後の値も1つ大きくなることを特徴とする請求項2または3のいずれか1項に記載の画像処理装置。
第4の閾値≧Q=第2の閾値+2 (2)
The syntax element replacement unit further encodes a value of the mvd syntax element of the reference submb that is equal to or greater than a fourth threshold indicated by the expression (2) according to a predetermined rule, and stores the encoded value in the syntax element memory.
The index generation unit decodes the mvd syntax element of the reference submb that is stored in the syntax element memory and is equal to or greater than the fourth threshold based on the predetermined rule, and then the index value of the reference submb To calculate
The predetermined rule is that two values whose encoded values are equal to or smaller than the pre-encoded value and equal to or greater than the fourth threshold and whose integer parts after dividing by 2 are the same are encoded into the same value, 4. The image processing apparatus according to claim 2, wherein when the integer part is increased by 1, the value after encoding is also increased by one.
Fourth threshold ≧ Q = second threshold + 2 (2)
前記インデックス生成部は、前記参照submbの前記指標値が該参照submbのmvdシンタックスエレメントの絶対値の1/2になると判定した場合においてのみ、前記シンタックスエレメントメモリに格納された該参照submbのmvdシンタックスエレメントに対して前記所定のルールに基づいたデコードを行うことを特徴とする請求項4に記載の画像処理装置。   The index generation unit determines that the index value of the reference submb stored in the syntax element memory is only when the index value of the reference submb is determined to be ½ of the absolute value of the mvd syntax element of the reference submb. The image processing apparatus according to claim 4, wherein the decoding is performed on the mvd syntax element based on the predetermined rule. 前記第4の閾値は、式(2)に示すQであることを特徴とする請求項4または5に記載の画像処理装置。   The image processing apparatus according to claim 4, wherein the fourth threshold value is Q shown in Expression (2). CABAC符号化またはCABAC復号化により動きベクトルの符号化または復号化をマクロブロック毎に順次行う画像処理装置であって、
注目マクロブロックの符号化または復号化時に複数のシンタックスエレメントを参照されるマクロブロックである参照MBの前記複数のシンタックスエレメントであって、該参照MBを分割して得たサブマクロブロックである参照submb毎の各種動きベクトル差分をそれぞれ表す各種mvdシンタックスエレメントを含む前記複数のシンタックスエレメントを格納するシンタックスエレメントメモリと、
前記mvdシンタックスエレメント毎に割り当てられたコンテキストを格納するコンテキストメモリと、
前記注目マクロブロックの各サブマクロブロックについて、各mvdシンタックスエレメントにそれぞれ対応するコンテキストが前記コンテキストメモリに格納されたアドレスを示すコンテキストインデックスを生成する際に、該サブマクロブロックに対応する2つの前記参照submbの指標値をそれぞれ求め、求められた2つの前記指標値の和に基づいて前記コンテキストインデックスを生成するインデックス生成部であって、前記2つの指標値の和が第1の閾値未満であるときと、前記第1の閾値より大きい第2の閾値より大きいときと、他のときとにおいて異なる値のコンテキストインデックスをそれぞれ生成する前記インデックス生成部と、
式(3)が示す第3の閾値以上である前記参照submbのmvdシンタックスエレメントの値を、該mvdシンタックスエレメントの値より小さく、式(3)に示すP以上の任意の値に置換えて前記シンタックスエレメントメモリに格納するシンタックスエレメント置換部とを備えることを特徴とする画像処理装置。
第3の閾値≧P=(第2の閾値+1)×2 (3)
An image processing apparatus that sequentially encodes or decodes a motion vector for each macroblock by CABAC encoding or CABAC decoding,
The plurality of syntax elements of a reference MB, which is a macroblock to which a plurality of syntax elements are referred when encoding or decoding a target macroblock, and is a sub macroblock obtained by dividing the reference MB. A syntax element memory for storing the plurality of syntax elements including various mvd syntax elements respectively representing various motion vector differences for each reference submb;
A context memory for storing a context allocated for each mvd syntax element;
For each sub macroblock of the macro block of interest, when the context corresponding to each mvd syntax element generates a context index indicating the address stored in the context memory, the two macro macro blocks corresponding to the sub macro block are generated. An index generation unit that obtains each index value of a reference submb and generates the context index based on the sum of the two obtained index values, wherein the sum of the two index values is less than a first threshold value The index generation unit for generating context indexes of different values when, when greater than a second threshold greater than the first threshold, and at other times;
The value of the mvd syntax element of the reference submb that is equal to or larger than the third threshold indicated by the expression (3) is replaced with an arbitrary value that is smaller than the value of the mvd syntax element and is equal to or larger than P shown in the expression (3). An image processing apparatus comprising: a syntax element replacement unit for storing in the syntax element memory.
Third threshold ≧ P = (second threshold + 1) × 2 (3)
前記シンタックスエレメント置換部は、式(3)に示すPを前記第3の閾値とし、P以上である前記参照submbのmvdシンタックスエレメントの値をPに置換えて前記シンタックスエレメントメモリに格納することを特徴とする請求項7に記載の画像処理装置。   The syntax element replacement unit replaces the value of the mvd syntax element of the reference submb that is equal to or greater than P with P as the third threshold value, and stores it in the syntax element memory. The image processing apparatus according to claim 7. 前記シンタックスエレメント置換部は、さらに、式(4)が示す第4の閾値以上である前記参照submbのmvdシンタックスエレメントの値を所定のルールでエンコードして前記シンタックスエレメントメモリに格納し、
前記インデックス生成部は、前記シンタックスエレメントメモリに格納された、前記第4の閾値以上である参照submbのmvdシンタックスエレメントを前記所定のルールに基づいてデコードしてから該参照submbの前記指標値を算出し、
前記所定のルールは、エンコード後の値がエンコード前の値以下前記第4の閾値以上であり、かつ、2で割った後の整数部分が同一である2つの値が同一の値にエンコードされ、かつ、前記整数部分が1つ大きくなるとエンコード後の値も1つ大きくなることを特徴とする請求項7または8のいずれか1項に記載の画像処理装置。
第4の閾値≧Q=第2の閾値+2 (4)
The syntax element replacement unit further encodes a value of the mvd syntax element of the reference submb that is equal to or greater than a fourth threshold indicated by Formula (4) according to a predetermined rule, and stores the encoded value in the syntax element memory.
The index generation unit decodes the mvd syntax element of the reference submb that is stored in the syntax element memory and is equal to or greater than the fourth threshold based on the predetermined rule, and then the index value of the reference submb To calculate
The predetermined rule is that two values whose encoded values are equal to or smaller than the pre-encoded value and equal to or greater than the fourth threshold and whose integer parts after dividing by 2 are the same are encoded into the same value, 9. The image processing apparatus according to claim 7, wherein when the integer part is increased by one, the encoded value is also increased by one.
Fourth threshold ≧ Q = second threshold + 2 (4)
前記インデックス生成部は、前記参照submbの前記指標値が該参照submbのmvdシンタックスエレメントの絶対値の1/2になると判定した場合においてのみ、前記シンタックスエレメントメモリに格納された該参照submbのmvdシンタックスエレメントに対して前記所定のルールに基づいたデコードを行うことを特徴とする請求項9に記載の画像処理装置。   The index generation unit determines that the index value of the reference submb stored in the syntax element memory is only when the index value of the reference submb is determined to be ½ of the absolute value of the mvd syntax element of the reference submb. The image processing apparatus according to claim 9, wherein the decoding is performed on the mvd syntax element based on the predetermined rule. 前記第4の閾値は、式(4)に示すQであることを特徴とする請求項9または10に記載の画像処理装置。   11. The image processing apparatus according to claim 9, wherein the fourth threshold value is Q shown in Expression (4). 前記シンタックスエレメント置換部は、さらに、前記参照submbのmvdシンタックスエレメントを前記シンタックスエレメントメモリに格納する際に、該mvdシンタックスエレメントの値に関わらず、該参照submbの前記指標値が「0」になるか否かの判定をすると共に、前記指標値が「0」になると判定したときに、前記mvdシンタックスエレメントを「0」に置換えて前記シンタックスエレメントメモリに格納し、それ以外の場合には前記mvdシンタックスエレメントを前記シンタックスエレメントメモリに格納し、
前記インデックス生成部は、前記シンタックスエレメントメモリに格納された、前記参照submbの該mvdシンタックスエレメントの絶対値と、前記絶対値の2倍と、前記絶対値の1/2のうちのいずれか1つを前記指標値として求めることを特徴とする請求項7から11のいずれか1項に記載の画像処理装置。
The syntax element replacement unit further stores the mvd syntax element of the reference submb in the syntax element memory when the index value of the reference submb is “regardless of the value of the mvd syntax element”. In addition to determining whether or not the index value is “0”, the mvd syntax element is replaced with “0” and stored in the syntax element memory. In the case of storing the mvd syntax element in the syntax element memory,
The index generation unit is one of an absolute value of the mvd syntax element of the reference submb stored in the syntax element memory, twice the absolute value, and 1/2 of the absolute value. The image processing apparatus according to claim 7, wherein one is obtained as the index value.
JP2009261670A 2009-11-17 2009-11-17 Image processing apparatus Pending JP2011109364A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2009261670A JP2011109364A (en) 2009-11-17 2009-11-17 Image processing apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2009261670A JP2011109364A (en) 2009-11-17 2009-11-17 Image processing apparatus

Publications (1)

Publication Number Publication Date
JP2011109364A true JP2011109364A (en) 2011-06-02

Family

ID=44232380

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2009261670A Pending JP2011109364A (en) 2009-11-17 2009-11-17 Image processing apparatus

Country Status (1)

Country Link
JP (1) JP2011109364A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013001795A1 (en) * 2011-06-29 2013-01-03 パナソニック株式会社 Image encoding method, image decoding method, image encoding device, and image decoding device
WO2013006483A1 (en) * 2011-07-01 2013-01-10 Qualcomm Incorporated Video coding using adaptive motion vector resolution
CN109068144A (en) * 2018-07-18 2018-12-21 北京奇艺世纪科技有限公司 A kind of Probabilistic estimation, device and electronic equipment

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013001795A1 (en) * 2011-06-29 2013-01-03 パナソニック株式会社 Image encoding method, image decoding method, image encoding device, and image decoding device
WO2013006483A1 (en) * 2011-07-01 2013-01-10 Qualcomm Incorporated Video coding using adaptive motion vector resolution
CN103703781A (en) * 2011-07-01 2014-04-02 高通股份有限公司 Video coding using adaptive motion vector resolution
US10536701B2 (en) 2011-07-01 2020-01-14 Qualcomm Incorporated Video coding using adaptive motion vector resolution
CN109068144A (en) * 2018-07-18 2018-12-21 北京奇艺世纪科技有限公司 A kind of Probabilistic estimation, device and electronic equipment
CN109068144B (en) * 2018-07-18 2021-03-12 北京奇艺世纪科技有限公司 Probability estimation method and device and electronic equipment

Similar Documents

Publication Publication Date Title
JP6059384B2 (en) Method and apparatus for encoding or decoding
WO2020253831A1 (en) Method and device for coding and decoding, and storage medium
JP6315911B2 (en) Image encoding device, image encoding method and program, image decoding device, image decoding method and program
JP2002016500A (en) Method and device for variable length encoding and decoding using plural mapping tables
US9609316B2 (en) Image coding apparatus, image coding method, and recording medium thereof, image decoding apparatus, and image decoding method, and recording medium thereof
JP6208993B2 (en) Image decoding apparatus and decoding processing method of image decoding apparatus
US20230262258A1 (en) Method and apparatus for coding video using merging candidate list according to block division
WO2013089264A1 (en) Image quantization apparatus, method and program, and image inverse quantization apparatus, method and program
JP5116704B2 (en) Image coding apparatus and image coding method
US20150326859A1 (en) Video quantization-parameter encoding method, video quantization-parameter decoding method, device, and program
US20120121024A1 (en) Method and apparatus for parallel entropy encoding and parallel entropy decoding based on decoding rate
US20110103469A1 (en) Entropy encoding/decoding method and apparatus for accelerating video decoding
JP2011109364A (en) Image processing apparatus
JP2024019496A (en) Image encoder, image decoder, image encoding method, and image decoding method
JP2024019495A (en) Image encoder, image decoder, image encoding method, and image decoding method
JP6469277B2 (en) Image encoding device, image encoding method and program, image decoding device, image decoding method and program
JP2007259323A (en) Image decoding apparatus
US20160014415A1 (en) Method and apparatus for performing wave-front parallel encoding procedure with constraint on coding mode and/or quantization parameter selection
JP6187826B2 (en) Moving picture coding apparatus and moving picture coding method
US9219926B2 (en) Image encoding apparatus, image encoding method and program, image decoding apparatus, image decoding method and program
JP2007158698A (en) Image decoding apparatus and image decoding method
JP2006165699A (en) Image encoder and image encoding method
JP2015005903A (en) Compressor, decompressor and image processing apparatus
KR102668065B1 (en) Image encoding device, image decoding device, image encoding method, image decoding method, non-transitory computer-readable storage medium storing a computer program
JP2014187473A (en) Image compression device and image processing system