JPH0548907A - Encoder - Google Patents

Encoder

Info

Publication number
JPH0548907A
JPH0548907A JP3230898A JP23089891A JPH0548907A JP H0548907 A JPH0548907 A JP H0548907A JP 3230898 A JP3230898 A JP 3230898A JP 23089891 A JP23089891 A JP 23089891A JP H0548907 A JPH0548907 A JP H0548907A
Authority
JP
Japan
Prior art keywords
value
pixel
prediction
encoded
encoding
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
JP3230898A
Other languages
Japanese (ja)
Inventor
Takeshi Sato
健 佐藤
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.)
Casio Computer Co Ltd
Original Assignee
Casio Computer 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 Casio Computer Co Ltd filed Critical Casio Computer Co Ltd
Priority to JP3230898A priority Critical patent/JPH0548907A/en
Publication of JPH0548907A publication Critical patent/JPH0548907A/en
Pending legal-status Critical Current

Links

Landscapes

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

Abstract

PURPOSE:To count the predicted value only by a combining circuit and to miniaturize a device by weighting and adding to the peripheral plural picture elements of the encoding object picture element and obtaining the predictive value of the encoding object picture element based on it. CONSTITUTION:Image data to be compressed are stored in an image data memory 32. The weight is respectively added to plural peripheral picture elements of the picture element to be encoded which is read from the device 32 by a picture element predictive value generator 33, the result is compared with a threshold, the predictive value is generated, and outputted to a predictive error counter 34. The device 34 outputs the predictive value error between the picture element value to be encoded which is received from the device 32 and the predictive value output from the device 33 to an entropy encoder 35, encodes it here, and successively stores it in an encoding memory 36. Here, the predictive error is predicted, the value is deviated to '0', and since as for the entropy encoding, the encoding deviated to the value to be encoded has the small number of the prepared codes, the image data can efficiently be more compressed.

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、画像データを画素レベ
ルで圧縮する画像データ圧縮処理等に用いられる符号化
装置に係り、詳細には小さな回路規模でデータ圧縮を行
うことが可能な符号化装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an encoding device used for image data compression processing for compressing image data at a pixel level, and more particularly to an encoding device capable of performing data compression with a small circuit scale. Regarding the device.

【0002】[0002]

【従来の技術】画像信号に含まれる冗長な信号成分を除
去することによって、原画像信号のデータ量を低減する
ための処理を画像の高能率符号化(hihg-efficiency co
ding)、あるいは単に画像符号化(picture coding)と
いう。また、この技術は、データ圧縮符号化、冗長度抑
圧符号化、ビットレート低減符号化(bit-rate reducti
on coding)などと呼ばれることもある。
2. Description of the Related Art A process for reducing the data amount of an original image signal by removing redundant signal components contained in the image signal is performed by a high efficiency coding (hihg-efficiency co-coding) of the image.
ding), or simply picture coding. In addition, this technique is based on data compression coding, redundancy suppression coding, and bit rate reduction coding.
on coding) and so on.

【0003】ファクシミリのように文書、図面など中間
調の信号成分を含まず、白黒2値のみでできているとみ
なせる画像を2値画像と呼んでいる。2値画像は一般に
大きな冗長性を有しており、情報源符号化の手法により
データ圧縮が可能である。2値画像の画質は、振幅方向
の量子化レベル数が2で十分なため、標本化密度によっ
て定まるとみてよい。
An image that does not include a halftone signal component such as a document or a drawing and can be regarded as being made up of only black and white binary data is called a binary image. Binary images generally have large redundancy, and data compression is possible by the method of information source coding. Since the number of quantization levels in the amplitude direction is two, the image quality of a binary image may be determined by the sampling density.

【0004】データ圧縮符号化のうちで重要なものは、
予測符号化(predictive coding)と変換符号化(trans
form coding)及び、ベクトル量子化(vector quantiza
tion)である。これらの2者、3者を組み合わせること
も多く(ハイブリッド符号化)、更に、上記の諸手法に
組み合わせてデータ圧縮効果を高める有力な手段とし
て、エントロピーコーディング(可変長符号化、ハフマ
ン符号化)がよく用いられる。
The most important data compression encoding is
Predictive coding and transcoding
form coding and vector quantiza
tion). Often, these two and three parties are combined (hybrid coding), and entropy coding (variable-length coding, Huffman coding) is a powerful means of increasing the data compression effect by combining the above methods. Often used.

【0005】冗長度を除去するためのエントロピー符号
化のうち、最も代表的なエントロピー符号化の一つは不
等長符号化であり、これは頻度に高い出力レベルには短
い符号を、出現頻度の低い出力レベルには長い符号をそ
れぞれ割り当てる。これによって符号出力の平均符号長
を短くできる。エントロピー符号化を行うことによっ
て、符号出力の発生速度は一定ではなくなる。一般の伝
送路は、一定速度で情報を伝送するようにできているの
で、不均一に発生した情報(符号)をそのまま伝送路に
送出することはできない。このため、一旦バッファ記憶
によって情報を平滑化してから信号として送出する。ま
た、バッファ記憶のオーバーフロー、アンダーフローを
防ぐために、バッファ記憶占有率を監視し、常に一定範
囲に収まるように冗長度除去符号化のパラメータを制御
する。
Among the entropy codings for removing redundancy, one of the most typical entropy codings is unequal length coding, which is a short code for a high output level and an appearance frequency. A long code is assigned to each low output level. As a result, the average code length of code output can be shortened. By performing entropy coding, the code generation rate is not constant. Since a general transmission line is designed to transmit information at a constant speed, it is not possible to send out information (codes) generated unevenly to the transmission line as it is. Therefore, the information is temporarily smoothed by the buffer storage and then transmitted as a signal. Further, in order to prevent the overflow and underflow of the buffer storage, the buffer storage occupancy rate is monitored, and the redundancy removal encoding parameter is controlled so that it is always within a certain range.

