JPH10174106A - Video data compressor and its method - Google Patents

Video data compressor and its method

Info

Publication number
JPH10174106A
JPH10174106A JP33208096A JP33208096A JPH10174106A JP H10174106 A JPH10174106 A JP H10174106A JP 33208096 A JP33208096 A JP 33208096A JP 33208096 A JP33208096 A JP 33208096A JP H10174106 A JPH10174106 A JP H10174106A
Authority
JP
Japan
Prior art keywords
picture
video data
compression
data
unit
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.)
Granted
Application number
JP33208096A
Other languages
Japanese (ja)
Other versions
JP4032446B2 (en
Inventor
Kanji Mihara
寛司 三原
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.)
Sony Corp
Original Assignee
Sony 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 Sony Corp filed Critical Sony Corp
Priority to JP33208096A priority Critical patent/JP4032446B2/en
Priority to KR1019980706189A priority patent/KR100599017B1/en
Priority to US09/117,973 priority patent/US6163573A/en
Priority to PCT/JP1997/004565 priority patent/WO1998026602A1/en
Publication of JPH10174106A publication Critical patent/JPH10174106A/en
Priority to US09/715,393 priority patent/US6493384B1/en
Priority to US10/273,491 priority patent/US20030039309A1/en
Priority to US10/299,174 priority patent/US7313184B2/en
Application granted granted Critical
Publication of JP4032446B2 publication Critical patent/JP4032446B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Television Signal Processing For Recording (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

PROBLEM TO BE SOLVED: To allow an encoder side to automatically detect a preceding picture type and to conduct compression coding while a group of picture(GOP) phase is matched in the case of repeating compression coding of video data. SOLUTION: Sections, motion compensation section 240 to discrete cosine transformation(DCT) section 244 apply motion compensation and DC transformation or the like to input video data to generate a DCT coefficient. A back search section 248 detects whether or not a minimum value is in existence in total sum of residues as the result of division by each quantization step of the DCT coefficient and discriminates that a picture with a minimum value is compression-coded for I picture in a preceding compression coding and discriminates a configuration (number N of pictures and interval M of P pictures) of a GOP at the preceding compression coding. A picture type control section 250 controls a picture rearrangment section 200 based on the discriminated GOP configuration to rearrange pictures of the input video data in a sequence by the compression coding section 20 for compression coding in the same GOP phase as the preceding compression coding.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、例えば、MPEG
方式等により圧縮符号化した映像データを記録し、再生
した映像データを伸長復号して出力するビデオテープレ
コーダ(VTR装置)を直列(タンデム)接続して映像
データの複写(ダビング)を行う場合に、伸長復号した
映像データの各ピクチャーを、前回の圧縮符号化の際と
同じ種類のピクチャーに圧縮符号化する映像データ圧縮
装置およびその方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention
When copying video data (dubbing) by connecting video tape recorders (VTR devices) that record video data compressed and encoded according to a system, expand and decode reproduced video data, and output the video data, in tandem, The present invention relates to a video data compression apparatus and a video data compression method for compressing and encoding each picture of video data that has been decompressed and decoded into a picture of the same type as in the previous compression encoding.

【0002】[0002]

【従来の技術および発明が解決しようとする課題】近
年、映像データ圧縮の分野においては、動き補償(M
C;motion compensation)処理と離散余弦変換(DC
T;discrete cosine transfer )等の直交変換による冗
長度低減処理との組合せによって符号化効率を高めた、
いわゆるMC−DCT方式として、MPEG2(moving
picture experts group 2)方式が盛んに用いられてい
る。
2. Description of the Related Art In recent years, in the field of video data compression, motion compensation (M
C; motion compensation) processing and discrete cosine transform (DC
T: Discrete cosine transfer), etc., to improve the coding efficiency by combining with redundancy reduction processing by orthogonal transformation.
As a so-called MC-DCT method, MPEG2 (moving
The picture experts group 2) method is widely used.

【0003】このMPEG2方式は通常、非圧縮映像デ
ータを、他のピクチャーの画素データを用いずに伸長復
号が可能な1枚のIピクチャー(intra coded picture)
、および、前のピクチャーの画素データを用いて伸長
復号するPピクチャー(predictive coded picture)と、
前後のピクチャーの画素データを用いて伸長復号するB
ピクチャー(bi-directionally predictive coded pictu
re) とを所定数ずつ含むGOP(group of picture)単位
に圧縮符号化する。
In the MPEG2 system, one I-picture (intra coded picture) that can normally expand and decode uncompressed video data without using pixel data of another picture is used.
, And a P picture (predictive coded picture) to be decompressed and decoded using the pixel data of the previous picture,
B that performs decompression decoding using pixel data of the preceding and following pictures
Picture (bi-directionally predictive coded pictu
re) is compressed and encoded in GOP (group of picture) units each including a predetermined number of GOPs.

【0004】ここで、例えば、テレビジョン放送局間で
映像データの伝送を行う際、あるいは、複数のビデオテ
ープレコーダ(VTR装置)を用いて映像データの複写
(ダビング)を行う際には、既にMPEG2方式により
圧縮符号化してある映像データを伸長復号し、再度、圧
縮符号化するために、圧縮符号化装置(エンコーダ)と
伸長復号装置(デコーダ)とを直列に接続(タンデム接
続)する必要が生じることがある。
Here, for example, when transmitting video data between television broadcasting stations or when copying (dubbing) video data using a plurality of video tape recorders (VTR devices), In order to decompress and decode the video data that has been compression-encoded by the MPEG2 system and to perform compression-encoding again, it is necessary to connect a tandem connection with a compression coder (encoder) and a decompression decoder (decoder) in series. May occur.

【0005】このように、エンコーダとデコーダとをタ
ンデム接続して映像データの圧縮符号化と伸長復号を繰
り返した場合、映像の品質が劣化する。特に、テレビジ
ョン放送局設備等の業務用システムにおいては高い映像
品質が要求されるので、タンデム接続したエンコーダお
よびデコーダによる圧縮符号化および伸長復号に伴う映
像品質の劣化防止が厳しく要求される。
[0005] As described above, when the encoder and the decoder are connected in tandem and the compression encoding and decompression decoding of the video data are repeated, the quality of the video deteriorates. In particular, since high-quality video is required in a business system such as a television broadcasting station facility, it is strictly required to prevent deterioration of video quality due to compression encoding and decompression decoding by tandem-connected encoders and decoders.

【0006】タンデム接続したエンコーダおよびデコー
ダにおいて生じる映像品質の劣化を最小にするために
は、圧縮符号化および伸長復号において用いられる量子
化ステップを同じにする必要があり、量子化ステップを
圧縮映像データとともに保持しておかねばならない。
[0006] In order to minimize the degradation of video quality that occurs in tandem-connected encoders and decoders, it is necessary to use the same quantization step in compression encoding and decompression decoding. Must be kept with it.

【0007】動き補償処理を行わずに圧縮符号化する場
合には、例えば、特開平5−284458号公報および
特開平6−319112号公報に開示されているよう
に、以前の圧縮符号化で使用された量子化ステップ、あ
るいは、その倍数関係にある量子化ステップを用いる
と、DCT係数の剰余総和が極小になるという性質を利
用し、最小の極小値を示す量子化ステップを最適な量子
化ステップとして求めるバックサーチという優れた方式
を用いることにより、圧縮符号化時と伸長復号時とで量
子化ステップを等しくし、映像品質の劣化を防ぐことが
できる。
In the case of performing compression encoding without performing motion compensation processing, for example, as disclosed in JP-A-5-284458 and JP-A-6-319112, By using the quantized step or the quantized step having a multiple relation thereof, the property that the sum of the remainder of the DCT coefficients is minimized is used, and the quantizing step indicating the minimum value is converted to the optimal quantizing step. By using an excellent method called back search, which is obtained as follows, it is possible to make the quantization steps equal between the time of compression encoding and the time of decompression decoding, and to prevent deterioration in video quality.

【0008】しかしながら、GOPがIピクチャーとB
ピクチャーをそれぞれ1枚ずつ含む2フレーム構成をと
る場合や、GOPが15フレーム構成をとる場合におい
ては、タンデム接続時の映像品質の劣化を抑えるため
に、量子化ステップを合わせるよりも、まず、毎回、同
じピクチャーを同じ種類のピクチャー(ピクチャータイ
プ)に圧縮符号化すること、つまり、圧縮符号化のたび
にGOPの位相を合わせることが重要である。
However, the GOP is composed of an I picture and a B picture.
When a two-frame configuration including one picture each is used, or when a GOP has a 15-frame configuration, first of all, rather than adjusting the quantization step, each time, in order to suppress the deterioration of video quality at the time of tandem connection, It is important to compress and encode the same picture into the same type of picture (picture type), that is, to match the phase of the GOP each time the compression and encoding are performed.

【0009】GOPの位相が崩れると、上述したバック
サーチ方式を用いることができなくなる上に、Bピクチ
ャーあるいはPピクチャーから伸長復号したピクチャー
を、Iピクチャーに圧縮符号化するというように、同じ
ピクチャーを異なったピクチャータイプに圧縮符号化し
てしまい、圧縮符号化のたびに映像の情報量を大きく失
い、大幅に映像の品質を大きく劣化させてしまう。
If the phase of the GOP is lost, the above-described back search method cannot be used. In addition, the same picture is compressed and coded as an I picture by expanding and decoding a B picture or a P picture. When compression encoding is performed for a different picture type, the amount of video information is greatly lost every time the compression encoding is performed, and the quality of the video is greatly deteriorated.

【0010】このような不具合に対処するためには、例
えば、特開平6−284414号公報に開示されている
ように、伸長復号時にピクチャータイプと復号された映
像データとを多重化して出力し、エンコーダは、多重化
されたピクチャータイプを参照してGOPの位相を合わ
せて圧縮符号化を行う方法が考えられている。
In order to cope with such a problem, for example, as disclosed in Japanese Patent Laid-Open No. 6-284414, a picture type and decoded video data are multiplexed and output at the time of decompression decoding. A method has been considered in which the encoder performs compression encoding by referring to the multiplexed picture types and adjusting the phases of the GOPs.

【0011】しかしながら、特開平6−284414号
公報に開示された方法によると、ピクチャータイプの情
報を、映像データの有効画素以外の部分に多重すること
になり、例えばテレビジョン放送局の操作卓(スイッチ
ャー)あるいは方式が異なるデジタルVTR装置等がタ
ンデム接続されたエンコーダおよびデコーダの間に入っ
たときに、ピクチャータイプの情報がブランキングされ
る等して失われてしまう可能性がある。
However, according to the method disclosed in Japanese Patent Application Laid-Open No. 6-284414, picture type information is multiplexed into portions other than effective pixels of video data. When a switcher) or a digital VTR device of a different system enters between a tandem-connected encoder and decoder, picture type information may be lost due to blanking or the like.

【0012】このように、ピクチャータイプの情報が失
われてしまったり、ピクチャータイプの情報が別の情報
やランダムデータに置換された場合には、次のエンコー
ダーがランダムデータ等をピクチャータイプの情報であ
ると誤って検出し、でたらめなピクチャータイプでエン
コードしてしまい、却って映像の品質の劣化が大きくな
ってしまう可能性がある。
As described above, when the picture type information is lost or the picture type information is replaced with other information or random data, the next encoder replaces the random data or the like with the picture type information. There is a possibility that the image quality may be erroneously detected and encoded with a random picture type.

【0013】本発明は、上述した不具合を解決するべく
なされたものであり、ピクチャータイプの情報を特別に
有効画素データと多重化しなくても、前回の圧縮符号化
時のピクチャータイプをエンコーダ側で自動検出し、G
OP位相を合わせて圧縮符号化することができる映像デ
ータ圧縮装置およびその方法を提供することを目的とす
る。
SUMMARY OF THE INVENTION The present invention has been made to solve the above-described problem. Even if the picture type information is not specially multiplexed with effective pixel data, the picture type at the time of the previous compression encoding can be converted on the encoder side. Automatic detection, G
It is an object of the present invention to provide a video data compression apparatus and a method thereof capable of performing compression encoding in accordance with an OP phase.

【0014】[0014]

【課題を解決するための手段】上記目的を達成するため
に、本発明にかかる映像データ圧縮装置は、Iピクチャ
ー、PピクチャーおよびBピクチャーの組み合わせに圧
縮処理された圧縮映像データを伸長した映像データのピ
クチャーの内、前記圧縮処理においてIピクチャーに圧
縮符号化されたピクチャーを検出するIピクチャー検出
手段と、検出したIピクチャーの間隔に基づいて、前記
映像データのピクチャーそれぞれが、前記圧縮処理にお
いて、Iピクチャー、PピクチャーおよびBピクチャー
内のいずれのピクチャー種別に圧縮されたかを判定する
ピクチャー種別判定手段と、前記映像データのピクチャ
ーそれぞれを、前記圧縮処理においてと同じピクチャー
種別に圧縮する映像データ圧縮手段とを有する。
In order to achieve the above object, a video data compression apparatus according to the present invention provides a video data compression apparatus which expands compressed video data compressed to a combination of an I picture, a P picture and a B picture. And I picture detection means for detecting a picture that has been compression-encoded into an I picture in the compression processing, and, based on an interval between the detected I pictures, each picture of the video data is Picture type determining means for determining which picture type among I picture, P picture and B picture has been compressed, and video data compressing means for compressing each picture of the video data into the same picture type as in the compression processing And

【0015】好適には、前記Iピクチャー検出手段は、
前記映像データのピクチャーそれぞれをマクロブロック
ごとに直行変換して直行変換データを生成する直行変換
手段と、生成した前記映像データのピクチャーそれぞれ
のマクロブロックごとの前記直行変換データを複数の量
子化ステップそれぞれにより除算する除算手段と、前記
映像データのピクチャーそれぞれのマクロブロックごと
の前記直行変換データの前記複数の量子化ステップによ
る除算結果それぞれの剰余の総和を算出する剰余総和算
出手段と、前記剰余の総和の極小値があるか否かに基づ
いて、前記映像データのピクチャーが、前記圧縮処理に
おいてIピクチャーに圧縮符号化されたか否かを検出す
る検出手段とを有する。
Preferably, the I picture detecting means includes:
Orthogonal transformation means for orthogonally transforming each picture of the video data for each macroblock to generate orthogonal transformation data, and a plurality of quantization steps for the orthogonal transformation data for each macroblock of each of the generated pictures of the video data. Dividing means; dividing the orthogonal transform data for each macroblock of each picture of the video data by the plurality of quantization steps; and calculating the sum of the respective remainders of the result of the plurality of quantization steps, and the sum of the remainders Detecting means for detecting whether or not the picture of the video data has been compression-coded into an I-picture in the compression processing based on whether or not there is a minimum value of

【0016】好適には、前記Iピクチャー検出手段は、
前記映像データのピクチャーそれぞれのマクロブロック
の一部を直行変換して直行変換データを生成する直行変
換手段と、生成した前記映像データのピクチャーそれぞ
れのマクロブロックの一部の前記直行変換データを複数
の量子化ステップそれぞれにより除算する除算手段と、
前記映像データのピクチャーそれぞれのマクロブロック
の一部の前記直行変換データの前記複数の量子化ステッ
プによる除算結果それぞれの剰余の総和を算出する剰余
総和算出手段と、前記剰余の総和の極小値があるか否か
に基づいて、前記映像データのピクチャーが、前記圧縮
処理においてIピクチャーに圧縮符号化されたか否かを
検出する検出手段とを有する。
Preferably, the I picture detecting means includes:
Orthogonal transformation means for orthogonally transforming a part of a macroblock of each picture of the video data to generate orthogonal transformation data, and a plurality of orthogonal transformation data of a part of the generated macroblock of each picture of the video data picture; Division means for dividing by each of the quantization steps;
A remainder sum calculating means for calculating a sum of remainders of respective division results of the orthogonal transformation data of a part of each macroblock of the picture of the video data by the plurality of quantization steps; and a minimum value of the sum of the remainders Detecting means for detecting whether or not the picture of the video data has been compression-encoded into an I-picture in the compression processing based on whether or not the picture has been compressed.

【0017】好適には、前記Iピクチャー検出手段は、
前記剰余の総和の極小値が最小となる量子化ステップを
選択する量子化ステップ選択手段を有し、前記映像デー
タ圧縮手段は、選択した前記量子化ステップを用いて前
記映像データを量子化する量子化手段を有する。
Preferably, the I picture detecting means includes:
The image processing apparatus further includes a quantization step selection unit that selects a quantization step that minimizes a minimum value of the sum of the remainders, wherein the video data compression unit uses a quantization step that quantizes the video data using the selected quantization step. It has a conversion means.

【0018】好適には、前記Iピクチャー検出手段は、
前記映像データ圧縮手段が前記映像データを圧縮する前
に、前記圧縮処理においてIピクチャーに圧縮符号化さ
れたピクチャーを検出する。
Preferably, the I picture detecting means comprises:
Before the video data compression means compresses the video data, a picture compressed and coded into an I picture in the compression processing is detected.

【0019】本発明に係る映像データ圧縮装置は、非圧
縮映像データをIピクチャー、PピクチャーおよびBピ
クチャーの組み合わせに圧縮処理するMPEG方式等に
より圧縮符号化され、さらに、伸長復号された映像デー
タを、再度、圧縮符号化する際に、映像データを前回の
圧縮符号化時と同じ種類のピクチャーに圧縮符号化す
る。
The video data compression apparatus according to the present invention compresses and encodes uncompressed video data into a combination of an I picture, a P picture and a B picture by an MPEG method or the like. When compression encoding is performed again, the video data is compression-encoded into the same type of picture as in the previous compression encoding.

【0020】本発明に係る映像データ圧縮装置におい
て、Iピクチャー検出手段は、バックサーチに用いられ
る処理を利用して、既に圧縮符号化を経ている映像デー
タのピクチャーの内、前回の圧縮符号化においてIピク
チャーに圧縮符号化されたピクチャーを検出する。つま
り、まず、Iピクチャー検出手段は、まず、映像データ
をマクロブロックごとにDCT等の直行変換し、DCT
係数を求める。
In the video data compression apparatus according to the present invention, the I picture detection means uses the processing used for the back search to select the picture of the video data which has already been compression-encoded in the previous compression-encoding. A picture that has been compression-encoded into an I-picture is detected. That is, first, the I picture detecting means first performs orthogonal transform such as DCT on the macroblock for each macroblock,
Find the coefficient.

【0021】次に、前回の圧縮符号化においてIピクチ
ャーに圧縮符号化されたピクチャーのDCT係数を、前
回の圧縮符号化時と同じ量子化ステップ、または、前回
の圧縮符号化時の整数倍の量子化ステップで除算した場
合にのみ、除算の結果として得られる剰余の総和が極小
値を示すことを利用し、DCT係数の剰余の総和に極小
値が現れるピクチャーを、前回の圧縮符号化時にIピク
チャーに圧縮符号化されたものであると判定する。
Next, the DCT coefficient of the picture that has been compression-coded into an I picture in the previous compression coding is calculated by the same quantization step as that of the previous compression coding, or an integer multiple of the previous compression coding. Only by dividing by the quantization step, utilizing the fact that the sum of the remainder obtained as a result of the division shows the minimum value, the picture in which the minimum value appears in the sum of the remainders of the DCT coefficients is determined by the I compression in the previous compression encoding. It is determined that the picture has been compression-coded.

【0022】ピクチャー種別判定手段は、例えば、前回
の圧縮符号化時にIピクチャーに圧縮符号化されたと判
定されたピクチャーの間隔から、前回の圧縮符号化時の
GOPのピクチャー数(N)、および、Pピクチャーの
間隔(M)を導出し、映像データの各ピクチャーが前回
の圧縮符号化においていずれの種類のピクチャーに圧縮
符号化されたかを判定する。
The picture type determining means calculates, for example, the number of pictures (N) of the GOP at the time of the previous compression encoding based on the interval between pictures determined to have been compressed and encoded into an I picture at the time of the previous compression encoding. The interval (M) between P pictures is derived, and it is determined which type of picture each picture of the video data has been compression-encoded in the previous compression encoding.

【0023】映像データ圧縮手段は、映像データの各ピ
クチャーを、前回の圧縮符号化においてと同じ種類のピ
クチャーに圧縮符号化するために適した順番に並び替
え、前回の圧縮符号化においてと同じGOP位相および
圧縮符号化方式で圧縮符号化する。
The video data compression means rearranges each picture of the video data into an order suitable for compression-encoding the same type of picture as in the previous compression encoding, and performs the same GOP as in the previous compression encoding. Compression encoding is performed by the phase and compression encoding method.

【0024】また、本発明に係る映像データ圧縮方法
は、Iピクチャー、PピクチャーおよびBピクチャーの
組み合わせに圧縮処理された圧縮映像データを伸長した
映像データのピクチャーの内、前記圧縮処理においてI
ピクチャーに圧縮符号化されたピクチャーを検出し、検
出したIピクチャーの間隔に基づいて、前記映像データ
のピクチャーそれぞれが、前記圧縮処理において、Iピ
クチャー、PピクチャーおよびBピクチャー内のいずれ
のピクチャー種別に圧縮されたかを判定し、前記映像デ
ータのピクチャーそれぞれを、前記圧縮処理においてと
同じピクチャー種別に圧縮する。
Further, according to the video data compression method of the present invention, of the pictures of video data obtained by expanding compressed video data which has been compressed into a combination of an I picture, a P picture and a B picture,
A picture compression-encoded into a picture is detected, and each picture of the video data is assigned to any of the picture types in the I picture, P picture and B picture in the compression processing based on the detected interval of the I picture. It is determined whether the video data has been compressed, and each picture of the video data is compressed into the same picture type as in the compression processing.

