JP2004266720A - Image compression device, image compression method, and image compression program - Google Patents

Image compression device, image compression method, and image compression program Download PDF

Info

Publication number
JP2004266720A
JP2004266720A JP2003057041A JP2003057041A JP2004266720A JP 2004266720 A JP2004266720 A JP 2004266720A JP 2003057041 A JP2003057041 A JP 2003057041A JP 2003057041 A JP2003057041 A JP 2003057041A JP 2004266720 A JP2004266720 A JP 2004266720A
Authority
JP
Japan
Prior art keywords
data
difference
block
output
evaluation result
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
JP2003057041A
Other languages
Japanese (ja)
Inventor
Hajime Sakano
肇 坂野
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.)
IHI Corp
Original Assignee
IHI Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by IHI Corp filed Critical IHI Corp
Priority to JP2003057041A priority Critical patent/JP2004266720A/en
Publication of JP2004266720A publication Critical patent/JP2004266720A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide an image compression device hardly causing distortion in inter-frame compression and capable of improving a compressibility. <P>SOLUTION: The image compressing device is equipped with a means of dividing the whole image in a frame into blocks of n×m pixels (n, m: natural numbers), a means of finding a difference quantity between data of a block and data of a block of a last frame, a means of outputting one of large, intermediate, and small difference evaluation results according to a result of comparison of the difference quantity with specified thresholds, a data selecting means of selecting and outputting block data divided as output data when the difference evaluation evaluation result shows a large difference, selecting and outputting difference data between the data of the block and the block data of the last frame when an intermediate difference, and outputting no data when a small difference, a means of reversibly encoding and outputting the data outputted by the data selecting means and the difference evaluation result, and a means of putting a new last frame together according to the difference evaluation result. <P>COPYRIGHT: (C)2004,JPO&NCIPI

Description

