JP2006041659A - Variable length decoder - Google Patents

Variable length decoder Download PDF

Info

Publication number
JP2006041659A
JP2006041659A JP2004215240A JP2004215240A JP2006041659A JP 2006041659 A JP2006041659 A JP 2006041659A JP 2004215240 A JP2004215240 A JP 2004215240A JP 2004215240 A JP2004215240 A JP 2004215240A JP 2006041659 A JP2006041659 A JP 2006041659A
Authority
JP
Japan
Prior art keywords
processing unit
data
code
decoder
setting
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
JP2004215240A
Other languages
Japanese (ja)
Inventor
Yoshiyuki Wada
由之 和田
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co Ltd
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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP2004215240A priority Critical patent/JP2006041659A/en
Publication of JP2006041659A publication Critical patent/JP2006041659A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To reduce circuit resources not in use for a variable length decoder employing a PLA. <P>SOLUTION: An AND processing section includes a mode wherein one code is detected by one entry and a mode wherein a plurality of codes are detected by one entry, the AND processing section carries out the same operation as that of a configuration of prior arts in the mode wherein one code is detected by one entry and detects a plurality of the codes and informs an OR processing section about it when detecting any code in the mode wherein a plurality of the codes are detected in one entry. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

可変長符号で符号化されたデータを復号化する可変長デコーダに関するものである。   The present invention relates to a variable length decoder for decoding data encoded with a variable length code.

NTSCやPAL等の地上波アナログ放送方式および衛星放送方式のデジタル化などのAV機器のデジタル化に伴って、情報量の多い動画像をデジタル信号で効率的に通信するために、動画像圧縮技術が用いられている。動画像圧縮技術の代表的なものとして、MPEG(Moving Picture Exisperts Group)による方式がある。これはISO/IECにおいて議論され、国際標準化されたもので、画面間や画面内の相関を利用してデータ量を圧縮する符号化方式であり、差分符号化や変換符号化されたデータを可変長符号化することによってデータを圧縮する符号化方式である。   Along with the digitalization of AV equipment such as NTSC and PAL digital terrestrial broadcasting systems and satellite broadcasting systems, moving image compression technology to efficiently communicate moving images with a large amount of information with digital signals Is used. As a typical moving image compression technique, there is a method based on MPEG (Moving Picture Experts Group). This was discussed in ISO / IEC and internationally standardized. It is an encoding method that compresses the amount of data using correlation between screens and within screens, and variable encoding and conversion encoding data can be changed. This is an encoding method in which data is compressed by long encoding.

可変長符号化は、無損失のデータ圧縮のために使用される符号化で、データの統計的性質をもとに、固定長のデータを可変長符号に変換する。つまり、データの発生頻度に応じて、発生頻度の大きいデータを短い符号長の符号に変換し、発生頻度の小さいデータを長い符号長の符号に変換する。このデータと可変長符号の対応は符号表と呼ばれ、符号化するデータの統計的性質に応じた符号表を用いることによって、データを圧縮することが可能となる。   Variable length coding is coding used for lossless data compression, and converts fixed length data into variable length code based on the statistical properties of the data. That is, data having a high occurrence frequency is converted into a code having a short code length and data having a low occurrence frequency is converted into a code having a long code length in accordance with the occurrence frequency of the data. The correspondence between the data and the variable length code is called a code table, and the data can be compressed by using a code table corresponding to the statistical properties of the data to be encoded.

一方、可変長符号化されたデータの復号化処理は、符号化時に使用された符号表にしたがって復号化値を得る変換となる。   On the other hand, the decoding process of the variable-length encoded data is a conversion for obtaining a decoded value according to the code table used at the time of encoding.

一般に、可変長符号の復号化処理は符号化処理に比べて処理負荷が大きい。これは、可変長符号の復号化処理が、1つの符号の復号化を完了しなければ次の符号を復号化することができないという逐次的な処理であることによる。特に、映像データを遅延やコマ落ちなどを起こさずに再生するリアルタイム処理を実現する場合、可変長デコーダは高い処理性能が必要となり、このような要求を満たすために可変長デコーダは専用のハードウェアによって実現されることが多い。   In general, decoding processing of variable length codes has a larger processing load than encoding processing. This is because the variable length code decoding process is a sequential process in which the next code cannot be decoded unless the decoding of one code is completed. In particular, when realizing real-time processing that reproduces video data without causing delays or dropped frames, variable-length decoders require high processing performance. To meet these requirements, variable-length decoders have dedicated hardware. It is often realized by.