【0006】上記予測符号化は、符号器内のメモリに既
に符号化された過去の画素値を記憶しておき、これから
新たに入力される画素Xの予測値(X)を求める。その差
(予測誤差という)X−(X)を量子化し、その出力レベ
ルを適当な2進符号に変換して送出する。受信側におい
ても全く同様の計算によって、予測値(X)が再生できる
から、伝送されてきた符号から予測誤差を再生し、これ
を既に復号された直前の画像信号に加えて新たな画像信
号が復元できる。標本値間の相関が大きい信号に対して
は精度の高い予測が可能なため、予測値(X)が実際の信
号Xに近くなり、予測誤差は小さくなる。従って、信号
Xよりも少ない情報量で伝送が可能となり、高能率符号
化が実現できる。
In the predictive coding, the past pixel value which has already been coded is stored in the memory in the encoder, and the predicted value (X) of the pixel X newly input from this is calculated. The difference (referred to as prediction error) X- (X) is quantized, the output level thereof is converted into an appropriate binary code, and the binary code is transmitted. Since the prediction value (X) can be reproduced by the same calculation on the receiving side, the prediction error is reproduced from the transmitted code, and this is added to the previously decoded image signal, and a new image signal is added. Can be restored. Since a highly accurate prediction is possible for a signal having a large correlation between sample values, the predicted value (X) becomes close to the actual signal X, and the prediction error becomes small. Therefore, it is possible to transmit with a smaller amount of information than the signal X, and high efficiency coding can be realized.

【0007】図8は予測誤差を符号化することによって
画像データを画素レベルで圧縮する画像データ圧縮装置
11のブロック図である。図8において、画像データ圧
縮装置11は、圧縮すべき画像データを記憶する画像デ
ータ記憶装置12と、符号化しようとする画素(符号化
対象画素)の周辺数画素の値により予測値のアドレスを
指定するアドレス発生装置13と、アドレス発生装置1
3により指定されたアドレスに対応する値を基に予測値
表22(図10)から予測値(X)を出力する画素予測値
記憶装置14と、画像データ記憶装置12から出力され
た符号化しようとする画素と画素予測値記憶装置14か
らの予測値(X)出力とにより予測誤差を算出する予測誤
差算出装置15と、算出された予測誤差を符号化するこ
とによって画像データを圧縮するエントロピー符号化装
置16と、発生した符号を順次記憶する符号記憶装置1
7と、上記各装置の動作を制御する制御装置18とによ
り構成されている。
FIG. 8 is a block diagram of an image data compression apparatus 11 for compressing image data at a pixel level by encoding a prediction error. In FIG. 8, the image data compression apparatus 11 determines an address of a prediction value by an image data storage apparatus 12 that stores image data to be compressed and a value of several pixels around a pixel to be encoded (encoding target pixel). Address generator 13 to be designated and address generator 1
The pixel prediction value storage device 14 that outputs the prediction value (X) from the prediction value table 22 (FIG. 10) based on the value corresponding to the address designated by 3 and the encoding output from the image data storage device 12 And a prediction error calculation device 15 that calculates a prediction error based on the predicted value (X) output from the pixel prediction value storage device 14, and an entropy code that compresses the image data by encoding the calculated prediction error. And a code storage device 1 for sequentially storing generated codes.
7 and a control device 18 for controlling the operation of each of the above devices.

【0008】以上の構成において、アドレス発生装置1
3が符号化しようとする画素の周辺数画素の値により予
測値表22(図10)のアドレスを指定すると、画素予
測値記憶装置14は指定されたアドレスに対応する値を
予測値表を基に取出して予測値として予測誤差算出装置
15に出力する。予測誤差算出装置15は符号化しよう
とする画素と上記予測値出力との予測誤差を算出し、エ
ントロピー符号化装置16は算出された予測誤差を符号
化することによって画像データを圧縮していく。発生し
た符号は符号記憶装置17で順次記憶される。
In the above configuration, the address generator 1
3 specifies the address of the prediction value table 22 (FIG. 10) by the values of several pixels around the pixel to be encoded, the pixel prediction value storage device 14 determines the value corresponding to the specified address based on the prediction value table. And outputs it to the prediction error calculation device 15 as a prediction value. The prediction error calculation device 15 calculates a prediction error between the pixel to be coded and the predicted value output, and the entropy coding device 16 compresses the image data by coding the calculated prediction error. The generated codes are sequentially stored in the code storage device 17.

