JP3450357B2 - Image processing apparatus and method - Google Patents

Image processing apparatus and method

Info

Publication number
JP3450357B2
JP3450357B2 JP20388492A JP20388492A JP3450357B2 JP 3450357 B2 JP3450357 B2 JP 3450357B2 JP 20388492 A JP20388492 A JP 20388492A JP 20388492 A JP20388492 A JP 20388492A JP 3450357 B2 JP3450357 B2 JP 3450357B2
Authority
JP
Japan
Prior art keywords
image data
screen
code amount
image
quantization
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.)
Expired - Fee Related
Application number
JP20388492A
Other languages
Japanese (ja)
Other versions
JPH0654309A (en
Inventor
章 菅
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.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Canon Inc filed Critical Canon Inc
Priority to JP20388492A priority Critical patent/JP3450357B2/en
Publication of JPH0654309A publication Critical patent/JPH0654309A/en
Priority to US08/622,181 priority patent/US6222943B1/en
Application granted granted Critical
Publication of JP3450357B2 publication Critical patent/JP3450357B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、複数画面の画像データ
を例えばデジタル記録する画像記録装置及び画像処理装
置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an image recording apparatus and an image processing apparatus for digitally recording image data of a plurality of screens.

【0002】[0002]

【従来の技術】従来から複数画面の画像データを圧縮し
て記録媒体に記録する技術は知られている。
2. Description of the Related Art Conventionally, a technique for compressing image data of a plurality of screens and recording it on a recording medium has been known.

【0003】かかる技術の一例として、与えられる画像
データをJPEG方式と呼ばれる圧縮方式が知られてい
る。
As an example of such a technique, a compression method called JPEG method for known image data is known.

【0004】かかる圧縮方式を用いて与えられる複数の
画像データを固定長に圧縮するに際しては、1枚当たり
の符号量の割当をLとすると連写開始からn枚の画像を
連写終了するまで2パス方式の圧縮方式を繰り返し行う
ことによって各画像の符号量L1 〜Ln をそれぞれ符号
量L以下に抑える。
When compressing a plurality of image data given by using such a compression method to a fixed length, if the allocation of the code amount per image is L, from the start of continuous shooting to the end of continuous shooting of n images. The code amount L 1 to L n of each image is suppressed to the code amount L or less by repeatedly performing the 2-pass compression method.

【0005】[0005]

【発明が解決しようとしている課題】しかしながら上記
従来例では、連続記録時に撮影毎に2ステップの符号化
を行うためにデータ圧縮作業に時間がかかり、連続記録
スピードを上げる際の制約となっていた。
However, in the above-mentioned conventional example, the data compression work takes a long time because the two-step encoding is performed for each photographing at the time of continuous recording, which is a limitation when increasing the continuous recording speed. .

【0006】かかる点に鑑み、本発明においては連続記
録時に連続記録開始から終了までの総符号量を高速に所
定の符号量に抑えるようにすることによって、連続記録
のスピードの低下を防止しようとするものである。
In view of the above point, in the present invention, it is intended to prevent the speed of continuous recording from decreasing by suppressing the total code amount from the start to the end of continuous recording to a predetermined code amount at high speed during continuous recording. To do.

【0007】[0007]

【課題を解決するための手段】上述の目的を達成するた
め、本願発明にかかる画像処理装置は、一連のn(nは
4以上の自然数)画面の画像データを入力する入力手段
と、前記入力手段によって入力された画像データを量子
化する量子化手段と、前記量子化手段によって量子化さ
れた画像データを可変長符号化する符号化手段と、前記
量子化手段に使用される量子化ステップを画面単位に制
御する制御手段とを有し、前記制御手段は、前記n画面
において最終的に符号化する画面の画像データに対する
量子化ステップを、前記n画面分の画像データに対して
予め割り当てられた符号量から既に符号化されたn−1
画面分の画像データの符号量の和を差引いた符号量に基
づいて制御し、前記最終的に符号化する画面以外の画面
の画像データに対する量子化ステップを、符号化対象画
面の前画面の画像データを符号化した際の符号量に基づ
いて制御することを特徴とする。
In order to achieve the above object, an image processing apparatus according to the present invention comprises an input means for inputting a series of image data of n (n is a natural number of 4 or more) screens, and the input means. A quantizing means for quantizing the image data input by the means, a coding means for variable-length coding the image data quantized by the quantizing means, and a quantizing step used by the quantizing means. A control unit for controlling each screen, wherein the control unit is pre-assigned to the image data for the n screens a quantization step for the image data of the screens finally encoded in the n screens. N-1 already encoded from the code amount
Control based on the code amount obtained by subtracting the sum of the code amount of the image data for the screen, the quantization step for the image data of the screen other than the screen to be finally encoded, the image of the previous screen of the encoding target screen It is characterized in that the control is performed based on the code amount when the data is encoded.

【0008】上述の目的を達成するため、本願発明にか
かる画像処理方法は、一連のn(nは4以上の自然数)
画面の画像データを入力する入力工程と、前記入力され
た画像データを量子化する量子化工程と、前記量子化さ
れた画像データを可変長符号化する符号化工程と、前記
量子化工程で使用される量子化ステップを画面単位に制
御する制御工程とを有し、前記制御工程では、前記n画
面において最終的に符号化する画面の画像データに対す
る量子化ステップを、前記n画面分の画像データに対し
て予め割り当てられた符号量から既に符号化されたn−
1画面分の画像データの符号量の和を差引いた符号量に
基づいて制御し、前記最終的に符号化する画面以外の画
面の画像データに対する量子化ステップを、符号化対象
画面の前画面の画像データを符号化した際の符号量に基
づいて制御することを特徴とする。
In order to achieve the above-mentioned object, the image processing method according to the present invention has a series of n (n is a natural number of 4 or more).
An input step of inputting image data of a screen, a quantization step of quantizing the input image data, an encoding step of variable-length encoding the quantized image data, and a use in the quantization step And a control step of controlling the quantization step for each screen, wherein in the control step, the quantization step for the image data of the screen to be finally encoded in the n screens is performed by the image data for the n screens. Already encoded from the code amount previously assigned to
The quantization step for the image data of the screen other than the screen to be finally encoded is controlled based on the code amount obtained by subtracting the sum of the code amounts of the image data for one screen, and It is characterized in that the control is performed based on the code amount when the image data is encoded.

【0009】[0009]

【実施例】図3は、本発明の一実施例の電子スチルカメ
ラのブロック図であり、101はレンズ、102は絞
り、103はシャッター、104は画像を電気信号に変
換する固体撮像素子、105は固体撮像素子の出力をA
D変換するAD変換回路、106はAD変換された信号
を処理するために一時的にデータを蓄積するメモリであ
る。107はメモリ106から読み出した固体撮像素子
104の出力から輝度信号と色差信号を演算によって作
り出し演算結果を再びメモリ106に記憶する信号処理
回路である。108はメモリ106からの信号を8×8
のブロックに分割しブロック毎に8×8のDCT係数に
DCT変換(離散コサイン変換)しメモリ106に記憶
するDCT変換回路である。109はメモリ106から
読み出したDCT係数の符号量を圧縮するためにDCT
係数を量子化する量子化回路である。110はDCT係
数の量子化に用いる量子化係数を設定する量子化テーブ
ルである。111は量子化テーブルの各係数に係数をか
けることによって量子化のステップを調整するための量
子化ステップ調整回路である。112は量子化されたD
CT係数をブロック毎にジグザグ走査するジグザグ走査
回路である。113はDCT係数のDC成分のブロック
間の差分をとって更にデータ量を圧縮するためのDPC
M回路である。114はDPCM回路の出力をハフマン
符号化するハフマン符号化回路である。115はハフマ
ン符号化する際に参照するハフマンテーブルである。1
16はジグザグスキャンされたDCT係数のAC成分中
非ゼロ係数と非ゼロ係数の間隔すなわちゼロが続く長さ
をカウントするランレングス符号化回路である。117
は各ブロックに割り当てられた符号長を越えそうになっ
た時点で高次の係数を強制的にゼロにする打ち切り回路
である。118はゼロラン長とゼロに続く非ゼロ係数に
対してハフマン符号を割り付けるハフマン符号化回路で
ある。119はハフマン符号化回路が参照するハフマン
テーブルである。120は符号量を検出する符号量検出
回路である。121は圧縮符号化されたデータを記録す
るメモリカードである。符号量検出回路120によって
検出された符号量をもとにして目標符号量にするために
量子化ステップ調整回路111において量子化テーブル
の各係数にかける係数値と各ブロックに割り当てる符号
量を決定する。各ブロックの符号量が指定量を越えてし
まいそうな場合AC係数の高次の係数を強制的にゼロと
することで符号化を打ち切る。122はシステム全体の
動作を制御するシステム制御回路である。123は撮影
を開始するためのレリーズスイッチであり、124は連
写と単写モードを切り替えるモード切り替えスイッチで
ある。
FIG. 3 is a block diagram of an electronic still camera according to an embodiment of the present invention, in which 101 is a lens, 102 is a diaphragm, 103 is a shutter, 104 is a solid-state image sensor for converting an image into an electric signal, and 105. Is the output of the solid-state image sensor
An AD conversion circuit for D conversion, and 106 is a memory for temporarily storing data for processing the AD converted signal. Reference numeral 107 denotes a signal processing circuit that creates a luminance signal and a color difference signal by calculation from the output of the solid-state image sensor 104 read from the memory 106 and stores the calculation result in the memory 106 again. 108 indicates the signal from the memory 106 by 8 × 8
Is a DCT conversion circuit for dividing each block into DCT coefficients (discrete cosine transform) into 8 × 8 DCT coefficients and storing in the memory 106. 109 is a DCT for compressing the code amount of the DCT coefficient read from the memory 106.
This is a quantization circuit that quantizes the coefficients. Reference numeral 110 is a quantization table for setting the quantization coefficient used for the quantization of the DCT coefficient. Reference numeral 111 denotes a quantization step adjustment circuit for adjusting the quantization step by multiplying each coefficient of the quantization table. 112 is the quantized D
It is a zigzag scanning circuit that performs zigzag scanning of CT coefficients for each block. Reference numeral 113 is a DPC for further compressing the data amount by taking the difference between the blocks of the DC component of the DCT coefficient.
It is an M circuit. Reference numeral 114 denotes a Huffman coding circuit that performs Huffman coding on the output of the DPCM circuit. A Huffman table 115 is referred to when Huffman coding is performed. 1
Reference numeral 16 is a run length encoding circuit which counts the interval between the non-zero coefficient and the non-zero coefficient in the AC component of the zigzag-scanned DCT coefficient, that is, the length in which zero continues. 117
Is a truncation circuit that forcibly sets high-order coefficients to zero when the code length assigned to each block is about to be exceeded. A Huffman coding circuit 118 assigns a Huffman code to a zero run length and a non-zero coefficient following zero. A Huffman table 119 is referred to by the Huffman coding circuit. A code amount detection circuit 120 detects the code amount. Reference numeral 121 is a memory card for recording compression-encoded data. Based on the code amount detected by the code amount detection circuit 120, the quantization step adjustment circuit 111 determines the coefficient value to be multiplied by each coefficient of the quantization table and the code amount to be assigned to each block in order to obtain the target code amount. . When the code amount of each block is likely to exceed the specified amount, the coding is terminated by forcibly setting the high-order AC coefficient to zero. A system control circuit 122 controls the operation of the entire system. Reference numeral 123 is a release switch for starting shooting, and 124 is a mode switching switch for switching between continuous shooting and single shooting mode.

【0010】図4は1枚の画像を撮影する撮像シークエ
ンスを示した図である。時刻T0にレリーズ123がオ
ンされると時刻T0からT1の間に測光動作が行われ、
概ね適正シャッタースピードと絞り値が決定される。次
に時刻T1〜T2にシャッター103を開いて前露光を
行い時刻T2にシャッター103を閉じてから、露光電
荷の読み出しを行い、時刻T3からT4の間に実際の露
光電荷の情報を基にして最適露光量算出を行う。次に時
刻T4に再びシャッター103を開き、本露光を行う。
時刻T5からT6間に露光電荷読み出しAD変換回路1
05でAD変換を行いメモリ106に記憶する。T6か
らT7間でメモリ106から信号処理回路107に読み
出し、輝度信号(Y)、色差信号(R−Y)、色差信号
(B−Y)を生成する。次に時刻T7〜T8間にDCT
変換回路108においてDCT変換を行う。時刻T8か
らT9で後述するやり方で圧縮符号化を行う。圧縮され
た画像信号をT9からT10の間にメモリカード121
に記録する。
FIG. 4 is a diagram showing an imaging sequence for shooting one image. When the release 123 is turned on at time T0, the photometric operation is performed from time T0 to T1,
The appropriate shutter speed and aperture value are determined. Next, the shutter 103 is opened at time T1 to T2 to perform pre-exposure, the shutter 103 is closed at time T2, and then the exposure charge is read out. Based on the information on the actual exposure charge between times T3 and T4. The optimum exposure amount is calculated. Next, at time T4, the shutter 103 is opened again to perform main exposure.
Exposure charge reading AD conversion circuit 1 between times T5 and T6
In step 05, AD conversion is performed and the result is stored in the memory 106. Between T6 and T7, the signal is read from the memory 106 to the signal processing circuit 107 to generate a luminance signal (Y), a color difference signal (RY), and a color difference signal (BY). Next, DCT is executed between time T7 and T8.
The conversion circuit 108 performs DCT conversion. From time T8 to T9, compression encoding is performed by a method described later. The compressed image signal is output from the memory card 121 between T9 and T10.
To record.

【0011】圧縮時に行うDCT演算に先立って画像デ
ータは通常8×8画素のブロックに分割される。図8は
画像のブロック化を示した図である。図8の(a)のよ
うに画像は画面左上から順に8×8画素ずつのブロック
に分割されそれぞれのブロック毎の各画素は図8の
(b)のようにs00〜s77でインデックスされる。図9
は各ブロック毎のDCT係数を示す図である。図8の
(b)の8×8画素の信号に対して(1)式のDCT演
算を施すことによって図9の(a)のように8×8のD
CT係数S00〜S77が得られる。逆DCT演算は(2)
式で示される。
Prior to the DCT calculation performed at the time of compression, image data is usually divided into blocks of 8 × 8 pixels. FIG. 8 is a diagram showing how the image is divided into blocks. As shown in FIG. 8A, the image is divided into blocks of 8 × 8 pixels in order from the upper left of the screen, and each pixel in each block is indexed by s 00 to s 77 as shown in FIG. 8B. It Figure 9
FIG. 6 is a diagram showing DCT coefficients for each block. By applying the DCT operation of the equation (1) to the signal of 8 × 8 pixels in FIG. 8B, 8 × 8 D is obtained as shown in FIG.
The CT coefficients S 00 to S 77 are obtained. Inverse DCT operation is (2)
It is shown by the formula.

【0012】[0012]

【外1】 [Outer 1]

【0013】図9の(b)に示す量子化テーブルに示さ
れる係数Q00〜Q77に対して量子化ステップ補正係数F
をかけたQ’00〜Q’77で各インデックスに対応するD
CT係数を除算することによって量子化されたDCT係
数Sq00〜Sq77を得る。
For the coefficients Q 00 to Q 77 shown in the quantization table shown in FIG. 9B, the quantization step correction coefficient F
D corresponding to each index Q '00 ~Q' 77 multiplied by the
The quantized DCT coefficients Sq 00 to Sq 77 are obtained by dividing the CT coefficient.

【0014】量子化されたDCT係数を符号化する手法
について説明する図を図10に示す。量子化されたDC
T係数Sq00〜Sq77は図10の(a)に示される順序
でジグザグスキャンされる。このようにすることでブロ
ックの直流成分を示すSq00から空間周波数の低い方か
ら高くなる順にDCT係数が並べられる。このようにジ
グザグスキャンを行うと図10の(b)に示すように直
流成分を示すSq00すなわちDC係数と交流成分を示す
Sq01〜Sq77までのAC係数が並ぶことになる。一般
的な画像の性質として空間周波数の高いエネルギー成分
は小さくなること、また前述した量子化によって高周波
成分ではAC係数がゼロになることが多くなる。したが
ってジグザグスキャンされたAC係数の非ゼロ係数から
非ゼロ係数までのゼロのラン長とゼロに続く非ゼロ係数
のペアをハフマン符号化することによってAC係数のデ
ータ量の圧縮を行うことができる。一方、DC係数に関
しては隣接ブロックのDC係数との差分をとるDPCM
予測値をハフマン符号化することによってデータ量が圧
縮される。この際、符号量の大小は量子化の仕方できま
る。荒く量子化を行えばAC係数がゼロ成分が多くなり
データ量は少なくなるが画質も劣化する。
FIG. 10 is a diagram for explaining a method of coding the quantized DCT coefficient. Quantized DC
The T coefficients Sq 00 to Sq 77 are zigzag scanned in the order shown in FIG. By doing so, the DCT coefficients are arranged in the order of increasing spatial frequency from Sq 00 indicating the DC component of the block. When the zigzag scanning is performed in this way, Sq 00 indicating a DC component, that is, a DC coefficient and AC coefficients Sq 01 to Sq 77 indicating an AC component are arranged as shown in FIG. 10B. As a general characteristic of an image, an energy component having a high spatial frequency becomes small, and the above-described quantization often causes an AC coefficient to become zero in a high frequency component. Therefore, the data amount of the AC coefficient can be compressed by Huffman coding the pair of the zero run length from the non-zero coefficient to the non-zero coefficient of the zigzag scanned AC coefficient and the non-zero coefficient following the zero. On the other hand, regarding the DC coefficient, the DPCM that takes the difference from the DC coefficient of the adjacent block
The amount of data is compressed by Huffman coding the predicted value. At this time, the size of the code amount depends on the method of quantization. If the quantization is roughly performed, the AC coefficient has many zero components and the amount of data is small, but the image quality is deteriorated.

【0015】図5はスイッチ124が連写モードに設定
されたときに圧縮符号化を行う際の本発明の効果を示す
ための対比例のシークエンスを示した図である。DCT
を用いた符号化は基本的には可変長になる。しかしカー
ドに記録する枚数が一定になるよう何らかの固定長化の
工夫を施すのが一般的である。従来は2パス方式という
方法をとるのが通例であった。2パス方式のアルゴリズ
ムを図6、図7に示す。図6は2パス方式の第1ステッ
プを、図7は2パス方式の第2ステップを示している。
FIG. 5 is a diagram showing a proportional sequence for showing the effect of the present invention when performing compression coding when the switch 124 is set to the continuous shooting mode. DCT
The encoding using is basically variable length. However, it is general to devise some fixed length so that the number of recordings on the card is constant. Conventionally, it has been customary to use a method called a two-pass method. The two-pass algorithm is shown in FIGS. 6 and 7. FIG. 6 shows the first step of the two-pass method, and FIG. 7 shows the second step of the two-pass method.

【0016】図6及び図7に基づいて固定長化の手法に
ついて簡単に説明する。DCT演算を施して各ブロック
の画像データをDCT係数に変換しメモリに記憶するま
では符号化に先立って行われる。第1ステップではま
ず、量子化テーブルに対して量子化ステップ補正係数F
を仮設定することで量子化巾を設定する。次に量子化、
ジグザグスキャン、符号化を行う。次に各ブロックの符
号量を算出し、画像全体の符号量が目標とする符号量と
なるための第2ステップにおける量子化ステップ補正係
数Fを予測するとともに各ブロックに目標符号量を達成
するためのブロック毎最大符号量を割り当てることによ
って第1ステップが終了する。次に第2ステップにおい
ては、第1ステップにおいて設定された量子化ステップ
補正係数Fによって量子化巾を設定し量子化を行い、ジ
グザグスキャン、符号化を行うが、AC係数の符号化の
際、第1ステップで決められたブロック毎の割り当てを
越えそうになった時点でそのブロックのより高周波の高
周波成分の符号化を打ち切ることで符号量が設定符号量
を越えないようにすることで固定長化を行う。符号化さ
れたデータに復号時に必要な各種のマーカコードを付加
して第2ステップを終了する。
A method of fixing length will be briefly described with reference to FIGS. 6 and 7. It is performed before encoding until the image data of each block is converted into DCT coefficients by DCT calculation and stored in the memory. In the first step, the quantization step correction coefficient F is first compared with the quantization table.
The quantization width is set by temporarily setting. Next quantization,
Zigzag scanning and encoding are performed. Next, in order to achieve the target code amount for each block, the code amount of each block is calculated, and the quantization step correction coefficient F in the second step for making the code amount of the entire image the target code amount is predicted. The first step is completed by allocating the maximum code amount for each block. Next, in the second step, the quantization step is set by the quantization step correction coefficient F set in the first step, quantization is performed, zigzag scanning and encoding are performed, but when encoding the AC coefficient, When the allocation of each block determined in the first step is about to be exceeded, the coding amount of the higher-frequency component of the block is cut off so that the code amount does not exceed the set code amount. To convert. Various marker codes necessary for decoding are added to the encoded data, and the second step is completed.

【0017】上述した対比例の方法では2ステップによ
る符号化を行った後にデータ圧縮を行うのでデータ圧縮
に要する時間が大きくなるという問題が生じる。
In the above-described method of contrast, the data compression is performed after the two-step encoding, so that the time required for the data compression becomes long.

【0018】次に、本発明の一実施例における連写時の
符号化シークエンスについて図1を用いて説明する。図
2は1パス方式による符号化のフローチャートである。
Next, the coding sequence during continuous shooting in one embodiment of the present invention will be described with reference to FIG. FIG. 2 is a flowchart of encoding by the one-pass method.

【0019】以下、図1と図2を用いて本発明の実施例
の動作を説明する。モード切り替スイッチ124が連写
モードに設定された状態でレリーズスイッチ123がオ
ンされると連写が開始されるが、1枚目の画像は1パス
方式で符号化される。1パス方式の符号化は、図2に示
すような手順で行われる。すなわち、量子化ステップ補
正係数Fをあらかじめ所定の値に設定し(S101)量
子化(S103)、ジグザグスキャン(S105)、符
号化(S107〜S113)、マーカコードの付加(S
119)、符号量(S115)の算出を行う。連写の場
合の動作について図1を用いて説明する。この際、1枚
目の圧縮符号量が1枚当たりの割り当て符号量と一致し
ない可能性が高いので、カードには1枚目の画像は記録
せず、1枚当たりに割り当てられた画像の符号量をLと
するとLだけの空きスペースをカード上に残した状態
で、メモリ106に圧縮前の画像データを連写終了まで
一時的に記憶する。ただしメモリ106は画像2枚分の
容量を持っていることを前提とする。また、この1枚目
の画像圧縮過程において次の画像の量子化巾を決定す
る。連写の際は続く2枚の画像間では絵柄が大きく変わ
ることがないため、先に記録する画像を評価することに
よって次に撮影する画像の圧縮に対する量子化ステップ
をほぼ適正な値に決めることができる。1枚当たり割り
当てられた画像の符号量をLとすると連写開始1枚目の
画像はLと一致しない可能性が高いが2枚以降の画像の
符号量はほぼLに近づけることが可能となる。レリーズ
スイッチ213がオフされると連写が終了するが、連写
枚数をn、1枚当たりの割り当て符号量をL、2枚目の
画像の符号量をL2 、n枚目の画像の符号量をLn とす
ると、L1 が、連写枚数に1枚当たりの割当符号量の積
nLという符号量からL2 からLn までの符号量の和を
差し引いた符号量となるよう2パス方式によって圧縮符
号化する。
The operation of the embodiment of the present invention will be described below with reference to FIGS. 1 and 2. When the release switch 123 is turned on while the mode switching switch 124 is set to the continuous shooting mode, continuous shooting is started, but the first image is encoded by the 1-pass method. The one-pass encoding is performed by the procedure shown in FIG. That is, the quantization step correction coefficient F is set to a predetermined value in advance (S101), quantization (S103), zigzag scanning (S105), encoding (S107 to S113), and marker code addition (S).
119) and the code amount (S115) is calculated. The operation in the case of continuous shooting will be described with reference to FIG. At this time, there is a high possibility that the compressed code amount of the first image does not match the assigned code amount of one image, so the image of the first image is not recorded on the card, and the code of the image assigned per image is not recorded. When the amount is L, the image data before compression is temporarily stored in the memory 106 until the end of the continuous shooting, with an empty space of L left on the card. However, it is assumed that the memory 106 has a capacity of two images. Also, the quantization width of the next image is determined in the process of compressing the first image. During continuous shooting, the pattern does not change significantly between the two subsequent images, so the image to be recorded first should be evaluated to determine the quantization step for compression of the next image to be almost appropriate. You can If the code amount of the image assigned to each image is L, it is highly possible that the first image for continuous shooting does not match L, but the code amount of the second and subsequent images can be brought close to L. . When the release switch 213 is turned off, continuous shooting ends, but the number of continuous shots is n, the assigned code amount per image is L, the code amount of the second image is L 2 , the code of the nth image is If the amount is L n , two passes are performed so that L 1 is a code amount obtained by subtracting the sum of the code amounts from L 2 to L n from the code amount that is the product nL of the assigned code amount per continuous shooting number It is compression-encoded according to the method.