MPEGでは、符号化するデータに応じて異なる符号表を用いて可変長符号化される。これは、符号化するデータごとに統計的性質が異なるためである。さらに、MPEG−2(ISO/IEC 13818)やMPEG−4(ISO/IEC 14496)のように符号化方式が異なる場合においても、可変長符号化で使用される符号表は異なる。このため、複数の符号化方式に対応する可変長デコーダを実現する場合、異なる符号表を複数実装しなければならず、回路規模が増大する。   In MPEG, variable length encoding is performed using different code tables depending on data to be encoded. This is because the statistical properties differ depending on the data to be encoded. Furthermore, even when the encoding schemes are different, such as MPEG-2 (ISO / IEC 13818) and MPEG-4 (ISO / IEC 14496), the code tables used for variable length encoding are different. For this reason, when realizing a variable length decoder corresponding to a plurality of encoding schemes, a plurality of different code tables must be mounted, which increases the circuit scale.

特許文献1では、メモリを用いて符号表を実現する可変長符号の復号化方法が示されている。この方法で可変長デコーダを実現すると、メモリに格納されたデータを書き換えることによって複数の異なる符号表に対応することが可能になるが、メモリアクセスのためのアドレス計算や、メモリに格納されたデータのアクセスタイムによって、リアルタイム処理を実現するような高い処理性能を得ることは困難である。   Patent Document 1 discloses a variable length code decoding method for realizing a code table using a memory. When a variable length decoder is realized by this method, it becomes possible to cope with a plurality of different code tables by rewriting data stored in the memory. However, address calculation for memory access and data stored in the memory are possible. It is difficult to obtain high processing performance that realizes real-time processing depending on the access time.

一方、プログラマブル ロジック アレイ(PLA)を用いて符号表を実現する方式が非特許文献1に記載されている。PLAは、AND処理部とOR処理部の対によって1つのエントリが構成され、そのエントリが複数個存在するものである。各エントリのAND処理部には同じデータが入力され、各AND処理部は予め設定されたパターンと、入力データが一致するかどうかを検出する。OR処理部は、対応するAND処理部が一致を検出した場合に、予め設定された値と隣接するOR処理部の出力の論理和を出力し、対応するAND処理部が一致を検出しない場合には、隣接するOR処理部の出力をそのまま出力する。このPLAを用いる方法は、メモリを用いる方法に比べて、アドレス計算が不要であるため、より高い処理性能を実現することができる。
特開2001−267931号公報 「An Entropy Coding System for Digital HDTV Applications」、IEEE Transactions on Circuits and Systems for Video Technology、第1号(1991年、3月)
On the other hand, Non-Patent Document 1 describes a method for realizing a code table using a programmable logic array (PLA). In the PLA, one entry is constituted by a pair of an AND processing unit and an OR processing unit, and a plurality of such entries exist. The same data is input to the AND processing unit of each entry, and each AND processing unit detects whether the input data matches a preset pattern. The OR processing unit outputs a logical sum of the preset value and the output of the adjacent OR processing unit when the corresponding AND processing unit detects a match, and the corresponding AND processing unit does not detect the match. Outputs the output of the adjacent OR processing unit as it is. Since the method using PLA does not require address calculation compared to the method using memory, higher processing performance can be realized.
JP 2001-267931 A "An Entropy Coding System for Digital HDTV Applications", IEEE Transactions on Circuits and Systems for Video Technology, No. 1 (March 1991)

しかしながら、前記従来のPLAを使用する可変長デコーダでは、PLAのAND処理部において、1つのエントリに1つの符号が割り当てられるため、符号長の短い符号が割り当てられたエントリには、使用されない回路資源が存在してしまい、回路規模の増大を招くという課題を有していた。   However, in the variable length decoder using the conventional PLA, since one code is assigned to one entry in the AND processing unit of the PLA, circuit resources that are not used for an entry to which a code with a short code length is assigned. Existed, and there was a problem of increasing the circuit scale.

本発明は、前記従来の課題を解決するもので、回路規模の増大を抑制した可変長デコーダを提供することを目的とする。   The present invention solves the above-described conventional problems, and an object thereof is to provide a variable length decoder that suppresses an increase in circuit scale.

前記従来の課題を解決するために、本発明の可変長デコーダは、AND処理部において、1つのエントリで1つの符号を検出するモードと、1つのエントリで複数の符号を検出するモードを有する。1つのエントリで1つの符号を検出するモードでは前期従来の構成と同じ動作を行い、1つのエントリで複数の符号を検出するモードでは複数の符号を検出し、いずれかの符号を検出したときにOR処理部に通知する。   In order to solve the conventional problems, the variable length decoder of the present invention has a mode in which one code is detected by one entry and a mode in which a plurality of codes are detected by one entry in the AND processing unit. In the mode in which one code is detected in one entry, the same operation as the previous configuration is performed, and in the mode in which a plurality of codes are detected in one entry, a plurality of codes are detected, and when any one of the codes is detected Notify the OR processing unit.