【0009】上記画像データ圧縮装置11において、2
値画像(例えば、ファクシミリ)について予測誤差を算
出するまでの動作は次のようなものである。図9は文書
等の画像データ21とその一部を拡大した予測値対象を
示す図である。この図に示すように、符号化時には画像
データ21の左上から右方向に走査を行って白黒(0か
1)2値のドットデータを得るものであるが、ある画素
Xのドットを符号化しようとした場合に原データを直接
符号化するのではなく、図9の拡大部に示すように画素
Xの左上、上及び右のa〜gの7つの画素の値(白黒の
値)からXの値を予測してその予測との誤差を求めるよ
うにする。すなわち、図9に示すように、画素予測値記
憶装置14内に、画素Xの左上方向のa〜gの周囲7画
素の値を基に予測値を統計的に記憶した予測値表(予測
符号表)22を作成しておき、上記a〜gの周囲7画素
の値によって予測値表22のアドレスを指定し、対応す
る予測値(X)を得る。上記予測値表22は、a〜gの画
素の値0000000から1111111までのすべて
の組合せに対応して0から1の予測値(X)を予め統計的
に求めて記憶しておくもので、例えば画像データ21を
走査して画素Xの周りに0(例えば、白)が多いときに
はこの符号化しようとするドットデータも白が多いと想
定されるので予測値(X)は0(白)とする。逆に、ベタ
塗りのようなときは1(例えば、黒)である確率は高い
と想定されるので予測値(X)は1(黒)とする。このよ
うにa〜gの画素の値に対応して最適な予測値(X)を予
め統計的に求めてROM等に記憶しておき、この予測値
(X)と画素Xを図11に示すEX−OR(排他的論理
和)回路23に入力してEX−OR論理をとり予測誤差
を算出する。EX−ORした結果、予測が正しければ
“0”、誤りの場合は“1”とする。予測が合っている
限りは“0”が多くなるから、この“0”が多いデータ
を符号化装置16に通して符号化すればこれは偏りが多
いデータであるからかなりの圧縮が期待できる。このよ
うにa〜gの画素の値による予測値(X)がXと一致して
いれば圧縮率が高くなる。
In the image data compression device 11, 2
The operation until the prediction error is calculated for the value image (for example, facsimile) is as follows. FIG. 9 is a diagram showing the image data 21 of a document or the like and a predicted value target obtained by enlarging a part thereof. As shown in this figure, at the time of encoding, black and white (0 or 1) binary dot data is obtained by scanning the image data 21 from the upper left to the right. In such a case, the original data is not directly encoded, but as shown in the enlarged part of FIG. Predict the value and find the error from the prediction. That is, as shown in FIG. 9, a prediction value table (prediction code) in which the prediction values are statistically stored in the pixel prediction value storage device 14 based on the values of seven pixels around a to g in the upper left direction of the pixel X. The table) 22 is created, and the address of the prediction value table 22 is designated by the values of the seven pixels around the above a to g to obtain the corresponding prediction value (X). The predicted value table 22 is for statistically previously calculating and storing predicted values (X) of 0 to 1 corresponding to all combinations of pixel values 0000000 to 1111111 of a to g. When the image data 21 is scanned and there are many 0s (for example, white) around the pixel X, it is assumed that the dot data to be encoded also has many whites, so the prediction value (X) is set to 0 (white). .. On the contrary, in the case of solid painting, the probability of being 1 (for example, black) is assumed to be high, so the prediction value (X) is set to 1 (black). Thus, the optimum predicted value (X) corresponding to the pixel values a to g is statistically obtained in advance and stored in the ROM or the like.
(X) and the pixel X are input to the EX-OR (exclusive OR) circuit 23 shown in FIG. 11 to take the EX-OR logic to calculate the prediction error. As a result of EX-OR, "0" is set if the prediction is correct, and "1" is set if the prediction is incorrect. As long as the prediction is correct, there will be many "0" s. If this data with many "0s" is passed through the encoding device 16 to be encoded, this is data with a large amount of bias, so considerable compression can be expected. In this way, if the predicted value (X) based on the pixel values of a to g matches X, the compression rate becomes high.

【0010】[0010]

【発明が解決しようとする課題】しかしながら、このよ
うな従来の画像データ圧縮装置にあっては、前記予測値
表に基づく予測値を予測値記憶装置に記憶しておく構成
であったため、予測値を求めるためには使用する周辺の
画素数に応じた容量の記憶装置(例えば、ROM,RA
M)が必要となり、そのために装置全体の回路規模が大
きくなってしまうという欠点があった。そこで本発明
は、予測値記憶装置及びそのアドレスを指定する装置を
不要にすることができ、小さな回路規模で精度良くデー
タの圧縮を行うことが可能な符号化装置を提供すること
を目的としている。
However, in such a conventional image data compression apparatus, the predicted value based on the predicted value table is stored in the predicted value storage device. In order to obtain the storage capacity, a storage device (eg, ROM, RA
M) is required, which causes a problem that the circuit scale of the entire device becomes large. Therefore, it is an object of the present invention to provide a coding device which can eliminate the need for a prediction value storage device and a device for designating its address, and can perform data compression with high accuracy on a small circuit scale. ..

【0011】[0011]

【課題を解決するための手段】本発明による符号化装置
は、上記目的達成のため、符号化対象のデータを供給す
るデータ供給手段と、符号化対象画素の周囲複数画素に
夫々所定の重み付けをして加算し、該加算結果に基づい
て符号化対象画素の予測値を発生する予測値発生手段
と、前記データ記憶手段から出力された符号化対象画素
と前記予測値発生手段により発生した予測値に基づいて
予測誤差を算出する予測誤差算出手段と、前記予測誤差
算出手段により算出された予測誤差を符号化する符号化
手段と、を備えている。前記予測値発生手段は、符号化
対象画素の周囲複数画素に夫々所定の重み付けをする重
み付け手段と、前記重付け手段により重み付けされた周
囲複数画素の値を加算する加算手段と、前記加算手段の
出力を所定値と比較して符号化対象画素の予測値を発生
する比較手段とにより構成されるものであってもよい。
In order to achieve the above object, an encoding apparatus according to the present invention provides a data supplying means for supplying data to be encoded and a plurality of pixels around a pixel to be encoded with predetermined weights. Then, the prediction value generating means for generating the prediction value of the encoding target pixel based on the addition result, the encoding target pixel output from the data storage means, and the prediction value generated by the prediction value generating means Prediction error calculating means for calculating a prediction error based on the above, and encoding means for encoding the prediction error calculated by the prediction error calculating means. The predictive value generating means includes a weighting means for weighting a plurality of surrounding pixels of the pixel to be coded with a predetermined weight, an adding means for adding the values of the surrounding plurality of pixels weighted by the weighting means, and an adding means It may be configured by a comparison unit that compares the output with a predetermined value and generates a prediction value of the pixel to be encoded.

【0012】[0012]

【作用】本発明の手段の作用は次の通りである。符号化
対象画素の周囲複数画素は予測値発生手段により夫々所
定の重み付けされた後加算され、加算結果と所定のしき
い値を用いて予測値が出力される。そして、データ供給
手段から供給された符号化対象画素と予測値発生手段か
ら出力された予測値に基づいて予測誤差算出手段により
予測誤差が算出される。符号化手段は、予測誤差算出手
段により算出された予測誤差を符号化する。従って、画
素の予測値を求めるときに記憶装置等の順序回路を使用
せず組合せ回路で行うことができるため、装置全体の規
模を小さくすることができる。
The operation of the means of the present invention is as follows. A plurality of pixels around the pixel to be coded are respectively weighted by the prediction value generating means and then added, and the prediction value is output using the addition result and a predetermined threshold value. Then, the prediction error is calculated by the prediction error calculation unit based on the encoding target pixel supplied from the data supply unit and the prediction value output from the prediction value generation unit. The encoding means encodes the prediction error calculated by the prediction error calculating means. Therefore, the predicted value of a pixel can be obtained by a combinational circuit without using a sequential circuit such as a storage device, so that the size of the entire device can be reduced.