【0025】好適には、前記映像データのピクチャーそ
れぞれをマクロブロックごとに直行変換して直行変換デ
ータを生成し、生成した前記映像データのピクチャーそ
れぞれのマクロブロックごとの前記直行変換データを複
数の量子化ステップそれぞれにより除算し、前記映像デ
ータのピクチャーそれぞれのマクロブロックごとの前記
直行変換データの前記複数の量子化ステップによる除算
結果それぞれの剰余の総和を算出し、前記剰余の総和の
極小値があるか否かに基づいて、前記映像データのピク
チャーが、前記圧縮処理においてIピクチャーに圧縮符
号化されたか否かを検出する。
Preferably, each picture of the video data is orthogonally transformed for each macroblock to generate orthogonal transformation data, and the generated orthogonal transformation data for each macroblock of each picture of the video data is divided into a plurality of quantum data. Dividing the orthogonal transform data for each macroblock of each picture of the video data by the plurality of quantization steps, and calculating the sum of the remainders of each of the results of the plurality of quantization steps, and has a minimum value of the sum of the remainders Whether or not the picture of the video data has been compression-encoded into an I-picture in the compression process is detected based on whether or not the video data has been compressed.

【0026】好適には、前記映像データのピクチャーそ
れぞれのマクロブロックの一部を直行変換して直行変換
データを生成し、生成した前記映像データのピクチャー
それぞれのマクロブロックの一部の前記直行変換データ
を複数の量子化ステップそれぞれにより除算し、前記映
像データのピクチャーそれぞれのマクロブロックの一部
の前記直行変換データの前記複数の量子化ステップによ
る除算結果それぞれの剰余の総和を算出し、前記剰余の
総和の極小値があるか否かに基づいて、前記映像データ
のピクチャーが、前記圧縮処理においてIピクチャーに
圧縮符号化されたか否かを検出する。
Preferably, a part of a macroblock of each picture of the video data is orthogonally transformed to generate orthogonal transformation data, and the orthogonal transformation data of a part of a macroblock of each picture of the generated video data is preferably transformed. Is divided by each of a plurality of quantization steps, the sum of the remainders of the respective division results of the plurality of orthogonal transformation data of the orthogonal transform data of a part of the macroblock of each picture of the video data is calculated, and the remainder of the remainder is calculated. Based on whether or not there is a minimum value of the sum, it is detected whether or not the picture of the video data has been compression-encoded into an I-picture in the compression processing.

【0027】好適には、前記剰余の総和の極小値が最小
となる量子化ステップを選択し、選択した前記量子化ス
テップを用いて前記映像データを量子化する。
Preferably, a quantization step that minimizes the minimum value of the sum of the remainders is selected, and the video data is quantized using the selected quantization step.

【0028】好適には、前記映像データを圧縮する前
に、前記圧縮処理においてIピクチャーに圧縮符号化さ
れたピクチャーを検出する。
Preferably, before the video data is compressed, a picture compression-encoded into an I picture in the compression process is detected.

【0029】[0029]

【発明の実施の形態】第1実施形態 以下、本発明の第1の実施形態を説明する。DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS First Embodiment Hereinafter, a first embodiment of the present invention will be described.

【0030】第1実施形態の背景 例えば、テレビジョン放送局間で複数のVTR装置を用
いて映像データのダビングを行う際には、既にMPEG
2方式により圧縮符号化してある映像データを伸長復号
し、再度、圧縮符号化するために、エンコーダとデコー
ダとをタンデム接続する必要が生じることがある。この
ように、映像データの圧縮符号化と伸長復号を繰り返し
た場合、映像の品質が劣化してしまう。
Background of the First Embodiment For example, when dubbing video data using a plurality of VTR devices between television broadcasting stations, MPEG
In order to decompress and decode video data that has been compression-encoded by the two methods, and to perform compression-encoding again, it may be necessary to connect the encoder and the decoder in tandem. As described above, when the compression encoding and the decompression decoding of the video data are repeated, the quality of the video is deteriorated.

【0031】映像データの圧縮符号化と伸長復号を繰り
返した場合の映像品質の劣化を最小にするためには、上
述したバックサーチ等により圧縮符号化および伸長復号
において用いられる量子化ステップを同じにし、さら
に、圧縮符号化のたびにGOPの位相を合わせることが
重要である。
In order to minimize the deterioration of the video quality when the video data is repeatedly subjected to the compression encoding and decompression decoding, the quantization steps used in the compression encoding and decompression decoding by the above-described back search and the like are made the same. Further, it is important to match the phase of the GOP every time the compression encoding is performed.

【0032】GOPの位相が崩れると、上述したバック
サーチ方式を用いることができなくなる上に、Bピクチ
ャーあるいはPピクチャーから伸長復号したピクチャー
を、Iピクチャーに圧縮符号化するというように、同じ
ピクチャーを異なったピクチャータイプに圧縮符号化し
てしまい、圧縮符号化のたびに映像の情報量を大きく失
い、大幅に映像の品質を大きく劣化させてしまう。
If the phase of the GOP is lost, the above-described back search method cannot be used, and the same picture is compressed and coded into an I picture by expanding and decoding a B picture or a P picture. When compression encoding is performed for a different picture type, the amount of video information is greatly lost every time the compression encoding is performed, and the quality of the video is greatly deteriorated.

【0033】第1の実施形態に示すエンコーダ2(2
a,2b)は、上述した不具合を解決するべくなされた
ものであり、ピクチャータイプの情報を特別に有効画素
データと多重化しなくても、前回の圧縮符号化時のピク
チャータイプをエンコーダ側で自動検出し、GOP位相
を合わせて圧縮符号化することができるように構成され
ている。
The encoder 2 (2) shown in the first embodiment
a, 2b) are intended to solve the above-described problem. The picture type at the time of the previous compression encoding is automatically set on the encoder side without specially multiplexing the picture type information with valid pixel data. It is configured so that it can be detected and compressed and encoded with the GOP phase matched.

【0034】映像データ処理システム1 以下、映像データ用のエンコーダおよびデコーダがタン
デム接続された映像データ処理システム1を説明する。
本発明に係るエンコーダは、映像データ処理システム1
において用いられる。
Video Data Processing System 1 Hereinafter, a video data processing system 1 in which an encoder and a decoder for video data are connected in tandem will be described.
An encoder according to the present invention is a video data processing system 1
Used in

【0035】図1は、本発明に係るエンコーダ2が用い
られる映像データ処理システム1の構成を示す図であ
る。図1に示すように、映像データ処理システム1は、
VTR装置あるいはハードディスク装置等の記録装置、
または、通信回線あるいは伝送路等の記録・伝送装置(b
rr channel) 3a〜3cを介して、エンコーダ(encoder
1, encoder2)2a,2bとデコーダ(decoder1, decoder
2)4a,4bとが直列に接続(タンデム接続)された構
成を採る。
FIG. 1 is a diagram showing a configuration of a video data processing system 1 using an encoder 2 according to the present invention. As shown in FIG. 1, the video data processing system 1
A recording device such as a VTR device or a hard disk device,
Alternatively, a recording / transmission device such as a communication line or a transmission line (b
rr channel) Encoders (encoder) via 3a-3c
1, encoder2) 2a, 2b and decoder (decoder1, decoder
2) A configuration in which 4a and 4b are connected in series (tandem connection) is adopted.

【0036】なお、明確に映像データ処理システム1の
構成を採らない場合であっても、例えば、入力される非
圧縮映像データをMPEG2方式等により圧縮符号化し
てVTRテープに記録し、再生時に伸長複合化して出力
するVTR装置を複数、接続して映像データの複写を行
う場合にも、映像データが通る経路は、実質的に映像デ
ータ処理システム1と同じになる。また、エンコーダ2
(2a,2b)は、複数の種類のピクチャーを含むGO
Pに非圧縮映像データを圧縮符号化する場合に本発明に
特徴的な効果を奏する。
Even if the configuration of the video data processing system 1 is not clearly adopted, for example, the input uncompressed video data is compression-encoded by the MPEG2 system or the like, recorded on a VTR tape, and decompressed during reproduction. Even in the case where a plurality of VTR devices that output in a complex form are connected and video data is copied, the path through which the video data passes is substantially the same as that of the video data processing system 1. Also, encoder 2
(2a, 2b) is a GO including a plurality of types of pictures.
When the non-compressed video data is compression-encoded in P, the present invention has an advantageous effect.

【0037】映像データ処理システム1において、エン
コーダ2aは、例えば、MPEG2方式といったMC−
DCT方式により、外部から入力される非圧縮映像デー
タ(入力映像データ)を複数の種類のピクチャーを含む
GOPの単位に圧縮符号化して圧縮映像データ(圧縮符
号化されたビットストリーム)を生成し、記録・伝送装
置3(3a)を介してデコーダ4aに伝送する。
In the video data processing system 1, the encoder 2a is, for example, an MC-
According to the DCT method, non-compressed video data (input video data) input from the outside is compression-coded into GOP units including a plurality of types of pictures to generate compressed video data (compression-coded bit stream), The data is transmitted to the decoder 4a via the recording / transmission device 3 (3a).

【0038】デコーダ4aは、記録・伝送装置3aを介
してエンコーダ2aから入力された圧縮映像データを伸
長復号して、例えば、編集処理等に適したD−1ディジ
タルVTR用の非圧縮(フルビット)の映像データに戻
し、記録・伝送装置3(3b)を介してエンコーダ2b
に伝送する。エンコーダ2bは、エンコーダ2aと同じ
方式により、記録・伝送装置3bを介してデコーダ4a
から入力されたフルビットの映像データを圧縮符号化
し、記録・伝送装置3(3c)を介してデコーダ4bに
伝送する。デコーダ4bは、デコーダ4aと同様に、記
録・伝送装置3cを介してエンコーダ2bから入力され
た圧縮映像データを伸長復号して出力映像データとして
出力する。
The decoder 4a decompresses and decodes the compressed video data input from the encoder 2a via the recording / transmission device 3a, and performs, for example, uncompression (full bit) for a D-1 digital VTR suitable for editing and the like. ) To the encoder 2b via the recording / transmission device 3 (3b).
To be transmitted. The encoder 2b is connected to the decoder 4a via the recording / transmission device 3b in the same manner as the encoder 2a.
The compression and encoding of the full-bit video data input from the device is performed and transmitted to the decoder 4b via the recording / transmission device 3 (3c). The decoder 4b, like the decoder 4a, decompresses and decodes the compressed video data input from the encoder 2b via the recording / transmission device 3c and outputs it as output video data.

【0039】なお、映像データ処理システム1において
は、タンデム接続された、エンコーダ2、記録・伝送装
置3およびデコーダ4が、必要に応じて3段以上、含ま
れることがあり、3段目以降の各構成部分は、2段目以
前と同様に映像データの圧縮符号化、伝送および伸長復
号を行う。
In the video data processing system 1, the tandem-connected encoder 2, recording / transmission device 3, and decoder 4 may be included in three or more stages as necessary. Each component performs compression encoding, transmission, and decompression decoding of video data in the same manner as before the second stage.

【0040】また、図1においては、フルビットチャネ
ル(full bit channel )と記載された記録・伝送装置3
bとしては、単に、伸長復号したフルビットの映像デー
タを伝送あるいは記録・再生する装置のほかに、例え
ば、伸長復号した映像データをディジタル/アナログ
(D/A)変換してアナログVTR装置に記録し、再び
アナログ/ディジタル(A/D)変換してデジタル映像
データに戻す装置、あるいは、スイッチャーや特殊効果
装置を介して映像データに対して編集、加工を加える装
置も含まれる。このような装置においても、映像データ
とともに記録したピクチャータイプの情報が失われるの
で、エンコーダ2(2a,2b)は、本発明に特徴的な
効果を奏する。
In FIG. 1, the recording / transmission device 3 described as a full bit channel (full bit channel)
As b, in addition to a device that simply transmits or records / reproduces full-length video data that has been expanded and decoded, for example, digital-to-analog (D / A) conversion of expanded and decoded video data and records it in an analog VTR device Then, a device for converting analog / digital (A / D) to digital video data again, or a device for editing and processing video data via a switcher or a special effect device is also included. Even in such an apparatus, the picture type information recorded together with the video data is lost, so that the encoder 2 (2a, 2b) has a characteristic effect of the present invention.

【0041】エンコーダ2(2a,2b) 図2は、図1に示した第1の実施形態における本発明に
係るエンコーダ2(2a,2b)の構成を示す図であ
る。図2に示すように、エンコーダ2は、圧縮符号化部
20および圧縮制御部24から構成される。
The encoder 2 (2a, 2b) FIG. 2 is a diagram showing the configuration of an encoder 2 according to the present invention in the first embodiment shown in FIG. 1 (2a, 2b). As shown in FIG. 2, the encoder 2 includes a compression encoding unit 20 and a compression control unit 24.

【0042】圧縮符号化部20は、ピクチャー並べ替え
部200、走査変換ブロック化部202、動き検出部2
04、FIFO206,220、減算回路207、DC
T部208、量子化部210、可変長符号化部(VL
C)212、逆量子化部214、逆DCT(IDCT)
部216、加算回路218および動き補償部222から
構成される。圧縮制御部24は、動き補償部240、減
算回路242、DCT部244、予測部246、バック
サーチ(back search) 部248およびピクチャータイプ
制御部250から構成される。
The compression encoding unit 20 includes a picture rearranging unit 200, a scan conversion blocking unit 202, and a motion detecting unit 2.
04, FIFOs 206 and 220, subtraction circuit 207, DC
T section 208, quantization section 210, variable length coding section (VL
C) 212, inverse quantization unit 214, inverse DCT (IDCT)
216, an adder 218, and a motion compensator 222. The compression control unit 24 includes a motion compensation unit 240, a subtraction circuit 242, a DCT unit 244, a prediction unit 246, a back search unit 248, and a picture type control unit 250.

【0043】エンコーダ2は、これらの構成部分によ
り、既にMPEG2方式等による圧縮符号化および伸長
復号を1回以上経た入力映像データ(video in)から、前
回の圧縮符号化におけるGOP位相を検出するととも
に、前回の圧縮符号化における量子化ステップをバック
サーチ方式により再生し、前回と同じ量子化ステップお
よびGOP位相で再び入力映像データを圧縮符号化し、
エンコーダとデコーダをタンデム接続して映像データの
圧縮符号化および伸長復号を繰り返した場合の映像の品
質の劣化を防止する。
With these components, the encoder 2 detects the GOP phase in the previous compression encoding from input video data (video in) that has already undergone compression encoding and decompression decoding by the MPEG2 system or the like at least once. , The quantization step in the previous compression encoding is reproduced by the back search method, and the input video data is compression-encoded again with the same quantization step and GOP phase as the previous one,
An encoder and a decoder are connected in tandem to prevent degradation of video quality when compression encoding and decompression decoding of video data are repeated.

【0044】エンコーダ2の各構成部分 以下、エンコーダ2の各構成部分を説明する。 Each component of encoder 2 will be described below.

【0045】圧縮符号化部20 圧縮符号化部20は、一般的なMPEG2方式のエンコ
ーダと同様に、入力映像データに対して動き補償処理、
DCT処理および可変長符号化処理を行って圧縮符号化
する。圧縮符号化部20において、ピクチャー並べ替え
部200は、ピクチャータイプ制御部250の制御に従
って、入力映像データのピクチャーが圧縮符号化後にい
ずれのピクチャータイプとなるかに応じて圧縮符号化に
適した順番に入力映像データのピクチャーを並び替え、
走査変換ブロック化部202に対して出力する。
Compression encoding unit 20 The compression encoding unit 20 performs motion compensation processing on input video data, as in a general MPEG2 encoder.
DCT processing and variable length coding processing are performed to perform compression coding. In the compression encoding unit 20, the picture rearranging unit 200, under the control of the picture type control unit 250, selects an order suitable for compression encoding according to the picture type of the picture of the input video data after compression encoding. Sorts the picture of the input video data to
Output to the scan conversion blocking unit 202.

【0046】走査変換ブロック化部202は、ピクチャ
ー並べ替え部200から入力された映像データをフィー
ルド/フレーム変換し、さらにマクロブロック化して動
き検出部204および圧縮制御部24の動き補償部24
0に対して出力する。動き検出部204は、走査変換ブ
ロック化部202から入力される映像データをFIFO
206および圧縮制御部24の減算回路242に対して
出力するとともに、走査変換ブロック化部202から入
力される映像データをマクロブロック単位に処理してそ
の動きを検出し、映像の動きを示す動きベクトルを生成
して動き補償部240およびFIFO220に対して出
力する。
The scan conversion block forming unit 202 performs field / frame conversion on the video data input from the picture rearranging unit 200 and further converts the video data into macroblocks to form the motion detecting unit 204 and the motion compensating unit 24 of the compression control unit 24.
Output for 0. The motion detection unit 204 converts the video data input from the scan conversion blocking unit 202 into a FIFO
206 and the subtraction circuit 242 of the compression control unit 24. The video data input from the scan conversion blocking unit 202 is processed in units of macroblocks to detect the motion, and a motion vector indicating the motion of the video. Is generated and output to the motion compensation unit 240 and the FIFO 220.

【0047】FIFO206は、動き検出部204から
入力された映像データをバッファリングし、圧縮制御部
24のDCT部244、予測部246およびバックサー
チ部248における処理(予備符号化処理)に要する時
間だけ遅延を与えて減算回路207に対して出力する。
The FIFO 206 buffers the video data input from the motion detection unit 204, and stores only the time required for processing (preliminary coding processing) in the DCT unit 244, prediction unit 246 and back search unit 248 of the compression control unit 24. The output is provided to the subtraction circuit 207 with a delay.

【0048】減算回路207は、FIFO206から入
力される映像データに含まれるピクチャーの内、圧縮符
号化後にIピクチャーとなるピクチャーの映像データを
そのままDCT部208に対して出力する。また、減算
回路207は、FIFO206から入力される映像デー
タに含まれるピクチャーの内、圧縮符号化後にPピクチ
ャーまたはBピクチャーとなるピクチャーの映像データ
から動き補償部222の出力映像データを減算し、予測
誤差データを生成してDCT部208に対して出力す
る。
The subtraction circuit 207 outputs, to the DCT unit 208, the video data of a picture that becomes an I-picture after compression encoding among the pictures included in the video data input from the FIFO 206. Further, the subtraction circuit 207 subtracts the output video data of the motion compensation unit 222 from the video data of a picture that becomes a P picture or a B picture after compression encoding among the pictures included in the video data input from the FIFO 206 and performs prediction. Error data is generated and output to DCT section 208.

【0049】DCT部208は、減算回路207から入
力される圧縮符号化後にIピクチャーとなる映像デー
タ、および、圧縮符号化後にPピクチャーまたはBピク
チャーとなる映像データの予測誤差データをDCT処理
し、DCT処理の結果として得られたDCT係数を量子
化部210に対して出力する。量子化部210は、圧縮
制御部24のバックサーチ部248から入力される量子
化インデックスが示す量子化ステップで、DCT部20
8から入力されたDCT係数を量子化し、量子化データ
として可変長符号化部212および逆量子化部214に
対して出力する。
The DCT section 208 performs DCT processing on the video data which is input from the subtraction circuit 207 to become an I picture after compression encoding and the prediction error data of the video data which becomes a P picture or a B picture after compression encoding. The DCT coefficient obtained as a result of the DCT processing is output to quantization section 210. The quantization unit 210 performs the quantization step indicated by the quantization index input from the back search unit 248 of the compression control unit 24,
8 is quantized and output to the variable length coding unit 212 and the inverse quantization unit 214 as quantized data.

【0050】可変長符号化部212は、量子化部210
から入力される量子化データを、例えばランレングス符
号化方式により可変長符号化し、出力映像データ(strea
m out)として出力する。逆量子化部214は、入力され
る量子化データに対して、量子化部210と逆の処理を
行ってDCT係数を再生し、逆DCT部216に対して
出力する。
The variable length coding section 212 includes a quantization section 210
Quantized data input from the VGA is variable-length encoded by, for example, a run-length encoding method, and output video data (strea
m out). The inverse quantization unit 214 performs a process reverse to that of the quantization unit 210 on the input quantized data to reproduce a DCT coefficient, and outputs the DCT coefficient to the inverse DCT unit 216.

【0051】逆DCT部216は、入力されるDCT係
数に対してDCT部208と逆の処理を行って映像デー
タを再生し、加算回路218に対して出力する。加算回
路218は、逆DCT部216から入力される映像デー
タと、動き補償部222から入力される映像データとを
加算して映像データを再生し、動き補償部222に対し
て出力する。
The inverse DCT section 216 performs the inverse processing of the DCT section 208 on the input DCT coefficients to reproduce video data, and outputs the video data to the addition circuit 218. The addition circuit 218 adds up the video data input from the inverse DCT unit 216 and the video data input from the motion compensation unit 222 to reproduce the video data, and outputs the video data to the motion compensation unit 222.