本構成によって、符号長の短い複数の符号をAND処理部の1つのエントリに割り当てることができる。   With this configuration, a plurality of codes having a short code length can be assigned to one entry of the AND processing unit.

本発明の可変長デコーダによれば、符号長の短い複数の符号をAND処理部の1つのエントリに割り当てることができるため、従来の構成では使用されない回路資源を使用することが可能となり、回路規模の不必要な増大を抑制することが可能となる。   According to the variable length decoder of the present invention, since a plurality of codes having a short code length can be assigned to one entry of the AND processing unit, circuit resources that are not used in the conventional configuration can be used, and the circuit scale can be used. It is possible to suppress an unnecessary increase of.

以下本発明の実施の形態について、図面を参照しながら説明する。   Embodiments of the present invention will be described below with reference to the drawings.

図6および図7は可変長符号を復号化するために用いる符号表を示す。可変長符号の符号表は、符号と、その符号の長さと、その符号に対応する復号化値から構成される。図6では、例えば、符号00001は、5ビットの符号長で、対応する復号化値は2となる。   6 and 7 show code tables used for decoding variable length codes. The code table of the variable length code includes a code, a length of the code, and a decoded value corresponding to the code. In FIG. 6, for example, code 00001 has a code length of 5 bits and the corresponding decoded value is 2.

図4は、本発明の一実施例による可変長デコーダを説明するためのブロック図であり、バッファ401とデータ切り出し部404と、デコーダ406から構成される。バッファ401は、可変長符号化された入力データ400を一時的に格納するためのバッファであり、データ切り出し部404からの要求402にしたがってバッファに保持している可変長符号化されたデータ403をデータ切り出し部404に出力する。データ切り出し部404は、バッファ401から入力されるデータ403からデコーダ406の入力ビット数切り出し、切り出したデータ405をデコーダ406に出力する。デコーダ406は、符号表に基づいて切り出したデータ405に対応する符号長データ408をデータ切り出し部404に出力するとともに、復号化値407を出力し、1つの可変長符号の復号化が完了する。次の可変長符号を復号化するには、データ切り出し部404は、デコーダ406から入力される符号長データ408分のデータを読み進め、次のデータを切り出してデコーダ406に出力する。   FIG. 4 is a block diagram for explaining a variable length decoder according to an embodiment of the present invention, which includes a buffer 401, a data cutout unit 404, and a decoder 406. The buffer 401 is a buffer for temporarily storing the variable length encoded input data 400, and the variable length encoded data 403 held in the buffer according to the request 402 from the data cutout unit 404. The data is output to the data cutout unit 404. The data cutout unit 404 cuts out the number of input bits of the decoder 406 from the data 403 input from the buffer 401 and outputs the cut out data 405 to the decoder 406. The decoder 406 outputs the code length data 408 corresponding to the data 405 cut out based on the code table to the data cutout unit 404 and also outputs the decoded value 407 to complete the decoding of one variable length code. In order to decode the next variable length code, the data cutout unit 404 reads the data for the code length data 408 input from the decoder 406, cuts out the next data, and outputs it to the decoder 406.

図5は、本発明の一実施例による可変長デコーダの具体的な動作を、図7の符号表に基づいて符号化された符号の復号化によって説明するものである。時間t0に、001000100111101000という可変長符号化されたデータが、データ切り出し部404に入力されると、データ切り出し部404はデコーダ406に001000の6ビットのデータを出力する。デコーダ406は、符号表に基づいて、001000の入力から符号001に対応する符号長3と復号化値4を出力し、1つの符号の復号化処理を完了する。次に、時間t1において、データ切り出し部404は001000100111101000から3ビット読み進めた箇所から切り出した6ビットのデータ000100を切り出してデコーダ406に出力する。デコーダ406は、符号表に基づいて、000100の入力から符号000100に対応する符号長6と復号化値1を出力し、1つの符号の復号化処理を完了する。以降の符号についても同様に処理され、復号化が行われる。   FIG. 5 illustrates a specific operation of the variable length decoder according to the embodiment of the present invention by decoding a code encoded based on the code table of FIG. When variable-length encoded data 00100101111101000 is input to the data cutout unit 404 at time t0, the data cutout unit 404 outputs 6-bit data of 001000 to the decoder 406. Based on the code table, the decoder 406 outputs the code length 3 and the decoded value 4 corresponding to the code 001 from the input of 001000, and completes the decoding process of one code. Next, at time t <b> 1, the data cutout unit 404 cuts out 6-bit data 000100 cut out from a position read from 300100010111101000 by 3 bits and outputs the cut out data to the decoder 406. Based on the code table, the decoder 406 outputs the code length 6 and the decoded value 1 corresponding to the code 000100 from the input of 000100, and completes the decoding process of one code. Subsequent codes are similarly processed and decoded.