【0013】[0013]

【実施例】以下、本発明を図面に基づいて説明する。第1実施例 図1〜図6は本発明に係る符号化装置の第1実施例を示
す図であり、画像データ圧縮装置に適用した例である。
この図において、画像データ圧縮装置31は圧縮すべき
データを記憶する画像データ記憶装置32と、符号化し
ようとする画素(符号化対象画素)の周辺数画素の値に
夫々重みを付けて加え合わせ、その結果から予測値を発
生する画素予測値発生装置33と、画像データ記憶装置
32から出力された符号化しようとする画素の値と画素
予測値発生装置33からの予測値出力とにより予測誤差
を算出する予測誤差算出装置34と、算出された予測誤
差を符号化することによって画像データを圧縮するエン
トロピー符号化装置35と、発生した符号を順次記憶す
る符号記憶装置36と、上記各装置の動作を制御する制
御装置37とにより構成されている。
DESCRIPTION OF THE PREFERRED EMBODIMENTS The present invention will be described below with reference to the drawings. First Embodiment FIGS. 1 to 6 are views showing a first embodiment of an encoding apparatus according to the present invention, which is an example applied to an image data compression apparatus.
In this figure, an image data compression device 31 adds an image data storage device 32 for storing data to be compressed and values of several pixels around a pixel to be encoded (encoding target pixel) by weighting them and adding them. , A prediction error due to the pixel prediction value generation device 33 that generates a prediction value from the result, the value of the pixel to be encoded output from the image data storage device 32, and the prediction value output from the pixel prediction value generation device 33. A prediction error calculation device 34, an entropy coding device 35 that compresses the image data by coding the calculated prediction error, a code storage device 36 that sequentially stores the generated codes, and The control device 37 controls the operation.

【0014】図2は画素予測値装置33の回路構成図で
ある。図2において、画素予測値発生装置33は、符号
化しようとする画素の周辺数画素(a1〜an-1の画素)
の値に夫々重み付けする重み係数Wk(但し、1≦K≦
n−1,またn=21)を所定ビット(mビット)で出
力する重み係数発生回路41〜44と、符号化しようと
する画素の周辺画素a1〜an-1及びこの周辺画素a1
n-1に対応した重み係数W1〜Wn-1が夫々入力され、
周辺画素a1〜an-1の値(0か1)mビットの重み係数
Wkの値を伝送するかしないかを制御するゲート回路4
5〜48と、ゲート回路45〜48のmビット(n−
1)入力を加算し、(m+l)ビット1出力として出力
する加算器49と、(m+l)ビット出力の予測値を決
定するための(m+l)ビットしきい値を発生するしき
い値発生回路50と、加算器49により加算された結果
をしきい値発生回路50からのしきい値と比較し、加算
結果がしきい値以上のとき予測値(X)=1を出力する比
較器51とにより構成されている。
FIG. 2 is a circuit diagram of the pixel prediction value device 33. In FIG. 2, the pixel prediction value generation device 33 includes several pixels around the pixel to be encoded (pixels a 1 to a n -1 )
Of the weighting coefficient Wk (where 1 ≦ K ≦
n−1, or n = 2 1 ) with predetermined bits (m bits) to output the weighting factor generation circuits 41 to 44, the peripheral pixels a 1 to a n−1 of the pixel to be encoded, and the peripheral pixel a. 1 ~
a n-1 weighting coefficient corresponding to W 1 ~W n-1 are respectively input,
A gate circuit 4 for controlling whether or not to transmit the value (0 or 1) m-bit weighting coefficient Wk of the peripheral pixels a 1 to a n-1.
5 to 48 and m bits (n- of gate circuits 45 to 48).
1) Adder 49 that adds inputs and outputs as (m + 1) bit 1 output, and threshold generation circuit 50 that generates (m + 1) bit threshold value for determining a predicted value of (m + 1) bit output And the comparator 51 which compares the result added by the adder 49 with the threshold value from the threshold value generation circuit 50 and outputs the predicted value (X) = 1 when the addition result is equal to or more than the threshold value. It is configured.

【0015】上記重み係数発生装置41〜44で発生す
る重み付け係数Wkは、符号化しようとする画素Xの周
辺画素a1〜an-1の値に夫々重付けするものであり、上
記周辺画素a1〜an-1が、例えばn=8とするとa1
7となり、前記図9の周囲7画素a〜gに相当する。
この場合、このa〜gの周囲7画素に夫々重み係数W1
〜W7を設定する(図3参照)。そして、重み係数W1
7による重み付けの方法として白黒2値画像の場合に
は、図3に示すように符号化しようとする画素Xに近い
周囲画素程相関が強いであろうと考える。この考え方に
従うと、a〜gの周囲7画素のうち画素Xに最も近いの
はc及びg画素であり、次いでb,d及びf画素、いち
ばん離れているのはa及びe画素であるからこの順に相
関が強いものとして図4に示すようにc及びg画素の重
み係数W3,W7を“4”に、b,d及びf画素の重み係
数W2,W4,W6を“2”に、a及びe画素の重み係数
1,W5を“1”に夫々設定する。
The weighting factors Wk generated by the weighting factor generators 41 to 44 are for weighting the values of the peripheral pixels a 1 to a n-1 of the pixel X to be encoded, respectively. If a 1 to a n−1 are, for example, n = 8, then a 1 to
next a 7, corresponding to around 7 pixels a~g of FIG 9.
In this case, the weighting factor W 1 is applied to each of the seven pixels surrounding a to g.
Set ~ W 7 (see Figure 3). Then, the weighting factor W 1 ~
In the case of a black-and-white binary image as a weighting method by W 7 , it is considered that the closer the surrounding pixels are to the pixel X to be encoded, as shown in FIG. 3, the stronger the correlation. According to this concept, the c and g pixels are closest to the pixel X among the seven pixels around a to g, the b, d and f pixels are next, and the a and e pixels are the farthest. As shown in FIG. 4, the weighting factors W 3 and W 7 of the c and g pixels are set to “4”, and the weighting factors W 2 , W 4 and W 6 of the b, d and f pixels are set to “2” as the correlations are strong in order. , The weighting factors W 1 and W 5 of the a and e pixels are set to “1”, respectively.