【0001】
【発明の属する技術分野】
本発明は、動画像の圧縮を行う画像圧縮装置、画像圧縮方法及び画像圧縮プログラムに関する。
【0002】
【従来の技術】
動画像のデータはデータ量が大きいため、圧縮せずに蓄積することはデータを利用する際の速度、蓄積効率のすべてにおいて性能の低下を引き起こす。このため画像データを蓄積、利用する際には高効率圧縮することが必須となっている。この高効率圧縮の方法として、画像を時間方向で独立に圧縮するMotionJPEGのような静止画圧縮を連続する方法とMPEGのように画像の時間方向の関連性を利用し冗長度をさらに減少させる圧縮方法が提案されている。この画像の時間方向の関連性を利用し冗長度をさらに減少させる画像圧縮方法は、さらなる高い圧縮率を実現することが必要とされている。
【0003】
画像の関連性を利用して圧縮する方法で動画のデータを生成する際には、単体で1フレームのデータを復元できるフレーム内圧縮と前後のフレームのデータを利用して1フレームのデータを復元できるフレーム間圧縮の2種類の圧縮を用いるのが一般的である。フレーム間圧縮は画面での前後の画素間だけでなく時間での冗長度の圧縮も行えるため圧縮率は高くなるが、時間的に前、もしくは後の画像がないと復元できない制約がある。このため動画圧縮においては、1フレームのフレーム内圧縮データと複数のフレーム間圧縮データを一組としてGOP(Group of Picture)を構成して圧縮データとする。このようなフレーム内圧縮とフレーム間圧縮を組み合わせた圧縮方法としてはMPEGが有名である。
【0004】
ここで、従来のフレーム間圧縮についてMPEG2を例にして説明する。MPEG2のフレーム間圧縮の動作を以下に示す。
(1)ビデオ信号をフレームメモリに読み込み、ブロックヘの切り出しを行う。
(2)ブロック毎に直前の時刻のフレームのデータを動き予測し、前後する時刻の対応する位置のデータ同士で差分を計算する。
(3)差分を離散コサイン変換(DCT)によって符号化する。
(4)DCT符号データを量子化し、サブバンド成分を低解像度レイヤに、高解像度成分を拡張レイヤに出力する。
(5)先に得られた予測した動きベクトルと、量子化後のデータについてエントロピー符号化、ランレングス符号化などの可逆符号化を行い出力データとする。
(6)(4)の出力を逆量子化、逆DCT変換を通して復元データをフレームメモリに保存し、次の時刻でのフレーム予測に用いる。
なお、MPEG1、MPEG2については、非特許文献1に記載されている。また、MPEGの改良に関する技術が特許文献1に記載されている。
【0005】
【特許文献1】
特開平4−177992号公報
【非特許文献1】
「Bit別冊:デジタル放送・インターネットのための情報圧縮技術」共立出版、1998年2月5日、p.128〜p.145,p.152〜p.177,p.205〜p.237
【0006】
【発明が解決しようとする課題】
従来技術のフレーム間圧縮では突然のシーンチェンジやそれまで見えていなかった物体が急に画面中に現れた場合、もしくは、画面から隠れた場合などにも最も似ている画面からの差分計算が行われる。この場合の処理でも最も近いデータを持つとはいえ、関連性がないデータ同士の処理になるために冗長性を減らすことに繋がらない。逆に差分を計算することで元画像に無い差し引く画像に含まれていた模様が加わり、残像のような部分を含んだ復元画像となる場合がある。シーンチェンジなどに限ると、補償画像の選択は2つの画像の平均値が近く差分、もしくは、差分の二乗和が少ないためおきやすい。
これに比べ圧縮対象データから対象の画素の平均であるDC成分を差し引いただけのデータ(時間方向の処理を行っていない)を圧縮する場合を考えると、シーンチェンジなどにおいては、符号化によるノイズが発生しくいデータとなる。
一方、差分計算無しの圧縮を常に用いると先に説明した無関係の画像データを差分することによる残像を発生させない。ところが、この方法では動き予測で正しく予想できる部分について動き予測補償によって減少していた冗長性を削減できなくなり、画像の大部分でのデータ量は増加することになる。
【0007】
本発明は、このような事情に鑑みてなされたもので、動画像データの関連性に応じて圧縮方法に切り替えることでフレーム間圧縮で歪が出にくく、圧縮率を向上させることができる画像圧縮装置、画像圧縮方法及び画像圧縮プログラムを提供することを目的とする。
【0008】
【課題を解決するための手段】
請求項1に記載の発明は、動画像データをフレーム間圧縮する画像圧縮装置であって、フレーム内の画像全体をn×m画素(n,mは自然数)のブロックに切り分けるブロック分割手段と、前記ブロックのデータと直前フレームのブロックデータとの差分量を求める差分算出手段と、前記差分量と所定の閾値とを比較した結果に基づき、差分大、差分中、差分小のいずれかの差分評価結果を出力する差分評価手段と、前記差分評価結果が差分大である場合には出力データとして前記ブロック分割手段によって切り出したブロックデータを選択して出力し、差分中である場合には前記ブロックのデータと直前フレームのブロックデータとの差分データを選択して出力し、差分小である場合にはデータを選択しないデータ選択手段と、前記データ選択手段が出力するデータと前記差分評価結果を可逆符号化して出力する可逆符号化手段と、前記差分評価結果に基づいて、新たな直前フレームを合成するデータ合成手段とを備えたことを特徴とする。
【0009】
請求項2に記載の発明は、前記画像圧縮装置は、データ選択手段の出力データをブロック符号化するブロック符号化手段と、前記ブロック符号化手段の出力データを量子化する量子化手段とをさらに備えたことを特徴とする。
【0010】
請求項3に記載の発明は、前記画像圧縮装置は、ブロック分割手段によって切り出したブロックのデータをブロック符号化するブロック符号化手段と、前記ブロック符号化手段の出力データを量子化する量子化手段とをさらに備えたことを特徴とする。
【0011】
請求項4に記載の発明は、動画像データをフレーム間圧縮する画像圧縮方法であって、フレーム内の画像全体をn×m画素(n,mは自然数)のブロックに切り分けるブロック分割過程と、前記ブロックのデータと直前フレームのブロックデータとの差分量を求める差分算出過程と、前記差分量と所定の閾値とを比較した結果に基づき、差分大、差分中、差分小のいずれかの差分評価結果を出力する差分評価過程と、前記差分評価結果が差分大である場合には出力データとして前記ブロック分割過程によって切り出したブロックデータを選択して出力し、差分中である場合には前記ブロックのデータと直前フレームのブロックデータとの差分データを選択して出力し、差分小である場合にはデータを選択しないデータ選択過程と、前記データ選択過程において出力したデータと前記差分評価結果を可逆符号化して出力する可逆符号化過程と、前記差分評価結果に基づいて、新たな直前フレームを合成するデータ合成過程とを有することを特徴とする。
【0012】
請求項5に記載の発明は、動画像データをフレーム間圧縮する画像圧縮プログラムであって、フレーム内の画像全体をn×m画素(n,mは自然数)のブロックに切り分けるブロック分割処理と、前記ブロックのデータと直前フレームのブロックデータとの差分量を求める差分算出処理と、前記差分量と所定の閾値とを比較した結果に基づき、差分大、差分中、差分小のいずれかの差分評価結果を出力する差分評価処理と、前記差分評価結果が差分大である場合には出力データとして前記ブロック分割処理によって切り出したブロックデータを選択して出力し、差分中である場合には前記ブロックのデータと直前フレームのブロックデータとの差分データを選択して出力し、差分小である場合にはデータを選択しないデータ選択処理と、前記データ選択処理において出力したデータと前記差分評価結果を可逆符号化して出力する可逆符号化処理と、前記差分評価結果に基づいて、新たな直前フレームを合成するデータ合成処理とをコンピュータに行わせることを特徴とする。
【0013】
【発明の実施の形態】
以下、本発明の一実施形態による画像圧縮装置を図面を参照して説明する。図1は同実施形態の構成を示すブロック図である。この図において、符号1は、ビデオ入力信号を標本化・量子化して1フレーム分の画像データを記憶するフレームメモリである。符号2は、画像データをn×m(n、mは自然数)画素のブロックを切り出すブロック切り出し部である。符号3は、直前のフレームとの差分の大きさを評価する差分評価部である。符号4は、差分評価部3の評価結果に応じて複数のデータの中から1つを選択するデータ選択部である。符号5は、直前のフレームを作成するためのデータを選択する合成用データ選択部である。符号6は、直前フレームを記憶するフレームメモリである。符号7は、動き補償予測を行う動き補償予測部である。符号8、9は、入力データを可逆符号化して出力する可逆符号化部である。可逆符号化部8、9から出力される符号化データを多重化することにより圧縮データを出力する多重化部である。符号11は、2つの画像データの差分を出力する差分出力部である。符号12は、2つの画像データを合成する合成部である。
【0014】
次に、図2を参照して、図1に示す画像圧縮装置のフレーム間圧縮による画像圧縮動作を説明する。
まず、ブロック切り出し部2は、フレームメモリ1からn×m画素のブロックデータを切り出す。ここで切り出したブロックデータは、動き補償予測部7へ出力する。これを受けて、動き補償予測部7は、フレームメモリ6に記憶されている直前のフレームの中から処理対象のブロックと最も近い画像データを持つブロックを1つ探し出し、このブロックデータを動き補償データとし、差分出力部11に対して出力する。最も近いデータの条件としてブロックの各地点で画素値の差分をとり、その絶対値和がもっとも少なくなる場所のブロックを1つ選び出す。また、動きがないと仮定して動きを計算するかわりに常に直前のフレームの同じ位置のブロックを選び出してもよい。
【0015】
次に、差分出力部11は、動き補償データとブロック切り出し部2において切り出したブロックデータの画素毎の差分(画素が持つ値の差分)を求める。そして、各画素の差分の絶対値を合計し、この合計値を差分量と称する。差分出力部11は、ここで求めた差分量を差分評価部3へ出力する。
【0016】
また、画素ブロックの差分量を切り出したブロックデータの画素毎の差分を求めた後、差分の分散を計算し差分量としてもよい。これは、画面が一様に明るくなった場合を考えた計算方法であり、画面が一様に明るくなった場合には、関連性が高いブロックの画素で差分を計算すると差分が0を中心ではなく、明るくなった分の値±誤差となる。このとき誤差を最小にするためには差分の絶対値和ではなく、差分の分散を最小にすることで達成する。これにより、光源の変動によっても圧縮率が低下しない応用範囲が広い圧縮方法にすることができる。
【0017】
これを受けて、差分評価部3は、差分量の評価を行う。差分評価部3は、差分量が閾値Th1を超えていれば関連性のある補償データが見つからなかったと判断し、差分評価の結果を「差分大」としてデータ選択部4へ通知する。また、差分量が閾値Th1を超えないが、閾値Th2(ただし、Th1>Th2>0)を超えている場合、直前のフレームと関連性のある変動があったと判断し、差分評価の結果を「差分中」としてデータ選択部4へ通知する。また、差分量がTh2を超えない場合、直前のフレームとブロック内部が変化していないと判断し、差分評価の結果を「差分小」とデータ選択部4へ通知する。
【0018】
次に、データ選択部4は、差分評価部3から通知された差分評価結果に基づいて、出力データを選択する。差分評価結果が「差分大」である場合、データ選択部4は、ブロック切り出し部2において切り出したブロックデータを選択して、このブロックデータをそのまま出力する。また、「差分中」である場合は、対象のブロックデータの各点の画素から動き補償データの各点の画素を減算したブロックデータ(差分出力部11の出力)を選択し、このブロックデータを出力する。また、「差分小」である場合は、ブロック無し情報に置き換えて出力する。
【0019】
次に、可逆符号化部9は、データ選択部4において選択されて出力されたデータを可逆符号化する。ここで用いる符号化方法は、エントロピー符号化のひとつであるハフマン符号化を行い出力する。
これと並行して、可逆符号化部8は、差分評価部3が出力する差分評価結果を識別可能な情報(例えば、差分大=1、差分中=2、差分小=3)をハフマン符号化を用いて可逆符号化する。
なお、エントロピー符号化として算術符号化、レンジコード法など、適した符号化を用いるようにしてもよい。
【0020】
次に、多重化部10は、2つの可逆符号化部8、9の出力を多重化して出力する。これが、1つのブロックデータを圧縮した圧縮データとなる。
【0021】
次に、合成部12は、データの再合成を行い、差分評価部3の出力に基づいて合成用データ選択部5は、データを選択して、フレームメモリ6へ出力する。すなわち、「差分大」の場合には、データ選択部4の出力のブロックを、差分中の場合には、データ選択部4の出力データに直前のフレームの値(動き補償後)を加算したブロックを、また差分小ならば直前のフレーム(動き補償後)のデータをフレームメモリ6へ出力する。
以上の処理を全てのブロックに対して実行することにより、画像の圧縮データが出力されることとなる。
【0022】
なお、前述した閾値Th1,Th2の2つの閾値を変更して、必要に応じて画質を上げて圧縮率を下げたり、圧縮率を下げて画質を上げたりする調整を行うようにしてもよい。
【0023】
次に、図2を参照して、他の実施形態を説明する。図2に示す装置が図1に示す装置と異なる点は、ブロック符号化13、量子化部14、ブロック復号化部15を新たに設け、データ選択部4の出力をに対して、ブロック符号化と量子化を行うようにした点である。データ選択部4の出力は−255〜255までとりうるため、0〜255に値を正規化する。ブロック符号化部13は、離散コサイン変換(もしくは、その他の直交変換)やBTC(Block Truncation Coding)、ベクトル量子化など、固定サイズの長方形画素の集まり(ブロック)から画像特有の特徴・成分を示す値を抽出して少ないデータとして表すための処理を行う。離散コサイン変換を用いた場合に出力される符号化データはn×m個の周波数成分(Qij)がDCT系列として出力され、また、全体の画素の平均がDC成分として出力する。また、量子化部14は、本来実数であるQijに乗算後に−128〜+127に収まる定数を求め乗算し、そのさいには絶対値が小さくなる切り捨てを行うなど一定の法則で整数化をおこなうとともに、ある条件下(たとえば2以下の値、ジグザクスキャンを行い一度でも0が見つかった後)であればさらに0に近似する処理を行う。ブロック復号化部15は、データを合成するために、ブロック符号化部13によって符号化されたブロックデータを復号化する。
【0024】
次に、図3を参照して、他の実施形態を説明する。図3に示す装置が、図2に示す装置と異なる点は、ブロック符号化13、量子化部14をブロック切り出し部2と差分出力部11の間に設けた点である。図3に示すブロック符号化13、量子化部14の動作は、図2に示すものと同様であるため詳細な説明を省略する。
【0025】
次に、図2、3に示すブロック符号化部13においてBTC(Block Truncation Coding)を用いる場合について説明する。BTCによる圧縮方法については特開昭60−87596号公報でRGB表現の場合について述べられており、さらに、特許第3260910号公報などでも利用法が記載されている。なお、カラーをBTC法でブロック符号化する場合RGBではなくYUV420を用いる。以下にBTCの処理を簡単に説明する。まず、ブロック中の全画素の平均を計算し平均階調値Mとする。続いて、ブロック中の各画素から平均値Mを減算し、それぞれを絶対値の平均Rを計算し階調振幅指標Rとする。そして、M以上の画素を階調番号1、M以下の画素を階調番号0としてn×m個の要素をもつベクトルとして階調番号の羅列を出力する。これにより符号化を行うことができる。
【0026】
次に、図3に示す装置において、ブロックデータのブロック符号化をBTC(Block Truncation Coding)を用い、さらに、差分量の計算方法について説明する。BTCの出力を平均色情報、平均からの起伏をしめす平均階調値、画素ごとにどの階調に属するかを示した量子化値(画素数分)とする。
差分量は、差分量=平均色情報の差×k1(平均色係数)+色階調指標の差×k2(階調値係数)+|量子化値の差|×(平均階調値の平均)によって算出する。ここで、|量子化値の差|は量子化値をn×m次元のベクトルと考え、2つのベクトルのユークリッド距離を計算した値とする。また、k1、k2は重み付け係数ですべての動画において同じ値を用いる。
【0027】
次に、図2,3に示すブロック符号化部13においてベクトル量子化を用いる方法について説明する。ベクトル量子化による圧縮については特開昭64−60059号公報に述べられている。また、動き補償を伴うベクトル量子化については特開昭60−146363号公報に示されている。ベクトル量子化をブロックの符号化に適用した場合の動作を簡単に説明する。
まず、ベクトル量子化の前にブロックの平均Ebおよび、平均からの最大振幅Rbを計算し、Eb,Rbを用いて(−128〜+128など)に平均からの変動を正規化する。そして、正規化した変動値のn×m画素のブロックについて、ブロックを構成する画素の値を要素としたベクトルに近い要素構成をもつベクトルをあらかじめ用意したベクトルテーブルから選び出し、そのベクトルのインデックス番号Ibと、Eb,Rbがブロックを量子化した結果となる。ベクトルを選ぶ際には、そのユークリッド距離が小さいものが近いベクトルとなるよう各要素の差分の二乗和を計算する。この動作によってベクトル量子化処理を行うことができる。
【0028】
次に、図3に示す装置において、ブロック符号化をベクトル量子化で行い、さらに、差分量の計算を行う動作を説明する。まず、ベクトル量子化の前にブロックの平均Ebおよび、平均からの最大振幅Rbを計算し、Eb,Rbを用いて、−128〜+128などに平均からの変動を正規化する。そして、正規化した変動について最も近い値をもつベクトルを探し、そのインデックス番号Ibと、Eb,Rbをブロックを量子化した結果とする。
差分量は、差分量=Ebの差 ×K1(平均色係数)+Rbの差 ×K2(振幅係数)+|Ibが示す2つベクトルの個々の要素の差|×Rbの平均 によって計算する。ここで、|…|はn×m次元での差の値を要素に持つベクトルと考え、2つのベクトルのユークリッド距離を計算した値とする。また、k1、k2は重み付け係数で動画中のすべて圧縮において一定の値を用いる。
【0029】
次に、図3に示す装置において、ブロック符号化に離散コサイン変換を用い、直交変換後の出力である直流成分DCおよび、変換後の要素Qijを用いて差分量計算を行う動作を説明する。
変化量は、変化量=DCの差分+Σ(|対象画像のQij−比較画像のQij|×Kij)によって求める。ここで、Kij(i<n,j<m)は重み付け係数で動画中のすべての圧縮において一定の値を用い、Kij≧Ki+1j,Kij≧Kij+1を満たすようにKを設計する。ここに、示した式は差分の重み付け和であり、その重みを人間の視覚が敏感に反応する低周波成分が大きくなるように重み付けする方法で人間の感覚に近い値になるようにすることで、さらに自然な復元画像を得ることができるようになる。
【0030】
なお、ブロックデータの符号化で生成する属性値(BTCでは平均階調値、階調振幅、量子化値(階調番号の羅列)に相当、また、DCTではDC成分とACの各周波数成分に対応するQijに相当)を別個に、もしくはその中で独立した属性ごとをグループにして差分をとり、それぞれの属性値ごとの差分によって評価を行い、さらに、その属性ごとに差分、元値、データ無しと選択するようにしてもよい。例えば、BTC法をブロック符号化に用いている場合、平均階調値と、階調振幅が独立であり、平均階調値が同じで階調振幅が大きく変化した場合、階調振幅および階調番号のベクトルを送信するだけで平均階調値は送信せず、復号時に以前と同じ値を用いることで、同じ画像を少ない情報伝送で再現可能とすることができる。これによると、例えば、背景の色が変化せずに模様が変化・変形した場合にデータ量が減少することになる。逆の平均階調値のみの変化する場合にも少ない情報伝送で再現可能とすることができる。これによると、例えば光源の変化で画面全体が均等に明るくなる場合にデータ量が減少することになる。このように、平均階調値と階調振幅といった独立した要素については別個に差分量の大中小を評価し、それぞれに対応して個々に元画像ブロックを用いた可逆符号化、差分値からなるブロックを用いた可逆符号化、データ無しとする事で必要なデータのみを送信することで従来よりデータ量を減少させ、圧縮率が向上する。
【0031】
このように、フレーム間圧縮において、フレームをブロックに分割し時間変化を検査し、ブロックの変化が大きい場合には時間方向のフレーム間関連を利用しない圧縮を、変化が小さい場合には前画面と同じという情報を、その中間ではフレーム間の関連を利用した圧縮したデータを送信するようにし、データの関連性に応じて圧縮方法に切り替えるようにしたため、フレーム間圧縮で歪が出にくく、圧縮率を向上させることが可能となる。
【0032】
なお、図1〜3における各処理部の機能を実現するためのプログラムをコンピュータ読み取り可能な記録媒体に記録して、この記録媒体に記録されたプログラムをコンピュータシステムに読み込ませ、実行することにより画像圧縮処理を行ってもよい。なお、ここでいう「コンピュータシステム」とは、OSや周辺機器等のハードウェアを含むものとする。また、「コンピュータシステム」は、ホームページ提供環境(あるいは表示環境)を備えたWWWシステムも含むものとする。また、「コンピュータ読み取り可能な記録媒体」とは、フレキシブルディスク、光磁気ディスク、ROM、CD−ROM等の可搬媒体、コンピュータシステムに内蔵されるハードディスク等の記憶装置のことをいう。さらに「コンピュータ読み取り可能な記録媒体」とは、インターネット等のネットワークや電話回線等の通信回線を介してプログラムが送信された場合のサーバやクライアントとなるコンピュータシステム内部の揮発性メモリ(RAM)のように、一定時間プログラムを保持しているものも含むものとする。
【0033】
また、上記プログラムは、このプログラムを記憶装置等に格納したコンピュータシステムから、伝送媒体を介して、あるいは、伝送媒体中の伝送波により他のコンピュータシステムに伝送されてもよい。ここで、プログラムを伝送する「伝送媒体」は、インターネット等のネットワーク(通信網)や電話回線等の通信回線(通信線)のように情報を伝送する機能を有する媒体のことをいう。また、上記プログラムは、前述した機能の一部を実現するためのものであっても良い。さらに、前述した機能をコンピュータシステムにすでに記録されているプログラムとの組み合わせで実現できるもの、いわゆる差分ファイル(差分プログラム)であっても良い。
【0034】
【発明の効果】
以上説明したように、この発明によれば、関連性が少ない場合に予測画像による補償を引くことなく元画像の符号化を行い、関連性が大きい場合に予測画像による補償を行うことを提案することで、高い圧縮率を維持しながら残像ノイズを減らすことができる。また、関連性を検査する方法として予測画像データと元画像データの差を用い、差が大きい場合には関連性がないと予想し、小さい場合には差が無いと予想し、それ以外の場合には関連性が大きいと予想する簡単な判定するようにしたため、必要度が高い順にデータ量を多くするような判断を高速に行うことができる。特に差分が所定の閾値より小さい場合には、変動はノイズやゆらぎであることが多く、またノイズやゆらぎに隠されて人間には判別できない変化となるため、差が無いと判断しデータを生成しないことにより常に差分データもしくはフレーム内圧縮データを送る方法に比べて送信データ量を減らすことが可能となる。また、画像のフレームデータをブロック化してブロック内で符号化、量子化を行う特徴をもった圧縮手法に適用可能であり、このブロック符号化方法として離散コサイン変換、BlockTruncationCoding、ベクトル量子化などが使用可能となる。
【図面の簡単な説明】
【図1】本発明の一実施形態の構成を示すブロック図である。
【図2】本発明の他の実施形態の構成を示すブロック図である。
【図3】本発明の他の実施形態の構成を示すブロック図である。
【符号の説明】
1、6・・・フレームメモリ
2・・・ブロック切り出し部
3・・・差分評価部
4・・・データ選択部
5・・・合成用データ選択部
7・・・動き補償予測部
8、9・・・可逆符号化部
10・・・多重化部
11・・・差分出力部
12・・・合成部
13・・・ブロック符号化部
14・・・量子化部
[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention relates to an image compression device for compressing a moving image, an image compression method, and an image compression program.
[0002]
[Prior art]
Since moving image data has a large data amount, storing it without compression causes a reduction in performance in all of the speed and storage efficiency when using data. Therefore, when storing and using image data, it is essential to perform high-efficiency compression. As a method of this high-efficiency compression, a method of continuously compressing still images such as Motion JPEG, which independently compresses images in the time direction, and a compression method of further reducing redundancy by utilizing the temporal relationship of images as in MPEG. A method has been proposed. An image compression method that further reduces redundancy by utilizing the temporal relevance of the image is required to achieve a higher compression ratio.
[0003]
When generating moving image data by a method of compressing using the relevance of images, one frame of data can be restored by itself, and one frame of data is restored using intra-frame compression and data from previous and subsequent frames. It is general to use two types of compression, namely possible inter-frame compression. The inter-frame compression can increase the compression ratio because the redundancy can be compressed not only between the preceding and succeeding pixels on the screen but also in time, but it cannot be restored unless there is a temporally previous or subsequent image. For this reason, in moving image compression, a GOP (Group of Picture) is formed as a set of compressed data in one frame and a plurality of inter-frame compressed data as a set. MPEG is famous as a compression method combining such intra-frame compression and inter-frame compression.
[0004]
Here, conventional inter-frame compression will be described using MPEG2 as an example. The operation of MPEG2 inter-frame compression will be described below.
(1) A video signal is read into a frame memory and cut out into blocks.
(2) For each block, motion prediction is performed on the data of the frame at the immediately preceding time, and the difference between the data at the corresponding positions at the preceding and following times is calculated.
(3) The difference is encoded by a discrete cosine transform (DCT).
(4) Quantize the DCT code data and output the subband component to the low resolution layer and the high resolution component to the enhancement layer.
(5) Lossless encoding such as entropy encoding and run-length encoding is performed on the predicted motion vector obtained earlier and the quantized data to obtain output data.
(6) The reconstructed data is stored in the frame memory through the inverse quantization and the inverse DCT transform of the output of (4), and is used for frame prediction at the next time.
Note that MPEG1 and MPEG2 are described in Non-Patent Document 1. Further, a technique relating to improvement of MPEG is described in Patent Document 1.
[0005]
[Patent Document 1]
Japanese Patent Application Laid-Open No. H4-177992 [Non-Patent Document 1]
"Bit Separate Volume: Information Compression Technology for Digital Broadcasting and the Internet," Kyoritsu Shuppan, February 5, 1998, p. 128 to p. 145, p. 152-p. 177, p. 205-p. 237
[0006]
[Problems to be solved by the invention]
In the conventional frame-to-frame compression, when a sudden scene change or an object that was not visible until now suddenly appears on the screen, or when it is hidden from the screen, the difference calculation from the screen that is most similar is performed. Is Even in this case, although the process has the closest data, the process is performed between unrelated data, which does not lead to a reduction in redundancy. Conversely, by calculating the difference, a pattern included in the subtracted image that is not in the original image is added, and the restored image may include a portion such as an afterimage. In the case of only a scene change or the like, selection of a compensation image is easy because the average value of the two images is close and the difference or the sum of squares of the difference is small.
On the other hand, when data in which only the DC component which is the average of the target pixel is subtracted from the data to be compressed (no processing in the time direction is performed) is considered, the noise caused by the encoding in a scene change or the like is considered. Is data that is unlikely to occur.
On the other hand, if the compression without the difference calculation is always used, an afterimage due to the difference between the irrelevant image data described above is not generated. However, in this method, the redundancy that has been reduced by the motion prediction compensation for the portion that can be correctly predicted by the motion prediction cannot be reduced, and the data amount in most of the image increases.
[0007]
The present invention has been made in view of such circumstances, and by switching to a compression method in accordance with the relevance of moving image data, distortion is less likely to occur in inter-frame compression and image compression can be improved. It is an object to provide an apparatus, an image compression method, and an image compression program.
[0008]
[Means for Solving the Problems]
The invention according to claim 1 is an image compression apparatus for compressing moving image data between frames, and a block dividing unit that divides an entire image in the frame into blocks of nxm pixels (n and m are natural numbers), A difference calculating means for calculating a difference between the data of the block and the block data of the immediately preceding frame; and a difference evaluation of any of a large difference, a medium difference, and a small difference based on a result of comparing the difference with a predetermined threshold value. A difference evaluation unit that outputs a result, and selects and outputs the block data cut out by the block dividing unit as output data when the difference evaluation result is a large difference, and outputs the block data when the difference is in the middle. Data selecting means for selecting and outputting difference data between the data and the block data of the immediately preceding frame, and selecting no data if the difference is small; A lossless encoding unit that losslessly encodes and outputs the data output by the selection unit and the difference evaluation result, and a data synthesis unit that synthesizes a new immediately preceding frame based on the difference evaluation result. I do.
[0009]
According to a second aspect of the present invention, in the image compression apparatus, the image compression apparatus further includes a block encoding unit that performs block encoding on output data of the data selection unit, and a quantization unit that quantizes output data of the block encoding unit. It is characterized by having.
[0010]
According to a third aspect of the present invention, in the image compression apparatus, a block encoding unit that performs block encoding on data of a block cut out by the block dividing unit, and a quantization unit that quantizes output data of the block encoding unit. And further comprising:
[0011]
According to a fourth aspect of the present invention, there is provided an image compression method for compressing moving image data between frames, wherein a whole image in the frame is divided into blocks of n × m pixels (n and m are natural numbers); A difference calculating step of calculating a difference amount between the block data and the block data of the immediately preceding frame; and a difference evaluation of any of a large difference, a medium difference, and a small difference based on a result of comparing the difference amount with a predetermined threshold value. A difference evaluation step of outputting a result, and selecting and outputting the block data cut out by the block division step as output data when the difference evaluation result is a large difference; A data selection step of selecting and outputting difference data between the data and the block data of the immediately preceding frame, and selecting no data if the difference is small; A lossless encoding step of losslessly encoding the data output in the selection step and the difference evaluation result and outputting the result, and a data synthesis step of synthesizing a new immediately preceding frame based on the difference evaluation result. .
[0012]
According to a fifth aspect of the present invention, there is provided an image compression program for compressing moving image data between frames, wherein the whole image in the frame is divided into blocks of n × m pixels (n and m are natural numbers); A difference calculation process for calculating a difference amount between the data of the block and the block data of the immediately preceding frame, and a difference evaluation of one of a large difference, a medium difference, and a small difference based on a result of comparing the difference amount with a predetermined threshold. A difference evaluation process for outputting a result, and selecting and outputting the block data cut out by the block division process as output data when the difference evaluation result is a large difference; Data selection processing for selecting and outputting difference data between the data and the block data of the immediately preceding frame, and selecting no data if the difference is small; The lossless encoding process that losslessly encodes the data output in the data selection process and the difference evaluation result and outputs the data, and the data synthesis process that synthesizes a new immediately preceding frame based on the difference evaluation result is performed by the computer. It is characterized by the following.
[0013]
BEST MODE FOR CARRYING OUT THE INVENTION
Hereinafter, an image compression apparatus according to an embodiment of the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing the configuration of the embodiment. In this figure, reference numeral 1 denotes a frame memory for sampling and quantizing a video input signal and storing one frame of image data. Reference numeral 2 denotes a block cutout unit that cuts out a block of image data of n × m (n and m are natural numbers) pixels. Reference numeral 3 denotes a difference evaluation unit that evaluates the magnitude of the difference from the immediately preceding frame. Reference numeral 4 denotes a data selection unit that selects one of a plurality of data according to the evaluation result of the difference evaluation unit 3. Reference numeral 5 denotes a combining data selection unit that selects data for creating the immediately preceding frame. Reference numeral 6 denotes a frame memory for storing the immediately preceding frame. Reference numeral 7 denotes a motion compensation prediction unit that performs motion compensation prediction. Reference numerals 8 and 9 are lossless encoding units that losslessly encode input data and output the encoded data. A multiplexing unit that outputs compressed data by multiplexing the encoded data output from the lossless encoding units 8 and 9. Reference numeral 11 denotes a difference output unit that outputs a difference between two image data. Reference numeral 12 denotes a combining unit that combines two pieces of image data.
[0014]
Next, an image compression operation by inter-frame compression of the image compression apparatus shown in FIG. 1 will be described with reference to FIG.
First, the block cutout unit 2 cuts out block data of n × m pixels from the frame memory 1. The block data cut out here is output to the motion compensation prediction unit 7. In response to this, the motion compensation prediction unit 7 searches the immediately preceding frame stored in the frame memory 6 for one block having image data closest to the block to be processed. And outputs the result to the difference output unit 11. As a condition of the closest data, a difference between pixel values at each point of the block is obtained, and one block at a place where the sum of absolute values is the smallest is selected. Alternatively, instead of calculating the motion assuming that there is no motion, a block at the same position in the immediately preceding frame may be always selected.
[0015]
Next, the difference output unit 11 obtains a difference (a difference between values of pixels) for each pixel between the motion compensation data and the block data cut out by the block cutout unit 2. Then, the absolute values of the differences of the pixels are summed, and this sum is referred to as a difference amount. The difference output unit 11 outputs the obtained difference amount to the difference evaluation unit 3.
[0016]
Alternatively, after calculating the difference for each pixel of the block data obtained by cutting out the difference amount of the pixel block, the variance of the difference may be calculated and used as the difference amount. This is a calculation method that considers the case where the screen is uniformly brightened. If the screen is uniformly brightened, when the difference is calculated with the pixels of the highly relevant block, the difference is centered around 0. And the error is the value ± error of the brightened portion. At this time, the error is minimized by minimizing the variance of the difference instead of the sum of the absolute values of the difference. This makes it possible to provide a compression method having a wide application range in which the compression ratio does not decrease even when the light source changes.
[0017]
In response, the difference evaluation unit 3 evaluates the difference amount. If the difference amount exceeds the threshold Th1, the difference evaluation unit 3 determines that no relevant compensation data has been found, and notifies the data selection unit 4 of the result of the difference evaluation as "large difference". When the difference amount does not exceed the threshold value Th1 but exceeds the threshold value Th2 (where Th1>Th2> 0), it is determined that there is a change relevant to the immediately preceding frame, and the result of the difference evaluation is set to “ Notifying the data selection unit 4 of "differential". If the difference amount does not exceed Th2, it is determined that the previous frame and the inside of the block have not changed, and the result of the difference evaluation is notified to the data selection unit 4 as "small difference".
[0018]
Next, the data selection unit 4 selects output data based on the difference evaluation result notified from the difference evaluation unit 3. When the difference evaluation result is “large difference”, the data selection unit 4 selects the block data cut out by the block cutout unit 2 and outputs the block data as it is. In the case of “difference in difference”, block data (output of the difference output unit 11) is selected by subtracting the pixel of each point of the motion compensation data from the pixel of each point of the target block data, and this block data is Output. If the difference is “small difference”, the information is replaced with the no-block information and output.
[0019]
Next, the lossless encoding unit 9 losslessly encodes the data selected and output by the data selection unit 4. The encoding method used here performs Huffman encoding, which is one of entropy encoding, and outputs the result.
In parallel with this, the lossless encoding unit 8 performs Huffman encoding of information (for example, large difference = 1, medium difference = 2, small difference = 3) which can identify the difference evaluation result output from the difference evaluation unit 3. Is used for lossless encoding.
Note that a suitable coding such as an arithmetic coding and a range code method may be used as the entropy coding.
[0020]
Next, the multiplexing unit 10 multiplexes and outputs the outputs of the two lossless encoding units 8 and 9. This is compressed data obtained by compressing one block data.
[0021]
Next, the synthesizing unit 12 re-synthesizes the data, and the synthesizing data selecting unit 5 selects the data based on the output of the difference evaluating unit 3 and outputs the selected data to the frame memory 6. That is, in the case of "large difference", the block of the output of the data selection unit 4 is added, and in the case of the difference, the block obtained by adding the value of the immediately preceding frame (after motion compensation) to the output data of the data selection unit 4 If the difference is small, the data of the immediately preceding frame (after motion compensation) is output to the frame memory 6.
By executing the above processing for all blocks, compressed data of an image is output.
[0022]
It should be noted that the two thresholds Th1 and Th2 described above may be changed, and adjustments may be made to increase the image quality to lower the compression ratio or lower the compression ratio to increase the image quality as needed.
[0023]
Next, another embodiment will be described with reference to FIG. The device shown in FIG. 2 is different from the device shown in FIG. 1 in that a block coding unit 13, a quantization unit 14, and a block decoding unit 15 are newly provided. That is, quantization is performed. Since the output of the data selection unit 4 can take from -255 to 255, the value is normalized to 0 to 255. The block encoding unit 13 shows features / components specific to an image from a set (block) of fixed-size rectangular pixels, such as discrete cosine transform (or other orthogonal transform), BTC (Block Truncation Coding), and vector quantization. A process for extracting a value and expressing it as a small amount of data is performed. As encoded data output when the discrete cosine transform is used, n × m frequency components (Qij) are output as a DCT sequence, and the average of all pixels is output as a DC component. In addition, the quantization unit 14 obtains and multiplies a constant that falls within the range of −128 to +127 after multiplying Qij which is originally a real number, and performs integer conversion according to a certain rule such as truncation to reduce the absolute value. Under a certain condition (for example, a value of 2 or less, after a zigzag scan is performed and 0 is found at least once), a process closer to 0 is further performed. The block decoding unit 15 decodes the block data encoded by the block encoding unit 13 to combine the data.
[0024]
Next, another embodiment will be described with reference to FIG. The device shown in FIG. 3 differs from the device shown in FIG. 2 in that a block coding unit 13 and a quantization unit 14 are provided between the block cutout unit 2 and the difference output unit 11. The operations of the block encoding unit 13 and the quantizing unit 14 shown in FIG. 3 are the same as those shown in FIG.
[0025]
Next, a case where BTC (Block Trunking Coding) is used in the block encoding unit 13 shown in FIGS. Japanese Patent Application Laid-Open No. 60-87596 describes a compression method using BTC in the case of RGB expression, and further describes a usage method in Japanese Patent No. 3260910. When color is block-coded by the BTC method, YUV420 is used instead of RGB. The BTC process will be briefly described below. First, the average of all the pixels in the block is calculated and set as an average gradation value M. Subsequently, the average value M is subtracted from each pixel in the block, and the average value R of each is calculated as a gradation amplitude index R. Pixels of M or more are represented by gradation number 1 and pixels of M or less are represented by gradation number 0, and a sequence of gradation numbers is output as a vector having n × m elements. Thus, encoding can be performed.
[0026]
Next, in the apparatus shown in FIG. 3, block coding of block data is performed using BTC (Block Trunking Coding), and a method of calculating a difference amount will be described. The output of the BTC is the average color information, the average gradation value indicating the undulation from the average, and the quantization value (for the number of pixels) indicating which gradation belongs to each pixel.
The difference amount is: difference amount = difference in average color information × k1 (average color coefficient) + difference in color tone index × k2 (tone value coefficient) + | difference in quantization value | × (average of average tone value ). Here, | difference in quantization value | is a value obtained by calculating the Euclidean distance between two vectors, considering the quantization value as an n × m-dimensional vector. Further, k1 and k2 are weighting coefficients, and the same value is used for all moving images.
[0027]
Next, a method of using vector quantization in the block encoding unit 13 shown in FIGS. Compression by vector quantization is described in JP-A-64-60059. Japanese Patent Application Laid-Open No. Sho 60-146363 discloses vector quantization with motion compensation. The operation when vector quantization is applied to block coding will be briefly described.
First, before the vector quantization, the average Eb of the block and the maximum amplitude Rb from the average are calculated, and the variation from the average is normalized to (eg, −128 to +128) using Eb and Rb. Then, for a block of n × m pixels of the normalized fluctuation value, a vector having an element configuration close to a vector having the values of the pixels constituting the block as elements is selected from a prepared vector table, and the index number Ib of the vector is selected. And Eb and Rb are the results of quantizing the block. When selecting a vector, the sum of squares of the differences between the elements is calculated so that the one with a smaller Euclidean distance becomes the closer vector. By this operation, a vector quantization process can be performed.
[0028]
Next, an operation of performing block encoding by vector quantization and calculating a difference amount in the apparatus illustrated in FIG. 3 will be described. First, before the vector quantization, the average Eb of the block and the maximum amplitude Rb from the average are calculated, and the variation from the average is normalized to -128 to +128 using Eb and Rb. Then, a vector having the closest value to the normalized variation is searched for, and its index number Ib, Eb, and Rb are taken as the result of quantizing the block.
The difference is calculated by the following equation: Difference = Eb difference × K1 (average color coefficient) + Rb difference × K2 (amplitude coefficient) + average of difference | × Rb of individual elements of two vectors indicated by Ib. Here, | ... | is assumed to be a vector having a difference value in the n × m dimension as an element, and a value obtained by calculating a Euclidean distance between the two vectors. Further, k1 and k2 are weighting coefficients, and constant values are used in all compression in the moving image.
[0029]
Next, the operation of the apparatus shown in FIG. 3 in which the discrete cosine transform is used for block coding and the difference amount calculation is performed using the DC component DC which is the output after the orthogonal transform and the element Qij after the transform is described.
The amount of change is obtained by the amount of change = DC difference + Σ (| Qij of target image−Qij of comparative image × Kij). Here, Kij (i <n, j <m) is a weighting coefficient, and a constant value is used in all compressions in the moving image, and K is designed to satisfy Kij ≧ Ki + 1j and Kij ≧ Kij + 1. The equation shown here is a weighted sum of the differences, and the weights are weighted so that the low-frequency components to which human vision reacts sensitively become large so that the values become close to human senses. Thus, a more natural restored image can be obtained.
[0030]
It should be noted that attribute values generated by encoding block data (corresponding to an average gradation value, gradation amplitude, and quantization value (sequence of gradation numbers) in BTC, and DC components and AC frequency components in DCT). Corresponding to the corresponding Qij), or each of the independent attributes is grouped to obtain a difference, and the difference is evaluated based on the difference for each attribute value. Furthermore, the difference, the original value, and the data are calculated for each attribute. You may make it select none. For example, when the BTC method is used for block coding, the average grayscale value and the grayscale amplitude are independent, and if the average grayscale value is the same and the grayscale amplitude changes greatly, the grayscale amplitude and grayscale By transmitting only the vector of the number and not transmitting the average gradation value, by using the same value as before at the time of decoding, the same image can be reproduced with less information transmission. According to this, for example, when the pattern changes or deforms without changing the background color, the data amount decreases. Even when only the reverse average gradation value changes, it can be reproduced with a small amount of information transmission. According to this, for example, when the entire screen becomes evenly bright due to a change in the light source, the data amount is reduced. As described above, for the independent elements such as the average gradation value and the gradation amplitude, the difference amount is separately evaluated for large, medium, and small, and the loss amount is composed of the lossless encoding using the original image block and the difference value respectively corresponding to each. By transmitting only necessary data by reversible coding using blocks and no data, the amount of data is reduced and the compression rate is improved.
[0031]
As described above, in inter-frame compression, a frame is divided into blocks, and a time change is inspected. In the middle of the same information, compressed data using the relationship between frames is transmitted in the middle, and the compression method is switched according to the relationship of data, so distortion is hardly generated by inter-frame compression and the compression ratio Can be improved.
[0032]
In addition, a program for realizing the function of each processing unit in FIGS. 1 to 3 is recorded on a computer-readable recording medium, and the program recorded on the recording medium is read and executed by a computer system. Compression processing may be performed. Here, the “computer system” includes an OS and hardware such as peripheral devices. The “computer system” also includes a WWW system provided with a homepage providing environment (or display environment). The “computer-readable recording medium” refers to a portable medium such as a flexible disk, a magneto-optical disk, a ROM, and a CD-ROM, and a storage device such as a hard disk built in a computer system. Further, the “computer-readable recording medium” refers to a volatile memory (RAM) inside a computer system serving as a server or a client when a program is transmitted through a network such as the Internet or a communication line such as a telephone line. In addition, programs that hold programs for a certain period of time are also included.
[0033]
Further, the above program may be transmitted from a computer system storing the program in a storage device or the like to another computer system via a transmission medium or by a transmission wave in the transmission medium. Here, the "transmission medium" for transmitting the program refers to a medium having a function of transmitting information, such as a network (communication network) such as the Internet or a communication line (communication line) such as a telephone line. Further, the program may be for realizing a part of the functions described above. Furthermore, what can implement | achieve the function mentioned above in combination with the program already recorded on the computer system, and what is called a difference file (difference program) may be sufficient.
[0034]
【The invention's effect】
As described above, according to the present invention, it is proposed to perform encoding of an original image without subtracting compensation by a predicted image when the relevance is small, and to perform compensation by a predicted image when the relevance is large. Thus, afterimage noise can be reduced while maintaining a high compression ratio. Also, as a method of checking the relevancy, the difference between the predicted image data and the original image data is used. Since the simple determination that the relevance is large is made, the determination that the data amount is increased in descending order of the necessity can be performed at high speed. In particular, when the difference is smaller than a predetermined threshold value, the fluctuation is often noise or fluctuation, and is a change that is hidden by the noise or fluctuation and cannot be discriminated by humans. Therefore, it is determined that there is no difference, and data is generated. By not doing so, it becomes possible to reduce the amount of transmission data as compared with the method of always sending differential data or compressed data within a frame. Also, the present invention can be applied to a compression method having a feature of dividing image frame data into blocks and performing encoding and quantization in blocks. As the block encoding method, discrete cosine transform, BlockTruncationCoding, vector quantization, or the like is used. It becomes possible.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a configuration of an embodiment of the present invention.
FIG. 2 is a block diagram showing a configuration of another embodiment of the present invention.
FIG. 3 is a block diagram showing a configuration of another embodiment of the present invention.
[Explanation of symbols]
1, 6 ... frame memory 2 ... block cutout unit 3 ... difference evaluation unit 4 ... data selection unit 5 ... synthesis data selection unit 7 ... motion compensation prediction unit 8, 9, ... ..Reversible encoding unit 10 Multiplexing unit 11 Difference output unit 12 Synthesizing unit 13 Block encoding unit 14 Quantizing unit