図8は、デコーダ406がPLAによって構成されることを説明するブロック図である。デコーダ406は、AND処理部800、AND処理部802、AND処理部804、AND処理部806と、OR処理部801、OR処理部803、OR処理部805、OR処理部807から構成される。AND処理部800、AND処理部802、AND処理部804、AND処理部806は同じ回路構成を有する。AND処理部800は、設定保持部808、設定保持部809、設定保持部810、設定保持部811、設定保持部812、設定保持部813とマッチング検出部814、マッチング検出部815、マッチング検出部816、マッチング検出部817、マッチング検出部818、マッチング検出部819と、論理積演算器820、論理積演算器821、論理積演算器822から構成される。設定保持部808、設定保持部809、設定保持部810、設定保持部811、設定保持部812、設定保持部813は同じ回路構成を有する。また、マッチング検出部814、マッチング検出部815、マッチング検出部816、マッチング検出部817、マッチング検出部818、マッチング検出部819は同じ回路構成を有する。   FIG. 8 is a block diagram for explaining that the decoder 406 is composed of PLA. The decoder 406 includes an AND processing unit 800, an AND processing unit 802, an AND processing unit 804, an AND processing unit 806, an OR processing unit 801, an OR processing unit 803, an OR processing unit 805, and an OR processing unit 807. The AND processing unit 800, the AND processing unit 802, the AND processing unit 804, and the AND processing unit 806 have the same circuit configuration. The AND processing unit 800 includes a setting holding unit 808, a setting holding unit 809, a setting holding unit 810, a setting holding unit 811, a setting holding unit 812, a setting holding unit 813, a matching detection unit 814, a matching detection unit 815, and a matching detection unit 816. , A matching detection unit 817, a matching detection unit 818, a matching detection unit 819, an AND operation unit 820, an AND operation unit 821, and an AND operation unit 822. The setting holding unit 808, the setting holding unit 809, the setting holding unit 810, the setting holding unit 811, the setting holding unit 812, and the setting holding unit 813 have the same circuit configuration. The matching detection unit 814, the matching detection unit 815, the matching detection unit 816, the matching detection unit 817, the matching detection unit 818, and the matching detection unit 819 have the same circuit configuration.

設定保持部808は、入力827が0か、1か、または無視(x)であるかの何れかを指定する値を保持する。マッチング検出部814は設定保持部808が保持する値が指定する値と入力827が一致するかどうかを検出し、一致する場合には1を出力し、一致しない場合には0を出力する。設定保持部808が無視(x)を指定する値を保持しているときには、入力827の値に依らずに常に1を出力する。このようなAND処理部によって、例えば、001という入力を検出したい場合には、設定保持部808と設定保持部809に0を指定する値を設定し、設定保持部810に1を指定する値を設定し、設定保持部812と設定保持部813にxを指定する値を設定することによって所望の入力パターンを検出することが可能となる。   The setting holding unit 808 holds a value that specifies whether the input 827 is 0, 1 or ignore (x). The matching detection unit 814 detects whether the value held by the setting holding unit 808 matches the value specified by the input 827, and outputs 1 if the values match, and outputs 0 if they do not match. When the setting holding unit 808 holds a value designating ignore (x), 1 is always output regardless of the value of the input 827. For example, when it is desired to detect an input of “001” by such an AND processing unit, a value specifying 0 is set in the setting holding unit 808 and the setting holding unit 809, and a value specifying 1 is set in the setting holding unit 810. It is possible to detect a desired input pattern by setting and setting a value specifying x in the setting holding unit 812 and the setting holding unit 813.

OR処理部801、OR処理部803、OR処理部805、OR処理部807の動作を説明する。OR処理部803、OR処理部805、OR処理部807は同じ回路構成を有する。OR処理部801はAND処理部800から入力される検出信号823が1のときに設定された値を出力し、検出信号823が0のときには0を出力する。OR処理部803は、AND処理部802から入力される検出信号825が1のときに設定された値とOR処理部801からのOR処理部出力データ824の論理和を出力し、検出信号825が0のときにはOR処理部801からのOR処理部出力データ824を出力する。   The operations of the OR processing unit 801, the OR processing unit 803, the OR processing unit 805, and the OR processing unit 807 will be described. The OR processing unit 803, the OR processing unit 805, and the OR processing unit 807 have the same circuit configuration. The OR processing unit 801 outputs a value set when the detection signal 823 input from the AND processing unit 800 is 1, and outputs 0 when the detection signal 823 is 0. The OR processing unit 803 outputs a logical sum of the value set when the detection signal 825 input from the AND processing unit 802 is 1 and the OR processing unit output data 824 from the OR processing unit 801, and the detection signal 825 When 0, OR processing unit output data 824 from the OR processing unit 801 is output.