【0020】図11は本発明の別の実施例における連写
時の符号化シークエンスを示す図である。
FIG. 11 is a diagram showing an encoding sequence during continuous shooting in another embodiment of the present invention.

【0021】図11と図2を用いて本発明の動作を説明
する。モード切り替スイッチ124が連写モードに設定
された状態でレリーズスイッチ123がオンされると連
写が開始されるが、1枚目の画像は前述の図2の1パス
方式で符号化される。本実施例においては、図11に示
されるように、1枚当たりの符号割当量をLとすると1
枚目の画像の符号量が2Lよりも十分小さい値になるよ
う量子化ステップ補正係数Fを設定し、1枚目の圧縮符
号量が1枚当たりの割り当て符号量と一致していなくて
もそのまま記録する。また、この1枚目の過程において
次の画像の量子化巾を決定する。連写の際は続く2枚の
画像間で絵柄が大きく変わることがないため、先に記録
する画像を評価することによって次に撮影する画像の圧
縮に対する量子化ステップをほぼ適正な値に決めること
ができる。1枚当たりに割り当てられた画像の符号量を
Lとすると連写開始1枚目の画像はLと一致しない可能
性が高いが2枚以降の画像の符号量はほぼLに近付ける
ことが可能となる。レリーズスイッチ213がオフされ
ると連写が終了するが、連写枚数をn、1枚当たりの割
り当て符号量をL、1枚目の画像の符号量をL1 、n−
1枚目の符号量をLn −1、n枚目の画像の符号量をL
n とすると、Ln が連写枚数に1枚当たりの割当符号量
の積nLという符号量からL1 からLn −1までの符号
量の和を差し引いた符号量となるよう2パス方式によっ
て圧縮符号化する。
The operation of the present invention will be described with reference to FIGS. 11 and 2. When the release switch 123 is turned on with the mode switching switch 124 set to the continuous shooting mode, continuous shooting is started, but the first image is encoded by the one-pass method of FIG. 2 described above. In the present embodiment, as shown in FIG. 11, when the code allocation amount per sheet is L, it is 1
The quantization step correction coefficient F is set so that the code amount of the first image becomes a value sufficiently smaller than 2L, and even if the compression code amount of the first image does not match the assigned code amount of one image, it remains as it is. Record. Also, the quantization width of the next image is determined in the process of the first sheet. During continuous shooting, the pattern does not change significantly between the two subsequent images, so the image to be recorded first should be evaluated to determine the quantization step for the compression of the next image to be an appropriate value. You can If the code amount of the image assigned to each image is L, it is highly likely that the first image at the start of continuous shooting does not match L, but the code amount of the second and subsequent images can approach L. Become. When the release switch 213 is turned off, continuous shooting ends, but the number of continuous shots is n, the assigned code amount per image is L, the code amount of the first image is L 1 , n−.
The code amount of the first image is L n -1, and the code amount of the n -th image is L n -1.
If n , then L n is set by the two-pass method such that the code amount obtained by subtracting the sum of the code amounts from L 1 to L n −1 from the code amount of product nL of the assigned code amount per continuous shot number Compress and encode.