【0016】上記ゲート回路45〜48は、周辺画素a
1〜an-1に対応して設けられた(n−1)個のANDゲ
ート回路により構成され、上述した例ではa〜gの周囲
7画素の値(0か1)が1ビットで入力される。従っ
て、各画素a〜gの値によってmビットの重み係数W1
〜W7が加算器49に出力されるか否かが決まる。
The gate circuits 45 to 48 are provided for the peripheral pixels a.
It is composed of (n-1) AND gate circuits provided corresponding to 1 to an -1 , and in the above example, the value (0 or 1) of 7 pixels around a to g is input by 1 bit. To be done. Therefore, depending on the value of each pixel a to g, an m-bit weighting factor W 1
It is determined whether ~ W 7 is output to the adder 49.

【0017】上記加算器49は、重み付けが行われたm
ビットの入力を全て足し合わせ(m+l)ビット出力と
して出力する加算器である。上記しきい値発生回路50
は、(m+l)ビットの所定しきい値を発生する回路で
あり、上述した重み係数を用いる場合は、例えばしきい
値は“7”に設定される。上記比較器51は、加算器4
9の出力としきい値発生回路50の出力を比較するコン
パレータ等である。
The adder 49 is a weighted m
It is an adder that adds all bit inputs and outputs as (m + 1) bit output. The threshold value generating circuit 50
Is a circuit for generating a predetermined threshold value of (m + l) bits, and when the above weighting coefficient is used, the threshold value is set to “7”, for example. The comparator 51 is the adder 4
It is a comparator or the like for comparing the output of 9 and the output of the threshold generation circuit 50.

【0018】次に、本実施例の動作を説明する。全体動作 先ず、画像データ記憶装置32には、圧縮すべき画像デ
ータが蓄えられている。画素予測値発生装置33は画像
データ記憶装置32から読出した符号化しようとする画
素Xの周辺7画素a〜gの値にそれぞれ重みW1〜W7
付けて加え合わせ、その結果をしきい値と比較して予測
値(X)を発生し予測誤差算出装置34に出力する。
Next, the operation of this embodiment will be described. Overall Operation First, the image data storage device 32 stores image data to be compressed. The pixel prediction value generation device 33 adds the weights W 1 to W 7 to the values of the seven pixels a to g around the pixel X to be encoded read from the image data storage device 32 and adds them, and the result is thresholded. The predicted value (X) is generated by comparison with the value and output to the prediction error calculation device 34.

【0019】予測誤差算出装置34は画像データ記憶装
置32から受け取った符号化しようとする画素Xの値と
画素予測値発生装置33からの予測値(X)出力との予測
誤差をエントロピー符号化装置35に出力する。エント
ロピー符号化装置35は受け取った予測誤差を符号化
し、符号化記憶装置36はエントロピー符号化装置35
によって発生した符号を順次記憶していく。ここで、予
測誤差は予測が合って値が0の方に偏っており、また、
エントロピー符号化は符号化すべき値に偏りがある方が
発生符号が少ない、すなわち、効率が良いため画像デー
タがより圧縮させることになる。
The prediction error calculation device 34 calculates the prediction error between the value of the pixel X to be encoded received from the image data storage device 32 and the prediction value (X) output from the pixel prediction value generation device 33 as an entropy coding device. To 35. The entropy coding device 35 codes the received prediction error, and the coding storage device 36 codes the entropy coding device 35.
The codes generated by are sequentially stored. Here, the prediction error is biased toward the value of 0 because the prediction is correct, and
In entropy coding, when the values to be coded are biased, the number of generated codes is small, that is, the efficiency is high, and the image data is compressed more.

【0020】画素予測値発生装置33における予測値算出の動作 先ず、重み係数発生装置41〜44から重み付けの係数
1〜W7がmビットでゲート回路45〜48に出力され
る。ゲート回路45〜48はa〜gの値(0か1)によ
り重み係数W1〜W7の値を加算器49に伝えるか否かの
AND論理をとる。なお、前述したように図2において
n=8とした場合のa1〜a7が、図9におけるa〜gに
相当し、このa〜gの画素に対応して図3及び図4の重
み係数W1〜W7が設定されているものとする。
Prediction Value Calculation Operation in Pixel Prediction Value Generation Device 33 First, the weighting coefficient generation devices 41 to 44 output weighting coefficients W 1 to W 7 to the gate circuits 45 to 48 in m bits. The gate circuits 45 to 48 take AND logic as to whether or not to transmit the values of the weighting factors W 1 to W 7 to the adder 49 according to the values of a to g (0 or 1). As described above, a 1 to a 7 when n = 8 in FIG. 2 correspond to a to g in FIG. 9, and the weights in FIGS. 3 and 4 correspond to the pixels in a to g. shall coefficients W 1 to W-7 is set.