上記、PLAを用いたデコーダ406を用いて図6および図7の符号表を実現する場合の設定を図9と図10を用いて説明する。   The setting for realizing the code tables of FIGS. 6 and 7 using the decoder 406 using PLA will be described with reference to FIGS. 9 and 10. FIG.

図9は図6の符号表を実現するときの設定である。図9の設定0はAND処理部の設定保持部で指定する値であり、設定1および設定2はOR処理部に設定する値である。エントリは、AND処理部とOR処理部の対の何れであるかに対応し、エントリが1のものはAND処理部800とOR処理部801に対応し、2のものはAND処理部802とOR処理部803に対応する。例えば、図9のエントリ1では、設定保持部808と設定保持部809と設定保持部810と設定保持部811に0を指定する値が設定され、設定保持部812に1を指定する値が設定され、設定保持部813にxを指定する値が設定され、AND処理部800の検出信号823が1のときに、OR処理部801は符号長である5と復号化値である2を出力するように設定される。なお、符号長と復号化値の両方を復号化する構成として設定1と設定2を設けたが、設定1のみまたは設定2のみをOR処理部に設定する構成としてもよい。   FIG. 9 shows settings for realizing the code table of FIG. The setting 0 in FIG. 9 is a value specified by the setting holding unit of the AND processing unit, and the setting 1 and the setting 2 are values set in the OR processing unit. An entry corresponds to a pair of an AND processing unit and an OR processing unit, an entry having 1 corresponds to an AND processing unit 800 and an OR processing unit 801, and two has an AND processing unit 802 and an OR. This corresponds to the processing unit 803. For example, in entry 1 in FIG. 9, values specifying 0 are set in the setting holding unit 808, setting holding unit 809, setting holding unit 810, and setting holding unit 811, and values specifying 1 are set in the setting holding unit 812. When the value specifying x is set in the setting holding unit 813 and the detection signal 823 of the AND processing unit 800 is 1, the OR processing unit 801 outputs 5 which is a code length and 2 which is a decoded value. Is set as follows. Although setting 1 and setting 2 are provided as a configuration for decoding both the code length and the decoded value, only setting 1 or only setting 2 may be set in the OR processing unit.

図1は本発明の一実施の形態を示すブロック図である。図1において、図8と同じ構成要素については同じ符号を用い、説明を省略する。   FIG. 1 is a block diagram showing an embodiment of the present invention. In FIG. 1, the same components as those in FIG.

図1の本発明の一実施の形態におけるデコーダ406は、AND処理部100、AND処理部101、AND処理部102は同じ回路構成を有する。AND処理部100は、AND処理部800にモード保持部106とセレクタ103、セレクタ104、セレクタ105、セレクタ108と論理和演算器107が追加されたものである。モード保持部106は、AND処理部100で2つの符号を同時に検出するかどうかを保持する。モード保持部106が2つの符号を同時に検出するモードを保持するとき、セレクタ103は入力827を選択し、セレクタ104は入力828を選択し、セレクタ105は入力829を選択し、セレクタ108は論理和演算器107の出力を選択する。モード保持部106が1つの符号のみを検出するモードを保持するとき、セレクタ103は入力830を選択し、セレクタ104は入力831を選択し、セレクタ105は入力832を選択し、セレクタ108は論理積演算器822の出力を選択する。   In the decoder 406 according to the embodiment of the present invention shown in FIG. 1, the AND processing unit 100, the AND processing unit 101, and the AND processing unit 102 have the same circuit configuration. The AND processing unit 100 is obtained by adding a mode holding unit 106, a selector 103, a selector 104, a selector 105, a selector 108, and a logical sum calculator 107 to the AND processing unit 800. The mode holding unit 106 holds whether the AND processing unit 100 detects two codes at the same time. When the mode holding unit 106 holds a mode in which two codes are detected simultaneously, the selector 103 selects the input 827, the selector 104 selects the input 828, the selector 105 selects the input 829, and the selector 108 performs a logical sum. The output of the arithmetic unit 107 is selected. When the mode holding unit 106 holds a mode in which only one code is detected, the selector 103 selects the input 830, the selector 104 selects the input 831, the selector 105 selects the input 832, and the selector 108 performs a logical product. The output of the calculator 822 is selected.

上記、本発明の一実施の形態を用いて図6および図7の符号表に基づいて符号長を復号化する場合の設定を図2と図3を用いて説明する。   The setting when the code length is decoded based on the code tables of FIGS. 6 and 7 using the embodiment of the present invention will be described with reference to FIGS.