【0022】連写終了前の最後の画像の圧縮は連写終了
後に行うのである程度時間がかかっても構わない。した
がって2パス方式でなくとも符号量がLn に収束するま
で量子化ステップ補正係数Fを変えながら1パス方式の
符号化を繰り返すことによって符号量がLn となるよう
な繰り返し方式としてもよい。
Since the compression of the last image before the end of continuous shooting is performed after the end of continuous shooting, it may take some time. Therefore, the iterative method may be such that the code amount becomes L n by repeating the 1-pass system encoding while changing the quantization step correction coefficient F until the code amount converges to L n , instead of the 2-pass system.

【0023】また、本発明は電子スチルカメラ以外にも
画像ファイル装置やカラー複写機等にも適用することが
でき、電子スチルカメラに限るものではない。
The present invention can be applied not only to the electronic still camera but also to an image file device, a color copying machine, etc., and is not limited to the electronic still camera.

【0024】[0024]

【発明の効果】以上説明したように本発明よれば、一連
のn(nは4以上の自然数)画面分の画像データの符号
量を所定量に制御しながら、高速に符号化処理すること
ができ、かつn画面分の画像データに予め割り当てられ
た符号量を無駄なく有効に利用することができる。
As described above, according to the present invention, high-speed encoding processing can be performed while controlling the code amount of a series of image data for n (n is a natural number of 4 or more) screens to a predetermined amount. In addition, the code amount pre-allocated to the image data for n screens can be effectively used without waste.

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

