JPH07203453A - Context generator and coder using the same - Google Patents

Context generator and coder using the same

Info

Publication number
JPH07203453A
JPH07203453A JP33574893A JP33574893A JPH07203453A JP H07203453 A JPH07203453 A JP H07203453A JP 33574893 A JP33574893 A JP 33574893A JP 33574893 A JP33574893 A JP 33574893A JP H07203453 A JPH07203453 A JP H07203453A
Authority
JP
Japan
Prior art keywords
register
image data
memory
word
data
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
JP33574893A
Other languages
Japanese (ja)
Inventor
Hitoshi Horie
等 堀江
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 System Solutions Japan Co Ltd
Original Assignee
Matsushita Graphic Communication Systems Inc
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 Graphic Communication Systems Inc filed Critical Matsushita Graphic Communication Systems Inc
Priority to JP33574893A priority Critical patent/JPH07203453A/en
Publication of JPH07203453A publication Critical patent/JPH07203453A/en
Pending legal-status Critical Current

Links

Landscapes

  • Image Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression Of Band Width Or Redundancy In Fax (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

PURPOSE:To generate context data at a high speed only with shift operation by realizing the generation of a state identification number required for coding for each state by the coder, that is, a context with only a general-purpose arithmetic logic circuit and its peripheral hardware. CONSTITUTION:The coder used for a context generator is made up of, e.g. a 40-bit arithmetic logic circuit l, a 40-bit shifter 2, a data RAM 3 storing picture data whose word width is 16-bit, a register bank 4 being a register set of 40-bit, an address control section 5 controlling R/W of the bank 4, an address control section 6 controlling the RAM 3, and a microprogram control section 7 controlling the generation of a context. In order to activate the coder, i-th image data word of a line Y-2 is set to a high-order word of the register R1, (i+1)th image data are given to a low-order word of the register R1, picture data of a line Y-1 are set to the register R2 and i-th word of the picture line is given to a low-order word of the register R3.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は画像データの符号化装置
に関し、特に、符号化シンボルをその周辺n画素P0、
P1、・・・Pnによって定義される状態Si=(P
0、P1、・・・Pn)に分離し、各状態毎に符号化す
る際に必要な状態識別番号Si(以下、コンテクストと
いう)を生成する装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a coding device for image data, and more particularly, to a coding symbol which is a pixel for a peripheral n pixel P0,
P1, ... State defined by Pn Si = (P
0, P1, ... Pn) and generates a state identification number Si (hereinafter, referred to as context) necessary for encoding each state.

【0002】[0002]

【従来の技術】従来この種の装置は、算術符号などを使
ったマルコフモデル符号化装置において必要になる。従
来の符号化装置におけるコンテクスト生成過程を説明す
る前に、このような符号化処理全体におけるコンテクス
ト生成の位置づけを説明する。図12は算術符号を用い
た、2値画像マルコフモデル符号器の概略構成図であ
る。算術符号は符号化シンボル系列の発生確率に対応す
る2進小数点を符号とするものである。また、図13は
符号化シンボルとマルコフモデルを構築する参照画素の
配置例を示し、”?”が符号化の対象となるシンボル
(画素)、Yラインは上記シンボルを含む処理ライン、
以降Y−1ラインは前ライン、Y−2ラインは前々ライ
ンであり、各ラインには図示のような参照画素としてA
〜Jを含むものである。図12に示す符号器は、コンテ
クスト生成部101、確率推定部102、各コンテクス
ト毎に優勢シンボル(MPS)の予測値と確率推定部1
02の状態番号を記憶するRAM(ここではコンテクス
トテーブル)103、および算術符号器104によって
構成されている。このような符号器において、コンテク
スト生成部101は、参照画素を適当な順番に並べて
(以下、ABC順とする)、状態識別信号
2. Description of the Related Art Conventionally, this type of device is required in a Markov model coding device using arithmetic code or the like. Before describing the context generation process in the conventional encoding device, the position of the context generation in the whole encoding process will be described. FIG. 12 is a schematic configuration diagram of a binary image Markov model encoder using arithmetic codes. The arithmetic code uses a binary point corresponding to the occurrence probability of the encoded symbol sequence as a code. Further, FIG. 13 shows an example of arrangement of coded symbols and reference pixels for constructing a Markov model, where "?" Is a symbol (pixel) to be coded, Y line is a processing line including the symbol,
After that, the Y-1 line is the previous line, the Y-2 line is the previous line, and each line has A as a reference pixel as shown.
~ J are included. The encoder shown in FIG. 12 includes a context generation unit 101, a probability estimation unit 102, a predicted value of a dominant symbol (MPS) and a probability estimation unit 1 for each context.
It is configured by a RAM (context table in this case) 103 for storing the state number 02 and an arithmetic encoder 104. In such an encoder, the context generation unit 101 arranges the reference pixels in an appropriate order (hereinafter, referred to as ABC order), and outputs the state identification signal.

【0003】[0003]

【数1】 n=0〜(210−1) を作る。状態識別信号Snは各画素が2通りの値をとる
ので,全部で210個存在する。コンテクストSnに対応
するコンテクストテーブルの内容*Snは、MPSの予
測値と確率推定テーブル(Qeテーブル)の状態番号か
ら構成されている。即ち、
[Equation 1] Make n = 0 to (210-1). Since each pixel has two values for the state identification signal Sn, there are a total of 2 @ 10 values. The content * Sn of the context table corresponding to the context Sn is composed of the predicted value of the MPS and the state number of the probability estimation table (Qe table). That is,

【0004】[0004]

【数2】 *Sn=[MPS予測値,Qeテーブル状態番号] ここで,*XはXが示すメモリの内容を表わす。i番目
のシンボルの算術符号化データCiは、コンテクストテ
ーブルの内容と,これが指し示す確率推定部102の内
容(確率推定値Qe)を用いた再帰的な算術演算処理に
よって次のように得られる。
## EQU00002 ## * Sn = [MPS predicted value, Qe table state number] where * X represents the contents of the memory indicated by X. The arithmetically encoded data Ci of the i-th symbol is obtained as follows by a recursive arithmetic operation process using the content of the context table and the content of the probability estimation unit 102 (probability estimated value Qe) pointed to by the context table.

【0005】[0005]

【数3】 Ci=Ci-1+f{MPS予測値,Qe} =Ci-1+f{*Sn,*[*Sn]} (1) ここで”+”は符号データの連絡処理であり、fは符号
化アルゴリズムを表わす。しかし、これは本発明の範囲
外であり詳細は「ISO 11544(JBIG)」ま
たは[CCITT勧告T. 82」に記載されている。こ
のような符号化処理を効率良く実行するには、コンテク
ストSnの生成と*Snの読みだしを効率化することが
重要である。
## EQU00003 ## Ci = Ci-1 + f {MPS predicted value, Qe} = Ci-1 + f {* Sn, * [* Sn]} (1) Here, "+" is a communication process of code data and f is a code Representation algorithm. However, this is outside the scope of the invention and details are described in "ISO 11544 (JBIG)" or [CCITT Recommendation T. 82]. In order to efficiently execute such encoding processing, it is important to make the generation of the context Sn and the reading of * Sn efficient.

【0006】従来、この種の符号化装置におけるコンテ
クストの生成は専用のハードウェア、または汎用のマイ
クロプロセッサの算術論理演算回路(ALU)を使って
実行されていた。図14はコンテクトを生成するための
専用ハードウェアを示すブロック図である。なお、この
ような専用のハードウェアの具体的な構成については特
開平4ー6954号公報に詳しく記載されている。同図
に示すように、複数のラインメモリと、それに続く1ビ
ットの遅延素子を参照画素の配置に対応するように並
べ、それぞれの遅延素子の出力を専用レジスタの入力信
号としてコンテクスト識別信号を構成するものである。
1シンボルの符号化が終了すると、画像データを右に1
ビットシフトすることによって新しいコンテクストが生
成される。
Conventionally, the generation of the context in this type of encoding device has been executed by using dedicated hardware or an arithmetic logic unit (ALU) of a general-purpose microprocessor. FIG. 14 is a block diagram showing dedicated hardware for generating a protect. Note that the specific configuration of such dedicated hardware is described in detail in Japanese Patent Laid-Open No. 4-6954. As shown in the figure, a plurality of line memories and a 1-bit delay element following the line memory are arranged so as to correspond to the arrangement of reference pixels, and the output of each delay element is used as an input signal of a dedicated register to form a context identification signal. To do.
When the encoding of one symbol is completed, the image data is moved to the right by 1
A new context is created by bit shifting.

【0007】図15〜図16は、汎用ALUを使って、
プログラム処理によって実現した例である。図15はメ
モリ上の符号化画素(?)と参照画素(A〜J)の配置
を示したものである。この状態を前提にして図16のフ
ローに従って従来の処理例を説明する。処理1401で
参照画素が含まれているワードデータのアドレスを計算
する。処理1402は、コンテクストを作るレジスタR
1をクリアする。処理1403で、レジスタR1にワー
ドAの画像データをロードする。処理1404では、画
素Cが”1”かどうか判断し、”1”であれば処理14
05でレジスタのb2ビットを”1”に設定する。ここ
で、レジスタR1のビットはLSB側からb0,b1,
b2,・・・,b15としている。以上の処理を全ての
参照画素について繰り返すとレジスタR1にコンテクス
トデータが構成される。1画素の符号化が終了すると,
参照画素位置を処理1401によって計算して上記の処
理を繰り返す。マイクロプロセッサでは、処理140
2、処理1403、処理1405は1マシンサイクルで
実行できるが、処理1404等の条件判断は2〜3マシ
ンサイクルかかるのが普通である。そうすると1つのコ
ンテクストを生成するために,処理1401等を除いて
評価しても最低30〜40マシンサイクルが必要とな
る。
FIG. 15 to FIG. 16 use a general-purpose ALU to
This is an example realized by program processing. FIG. 15 shows the arrangement of coded pixels (?) And reference pixels (A to J) on the memory. Given this state, a conventional processing example will be described according to the flow of FIG. In process 1401, the address of the word data including the reference pixel is calculated. The process 1402 is performed by the register R that creates a context.
Clear 1. In process 1403, the image data of word A is loaded into the register R1. In processing 1404, it is determined whether the pixel C is "1", and if it is "1", processing 14
At 05, the b2 bit of the register is set to "1". Here, the bits of the register R1 are b0, b1, and LSB from the LSB side.
b2, ..., b15. When the above processing is repeated for all the reference pixels, the context data is formed in the register R1. When the encoding of one pixel is completed,
The reference pixel position is calculated by processing 1401 and the above processing is repeated. In the microprocessor, processing 140
2, the processing 1403 and the processing 1405 can be executed in one machine cycle, but the condition judgment such as the processing 1404 usually takes 2 to 3 machine cycles. Then, in order to generate one context, at least 30 to 40 machine cycles are required even if the evaluation is performed excluding the processing 1401 and the like.

【0008】[0008]

【発明が解決しようとする課題】上述のように構成され
た専用ハードウェアによる実現は,高速であるが専用の
回路が必要となるため回路規模の増大、低価格で実現不
可能等の課題が生ずる。また、汎用ALUによる従来構
成では上記課題を解決できるものの処理時間がかかると
いう新たな課題が生ずる。
The realization by the dedicated hardware configured as described above has problems such as an increase in circuit scale and an unrealizable cost at a low cost because a dedicated circuit is required at high speed. Occurs. Further, although the conventional configuration using the general-purpose ALU can solve the above-mentioned problems, a new problem that processing time is required arises.

【0009】本発明は上述の課題に鑑みてなされたもの
で、汎用的なALUを使ってプログラム処理によって高
速にコンテクストを生成する符号化装置を提供すること
を主たる目的とする。
The present invention has been made in view of the above problems, and a main object of the present invention is to provide an encoding device for generating a context at high speed by program processing using a general-purpose ALU.

【0010】[0010]

【課題を解決するための手段】本発明は上述の課題を解
決するため,画像データを所定数ライン分格納するメモ
リと、このメモリのワード幅の少なくとも2倍+所定数
ビット以上の容量を有し、前記メモリより画像データを
ワード単位で入力する複数のレジスタと、このレジスタ
内の画像データを左右にビット単位にシフト処理するこ
とにより、符号化処理のための状態分離信号を生成する
シフト手段とを備えたものである。
In order to solve the above problems, the present invention has a memory for storing a predetermined number of lines of image data and a capacity of at least twice the word width of this memory + a predetermined number of bits or more. A plurality of registers for inputting image data in units of words from the memory, and shift means for shifting the image data in the registers to the left and right in bit units to generate a state separation signal for encoding processing. It is equipped with and.

【0011】[0011]

【作用】本発明の符号化装置は上述の構成によってコン
テクストの生成を、ALUとその周辺のハードウェアの
みで実現できるので、ハードウェアの汎用性を損なうこ
となく、シフト操作のみによってコンテクストデータを
高速に生成することができる。
With the above-described configuration, the encoding device of the present invention can realize the context generation only by the ALU and the hardware around it, so that the context data can be processed at high speed only by the shift operation without deteriorating the versatility of the hardware. Can be generated.

【0012】[0012]

【実施例】図1は本発明の符号化装置におけるコンテク
ストを生成する処理を実行する回路のブロック構成図で
ある。1は40ビット(本実施例では40ビットとする
が、これのみに限定されるものではなく所定数以上のビ
ットであればよい)のALU、2は40ビット(ALU
と同様である)のシフタ、3は画像データを格納するワ
ード幅16ビットのデータRAM、4は40ビット(A
LUと同様である)のレジスタの集合体であるレジスタ
バンク、これについては後に詳しく説明する。5はレジ
スタ4のR/Wを制御するアドレス制御部、6はデータ
RAM3のアクセスを制御するアドレス制御部、7はコ
ンテクスト生成における動作を制御するマイクロプログ
ラム制御部であり、制御プログラムはこのマイクロプロ
グラム制御部7の内部に含まれている。なお、8は制御
バス、9はデータバスである。
1 is a block diagram of a circuit for executing a process for generating a context in an encoding apparatus according to the present invention. 1 is a 40-bit (40-bit in the present embodiment, but is not limited to this, and may be a predetermined number or more) ALU, 2 is a 40-bit (ALU
(The same as the above), 3 is a data RAM having a word width of 16 bits for storing image data, and 4 is 40 bits (A
A register bank, which is a collection of registers (similar to LU), will be described in detail later. Reference numeral 5 is an address control unit that controls the R / W of the register 4, 6 is an address control unit that controls access to the data RAM 3, and 7 is a microprogram control unit that controls operations in context generation. The control program is this microprogram. It is included in the control unit 7. In addition, 8 is a control bus and 9 is a data bus.

【0013】また、図2に図1のレジスタ4の詳細な構
成を示す。図2において41はレジスタバンク4の一本
のレジスタ構成を示している。40ビットレジスタが下
位ワード(0〜15ビット)、上位ワード(16〜31
ビット)、拡張バイト(32〜39ビット)に分かれて
いる。42、43はセレクタであり、ALU1からのデ
ータあるいはデータバス9からのデータを選択し、それ
ぞれ上位ワード、下位ワードに書き込む。44は上位ワ
ード、下位ワードからデータを選択して読み出し、デー
タバス9へ出力するセレクタである。これらセレクタ4
2、43、44によって独立にデータRAM3または他
のレジスタにR/W(リード/ライト)できる構成にな
っている。それを制御する信号が45〜47である。こ
れらの制御信号は、上述したマイクロプログラムに従っ
てアドレス制御部6から出力される。
Further, FIG. 2 shows a detailed configuration of the register 4 of FIG. In FIG. 2, reference numeral 41 indicates a register configuration of the register bank 4. A 40-bit register has a lower word (0 to 15 bits) and an upper word (16 to 31 bits).
Bits) and extension bytes (32 to 39 bits). Reference numerals 42 and 43 are selectors, which select the data from the ALU 1 or the data from the data bus 9 and write them in the upper word and the lower word, respectively. Reference numeral 44 is a selector that selects and reads out data from the upper word and the lower word and outputs it to the data bus 9. These selectors 4
2, 43, and 44 make it possible to independently perform R / W (read / write) to the data RAM 3 or another register. The signals for controlling it are 45 to 47. These control signals are output from the address control unit 6 according to the above-mentioned microprogram.

【0014】図3はデータRAM3の内部構成を示した
ものである。領域A、領域Bにはそれぞれ確率推定部の
状態遷移とコンテクストテーブルが設定されているもの
とする。また領域Cは画像データが3ライン(Y〜Y−
2ライン)入力されているものとする。ADP0〜AD
P4は16ビットのアドレスポインタで、アドレス制御
部6に含まれている。
FIG. 3 shows the internal structure of the data RAM 3. It is assumed that the state transition and the context table of the probability estimation unit are set in the areas A and B, respectively. In the area C, the image data has 3 lines (Y to Y-
2 lines) It is assumed that it has been input. ADP0-AD
P4 is a 16-bit address pointer, which is included in the address control unit 6.

【0015】次に、本発明における符号化装置の動作を
説明する。図4はレジスタの使用方法を示したものであ
る。レジスタR1の上位ワードはY−2ラインのi番目
の画像データワード、下位ワードにはi+1番目の画像
データワードを入力する。レジスタR2にはY−1ライ
ンのデータを同様に入力する。レジスタR3はR1、R
2と異なり、下位ワードにYライン(処理ライン)のi
番目の画像データワードを入力する。このようにする
と、符号化対象画素と参照画素のレジスタ内の配置が同
図に示したように、参照画素C,H,Gは各レジスタの
拡張バイトに位置し、A,B,D,E,F,I,Jは各
レジスタの上位ワードに位置することになる。
Next, the operation of the coding apparatus according to the present invention will be described. FIG. 4 shows how to use the register. The upper word of the register R1 receives the i-th image data word of the Y-2 line, and the lower word thereof receives the (i + 1) th image data word. Similarly, the data of the Y-1 line is input to the register R2. Register R3 is R1, R
Unlike 2, the i of the Y line (processing line) is added to the lower word.
Enter the th image data word. With this arrangement, the reference pixels C, H, and G are located in the extension byte of each register as shown in FIG. , F, I, J will be located in the upper word of each register.

【0016】図5は1ラインの符号化処理の動作を示す
フロー図である。処理401で図3のADP2が示すア
ドレスに1ラインの画像データを外部から入力する。処
理402でデータRAM上の最終ワードの次のアドレス
に”0”を書き込む。この処理によって、ライン終端の
状態が図6に示すようになる。処理403でレジスタR
1〜R3の前ラインの符号化に用いたデータをクリアし
て、データRAM3上のADP2〜ADP4に格納され
ている画像データをレジスタバンク4にロードする。因
みに、初期状態での各レジスタの格納状態を図7に示
す。処理402、403はラインデータの外側を”0”
とみなすことに相当する。処理404でコンテクストデ
ータを作成する。処理405〜407は符号化処理であ
るが、本発明の範囲外であり詳細な説明は省略する。1
画素の符号化が終わると処理408〜処理410でレジ
スタR1〜R3を左に1ビットシフトする。処理411
の16シンボルが終了したか否なかを判別し、終了して
いない場合には処理404の上流に戻り、以上の処理を
繰り返し実行する。以上のように処理404〜410を
16回繰り返す。1ワード分の符号化が終了すると、処
理412〜処理414によってR1,R2,R3の下位
ワードに画像データを入力する。処理415の判断で、
1ラインの符号化が終わるまで上記の処理を繰り返す。
1ラインの符号化が終了すると、処理416によってア
ドレスポインタADP2の内容をADP3に移し、AD
P3の内容をADP4に移し、ADP4の内容をADP
2に移す。こうすることによって、ADP2,ADP
3,ADP4の指し示すアドレスが常に処理ライン、前
ライン、前々ラインを示すことになる。
FIG. 5 is a flow chart showing the operation of the encoding process for one line. In process 401, one line of image data is externally input to the address indicated by ADP2 in FIG. In process 402, "0" is written in the address next to the last word on the data RAM. By this processing, the state of the line end is as shown in FIG. Register R in process 403
The data used for encoding the previous lines 1 to R3 are cleared, and the image data stored in ADP2 to ADP4 on the data RAM 3 is loaded into the register bank 4. Incidentally, the storage state of each register in the initial state is shown in FIG. Processes 402 and 403 are "0" outside the line data.
Is equivalent to In process 404, context data is created. Although the processings 405 to 407 are encoding processings, they are outside the scope of the present invention, and detailed description thereof will be omitted. 1
When the pixel coding is completed, in steps 408 to 410, the registers R1 to R3 are shifted to the left by 1 bit. Process 411
It is determined whether or not 16 symbols have been completed. If not completed, the process returns to the upstream of the process 404 and the above processes are repeatedly executed. As described above, the processes 404 to 410 are repeated 16 times. When the encoding for one word is completed, the image data is input to the lower words of R1, R2, and R3 by processes 412 to 414. At the judgment of processing 415,
The above process is repeated until the encoding of one line is completed.
When the encoding of one line is completed, the contents of the address pointer ADP2 are moved to ADP3 by processing 416, and AD
The contents of P3 are moved to ADP4, and the contents of ADP4 are ADP
Move to 2. By doing this, ADP2, ADP
3, the address indicated by ADP4 always indicates the processing line, the preceding line, and the preceding line.

【0017】次に、処理404のコンテクストデータ生
成の具体的な動作を図8、図9を用いて説明する。図8
は処理404のコンテクスト生成の第1の実施例を示す
フロー図である。本実施例ではレジスタR0を用いてコ
ンテクストデータを生成する。処理501でレジスタR
1の内容を右に17ビットシフトしてR0にライトす
る。その結果、R0の内容は図9の701に示すように
なる。処理502ではR2を右に13ビットシフトし
て、R0の上位ワードにライトする。これによって、R
0は図9の702に示すようになる。処理503はR0
を右に5ビットシフトする(図9の703)。処理50
4は、R3の上位ワードをR0の上位ワードにライトす
る(図9の704)。処理505でR0を左に22ビッ
トシフトし、処理506で右に30ビットシフトする。
この時、R0の左から”0”が入るようになっており、
R0の下位ワードは図9の706のようにコンテクスト
データが生成される。シフタでシフト時に左右から”
0”が入る構成は特殊なものではない。このデータをア
ドレスポインタADP1に書き込んで、その内容を参照
すれば符号化に必要な情報が得られる。以上の各処理は
1マシンサイクルで実行可能であり,図16の従来例に
比べて高速に処理できる。図8では処理502、504
のようにレジスタ間で上位ワード、下位ワードを別々に
アクセスできる仕組みを前提にしている。
Next, a concrete operation of the context data generation of the process 404 will be described with reference to FIGS. 8 and 9. Figure 8
FIG. 8 is a flowchart showing a first example of context generation of process 404. In this embodiment, the register R0 is used to generate context data. Register 501 in process 501
The contents of 1 are shifted to the right by 17 bits and written to R0. As a result, the contents of R0 are as shown at 701 in FIG. In process 502, R2 is shifted to the right by 13 bits and written in the upper word of R0. By this, R
0 becomes as indicated by 702 in FIG. Process 503 is R0
Is shifted to the right by 5 bits (703 in FIG. 9). Processing 50
4 writes the upper word of R3 to the upper word of R0 (704 in FIG. 9). In process 505, R0 is shifted to the left by 22 bits, and in process 506, it is shifted to the right by 30 bits.
At this time, "0" is entered from the left of R0,
Context data is generated in the lower word of R0 as shown by 706 in FIG. From the left and right when shifting with the shifter
The configuration that "0" is entered is not special. By writing this data in the address pointer ADP1 and referring to the content, the information necessary for encoding can be obtained. Each of the above processes can be executed in one machine cycle. Yes, processing can be performed faster than in the conventional example of Fig. 16. In Fig. 8, processes 502 and 504 are performed.
It is assumed that the upper word and the lower word can be accessed separately between the registers.

【0018】次に、レジスタとデータRAM間のアクセ
スに対してのみ、レジスタの上位、下位ワードが独立に
アクセスできる場合の処理例を図10のフロー図に示
す。このフロー図で、WRKA,WRKB,WRKCは
データRAM3上に設定したワーク領域である。処理6
01、処理602では、それぞれ画素A,Dをビット1
6の位置に移動し、ワーク領域に格納する。処理60
4,605によって、レジスタR0の内容は701のよ
うになる。処理606,607によって、R0は703
のようになる。処理608によって、R0は704のよ
うになる。処理609以降は、処理505以降と同一で
ある。図8と比較すると処理が多くなっているが、従来
例に比較すると処理ステップ数は少ない。いづれの実施
例もビット判定を必要とせず、シフト操作のみによって
コンテクストデータの生成が可能である。
Next, a flow chart of FIG. 10 shows a processing example in which the upper and lower words of the register can be independently accessed only for the access between the register and the data RAM. In this flow chart, WRKA, WRKB, and WRKC are work areas set on the data RAM 3. Process 6
01 and processing 602, the pixels A and D are set to bit 1 respectively.
Move to position 6 and store in the work area. Processing 60
4, 605, the content of the register R0 becomes 701. By processing 606 and 607, R0 is 703
become that way. By the process 608, R0 becomes like 704. The process 609 and subsequent steps are the same as the process 505 and subsequent steps. Although the number of processes is larger than that of FIG. 8, the number of processing steps is smaller than that of the conventional example. In each of the embodiments, the bit judgment is not required, and the context data can be generated only by the shift operation.

【0019】以上の実施例は図13の参照画素配置を前
提としたが、ディザ画像や網点画像など周期性の高い画
像では、参照画素の配置を変えることによって符号化性
能を上げることができる。ここでは、画素DをYライン
の符号化済みの画素上に移動した場合のコンテクストの
生成処理を説明する。図11はこの動作を示す処理フロ
ー図である。ここでは、画素Dは図4のレジスタR3の
ビット18〜39の範囲とし、そのビット位置をbnと
表わす。処理1101〜1106は図8の処理501〜
506と同じである。処理1107でbnの値を判定
し、処理1108、処理1109でb3(D画素の位
置)を書き換えることによって、画素Dを一定範囲に移
動した場合も効率的にコンテクストを生成することがで
きる。
Although the above embodiment is based on the reference pixel arrangement shown in FIG. 13, in an image having a high periodicity such as a dither image or a halftone dot image, the encoding performance can be improved by changing the arrangement of the reference pixels. . Here, the process of generating the context when the pixel D is moved to the encoded pixel on the Y line will be described. FIG. 11 is a processing flow chart showing this operation. Here, the pixel D is in the range of bits 18 to 39 of the register R3 in FIG. 4, and its bit position is represented by bn. Processing 1101 to 1106 are processing 501 to FIG.
Same as 506. By determining the value of bn in processing 1107 and rewriting b3 (position of D pixel) in processing 1108 and processing 1109, it is possible to efficiently generate the context even when the pixel D is moved within a certain range.

【0020】以上の処理は、シフト操作が複数のレジス
タを連結してシフトできる構造を有すれば、画像データ
のワード幅と同じサイズのレジスタやALUを使用して
も同様に実行可能である。また、符号化方式も算術符号
に限定されるものではなく、符号化処理が上記のの数式
のように、コンテクストSnに依存する場合には適用で
きる.
If the shift operation has a structure capable of shifting by connecting a plurality of registers, the above processing can be similarly executed by using a register or ALU having the same size as the word width of the image data. Also, the encoding method is not limited to the arithmetic code, and can be applied when the encoding process depends on the context Sn as in the above formula.

【0021】[0021]

【発明の効果】以上の説明から分かるように,本発明は
コンテクストの生成のために専用の回路を必要とせず、
汎用的な算術論理演算回路(ALU)を用いてコンテク
ストを効率的に生成できるという効果を有するものであ
る。その結果、必要な条件を満たすMPU(Micro
Processing Unit)やDSP(Dig
ital Signal Processor)によっ
て、コンテクスト生成処理を高速に実行可能である。ま
た専用LSI等で符号化装置を実現する際も、他の処理
にも共通使用するALUで効率的に実行できるので回路
規模が小さくなるという効果も有する。
As can be seen from the above description, the present invention does not require a dedicated circuit for generating a context,
This has an effect that a context can be efficiently generated by using a general-purpose arithmetic logic operation circuit (ALU). As a result, MPU (Micro
Processing Unit) and DSP (Dig)
The context signal generation processing can be executed at high speed by using the ital Signal Processor. Further, even when the encoding device is implemented by a dedicated LSI or the like, it can be efficiently executed by an ALU commonly used for other processing, and thus there is an effect that the circuit scale is reduced.

【図面の簡単な説明】[Brief description of drawings]

【図1】本発明の符号化装置におけるコンテクストを生
成する処理を実行する回路のブロック構成図
FIG. 1 is a block configuration diagram of a circuit that executes a process of generating a context in an encoding device of the present invention.

【図2】図1で示したレジスタ4の詳細な構成を示す図FIG. 2 is a diagram showing a detailed configuration of a register 4 shown in FIG.

【図3】図1で示したデータRAM3の内部構成を示し
た図
FIG. 3 is a diagram showing an internal configuration of a data RAM 3 shown in FIG.

【図4】本発明におけるレジスタの使用方法を示した図FIG. 4 is a diagram showing a method of using a register in the present invention.

【図5】本発明における1ラインの符号化処理の動作を
示すフロー図
FIG. 5 is a flow chart showing the operation of one-line encoding processing according to the present invention.

【図6】図5で示すフロー図を実行した場合のライン終
端の状態を示す図
6 is a diagram showing a state of a line end when the flow chart shown in FIG. 5 is executed.

【図7】初期状態での各レジスタの格納状態を示す図FIG. 7 is a diagram showing a storage state of each register in an initial state.

【図8】本発明におけるコンテクスト生成の第1の実施
例を示すフロー図
FIG. 8 is a flowchart showing a first embodiment of context generation in the present invention.

【図9】図8のフロー図を実行した場合のレジスタの遷
移状態を示す図
9 is a diagram showing transition states of registers when the flow chart of FIG. 8 is executed.

【図10】本発明におけるコンテクスト生成の第2の実
施例を示すフロー図
FIG. 10 is a flowchart showing a second embodiment of context generation in the present invention.

【図11】本発明におけるコンテクスト生成の第3の実
施例を示すフロー図
FIG. 11 is a flowchart showing a third embodiment of context generation in the present invention.

【図12】算術符号を用いた2値画像マルコフモデル符
号器の概略構成図
FIG. 12 is a schematic configuration diagram of a binary image Markov model encoder using arithmetic codes.

【図13】符号化シンボルとマルコフモデルを構築する
参照画素の配置例を示した図
FIG. 13 is a diagram showing an arrangement example of reference pixels for constructing a coded symbol and a Markov model.

【図14】従来の符号化装置におけるコンテクトを生成
するための専用ハードウェアブロック図
FIG. 14 is a block diagram of dedicated hardware for generating a protect in a conventional encoding device.

【図15】従来の符号化装置においてプログラム処理に
よりコンテクトを生成する場合のメモリの内部を示す図
FIG. 15 is a diagram showing the inside of a memory when a protect is generated by program processing in a conventional encoding device.

【図16】従来の符号化装置においてプログラム処理に
よりコンテクトを生成する場合のフロー図
FIG. 16 is a flowchart of a case in which a context is generated by program processing in a conventional encoding device.

【符号の説明】[Explanation of symbols]

1 ALU 2 シフタ 3 データRAM 4 レジスタバンク 5 アドレス制御部 6 アドレス制御部 7 マイクロプログラム制御部 1 ALU 2 shifter 3 data RAM 4 register bank 5 address control unit 6 address control unit 7 micro program control unit

───────────────────────────────────────────────────── フロントページの続き (51)Int.Cl.6 識別記号 庁内整理番号 FI 技術表示箇所 H04N 1/41 B ─────────────────────────────────────────────────── ─── Continuation of the front page (51) Int.Cl. 6 Identification code Office reference number FI technical display location H04N 1/41 B

Claims (6)

【特許請求の範囲】[Claims] 【請求項1】 画像データを所定数ライン分格納するメ
モリと、このメモリのワード幅の少なくとも2倍+所定
数ビット以上の容量を有し、前記メモリより画像データ
をワード単位で入力する複数のレジスタと、このレジス
タ内の画像データを左右にビット単位にシフト処理する
ことにより、符号化処理のための状態分離信号を生成す
るシフト手段とを具備したコンテクスト生成装置。
1. A memory for storing a predetermined number of lines of image data, and a plurality of memories each having a capacity of at least twice the word width of the memory + a predetermined number of bits or more, and inputting image data from the memory in word units. A context generation device comprising a register and shift means for generating a state separation signal for encoding processing by shifting image data in the register left and right in bit units.
【請求項2】 画像データを所定数ライン分格納するメ
モリと、このメモリのワード幅の少なくとも2倍+所定
数ビット以上の容量を有し、前記メモリより画像データ
をワード単位で入力する複数のレジスタと、このレジス
タ内の画像データを左右にビット単位にシフト処理する
ことにより、符号化処理のための状態分離信号を生成す
るシフト手段と、各ラインの初期処理時に前記レジスタ
をクリアするとともに前記メモリに格納された画像デー
タの最終ワードの次のデータをクリアする手段とを具備
したコンテクスト生成装置。
2. A memory for storing a predetermined number of lines of image data, and a plurality of memories each having a capacity of at least twice the word width of the memory + a predetermined number of bits or more, and inputting image data from the memory in word units. A register, shift means for generating a state separation signal for encoding processing by shifting the image data in the register right and left in bit units, and clearing the register at the time of initial processing of each line and A context generation device having means for clearing data next to the last word of the image data stored in the memory.
【請求項3】 画像データを所定数ライン分格納するメ
モリと、このメモリのワード幅の少なくとも2倍+所定
数ビット以上の容量を有し、前記メモリより画像データ
をワード単位で入力する複数のレジスタと、このレジス
タ内の画像データを左右にビット単位にシフト処理する
ことにより、符号化処理のための状態分離信号を生成す
るシフト手段と、参照画素配置を変更するに際して変更
前の配置で状態分離信号を生成し、配置を変更したビッ
トのみを書き換える書換手段とを具備したコンテクスト
生成装置。
3. A memory for storing a predetermined number of lines of image data, and a plurality of memories each having a capacity of at least twice the word width of this memory + a predetermined number of bits or more, and inputting image data from the memory in word units. A register, a shift means for generating a state separation signal for encoding processing by shifting the image data in the register right and left bit by bit, and a state before the change when the reference pixel arrangement is changed. A context generation device comprising a rewriting unit that generates a separation signal and rewrites only the bits whose arrangement has been changed.
【請求項4】 配置を変更した画素は符号化すべき画素
と同一のレジスタ上に存在させるようにしたことを特徴
とする請求項3記載のコンテクスト生成装置。
4. The context generation device according to claim 3, wherein the pixel whose arrangement has been changed is made to exist on the same register as the pixel to be coded.
【請求項5】 画像データを所定数ライン分格納するメ
モリと、このメモリのワード幅の容量を有するレジスタ
を複数個連結し、前記メモリより画像データをワード単
位で入力するレジスタ群と、このレジスタ群に含まれる
各レジスタ内の画像データを左右にビット単位にシフト
処理することにより、符号化処理のための状態分離信号
を生成するシフト手段とを具備したコンテクスト生成装
置。
5. A memory for storing a predetermined number of lines of image data, a plurality of registers having a word width capacity of the memory, and a register group for inputting the image data in word units from the memory, and the register. A context generation device comprising shift means for generating a state separation signal for encoding processing by shifting image data in each register included in the group to the left and right in bit units.
【請求項6】 画像データを所定数ライン分格納する第
1のメモリと、このメモリのワード幅の少なくとも2倍
+所定数ビット以上の容量を有し、前記メモリより画像
データをワード単位で入力する複数のレジスタと、この
レジスタ内の画像データを左右にビット単位にシフト処
理することにより、符号化処理のための状態分離信号を
生成するシフト手段と、前記各状態分離信号に応じて符
号化時における確率推定データを出力する手段と、前記
画像データの符号化データと前記確率推定データとを演
算することにより符号データを出力する演算手段とを具
備した符号化装置。
6. A first memory for storing a predetermined number of lines of image data, and a capacity of at least twice the word width of this memory + a predetermined number of bits or more, and the image data is input in word units from the memory. A plurality of registers, shift means for generating a state separation signal for encoding processing by shifting image data in the registers to the left and right in bit units, and encoding according to each state separation signal. An encoding device comprising: means for outputting probability estimation data at time; and operation means for outputting code data by calculating encoded data of the image data and the probability estimation data.
JP33574893A 1993-12-28 1993-12-28 Context generator and coder using the same Pending JPH07203453A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP33574893A JPH07203453A (en) 1993-12-28 1993-12-28 Context generator and coder using the same

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP33574893A JPH07203453A (en) 1993-12-28 1993-12-28 Context generator and coder using the same

Publications (1)

Publication Number Publication Date
JPH07203453A true JPH07203453A (en) 1995-08-04

Family

ID=18292029

Family Applications (1)

Application Number Title Priority Date Filing Date
JP33574893A Pending JPH07203453A (en) 1993-12-28 1993-12-28 Context generator and coder using the same

Country Status (1)

Country Link
JP (1) JPH07203453A (en)

Similar Documents

Publication Publication Date Title
US4675809A (en) Data processing system for floating point data having a variable length exponent part
US7191310B2 (en) Parallel processor and image processing apparatus adapted for nonlinear processing through selection via processor element numbers
JP2002171401A (en) Simd arithmetic unit provided with thinning arithmetic instruction
KR910000365B1 (en) Memory circuit
JP3459759B2 (en) Arithmetic decoding device
US6795062B1 (en) Screen driver with animation circuit
JPH07203453A (en) Context generator and coder using the same
JP3305406B2 (en) Program-controlled processor
JPH0951276A (en) Digital data processing unit
JP3261208B2 (en) Picture information prediction encoding and decoding apparatus
JP3255808B2 (en) Compression / expansion device
JP3270665B2 (en) Encoding / decoding apparatus and method
US6473530B2 (en) Encoding and decoding apparatuses and image processing apparatus using the same
JP2003198858A (en) Encoder and decoder
JP3461640B2 (en) Arithmetic encoding / decoding device
JP2770516B2 (en) Drawing method
JP3786329B2 (en) Encoding / decoding device
JPH04182751A (en) Picture memory read-out control circuit
JP3724868B2 (en) Image processing method
JP2595900B2 (en) Change point coordinate detection device for binary image data
JP3080937B2 (en) JBIG encoding method and recording medium recording JBIG program
US5550648A (en) System for filling outlines by addition and subtraction according to start and end positions of the outlines
JP2002171412A (en) Simd type information processing apparatus provided with x-branch tree instruction
JP3484900B2 (en) Image data encoding device
JPH05127980A (en) Picture processor

Legal Events

Date Code Title Description
A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20040413