【0021】重み係数W1〜W7で重み付けされた画素a
〜gの値は加算器49に入力され、加算器49はこれら
の入力を全部加算して加算結果を比較器51に出力す
る。従って、例えばa〜gの周囲7画素の値が“0”の
ときは加算器49の値は“0”となり、また、c画素の
みが“1”で他の画素が“0”のときはc画素の重み係
数W3による“4”が加算器49から出力されることに
なる。
Pixels a weighted by weighting factors W 1 to W 7.
The values of ~ g are input to the adder 49, and the adder 49 adds all these inputs and outputs the addition result to the comparator 51. Therefore, for example, when the value of the seven pixels around a to g is "0", the value of the adder 49 becomes "0", and when only the c pixel has "1" and the other pixels have "0". “4” according to the weighting factor W 3 of the c pixel is output from the adder 49.

【0022】比較器51は加算器49の出力としきい値
発生回路50の出力を比較し、加算器49出力がしきい
値発生回路50の出力以上の場合には予測値(X)=1を
出力し、そうでない場合には(X)=0を出力する。すな
わち、図9の従来の方式と同様に画像データ21を左上
から右に走査を行い、a1〜an-1の値から加算器49に
より加算を行なうと数式1のようになる。
The comparator 51 compares the output of the adder 49 with the output of the threshold value generating circuit 50. When the output of the adder 49 is equal to or more than the output of the threshold value generating circuit 50, the predicted value (X) = 1. Otherwise, outputs (X) = 0. That is, similarly to the conventional method of FIG. 9, the image data 21 is scanned from the upper left to the right, and addition is performed by the adder 49 from the values of a 1 to a n−1 , and the result is as shown in Expression 1.

【0023】[0023]

【数1】 [Equation 1]

【0024】そして、比較器51により数式1で示され
る加算結果としきい値発生回路50のしきい値出力とを
比較して予測値(X)を出力する。この予測値(X)により
符号化しようとする画素の値Xに対する予測誤差が得ら
れ、これをエントロピー符号化装置36に入力して符号
化を行なう。
Then, the comparator 51 compares the addition result expressed by the equation 1 with the threshold value output of the threshold value generating circuit 50 and outputs the predicted value (X). A prediction error for the value X of the pixel to be coded is obtained from this prediction value (X), and this is input to the entropy coding device 36 for coding.

【0025】図5は符号化しようとする画素Xの周囲の
画素をa〜gの周囲7画素とし、このa〜gの画素に対
応する重みをWa=1,Wb=2,Wc=4,Wd=
2,We=1,Wf=2,Wg=4(図4参照)とし、
かつ、しきい値を“7”にしたときの予測値表の出力例
であり、図6はそのしきい値を“8”にしたときの予測
値表の出力例である。
In FIG. 5, the pixels around the pixel X to be encoded are 7 pixels around a to g, and the weights corresponding to the pixels a to g are Wa = 1, Wb = 2, Wc = 4. Wd =
2, We = 1, Wf = 2, Wg = 4 (see FIG. 4),
Further, it is an output example of the prediction value table when the threshold value is set to "7", and FIG. 6 is an output example of the prediction value table when the threshold value is set to "8".

【0026】図5及び図6に示した予測値表の出力例を
用いてデータ圧縮を行った結果、従来のROM等に記憶
した予測値表を用いた場合と同等以上の圧縮効果を得る
ことができた。
As a result of data compression using the output examples of the prediction value tables shown in FIGS. 5 and 6, a compression effect equal to or higher than that obtained when using the prediction value table stored in the conventional ROM or the like is obtained. I was able to.

【0027】以上説明したように、本実施例の画像デー
タ圧縮装置31は、圧縮すべきデータを記憶する画像デ
ータ記憶装置32と、符号化しようとする画素(符号化
対象画素)の周辺数画素の値に夫々重みを付けて加え合
わせ、その結果から予測値を発生する画素予測値発生装
置33と、画像データ記憶装置32から出力された符号
化しようとする画素の値と画素予測値発生装置33から
の予測値出力とにより予測誤差を算出する予測誤差算出
装置34と、算出された予測誤差を符号化することによ
って画像データを圧縮するエントロピー符号化装置35
とを設け、加算器49、比較器51等の組合せ回路によ
り予測値を発生させるようにしているので、従来予測値
を求めるために必要であった記憶装置(図8の画像予測
値記憶装置14)とその記憶装置のアドレスを指定する
装置(図8のアドレス発生装置13)を不要にすること
ができ、装置全体の規模を大幅に小さくすることができ
る。また、このように回路規模の小さな画像データ圧縮
装置が実現できることから本装置を組み込んだ機器の小
型化を図ることができる。
As described above, the image data compression device 31 of the present embodiment has the image data storage device 32 for storing the data to be compressed and several pixels around the pixel to be encoded (encoding target pixel). Of the pixel values and the pixel prediction value generating device 33 that generates a prediction value from the result, and the value of the pixel to be encoded output from the image data storage device 32 and the pixel prediction value generating device. A prediction error calculation device 34 that calculates a prediction error based on the prediction value output from 33, and an entropy coding device 35 that compresses the image data by coding the calculated prediction error.
Since the prediction value is generated by the combination circuit such as the adder 49 and the comparator 51, the storage device (image prediction value storage device 14 of FIG. ) And a device (address generating device 13 in FIG. 8) for designating an address of the storage device can be eliminated, and the scale of the entire device can be significantly reduced. Further, since the image data compression apparatus having a small circuit scale can be realized in this way, it is possible to reduce the size of a device incorporating the apparatus.

【0028】第2実施例 図7は符号化装置の第2実施例を示す図であり、第1実
施例と同様画像データ圧縮装置に適用した例である。本
実施例は前記画素予測値発生回路33の回路構成をより
簡略にしたものである。図2に示した第1実施例と同一
構成部材には同一符号を付して重複部分の説明を省略す
る。
Second Embodiment FIG. 7 is a diagram showing a second embodiment of the coding apparatus, which is an example applied to the image data compression apparatus as in the first embodiment. In this embodiment, the circuit configuration of the pixel prediction value generation circuit 33 is simplified. The same components as those of the first embodiment shown in FIG. 2 are designated by the same reference numerals, and the description of the overlapping portions will be omitted.