【図1】本発明における連写時の符号化シークエンスを
示した図。
FIG. 1 is a diagram showing an encoding sequence during continuous shooting according to the present invention.

【図2】1パス方式による符号化のフローチャート。FIG. 2 is a flowchart of encoding by the one-pass method.

【図3】電子スチルカメラのブロック図。FIG. 3 is a block diagram of an electronic still camera.

【図4】1枚の画像を撮影する撮像シークエンスを示し
た図。
FIG. 4 is a diagram showing an image capturing sequence for capturing one image.

【図5】スイッチ124が連写モードに設定されたとき
に圧縮符号化を行う際の、本発明の対比例のシークエン
スを示した図。
FIG. 5 is a diagram showing a comparative sequence of the present invention when performing compression encoding when the switch 124 is set to the continuous shooting mode.

【図6】2パス方式の第1ステップを示した図。FIG. 6 is a diagram showing a first step of a two-pass method.

【図7】2パス方式の第2ステップを示した図。FIG. 7 is a diagram showing a second step of the two-pass method.

【図8】画像のブロック化を示した図。FIG. 8 is a diagram showing how an image is divided into blocks.

【図9】各ブロック毎のDCT係数を示した図。FIG. 9 is a diagram showing DCT coefficients for each block.

【図10】量子化されたDCT係数を符号化する手法に
ついて説明した図。
FIG. 10 is a diagram illustrating a method of encoding a quantized DCT coefficient.