【0052】FIFO220は、動き検出部204から
入力される動きベクトルをバッファリングし、FIFO
206〜加算回路218の処理に要する時間だけ遅延し
て動き補償部222に対して出力する。動き補償部22
2は、加算回路218から入力される映像データに対し
て、FIFO220から入力される動きベクトルを用い
た動き補償処理を行い、減算回路207およびDCT部
208に対して出力する。
The FIFO 220 buffers the motion vector input from the motion detection unit 204, and
206 to output to the motion compensator 222 with a delay by the time required for the processing of the adder circuit 218. Motion compensator 22
2 performs a motion compensation process on the video data input from the addition circuit 218 using the motion vector input from the FIFO 220, and outputs the result to the subtraction circuit 207 and the DCT unit 208.

【0053】圧縮制御部24 圧縮制御部24は、入力映像データの前回の圧縮符号化
における量子化ステップおよびGOP位相を検出し、こ
れらが一致するように圧縮符号化部20を制御する。ま
た、圧縮制御部24は、入力映像データの絵柄の複雑さ
および動きの速さ〔絵柄の難しさ(難度);difficult
y〕に基づいて、可変長符号化部212から出力される
出力映像データの総量(データレート)が、1〜数GO
P分の圧縮映像データを生成する時間(単位期間)ごと
の出力映像データの許容値〔例えば伝送路の伝送容量
等〕以下であって、この許容値にほぼ等しくする量子化
ステップを算出し、量子化インデックスの形式で量子化
部210に設定する。
The compression control unit 24 detects the quantization step and the GOP phase in the previous compression encoding of the input video data, and controls the compression encoding unit 20 so that they match. Further, the compression control unit 24 controls the complexity and the speed of movement of the pattern of the input video data [difficulty of the pattern (difficulty);
y], the total amount (data rate) of the output video data output from the variable length coding unit 212 is 1 to several GOs
Calculate a quantization step that is less than or equal to the permissible value (for example, the transmission capacity of the transmission path) of the output video data for each time (unit period) for generating the compressed video data for P; The value is set in the quantization unit 210 in the form of a quantization index.

【0054】圧縮制御部24において、動き補償部24
0は、圧縮符号化部20の動き補償部222と同様に、
走査変換ブロック化部202から入力される映像データ
に対して、動き検出部204から入力される動きベクト
ルを用いて動き補償処理を行い、減算回路242に対し
て出力する。減算回路242は、圧縮符号化部20の減
算回路207と同様に、動き検出部204から入力され
る映像データから、動き補償部240から入力される動
き補償された映像データを減算し、Iピクチャーの映像
データ、および、PピクチャーまたはBピクチャーの予
測誤差データを生成し、DCT部244に対して出力す
る。
In the compression controller 24, the motion compensator 24
0 is the same as the motion compensator 222 of the compression encoder 20.
The video data input from the scan conversion blocking unit 202 is subjected to a motion compensation process using the motion vector input from the motion detection unit 204, and is output to the subtraction circuit 242. The subtraction circuit 242 subtracts the motion-compensated video data input from the motion compensation unit 240 from the video data input from the motion detection unit 204, similarly to the subtraction circuit 207 of the compression encoding unit 20. , And the prediction error data of the P picture or the B picture are generated and output to the DCT section 244.

【0055】DCT部244は、圧縮符号化部20のD
CT部208と同様に、減算回路242から入力された
Iピクチャーの映像データ、および、Pピクチャーまた
はBピクチャーの予測誤差データをDCT変換し、DC
T処理の結果として得られたDCT係数を生成して予測
部246に対して出力する。
The DCT unit 244 outputs the D
Similarly to the CT unit 208, the I-picture video data and the P-picture or B-picture prediction error data input from the subtraction circuit 242 are DCT-
A DCT coefficient obtained as a result of the T processing is generated and output to the prediction unit 246.

【0056】予測部246は、DCT部244から入力
されたDCT係数をバックサーチ部248に対して出力
する。また、予測部246は、例えば、1〜数GOP分
の圧縮映像データを生成する時間を単位期間として、こ
の単位期間ごとに固定値の量子化ステップ(fix-q) でD
CT部244から入力されたDCT係数を量子化して量
子化データを生成する。
The prediction section 246 outputs the DCT coefficient input from the DCT section 244 to the back search section 248. For example, the prediction unit 246 sets the time for generating compressed video data for one to several GOPs as a unit period, and sets a fixed value quantization step (fix-q) for each unit period.
The DCT coefficient input from the CT unit 244 is quantized to generate quantized data.

【0057】また、予測部246は、映像データ処理シ
ステム1(エンコーダ2)の使用者等によって外部から
設定され、上記許容値を示す目標データ量、および、生
成した量子化データのデータ量(発生符号量)に基づい
て、入力映像データの絵柄の難しさ(難度)を単位期間
ごとに見積もる。
The prediction section 246 is set from the outside by a user of the video data processing system 1 (encoder 2), and sets a target data amount indicating the allowable value and a data amount of the generated quantized data. Based on the code amount, the difficulty (difficulty) of the pattern of the input video data is estimated for each unit period.

【0058】また、予測部246は、見積もった入力映
像データの絵柄の難しさに応じて、入力映像データの絵
柄が難しい部分に多くのデータ量(データレート)を割
り当て、入力映像データの絵柄が簡単な部分に少ないデ
ータ量(データレート)を割り当てて出力映像データの
品質を全体として高く保ち、しかも、出力映像データの
総量が上記許容値を超えないようにするために実際に用
いるべき量子化ステップを示す量子化インデックスを単
位期間ごとに算出し、バックサーチ部248に対して出
力する。
The predicting unit 246 allocates a large amount of data (data rate) to a portion where the pattern of the input video data is difficult according to the estimated difficulty of the pattern of the input video data. A small amount of data (data rate) is allocated to simple parts to keep the quality of the output video data high as a whole, and the quantization to be actually used so that the total amount of the output video data does not exceed the allowable value. A quantization index indicating a step is calculated for each unit period, and is output to the back search unit 248.

【0059】なお、予測部246においては、上述した
固定値の量子化ステップでDCT係数を量子化して量子
化インデックスを予測する方法の他に、例えば、DCT
部244から入力されるDCT係数をいくつかの仮の量
子化値を用いて量子化して量子化データを生成し、生成
した量子化データのデータ量(発生符号量)と目標デー
タ量(許容値)とを比較して、これらのいずれが多いか
に応じて二分木検索により最適な量子化ステップを予測
する方法〔バイナリサーチ(binary search) 〕を採るこ
とも可能である。
Note that, in addition to the method of predicting a quantization index by quantizing DCT coefficients in the above-described fixed-value quantization step, the prediction unit 246 includes, for example, DCT
The DCT coefficient input from the section 244 is quantized using some temporary quantized values to generate quantized data, and the data amount (generated code amount) of the generated quantized data and the target data amount (allowable value) ), It is also possible to adopt a method (binary search) of predicting an optimal quantization step by a binary tree search depending on which of these is larger.

【0060】バックサーチ部248の処理の概要 バックサーチ部248は、予測部246から入力される
量子化インデックス、および、DCT部244から予測
部246を介して入力されるDCT係数に基づいて、前
回の圧縮符号化においてイントラ符号化されたピクチャ
ーを検出し、検出結果をピクチャータイプ制御部250
に対して出力する。
Overview of Processing of Back Search Unit 248 The back search unit 248 performs the previous search based on the quantization index input from the prediction unit 246 and the DCT coefficient input from the DCT unit 244 via the prediction unit 246. , Detects an intra-coded picture in the compression coding of
Output to

【0061】また、バックサーチ部248は、バックサ
ーチにより入力映像データが1度以上の圧縮符号化を経
ているか否かを判断し、前回の圧縮符号化において用い
られた量子化ステップを示す量子化インデックスを生成
し、圧縮符号化部20の量子化部210に設定する。
The back search unit 248 determines whether or not the input video data has undergone one or more compression encodings by a back search, and determines the quantization step used in the previous compression encoding. An index is generated and set in the quantization unit 210 of the compression encoding unit 20.

【0062】つまり、バックサーチ部248は、予測部
246が予測した量子化インデックスが示す量子化ステ
ップおよびその近傍の値で、DCT部244から予測部
246を介して入力されるDCT係数を除算し、除算結
果の剰余の総和が著しく小さい値を示す量子化ステップ
が存在する場合には、この著しく小さい値を示す量子化
ステップを前回の圧縮符号化において用いられた量子化
ステップと判定し、この量子化ステップを示す量子化イ
ンデックスを量子化部210に対して出力する。
That is, the back search section 248 divides the DCT coefficient input from the DCT section 244 via the prediction section 246 by the quantization step indicated by the quantization index predicted by the prediction section 246 and a value near the quantization step. If there is a quantization step in which the sum of the remainder of the division result indicates a significantly small value, the quantization step in which the significantly small value is determined is determined as the quantization step used in the previous compression encoding. A quantization index indicating a quantization step is output to quantization section 210.

【0063】バックサーチ部248の処理の詳細 さらに、バックサーチ部248の入力映像データのIピ
クチャーの検出処理の内容を詳細に説明する。バックサ
ーチ部248におけるGOP位相の検出処理は、入力映
像データに含まれるIピクチャーから伸長復号されたピ
クチャー(単に「入力映像データのIピクチャー」とも
記す)を、次の圧縮符号化においても再びIピクチャー
に圧縮符号化(イントラ符号化)した場合にのみ、バッ
クサーチにより求められるDCT係数の剰余総和が顕著
な極小を示すという性質に着目して行われる。
The details of the processing of the back search section 248 Further, the contents of the processing of detecting the I picture of the input video data by the back search section 248 will be described in detail. The GOP phase detection process performed by the back search unit 248 is a process in which a picture decompressed and decoded from an I picture included in the input video data (also simply referred to as an “I picture of the input video data”) is again subjected to the I compression even in the next compression encoding. Only when the picture is compression-coded (intra-coded), attention is paid to the property that the residual sum of the DCT coefficients obtained by the back search shows a remarkable minimum.

【0064】この理由は、PピクチャーまたはBピクチ
ャーは、動き補償処理により算出した予測誤差データを
DCT処理し、量子化することにより圧縮符号化されて
いるために、PピクチャーまたはBピクチャーを逆DC
T処理、逆量子化および動き補償して伸長復号しても、
伸長復号の結果として得られる映像データの値は量子化
ステップの整数倍にはなりえないからである。従って、
PピクチャーまたはBピクチャーを伸長復号して得られ
たピクチャー(単に「入力映像データのPピクチャー,
Bピクチャー」とも記す)をイントラ符号化し、バック
サーチ処理した場合には、DCT係数の剰余の総和に極
小点は存在せず、見つけることはできない。
The reason is that the P picture or the B picture is subjected to the DCT processing of the prediction error data calculated by the motion compensation processing and is compression-coded by quantization, so that the P picture or the B picture is inversely DC-coded.
Even if T processing, dequantization and motion compensation are performed for decompression decoding,
This is because the value of the video data obtained as a result of the decompression decoding cannot be an integral multiple of the quantization step. Therefore,
A picture obtained by decompressing and decoding a P picture or a B picture (hereinafter simply referred to as “P picture of input video data,
When the B-picture is also intra-coded and back-searched, there is no minimum point in the sum of the remainder of the DCT coefficients, and it cannot be found.

【0065】また、同様に、入力映像データのBピクチ
ャー(Pピクチャー)を再度同じBピクチャー(Pピク
チャー)に圧縮符号化し、バックサーチ処理した場合に
も、前回の圧縮符号化で求められた動きベクトルと、次
回の圧縮符号化により歪んだ映像から求められた動きベ
クトルとは同一にはならず、また、前回の圧縮符号化お
よび伸長復号による映像の歪みのために、次回の圧縮符
号化において得られる予測誤差データは、前回の圧縮符
号化の際に得られた予測誤差データと同一にはならな
い。従って、次回、入力映像データのBピクチャーまた
はPピクチャーを前回と同じピクチャータイプに圧縮符
号化しても、バックサーチ処理において、DCT係数の
剰余の総和が顕著に小さい値になる極小点が見つかる確
率は非常に低い。
Similarly, when a B-picture (P-picture) of input video data is compression-encoded again into the same B-picture (P-picture) and a back search process is performed, the motion obtained by the previous compression-encoding is also obtained. The vector and the motion vector obtained from the video distorted by the next compression encoding are not the same, and because of the distortion of the video by the previous compression encoding and decompression decoding, in the next compression encoding, The obtained prediction error data is not the same as the prediction error data obtained in the previous compression encoding. Therefore, even if the B picture or P picture of the input video data is compressed and coded to the same picture type as the previous time, the probability of finding a minimum point at which the sum of the remainder of the DCT coefficient becomes a remarkably small value in the back search processing is small. Very low.

【0066】以上説明したピクチャータイプごとのバッ
クサーチ処理における性質を利用すると、入力映像デー
タのピクチャーが、前回、イントラ符号化されたもので
あるか否かを、バックサーチ処理においてDCT係数の
顕著な極小値を生じるか否かに基づいて自動的に検出す
ることができる。
By utilizing the above-described nature of the back search processing for each picture type, it is determined whether or not the picture of the input video data has been previously intra-coded by the DCT coefficient in the back search processing. It can be automatically detected based on whether or not a local minimum occurs.

【0067】バックサーチ部248は、DCT係数の剰
余の総和に顕著な極小値が存在するか否か、例えば、予
測部246から入力された量子化インデックスが示す量
子化ステップでDCT係数を除算した場合の剰余の総和
に対して、バックサーチ部248におけるバックサーチ
処理により求められたDCT係数の剰余の総和の比率
が、ある一定の閾値以下になるか否かを判断することに
より、エンコーダ2が入力映像データのIピクチャーを
イントラ符号化したか否かを判断することができる。
The back search unit 248 divides the DCT coefficient by a quantization step indicated by the quantization index input from the prediction unit 246 to determine whether or not there is a remarkable minimum value in the sum of the remainder of the DCT coefficient. The encoder 2 determines whether the ratio of the sum of the remainders of the DCT coefficients obtained by the back search processing in the back search unit 248 to the sum of the remainders in the case becomes equal to or smaller than a certain threshold. It can be determined whether or not the I picture of the input video data has been intra-coded.

【0068】このように、バックサーチ部248は、入
力映像データのIピクチャーの位置を検出することによ
り、入力映像データのIピクチャーの間隔(GOPに含
まれるピクチャーの数N)を判定することができ、判定
結果をピクチャータイプ制御部250に通知する。
As described above, the back search unit 248 detects the position of the I picture of the input video data, thereby determining the interval between the I pictures of the input video data (the number N of pictures included in the GOP). Yes, the determination result is notified to the picture type control unit 250.

【0069】ピクチャータイプ制御部250は、求めた
Iピクチャーの間隔と、映像データ処理システム1のエ
ンコーダ2a,2bおよびデコーダ4a,4bが用いる
GOPの構成(GOP内にいずれのピクチャータイプが
どのような順番で含まれるか;GOPシーケンス)とに
基づいて、GOP内のPピクチャーの間隔(M)を判定
することができ、さらに、入力映像データの各ピクチャ
ーが、前回、いずれのピクチャータイプに圧縮符号化さ
れたかを判定することができる。
The picture type control unit 250 determines the interval between the obtained I pictures and the configuration of the GOP used by the encoders 2a and 2b and the decoders 4a and 4b of the video data processing system 1 (what kind of picture type is included in the GOP). (GOP sequence), the interval (M) between P pictures in the GOP can be determined. Furthermore, each picture of the input video data Can be determined.

【0070】ピクチャータイプ制御部250は、以上説
明したように判定した入力映像データが前回の圧縮符号
化においていずれのピクチャータイプに圧縮符号化され
たかを示す情報に基づいて、入力映像データの各ピクチ
ャーが前回と同じピクチャータイプに圧縮符号化され、
前回の圧縮符号化と次回の圧縮符号化におけるGOP位
相が保たれるようにピクチャー並べ替え部200を制御
し、ピクチャーの並び替えを行わせる。
The picture type control section 250 controls each picture of the input video data based on the information indicating which picture type the input video data determined as described above was compression-coded in the previous compression coding. Is compressed and encoded to the same picture type as last time,
The picture rearranging unit 200 is controlled so that the GOP phase in the previous compression encoding and the next compression encoding is maintained, and the pictures are rearranged.

【0071】エンコーダ2の動作 以下、図3をさらに参照して図1および図2に示したエ
ンコーダ2(図1,図2)の動作を説明する。圧縮制御
部24の動き補償部240は、圧縮符号化部20のピク
チャー並べ替え部200および走査変換ブロック化部2
02が処理した映像データを動き補償する。減算回路2
42は、Iピクチャーの映像データ、および、Pピクチ
ャーまたはBピクチャーの予測誤差データを生成する。
DCT部244は、Iピクチャーの映像データ、およ
び、PピクチャーまたはBピクチャーの予測誤差データ
をDCT変換し、DCT係数を生成する。
Operation of Encoder 2 The operation of the encoder 2 (FIGS. 1 and 2) shown in FIGS. 1 and 2 will be described with further reference to FIG. The motion compensation unit 240 of the compression control unit 24 includes the picture rearranging unit 200 and the scan conversion blocking unit 2 of the compression encoding unit 20.
02 performs motion compensation on the processed video data. Subtraction circuit 2
Reference numeral 42 generates video data of an I picture and prediction error data of a P picture or a B picture.
The DCT unit 244 performs DCT transform on the video data of the I picture and the prediction error data of the P picture or the B picture, and generates DCT coefficients.

【0072】予測部246は、例えば、1GOP分の圧
縮映像データを生成する時間を単位期間として、この単
位期間ごとに固定値の量子化ステップ(fix-q) でDCT
部244から入力されたDCT係数を量子化して量子化
データを生成し、その発生符号量に基づいて、入力映像
データの難度を見積もり、さらに、量子化インデックス
を単位期間ごとに算出する。
The prediction unit 246 sets the time for generating compressed video data for one GOP as a unit period, and performs a DCT by a fixed quantization step (fix-q) for each unit period.
The DCT coefficient input from the unit 244 is quantized to generate quantized data, the difficulty of the input video data is estimated based on the generated code amount, and a quantization index is calculated for each unit period.

【0073】バックサーチ部248は、予測部246が
生成した量子化インデックスと、DCT部244が生成
したDCT係数とに基づいて、前回の圧縮符号化におい
てイントラ符号化されたピクチャーを検出し、さらに、
バックサーチにより前回の圧縮符号化において用いられ
た量子化ステップを示す量子化インデックスを生成す
る。図3は、図1および図2に示したエンコーダ2(2
a,2b)のバックサーチ部248およびピクチャータ
イプ制御部250の処理内容、つまり、いかにイントラ
符号化する入力映像データのピクチャーを指定するかを
例示するフローチャート図である。
The back search section 248 detects a picture that has been intra-coded in the previous compression coding based on the quantization index generated by the prediction section 246 and the DCT coefficient generated by the DCT section 244. ,
A back search generates a quantization index indicating the quantization step used in the previous compression encoding. FIG. 3 shows the encoder 2 (2) shown in FIG. 1 and FIG.
FIGS. 7A and 7B are flowcharts illustrating the processing contents of the back search unit 248 and the picture type control unit 250 in a) and 2b), that is, how to specify a picture of input video data to be intra-coded.