図3は図7の符号長を復号化する符号表を実現するときの設定である。図3の設定0はAND処理部の設定保持部で指定する値であり、設定1はモード保持部に設定する値であり、設定2はOR処理部に設定する値である。エントリは、AND処理部とOR処理部の対の何れであるかに対応し、エントリが1のものはAND処理部100とOR処理部801に対応し、2のものはAND処理部102とOR処理部803に対応する。モード保持部で設定する値は、0は1つの符号のみを検出するモードであることを指定し、1は2つの符号を検出するモードであることを指定する。例えば、図3のエントリ1では、モード保持部に1が指定されているため、エントリ1のAND処理部は2つの符号を検出する。この例では、AND処理部100において、001という符号と111という符号が同時に検出される。   FIG. 3 shows settings for realizing a code table for decoding the code length of FIG. In FIG. 3, setting 0 is a value specified by the setting holding unit of the AND processing unit, setting 1 is a value set in the mode holding unit, and setting 2 is a value set in the OR processing unit. An entry corresponds to a pair of an AND processing unit and an OR processing unit, an entry having 1 corresponds to an AND processing unit 100 and an OR processing unit 801, and two has an AND processing unit 102 and an OR. This corresponds to the processing unit 803. The value set by the mode holding unit specifies that 0 is a mode for detecting only one code, and 1 is a mode for detecting two codes. For example, in entry 1 of FIG. 3, since 1 is designated in the mode holding unit, the AND processing unit of entry 1 detects two codes. In this example, the AND processing unit 100 simultaneously detects a code of 001 and a code of 111.

図2は図6の符号長を復号化する符号表を実現するときの設定である。図2の設定では設定1が全て0であるので、全てのエントリはそれぞれ1つの符号を検出する。   FIG. 2 shows settings for realizing a code table for decoding the code length of FIG. In the setting of FIG. 2, since all the settings 1 are 0, all entries detect one code.

かかる構成によれば、モード保持部とセレクタと論理和演算器を追加することにより、使用されない回路資源を削減することができ、PLAのエントリ数(個数)を削減することができる。   According to such a configuration, by adding a mode holding unit, a selector, and an OR calculator, circuit resources that are not used can be reduced, and the number of PLA entries (number) can be reduced.

本発明のデコーダとプロセッサを接続し、上記図2および図3の設定を、プロセッサ上で動作するプログラムによって行ってもよい。図11は本発明のデコーダに図2のエントリ1の設定を行うプログラムの例である。wt命令はデータをレジスタに書き込む命令で、1行目では、『0』というデータが本発明のデコーダにおけるエントリ1の設定0の最上位ビットを表すレジスタ(%conf_1_0_0)に書き込まれる。2行目から6行目では、1行目と同様にエントリ1の設定0の設定が行われる。6行目で書き込まれる『2』というデータは図2の『x』をあらわす。設定1の設定は7行目の%conf_1_1への書き込みによって行われ、設定2の設定は8行目の%conf_1_2への書き込みによって行われる。本発明のデコーダの設定を専用命令で行うこともできる。図12は上記wt命令のような汎用的な命令ではなく、本発明のデコーダ専用の命令で設定するプログラムの例である。setconf1命令はエントリ1の設定を行う命令であり、setconf2命令はエントリ2の設定を行う命令で、setconf3命令はエントリ3の設定を行う命令である。このような専用命令を用いて設定することで、本発明のデコーダの設定に要する時間を削減することができる。   The decoder of the present invention may be connected to a processor, and the settings shown in FIGS. 2 and 3 may be performed by a program operating on the processor. FIG. 11 shows an example of a program for setting entry 1 of FIG. 2 in the decoder of the present invention. The wt instruction is an instruction for writing data into a register. In the first line, data “0” is written into a register (% conf — 1 — 0 — 0) representing the most significant bit of setting 0 of entry 1 in the decoder of the present invention. In the second to sixth lines, the setting 0 of entry 1 is set as in the first line. The data “2” written in the sixth line represents “x” in FIG. Setting 1 is set by writing to% conf_1_1 on the seventh line, and setting 2 is set by writing to% conf_1_2 on the eighth line. The setting of the decoder of the present invention can also be performed with a dedicated instruction. FIG. 12 shows an example of a program set by a dedicated instruction for the decoder of the present invention, not a general purpose instruction such as the wt instruction. The setconf1 instruction is an instruction for setting entry 1, the setconf2 instruction is an instruction for setting entry 2, and the setconf3 instruction is an instruction for setting entry 3. By setting using such a dedicated instruction, the time required for setting the decoder of the present invention can be reduced.