【図11】本発明の別の実施例のシーケンスを示した
図。
FIG. 11 is a view showing the sequence of another embodiment of the present invention.

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

108 DCT変換回路 109 量子化回路 112 ジグザグ走査回路 108 DCT conversion circuit 109 Quantization circuit 112 Zigzag scanning circuit

───────────────────────────────────────────────────── フロントページの続き (58)調査した分野(Int.Cl.7,DB名) H04N 7/24 - 7/68 H04N 1/41 - 1/419 H04N 5/91 - 5/956 H04N 5/78 - 5/781 H03M 7/30 - 7/50 ─────────────────────────────────────────────────── ─── Continuation of front page (58) Fields surveyed (Int.Cl. 7 , DB name) H04N 7 /24-7/68 H04N 1/41-1/419 H04N 5/91-5/956 H04N 5 / 78-5/781 H03M 7/30-7/50

Claims (2)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 一連のn(nは4以上の自然数)画面の
画像データを入力する入力手段と、 前記入力手段によって入力された画像データを量子化す
る量子化手段と、 前記量子化手段によって量子化された画像データを可変
長符号化する符号化手段と、 前記量子化手段に使用される量子化ステップを画面単位
に制御する制御手段とを有し、 前記制御手段は、前記n画面において最終的に符号化す
る画面の画像データに対する量子化ステップを、前記n
画面分の画像データに対して予め割り当てられた符号量
から既に符号化されたn−1画面分の画像データの符号
量の和を差引いた符号量に基づいて制御し、前記最終的
に符号化する画面以外の画面の画像データに対する量子
化ステップを、符号化対象画面の前画面の画像データを
符号化した際の符号量に基づいて制御することを特徴と
する画像処理装置。
1. An input means for inputting a series of image data of n (n is a natural number of 4 or more) screens, a quantizing means for quantizing the image data input by the input means, and the quantizing means. The encoding means for variable-length encoding the quantized image data, and the control means for controlling the quantization step used by the quantization means in screen units, the control means in the n screen The quantization step for the image data of the screen finally encoded is
The control is performed based on the code amount obtained by subtracting the sum of the code amounts of the already coded image data of n-1 screens from the code amount assigned in advance to the image data of the screen, and finally encoding is performed. An image processing apparatus, wherein a quantization step for image data of a screen other than the screen to be controlled is controlled based on a code amount when the image data of the previous screen of the encoding target screen is encoded.
【請求項2】 一連のn(nは4以上の自然数)画面の
画像データを入力する入力工程と、 前記入力された画像データを量子化する量子化工程と、 前記量子化された画像データを可変長符号化する符号化
工程と、 前記量子化工程で使用される量子化ステップを画面単位
に制御する制御工程とを有し、 前記制御工程では、前記n画面において最終的に符号化
する画面の画像データに対する量子化ステップを、前記
n画面分の画像データに対して予め割り当てられた符号
量から既に符号化されたn−1画面分の画像データの符
号量の和を差引いた符号量に基づいて制御し、前記最終
的に符号化する画面以外の画面の画像データに対する量
子化ステップを、符号化対象画面の前画面の画像データ
を符号化した際の符号量に基づいて制御することを特徴
とする画像処理方法。
2. An input step of inputting a series of image data of n (n is a natural number of 4 or more) screens, a quantization step of quantizing the input image data, and a step of quantizing the quantized image data. A coding process for variable-length coding and a control process for controlling the quantization step used in the quantization process on a screen-by-screen basis. In the control process, a screen to be finally coded in the n screens. To the code amount obtained by subtracting the sum of the code amounts of the already coded image data of n-1 screens from the code amount previously assigned to the image data of n screens. Based on the code amount when the image data of the previous screen of the encoding target screen is encoded, the quantization step for the image data of the screen other than the screen to be finally encoded. Image processing method for the butterflies.
JP20388492A 1992-07-30 1992-07-30 Image processing apparatus and method Expired - Fee Related JP3450357B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP20388492A JP3450357B2 (en) 1992-07-30 1992-07-30 Image processing apparatus and method
US08/622,181 US6222943B1 (en) 1992-07-30 1996-03-25 Image reading, processing and recording with quick data compression

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP20388492A JP3450357B2 (en) 1992-07-30 1992-07-30 Image processing apparatus and method