Claims (5)

動画像データをフレーム間圧縮する画像圧縮装置であって、
フレーム内の画像全体をn×m画素(n,mは自然数)のブロックに切り分けるブロック分割手段と、
前記ブロックのデータと直前フレームのブロックデータとの差分量を求める差分算出手段と、
前記差分量と所定の閾値とを比較した結果に基づき、差分大、差分中、差分小のいずれかの差分評価結果を出力する差分評価手段と、
前記差分評価結果が差分大である場合には出力データとして前記ブロック分割手段によって切り出したブロックデータを選択して出力し、差分中である場合には前記ブロックのデータと直前フレームのブロックデータとの差分データを選択して出力し、差分小である場合にはデータを選択しないデータ選択手段と、
前記データ選択手段が出力するデータと前記差分評価結果を可逆符号化して出力する可逆符号化手段と、
前記差分評価結果に基づいて、新たな直前フレームを合成するデータ合成手段と
を備えたことを特徴とする画像圧縮装置。
An image compression apparatus for compressing moving image data between frames, comprising:
Block dividing means for dividing the entire image in the frame into blocks of n × m pixels (n and m are natural numbers);
Difference calculation means for calculating the difference between the data of the block and the block data of the immediately preceding frame,
A difference evaluation unit that outputs a difference evaluation result of any of a large difference, a difference, and a small difference based on a result of comparing the difference amount and a predetermined threshold value;
When the difference evaluation result is a large difference, the block data cut out by the block dividing means is selected and output as output data, and when the difference is being calculated, the data of the block and the block data of the immediately preceding frame are compared. Data selection means for selecting and outputting the difference data and not selecting the data when the difference is small;
Lossless encoding means for outputting the data output by the data selection means and the difference evaluation result in a lossless manner,
An image compression device comprising: a data synthesizing unit that synthesizes a new immediately preceding frame based on the difference evaluation result.
前記画像圧縮装置は、データ選択手段の出力データをブロック符号化するブロック符号化手段と、
前記ブロック符号化手段の出力データを量子化する量子化手段と
をさらに備えたことを特徴とする請求項1に記載の画像圧縮装置。
The image compression device, block encoding means for block encoding the output data of the data selection means,
The image compression apparatus according to claim 1, further comprising a quantization unit that quantizes output data of the block encoding unit.
前記画像圧縮装置は、ブロック分割手段によって切り出したブロックのデータをブロック符号化するブロック符号化手段と、
前記ブロック符号化手段の出力データを量子化する量子化手段と
をさらに備えたことを特徴とする請求項1に記載の画像圧縮装置。
The image compression device, block encoding means for block encoding the data of the block cut out by the block dividing means,
The image compression apparatus according to claim 1, further comprising a quantization unit that quantizes output data of the block encoding unit.
動画像データをフレーム間圧縮する画像圧縮方法であって、
フレーム内の画像全体をn×m画素(n,mは自然数)のブロックに切り分けるブロック分割過程と、
前記ブロックのデータと直前フレームのブロックデータとの差分量を求める差分算出過程と、
前記差分量と所定の閾値とを比較した結果に基づき、差分大、差分中、差分小のいずれかの差分評価結果を出力する差分評価過程と、
前記差分評価結果が差分大である場合には出力データとして前記ブロック分割過程によって切り出したブロックデータを選択して出力し、差分中である場合には前記ブロックのデータと直前フレームのブロックデータとの差分データを選択して出力し、差分小である場合にはデータを選択しないデータ選択過程と、
前記データ選択過程において出力したデータと前記差分評価結果を可逆符号化して出力する可逆符号化過程と、
前記差分評価結果に基づいて、新たな直前フレームを合成するデータ合成過程と
を有することを特徴とする画像圧縮方法。
An image compression method for compressing moving image data between frames,
A block division process of dividing the entire image in the frame into blocks of n × m pixels (n and m are natural numbers);
A difference calculation step of calculating a difference amount between the data of the block and the block data of the immediately preceding frame,
A difference evaluation step of outputting a difference evaluation result of one of a large difference, a difference, and a small difference based on a result of comparing the difference amount with a predetermined threshold;
When the difference evaluation result is a large difference, the block data cut out by the block division process is selected and output as output data, and when the difference is in the middle, the data of the block is compared with the block data of the immediately preceding frame. A data selection step of selecting and outputting the difference data and not selecting the data when the difference is small;
A lossless encoding step of losslessly encoding and outputting the data and the difference evaluation result output in the data selection step,
A data synthesizing step of synthesizing a new immediately preceding frame based on the difference evaluation result.
動画像データをフレーム間圧縮する画像圧縮プログラムであって、
フレーム内の画像全体をn×m画素(n,mは自然数)のブロックに切り分けるブロック分割処理と、
前記ブロックのデータと直前フレームのブロックデータとの差分量を求める差分算出処理と、
前記差分量と所定の閾値とを比較した結果に基づき、差分大、差分中、差分小のいずれかの差分評価結果を出力する差分評価処理と、
前記差分評価結果が差分大である場合には出力データとして前記ブロック分割処理によって切り出したブロックデータを選択して出力し、差分中である場合には前記ブロックのデータと直前フレームのブロックデータとの差分データを選択して出力し、差分小である場合にはデータを選択しないデータ選択処理と、
前記データ選択処理において出力したデータと前記差分評価結果を可逆符号化して出力する可逆符号化処理と、
前記差分評価結果に基づいて、新たな直前フレームを合成するデータ合成処理と
をコンピュータに行わせることを特徴とする画像圧縮プログラム。
An image compression program for compressing moving image data between frames,
A block division process of dividing the entire image in the frame into blocks of nxm pixels (n and m are natural numbers);
A difference calculation process for calculating a difference amount between the data of the block and the block data of the immediately preceding frame;
Based on the result of comparing the amount of difference with a predetermined threshold, a difference evaluation process of outputting a difference evaluation result of any of a large difference, a difference, and a small difference,
When the difference evaluation result is a large difference, the block data cut out by the block division processing is selected and output as output data, and when the difference is being calculated, the data of the block and the block data of the immediately preceding frame are compared. A data selection process for selecting and outputting the difference data and not selecting the data when the difference is small;
A lossless encoding process in which the data output in the data selection process and the difference evaluation result are losslessly encoded and output,
An image compression program for causing a computer to perform a data synthesis process for synthesizing a new immediately preceding frame based on the difference evaluation result.
JP2003057041A 2003-03-04 2003-03-04 Image compression device, image compression method, and image compression program Pending JP2004266720A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003057041A JP2004266720A (en) 2003-03-04 2003-03-04 Image compression device, image compression method, and image compression program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003057041A JP2004266720A (en) 2003-03-04 2003-03-04 Image compression device, image compression method, and image compression program