【0029】先ず、構成を説明する。図7は画素予測値
発生装置61の回路構成図である。第1実施例において
は、しきい値として(m+l)ビットの任意の値をとる
ことができるようにしているが、本画素予測値発生装置
61では、しきい値を2のべき乗(2m)と限定してし
まうことによって、図2に示すしきい値発生回路50と
比較器51をORゲート回路62を用いて加算器45出
力の上位ビットの論理和で置き換えることができる。図
7の画素予測値発生装置61はしきい値が2mであり、
予測値(X)が加算器49出力の上位(l+1)ビットの
論理和で置き換えられた例を示している。
First, the structure will be described. FIG. 7 is a circuit configuration diagram of the pixel prediction value generator 61. In the first embodiment, the threshold value can be any value of (m + 1) bits, but in the pixel prediction value generation device 61, the threshold value is a power of 2 (2 m ). By limiting the above, the threshold value generating circuit 50 and the comparator 51 shown in FIG. 2 can be replaced with the logical sum of the upper bits of the output of the adder 45 by using the OR gate circuit 62. The pixel prediction value generator 61 of FIG. 7 has a threshold value of 2 m ,
An example is shown in which the predicted value (X) is replaced with the logical sum of the upper (l + 1) bits of the output of the adder 49.

【0030】すなわち、第1実施例では加算器49の全
ビットを出力してしきい値発生回路50からのしきい値
としなければならなかったが、しきい値を2のべき(2
m)と限定すると、加算器49出力のしきい値より下位
のビットを全く気にすることがなくなり上位ビットだけ
で比較することができる。例えば、2mに限定されたし
きい値がm=3(すなわち、しきい値は23=8)とし
たとき、加算器49に入力される値が0〜7であるとす
ればこれは0000〜0111であるから2mビットよ
り上位のビットは全部0になって値が出力されない。す
なわち、出力が0〜7の場合は2m(=23)ビットまで
は加算器49から値が出ない。入力が8になると100
00となって加算器49の2mビットに値が出る。ま
た、入力が8以上のときは上位ビットの何れかに少なく
とも1が存在するのでORゲート回路51により加算器
46出力の論理和をとれば予測値(X)=1が出力される
ことになる。
That is, in the first embodiment, all the bits of the adder 49 had to be output and set as the threshold value from the threshold value generating circuit 50, but the threshold value should be 2 (2
If it is limited to m ), the bits lower than the threshold value of the output of the adder 49 will not be taken into consideration at all, and only the upper bits can be compared. For example, when the threshold value limited to 2 m is m = 3 (that is, the threshold value is 2 3 = 8), if the value input to the adder 49 is 0 to 7, this is Since it is 0000 to 0111, all the bits higher than 2 m bits are 0 and no value is output. That is, when the output is 0 to 7, no value is output from the adder 49 up to 2 m (= 2 3 ) bits. 100 when the input becomes 8
It becomes 00 and a value appears in the 2 m bit of the adder 49. Further, when the number of inputs is 8 or more, at least 1 exists in any of the upper bits, so that if the OR gate circuit 51 takes the logical sum of the outputs of the adder 46, the predicted value (X) = 1 is output. ..

【0031】また、m=3とした場合のしきい値は
“8”であるから前記図6の予測値表と同一の予測値表
となる。このように本実施例ではしきい値を2のべきに
限定することによってしきい値発生回路及び比較器を省
略することができ、回路規模を更に簡略化することがで
きる。
Since the threshold value when m = 3 is "8", the prediction value table is the same as the prediction value table shown in FIG. As described above, in this embodiment, the threshold value generation circuit and the comparator can be omitted by limiting the threshold value to a power of 2, and the circuit scale can be further simplified.

【0032】なお、上記各実施例では符号化装置を画像
データ圧縮装置に適用した例であるが、勿論これには限
定されず、予測値を使用するものであれば全ての装置に
適用可能であることは言うまでもない。
In each of the above embodiments, the encoding device is applied to the image data compression device, but of course the invention is not limited to this, and it can be applied to any device as long as it uses a predicted value. Needless to say.

【0033】また、上記符号化対象画素の周囲画素の取
出方法やその個数、及び重み係数の設定方法は前述した
実施例に限られるものではなく任意のものが使用可能で
ある。また、上記画像データ圧縮装置31,61や画素
予測値発生装置33,61等を構成する回路や部材の
数、種類などは前述した実施例に限られないことは言う
までもない。
Further, the extraction method of the surrounding pixels of the pixel to be encoded, the number thereof, and the setting method of the weighting coefficient are not limited to those in the above-mentioned embodiment, and any method can be used. Needless to say, the numbers and types of circuits and members forming the image data compression devices 31 and 61 and the pixel prediction value generation devices 33 and 61 are not limited to those in the above-described embodiments.

【0034】[0034]

【発明の効果】本発明によれば、符号化対象画素の周囲
複数画素に夫々所定の重み付けをして加算し、該加算結
果に基づいて符号化対象画素の予測値を求めるようにし
ているので、画素の予測値を、記憶装置を使用せずに組
合せ回路のみで算出することができ、装置全体の規模を
小さくすることができる。
According to the present invention, a plurality of pixels around the pixel to be coded are weighted with predetermined weights and added, and the predicted value of the pixel to be coded is obtained based on the addition result. The predicted value of the pixel can be calculated only by the combinational circuit without using the storage device, and the size of the entire device can be reduced.

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

【図1】符号化装置のブロック構成図である。FIG. 1 is a block configuration diagram of an encoding device.

【図2】符号化装置の画素予測値発生装置の回路構成図
である。
FIG. 2 is a circuit configuration diagram of a pixel prediction value generation device of the encoding device.

【図3】符号化装置の重み係数発生回路の重み係数の設
定方法を説明するための図である。
FIG. 3 is a diagram for explaining a method of setting a weight coefficient of a weight coefficient generation circuit of the encoding device.

【図4】符号化装置の重み係数発生回路の重み係数の設
定方法を説明するための図である。
FIG. 4 is a diagram for explaining a method of setting a weight coefficient of a weight coefficient generation circuit of the encoding device.