Publications (2)

Publication Number Publication Date
JPH0654309A JPH0654309A (en) 1994-02-25
JP3450357B2 true JP3450357B2 (en) 2003-09-22

Family

ID=16481320

Family Applications (1)

Application Number Title Priority Date Filing Date
JP20388492A Expired - Fee Related JP3450357B2 (en) 1992-07-30 1992-07-30 Image processing apparatus and method

Country Status (1)

Country Link
JP (1) JP3450357B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100634660B1 (en) 1999-09-13 2006-10-16 마츠시타 덴끼 산교 가부시키가이샤 Apparatus and method for encoding
WO2005034504A1 (en) * 2003-09-30 2005-04-14 Mitsubishi Denki Kabushiki Kaisha Image pickup device and image pickup method

Also Published As

Publication number Publication date
JPH0654309A (en) 1994-02-25

Similar Documents

Publication Publication Date Title
US5216518A (en) Image processing method and apparatus for encoding variable-length data
JP3085465B2 (en) Image data encoding apparatus and encoding method
US5291282A (en) Image data coding apparatus and method capable of controlling amount of codes
JP4350809B2 (en) Digital camera
JPH053550A (en) Device and method for encoding image data
JPH09130802A (en) Image compressing method
JPH0832037B2 (en) Image data compression device
JP3450357B2 (en) Image processing apparatus and method
JP4183432B2 (en) Image data encoding method
US6222943B1 (en) Image reading, processing and recording with quick data compression
JP3222780B2 (en) Image compression device
JP2941913B2 (en) Image signal recording device
JP3227213B2 (en) Imaging method and apparatus
JPH0752951B2 (en) Image data compression processing method and apparatus
JPH04167868A (en) Coding device and coding method for picture
JPH0420190A (en) Electronic camera device and encoding device for picture data
JP3076081B2 (en) Image signal processing device
JPH09219807A (en) Digital still camera
JPH07115668A (en) Device and method for compressing image
EP0758513A1 (en) Device and method for coding video pictures
JPH09284767A (en) Picture compression system and picture compression method
JPH04144489A (en) Image data recording system
JP3144727B2 (en) Digital electronic still camera
JP3223866B2 (en) Image processing method
JPH1066004A (en) Picture file size controller

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20030624

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

Free format text: PAYMENT UNTIL: 20080711

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20080711

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20090711

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20090711

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20100711

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20100711

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20110711

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20120711

Year of fee payment: 9

LAPS Cancellation because of no payment of annual fees