【0074】図3に示すように、ステップ100(S1
00)において、バックサーチ部248は、変数jを初
期値1とする。ステップ102(S102)において、
バックサーチ部248は、圧縮符号化部20の動き補償
部240、減算回路242およびDCT部244が入力
映像データの第j番目のピクチャーを圧縮処理した結果
として得られたDCT係数に対してバックサーチ処理を
行い、DCT係数の剰余の総和Rmin,j と、予測部24
6が得た量子化ステップ(その前の量子化ステップ)に
よるDCT係数の剰余の総和Rj とを記憶する。
As shown in FIG. 3, step 100 (S1
In (00), the back search unit 248 sets the variable j to the initial value 1. In step 102 (S102),
The back search unit 248 performs a back search on the DCT coefficient obtained as a result of the motion compensation unit 240, the subtraction circuit 242, and the DCT unit 244 of the compression encoding unit 20 compressing the j-th picture of the input video data. The processing is performed, and the sum R min, j of the remainder of the DCT coefficients and the prediction unit 24
Quantization step 6 was obtained stores the sum R j remainder of the DCT coefficients by (the previous quantization step).

【0075】ステップ104(S104)において、バ
ックサーチ部248は、変数jと、それまでに求めたG
OPのピクチャー数Nとを比較し、変数jがピクチャー
数Nより大きい場合にはS108の処理に進み、変数j
がピクチャー数N以下である場合にはS106の処理に
進む。ステップ106(S106)において、バックサ
ーチ部248は、変数jに1を加算(インクリメント)
する。
In step 104 (S104), the back search unit 248 sets the variable j and the G
The number of pictures in the OP is compared with the number N of pictures. If the variable j is larger than the number N of pictures, the process proceeds to S108 and the variable j
Is less than or equal to the number N of pictures, the process proceeds to S106. In step 106 (S106), the back search unit 248 adds 1 to the variable j (increment)
I do.

【0076】S100〜S106の処理が構成するルー
プ処理において、バックサーチ部248は、N枚(1G
OP分)のピクチャーについて、バックサーチ処理によ
り得られるDCT係数の剰余の総和Rsub,j と、予測部
246が固定値の量子化ステップでDCT係数を量子化
することにより、あるいは、バイナリサーチにより得た
量子化ステップで量子化したときの剰余総和Rj とを保
存する処理を行う。
In the loop processing composed of the processing of S100 to S106, the back search unit 248 sets N (1G
OP), the prediction unit 246 quantizes the DCT coefficient by a fixed-value quantization step, or the binary search using the sum R sub, j of the remainder of the DCT coefficient obtained by the back search process. the resulting quantization step carries out a process of storing the remainder sum R j when the quantized by.

【0077】ステップ108(S108)において、バ
ックサーチ部248は、予測部246が得た量子化ステ
ップにより得られる剰余総和Rj に対する、S100〜
S106の処理が構成するループ処理により得られたN
個の剰余総和Rsub,j の比率(Rmin,j /Rj )の最小
値〔min(Rmin,j /Rj )〕と、所定の閾値Thと
を比較する。
In step 108 (S 108), the back search unit 248 calculates the residual sum R j obtained by the quantization step obtained by the prediction unit 246 from S 100 to S 100.
N obtained by the loop processing constituted by the processing of S106
The minimum value [min ( Rmin, j / Rj )] of the ratio ( Rmin, j / Rj ) of the remainder sum Rsub, j is compared with a predetermined threshold Th.

【0078】バックサーチ部248は、最小値〔min
(Rmin,j /Rj )〕が閾値Th以上である場合には、
入力映像データが1度も圧縮符号化を経ていないオリジ
ナルの映像データであると判断してS100の処理に進
み、最小値〔min(Rmin,j /Rj )〕が閾値Th未
満である場合には、入力映像データが既に圧縮符号化を
経ている(ダビング後の)映像データであると判断して
S110の処理に進む。
The back search unit 248 calculates the minimum value [min
(R min, j / R j )] is equal to or greater than the threshold Th,
When it is determined that the input video data is the original video data that has never undergone compression encoding, the process proceeds to S100, and when the minimum value [min (R min, j / R j )] is less than the threshold value Th In, it is determined that the input video data is video data that has already undergone compression encoding (after dubbing), and the process proceeds to S110.

【0079】ステップ110(S110)において、バ
ックサーチ部248は、S108の処理において、最小
値〔min(Rmin,j /Rj )〕を与える第jmin 番目
のピクチャーを入力映像データのIピクチャーと判断
し、ピクチャータイプ制御部250に対して通知する。
ステップ112(S112)において、ピクチャータイ
プ制御部250は、第jmin 番目のピクチャーが、GO
Pの第1番目のピクチャーであるか否かを判断し、第j
min 番目のピクチャーがGOPの第1番目のピクチャー
である場合にはS100の処理に進み、第jmin 番目の
ピクチャーがGOPの第1番目のピクチャーでない場合
にはS114の処理に進む。
In step 110 (S110), the back search unit 248 sets the j min- th picture giving the minimum value [min (R min, j / R j )] to the I picture of the input video data in the processing of S108. And notifies the picture type control unit 250.
In step 112 (S112), the picture type control unit 250, the first j min th picture, GO
Judge whether the picture is the first picture of P, and j
If the min- th picture is the first picture of the GOP, the process proceeds to S100. If the j-th min- th picture is not the first picture of the GOP, the process proceeds to S114.

【0080】S112の処理において、第jmin 番目の
ピクチャーがGOPの第1番目のピクチャーであるとい
うことは、現在のバックサーチ処理の対象となっている
GOPの位相(構成)が、の前回のバックサーチ処理の
対象となっていたGOPの位相(構成)と同じであるこ
とを意味するので、ピクチャータイプ制御部250は、
GOPの位相の変更を要さない。
In the processing of S112, the fact that the j min- th picture is the first picture of the GOP means that the phase (configuration) of the GOP currently subjected to the back search processing is the previous one. Since this means that the phase (configuration) of the GOP targeted for the back search process is the same, the picture type control unit 250
There is no need to change the phase of the GOP.

【0081】反対に、S112の処理において、第j
min 番目のピクチャーがGOPの第1番目のピクチャー
でないということは、バックサーチ部248の現在の処
理の対象となっているGOPの位相(構成)が、バック
サーチ部248の前回の処理の対象となっていたGOP
の位相(構成)と異なっていることを意味するので、ピ
クチャータイプ制御部250は、GOPの位相の変更を
要する。
On the other hand, in the processing of S112, the j-th
The fact that the min- th picture is not the first picture of the GOP means that the phase (configuration) of the GOP currently being processed by the back search unit 248 is the same as that of the previous processing by the back search unit 248. GOP which had become
Therefore, the picture type control unit 250 needs to change the phase of the GOP.

【0082】ステップ114(S114)において、ピ
クチャータイプ制御部250は、第N+jmin 番目の入
力映像データのピクチャーをイントラ符号化するよう
に、ピクチャーの並び替えの順番を変更するようにピク
チャー並べ替え部200を制御する。ステップ116
(S116)において、ピクチャータイプ制御部250
は、変数jに数値jmin を代入し、S102の処理に進
む。
[0082] At step 114 (S114), the picture type control unit 250, the N + j min th input a picture of the video data so as to intra-picture reordering unit so as to change the order of the rearranged pictures 200 is controlled. Step 116
In (S116), the picture type control unit 250
Substitutes the numerical value j min for the variable j, and proceeds to the process of S102.

【0083】圧縮符号化部20のピクチャー並べ替え部
200は、以上説明したピクチャータイプ制御部250
の制御に従って、入力映像データのピクチャーの順番を
並び替える。走査変換ブロック化部202は、映像デー
タをフィールド/フレーム変換し、さらにマクロブロッ
ク化する。
The picture rearranging section 200 of the compression encoding section 20 includes the picture type control section 250 described above.
In the order of the picture of the input video data. The scan conversion blocking unit 202 performs field / frame conversion on the video data and further converts the video data into macroblocks.

【0084】動き検出部204は、映像データをマクロ
ブロック単位に処理してその動きを検出し、映像の動き
を示す動きベクトルを生成する。FIFO206は、映
像データをバッファリングし、所定の時間遅延を与え
る。減算回路207は、圧縮符号化後にPピクチャーま
たはBピクチャーとなるピクチャーの予測誤差データを
生成する。
The motion detecting section 204 processes the video data on a macroblock basis, detects the motion, and generates a motion vector indicating the motion of the video. The FIFO 206 buffers the video data and gives a predetermined time delay. The subtraction circuit 207 generates prediction error data of a picture that becomes a P picture or a B picture after compression encoding.

【0085】DCT部208は、圧縮符号化後にIピク
チャーとなる映像データ、および、Pピクチャーまたは
Bピクチャーとなる映像データの予測誤差データをDC
T処理し、DCT係数を生成する。量子化部210は、
圧縮制御部24のバックサーチ部248が生成した量子
化インデックスが示す量子化ステップで、DCT部20
8から入力されたDCT係数を量子化し、量子化データ
を生成する。可変長符号化部212は、量子化部210
から入力される量子化データを可変長符号化し、出力映
像データ(stream out)として出力する。
The DCT section 208 converts the prediction error data of the I-picture video data and the P-picture or B-picture video data after compression encoding into DC data.
T processing is performed to generate DCT coefficients. The quantization unit 210
In the quantization step indicated by the quantization index generated by the back search unit 248 of the compression control unit 24, the DCT unit 20
8 to quantize the DCT coefficient input thereto, and generate quantized data. The variable-length coding unit 212 includes a quantization unit 210
, Performs variable-length encoding on the quantized data input from, and outputs it as output video data (stream out).

【0086】逆量子化部214は、量子化データを逆量
子化処理してDCT係数を再生する。逆DCT部216
は、再生されたDCT係数を逆DCT処理して映像デー
タを再生する。加算回路218は、逆DCT部216か
ら入力される映像データと、動き補償部222から入力
される映像データとを加算する。
The inverse quantization unit 214 performs an inverse quantization process on the quantized data to reproduce DCT coefficients. Inverse DCT section 216
Reproduces video data by performing inverse DCT processing on the reproduced DCT coefficients. The addition circuit 218 adds the video data input from the inverse DCT unit 216 and the video data input from the motion compensation unit 222.

【0087】FIFO220は、動き検出部204から
入力される動きベクトルをバッファリングし、所定の時
間遅延を与える。動き補償部222は、加算回路218
から入力される映像データに対して、FIFO220か
ら入力される動きベクトルを用いた動き補償処理を行
う。
The FIFO 220 buffers the motion vector input from the motion detector 204 and gives a predetermined time delay. The motion compensator 222 includes an adder 218
Is subjected to a motion compensation process using the motion vector input from the FIFO 220 to the video data input from the.

【0088】変形例 以下、図4を参照して、第1の実施形態の変形例を説明
する。エンコーダ2(図1,図2)は、圧縮符号化部2
0の量子化部210に設定する量子化インデックスを求
めるバックサーチ処理を行う際に、前回の圧縮符号化の
際のピクチャータイプを検出し、ピクチャー並べ替え部
200のピクチャーの並び替え処理を制御するように構
成されているので、遅延量が多く、しかも、ピクチャー
並べ替え部200におけるピクチャーの並び替えの順番
を迅速に変更することができない。
Modified Example Hereinafter, a modified example of the first embodiment will be described with reference to FIG. The encoder 2 (FIGS. 1 and 2) includes a compression encoding unit 2
When performing a back search process for obtaining a quantization index to be set in the quantization unit 210 of 0, the picture type in the previous compression encoding is detected, and the picture rearrangement process of the picture rearrangement unit 200 is controlled. With such a configuration, the amount of delay is large, and the order of rearranging pictures in the picture rearranging section 200 cannot be changed quickly.

【0089】しかしながら、バックサーチ処理により、
DCT係数の剰余総和の極小点を見つけるためには、必
ずしもピクチャーの全てのDCT係数の剰余総和を算出
する必要はなく、ピクチャー中のいくつかのマクロブロ
ックを抽出して、剰余総和の極小点が存在するか否かを
調べれば充分である。
However, by the back search process,
In order to find the minimum point of the residual sum of the DCT coefficients, it is not always necessary to calculate the residual sum of all the DCT coefficients of the picture; some macroblocks in the picture are extracted and the minimum point of the residual sum is calculated. It is sufficient to check for its presence.

【0090】以下に説明する第1の実施形態に示したエ
ンコーダ2の変形例(エンコーダ5)は、このような点
に着目し、エンコーダ2の処理速度を改善するのために
なされたものであり、量子化インデックスを生成する機
能と、GOPの位相を検出する機能とを分離し、予めG
OP位相を検出してから入力映像データを圧縮符号化す
るように構成されている。
A modified example (encoder 5) of the encoder 2 shown in the first embodiment described below focuses on such a point and is made to improve the processing speed of the encoder 2. , The function of generating the quantization index and the function of detecting the phase of the GOP
The input video data is compressed and coded after detecting the OP phase.

【0091】図4は、第1の実施形態の変形例のエンコ
ーダ5の構成を示す図である。なお、図4においては、
エンコーダ5の構成部分の内、エンコーダ2と同一のも
のには図2と同じ符号が付してある。図4に示すよう
に、エンコーダ5は、圧縮符号化部20と圧縮制御部2
6から構成される。圧縮制御部26は、圧縮制御部24
(図2)にGOP位相制御部28を付加した構成を採
る。GOP位相制御部28は、ブロック抽出部280、
DCT部282、予測部284およびバックサーチ部2
86から構成される。
FIG. 4 is a diagram showing a configuration of an encoder 5 according to a modification of the first embodiment. In FIG. 4,
Among the components of the encoder 5, the same components as those of the encoder 2 are denoted by the same reference numerals as in FIG. As shown in FIG. 4, the encoder 5 includes a compression encoder 20 and a compression controller 2
6 is comprised. The compression control unit 26 includes the compression control unit 24
A configuration in which a GOP phase control unit 28 is added to FIG. 2 is adopted. The GOP phase control unit 28 includes a block extraction unit 280,
DCT section 282, prediction section 284, and back search section 2
86.

【0092】圧縮制御部26のGOP位相制御部28に
おいて、ブロック抽出部280は、入力映像データの各
ピクチャーから数ブロック分の映像データを抽出し、D
CT部282に対して出力する。DCT部282は、ブ
ロック抽出部280から入力された数ブロック分の映像
データをDCT処理し、DCT処理により得られたDC
T係数を予測部284に対して出力する。
In the GOP phase control unit 28 of the compression control unit 26, the block extraction unit 280 extracts several blocks of video data from each picture of the input video data, and
Output to the CT unit 282. The DCT unit 282 performs DCT processing on video data of several blocks input from the block extraction unit 280, and obtains a DCT obtained by the DCT processing.
The T coefficient is output to the prediction unit 284.

【0093】予測部284は、圧縮制御部24の予測部
246と同様に、単位期間ごとに固定値の量子化ステッ
プ(fix-q) またはバイナリサーチにより入力映像データ
の絵柄の難しさを見積もり、実際に用いるべき量子化ス
テップを示す量子化インデックスを単位期間ごとに算出
してバックサーチ部286に対して出力する。
The prediction unit 284, like the prediction unit 246 of the compression control unit 24, estimates the difficulty of the picture of the input video data by a fixed value quantization step (fix-q) or binary search for each unit period. A quantization index indicating a quantization step to be actually used is calculated for each unit period and output to the back search unit 286.

【0094】バックサーチ部286は、エンコーダ2に
おける圧縮制御部24のバックサーチ部248と同様
に、予測部284から入力される量子化インデックス、
および、DCT部282から予測部284を介して入力
されるDCT係数を用いてバックサーチ処理を行い、入
力映像データのGOP位相(Iピクチャー)を検出し、
ピクチャータイプ制御部250に通知する。ピクチャー
タイプ制御部250は、エンコーダ2においてと同様
に、バックサーチ部286から入力されるIピクチャー
の位置を示す情報に従って、圧縮符号化部20のピクチ
ャー並べ替え部200の処理を制御する。
[0094] The back search section 286, like the back search section 248 of the compression control section 24 in the encoder 2, has the quantization index input from the prediction section 284,
Also, a back search process is performed using the DCT coefficient input from the DCT unit 282 via the prediction unit 284, and the GOP phase (I picture) of the input video data is detected.
The picture type control unit 250 is notified. The picture type control unit 250 controls the processing of the picture rearranging unit 200 of the compression encoding unit 20 according to the information indicating the position of the I picture input from the back search unit 286, as in the encoder 2.

【0095】なお、エンコーダ2と異なり、エンコーダ
5においては、GOP位相の検出(Iピクチャーの検
出)に先立つ動き補償は行なわれないので、GOP位相
制御部28のバックサーチ部286は、入力映像データ
の全てのピクチャーに対してイントラ符号化して得られ
たDCT係数に対してバックサーチ処理を行うことにな
る。従って、結果的に、GOP位相制御部28による入
力映像データが既に圧縮符号化を経ているか否かの判定
は非常に簡単になる。
Note that, unlike the encoder 2, the encoder 5 does not perform motion compensation prior to GOP phase detection (I-picture detection), so the back search unit 286 of the GOP phase control unit 28 The back search process is performed on the DCT coefficients obtained by intra-encoding all the pictures. Therefore, as a result, it is very easy for the GOP phase control unit 28 to determine whether or not the input video data has already been subjected to compression encoding.

【0096】また、図1および図2に示したエンコーダ
2(2a,2b)の各構成部分は、同一の機能および性
能を実現可能である限り、ソフトウェア的に構成される
かハードウェア的に構成されるかを問わない。また、エ
ンコーダ2の各構成部分は、同一の機能および性能を実
現可能な他の装置に置換可能である。また、エンコーダ
2は、適切な変形を加えることにより、映像データの
他、例えば、音声データといった冗長性を有する他の種
類のデータの圧縮符号化に応用することができる。
Each component of the encoder 2 (2a, 2b) shown in FIG. 1 and FIG. 2 is configured by software or hardware as long as the same function and performance can be realized. It does not matter. Further, each component of the encoder 2 can be replaced with another device that can realize the same function and performance. The encoder 2 can be applied to compression encoding of other types of data having redundancy, such as audio data, in addition to video data, by appropriately modifying the encoder.

【0097】効果 以上説明したように、エンコーダ2,5によれば、前回
の圧縮符号化と同じGOP位相を保って次回の圧縮符号
化を行うことができ、図1に示した映像データ処理シス
テム1における映像の品質の劣化を防ぐことができる。
また、エンコーダ2,5においては、ピクチャータイプ
情報が失われた場合、あるいは、1度も圧縮符号化を経
ていないオリジナルの映像データが入力された場合に、
圧縮映像データとピクチャータイプを示す情報とを多重
化し、ピクチャータイプ情報に基づいて次回の圧縮符号
化を行う従来の方法において生じていた誤動作等の不具
合は発生しない。
[0097] As the effect described above, according to the encoder 2 and 5, it is possible to perform the next compression encoding while maintaining the same GOP phase the previous compression-encoded, the video data processing system shown in FIG. 1 1 can be prevented from deteriorating the image quality.
In the encoders 2 and 5, when picture type information is lost, or when original video data that has never undergone compression encoding is input,
The compressed video data and the information indicating the picture type are multiplexed, and a malfunction such as a malfunction that occurs in the conventional method of performing the next compression encoding based on the picture type information does not occur.

【0098】また、エンコーダ2,5においては、例え
ば、圧縮映像データをアナログ映像信号に戻し、再度、
ディジタル圧縮映像データとして記録等を行う場合に
も、アナログ映像データに戻す前の圧縮映像データと同
じGOP位相で圧縮符号化を行うことができ、映像の品
質の劣化を防ぐことができる。また、エンコーダ5は、
ピクチャーの一部のマクロブロックを用いてGOP位相
を検出するので、エンコーダ2に比べて大幅に装置規模
が増大することがない。また、エンコーダ5によると、
GOP位相を検出するために要する処理時間が短縮され
るので、エンコーダ2に比べて遅延時間を短縮すること
ができる。
In the encoders 2 and 5, for example, the compressed video data is returned to an analog video signal, and
Even when recording as digital compressed video data, compression encoding can be performed at the same GOP phase as the compressed video data before returning to analog video data, and deterioration of video quality can be prevented. Also, the encoder 5
Since the GOP phase is detected by using a part of macroblocks of the picture, the device scale does not greatly increase as compared with the encoder 2. Also, according to the encoder 5,
Since the processing time required for detecting the GOP phase is reduced, the delay time can be reduced as compared with the encoder 2.

【0099】第2実施形態 以下、本発明の第2の実施形態を説明する。 Second Embodiment Hereinafter, a second embodiment of the present invention will be described.

【0100】第2の実施形態の背景 MPEG2方式等のMC−DCT方式等の圧縮符号化技
術を、映像データの放送、通信あるいは伝送に用いる場
合には、圧縮符号化して得られる圧縮映像データのデー
タ量(発生符号量)を伝送路の伝送容量以下に押さえ込
むためには、MPEG方式のTM5等に代表されるよう
に、通常、フィードバックによる量子化ステップの制御
が行なわれる。
Background of the Second Embodiment When the compression coding technique such as the MC-DCT method such as the MPEG2 method is used for broadcasting, communication or transmission of video data, the compression coding technique of the compressed video data obtained by the compression coding is used. In order to suppress the amount of data (the amount of generated code) to be equal to or less than the transmission capacity of the transmission path, the quantization step is usually controlled by feedback, as represented by TM5 of the MPEG system.

【0101】このフィードバックによる量子化ステップ
の制御は、過去の量子化ステップ(量子化インデック
ス)と、この量子化ステップに対応する発生符号量との
関係により、その時点のバッファ残量に適合する量子化
ステップ(量子化インデックス)を動的(ダイナミッ
ク)に調節することにより行われる。
The control of the quantization step based on the feedback is performed by controlling the quantization step suitable for the buffer remaining amount at that time based on the relationship between the past quantization step (quantization index) and the generated code amount corresponding to the quantization step. This is performed by dynamically adjusting the quantization step (quantization index).

【0102】しかしながら、このフィードバック制御方
式は、長い時間で見たときは所望のデータレートに符号
発生量を抑え込むことができるものの、瞬間的に見る
と、発生符号量の増大を招くことがある。従って、テレ
ビジョン放送業務用デジタルVTR装置あるいは録再型
ディスク装置への応用を考えると、例えばインサート編
集、可変速再生あるいは記録エラーのコンシール(conce
al) に対応できるように、ある単位期間ごとに、発生符
号量が必ず目標符号量となるように発生符号量を制御
し、VTRテープあるいはMOディスク等のディスク記
録媒体の特定の場所に記録するという制御がさらに必要
になる。
However, this feedback control method can suppress the amount of code generation to a desired data rate when viewed in a long time, but may increase the generated code amount when viewed instantaneously. Therefore, in consideration of application to a digital VTR device for a television broadcasting business or a recording / reproducing disk device, for example, concealment of insert editing, variable speed reproduction or recording error is considered.
al), the generated code amount is controlled in each unit period so that the generated code amount always reaches the target code amount, and is recorded in a specific location on a disk recording medium such as a VTR tape or MO disk. That control is further required.