なお、上記一実施の形態では、AND処理部では2つの符号を検出する構成としたが、3つ以上の符号を検出する構成としてもよいし、上記一実施の形態では、全てのエントリで複数の符号を検出することができる構成としたが、一部のエントリのみ複数の符号を検出できる構成としてもよいし、上記一実施の形態では、エントリごとにモードを設けたが複数のエントリごとにモードを設けてもよい。   In the above-described embodiment, the AND processing unit detects two codes. However, the AND processing unit may detect three or more codes. In the above-described embodiment, multiple entries may be used for all entries. However, it may be configured such that only some of the entries can detect a plurality of codes. In the above embodiment, a mode is provided for each entry. A mode may be provided.

本発明に係る復号化装置等は、LSI等の電子回路で実現される映像デコーダ等として利用することができる。例えば、符号化された動画像を復号化して再生するコンピュータ、PDA、デジタル放送受信機及び携帯電話機等に備えられる映像デコーダ等として有用である。   The decoding device or the like according to the present invention can be used as a video decoder or the like realized by an electronic circuit such as an LSI. For example, the present invention is useful as a video decoder or the like provided in a computer, PDA, digital broadcast receiver, mobile phone, or the like that decodes and plays back an encoded moving image.

本発明の実施の形態における可変長デコーダのデコーダの構成を示す図The figure which shows the structure of the decoder of the variable-length decoder in embodiment of this invention 本発明の実施の形態1における可変長デコーダの設定を示す図The figure which shows the setting of the variable-length decoder in Embodiment 1 of this invention 本発明の実施の形態1における可変長デコーダの設定を示す図The figure which shows the setting of the variable-length decoder in Embodiment 1 of this invention 本発明の実施の形態における可変長デコーダを説明する図The figure explaining the variable-length decoder in embodiment of this invention 本発明の実施の形態における可変長デコーダの動作の模式図Schematic diagram of the operation of the variable-length decoder in the embodiment of the present invention 可変長符号の符号表を示す図Diagram showing the code table of variable length codes 可変長符号の符号表を示す図Diagram showing the code table of variable length codes PLAによる可変長デコーダのデコーダを示す図The figure which shows the decoder of the variable length decoder by PLA PLAによる可変長デコーダの設定を示す図The figure which shows the setting of the variable length decoder by PLA PLAによる可変長デコーダの設定を示す図The figure which shows the setting of the variable length decoder by PLA デコーダを設定するプログラムを示す図The figure which shows the program which sets the decoder デコーダを設定するプログラムを示す図The figure which shows the program which sets the decoder

符号の説明Explanation of symbols

100 AND処理部
101 AND処理部
102 AND処理部
103 セレクタ
104 セレクタ
105 セレクタ
106 モード保持部
108 セレクタ
400 入力データ
401 バッファ
402 要求
403 データ
404 データ切り出し部
405 切り出したデータ
406 デコーダ
407 出力データ
408 符号長データ
800,802,804,806 AND処理部
801,803,805,807 OR処理部
808,809,810,811,812,813 設定保持部
814,815,816,817,818,819 マッチング検出部
820,821,822 論理積演算器
823 検出信号
824 OR処理部出力データ
825 検出信号
826 OR処理部出力データ
827,828,829,830,831,832 入力データ
100 AND processing unit 101 AND processing unit 102 AND processing unit 103 selector 104 selector 105 selector 106 mode holding unit 108 selector 400 input data 401 buffer 402 request 403 data 404 data extraction unit 405 extracted data 406 decoder 407 output data 408 code length data 800, 802, 804, 806 AND processing unit 801, 803, 805, 807 OR processing unit 808, 809, 810, 811, 812, 813 Setting holding unit 814, 815, 816, 817, 818, 819 Matching detection unit 820, 821, 822 AND operator 823 Detection signal 824 OR processing unit output data 825 Detection signal 826 OR processing unit output data 827, 828, 829, 830, 831, 832 Input data

Claims (2)