Publications (1)

Publication Number Publication Date
JP2004266720A true JP2004266720A (en) 2004-09-24

Family

ID=33120557

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003057041A Pending JP2004266720A (en) 2003-03-04 2003-03-04 Image compression device, image compression method, and image compression program

Country Status (1)

Country Link
JP (1) JP2004266720A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011176811A (en) * 2010-02-25 2011-09-08 Internatl Business Mach Corp <Ibm> Method and apparatus for encoding surveillance video
CN105763855A (en) * 2016-04-22 2016-07-13 微景天下(北京)科技有限公司 Image transmission system and image transmission method

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011176811A (en) * 2010-02-25 2011-09-08 Internatl Business Mach Corp <Ibm> Method and apparatus for encoding surveillance video
US9426477B2 (en) 2010-02-25 2016-08-23 International Business Machines Corporation Method and apparatus for encoding surveillance video
CN105763855A (en) * 2016-04-22 2016-07-13 微景天下(北京)科技有限公司 Image transmission system and image transmission method
CN105763855B (en) * 2016-04-22 2018-12-07 微景天下(北京)科技有限公司 Image delivering system and image transfer method

Similar Documents

Publication Publication Date Title
JP4800571B2 (en) Apparatus and method for encoding digital images in a lossless manner
JP5957562B2 (en) Video encoding / decoding method and apparatus using large size transform unit
JP3888597B2 (en) Motion compensation coding apparatus and motion compensation coding / decoding method
KR100788220B1 (en) Quality based image compression
US7340103B2 (en) Adaptive entropy encoding/decoding for screen capture content
KR100763178B1 (en) Method for color space scalable video coding and decoding, and apparatus for the same
RU2720975C2 (en) Method of encoding and decoding images, an encoding and decoding device and corresponding computer programs
JP4102841B2 (en) Computer-implemented method for processing video images
US20060233250A1 (en) Method and apparatus for encoding and decoding video signals in intra-base-layer prediction mode by selectively applying intra-coding
JPWO2008084745A1 (en) Image coding apparatus and image decoding apparatus
US9077960B2 (en) Non-zero coefficient block pattern coding
JP2007503784A (en) Hybrid video compression method
JPH07288474A (en) Vector quantization coding/decoding device
JP3703299B2 (en) Video coding method, system and computer program product for optimizing picture center image quality
KR20100102386A (en) Method and apparatus for encoding/decoding image based on residual value static adaptive code table selection
KR100714695B1 (en) Method for performing rate control by picture dropping and picture composition, video encoder, and transcoder thereof
JPH05219385A (en) Picture compression expansion method and device
JP2013239923A (en) Color conversion apparatus, encoder and decoder and their program
JP3674158B2 (en) Image encoding method and image decoding apparatus
JP2003188733A (en) Encoding method and arrangement
JP4028900B2 (en) Moving picture coding apparatus and moving picture decoding apparatus
KR20160040930A (en) Method and apparatus for re-encoding an image
JP2004266720A (en) Image compression device, image compression method, and image compression program
JP2004135254A (en) Image processing unit
JPS63284974A (en) Picture compression system

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20060222

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20071106

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20071113

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080109

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20080129