【0103】また、高い映像の品質が要求されるテレビ
ジョン放送局用においては、タンデム接続したエンコー
ダおよびデコーダ(コーデック)により圧縮符号化およ
び伸長復号を繰り返した場合の映像の品質の劣化防止も
厳しく要求される。
For television broadcasting stations requiring high video quality, it is also strictly required to prevent deterioration of video quality when compression encoding and decompression decoding are repeated by tandem-connected encoders and decoders (codecs). Required.

【0104】従って、映像データ処理システム1(図
1)等において圧縮符号化および伸長復号を繰り返す場
合には、各圧縮符号化処理における量子化ステップを同
じにするために、例えば、エンコーダ2,5(図1,図
2,図4)のバックサーチ部248によるバックサーチ
処理が用いられる。
Therefore, when the compression encoding and decompression decoding are repeated in the video data processing system 1 (FIG. 1) and the like, the encoders 2 and 5 are used to make the quantization steps in each compression encoding process the same. The back search processing by the back search unit 248 of FIGS. 1, 2, and 4 is used.

【0105】しかしながら、エンコーダ2,5のバック
サーチ部248のバックサーチ処理においては、DCT
係数の剰余総和の中に、所定の閾値を超える割合の著し
い極小点が存在するか否かに基づいて、前回の圧縮符号
化において用いられた量子化ステップを検出する方法が
採られるため、この閾値を小さく設定しすぎると、本
来、DCT係数の剰余総和の極小点が存在しない、一度
の圧縮符号化も経ていないオリジナル映像データのピク
チャーのいくつかのマクロブロックから、DCT係数の
剰余総和の極小点が誤って検出される可能性がある。
However, in the back search processing of the back search unit 248 of the encoders 2 and 5, the DCT
Since a method of detecting the quantization step used in the previous compression encoding based on whether or not there is a remarkable minimum point having a ratio exceeding a predetermined threshold value in the residual sum of the coefficients is adopted, If the threshold value is set too small, the minimum sum of the remainder of the DCT coefficients is reduced from some macroblocks of the picture of the original video data which have not undergone a single compression encoding, since there is no minimum point of the remainder sum of the DCT coefficients. Points may be detected incorrectly.

【0106】バックサーチ部248がDCT係数の剰余
総和を誤って検出し、誤って生成した量子化ステップ
(量子化インデックス)に基づいて圧縮符号化部20の
量子化部210が量子化を行うと、最適な量子化ステッ
プよりも大きい値でDCT係数を量子化してしまい、結
果として映像の品質が大きく劣化してしまう可能性があ
る。
When the back search unit 248 erroneously detects the remainder sum of DCT coefficients and the quantization unit 210 of the compression encoding unit 20 performs quantization based on the erroneously generated quantization step (quantization index). However, there is a possibility that the DCT coefficient is quantized with a value larger than the optimal quantization step, and as a result, the quality of the image is largely deteriorated.

【0107】また逆に、DCT係数の剰余総和の検出に
用いる閾値を過度に大きく設定すると、既に圧縮符号化
を経ている映像データが入力されても、ピクチャー内の
いくつかのマクロブロックではDCT係数の剰余総和の
極小点を検出できない可能性がある。本来、検出される
べき極小点が検出できないと、前回の圧縮符号化にいて
と異なる量子化ステップで、次回の圧縮符号化における
量子化処理が行われ、映像の品質が大きく劣化してしま
う。これらの観点から、DCT係数の剰余総和の検出に
用いる閾値を適切に選択する必要があるが、以上のよう
な不具合の解決は難しく、さらに、入力映像データの絵
柄によっては、以上の不具合が顕著に現れる可能性もあ
る。
Conversely, if the threshold value used for detecting the DCT coefficient remainder sum is set too large, even if video data that has already undergone compression encoding is input, some macroblocks in the picture may have DCT coefficients. May not be able to detect the minimum point of the remainder sum of Originally, if the minimum point to be detected cannot be detected, a quantization process in the next compression encoding is performed in a quantization step different from that in the previous compression encoding, and the quality of the video is greatly deteriorated. From these viewpoints, it is necessary to appropriately select the threshold value used for detecting the residual sum of the DCT coefficients, but it is difficult to solve the above-mentioned problems, and the above problems are remarkable depending on the pattern of the input video data. May also appear.

【0108】さらに、MPEG 4:2:2 Profile方
式を用いる装置には、例えば、GOPがIピクチャーお
よびBピクチャーの2フレーム構成となっているものが
あり、また、MP@ML方式を用いる装置には、GOP
が15フレーム構成を採ることが代表的である。
Further, as an apparatus using the MPEG 4: 2: 2 Profile system, for example, there is a system in which a GOP has a two-frame structure of an I picture and a B picture, and an apparatus using the MP @ ML system. Is a GOP
Typically employs a 15-frame configuration.

【0109】一方、複数フレーム構成のGOPを用いる
MC−DCT方式のエンコーダおよびデコーダにおいて
は、圧縮符号化の際に動き補償処理を行うピクチャータ
イプにおいて前回と同じ動きベクトルを再現することは
不可能であるため、次回の圧縮符号化における動きベク
トルおよび予測誤差の再現性が低く、結果として、前回
の圧縮符号化においてBピクチャーおよびPピクチャー
に圧縮符号化されたピクチャーのDCT係数の剰余総和
に顕著な極小点は存在しない。
On the other hand, in an MC-DCT encoder and decoder using a GOP having a plurality of frames, it is impossible to reproduce the same motion vector as the previous one in a picture type for which motion compensation processing is performed during compression encoding. Therefore, the reproducibility of the motion vector and the prediction error in the next compression encoding is low, and as a result, the residual sum of the DCT coefficients of the pictures compressed and encoded into the B picture and the P picture in the previous compression encoding is remarkable. There is no minimum point.

【0110】従って、バックサーチ部248において前
回の圧縮符号化においてイントラ符号化されたピクチャ
ーを検出するための閾値を用いてバックサーチ処理を行
っても、前回の圧縮符号化においてBピクチャーおよび
Pピクチャーに圧縮符号化されたピクチャーからは、D
CT係数の極小点を検出できない。第2の実施形態は、
このような不具合を解決し、ピクチャータイプの誤検出
を防ぐことができるバックサーチ処理をズムを実現し、
例えば、複数のディジタルVTR装置を接続して映像デ
ータを複写する際等の映像の品質劣化を防ぐことを目的
としている。
Therefore, even if the back search process is performed by the back search unit 248 using a threshold value for detecting a picture intra-coded in the previous compression encoding, the B picture and the P picture From a picture that has been compressed and encoded into
The minimum point of the CT coefficient cannot be detected. In the second embodiment,
To solve such a problem and realize a back search process that can prevent erroneous detection of picture type,
For example, an object of the present invention is to prevent deterioration of video quality when a plurality of digital VTR devices are connected to copy video data.

【0111】図5は、第2の実施形態における本発明に
係るエンコーダ6の構成を示す図である。なお、図5に
おいては、エンコーダ6の構成部分のうち、図2に示し
たエンコーダ2および図4に示したエンコーダ5の構成
部分と同じものには、同一の符号を付してある。
FIG. 5 is a diagram showing a configuration of the encoder 6 according to the present invention in the second embodiment. In FIG. 5, the same components as those of the encoder 2 shown in FIG. 2 and the encoder 5 shown in FIG. 4 among the components of the encoder 6 are denoted by the same reference numerals.

【0112】図5に示すように、エンコーダ6は、圧縮
符号化部20、圧縮制御部30およびビデオインデック
ス(video index;仮称)検出部32から構成され、圧縮
制御部30は、エンコーダ2,5(図1,図2,図4)
の圧縮制御部24にスイッチ(sw)回路300を付加した
構成を採る。なお、第2の実施形態において示すエンコ
ーダ6は、圧縮符号化において動き補償を行うように構
成されているが、動き補償処理は必須ではない。
As shown in FIG. 5, the encoder 6 comprises a compression encoding section 20, a compression control section 30, and a video index (temporary name) detection section 32. The compression control section 30 includes encoders 2, 5 (Fig. 1, Fig. 2, Fig. 4)
And a switch (sw) circuit 300 is added to the compression control unit 24 of FIG. Note that the encoder 6 shown in the second embodiment is configured to perform motion compensation in compression encoding, but the motion compensation processing is not essential.

【0113】エンコーダ6は、例えば、映像データ処理
システム1(図1)において、エンコーダ2,5の代わ
りに用いられ、エンコーダ2,5と同様に、入力映像デ
ータに含まれる各ピクチャーが前回、いずれのピクチャ
ータイプに圧縮符号化されたかを検出し、さらに、前回
と同じ量子化ステップでDCT係数を量子化し、圧縮符
号化を行う。
The encoder 6 is used, for example, in the video data processing system 1 (FIG. 1) in place of the encoders 2 and 5, and like the encoders 2 and 5, each picture contained in the input video data is Is detected, and the DCT coefficient is quantized in the same quantization step as in the previous time to perform compression encoding.

【0114】エンコーダ6におけるバックサーチ処理 エンコーダ6におけるバックサーチ処理は、バックサー
チアルゴリズムは、一度も圧縮符号化を経ていないオリ
ジナルの映像に対しては使用しないほうがよく、同じ圧
縮符号化方式を用いるエンコーダによる圧縮符号化を既
に経ている映像データに対してのみ適用することが好ま
しいという性質に着眼して変更されている。
Back search processing in the encoder 6 In the back search processing in the encoder 6, it is better not to use the back search algorithm for the original video that has never undergone compression encoding, and to use an encoder that uses the same compression encoding method. Has been changed with a view to the property that it is preferable to apply only to video data that has already undergone compression encoding according to.

【0115】つまり、第1の実施形態において示したエ
ンコーダ2,5においては、入力映像データの全てのピ
クチャーに対してバックサーチ処理を行い、オリジナル
の映像データにおいてはDCT係数の剰余総和に極小点
が見つからず、既に圧縮符号化を経た映像データにおい
てのみ剰余総和に極小点が見つかってバックサーチ処理
が有効となること期待しているが、この期待どおりとな
らない場合がある。
That is, in the encoders 2 and 5 shown in the first embodiment, the back search processing is performed on all the pictures of the input video data, and the minimum sum is added to the residual sum of the DCT coefficients in the original video data. Is not found, and it is expected that the minimum point will be found in the residual sum only in the video data that has already been subjected to the compression encoding, and that the back search processing will be effective. However, this may not be as expected.

【0116】そこで、第2の実施形態において示すエン
コーダ6は、ビデオインデックスを用いて、入力される
映像データのピクチャーが、既に圧縮符号化を経た映像
データかオリジナルの映像データかを識別し、オリジナ
ルの映像データ、および、前回、他の方式により圧縮符
号化された映像データであると識別された場合には、バ
ックサーチ処理を実行せず、逆に、前回、同じ方式によ
り圧縮符号化され、かつ、前回のGOP位相が次の圧縮
符号化におけるGOP移動と同じ場合にのみバックサー
チ処理を実行するように構成されている。
Therefore, the encoder 6 shown in the second embodiment uses the video index to identify whether the picture of the input video data is video data that has already undergone compression encoding or original video data, and If the video data, and the previous time, if it is identified that the video data is compression-encoded by another method, the back search process is not performed, conversely, the previous time, compression encoding by the same method, In addition, the back search process is performed only when the previous GOP phase is the same as the GOP movement in the next compression encoding.

【0117】前回の圧縮符号化方式の検出方法 次に、前回の圧縮符号化方式が、次回の圧縮符号化方式
と同じか否かを検出する方法を説明する。現在、SMP
TEにおいて、ビデオインデックスと呼ばれるエンコー
ド条件を示す情報を、デコーダ側で映像データに多重化
することが標準化されつつある。映像データに正しいビ
デオインデックスが多重化されているか否かを検出する
ことにより、エンコーダ6の入力部分において、入力映
像データが前回、同じ方式により圧縮符号化されたか否
か、および、次回の圧縮符号化におけるGOPの位相
(構造)と前回の圧縮符号化におけるGOPの位相とが
一致しているか否かを判定することができる。以下、映
像データ処理システム1において、デコーダ4a,4b
がビデオインデックスを映像データに多重化する場合に
ついて説明を行う。
[0117] Detection method of the previous compression coding method Next, the previous compression coding method, a method of detecting whether the same or not the next compression coding method. Currently, SMP
In TE, it is being standardized that information indicating an encoding condition called a video index is multiplexed on video data on a decoder side. By detecting whether or not the correct video index is multiplexed in the video data, the input portion of the encoder 6 determines whether or not the input video data has been compression-coded in the same manner in the previous time, and It is possible to determine whether or not the phase (structure) of the GOP in the encoding and the phase of the GOP in the previous compression encoding match. Hereinafter, in the video data processing system 1, the decoders 4a and 4b
Multiplexes a video index with video data.

【0118】ビデオインデックス検出部32の動作の概
以下、ビデオインデックス検出部32の動作の概要を説
明する。ビデオインデックス検出部32は、入力映像デ
ータに正しいビデオインデックス情報が多重化されてい
るか否かを監視し、入力映像データに正しいビデオイン
デックス情報が多重化されており、かつ、次回の圧縮符
号化におけるGOPの位相(構造)と前回の圧縮符号化
におけるGOPの位相とが一致している場合にのみ、次
回の圧縮符号化におけるGOPの位相(構造)と前回の
圧縮符号化におけるGOPの位相とが一致するようにピ
クチャータイプ制御部250を介してピクチャー並べ替
え部200の動作を制御し、さらに、スイッチ回路30
0を制御して入力端子bを選択させ、圧縮制御部24の
バックサーチ部248の処理により決定された量子化ス
テップ(量子化インデックス)を量子化部210に対し
て出力させる。
Overview of Operation of Video Index Detection Unit 32
In brief, an outline of the operation of the video index detection unit 32 will be described below. The video index detection unit 32 monitors whether or not the correct video index information is multiplexed on the input video data, and determines whether the correct video index information is multiplexed on the input video data, and Only when the phase (structure) of the GOP matches the phase of the GOP in the previous compression encoding, the phase (structure) of the GOP in the next compression encoding and the phase of the GOP in the previous compression encoding are changed. The operation of the picture rearranging unit 200 is controlled via the picture type control unit 250 so that they match with each other.
By controlling 0, the input terminal b is selected, and the quantization step (quantization index) determined by the processing of the back search unit 248 of the compression control unit 24 is output to the quantization unit 210.

【0119】また、ビデオインデックス検出部32は、
逆に、ビデオインデックスが入力映像データに全く多重
化されていなかったり、多重化されていても違う圧縮符
号化方式を示していたり、あるいは、同じ圧縮符号化方
式を示していても、編集作業等によりGOP位相が変更
されたりといったように、次回の圧縮符号化におけるG
OP位相で圧縮符号化を行わない方がよい場合に、スイ
ッチ回路300を制御して入力端子aを選択させ、予測
部246により固定量子化ステップあるいはバイナリー
サーチにより求められた量子化ステップ(インデック
ス)を量子化部210に対して出力させる。
The video index detecting section 32
Conversely, even if the video index is not multiplexed at all with the input video data, indicates a different compression coding method even if multiplexed, or indicates the same compression coding method, editing work etc. The GOP phase in the next compression encoding
If compression coding should not be performed in the OP phase, the switch circuit 300 is controlled to select the input terminal a, and the prediction unit 246 performs a fixed quantization step or a quantization step (index) obtained by a binary search. Is output to the quantization unit 210.

【0120】ビデオインデックス検出部32の動作の詳
以下、図7をさらに参照して、ビデオインデックス検出
部32の詳細な動作を説明する。図7は、図5に示した
エンコーダ6のビデオインデックス検出部32の動作を
例示するフローチャート図であって、ビデオインデック
ス検出部32が1ピクチャーの映像データを取り込んで
から、量子化インデックスを生成するまでが例示されて
いる。
Details of operation of video index detecting section 32
Fine below with further reference to FIG. 7, a detailed operation of video index detection unit 32. FIG. 7 is a flowchart illustrating the operation of the video index detection unit 32 of the encoder 6 shown in FIG. 5. The video index detection unit 32 captures video data of one picture and then generates a quantization index. Are exemplified.