可変長の符号を復号化するデコーダであって、第一の入力データが予め設定されたパターンと一致するかどうかを検出するAND処理部と、前記AND処理部が前記第一の入力データと前記予め設定されたパターンの一致を検出すると予め設定されたデータと第二の入力データの論理和を出力し、前記AND処理部が前記第一の入力データと前記予め設定されたパターンの一致を検出しないと前記第二の入力データを出力するOR処理部から構成されるエントリが複数存在し、各エントリの前記第一の入力データは前記デコーダの入力に接続され、各エントリの前記第二の入力データは隣接するエントリの前記OR処理部の出力に接続されるプログラマブル論理アレイを有し、前記プログラマブル論理アレイの全てのエントリの前記AND処理部に、1つの符号を前記予め設定されたパターンに設定するモードと、複数の符号を前記予め設定されたパターンに設定するモードを有することを特徴とする復号化装置。 A decoder for decoding a variable-length code, wherein an AND processing unit that detects whether or not first input data matches a preset pattern; and the AND processing unit includes the first input data and the first input data When a preset pattern match is detected, a logical sum of the preset data and the second input data is output, and the AND processing unit detects the match between the first input data and the preset pattern. Otherwise, there are a plurality of entries composed of OR processing units that output the second input data, and the first input data of each entry is connected to the input of the decoder, and the second input of each entry Data has a programmable logic array connected to the output of the OR processing section of adjacent entries, and the AND processing of all entries of the programmable logic array. The parts, a mode one code set to the predetermined pattern, the decoding apparatus characterized by having a mode for setting a plurality of codes to said predetermined pattern. 可変長の符号を復号化するデコーダであって、第一の入力データが予め設定されたパターンと一致するかどうかを検出するAND処理部と、前記AND処理部が前記第一の入力データと前記予め設定されたパターンの一致を検出すると予め設定されたデータと第二の入力データの論理和を出力し、前記AND処理部が前記第一の入力データと前記予め設定されたパターンの一致を検出しないと前記第二の入力データを出力するOR処理部から構成されるエントリが複数存在し、各エントリの前記第一の入力データは前記デコーダの入力に接続され、各エントリの前記第二の入力データは隣接するエントリの前記OR処理部の出力に接続されるプログラマブル論理アレイを有し、前記プログラマブル論理アレイの一部のエントリの前記AND処理部に、1つの符号を前記予め設定されたパターンに設定するモードと、複数の符号を前記予め設定されたパターンに設定するモードを有することを特徴とする復号化装置。 A decoder for decoding a variable-length code, wherein an AND processing unit that detects whether or not first input data matches a preset pattern; and the AND processing unit includes the first input data and the first input data When a preset pattern match is detected, a logical sum of the preset data and the second input data is output, and the AND processing unit detects the match between the first input data and the preset pattern. Otherwise, there are a plurality of entries composed of OR processing units that output the second input data, and the first input data of each entry is connected to the input of the decoder, and the second input of each entry The data has a programmable logic array connected to the output of the OR processing unit of adjacent entries, and the AND process of some entries of the programmable logic array. The parts, a mode one code set to the predetermined pattern, the decoding apparatus characterized by having a mode for setting a plurality of codes to said predetermined pattern.
JP2004215240A 2004-07-23 2004-07-23 Variable length decoder Pending JP2006041659A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004215240A JP2006041659A (en) 2004-07-23 2004-07-23 Variable length decoder

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004215240A JP2006041659A (en) 2004-07-23 2004-07-23 Variable length decoder

Publications (1)

Publication Number Publication Date
JP2006041659A true JP2006041659A (en) 2006-02-09

Family

ID=35906211

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004215240A Pending JP2006041659A (en) 2004-07-23 2004-07-23 Variable length decoder

Country Status (1)

Country Link
JP (1) JP2006041659A (en)

Similar Documents

Publication Publication Date Title
US8462841B2 (en) System, method and device to encode and decode video data having multiple video data formats
US7804903B2 (en) Hardware-based CABAC decoder
US5576765A (en) Video decoder
US6008745A (en) Variable length decoding using lookup tables
US6215424B1 (en) System for variable length codeword processing suitable for video and other applications
US11234005B2 (en) Device and method of video decoding with first and second decoding code
JP2005510981A (en) Multi-channel video transcoding system and method
US20060133507A1 (en) Picture information decoding method and picture information encoding method
US6185339B1 (en) Bit stream analyzing method and apparatus
US20200162748A1 (en) Device and method of video encoding with first and second encoding code
US6285789B1 (en) Variable length code decoder for MPEG
US20110316862A1 (en) Multi-Processor
US8625677B2 (en) Apparatus processing video stream
TWI455587B (en) Circuit and method for multi-format video codec
JP2007259323A (en) Image decoding apparatus
US20160134894A1 (en) Video compression method and video compressor
US20170064321A1 (en) System and method for decoding a video digital data stream using a table of range values and probable symbols
US8228214B2 (en) Variable-length code decoding apparatus and method
US6512852B1 (en) Method and apparatus for concatenating bits of odd-length words
US20070242749A1 (en) Image frame compression of video stream with fast random accessing and decompressing
US20120183071A1 (en) Video decoder with adaptive outputs
JP2006041659A (en) Variable length decoder
US20090245350A1 (en) Image coding apparatus and image coding method
US5619200A (en) Code table reduction apparatus for variable length decoder
US7675437B2 (en) Variable length decoding device and method for improving variable length decoding performance