【図5】符号化装置の予測値の表の出力例である。FIG. 5 is an output example of a table of prediction values of the encoding device.

【図6】符号化装置の予測値の表の出力例である。FIG. 6 is an output example of a table of prediction values of the encoding device.

【図7】他の実施例の符号化装置の画素予測値発生装置
の回路構成図である。
FIG. 7 is a circuit configuration diagram of a pixel prediction value generation device of an encoding device according to another embodiment.

【図8】従来の画像データ圧縮装置のブロック構成図で
ある。
FIG. 8 is a block diagram of a conventional image data compression device.

【図9】従来の画像データ及び符号化対象画素の周囲画
素を示す図である。
FIG. 9 is a diagram showing conventional image data and pixels surrounding a pixel to be encoded.

【図10】従来の予測値表を示す図である。FIG. 10 is a diagram showing a conventional prediction value table.

【図11】従来の予測誤差算出装置の回路構成図であ
る。
FIG. 11 is a circuit configuration diagram of a conventional prediction error calculation device.

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

31 画像データ圧縮装置 32 画像データ記憶装置 33,61 画素予測値発生装置 34 予測誤差算出装置 35 エントロピー符号化装置 36 符号化記憶装置 37 制御装置 41〜44 重み係数発生回路 45〜48 ゲート回路 49 加算器 50 しきい値発生回路 51 比較器 62 ORゲート回路 31 image data compression device 32 image data storage device 33, 61 pixel prediction value generation device 34 prediction error calculation device 35 entropy coding device 36 coding storage device 37 control device 41-44 weighting coefficient generation circuit 45-48 gate circuit 49 addition 50 threshold generator 51 comparator 62 OR gate circuit

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】 符号化対象のデータを供給するためのデ
ータ供給手段と、 符号化対象画素の周囲複数画素に夫々所定の重み付けを
して加算し、該加算結果に基づいて符号化対象画素の予
測値を発生する予測値発生手段と、 前記データ供給手段から供給された符号化対象画素と前
記予測値発生手段により発生した予測値に基づいて予測
誤差を算出する予測誤差算出手段と、 前記予測誤差算出手段により算出された予測誤差を符号
化する符号化手段と、 を具備したことを特徴とする符号化装置。
1. A data supply unit for supplying data to be encoded, a plurality of pixels around a pixel to be encoded are weighted with predetermined weights, respectively, and added, and the pixel to be encoded is added based on the addition result. A prediction value generating means for generating a prediction value; a prediction error calculating means for calculating a prediction error based on the encoding target pixel supplied from the data supplying means and the prediction value generated by the prediction value generating means; An encoding device comprising: an encoding unit that encodes the prediction error calculated by the error calculating unit.
【請求項2】 前記予測値発生手段は、符号化対象画素
の周囲複数画素に夫々所定の重み付けをする重付け手段
と、 前記重付け手段により重み付けされた周囲複数画素の値
を加算する加算手段と、 前記加算手段の出力を所定値と比較して符号化対象画素
の予測値を発生する比較手段と、 を具備したことを特徴とする請求項1記載の符号化装
置。
2. The prediction value generating means adds weighting means for weighting a plurality of surrounding pixels of a pixel to be coded to a predetermined weight respectively, and adding means for adding the values of the plurality of surrounding pixels weighted by the weighting means. The encoding device according to claim 1, further comprising: a comparison unit configured to compare an output of the addition unit with a predetermined value to generate a prediction value of a pixel to be encoded.
JP3230898A 1991-08-19 1991-08-19 Encoder Pending JPH0548907A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3230898A JPH0548907A (en) 1991-08-19 1991-08-19 Encoder

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3230898A JPH0548907A (en) 1991-08-19 1991-08-19 Encoder

Publications (1)

Publication Number Publication Date
JPH0548907A true JPH0548907A (en) 1993-02-26

Family

ID=16915030

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3230898A Pending JPH0548907A (en) 1991-08-19 1991-08-19 Encoder

Country Status (1)

Country Link
JP (1) JPH0548907A (en)

Similar Documents

Publication Publication Date Title
US6310980B1 (en) Encoding apparatus and method and storage medium
EP0385654B1 (en) Highly efficient coding apparatus
EP0399487B1 (en) Transformation coding device
EP0734174A2 (en) A method for adaptively compressing residual digital image data in a DPCM compression system
EP0066697A1 (en) A method and system for compressing grey scale image data
US6912318B2 (en) Method and system for compressing motion image information
US6785422B2 (en) Image processing apparatus utilizing pixel values of peripheral pixels adjacent the subject pixel
US6631161B1 (en) Method and system for compressing motion image information
JPH0541860A (en) Picture compression coder
JPH08204971A (en) Image compression method using predictive coding and error diffusion
JPH0548907A (en) Encoder
US5737021A (en) Transform coefficient selection method and apparatus for a transform coding system
JP2000165873A (en) Compression method for moving picture information and its system
JP3985465B2 (en) Image encoding apparatus, image decoding apparatus, image encoding / decoding apparatus, and methods thereof
JP3127513B2 (en) Encoding device
US6347115B1 (en) Method and system for predictive coding of images treated with the Roberts Method
JP2785209B2 (en) Data transmission equipment
JP3709584B2 (en) Image signal processing apparatus and method
JP2570437B2 (en) Facsimile machine
JPH1155531A (en) Arithmetic coder
JPH01205670A (en) Picture signal encoding system
JP3397682B2 (en) Image coding device
Budge et al. An adaptive-search residual vector quantizer for airborne reconnaissance
JPH0654320A (en) Picture compression encoder
JP2001077700A (en) Picture compressing device and image expanding device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20071217

Year of fee payment: 8

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

Year of fee payment: 9

Free format text: PAYMENT UNTIL: 20081217

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

Free format text: PAYMENT UNTIL: 20091217

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20091217

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20101217

Year of fee payment: 11

LAPS Cancellation because of no payment of annual fees