【0121】図7に示すように、ステップ200(S2
00)において、エンコーダ6のビデオインデックス検
出部32は、次の入力映像データを1ピクチャー分取り
込む。ステップ202(S202)において、ビデオイ
ンデックス検出部32は、次の入力映像データが取り込
めたか否かを判断し、入力映像データが取り込めなかっ
た場合には処理を終了する。ステップ204(S20
4)において、ビデオインデックス検出部32は、入力
映像データのビデオインデックスが多重化されているべ
き位置のデータ(例えば3バイト)の全てを分離し、読
み出す。
As shown in FIG. 7, step 200 (S2
In (00), the video index detection unit 32 of the encoder 6 captures the next input video data for one picture. In step 202 (S202), the video index detection unit 32 determines whether or not the next input video data has been captured. If the input video data has not been captured, the process ends. Step 204 (S20
In 4), the video index detection unit 32 separates and reads out all data (for example, 3 bytes) at a position where the video index of the input video data is to be multiplexed.

【0122】ステップ206(S206)において、ビ
デオインデックス検出部32は、読み出した3バイトの
データに対してCRCチェックを行う。CRCチェック
の結果、3バイトのデータが正しい場合にはS208の
処理に進み、正しくない場合にはS216の処理に進
む。
In step 206 (S206), the video index detection unit 32 performs a CRC check on the read 3-byte data. As a result of the CRC check, if the 3-byte data is correct, the process proceeds to S208; otherwise, the process proceeds to S216.

【0123】ステップ208(S208)において、ビ
デオインデックス検出部32は、ビデオインデックスに
含まれるGOP構成、Pピクチャーの間隔(M)および
量子化方法(Q_type)を示すピクチャーごとの変
更がないデータに基づいて、次回(現在)の圧縮符号化
におけるこれらの条件と、前回の圧縮符号化におけるこ
れらの条件とが一致するか否かを判断する。一致する場
合にはS210の処理に進み、一致しない場合にはS2
16の処理に進む。
In step 208 (S208), the video index detecting unit 32 determines the GOP structure, the P picture interval (M) and the quantization method (Q_type) included in the video index based on the data having no change for each picture. Then, it is determined whether or not these conditions in the next (current) compression encoding match these conditions in the previous compression encoding. If they match, the process proceeds to S210; if they do not match, S2
Proceed to step 16.

【0124】ステップ210(S210)において、ビ
デオインデックス検出部32は、インデックスに含まれ
ているピクチャータイプ(picture type)およびフレーム
数(N;frame number)と、次回(現在)の圧縮符号化
において期待されるピクチャータイプおよびフレーム数
(N)とを比較し、これらが一致するか否かを判断す
る。一致する場合にはS212の処理に進み、一致しな
い場合にはS216の処理に進む。
In step 210 (S210), the video index detecting section 32 expects the picture type (picture type) and the number of frames (N; frame number) included in the index in the next (current) compression encoding. The picture type and the number of frames (N) are compared to determine whether or not they match. If they match, the process proceeds to S212, and if they do not match, the process proceeds to S216.

【0125】つまり、ビデオインデックス検出部32
は、ビデオインデックスに含まれるピクチャータイプを
示すデータおよびフレーム番号を示すデータと、期待さ
れているパターンとが一致する否かを調べる。例えば、
GOPがBピクチャーおよびIピクチャーそれぞれ1枚
ずつの2フレーム構成である場合には、表示順で、GO
Pの1枚目はBピクチャー、2枚目はIピクチャーとな
ることが期待される。
That is, the video index detecting section 32
Checks whether or not the data indicating the picture type and the data indicating the frame number included in the video index match the expected pattern. For example,
When the GOP has a two-frame configuration of one B picture and one I picture, GO
The first P is expected to be a B picture and the second P is expected to be an I picture.

【0126】従って、ビデオインデックス検出部32
は、ビデオインデックスデータに含まれるフレーム番号
を示すデータ(Frame No.) が1であって、かつ、ビデオ
インデックスデータに含まれるピクチャータイプを示す
データがBピクチャーである場合、および、ビデオイン
デックスデータに含まれるフレーム番号を示すデータ(F
rame No.) が2であって、かつ、ビデオインデックスデ
ータに含まれるピクチャータイプを示すデータがIピク
チャーである場合の2つの場合にのみビデオインデック
スが正しいと判断する。
Therefore, the video index detecting section 32
Is when the data (Frame No.) indicating the frame number included in the video index data is 1 and the data indicating the picture type included in the video index data is a B picture, and Data indicating the included frame number (F
It is determined that the video index is correct only in the two cases where the “rame No.” is 2 and the data indicating the picture type included in the video index data is an I picture.

【0127】ステップ212(S212)において、ビ
デオインデックス検出部32は、インデックスに含まれ
ているGOP位相を示す情報が、次回(現在)の圧縮符
号化におけるGOP位相と一致するか否かを判断する。
一致する場合にはS214の処理に進み、一致しない場
合にはS216の処理に進む。
In step 212 (S212), the video index detecting section 32 determines whether or not the information indicating the GOP phase included in the index matches the GOP phase in the next (current) compression encoding. .
If they match, the process proceeds to S214. If they do not match, the process proceeds to S216.

【0128】つまり、ビデオインデックス検出部32
は、次回(現在)の圧縮符号化におけるGOP位相と、
ビデオインデックスに含まれるGOP位相を示すデータ
とが一致している場合にのみ、バックサーチ部248が
生成した量子化インデックスを有効にする。
That is, the video index detecting section 32
Is the GOP phase in the next (current) compression encoding,
Only when the data indicating the GOP phase included in the video index matches, the quantization index generated by the back search unit 248 is validated.

【0129】ステップ214(S214)において、ビ
デオインデックス検出部32は、スイッチ回路300を
制御して入力端子b側を選択させ、圧縮符号化部20の
量子化部210にバックサーチ部248が生成した量子
化インデックスを出力させる。
In step 214 (S 214), the video index detection unit 32 controls the switch circuit 300 to select the input terminal b side, and the back search unit 248 generates the quantization unit 210 of the compression encoding unit 20. Output the quantization index.

【0130】つまり、ビデオインデックス検出部32
は、S202,S206〜S212の処理に示した全て
の条件が満たされた場合にのみ、バックサーチ部248
におけるバックサーチ処理を有効化し、S214の処理
においてスイッチ回路300を制御し、バックサーチ部
248が生成した量子化インデックスを量子化部210
に対して出力させる。
That is, the video index detecting section 32
Means that the back search unit 248 is used only when all the conditions shown in the processing of S202 and S206 to S212 are satisfied.
Is enabled, the switch circuit 300 is controlled in the process of S214, and the quantization index generated by the back search unit 248 is quantized by the quantization unit 210.
Output.

【0131】ステップ216(S216)において、ビ
デオインデックス検出部32は、スイッチ回路300に
入力端子a側を選択させ、量子化部210が、バックサ
ーチ部248が生成した量子化インデックスではなく、
予測部246が生成した量子化インデックスを用いて量
子化を行うように制御する〔フリーラン(free run)処
理〕。つまり、ビデオインデックス検出部32は、S2
02,S206〜S212の処理に示した条件のいずれ
かが満たされない場合には、バックサーチ部248にお
けるバックサーチ処理を無効化し、S216においてス
イッチ回路300を制御し、予測部246が生成した量
子化インデックスを量子化部210に対して出力させ
る。
In step 216 (S 216), the video index detecting section 32 causes the switch circuit 300 to select the input terminal “a”, and the quantizing section 210 makes a decision instead of the quantization index generated by the back search section 248.
Control is performed so that quantization is performed using the quantization index generated by the prediction unit 246 (free run processing). That is, the video index detection unit 32 determines that S2
02, if any of the conditions shown in the processing of S206 to S212 is not satisfied, the back search processing in the back search unit 248 is invalidated, the switch circuit 300 is controlled in S216, and the quantization generated by the prediction unit 246 is performed. The index is output to the quantization unit 210.

【0132】デコーダ4(4a,4b) 図6は、図1に示したデコーダ4(4a,4b)の構成
を示す図である。映像データ処理システム1(図1)に
おいて、エンコーダ2,5の代わりにエンコーダ6を用
いる場合、デコーダ4a,4bは、図6に示すように、
伸長復号部40に、ビデオインデックス多重化部414
を付加した構成を採る。
Decoder 4 (4a, 4b) FIG. 6 is a diagram showing the structure of the decoder 4 (4a, 4b) shown in FIG. When the encoder 6 is used instead of the encoders 2 and 5 in the video data processing system 1 (FIG. 1), the decoders 4a and 4b
A video index multiplexing unit 414 is added to the decompression decoding unit 40.
Is adopted.

【0133】伸長復号部40は、一般的な映像データ用
デコーダ装置と同様に、バッファメモリ(buffer)40
0、可変長復号部(VLD)402、逆量子化部40
4、逆DCT部406、動き補償部408、スイッチ回
路410、ピクチャー並べ替え部412およびピクチャ
ータイプ制御部416から構成される。
The decompression / decoding section 40 has a buffer memory (buffer) 40 in the same manner as a general video data decoder.
0, variable length decoding unit (VLD) 402, inverse quantization unit 40
4, an inverse DCT unit 406, a motion compensation unit 408, a switch circuit 410, a picture rearrangement unit 412, and a picture type control unit 416.

【0134】伸長復号部40は、エンコーダ2から入力
される圧縮映像データを伸長復号し、フルビットの映像
データを生成してビデオインデックス多重化部414に
対して出力する。ビデオインデックス多重化部414
は、ピクチャータイプ制御部416が検出した圧縮映像
データのGOPシーケンスに基づいて、前回の圧縮符号
化の方式およびGOP構成等を示すビデオインデックス
を生成し、ピクチャー並べ替え部412から入力される
映像データにビデオインデックスを付加し、エンコーダ
2に対して出力する。
The decompression decoding unit 40 decompresses and decodes the compressed video data input from the encoder 2, generates full-bit video data, and outputs it to the video index multiplexing unit 414. Video index multiplexing section 414
Generates a video index indicating the previous compression encoding method and the GOP configuration based on the GOP sequence of the compressed video data detected by the picture type control unit 416, and outputs the video index input from the picture rearranging unit 412. , And outputs the result to the encoder 2.

【0135】第2の実施形態における映像データ処理シ
ステム1の動作 以下、エンコーダ6(図5)およびデコーダ4(図6)
を用いた映像データ処理システム1(図1)の動作を説
明する。エンコーダ6(6a)は、入力される映像デー
タを圧縮符号化し、記録・伝送装置3aを介してデコー
ダ4(4a)に対して伝送する。デコーダ4aは、エン
コーダ6aから入力された圧縮映像データを伸長復号し
てフルビットの映像データを生成し、ビデオインデック
スデータを多重化して、記録・伝送装置3bを介してエ
ンコーダ6(6b)に伝送する。
The video data processing system according to the second embodiment
Following the operation of the stem 1 , the encoder 6 (FIG. 5) and the decoder 4 (FIG. 6)
The operation of the video data processing system 1 (FIG. 1) using the above will be described. The encoder 6 (6a) compresses and encodes the input video data and transmits it to the decoder 4 (4a) via the recording / transmission device 3a. The decoder 4a expands and decodes the compressed video data input from the encoder 6a to generate full-bit video data, multiplexes the video index data, and transmits the multiplexed video index data to the encoder 6 (6b) via the recording / transmission device 3b. I do.

【0136】エンコーダ6bにおいて、ビデオインデッ
クス検出部32(図5)は、ピクチャー1枚分の映像デ
ータが入力されるたびに、図7に示した処理を行い、入
力された映像データに多重化されたビデオインデックス
が正しいか否かを判断し、スイッチ回路300を制御し
て、圧縮符号化部20の量子化部210に、バックサー
チ部248が生成した量子化ステップ(量子化インデッ
クス)および予測部246が生成した量子化ステップ
(量子化インデックス)のいずれかを設定するととも
に、ピクチャータイプ制御部250を介して圧縮符号化
部20のピクチャー並べ替え部200を制御し、エンコ
ーダ6bにおける圧縮符号化に適した順番に入力映像デ
ータのピクチャーを並べ替えさせる。
In the encoder 6b, the video index detecting section 32 (FIG. 5) performs the processing shown in FIG. 7 every time video data of one picture is input, and multiplexes the video data with the input video data. It is determined whether or not the video index is correct, and the switch circuit 300 is controlled so that the quantization step (quantization index) generated by the back search section 248 and the prediction section 246 sets any of the quantization steps (quantization indexes) generated, controls the picture rearranging unit 200 of the compression encoding unit 20 via the picture type control unit 250, and performs compression encoding in the encoder 6b. The pictures of the input video data are rearranged in a suitable order.

【0137】圧縮符号化部20のピクチャー並べ替え部
200以降の各構成部分、および、圧縮制御部30は、
エンコーダ2,5と同様に入力映像データを圧縮符号化
し、記録・伝送装置3cを介してデコーダ4bに伝送す
る。
The components of the compression encoding unit 20 after the picture rearranging unit 200 and the compression control unit 30
Like the encoders 2 and 5, the input video data is compression-encoded and transmitted to the decoder 4b via the recording / transmission device 3c.

【0138】なお、エンコーダ6におけるように、ビデ
オインデックスに基づいて圧縮符号化部20のピクチャ
ー並べ替え部200を制御する場合、次回の圧縮符号化
時においても前回の圧縮符号化時のピクチャータイプを
把握できるので、前回の圧縮符号化時のピクチャータイ
プに基づいて、次回以降の圧縮符号化において圧縮制御
部30のバックサーチ部248のバックサーチ処理にお
いて用いられる閾値を、ピクチャータイプに応じて最適
化することが可能である。
When the picture rearranging section 200 of the compression encoding section 20 is controlled based on the video index as in the encoder 6, the picture type at the time of the previous compression encoding is also used in the next compression encoding. Based on the picture type at the previous compression encoding, the threshold used in the back search processing of the back search unit 248 of the compression control unit 30 in the next and subsequent compression encodings is optimized according to the picture type. It is possible to

【0139】つまり、前回の圧縮符号化時にイントラ符
号化されたピクチャーを、次回もイントラ符号化する場
合には、バックサーチ処理(図3)においてDCT係数
の剰余総和の顕著な極小点が現れやすい。従って、バッ
クサーチ処理に用いる閾値を大きめに設定することによ
り、DCT係数の剰余総和の極小点の誤検出が防止でき
る。
That is, when a picture that has been intra-encoded during the previous compression encoding is also intra-encoded next time, a remarkable minimum point of the remainder sum of the DCT coefficients tends to appear in the back search processing (FIG. 3). . Therefore, erroneous detection of the minimum point of the residual sum of the DCT coefficients can be prevented by setting the threshold value used for the back search process to be relatively large.

【0140】逆に、上述のように、前回の圧縮符号化に
おいてBピクチャーおよびPピクチャーに圧縮符号化さ
れたピクチャーを、次回の圧縮符号化においても同じピ
クチャータイプに圧縮符号化する場合には、動き予測を
用いた圧縮符号化であるために、前回の圧縮符号化にお
いて求められた動きベクトルと、次回以降の歪んだ映像
データから求められた動きベクトルとは一致せず、Pピ
クチャーおよびBピクチャーの予測誤差をDCT処理し
て得られたDCT係数の剰余総和を求めても、極小点が
さほど顕著には現れない。
Conversely, as described above, when the pictures that have been compressed and coded into the B picture and the P picture in the previous compression coding are to be compression coded to the same picture type in the next compression coding, Because of the compression coding using motion prediction, the motion vector obtained in the previous compression coding does not match the motion vector obtained from the distorted video data from the next time, and the P picture and the B picture Even if the residual sum of the DCT coefficients obtained by performing the DCT processing on the prediction error is obtained, the minimum point does not appear so remarkably.

【0141】このため、前回の圧縮符号化においてBピ
クチャーおよびPピクチャーに圧縮符号化されたピクチ
ャーを、次回の圧縮符号化においても同じピクチャータ
イプに圧縮符号化する場合には、バックサーチ部248
のバックサー処理において用いる閾値を高めに設定する
と、バックサーチ部248は、正しい量子化ステップ
(量子化インデックス)を求めることができない可能性
が生じる。
For this reason, in the case where a picture that has been compression-coded into a B picture and a P picture in the previous compression coding is to be compression-coded to the same picture type in the next compression coding, the back search unit 248 is used.
If the threshold value used in the backser process is set higher, there is a possibility that the back search unit 248 cannot find a correct quantization step (quantization index).

【0142】従って、前回の圧縮符号化においてBピク
チャーおよびPピクチャーに圧縮符号化されたピクチャ
ーを、次回の圧縮符号化においても同じピクチャータイ
プに圧縮符号化する場合には、バックサーチ部248の
バックサー処理において用いる閾値を、上記イントラ符
号化を行う場合に比べて小さい値とすることにより、バ
ックサーチ部248は正しい量子化ステップ(量子化イ
ンデックス)を求めることができるようになる。
Therefore, when the pictures which have been compressed and coded into the B picture and the P picture in the previous compression coding are to be compressed and coded to the same picture type in the next compression coding, the back search unit 248 By setting the threshold used in the processing to a value smaller than that in the case of performing the above-described intra coding, the back search unit 248 can obtain a correct quantization step (quantization index).

【0143】変形例 なお、図5に示したエンコーダ6においては、ビデオイ
ンデックス検出部32がスイッチ回路300を制御して
量子化ステップ(量子化インデックス)の変更を行う
が、ビデオインデックス検出部32の動作を、バックサ
ーチ部248の動作を直接にON/OFFするように変
更し、バックサーチ部248の動作を、ビデオインデッ
クス検出部32により動作がOFFにされた場合に、予
測部246から入力された量子化ステップ(量子化イン
デックス)を量子化部210に対して出力し、動作がO
Nにされた場合に、バックサーチ部248自体が生成し
た量子化ステップ(量子化インデックス)を量子化部2
10に対して出力するように変更してもよい。また、エ
ンコーダ6に対しても、エンコーダ2,5(図1,図
2,図4)に対してと同様な変更が可能である。
Modification In the encoder 6 shown in FIG. 5, the video index detection unit 32 controls the switch circuit 300 to change the quantization step (quantization index). The operation is changed so that the operation of the back search unit 248 is directly turned on / off. When the operation of the back search unit 248 is turned off by the video index detection unit 32, the operation is input from the prediction unit 246. The quantization step (quantization index) is output to the quantization unit 210, and the operation is
When N is set to N, the quantization step (quantization index) generated by the back search unit 248 itself is
The output may be changed so as to be output to 10. Also, the encoder 6 can be changed in the same manner as the encoders 2 and 5 (FIGS. 1, 2 and 4).

【0144】効果 以上説明したように、第2の実施形態に示したエンコー
ダ6によれば、圧縮符号化部30のビデオインデックス
検出部32が、オリジナルの映像データが入力された場
合には、バックサーチ部248のバックサーチ処理を無
効化するので、オリジナルの映像データを大きい量子化
ステップを用いて圧縮符号化するといった誤動作を防止
することができ、オリジナルの映像データを圧縮符号化
して得られる圧縮映像データの映像の品質が向上する。
[0144] As the effect described above, according to the encoder 6 shown in the second embodiment, when the video index detection unit 32 of the compression encoding section 30, the original image data is input, the back Since the back search processing of the search unit 248 is invalidated, it is possible to prevent a malfunction such as compression encoding of the original video data using a large quantization step, and to obtain a compression obtained by compression encoding the original video data. The image quality of the image data is improved.

【0145】また、エンコーダ6においては、圧縮符号
化部30のビデオインデックス検出部32が、オリジナ
ルの映像データが入力された場合には、バックサーチ部
248のバックサーチ処理が無効化されるので、既に圧
縮符号化を経た映像データが入力された場合にバックサ
ーチ部248が用いる閾値の値を小さく最適化すること
ができ、DCT係数の剰余総和の極小点の検出もれを防
ぐことができ、バックサーチ処理の制度が向上する。従
って結果的に、エンコーダ6によれば、既に圧縮符号化
を経た映像データを圧縮符号化して得られる圧縮映像デ
ータの品質も向上する。
In the encoder 6, the video index detection unit 32 of the compression encoding unit 30 invalidates the back search processing of the back search unit 248 when the original video data is input. When video data that has already been compression-encoded is input, the value of the threshold used by the back search unit 248 can be optimized to be small, and detection of a minimum point of the residual sum of DCT coefficients can be prevented from being missed. The system of back search processing is improved. Therefore, as a result, according to the encoder 6, the quality of the compressed video data obtained by compressing and encoding the video data that has already been subjected to the compression encoding is also improved.

【0146】第3実施形態 以下、本発明の第3実施形態を説明する。 Third Embodiment Hereinafter, a third embodiment of the present invention will be described.

【0147】第3の実施形態の背景 図8は、映像データ圧縮・多重化装置7の構成例を示す
図である。例えば、テレビジョン放送局間で複数の圧縮
映像データを多重化し、通信回線を介して伝送したい場
合がある。このような場合、例えば、図8に例示する映
像データ圧縮・多重化装置7が用いられる。
Background of Third Embodiment FIG. 8 is a diagram showing a configuration example of the video data compression / multiplexing device 7. For example, a plurality of compressed video data may be multiplexed between television broadcast stations and transmitted via a communication line. In such a case, for example, the video data compression / multiplexing device 7 illustrated in FIG. 8 is used.

【0148】図8に示すように、映像データ圧縮・多重
化装置7は、3個のエンコーダ70a〜70cおよび多
重化装置72から構成される。映像データ圧縮・多重化
装置7において、エンコーダ70a〜70cは、それぞ
れ例えばディジタルVTR装置から入力される入力映像
データCH1〜CH3を圧縮符号化し、それぞれ固定デ
ータレートFR1〜FR3の圧縮時映像データCH1’
〜CH3’として多重化装置72に対して出力する。多
重化装置72は、エンコーダ70a〜70cから入力さ
れた圧縮映像データCH1’〜CH3’を多重化し、出
力データレートTの出力映像データとして通信回線(図
示せず)に対して出力する。
As shown in FIG. 8, the video data compression / multiplexing device 7 is composed of three encoders 70a to 70c and a multiplexing device 72. In the video data compression / multiplexing device 7, the encoders 70a to 70c respectively compress and encode input video data CH1 to CH3 input from, for example, a digital VTR device, and compress video data CH1 'at fixed data rates FR1 to FR3, respectively.
CHCH3 'to the multiplexer 72. The multiplexing device 72 multiplexes the compressed video data CH1 ′ to CH3 ′ input from the encoders 70a to 70c, and outputs the multiplexed video data to a communication line (not shown) as output video data at an output data rate T.

【0149】多重化装置72に接続される通信回線の伝
送容量は予め決まっているので、多重化装置72の出力
データレートTは、この通信回線の伝送容量(許容値)
以下に制限される。従って、映像データ圧縮・多重化装
置7のユーザーは、エンコーダ70a〜70cそれぞれ
に対して、多重化装置72の出力データレートを配分し
て、圧縮映像データのデータレートFR1〜FR3(F
R1+FR2+FR3≦T)を設定する必要がある。
Since the transmission capacity of the communication line connected to the multiplexing device 72 is predetermined, the output data rate T of the multiplexing device 72 is determined by the transmission capacity (allowable value) of this communication line.
Limited to: Therefore, the user of the video data compression / multiplexing device 7 distributes the output data rate of the multiplexing device 72 to each of the encoders 70a to 70c, and sets the data rates FR1 to FR3 (F
R1 + FR2 + FR3 ≦ T) must be set.

【0150】このような場合には、単純にエンコーダ7
0a〜70cそれぞれに出力データレートTの1/3の
データレートを設定する方法の他に、入力映像データC
H1〜CH3の難度に応じて出力データレートTを配分
する方法が採られることがあり、後者の配分方法は統計
多重と呼ばれる。
In such a case, simply the encoder 7
In addition to the method of setting a data rate of 1/3 of the output data rate T to each of the input video data C
A method of allocating the output data rate T according to the difficulty of H1 to CH3 may be adopted, and the latter allocation method is called statistical multiplexing.

【0151】例えば、多重化装置72の出力データレー
トTが10Mbpsであり、入力映像データCH1が、
難しい絵柄のスポーツ映像の映像データであり、入力映
像データCH2が、比較的難しい絵柄のニュース映像の
映像データであり、入力映像データCH3が、比較的易
しい絵柄の映画の映像データである場合に、ユーザー
は、統計多重化方式に従って、エンコーダ70aにデー
タレートFR1として5Mbpsを配分し、エンコーダ
70bにデータレートFR2として3Mbpsを配分
し、エンコーダ70cにデータレートFR3として2M
bpsを配分し、それぞれに対して設定する。
For example, if the output data rate T of the multiplexer 72 is 10 Mbps, and the input video data CH1 is
If the input video data CH2 is video data of a news video having a relatively difficult pattern, and the input video data CH3 is video data of a movie having a relatively easy pattern, The user allocates 5 Mbps as the data rate FR1 to the encoder 70a, allocates 3 Mbps as the data rate FR2 to the encoder 70b, and allocates 2 Mbps as the data rate FR3 to the encoder 70c according to the statistical multiplexing method.
bps is allocated and set for each.

【0152】しかしながら、映像データの絵柄の難しさ
は経時的に変化し、入力映像データCH3の絵柄が、入
力映像データCH1の絵柄よりも大幅に難しくなる場合
がある。このような場合、映像データ圧縮・多重化装置
7によれば、エンコーダ70a〜70cに対してデータ
レートFR1〜FR3が固定的に設定されているので、
圧縮映像データCH3’の映像の品質が大幅に劣化して
しまう。第3の実施形態は、このような不具合を解決す
るためになされたものである。
However, the difficulty of the picture of the video data changes with time, and the picture of the input video data CH3 may be much more difficult than the picture of the input video data CH1. In such a case, according to the video data compression / multiplexing device 7, since the data rates FR1 to FR3 are fixedly set for the encoders 70a to 70c,
The quality of the video of the compressed video data CH3 'is significantly deteriorated. The third embodiment has been made to solve such a problem.

【0153】映像データ圧縮・多重化装置8の構成 図9は、第3の実施形態における本発明に係る映像デー
タ圧縮・多重化装置8の構成を示す図であって、映像デ
ータ圧縮・多重化装置8が3つの入力映像データを圧縮
符号化し、多重化する場合を例示する。なお、映像デー
タ圧縮・多重化装置8の構成部分の内、エンコーダ2,
5(図1,図2,図4)および映像データ圧縮・多重化
装置7(図7)と同じものには同一の符号が付してあ
る。
Configuration of Video Data Compression / Multiplexing Apparatus 8 FIG. 9 is a diagram showing the configuration of the video data compression / multiplexing apparatus 8 according to the third embodiment of the present invention. An example in which the device 8 compression-encodes and multiplexes three pieces of input video data will be described. It should be noted that, among the components of the video data compression / multiplexing device 8, the encoders 2,
5 (FIGS. 1, 2 and 4) and the video data compression / multiplexing device 7 (FIG. 7) are denoted by the same reference numerals.

【0154】図9に示すように、映像データ圧縮・多重
化装置8は、エンコーダ2,5,6のいずれかと同じ構
成のエンコーダ80a〜80c、多重化装置72および
制御部(CPU)82から構成される。映像データ圧縮
・多重化装置8において、エンコーダ80a〜80cの
圧縮制御部24(26,30、以下、単に圧縮制御部2
4と記す)の予測部246は、制御部82に対して、固
定値の量子化ステップにより単位期間ごとに求めた入力
映像データCH1〜CH3の発生符号量(難度)を出力
し、制御部82から単位期間ごとに入力される目標デー
タ量に基づいて、量子化部210に対する量子化ステッ
プを算出するように動作が変更されており、バックサー
チ部248は動作していても動作が無効にされていても
よい。
As shown in FIG. 9, the video data compression / multiplexing device 8 includes encoders 80a to 80c having the same configuration as any of the encoders 2, 5, and 6, a multiplexing device 72, and a control unit (CPU) 82. Is done. In the video data compression / multiplexing device 8, the compression control units 24 (26, 30, hereinafter simply referred to as the compression control units 2) of the encoders 80a to 80c.
The prediction unit 246 outputs the generated code amount (difficulty) of the input video data CH1 to CH3 obtained for each unit period by the fixed-value quantization step to the control unit 82. The operation has been changed so that the quantization step for the quantization unit 210 is calculated based on the target data amount input for each unit period from, and the operation is disabled even if the back search unit 248 operates. May be.

【0155】制御部82の動作の概要 制御部82は、エンコーダ80a〜80cからそれぞれ
単位期間(例えば1GOP分の圧縮映像データを生成す
る時間)ごとに入力される入力映像データの難度に基づ
いて、エンコーダ80a〜80cそれぞれに配分するデ
ータレートの値を算出し、エンコーダ80a〜80cの
圧縮符号化部24の予測部246に設定して、エンコー
ダ80a〜80cそれぞれが出力する圧縮映像データC
H1’〜CH3’のデータレートE1〜E3を単位期間
ごとに動的に調節する。
Overview of Operation of Control Unit 82 The control unit 82 determines the degree of difficulty of input video data input from the encoders 80a to 80c for each unit period (for example, the time for generating compressed video data for one GOP). The value of the data rate to be distributed to each of the encoders 80a to 80c is calculated and set in the prediction unit 246 of the compression encoding unit 24 of the encoders 80a to 80c, and the compressed video data C output by each of the encoders 80a to 80c is calculated.
The data rates E1 to E3 of H1 ′ to CH3 ′ are dynamically adjusted for each unit period.

【0156】映像データ圧縮・多重化装置8の動作 以下、映像データ圧縮・多重化装置8の動作をさらに説
明する。エンコーダ80a〜80cそれぞれにおいて、
圧縮制御部24の予測部246が、単位期間(1GO
P)分の入力映像データCH1〜CH3それぞれの難度
D1〜D3を制御部82に対して出力する。
Operation of Video Data Compression / Multiplexing Apparatus 8 The operation of the video data compression / multiplexing apparatus 8 will be further described below. In each of the encoders 80a to 80c,
The prediction unit 246 of the compression control unit 24 determines the unit period (1 GO
The difficulty levels D1 to D3 of the input video data CH1 to CH3 for P) are output to the control unit 82.

【0157】制御部82は、下の式1−1または式1−
2により、単位期間ごとの合計許容発生符号量Pを算出
する。
The control unit 82 calculates the following equation 1-1 or equation 1-
2, the total allowable generated code amount P for each unit period is calculated.

【0158】[0158]

【数1】 P=〔T(bps)×N(枚)〕/30(フレーム) =TN/30(ビット) …(NTSCの場合;1−1) P=〔T(bps)×N(枚)〕/25(フレーム) =TN/25(ビット) …(PALの場合;1−2) ただし、Nは単位期間(1GOP)に含まれるピクチャ
ー数であり、Tは、映像データ圧縮・多重化装置8に接
続される通信回線等が許容するデータレートである。
## EQU1 ## P = [T (bps) × N (sheet)] / 30 (frame) = TN / 30 (bit) (in the case of NTSC; 1-1) P = [T (bps) × N (sheet) )] / 25 (frame) = TN / 25 (bits) (in the case of PAL; 1-2) where N is the number of pictures included in a unit period (1 GOP), and T is video data compression / multiplexing. The data rate allowed by the communication line or the like connected to the device 8.

【0159】さらに、制御部82は、予測部246から
入力された入力映像データCH1〜CH3の難度D1〜
D3を用いて、下の式2−1〜式2−3,式3−1〜式
3−3に示すように、合計許容発生符号量Pを例えば比
例配分し、目標符号量E1〜E3を算出し、圧縮制御部
24の予測部246に設定する。
Further, control section 82 determines the difficulty levels D1 to D1 of input video data CH1 to CH3 input from prediction section 246.
Using D3, as shown in the following equations 2-1 to 2-3, equations 3-1 to 3-3, the total allowable generated code amount P is, for example, proportionally distributed, and the target code amounts E1 to E3 are calculated. It is calculated and set in the prediction unit 246 of the compression control unit 24.

【0160】[0160]

【数2】 E1=(TN/30)×〔D1/(D1+D2+D3)〕 (ビット) …(2−1) E2=(TN/30)×〔D2/(D1+D2+D3)〕 (ビット) …(2−2) E3=(TN/30)×〔D3/(D1+D2+D3)〕 (ビット) …(2−3) ただし、式2−1〜式2−3は入力映像データがNTS
C方式の場合に適合し、E1〜E3の小数点以下は切り
捨てである。
E1 = (TN / 30) × [D1 / (D1 + D2 + D3)] (bit) (2-1) E2 = (TN / 30) × [D2 / (D1 + D2 + D3)] (bit) (2) 2) E3 = (TN / 30) × [D3 / (D1 + D2 + D3)] (bits) (2-3) where the input video data is NTS
It is suitable for the case of the C method, and the decimal places of E1 to E3 are truncated.

【0161】[0161]

【数3】 E1=(TN/25)×〔D1/(D1+D2+D3)〕 (ビット) …(3−1) E2=(TN/25)×〔D2/(D1+D2+D3)〕 (ビット) …(3−2) E3=(TN/25)×〔D3/(D1+D2+D3)〕 (ビット) …(3−3) ただし、式3−1〜式3−3は入力映像データがPAL
方式の場合に適合する。
E1 = (TN / 25) × [D1 / (D1 + D2 + D3)] (bit) (3-1) E2 = (TN / 25) × [D2 / (D1 + D2 + D3)] (bit) (3- 2) E3 = (TN / 25) × [D3 / (D1 + D2 + D3)] (bits) (3-3) However, in Equations 3-1 to 3-3, the input video data is PAL.
Compatible with the method.

【0162】なお、映像データ圧縮・多重化装置8がn
個の入力映像データを処理する場合を一般的に示すと、
各エンコーダ80a〜80nに配分される目標データ量
Eiは、下の式4−1,式4−2により表される。
It should be noted that the video data compression / multiplexing device 8
In general, the case of processing input video data of
The target data amount Ei allocated to each of the encoders 80a to 80n is expressed by the following equations 4-1 and 4-2.

【0163】[0163]

【数4】 Ei=(TN/30)×〔Di/(D1+…+Dn)〕 (ビット) …(NTSCの場合;4−1) Ei=(TN/25)×〔D2/(D1+D2+D3)〕 (ビット) …(PALの場合;4−2) ただし、i=1〜n、Eiの小数点以下は切り捨てであ
る。
Ei = (TN / 30) × [Di / (D1 +... + Dn)] (bit) (in the case of NTSC; 4-1) Ei = (TN / 25) × [D2 / (D1 + D2 + D3)] ( (Bit)... (In the case of PAL; 4-2) where i = 1 to n, and the fractional part of Ei is rounded down.

【0164】具体例を挙げる。例えば、入力映像データ
がNTSC方式であり、N=30枚、T=10(Mbp
s)、D1=10(Mbit)、D2=20(Mbi
t)、D3=30(Mbit)である場合には、制御部
82は、入力映像データCH1〜CH3の難度D1〜D
3を用いて、目標データ量E1〜E3を、下の式5−1
〜式5−3に示すように算出する。
Specific examples will be described. For example, the input video data is in the NTSC format, N = 30, T = 10 (Mbp)
s), D1 = 10 (Mbit), D2 = 20 (Mbi)
t), when D3 = 30 (Mbit), the control unit 82 determines the difficulty levels D1 to D3 of the input video data CH1 to CH3.
3, the target data amounts E1 to E3 are calculated by the following equation 5-1.
To 5-3.

【0165】[0165]

【数5】 E1=〔(10×30)/30〕×〔10/(10+20+30)〕 =約1.6Mbps …(5−1) E2=〔(10×30)/30〕×〔20/(10+20+30)〕 =約3.3Mbps …(5−2) E3=〔(10×30)/30〕×〔30/(10+20+30)〕 =約5.0Mbps …(5−3)E1 = [(10 × 30) / 30] × [10 / (10 + 20 + 30)] = about 1.6 Mbps (5-1) E2 = [(10 × 30) / 30] × [20 / ( 10 + 20 + 30)] = about 3.3 Mbps (5-2) E3 = [(10 × 30) / 30] × [30 / (10 + 20 + 30)] = about 5.0 Mbps (5-3)

【0166】エンコーダ80a〜80cそれぞれの予測
部246は、バックサーチ部248から設定された目標
データ量に基づいて量子化ステップ(量子化インデック
ス)を算出して圧縮符号化部20の量子化部210に設
定する。エンコーダ80a〜80cそれぞれの圧縮符号
化部20は、バックサーチ部248が設定した量子化ス
テップ(量子化インデックス)を用いて圧縮符号化を行
い、単位期間ごとに目標データ量E1〜E3以下であっ
て、ほぼ目標データ量E1〜E3に近いデータ量の圧縮
時映像データCH1’〜CH3’を生成し、多重化装置
72に対して出力する。多重化装置72は、エンコーダ
80a〜80cからそれぞれ入力される圧縮映像データ
CH1’〜CH3’を多重化して出力映像データを生成
し、通信回線(図示せず)に対して出力する。
The prediction unit 246 of each of the encoders 80a to 80c calculates a quantization step (quantization index) based on the target data amount set by the back search unit 248, and calculates the quantization step (quantization index) of the quantization unit 210 of the compression encoding unit 20. Set to. The compression encoding unit 20 of each of the encoders 80a to 80c performs the compression encoding using the quantization step (quantization index) set by the back search unit 248, and the target data amount E1 to E3 or less per unit period. Thus, the compressed video data CH1 ′ to CH3 ′ having a data amount substantially close to the target data amounts E1 to E3 is generated and output to the multiplexer 72. The multiplexer 72 multiplexes the compressed video data CH1 ′ to CH3 ′ input from the encoders 80a to 80c to generate output video data, and outputs the output video data to a communication line (not shown).

【0167】変形例1 以下、第3の実施形態において説明した映像データ圧縮
・多重化装置8の動作の第1の変形例を説明する。例え
は、映像データ圧縮・多重化装置8に入力される映像デ
ータの1つが、スポーツプログラム等の絵柄が難しい映
像データである場合に、この映像データ全体を通じて、
高いデータレートで圧縮符号化を行いたい場合がある。
Modification 1 Hereinafter, a first modification of the operation of the video data compression / multiplexing device 8 described in the third embodiment will be described. For example, if one of the video data input to the video data compression / multiplexing device 8 is video data such as a sports program in which a pattern is difficult, the video data is transmitted through the entire video data.
There are cases where it is desired to perform compression encoding at a high data rate.

【0168】このような場合には、エンコーダ80a〜
80cそれぞれの予測部246から入力される難度D1
〜D3〔一般化してDk(k=1〜n)と記す〕に対し
て重み付け係数Akを乗算してプライオリティ(重み)
を付け、下の式6−1,式6−2に示すように目標デー
タ量Ekを算出するように、制御部82の動作を変形す
ればよい。
In such a case, the encoders 80a to 80a
80c, the difficulty level D1 input from each prediction unit 246.
DD3 (generalized as Dk (k = 1 to n)) is multiplied by a weighting coefficient Ak to give a priority (weight)
And the operation of the control unit 82 may be modified so as to calculate the target data amount Ek as shown in Equations 6-1 and 6-2 below.

【0169】[0169]

【数6】 Ek=(TN/30)×〔Ak×Dk/(A1×D1+…+An×Dn)〕 …(NTSCの場合;6−1) Ek=(TN/25)×〔Ak×Dk/(A1×D1+…+An×Dn)〕 …(PALの場合;6−2)Ek = (TN / 30) × [Ak × Dk / (A1 × D1 +... + An × Dn)] (in the case of NTSC; 6-1) Ek = (TN / 25) × [Ak × Dk / (A1 × D1 +... + An × Dn)] (for PAL; 6-2)

【0170】具体例を挙げる。入力映像データがNTS
C方式であり、N=30枚、T=10(Mbps)、D
1=10(Mbit)、D2=20(Mbit)、D3
=30(Mbit)であり、入力映像データCH1〜C
H3に対する重み付け係数A1〜A3がそれぞれ1,
3,2である場合には、下の式7−1〜式7−3に示す
ように目標データ量E1〜E3を求めることができる。
Specific examples will be described. Input video data is NTS
C method, N = 30 sheets, T = 10 (Mbps), D
1 = 10 (Mbit), D2 = 20 (Mbit), D3
= 30 (Mbit) and the input video data CH1 to C
The weighting coefficients A1 to A3 for H3 are 1,
In the case of 3, 2, the target data amounts E1 to E3 can be obtained as shown in the following equations 7-1 to 7-3.

【0171】[0171]

【数7】 E1=(10×30/30) ×〔(1×10)/(1×10+3×20+2×30)〕 =約0.7Mbps …(7−1) E2=(10×30/30) ×〔(3×20)/(1×10+3×20+2×30)〕 =約4.6Mbps …(7−2) E3=(10×30/30) ×〔(2×30)/(1×10+3×20+2×30)〕 =約4.6Mbps …(7−3)E1 = (10 × 30/30) × [(1 × 10) / (1 × 10 + 3 × 20 + 2 × 30)] = about 0.7 Mbps (7-1) E2 = (10 × 30/30) ) × [(3 × 20) / (1 × 10 + 3 × 20 + 2 × 30)] = about 4.6 Mbps (7-2) E3 = (10 × 30/30) × [(2 × 30) / (1 × 10 + 3 × 20 + 2 × 30)] = about 4.6 Mbps (7-3)

【0172】変形例2 以下、図10を参照して、第3の実施形態において示し
た映像データ圧縮・多重化装置8の第2の変形例を説明
する。図10は、図9に示した映像データ圧縮・多重化
装置8の第2の変形例の動作を示すフローチャート図で
ある。
Modification 2 Hereinafter, a second modification of the video data compression / multiplexing device 8 shown in the third embodiment will be described with reference to FIG. FIG. 10 is a flowchart showing the operation of the second modification of the video data compression / multiplexing device 8 shown in FIG.

【0173】エンコーダ80a〜80cそれぞれの圧縮
符号化部20のFIFO206の容量に応じて、GOP
単位ではなく、1フレーム分の圧縮映像データを生成す
る時間から数秒程度をフレキシブルに単位期間とするこ
とが可能である。
According to the capacity of the FIFO 206 of the compression encoder 20 of each of the encoders 80a to 80c, the GOP
Instead of the unit, it is possible to flexibly set the unit period to about several seconds from the time of generating the compressed video data for one frame.

【0174】図10に示すように、ステップ300(S
300)において、制御部82は、エンコーダ80a〜
80cそれぞれが算出した入力映像データCH1〜CH
3のフレームごとの難度d1〜d3をフレームごとに取
り込む。ステップ302(S302)において、制御部
82は、取り込んだ入力映像データの難度d1〜d3を
累加算(D1=d1++,D2=d2++,D3=d3
++)する。
As shown in FIG. 10, step 300 (S
300), the control unit 82 controls the encoders 80a to 80a.
80c calculated input video data CH1 to CH
3, the difficulty levels d1 to d3 for each frame are captured for each frame. In step 302 (S302), the control unit 82 cumulatively adds the difficulty levels d1 to d3 of the input video data (D1 = d1 ++, D2 = d2 ++, D3 = d3).
++).

【0175】ステップ304(S304)において、制
御部82は、計数したフレーム数がNであるかいなか、
つまり、S302の処理において、1単位期間(Nフレ
ーム分の圧縮映像データを生成する時間)の難度D1〜
D3の累加算が終了したか否かを判断する。終了した場
合にはS306の処理に進み、終了していない場合には
S302の処理に戻る。
In step 304 (S304), the control unit 82 determines whether the counted number of frames is N or not.
That is, in the processing of S302, the difficulty levels D1 to D1 for one unit period (time to generate compressed video data for N frames)
It is determined whether or not the accumulation of D3 has been completed. If the processing has been completed, the process proceeds to S306, and if not, the process returns to S302.

【0176】ステップ306(S306)において、制
御部82は、式2−1〜式2−3(入力映像データがN
TSC方式である場合)または式3−1〜式3−3(入
力映像データがPAL方式である場合)により、目標デ
ータ量E1〜E3を算出する。
In step 306 (S 306), the control section 82 sets the formulas 2-1 to 2-3 (when the input video data is N
The target data amounts E1 to E3 are calculated according to the TSC method or the formulas 3-1 to 3-3 (when the input video data is the PAL method).

【0177】ステップ308(S308)において、制
御部82は、エンコーダ80a〜80cそれぞれの圧縮
制御部24の予測部246に、算出した目標データ量E
1〜E3を設定し、圧縮映像データのデータレートE1
〜E3を調節する。さらに、エンコーダ80a〜80c
それぞれの圧縮符号化部20は、設定された目標データ
量E1〜E3を用いて入力映像データCH1〜CH3を
圧縮符号化し、その単位期間における発生符号量が目標
データ量E1〜E3以下であって、目標データ量E1〜
E3とほぼ同じ圧縮映像データCH1’〜CH3’を発
生し、出力する。
In step 308 (S308), the control unit 82 sends the calculated target data amount E to the prediction unit 246 of the compression control unit 24 of each of the encoders 80a to 80c.
1 to E3, and the data rate E1 of the compressed video data
Adjust ~ E3. Further, encoders 80a to 80c
Each of the compression encoding units 20 compression-encodes the input video data CH1 to CH3 using the set target data amounts E1 to E3, and the generated code amount in the unit period is equal to or less than the target data amounts E1 to E3. , Target data amount E1
It generates and outputs compressed video data CH1 'to CH3' substantially the same as E3.

【0178】なお、映像データ圧縮・多重化装置8のエ
ンコーダ80a〜80cの数は例示であって、多重化装
置72の入力端子数および制御部82の処理内容を適切
に変形することにより、任意の数とすることができる。
また、映像データ圧縮・多重化装置8に対しても、エン
コーダ2,5,6に対してと同様な変形が可能である。
また、映像データ圧縮・多重化装置7,8を、映像デー
タ処理システム1においてエンコーダ2,5,6の代わ
りに用いることができる。
Note that the number of encoders 80a to 80c of the video data compression / multiplexing device 8 is an example, and the number of input terminals of the multiplexing device 72 and the processing content of the control unit 82 can be changed as appropriate. Number.
Also, the same modification can be applied to the video data compression / multiplexing device 8 as to the encoders 2, 5, and 6.
Further, the video data compression / multiplexing devices 7 and 8 can be used in the video data processing system 1 instead of the encoders 2, 5 and 6.

【0179】効果 以上第3の実施形態において説明したように、本発明に
係る映像データ圧縮・多重化装置8によれば、圧縮制御
部24の予測部246が求める入力映像データの難度に
基づいて、複数の入力映像データそれぞれに配分する出
力データレートの値をダイナミックに調節することがで
き、多重化装置72の出力データレートを有効利用する
ことができ、しかも、圧縮映像データCH1’〜CH
3’の映像の品質が全体として向上する。
Effects As described above in the third embodiment, according to the video data compression / multiplexing apparatus 8 according to the present invention, based on the degree of difficulty of the input video data obtained by the prediction section 246 of the compression control section 24. , The value of the output data rate allocated to each of the plurality of input video data can be dynamically adjusted, the output data rate of the multiplexer 72 can be used effectively, and the compressed video data CH1 ′ to CH1
The image quality of 3 'is improved as a whole.

【0180】また、映像データ圧縮・多重化装置8の第
1の変形例によれば、入力映像データの難度に重み付け
して目標データ量の算出を行うことにより、より効果的
な圧縮映像データの多重化が可能となる。また、映像デ
ータ圧縮・多重化装置8の第2の変形例によれば、目標
データ量の調節の単位期間を、GOP単位にではなく、
1フレーム単位にフレキシブルに変更することができ
る。
According to the first modification of the video data compression / multiplexing device 8, the target data amount is calculated by weighting the degree of difficulty of the input video data, so that more effective compressed video data can be obtained. Multiplexing becomes possible. Further, according to the second modification of the video data compression / multiplexing device 8, the unit period for adjusting the target data amount is not set in GOP units,
It can be changed flexibly in units of one frame.

【0181】[0181]

【発明の効果】以上説明したように、本発明に係るデー
タ圧縮装置およびその方法によれば、ピクチャータイプ
の情報を特別に有効画素データと多重化しなくても、前
回の圧縮符号化時のピクチャータイプをエンコーダ側で
自動検出し、GOP位相を合わせて圧縮符号化すること
ができる。
As described above, according to the data compression apparatus and method according to the present invention, the picture data at the time of the previous compression encoding can be obtained without specially multiplexing the picture type information with the effective pixel data. The type can be automatically detected on the encoder side, and the GOP phase can be matched and compression-encoded.

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

【図1】本発明に係るエンコーダが用いられる映像デー
タ処理システムの構成を示す図である。
FIG. 1 is a diagram showing a configuration of a video data processing system in which an encoder according to the present invention is used.

【図2】図1に示した第1の実施形態における本発明に
係るエンコーダの構成を示す図である。
FIG. 2 is a diagram showing a configuration of an encoder according to the present invention in the first embodiment shown in FIG.

【図3】図1および図2に示したエンコーダのバックサ
ーチ部およびピクチャータイプ制御部の処理内容を例示
するフローチャート図である。
FIG. 3 is a flowchart illustrating processing contents of a back search unit and a picture type control unit of the encoder shown in FIGS. 1 and 2;

【図4】第1の実施形態の変形例のエンコーダの構成を
示す図である。
FIG. 4 is a diagram illustrating a configuration of an encoder according to a modified example of the first embodiment.

【図5】第2の実施形態における本発明に係るエンコー
ダの構成を示す図である。
FIG. 5 is a diagram illustrating a configuration of an encoder according to the present invention in a second embodiment.

【図6】図1に示したデコーダの構成を示す図である。FIG. 6 is a diagram illustrating a configuration of a decoder illustrated in FIG. 1;

【図7】図5に示したエンコーダのビデオインデックス
検出部の動作を例示するフローチャート図である。
FIG. 7 is a flowchart illustrating an operation of a video index detection unit of the encoder shown in FIG. 5;

【図8】映像データ圧縮・多重化装置の構成例を示す図
である。
FIG. 8 is a diagram illustrating a configuration example of a video data compression / multiplexing device.

【図9】第3の実施形態における本発明に係る映像デー
タ圧縮・多重化装置の構成を示す図である。
FIG. 9 is a diagram showing a configuration of a video data compression / multiplexing apparatus according to the present invention in a third embodiment.

【図10】図9に示した映像データ圧縮・多重化装置の
第2の変形例の動作を示すフローチャート図である。
FIG. 10 is a flowchart showing an operation of a second modification of the video data compression / multiplexing apparatus shown in FIG. 9;

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

1…映像データ処理システム、2(2a,2b),5,
6…エンコーダ、20…圧縮符号化部、200…ピクチ
ャー並べ替え部、202…走査変換ブロック化部、20
4…動き検出部、206…FIFO、208…DCT
部、210…量子化部、212…可変長符号化部、21
4…逆量子化部、216…逆DCT部、218…加算回
路、220…FIFO、222…動き補償部、24,2
6,30…圧縮制御部、240…動き補償部、242…
減算回路、244…DCT部、246…予測部、248
…バックサーチ部、250…ピクチャータイプ制御部、
28…GOP位相制御部、280…ブロック抽出部、2
82…DCT部、284…予測部、286…バックサー
チ部、300…スイッチ回路、32…ビデオインデック
ス検出部、3(3a〜3c)…記録・伝送装置、4(4
a,4b)…デコーダ、40…伸長復号部、400…バ
ッファメモリ、402…可変長復号部、404…逆量子
化部、406…逆DCT部、408…動き補償部、41
0…スイッチ回路、412…ピクチャー並べ替え部、4
14…ビデオインデックス多重化部、416…ピクチャ
ータイプ制御部、7,8…映像データ圧縮・多重化装
置、70a〜70c,80a〜80c…エンコーダ、7
2…多重化装置、82…制御部。
1. Video data processing system, 2 (2a, 2b), 5,
6 encoder, 20 compression encoding unit, 200 picture rearranging unit, 202 scan conversion blocking unit, 20
4: Motion detector, 206: FIFO, 208: DCT
Unit, 210: quantization unit, 212: variable length encoding unit, 21
4 Inverse quantization unit, 216 Inverse DCT unit, 218 Addition circuit, 220 FIFO, 222 Motion compensation unit, 24, 2
6, 30 ... compression control unit, 240 ... motion compensation unit, 242 ...
Subtraction circuit, 244... DCT section, 246... Prediction section, 248
... back search section, 250 ... picture type control section,
28: GOP phase control unit, 280: block extraction unit, 2
82 DCT unit, 284 prediction unit, 286 back search unit, 300 switch circuit, 32 video index detection unit, 3 (3a to 3c) recording / transmission device, 4 (4
a, 4b): decoder, 40: decompression decoder, 400: buffer memory, 402: variable length decoder, 404: inverse quantization unit, 406: inverse DCT unit, 408: motion compensation unit, 41
0: switch circuit, 412: picture rearranging section, 4
14 video index multiplexing section, 416 picture type control section, 7, 8 video data compression / multiplexing apparatus, 70a-70c, 80a-80c encoder, 7
2. Multiplexer, 82 Control unit.

Claims (10)

【特許請求の範囲】[Claims] 【請求項1】Iピクチャー、PピクチャーおよびBピク
チャーの組み合わせに圧縮処理された圧縮映像データを
伸長した映像データのピクチャーの内、前記圧縮処理に
おいてIピクチャーに圧縮符号化されたピクチャーを検
出するIピクチャー検出手段と、 検出したIピクチャーの間隔に基づいて、前記映像デー
タのピクチャーそれぞれが、前記圧縮処理において、I
ピクチャー、PピクチャーおよびBピクチャー内のいず
れのピクチャー種別に圧縮されたかを判定するピクチャ
ー種別判定手段と、 前記映像データのピクチャーそれぞれを、前記圧縮処理
においてと同じピクチャー種別に圧縮する映像データ圧
縮手段とを有する映像データ圧縮装置。
1. An I-picture for detecting a picture which has been compressed and coded into an I-picture in said compression processing from pictures of video data obtained by expanding compressed video data which has been compressed into a combination of an I picture, a P picture and a B picture. Each of the pictures of the video data is subjected to I-picture processing in the compression processing based on picture detection means and an interval between the detected I-pictures.
Picture type determining means for determining which picture type among pictures, P pictures and B pictures has been compressed; and video data compressing means for compressing each picture of the video data into the same picture type as in the compression processing. A video data compression device having:
【請求項2】前記Iピクチャー検出手段は、 前記映像データのピクチャーそれぞれをマクロブロック
ごとに直行変換して直行変換データを生成する直行変換
手段と、 生成した前記映像データのピクチャーそれぞれのマクロ
ブロックごとの前記直行変換データを複数の量子化ステ
ップそれぞれにより除算する除算手段と、 前記映像データのピクチャーそれぞれのマクロブロック
ごとの前記直行変換データの前記複数の量子化ステップ
による除算結果それぞれの剰余の総和を算出する剰余総
和算出手段と、 前記剰余の総和の極小値があるか否かに基づいて、前記
映像データのピクチャーが、前記圧縮処理においてIピ
クチャーに圧縮符号化されたか否かを検出する検出手段
とを有する請求項1に記載の映像データ圧縮装置。
2. An I-picture detecting means, comprising: a orthogonal transformation means for orthogonally transforming each picture of the video data for each macroblock to generate orthogonal conversion data; and for each macroblock of each picture of the generated video data. A dividing means for dividing the orthogonal transform data by each of a plurality of quantization steps; anda sum of remainders of respective division results of the orthogonal transform data by the plurality of quantization steps for each macroblock of each picture of the video data. A remainder sum calculating means for calculating; and a detecting means for detecting whether or not the picture of the video data is compression-encoded into an I-picture in the compression processing based on whether or not there is a minimum value of the sum of the remainders The video data compression device according to claim 1, comprising:
【請求項3】前記Iピクチャー検出手段は、 前記映像データのピクチャーそれぞれのマクロブロック
の一部を直行変換して直行変換データを生成する直行変
換手段と、 生成した前記映像データのピクチャーそれぞれのマクロ
ブロックの一部の前記直行変換データを複数の量子化ス
テップそれぞれにより除算する除算手段と、 前記映像データのピクチャーそれぞれのマクロブロック
の一部の前記直行変換データの前記複数の量子化ステッ
プによる除算結果それぞれの剰余の総和を算出する剰余
総和算出手段と、 前記剰余の総和の極小値があるか否かに基づいて、前記
映像データのピクチャーが、前記圧縮処理においてIピ
クチャーに圧縮符号化されたか否かを検出する検出手段
とを有する請求項1に記載の映像データ圧縮装置。
3. An I-picture detecting means, comprising: an orthogonal conversion means for orthogonally converting a part of a macroblock of each picture of the video data to generate orthogonal conversion data; and a macro for each picture of the generated video data picture. Division means for dividing the orthogonal transform data of a part of a block by each of a plurality of quantization steps; A residue sum calculating means for calculating the sum of the respective remainders, and whether or not the picture of the video data is compression-encoded into an I-picture in the compression process based on whether or not there is a minimum value of the sum of the remainders 2. The video data compression apparatus according to claim 1, further comprising: a detection unit configured to detect whether or not the video data is compressed.
【請求項4】前記Iピクチャー検出手段は、 前記剰余の総和の極小値が最小となる量子化ステップを
選択する量子化ステップ選択手段を有し、 前記映像データ圧縮手段は、 選択した前記量子化ステップを用いて前記映像データを
量子化する量子化手段を有する請求項2に記載の映像デ
ータ圧縮装置。
4. The I-picture detecting means includes a quantization step selecting means for selecting a quantization step that minimizes a minimum value of the sum of the remainders, and the video data compressing means includes: 3. The video data compression apparatus according to claim 2, further comprising a quantization unit that quantizes the video data using a step.
【請求項5】前記Iピクチャー検出手段は、前記映像デ
ータ圧縮手段が前記映像データを圧縮する前に、前記圧
縮処理においてIピクチャーに圧縮符号化されたピクチ
ャーを検出する請求項2に記載の映像データ圧縮装置。
5. The video picture according to claim 2, wherein said I picture detection means detects a picture which has been compression-encoded into an I picture in said compression processing before said video data compression means compresses said video data. Data compression device.
【請求項6】Iピクチャー、PピクチャーおよびBピク
チャーの組み合わせに圧縮処理された圧縮映像データを
伸長した映像データのピクチャーの内、前記圧縮処理に
おいてIピクチャーに圧縮符号化されたピクチャーを検
出し、 検出したIピクチャーの間隔に基づいて、前記映像デー
タのピクチャーそれぞれが、前記圧縮処理において、I
ピクチャー、PピクチャーおよびBピクチャー内のいず
れのピクチャー種別に圧縮されたかを判定し、 前記映像データのピクチャーそれぞれを、前記圧縮処理
においてと同じピクチャー種別に圧縮する映像データ圧
縮方法。
6. A picture which has been compressed and coded into an I picture in said compression processing among pictures of video data obtained by expanding compressed video data which has been compressed to a combination of an I picture, a P picture and a B picture, and Based on the detected I-picture intervals, each of the pictures of the video data is
A video data compression method for determining which picture type among a picture, a P picture and a B picture has been compressed, and compressing each picture of the video data into the same picture type as in the compression process.
【請求項7】前記映像データのピクチャーそれぞれをマ
クロブロックごとに直行変換して直行変換データを生成
し、 生成した前記映像データのピクチャーそれぞれのマクロ
ブロックごとの前記直行変換データを複数の量子化ステ
ップそれぞれにより除算し、 前記映像データのピクチャーそれぞれのマクロブロック
ごとの前記直行変換データの前記複数の量子化ステップ
による除算結果それぞれの剰余の総和を算出し、 前記剰余の総和の極小値があるか否かに基づいて、前記
映像データのピクチャーが、前記圧縮処理においてIピ
クチャーに圧縮符号化されたか否かを検出する請求項6
に記載の映像データ圧縮方法。
7. A method for orthogonally transforming each picture of said video data for each macroblock to generate orthogonally-converted data, wherein said orthogonally-transformed data for each macroblock of each picture of said generated video data is subjected to a plurality of quantization steps. Calculating the sum of the respective remainders of the orthogonal transformation data for each macroblock of each picture of the video data by the plurality of quantization steps, and determining whether there is a minimum value of the sum of the remainders And detecting whether or not the picture of the video data has been compression-encoded into an I-picture in the compression processing.
2. The video data compression method according to 1.
【請求項8】前記映像データのピクチャーそれぞれのマ
クロブロックの一部を直行変換して直行変換データを生
成し、 生成した前記映像データのピクチャーそれぞれのマクロ
ブロックの一部の前記直行変換データを複数の量子化ス
テップそれぞれにより除算し、 前記映像データのピクチャーそれぞれのマクロブロック
の一部の前記直行変換データの前記複数の量子化ステッ
プによる除算結果それぞれの剰余の総和を算出し、 前記剰余の総和の極小値があるか否かに基づいて、前記
映像データのピクチャーが、前記圧縮処理においてIピ
クチャーに圧縮符号化されたか否かを検出する請求項6
に記載の映像データ圧縮方法。
8. A method for orthogonally transforming a part of a macroblock of each picture of said video data to generate orthogonally transformed data, wherein a plurality of said orthogonally transformed data of a part of the generated macroblock of each picture of said video data are provided. Calculating the sum of the remainders of the respective division results of the orthogonal transformation data of the part of the macroblocks of each picture macroblock of the picture data of the video data, and calculating the sum of the sums of the remainders 7. A detection as to whether a picture of the video data has been compression-encoded into an I-picture in the compression processing based on whether or not there is a minimum value.
2. The video data compression method according to 1.
【請求項9】前記剰余の総和の極小値が最小となる量子
化ステップを選択し、 選択した前記量子化ステップを用いて前記映像データを
量子化する請求項7に記載の映像データ圧縮方法。
9. The video data compression method according to claim 7, wherein a quantization step that minimizes the minimum value of the sum of the remainders is selected, and the video data is quantized using the selected quantization step.
【請求項10】前記映像データを圧縮する前に、前記圧
縮処理においてIピクチャーに圧縮符号化されたピクチ
ャーを検出する請求項7に記載の映像データ圧縮方法。
10. The video data compression method according to claim 7, wherein a picture compressed and encoded into an I picture in said compression processing is detected before said video data is compressed.
JP33208096A 1996-12-12 1996-12-12 Video data compression apparatus and method Expired - Fee Related JP4032446B2 (en)

Priority Applications (7)

Application Number Priority Date Filing Date Title
JP33208096A JP4032446B2 (en) 1996-12-12 1996-12-12 Video data compression apparatus and method
US09/117,973 US6163573A (en) 1996-12-12 1997-12-11 Equipment and method for compressing picture data
PCT/JP1997/004565 WO1998026602A1 (en) 1996-12-12 1997-12-11 Equipment and method for compressing picture data
KR1019980706189A KR100599017B1 (en) 1996-12-12 1997-12-11 Image data compression device and method
US09/715,393 US6493384B1 (en) 1996-12-12 2000-11-17 Video data compression apparatus and method of same
US10/273,491 US20030039309A1 (en) 1996-12-12 2002-10-18 Video data compression apparatus and method of same
US10/299,174 US7313184B2 (en) 1996-12-12 2002-11-19 Video data compression apparatus and method of same

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP33208096A JP4032446B2 (en) 1996-12-12 1996-12-12 Video data compression apparatus and method

Publications (2)

Publication Number Publication Date
JPH10174106A true JPH10174106A (en) 1998-06-26
JP4032446B2 JP4032446B2 (en) 2008-01-16

Family

ID=18250930

Family Applications (1)

Application Number Title Priority Date Filing Date
JP33208096A Expired - Fee Related JP4032446B2 (en) 1996-12-12 1996-12-12 Video data compression apparatus and method

Country Status (1)

Country Link
JP (1) JP4032446B2 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007074467A (en) * 2005-09-08 2007-03-22 Sony Corp Information processor and method, transmitter and method, recorder and method, and program
US7933494B2 (en) 2005-09-08 2011-04-26 Sony Corporation Recording apparatus and method, and program
JP2012085367A (en) * 2006-04-07 2012-04-26 Microsoft Corp Quantization adjustment based on texture level
US8897359B2 (en) 2008-06-03 2014-11-25 Microsoft Corporation Adaptive quantization for enhancement layer video coding
US9967561B2 (en) 2006-05-05 2018-05-08 Microsoft Technology Licensing, Llc Flexible quantization

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1615067B1 (en) 2003-03-24 2015-09-23 Nikon Corporation Optical element, optical system, laser device, exposure device, mask testing device, and crystal processing device

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007074467A (en) * 2005-09-08 2007-03-22 Sony Corp Information processor and method, transmitter and method, recorder and method, and program
US7933494B2 (en) 2005-09-08 2011-04-26 Sony Corporation Recording apparatus and method, and program
JP2012085367A (en) * 2006-04-07 2012-04-26 Microsoft Corp Quantization adjustment based on texture level
US9967561B2 (en) 2006-05-05 2018-05-08 Microsoft Technology Licensing, Llc Flexible quantization
US8897359B2 (en) 2008-06-03 2014-11-25 Microsoft Corporation Adaptive quantization for enhancement layer video coding
US9185418B2 (en) 2008-06-03 2015-11-10 Microsoft Technology Licensing, Llc Adaptive quantization for enhancement layer video coding
US9571840B2 (en) 2008-06-03 2017-02-14 Microsoft Technology Licensing, Llc Adaptive quantization for enhancement layer video coding
US10306227B2 (en) 2008-06-03 2019-05-28 Microsoft Technology Licensing, Llc Adaptive quantization for enhancement layer video coding

Also Published As

Publication number Publication date
JP4032446B2 (en) 2008-01-16

Similar Documents

Publication Publication Date Title
KR100599017B1 (en) Image data compression device and method
US6441754B1 (en) Apparatus and methods for transcoder-based adaptive quantization
US7301999B2 (en) Quantization method and system for video MPEG applications and computer program product therefor
WO2002078355A1 (en) Variable length coding
JP2004343280A (en) Image processing apparatus and method, information processing apparatus, recording medium, and program
EP1032212A2 (en) Transcoder, transcoding system, and recording medium
JP3519673B2 (en) Video data creation device and video encoding device
JP4114210B2 (en) Video data compression apparatus and method
JPH07312756A (en) Circuit, device and method for conversion of information quantity of compressed animation image code signal
US6804299B2 (en) Methods and systems for reducing requantization-originated generational error in predictive video streams using motion compensation
US20080253447A1 (en) Video Transcoding with Selection of Data Portions to be Processed
JP3818819B2 (en) Image coding method conversion apparatus, image coding method conversion method, and recording medium
JP4032446B2 (en) Video data compression apparatus and method
US6040875A (en) Method to compensate for a fade in a digital video input sequence
JP3599942B2 (en) Moving picture coding method and moving picture coding apparatus
KR20020057525A (en) Apparatus for transcoding video
JP4292659B2 (en) Image information conversion apparatus and image information conversion method
JP2005012249A (en) Image processing apparatus and image processing method, information processing apparatus, recording medium, and program
KR100533025B1 (en) Partitioning apparatus for moving picture data and method
JP3800965B2 (en) Data rate converter
JP4539028B2 (en) Image processing apparatus, image processing method, recording medium, and program
JP2776424B2 (en) Cell loss compensation image decoding method
JP2002218470A (en) Method for converting image encoded data rate and device for converting image encoding rate
JP4000581B2 (en) Image coding apparatus and method
JP3770466B2 (en) Image coding rate conversion apparatus and image coding rate conversion method

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20060307

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20060419

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20070206

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20070307

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20071002

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20071015

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

Free format text: PAYMENT UNTIL: 20101102

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20101102

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20111102

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20121102

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20131102

Year of fee payment: 6

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees