[go: up one dir, main page]

JP2000299856A - Device and method for generating stream, device and method for transmitting stream, device and method for encoding and recording medium - Google Patents

Device and method for generating stream, device and method for transmitting stream, device and method for encoding and recording medium

Info

Publication number
JP2000299856A
JP2000299856A JP34315699A JP34315699A JP2000299856A JP 2000299856 A JP2000299856 A JP 2000299856A JP 34315699 A JP34315699 A JP 34315699A JP 34315699 A JP34315699 A JP 34315699A JP 2000299856 A JP2000299856 A JP 2000299856A
Authority
JP
Japan
Prior art keywords
encoding
data
stream
picture
history
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
JP34315699A
Other languages
Japanese (ja)
Other versions
JP2000299856A5 (en
JP4139983B2 (en
Inventor
Takuya Kitamura
卓也 北村
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 JP34315699A priority Critical patent/JP4139983B2/en
Publication of JP2000299856A publication Critical patent/JP2000299856A/en
Publication of JP2000299856A5 publication Critical patent/JP2000299856A5/en
Application granted granted Critical
Publication of JP4139983B2 publication Critical patent/JP4139983B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Television Systems (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

PROBLEM TO BE SOLVED: To transmit history information with a transmission path with small capacity by generating a 2nd encoded stream by encoding an encoded stream and describing combination information representing the combination of an encoding history in encoding processing. SOLUTION: A history information multiplexer 103 multiplexes the current encoding parameter supplied from a decoding device 102 and past encoding parameter outputted by a history coding device 104 into video data of a base band supplied from the device 102 according to a format and outputs them to an history information demultiplexer 105. The demultiplexer 105 extracts the encoding parameters from the video data of a base band supplied from the multiplexer 103, selects an encoding parameter being most suitable to encoding this time among them, and outputs it together with a descriptor to a combined descriptor demultiplexing part 511.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、ストリーム生成装
置および方法、ストリーム伝送装置および方法、符号化
装置および方法、並びに記録媒体に関し、特に、MPEG規
格に基づいて符号化された符号化ビットストリームのGO
P(Group of Pictures)の構造を変更したり、符号化ビ
ットストリームのビットレートを変更するためのトラン
スコーディング装置に用いて好適なストリーム生成装置
および方法、ストリーム伝送装置および方法、符号化装
置および方法、並びに記録媒体に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a stream generation apparatus and method, a stream transmission apparatus and method, an encoding apparatus and method, and a recording medium, and more particularly, to a coded bit stream encoded based on the MPEG standard. GO
Stream generating apparatus and method, stream transmitting apparatus and method, encoding apparatus and method suitable for use in transcoding apparatus for changing the structure of P (Group of Pictures) or changing the bit rate of an encoded bit stream And a recording medium.

【0002】[0002]

【従来の技術】近年、テレビジョンプログラムを制作及
び放送する放送局においては、ビデオデータを圧縮/符
号化処理するために、MPEG(Moving Picture Experts G
roup)技術が一般的に使われるようになってきた。特
に、ビデオデータをテープなどのランダムアクセス可能
な記録媒体素材に記録する場合、及びビデオデータをケ
ーブルや衛星を介して伝送する場合には、このMPEG技術
がデファクトスタンダードになりつつある。
2. Description of the Related Art In recent years, a broadcasting station that produces and broadcasts a television program uses a moving picture expert (MPEG) to compress / encode video data.
roup) technology has become popular. In particular, when video data is recorded on a recording medium material that can be randomly accessed such as a tape, and when video data is transmitted via a cable or a satellite, the MPEG technology is becoming a de facto standard.

【0003】放送局において制作されたビデオプログラ
ムが各家庭に伝送されるまでの放送局における処理の一
例を簡単に説明する。まず、ビデオカメラとVTR(Video
Tape Recorder)が一体となったカムコーダに設けら
れたエンコーダによって、ソースビデオデータをエンコ
ード処理して磁気テープ上に記録する。この際、カムコ
ーダのエンコーダは、VTRのテープの記録フォーマット
に適するように、ソースビデオデータを符号化する。た
とえば、この磁気テープ上に記録されるMPEGビットスト
リームのGOP構造は、2フレームから1GOPが構成される
構造(たとえば、I,B,I,B,I,B,・・・・・・)と
される。また磁気テープ上に記録されているMPEGビット
ストリームのビットレートは、18Mbpsである。
[0003] An example of processing in a broadcasting station until a video program produced in the broadcasting station is transmitted to each home will be briefly described. First, a video camera and VTR (Video
The source video data is encoded and recorded on a magnetic tape by an encoder provided in a camcorder integrated with a tape recorder. At this time, the encoder of the camcorder encodes the source video data so as to be suitable for the recording format of the VTR tape. For example, the GOP structure of an MPEG bit stream recorded on the magnetic tape is a structure in which one GOP is composed of two frames (for example, I, B, I, B, I, B,...). Is done. The bit rate of the MPEG bit stream recorded on the magnetic tape is 18 Mbps.

【0004】次に、メイン放送局において、この磁気テ
ープ上に記録されたビデオビットストリームを編集する
編集処理を行う。そのために、磁気テープ上に記録され
たビデオビットストリームのGOP構造を、編集処理に適
したGOP構造に変換する。編集処理に適したGOP構造と
は、1GOPが1フレームから構成され、すべてのピクチ
ャがIピクチャであるGOP構造である。なぜなら、フレ
ーム単位で編集を行うためには、他のピクチャと相関の
ないIピクチャがもっとも適しているからである。実際
のオペレーションとしては、磁気テープ上に記録された
ビデオストリームを一旦デコードしてベースバンドのビ
デオデータに戻す。そして、そのベースバンドのビデオ
信号を、すべてのピクチャがIピクチャとなるように再
エンコードする。このようにデコード処理及び再エンコ
ード処理を行うことによって、編集処理に適したGOP構
造を有したビットストリームを生成することができる。
Next, the main broadcast station performs an editing process for editing the video bit stream recorded on the magnetic tape. For this purpose, the GOP structure of the video bit stream recorded on the magnetic tape is converted into a GOP structure suitable for editing processing. The GOP structure suitable for the editing process is a GOP structure in which one GOP is composed of one frame and all pictures are I pictures. This is because an I-picture that is not correlated with other pictures is most suitable for editing on a frame basis. As an actual operation, a video stream recorded on a magnetic tape is temporarily decoded and returned to baseband video data. Then, the baseband video signal is re-encoded so that all pictures become I pictures. By performing the decoding process and the re-encoding process in this manner, a bit stream having a GOP structure suitable for the editing process can be generated.

【0005】次に、上述した編集処理によって生成され
た編集ビデオプログラムを、メイン局から地方局に伝送
するために、編集ビデオプログラムのビットストリーム
を、伝送処理に適したGOP構造及びビットレートに変換
する。放送局間の伝送に適したGOP構造とは、たとえ
ば、1GOPが15フレームから構成されているGOP構造
(たとえば、I,B,B,P,B,B,P・…)であ
る。また、放送局間の伝送に適したビットレートは、一
般的に放送局間においては、光ファイバなどの高伝送容
量を有した専用線が設けらてれいるので、50Mbps以上
のハイビットレートであることが望ましい。具体的に
は、編集処理されたビデオプログラムのビットストリー
ムを一旦デコードしてベースバンドのビデオデータに戻
す。そして、そのベースバンドのビデオデータを上述し
た放送局間の伝送に適したGOP構造及びビットレートを
有するように再エンコードする。
Next, in order to transmit the edited video program generated by the above-described editing process from the main station to the local station, the bit stream of the edited video program is converted into a GOP structure and a bit rate suitable for the transmission process. I do. The GOP structure suitable for transmission between broadcast stations is, for example, a GOP structure in which one GOP is composed of 15 frames (for example, I, B, B, P, B, B, P...). A bit rate suitable for transmission between broadcast stations is generally a high bit rate of 50 Mbps or more because a dedicated line having a high transmission capacity such as an optical fiber is provided between broadcast stations. It is desirable. Specifically, the bit stream of the edited video program is once decoded and returned to baseband video data. Then, the baseband video data is re-encoded so as to have a GOP structure and a bit rate suitable for the above-described transmission between broadcast stations.

【0006】地方局においては、メイン局から伝送され
てきたビデオプログラムの中に、地方特有のコマーシャ
ルを挿入するために編集処理が行われる。つまり、上述
した編集処理と同じように、メイン局から伝送されてき
たビデオストリームを一旦デコードしてベースバンドの
ビデオデータに戻す。そして、そのベースバンドのビデ
オ信号を、すべてのピクチャがIピクチャとなるように
再エンコードすることによって、編集処理に適したGOP
構造を有したビットストリームを生成することができ
る。
[0006] In the local station, an editing process is performed to insert a local-specific commercial into a video program transmitted from the main station. That is, similarly to the above-described editing processing, the video stream transmitted from the main station is temporarily decoded and returned to the baseband video data. Then, by re-encoding the baseband video signal so that all pictures become I pictures, a GOP suitable for editing processing is obtained.
A bit stream having a structure can be generated.

【0007】続いて、この地方局において編集処理が行
われたビデオプログラムを各家庭に、ケーブルや衛星を
介して伝送するために、この伝送処理に適したGOP構造
及びビットレートに変換する。たとえば、各家庭に伝送
するための伝送処理に適したGOP構造とは、1GOPが15
フレームから構成されるGOP構造(たとえば、I,B,
B,P,B,B,P・…)であって、各家庭に伝送する
ための伝送処理に適したビットレートは、5Mbps程度の
低ビットレートである。具体的には、編集処理されたビ
デオプログラムのビットストリームを一旦デコードして
ベースバンドのビデオデータに戻す。そして、そのベー
スバンドのビデオデータを上述した伝送処理に適したGO
P構造及びビットレートを有するように再エンコードす
る。
Subsequently, the video program edited in the local station is converted into a GOP structure and a bit rate suitable for the transmission process in order to transmit the video program to each home via a cable or a satellite. For example, a GOP structure suitable for transmission processing for transmission to each home is such that one GOP is 15
GOP structure composed of frames (for example, I, B,
B, P, B, B, P...), And the bit rate suitable for transmission processing for transmission to each home is a low bit rate of about 5 Mbps. Specifically, the bit stream of the edited video program is once decoded and returned to baseband video data. Then, the baseband video data is transmitted to the GO
Re-encode to have P structure and bit rate.

【0008】[0008]

【発明が解決しようとする課題】以上の説明からも理解
できるように、放送局から各家庭にビデオプログラムが
伝送される間に、複数回の復号処理及び符号化処理が繰
り返されている。実際には、放送局における処理は上述
した信号処理以外にもさまざまな信号処理が必要であ
り、そのたびに復号処理及び符号化処理を繰り返さなけ
ればならない。
As can be understood from the above description, the decoding process and the encoding process are repeated a plurality of times while the video program is transmitted from the broadcasting station to each home. Actually, processing at a broadcasting station requires various signal processings in addition to the above-described signal processing, and the decoding processing and the encoding processing must be repeated each time.

【0009】しかしながら、MPEG規格に基づく符号化処
理及び復号処理は、100%可逆の処理ではないことは
良く知られている。つまり、エンコードされる前のベー
スバンドのビデオデータと、デコードされた後のビデオ
データは100%同じでは無く、この符号化処理及び復
号処理によって画質が劣化している。つまり、上述した
ように、デコード処理及びエンコード処理を繰り返す
と、その処理の度に、画質が劣化してしまうと言う問題
があった。別の言葉で表現すると、デコード/エンコー
ド処理を繰り返す毎に、画質の劣化が蓄積されてしま
う。
However, it is well known that the encoding process and the decoding process based on the MPEG standard are not 100% reversible processes. That is, the baseband video data before encoding and the video data after decoding are not 100% the same, and the image quality is degraded by the encoding and decoding processes. That is, as described above, if the decoding process and the encoding process are repeated, there is a problem that the image quality is deteriorated every time the process is performed. In other words, each time decoding / encoding processing is repeated, deterioration in image quality is accumulated.

【0010】本発明は、このような状況に鑑みてなされ
たものであり、MPEG規格に基づいて符号化された符号化
ビットストリームのGOP(Group of Pictures)の構造を
変更するために復号及び符号化処理を繰り返したとして
も画質劣化の発生しないトランスコーディングシステム
を実現できるようにするものである。
[0010] The present invention has been made in view of such a situation, and has been developed in order to change the structure of a GOP (Group of Pictures) of an encoded bit stream encoded based on the MPEG standard. This makes it possible to realize a transcoding system in which image quality does not deteriorate even if the image processing is repeated.

【0011】[0011]

【課題を解決するための手段】請求項1に記載のストリ
ーム生成装置は、第1の符号化ストリームの過去の符号
化処理における符号化履歴を検出する検出手段と、検出
手段の検出結果を利用して、第1の符号化ストリームを
符号化して第2の符号化ストリームを生成する符号化手
段と、第2の符号化ストリームに対して、それまでの符
号化処理における符号化履歴の組み合わせを表す組み合
わせ情報を記述する記述手段とを備えることを特徴とす
る。
According to a first aspect of the present invention, there is provided a stream generation apparatus that uses a detection unit that detects an encoding history in a past encoding process of a first encoded stream and uses a detection result of the detection unit. Then, a combination of an encoding unit that encodes the first encoded stream to generate a second encoded stream, and a combination of the encoding history in the encoding process performed so far with respect to the second encoded stream. And description means for describing the combination information to be represented.

【0012】前記符号化手段には、MPEG方式で符号化を
行わせることができる。
[0012] The encoding means can perform encoding by the MPEG system.

【0013】前記記述手段は、前記符号化履歴の組み合
わせを表す組み合わせ情報を、前記MPEG方式の前記第2
のストリームのuser_dataとして記述させることができ
る。
[0013] The description means stores the combination information representing the combination of the coding histories in the second format of the MPEG system.
Stream can be described as user_data.

【0014】請求項4に記載のストリーム生成方法は、
第1の符号化ストリームの過去の符号化処理における符
号化履歴を検出する検出ステップと、検出ステップでの
検出結果を利用して、第1の符号化ストリームを符号化
して第2の符号化ストリームを生成する符号化ステップ
と、第2の符号化ストリームに対して、それまでの符号
化処理における符号化履歴の組み合わせを表す組み合わ
せ情報を記述する記述ステップとを含むことを特徴とす
る。
According to a fourth aspect of the present invention, there is provided a stream generation method comprising:
A detection step of detecting an encoding history in a past encoding process of the first encoded stream; and a second encoded stream obtained by encoding the first encoded stream by using a detection result in the detection step. And a description step of writing, for the second coded stream, combination information indicating a combination of coding histories in the previous coding processing.

【0015】請求項5に記載の記録媒体は、入力された
第1の符号化ストリームから第2の符号化ストリームを
生成し、出力するストリーム生成装置に、第1の符号化
ストリームの過去の符号化処理における符号化履歴を検
出する検出ステップと、検出ステップでの検出結果を利
用して、第1の符号化ストリームを符号化して第2の符
号化ストリームを生成する符号化ステップと、第2の符
号化ストリームに対して、それまでの符号化処理におけ
る符号化履歴の組み合わせを表す組み合わせ情報を記述
する記述ステップとを含む処理を実行させるコンピュー
タが読み取り可能なプログラムを提供することを特徴と
する。
According to a fifth aspect of the present invention, the recording medium according to the first aspect of the invention generates a second encoded stream from the input first encoded stream and outputs the second encoded stream to a stream generating apparatus which outputs the past encoded stream of the first encoded stream. A detecting step of detecting an encoding history in the encoding process, an encoding step of encoding the first encoded stream to generate a second encoded stream by using a detection result in the detecting step, And a description step of describing combination information indicating a combination of encoding histories in the encoding processing performed up to that time. .

【0016】請求項1に記載のストリーム生成装置、請
求項4に記載のストリーム生成方法、および請求項5に
記載の記録媒体のプログラムにおいては、第2の符号化
ストリームに対して、それまでの符号化処理における符
号化履歴の組み合わせを表す組み合わせ情報が記述され
る。
In the stream generating apparatus according to the first aspect, the stream generating method according to the fourth aspect, and the program of the recording medium according to the fifth aspect, the second encoded stream is Combination information indicating a combination of encoding histories in encoding processing is described.

【0017】請求項6に記載のストリーム伝送装置は、
過去の符号化処理において使用された複数の符号化パラ
メータから所定の符号化パラメータを選択的に組み合わ
せる組み合わせ手段と、組み合わせ手段により組み合わ
された符号化パラメータの履歴を表す符号化履歴情報を
生成する生成手段と、生成手段により生成された符号化
履歴情報を、符号化ストリームに重乗してメディアに伝
送する伝送手段とを備えることを特徴とする。
[0017] The stream transmission apparatus according to claim 6 is
Combining means for selectively combining predetermined encoding parameters from a plurality of encoding parameters used in past encoding processing, and generation for generating encoding history information indicating the history of the encoding parameters combined by the combining means Means, and transmission means for superimposing the encoded history information generated by the generating means on the encoded stream and transmitting the information to the medium.

【0018】前記符号化ストリームは、MPEG方式で符号
化されている符号化ストリームとすることができる。
[0018] The coded stream may be a coded stream coded according to the MPEG system.

【0019】前記重乗手段には、前記符号化履歴情報
を、前記符号化ストリームにuser_dataとして重乗させ
ることができる。
[0019] The multiplying means can multiply the coding history information as the user_data on the coded stream.

【0020】請求項9に記載のストリーム伝送方法は、
過去の符号化処理において使用された複数の符号化パラ
メータから所定の符号化パラメータを選択的に組み合わ
せる組み合わせステップと、組み合わせステップの処理
により組み合わされた符号化パラメータの履歴を表す符
号化履歴情報を生成する生成ステップと、生成ステップ
の処理により生成された符号化履歴情報を、符号化スト
リームに重乗して前記メディアに伝送する伝送ステップ
とを含むことを特徴とする。
A stream transmission method according to a ninth aspect is characterized in that:
Generating a combination step of selectively combining predetermined coding parameters from a plurality of coding parameters used in the past coding processing, and coding history information indicating a history of the combined coding parameters by the processing of the combination step; And transmitting the encoded history information generated by the process of the generating step to the medium by multiplying the encoded stream by the encoded stream information.

【0021】請求項10に記載の記録媒体のプログラム
は、過去の符号化処理において使用された複数の符号化
パラメータから所定の符号化パラメータを選択的に組み
合わせる組み合わせステップと、組み合わせステップの
処理により組み合わされた符号化パラメータの履歴を表
す符号化履歴情報を生成する生成ステップと、生成ステ
ップの処理により生成された符号化履歴情報を、符号化
ストリームに重乗してメディアに伝送する伝送ステップ
とを含むことを特徴とする。
According to a tenth aspect of the present invention, there is provided a program for a recording medium, comprising: a combination step of selectively combining predetermined coding parameters from a plurality of coding parameters used in past coding processing; Generating encoding history information representing the history of the encoded parameters, and transmitting the encoding history information generated by the processing of the generating step to the media by multiplying the encoded stream by the encoding step. It is characterized by including.

【0022】請求項6に記載のストリーム伝送装置、請
求項9に記載のストリーム伝送方法、および請求項10
に記載の記録媒体のプログラムにおいては、過去の符号
化処理において使用された複数の符号化パラメータから
所定の符号化パラメータが選択的に組み合わされ、組み
合わされた符号化パラメータの符号化履歴情報が生成さ
れ、符号化ストリームに重乗され、伝送される。
A stream transmission device according to claim 6, a stream transmission method according to claim 9, and a stream transmission device according to claim 10.
In the program of the recording medium described in the above, predetermined coding parameters are selectively combined from a plurality of coding parameters used in the past coding process, and coding history information of the combined coding parameters is generated. Is multiplied by the coded stream and transmitted.

【0023】請求項11に記載の符号化装置は、第1の
符号化ストリームに記述されている、その第1の符号化
ストリームのそれまでの符号化処理における符号化パラ
メータの組み合わせを表す組み合わせ情報を検出する検
出手段と、検出手段により検出された組み合わせ情報に
基づいて、第1の符号化ストリームのそれまでの符号化
処理における符号化パラメータを抽出する抽出手段と、
抽出手段により抽出された符号化パラメータに基づい
て、第1の符号化ストリームを第2の符号化ストリーム
に符号化する符号化手段とを備えることを特徴とする。
According to the present invention, there is provided an encoding apparatus, wherein combination information indicating a combination of encoding parameters described in a first encoded stream in a previous encoding process of the first encoded stream. Detecting means for detecting the combination of the first and second encoding streams, based on the combination information detected by the detecting means,
Encoding means for encoding the first encoded stream into the second encoded stream based on the encoding parameters extracted by the extracting means.

【0024】前記符号化手段には、MPEG方式で符号化を
行わせることができる。
[0024] The encoding means can perform encoding by the MPEG system.

【0025】前記検出手段には、前記組み合わせ情報
を、前記第1の符号化ストリームのuser_dataから検出
させることができる。
The detecting means can detect the combination information from user_data of the first coded stream.

【0026】請求項14に記載の符号化方法は、第1の
符号化ストリームに記述されている、その第1の符号化
ストリームのそれまでの符号化処理における符号化パラ
メータの組み合わせを表す組み合わせ情報を検出する検
出ステップと、検出ステップの処理により検出された組
み合わせ情報に基づいて、第1の符号化ストリームのそ
れまでの符号化処理における符号化パラメータを抽出す
る抽出ステップと、抽出ステップの処理により抽出され
た符号化パラメータに基づいて、第1の符号化ストリー
ムを第2の符号化ストリームに符号化する符号化ステッ
プとを含むことを特徴とする。
According to a fourteenth aspect of the present invention, there is provided an encoding method, comprising: combination information indicating a combination of encoding parameters described in a first encoded stream in a previous encoding process of the first encoded stream. , An extraction step of extracting an encoding parameter in the previous encoding processing of the first encoded stream based on the combination information detected by the processing of the detection step, and a processing of the extraction step. Encoding the first encoded stream into a second encoded stream based on the extracted encoding parameters.

【0027】請求項15に記載の記録媒体のプログラム
は、第1の符号化ストリームに記述されている、その第
1の符号化ストリームのそれまでの符号化処理における
符号化パラメータの組み合わせを表す組み合わせ情報を
検出する検出ステップと、検出ステップの処理により検
出された組み合わせ情報に基づいて、第1の符号化スト
リームのそれまでの符号化処理における符号化パラメー
タを抽出する抽出ステップと、抽出ステップの処理によ
り抽出された符号化パラメータに基づいて、第1の符号
化ストリームを第2の符号化ストリームに符号化する符
号化ステップとを含むことを特徴とする。
[0027] The program of the recording medium according to claim 15 is a combination which is described in a first encoded stream and represents a combination of encoding parameters in the encoding process of the first encoded stream up to then. A detection step of detecting information, an extraction step of extracting an encoding parameter in the previous encoding processing of the first encoded stream based on the combination information detected by the processing of the detection step, and a processing of the extraction step Coding the first coded stream into a second coded stream based on the coding parameters extracted by (1).

【0028】請求項11に記載の符号化装置、請求項1
4に記載の符号化方法、および請求項15に記載の記録
媒体のプログラムにおいては、組み合わせ情報に基づい
て、それまでの符号化処理における符号化パラメータが
抽出され、抽出された符号化パラメータに基づいて、第
1の符号化ストリームが第2の符号化ストリームに符号
化される。
[0028] The encoding device according to claim 11, wherein
In the encoding method according to the fourth aspect and the recording medium program according to the fifteenth aspect, the encoding parameters in the encoding process up to that point are extracted based on the combination information, and the extracted encoding parameters are used based on the extracted encoding parameters. Thus, the first encoded stream is encoded into the second encoded stream.

【0029】[0029]

【発明の実施の形態】以下に、本発明を適用したトラン
スコーダについて説明するが、その前に、動画像信号の
圧縮符号化について説明する。なお、本明細書において
システムの用語は、複数の装置、手段などにより構成さ
れる全体的な装置を意味するものである。
DESCRIPTION OF THE PREFERRED EMBODIMENTS A transcoder to which the present invention is applied will be described below. Before that, compression coding of a moving picture signal will be described. In this specification, the term “system” refers to an entire device including a plurality of devices and units.

【0030】例えば、テレビ会議システム、テレビ電話
システムなどのように、動画像信号を遠隔地に伝送する
システムにおいては、伝送路を効率良く利用するため、
映像信号のライン相関やフレーム間相関を利用して、画
像信号を圧縮符号化するようになされている。
For example, in a system for transmitting a moving image signal to a remote place, such as a video conference system and a video telephone system, in order to use a transmission path efficiently,
An image signal is compression-encoded using a line correlation or an inter-frame correlation of a video signal.

【0031】ライン相関を利用すると、画像信号を、例
えばDCT(離散コサイン変換)処理するなどして圧縮す
ることができる。
When the line correlation is used, the image signal can be compressed by, for example, DCT (Discrete Cosine Transform) processing.

【0032】また、フレーム間相関を利用すると、画像
信号をさらに圧縮して符号化することが可能となる。例
えば図1に示すように、時刻t1乃至t3において、フ
レーム画像PC1乃至PC3がそれぞれ発生している場
合、フレーム画像PC1およびPC2の画像信号の差を
演算して、PC12を生成し、また、フレーム画像PC
2およびPC3の差を演算して、PC23を生成する。
通常、時間的に隣接するフレームの画像は、それ程大き
な変化を有していないため、両者の差を演算すると、そ
の差分信号は小さな値のものとなる。そこで、この差分
信号を符号化すれば、符号量を圧縮することができる。
The use of the inter-frame correlation makes it possible to further compress and encode the image signal. For example, as shown in FIG. 1, when the frame images PC1 to PC3 are generated from time t1 to time t3, respectively, the difference between the image signals of the frame images PC1 and PC2 is calculated to generate PC12, and Image PC
The difference between PC2 and PC3 is calculated to generate PC23.
Normally, the images of frames temporally adjacent to each other do not have such a large change. Therefore, when the difference between them is calculated, the difference signal has a small value. Therefore, if the difference signal is encoded, the code amount can be compressed.

【0033】しかしながら、差分信号のみを伝送したの
では、元の画像を復元することができない。そこで、各
フレームの画像を、Iピクチャ、PピクチャまたはBピ
クチャの3種類のピクチャタイプのいずれかとし、画像
信号を圧縮符号化するようにしている。
However, if only the difference signal is transmitted, the original image cannot be restored. Therefore, the image of each frame is set to one of three types of pictures, i.e., I picture, P picture or B picture, and the image signal is compression-coded.

【0034】すなわち、例えば図2に示すように、フレ
ームF1乃至F17までの17フレームの画像信号をグ
ループオブピクチャ(GOP)とし、処理の1単位とする。
そして、その先頭のフレームF1の画像信号はIピクチ
ャとして符号化し、第2番目のフレームF2はBピクチ
ャとして、また第3番目のフレームF3はPピクチャと
して、それぞれ処理する。以下、第4番目以降のフレー
ムF4乃至F17は、BピクチャまたはPピクチャとし
て交互に処理する。
That is, as shown in FIG. 2, for example, image signals of 17 frames from F1 to F17 are set as a group of pictures (GOP), and are set as one unit of processing.
Then, the image signal of the first frame F1 is coded as an I picture, the second frame F2 is processed as a B picture, and the third frame F3 is processed as a P picture. Hereinafter, the fourth and subsequent frames F4 to F17 are alternately processed as B pictures or P pictures.

【0035】Iピクチャの画像信号としては、その1フ
レーム分の画像信号をそのまま伝送する。これに対し
て、Pピクチャの画像信号としては、基本的には、図2
に示すように、それより時間的に先行するIピクチャま
たはPピクチャの画像信号からの差分を伝送する。さら
にBピクチャの画像信号としては、基本的には、図3に
示すように、時間的に先行するフレームまたは後行する
フレームの両方の平均値からの差分を求め、その差分を
符号化する。
As an I-picture image signal, an image signal for one frame is transmitted as it is. On the other hand, as an image signal of a P picture, basically, as shown in FIG.
As shown in (1), a difference from an image signal of an I picture or a P picture which is earlier in time is transmitted. Further, as a B picture image signal, basically, as shown in FIG. 3, a difference from an average value of both temporally preceding and succeeding frames is obtained, and the difference is encoded.

【0036】図4は、このようにして、動画像信号を符
号化する方法の原理を示している。同図に示すように、
最初のフレームF1は、Iピクチャとして処理されるた
め、そのまま伝送データF1Xとして伝送路に伝送され
る(画像内符号化)。これに対して、第2のフレームF
2は、Bピクチャとして処理されるため、時間的に先行
するフレームF1と、時間的に後行するフレームF3の
平均値との差分が演算され、その差分が伝送データF2
Xとして伝送される。
FIG. 4 shows the principle of the method for encoding a moving picture signal in this way. As shown in the figure,
Since the first frame F1 is processed as an I picture, it is directly transmitted as transmission data F1X to the transmission path (intra-picture encoding). On the other hand, the second frame F
2 is processed as a B picture, the difference between the temporally preceding frame F1 and the average value of the temporally succeeding frame F3 is calculated, and the difference is calculated as the transmission data F2.
Transmitted as X.

【0037】ただし、このBピクチャとしての処理は、
さらに細かく説明すると、4種類存在する。その第1の
処理は、元のフレームF2のデータをそのまま伝送デー
タF2Xとして伝送するものであり(SP1)(イント
ラ符号化)、Iピクチャにおける場合と同様の処理とな
る。第2の処理は、時間的に後のフレームF3からの差
分を演算し、その差分(SP2)を伝送するものである
(後方予測符号化)。第3の処理は、時間的に先行する
フレームF1との差分(SP3)を伝送するものである
(前方予測符号化)。さらに第4の処理は、時間的に先
行するフレームF1と後行するフレームF3の平均値と
の差分(SP4)を生成し、これを伝送データF2Xと
して伝送するものである(両方向予測符号化)。
However, the processing as a B picture is as follows.
More specifically, there are four types. The first processing is to transmit the data of the original frame F2 as it is as the transmission data F2X (SP1) (intra coding), and is the same processing as in the case of the I picture. The second process is to calculate the difference from the temporally later frame F3 and transmit the difference (SP2) (backward prediction coding). The third process is to transmit a difference (SP3) from the temporally preceding frame F1 (forward prediction coding). Further, the fourth processing is to generate a difference (SP4) between the average value of the temporally preceding frame F1 and the average value of the following frame F3, and transmit this as transmission data F2X (bidirectional predictive coding). .

【0038】実際には、上述した4つの方法のうちの伝
送データが最も少なくなる方法が採用される。
In practice, of the four methods described above, the method that minimizes the transmission data is adopted.

【0039】なお、差分データを伝送するとき、差分を
演算する対象となるフレームの画像(参照画像)との間
の動きベクトルx1(フレームF1とF2の間の動きベ
クトル)(前方予測の場合)、もしくはx2(フレーム
F3とF2の間の動きベクトル)(後方予測の場合)、
またはx1とx2の両方(両方向予測の場合)が、差分
データとともに伝送される。
When transmitting the difference data, a motion vector x1 (a motion vector between frames F1 and F2) between the image of the frame (reference image) for which the difference is to be calculated (in the case of forward prediction) Or x2 (the motion vector between frames F3 and F2) (for backward prediction),
Alternatively, both x1 and x2 (in the case of bidirectional prediction) are transmitted together with the difference data.

【0040】また、PピクチャのフレームF3は、時間
的に先行するフレームF1を参照画像として、このフレ
ームとの差分信号(SP3)と、動きベクトルx3が演
算され、これが伝送データF3Xとして伝送される(前
方予測符号化)。あるいはまた、元のフレームF3のデ
ータが、そのままデータF3Xとして伝送される(SP
1)(イントラ符号化)。これらの方法のうち、Bピク
チャにおける場合と同様に、伝送データがより少なくな
る方法が選択される。
Further, as for the frame F3 of the P picture, a difference signal (SP3) from this frame and a motion vector x3 are calculated using the frame F1 preceding temporally as a reference image, and this is transmitted as transmission data F3X. (Forward prediction coding). Alternatively, the data of the original frame F3 is transmitted as it is as data F3X (SP
1) (Intra coding). Among these methods, a method in which the amount of transmission data is smaller is selected as in the case of the B picture.

【0041】図5は、上述した原理に基づいて、動画像
信号を符号化して伝送し、これを復号する装置の構成例
を示している。符号化装置1は、入力された映像信号を
符号化し、伝送路としての記録媒体3に伝送するように
なされている。そして、復号装置2は、記録媒体3に記
録された信号を再生し、これを復号して出力するように
なされている。
FIG. 5 shows an example of the configuration of an apparatus that encodes and transmits a moving image signal based on the principle described above and decodes it. The encoding device 1 encodes an input video signal and transmits the encoded video signal to a recording medium 3 as a transmission path. The decoding device 2 reproduces the signal recorded on the recording medium 3, decodes the signal, and outputs the decoded signal.

【0042】符号化装置1においては、入力された映像
信号が前処理回路11に入力され、そこで輝度信号と色
信号(本実施の形態の場合、色差信号)が分離され、そ
れぞれA/D変換器12,13でアナログ信号からデジタ
ル信号に変換される。A/D変換器12,13によりデジ
タル信号に変換された映像信号は、フレームメモリ14
に供給され、記憶される。フレームメモリ14は、輝度
信号を輝度信号フレームメモリ15に、また、色差信号
を色差信号フレームメモリ16に、それぞれ記憶させ
る。
In the encoding device 1, the input video signal is input to the pre-processing circuit 11, where the luminance signal and the chrominance signal (color difference signal in the case of the present embodiment) are separated and A / D converted. The signals are converted from analog signals to digital signals by the devices 12 and 13. A video signal converted into a digital signal by the A / D converters 12 and 13 is transmitted to a frame memory 14.
And stored. The frame memory 14 stores the luminance signal in the luminance signal frame memory 15 and stores the color difference signal in the color difference signal frame memory 16, respectively.

【0043】フォーマット変換回路17は、フレームメ
モリ14に記憶されたフレームフォーマットの信号を、
ブロックフォーマットの信号に変換する。すなわち、図
6に示すように、フレームメモリ14に記憶された映像
信号は、1ライン当りHドットのラインがVライン集め
られた、図6(A)に示すようなフレームフォーマットの
データとされている。フォーマット変換回路17は、こ
の1フレームの信号を、図6(B)に示すように、16ラ
インを単位としてM個のスライスに区分する。そして、
各スライスは、M個のマクロブロックに分割される。マ
クロブロックは、図6(C)に示すように、16×16個
の画素(ドット)に対応する輝度信号により構成され、
この輝度信号は、さらに8×8ドットを単位とするブロ
ックY[1]乃至Y[4]に区分される。そして、この
16×16ドットの輝度信号には、8×8ドットのCb
信号と、8×8ドットのCr信号が対応される。
The format conversion circuit 17 converts the frame format signal stored in the frame memory 14
Convert to block format signal. That is, as shown in FIG. 6, the video signal stored in the frame memory 14 is data in a frame format as shown in FIG. 6A in which V lines of H dots are collected per line. I have. As shown in FIG. 6B, the format conversion circuit 17 divides the signal of one frame into M slices in units of 16 lines. And
Each slice is divided into M macroblocks. As shown in FIG. 6C, the macro block is configured by luminance signals corresponding to 16 × 16 pixels (dots).
This luminance signal is further divided into blocks Y [1] to Y [4] in units of 8 × 8 dots. The luminance signal of 16 × 16 dots includes Cb of 8 × 8 dots.
The signal corresponds to an 8 × 8 dot Cr signal.

【0044】このように、ブロックフォーマットに変換
されたデータは、フォーマット変換回路17からエンコ
ーダ18に供給され、ここでエンコード(符号化)が行
われる。その詳細については、図7を参照して後述す
る。
The data converted into the block format is supplied from the format conversion circuit 17 to the encoder 18, where the data is encoded. The details will be described later with reference to FIG.

【0045】エンコーダ18によりエンコードされた信
号は、ビットストリームとして伝送路に出力される。例
えば記録回路19に供給され、デジタル信号として記録
媒体3に記録される。
The signal encoded by the encoder 18 is output to a transmission line as a bit stream. For example, it is supplied to the recording circuit 19 and recorded on the recording medium 3 as a digital signal.

【0046】復号装置2の再生回路30により記録媒体
3より再生されたデータは、デコーダ31に供給され、
デコードされる。デコーダ31の詳細については、図1
2を参照して後述する。
The data reproduced from the recording medium 3 by the reproduction circuit 30 of the decoding device 2 is supplied to a decoder 31.
Decoded. For details of the decoder 31, see FIG.
2 will be described later.

【0047】デコーダ31によりデコードされたデータ
は、フォーマット変換回路32に入力され、ブロックフ
ォーマットからフレームフォーマットに変換される。そ
して、フレームフォーマットの輝度信号は、フレームメ
モリ33の輝度信号フレームメモリ34に供給されて記
憶され、色差信号は色差信号フレームメモリ35に供給
されて記憶される。輝度信号フレームメモリ34と色差
信号フレームメモリ35から読み出された輝度信号と色
差信号は、それぞれD/A変換器36,37によりアナ
ログ信号に変換され、後処理回路38に供給される。後
処理回路38は、輝度信号と色差信号を合成して出力す
る。
The data decoded by the decoder 31 is input to a format conversion circuit 32 and converted from a block format to a frame format. The luminance signal in the frame format is supplied to and stored in the luminance signal frame memory 34 of the frame memory 33, and the color difference signal is supplied to and stored in the color difference signal frame memory 35. The luminance signal and the color difference signal read from the luminance signal frame memory 34 and the color difference signal frame memory 35 are converted into analog signals by D / A converters 36 and 37, respectively, and supplied to a post-processing circuit 38. The post-processing circuit 38 combines and outputs the luminance signal and the color difference signal.

【0048】次に図7を参照して、エンコーダ18の構
成について説明する。符号化される画像データは、マク
ロブロック単位で動きベクトル検出回路50に入力され
る。動きベクトル検出回路50は、予め設定されている
所定のシーケンスに従って、各フレームの画像データ
を、Iピクチャ、Pピクチャ、またはBピクチャとして
処理する。シーケンシャルに入力される各フレームの画
像を、I,P、またはBのいずれのピクチャとして処理
するかは、予め定められている(例えば、図2と図3に
示したように、フレームF1乃至F17により構成され
るグループオブピクチャが、I,B,P,B,P,・・
・B,Pとして処理される)。
Next, the configuration of the encoder 18 will be described with reference to FIG. The image data to be encoded is input to the motion vector detection circuit 50 in macroblock units. The motion vector detection circuit 50 processes the image data of each frame as an I picture, a P picture, or a B picture according to a predetermined sequence set in advance. Whether the image of each frame that is sequentially input is processed as one of I, P, and B pictures is determined in advance (for example, as shown in FIGS. 2 and 3, frames F1 to F17). Are grouped by I, B, P, B, P,.
-Processed as B, P).

【0049】Iピクチャとして処理されるフレーム(例
えば、フレームF1)の画像データは、動きベクトル検
出回路50からフレームメモリ51の前方原画像部51
aに転送、記憶され、Bピクチャとして処理されるフレ
ーム(例えば、フレームF2)の画像データは、原画像
部51bに転送、記憶され、Pピクチャとして処理され
るフレーム(例えば、フレームF3)の画像データは、
後方原画像部51cに転送、記憶される。
The image data of a frame (for example, frame F1) processed as an I picture is obtained from the motion vector detecting circuit 50 by using the forward original image section 51 of the frame memory 51.
The image data of a frame (for example, frame F2) transferred and stored in a and processed as a B picture is transferred to the original image unit 51b, stored, and processed as a P picture (for example, frame F3). Data is,
The data is transferred and stored in the rear original image section 51c.

【0050】また、次のタイミングにおいて、さらにB
ピクチャ(フレームF4)またはPピクチャ(フレーム
F5)として処理すべきフレームの画像が入力されたと
き、それまで後方原画像部51cに記憶されていた最初
のPピクチャ(フレームF3)の画像データが、前方原
画像部51aに転送され、次のBピクチャ(フレームF
4)の画像データが、参照原画像部51bに記憶(上書
き)され、次のPピクチャ(フレームF5)の画像デー
タが、後方原画像部51cに記憶(上書き)される。こ
のような動作が順次繰り返される。
At the next timing, B
When an image of a frame to be processed as a picture (frame F4) or a P picture (frame F5) is input, the image data of the first P picture (frame F3) stored in the rear original image section 51c until then is The image is transferred to the front original image section 51a and the next B picture (frame F
The image data of 4) is stored (overwritten) in the reference original image section 51b, and the image data of the next P picture (frame F5) is stored (overwritten) in the rear original image section 51c. Such operations are sequentially repeated.

【0051】フレームメモリ51に記憶された各ピクチ
ャの信号は、そこから読み出され、予測モード切り替え
回路52において、フレーム予測モード処理、またはフ
ィールド予測モード処理が行なわれる。
The signal of each picture stored in the frame memory 51 is read therefrom, and the prediction mode switching circuit 52 performs frame prediction mode processing or field prediction mode processing.

【0052】さらにまた、予測判定回路54の制御の下
に、演算器53において、画像内予測、前方予測、後方
予測、または両方向予測の演算が行なわれる。これらの
処理のうち、いずれの処理を行なうかは、予測誤差信号
(処理の対象とされている参照画像と、これに対する予
測画像との差分)に対応して決定される。このため、動
きベクトル検出回路50は、この判定に用いられる予測
誤差信号の絶対値和(自乗和でもよい)を生成する。
Further, under the control of the prediction determination circuit 54, the arithmetic unit 53 performs calculations of intra-picture prediction, forward prediction, backward prediction, or bidirectional prediction. Which of these processes is to be performed is determined according to the prediction error signal (the difference between the reference image to be processed and the predicted image corresponding to the reference image). Therefore, the motion vector detection circuit 50 generates a sum of absolute values (or a sum of squares) of the prediction error signal used for this determination.

【0053】ここで、予測モード切り替え回路52にお
けるフレーム予測モードとフィールド予測モードについ
て説明する。
Here, the frame prediction mode and the field prediction mode in the prediction mode switching circuit 52 will be described.

【0054】フレーム予測モードが設定された場合にお
いては、予測モード切り替え回路52は、動きベクトル
検出回路50より供給される4個の輝度ブロックY
[1]乃至Y[4]を、そのまま後段の演算器53に出
力する。すなわち、この場合においては、図8に示すよ
うに、各輝度ブロックに奇数フィールドのラインのデー
タと、偶数フィールドのラインのデータとが混在した状
態となっている。このフレーム予測モードにおいては、
4個の輝度ブロック(マクロブロック)を単位として予
測が行われ、4個の輝度ブロックに対して1個の動きベ
クトルが対応される。
When the frame prediction mode is set, the prediction mode switching circuit 52 controls the four luminance blocks Y supplied from the motion vector detection circuit 50.
[1] to Y [4] are directly output to the arithmetic unit 53 at the subsequent stage. That is, in this case, as shown in FIG. 8, the data of the odd field lines and the data of the even field lines are mixed in each luminance block. In this frame prediction mode,
Prediction is performed in units of four luminance blocks (macroblocks), and one motion vector corresponds to four luminance blocks.

【0055】これに対して、予測モード切り替え回路5
2は、フィールド予測モードにおいては、図8に示す構
成で動きベクトル検出回路50より入力される信号を、
図9に示すように、4個の輝度ブロックのうち、輝度ブ
ロックY[1]とY[2]を、例えば奇数フィールドの
ラインのドットだけで構成させ、他の2個の輝度ブロッ
クY[3]とY[4]を、偶数フィールドのラインのド
ットだけで構成させて、演算器53に出力する。この場
合においては、2個の輝度ブロックY[1]とY[2]
に対して、1個の動きベクトルが対応され、他の2個の
輝度ブロックY[3]とY[4]に対して、他の1個の
動きベクトルが対応される。
On the other hand, the prediction mode switching circuit 5
2, in the field prediction mode, the signal input from the motion vector detection circuit 50 having the configuration shown in FIG.
As shown in FIG. 9, of the four luminance blocks, the luminance blocks Y [1] and Y [2] are constituted by, for example, only the dots of the lines of the odd-numbered fields, and the other two luminance blocks Y [3 ] And Y [4] are composed of only the dots of the lines of the even-numbered fields and output to the arithmetic unit 53. In this case, two luminance blocks Y [1] and Y [2]
, One motion vector is associated, and the other two luminance blocks Y [3] and Y [4] are associated with another one motion vector.

【0056】動きベクトル検出回路50は、フレーム予
測モードにおける予測誤差の絶対値和、およびフィール
ド予測モードにおける予測誤差の絶対値和を予測モード
切り替え回路52に出力する。予測モード切り替え回路
52は、フレーム予測モードとフィールド予測モードに
おける予測誤差の絶対値和を比較し、その値が小さい予
測モードに対応する処理を施して、データを演算器53
に出力する。
The motion vector detecting circuit 50 outputs to the prediction mode switching circuit 52 the absolute value sum of the prediction error in the frame prediction mode and the absolute value sum of the prediction error in the field prediction mode. The prediction mode switching circuit 52 compares the absolute value sums of the prediction errors in the frame prediction mode and the field prediction mode, performs processing corresponding to the prediction mode having a small value, and outputs the data to the arithmetic unit 53
Output to

【0057】ただし、このような処理は、実際には動き
ベクトル検出回路50で行われる。すなわち、動きベク
トル検出回路50は、決定されたモードに対応する構成
の信号を予測モード切り替え回路52に出力し、予測モ
ード切り替え回路52は、その信号を、そのまま後段の
演算器53に出力する。
However, such processing is actually performed by the motion vector detection circuit 50. That is, the motion vector detection circuit 50 outputs a signal having a configuration corresponding to the determined mode to the prediction mode switching circuit 52, and the prediction mode switching circuit 52 outputs the signal as it is to the subsequent computing unit 53.

【0058】なお、色差信号は、フレーム予測モードの
場合、図8に示すように、奇数フィールドのラインのデ
ータと偶数フィールドのラインのデータとが混在する状
態で、演算器53に供給される。また、フィールド予測
モードの場合、図9に示すように、各色差ブロックC
b,Crの上半分(4ライン)が、輝度ブロックY
[1],Y[2]に対応する奇数フィールドの色差信号
とされ、下半分(4ライン)が、輝度ブロックY
[3],Y[4]に対応する偶数フィールドの色差信号
とされる。
Note that, in the frame prediction mode, the color difference signal is supplied to the arithmetic unit 53 in a state where the data of the lines of the odd fields and the data of the lines of the even fields are mixed, as shown in FIG. In the case of the field prediction mode, as shown in FIG.
The upper half (4 lines) of b and Cr is the luminance block Y
The color difference signals of the odd fields corresponding to [1] and Y [2] are used, and the lower half (4 lines)
These are color difference signals of even fields corresponding to [3] and Y [4].

【0059】また、動きベクトル検出回路50は、以下
に示すようにして、予測判定回路54において、画像内
予測、前方予測、後方予測、または両方向予測のいずれ
の予測を行なうかを決定するための予測誤差の絶対値和
を生成する。
Further, the motion vector detecting circuit 50 determines whether to perform intra-picture prediction, forward prediction, backward prediction, or bidirectional prediction in the prediction determination circuit 54 as described below. Generate the sum of absolute values of prediction errors.

【0060】すなわち、画像内予測の予測誤差の絶対値
和として、参照画像のマクロブロックの信号Aijの総和
ΣAijの絶対値|ΣAij|と、マクロブロックの信号A
ijの絶対値|Aij|の総和Σ|Aij|の差を求める。ま
た、前方予測の予測誤差の絶対値和として、参照画像の
マクロブロックの信号Aijと、予測画像のマクロブロッ
クの信号Bijの差Aij−Bijの絶対値|Aij−Bij|の
総和Σ|Aij−Bij|を求める。また、後方予測と両方
向予測の予測誤差の絶対値和も、前方予測における場合
と同様に(その予測画像を前方予測における場合と異な
る予測画像に変更して)求める。
That is, as the sum of the absolute values of the prediction errors of the intra-picture prediction, the absolute value | ijAij | of the sum ijAij of the signal Aij of the macroblock of the reference picture and the signal A of the macroblock
The difference between the sum 絶 対 | Aij | of the absolute values | Aij | The sum of absolute values | Aij−Bij | of the difference Aij−Bij | between the signal Aij of the macroblock of the reference image and the signal Bij of the macroblock of the predicted image is used as the absolute value sum of the prediction error of the forward prediction. Bij |. In addition, the absolute value sum of the prediction error between the backward prediction and the bidirectional prediction is obtained in the same manner as in the forward prediction (by changing the predicted image to a different predicted image from that in the forward prediction).

【0061】これらの絶対値和は、予測判定回路54に
供給される。予測判定回路54は、前方予測、後方予測
および両方向予測の予測誤差の絶対値和のうちの最も小
さいものを、インタ予測の予測誤差の絶対値和として選
択する。さらに、このインタ予測の予測誤差の絶対値和
と、画像内予測の予測誤差の絶対値和とを比較し、その
小さい方を選択し、この選択した絶対値和に対応するモ
ードを予測モードとして選択する。すなわち、画像内予
測の予測誤差の絶対値和の方が小さければ、画像内予測
モードが設定される。インタ予測の予測誤差の絶対値和
の方が小さければ、前方予測、後方予測または両方向予
測モードのうちの対応する絶対値和が最も小さかったモ
ードが設定される。
The sum of these absolute values is supplied to the prediction judgment circuit 54. The prediction determination circuit 54 selects the smallest absolute value sum of the prediction errors of the forward prediction, the backward prediction, and the bidirectional prediction as the absolute value sum of the prediction errors of the inter prediction. Furthermore, the absolute value sum of the prediction error of the inter prediction and the absolute value sum of the prediction error of the intra prediction are compared, and the smaller one is selected, and the mode corresponding to the selected absolute value sum is set as the prediction mode. select. That is, if the sum of the absolute values of the prediction errors of the intra prediction is smaller, the intra prediction mode is set. If the sum of the absolute values of the prediction errors in the inter prediction is smaller, the mode in which the corresponding sum of the absolute values is the smallest among the forward prediction, backward prediction, and bidirectional prediction modes is set.

【0062】このように、動きベクトル検出回路50
は、参照画像のマクロブロックの信号を、フレームまた
はフィールド予測モードのうち、予測モード切り替え回
路52により選択されたモードに対応する構成で、予測
モード切り替え回路52を介して演算器53に供給する
とともに、4つの予測モードのうちの予測判定回路54
により選択された予測モードに対応する予測画像と参照
画像の間の動きベクトルを検出し、可変長符号化回路5
8と動き補償回路64に出力する。上述したように、こ
の動きベクトルとしては、対応する予測誤差の絶対値和
が最小となるものが選択される。
As described above, the motion vector detecting circuit 50
Supplies the macroblock signal of the reference image to the arithmetic unit 53 via the prediction mode switching circuit 52 in a configuration corresponding to the mode selected by the prediction mode switching circuit 52 among the frame or field prediction modes. Prediction prediction circuit 54 of the four prediction modes
, A motion vector between the predicted image corresponding to the prediction mode selected by the above and the reference image is detected, and the variable length coding circuit 5
8 and output to the motion compensation circuit 64. As described above, as the motion vector, the motion vector having the smallest absolute value sum of the corresponding prediction errors is selected.

【0063】予測判定回路54は、動きベクトル検出回
路50が前方原画像部51aよりIピクチャの画像デー
タを読み出しているとき、予測モードとして、フレーム
またはフィールド(画像)内予測モード(動き補償を行
わないモード)を設定し、演算器53のスイッチ53d
を接点a側に切り替える。これにより、Iピクチャの画
像データがDCTモード切り替え回路55に入力される。
When the motion vector detection circuit 50 reads out the I-picture image data from the front original image section 51a, the prediction determination circuit 54 sets the intra-frame or field (image) intra prediction mode (performs motion compensation) as the prediction mode. Mode) and switch 53d of arithmetic unit 53
To the contact a side. As a result, the image data of the I picture is input to the DCT mode switching circuit 55.

【0064】DCTモード切り替え回路55は、図10ま
たは図11に示すように、4個の輝度ブロックのデータ
を、奇数フィールドのラインと偶数フィールドのライン
が混在する状態(フレームDCTモード)、または、分離
された状態(フィールドDCTモード)、のいずれかの状
態にして、DCT回路56に出力する。
As shown in FIG. 10 or 11, the DCT mode switching circuit 55 converts the data of the four luminance blocks into a state where the lines of the odd field and the lines of the even field are mixed (frame DCT mode), or The state is set to one of the separated states (field DCT mode) and output to the DCT circuit 56.

【0065】すなわち、DCTモード切り替え回路55
は、奇数フィールドと偶数フィールドのデータを混在し
てDCT処理した場合における符号化効率と、分離した状
態においてDCT処理した場合の符号化効率とを比較し、
符号化効率の良好なモードを選択する。
That is, the DCT mode switching circuit 55
Compares the coding efficiency when DCT processing is performed by mixing data of odd fields and even fields, and the coding efficiency when DCT processing is performed in a separated state,
Select a mode with good coding efficiency.

【0066】例えば、入力された信号を、図10に示す
ように、奇数フィールドと偶数フィールドのラインが混
在する構成とし、上下に隣接する奇数フィールドのライ
ンの信号と偶数フィールドのラインの信号の差を演算
し、さらにその絶対値の和(または自乗和)を求める。
For example, as shown in FIG. 10, the input signal has a configuration in which the lines of the odd field and the even field are mixed, and the difference between the signal of the line of the odd field and the signal of the line of the even field adjacent vertically. Is calculated, and the sum (or sum of squares) of the absolute values is calculated.

【0067】また、入力された信号を、図11に示すよ
うに、奇数フィールドと偶数フィールドのラインが分離
した構成とし、上下に隣接する奇数フィールドのライン
同士の信号の差と、偶数フィールドのライン同士の信号
の差を演算し、それぞれの絶対値の和(または自乗和)
を求める。
As shown in FIG. 11, the input signal has a configuration in which the lines of the odd field and the even field are separated from each other. Calculates the difference between the signals of each other and sums (or sums of squares) the absolute values of each
Ask for.

【0068】さらに、両者(絶対値和)を比較し、小さ
い値に対応するDCTモードを設定する。すなわち、前者
の方が小さければ、フレームDCTモードを設定し、後者
の方が小さければ、フィールドDCTモードを設定する。
Further, the DCT mode corresponding to the smaller value is set by comparing the two (the sum of absolute values). That is, if the former is smaller, the frame DCT mode is set, and if the latter is smaller, the field DCT mode is set.

【0069】そして、選択したDCTモードに対応する構
成のデータをDCT回路56に出力するとともに、選択し
たDCTモードを示すDCTフラグを、可変長符号化回路5
8、および動き補償回路64に出力する。
Then, the data having the configuration corresponding to the selected DCT mode is output to the DCT circuit 56, and the DCT flag indicating the selected DCT mode is transmitted to the variable-length encoding circuit 5.
8 and the motion compensation circuit 64.

【0070】予測モード切り替え回路52における予測
モード(図8と図9)と、このDCTモード切り替え回路
55におけるDCTモード(図10と図11)を比較して
明らかなように、輝度ブロックに関しては、両者の各モ
ードにおけるデータ構造は実質的に同一である。
As is clear from the comparison between the prediction mode (FIGS. 8 and 9) in the prediction mode switching circuit 52 and the DCT mode (FIGS. 10 and 11) in the DCT mode switching circuit 55, the luminance block The data structure in each mode is substantially the same.

【0071】予測モード切り替え回路52において、フ
レーム予測モード(奇数ラインと偶数ラインが混在する
モード)が選択された場合、DCTモード切り替え回路5
5においても、フレームDCTモード(奇数ラインと偶数
ラインが混在するモード)が選択される可能性が高く、
また予測モード切り替え回路52において、フィールド
予測モード(奇数フィールドと偶数フィールドのデータ
が分離されたモード)が選択された場合、DCTモード切
り替え回路55において、フィールドDCTモード(奇数
フィールドと偶数フィールドのデータが分離されたモー
ド)が選択される可能性が高い。
When the prediction mode switching circuit 52 selects a frame prediction mode (a mode in which odd lines and even lines are mixed), the DCT mode switching circuit 5
5, it is highly possible that the frame DCT mode (a mode in which odd lines and even lines are mixed) is selected,
When the field prediction mode (mode in which the data of the odd field and the data of the even field are separated) is selected in the prediction mode switching circuit 52, the field DCT mode (the data of the odd field and the even field) is (Separated mode) is likely to be selected.

【0072】しかしながら、必ずしも常にこのようにモ
ードが選択されるわけではなく、予測モード切り替え回
路52においては、予測誤差の絶対値和が小さくなるよ
うにモードが決定され、DCTモード切り替え回路55に
おいては、符号化効率が良好となるようにモードが決定
される。
However, the mode is not always selected in this manner. In the prediction mode switching circuit 52, the mode is determined so that the absolute value sum of the prediction error becomes small, and in the DCT mode switching circuit 55, the mode is determined. , The mode is determined so that the coding efficiency is good.

【0073】DCTモード切り替え回路55より出力され
たIピクチャの画像データは、DCT回路56に入力され
てDCT処理され、DCT係数に変換される。このDCT係数
は、量子化回路57に入力され、送信バッファ59のデ
ータ蓄積量(バッファ蓄積量)に対応した量子化スケー
ルで量子化された後、可変長符号化回路58に入力され
る。
The image data of the I picture output from the DCT mode switching circuit 55 is input to the DCT circuit 56, subjected to DCT processing, and converted into DCT coefficients. The DCT coefficient is input to the quantization circuit 57, quantized by a quantization scale corresponding to the data storage amount (buffer storage amount) of the transmission buffer 59, and then input to the variable length coding circuit 58.

【0074】可変長符号化回路58は、量子化回路57
より供給される量子化スケール(スケール)に対応し
て、量子化回路57より供給される画像データ(いまの
場合、Iピクチャのデータ)を、例えばハフマン符号な
どの可変長符号に変換し、送信バッファ59に出力す
る。
The variable length coding circuit 58 includes a quantization circuit 57
The image data (in this case, I-picture data) supplied from the quantization circuit 57 is converted into a variable-length code such as a Huffman code in accordance with the supplied quantization scale (scale), and transmitted. Output to the buffer 59.

【0075】可変長符号化回路58にはまた、量子化回
路57より量子化スケール(スケール)、予測判定回路
54より予測モード(画像内予測、前方予測、後方予
測、または両方向予測のいずれが設定されたかを示すモ
ード)、動きベクトル検出回路50より動きベクトル、
予測モード切り替え回路52より予測フラグ(フレーム
予測モードまたはフィールド予測モードのいずれが設定
されたかを示すフラグ)、およびDCTモード切り替え回
路55が出力するDCTフラグ(フレームDCTモードまたは
フィールドDCTモードのいずれが設定されたかを示すフ
ラグ)が入力されており、これらも可変長符号化され
る。
The variable length coding circuit 58 also sets a quantization scale (scale) by the quantization circuit 57 and a prediction mode (intra-picture prediction, forward prediction, backward prediction, or bidirectional prediction) by the prediction determination circuit 54. Mode indicating whether the motion vector has been detected), a motion vector from the motion vector detection circuit 50,
A prediction flag (a flag indicating whether the frame prediction mode or the field prediction mode has been set) from the prediction mode switching circuit 52, and a DCT flag (either the frame DCT mode or the field DCT mode) output from the DCT mode switching circuit 55 Are input, and these are also variable-length coded.

【0076】送信バッファ59は、入力されたデータを
一時蓄積し、蓄積量に対応するデータを量子化回路57
に出力する。送信バッファ59は、そのデータ残量が許
容上限値まで増量すると、量子化制御信号によって量子
化回路57の量子化スケールを大きくすることにより、
量子化データのデータ量を低下させる。また、これとは
逆に、データ残量が許容下限値まで減少すると、送信バ
ッファ59は、量子化制御信号によって量子化回路57
の量子化スケールを小さくすることにより、量子化デー
タのデータ量を増大させる。このようにして、送信バッ
ファ59のオーバフローまたはアンダフローが防止され
る。
The transmission buffer 59 temporarily stores the input data and converts the data corresponding to the storage amount into a quantization circuit 57.
Output to When the remaining data amount increases to the allowable upper limit, the transmission buffer 59 increases the quantization scale of the quantization circuit 57 by the quantization control signal,
The data amount of the quantized data is reduced. Conversely, when the remaining data amount decreases to the permissible lower limit value, the transmission buffer 59 sends the quantization signal to the quantization circuit 57 by the quantization control signal.
By reducing the quantization scale of, the data amount of the quantized data is increased. In this way, overflow or underflow of the transmission buffer 59 is prevented.

【0077】そして、送信バッファ59に蓄積されたデ
ータは、所定のタイミングで読み出され、伝送路に出力
され、例えば記録回路19を介して記録媒体3に記録さ
れる。
The data stored in the transmission buffer 59 is read at a predetermined timing, output to a transmission path, and recorded on the recording medium 3 via the recording circuit 19, for example.

【0078】一方、量子化回路57より出力されたIピ
クチャのデータは、逆量子化回路60に入力され、量子
化回路57より供給される量子化スケールに対応して逆
量子化される。逆量子化回路60の出力は、IDCT(逆離
散コサイン変換)回路61に入力され、逆離散コサイン
変換処理された後、演算器62を介してフレームメモリ
63の前方予測画像部63a供給されて記憶される。
On the other hand, the I picture data output from the quantization circuit 57 is input to the inverse quantization circuit 60 and inversely quantized according to the quantization scale supplied from the quantization circuit 57. The output of the inverse quantization circuit 60 is input to an IDCT (Inverse Discrete Cosine Transform) circuit 61, subjected to an inverse discrete cosine transform process, supplied to a forward prediction image section 63a of a frame memory 63 via an arithmetic unit 62, and stored. Is done.

【0079】動きベクトル検出回路50は、シーケンシ
ャルに入力される各フレームの画像データを、たとえ
ば、I,B,P,B,P,B・・・のピクチャとしてそ
れぞれ処理する場合、最初に入力されたフレームの画像
データをIピクチャとして処理した後、次に入力された
フレームの画像をBピクチャとして処理する前に、さら
にその次に入力されたフレームの画像データをPピクチ
ャとして処理する。Bピクチャは、後方予測を伴うた
め、後方予測画像としてのPピクチャが先に用意されて
いないと、復号することができないからである。
The motion vector detection circuit 50 is the first input when processing the sequentially input image data of each frame as, for example, I, B, P, B, P, B... After the image data of the input frame is processed as an I picture, the image data of the next input frame is processed as a P picture before the image of the next input frame is processed as a B picture. This is because a B picture involves backward prediction and cannot be decoded unless a P picture as a backward predicted image is prepared first.

【0080】そこで動きベクトル検出回路50は、Iピ
クチャの処理の次に、後方原画像部51cに記憶されて
いるPピクチャの画像データの処理を開始する。そし
て、上述した場合と同様に、マクロブロック単位でのフ
レーム間差分(予測誤差)の絶対値和が、動きベクトル
検出回路50から予測モード切り替え回路52と予測判
定回路54に供給される。予測モード切り替え回路52
と予測判定回路54は、このPピクチャのマクロブロッ
クの予測誤差の絶対値和に対応して、フレーム/フィー
ルド予測モード、または画像内予測、前方予測、後方予
測、もしくは両方向予測の予測モードを設定する。
Then, after the processing of the I picture, the motion vector detecting circuit 50 starts the processing of the picture data of the P picture stored in the rear original picture section 51c. Then, as in the case described above, the sum of the absolute values of the inter-frame differences (prediction errors) in macroblock units is supplied from the motion vector detection circuit 50 to the prediction mode switching circuit 52 and the prediction determination circuit 54. Prediction mode switching circuit 52
And the prediction determination circuit 54 sets a frame / field prediction mode or a prediction mode of intra-picture prediction, forward prediction, backward prediction, or bidirectional prediction in accordance with the absolute value sum of the prediction errors of the macroblocks of the P picture. I do.

【0081】演算器53は、画像内予測モードが設定さ
れたとき、スイッチ53dを上述したように接点a側に
切り替える。したがって、このデータは、Iピクチャの
データと同様に、DCTモード切り替え回路55、DCT回路
56、量子化回路57、可変長符号化回路58、および
送信バッファ59を介して伝送路に伝送される。また、
このデータは、逆量子化回路60、IDCT回路61、およ
び演算器62を介してフレームメモリ63の後方予測画
像部63bに供給されて記憶される。
When the intra-picture prediction mode is set, the arithmetic unit 53 switches the switch 53d to the contact a as described above. Therefore, this data is transmitted to the transmission path via the DCT mode switching circuit 55, the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59, like the I picture data. Also,
This data is supplied to and stored in the backward prediction image section 63b of the frame memory 63 via the inverse quantization circuit 60, the IDCT circuit 61, and the calculator 62.

【0082】また、前方予測モードが設定された場合、
スイッチ53dが接点bに切り替えられるとともに、フ
レームメモリ63の前方予測画像部63aに記憶されて
いる画像(いまの場合、Iピクチャの画像)データが読
み出され、動き補償回路64により、動きベクトル検出
回路50が出力する動きベクトルに対応して動き補償さ
れる。すなわち、動き補償回路64は、予測判定回路5
4より前方予測モードの設定が指令されたとき、前方予
測画像部63aの読み出しアドレスを、動きベクトル検
出回路50が、現在、出力しているマクロブロックの位
置に対応する位置から動きベクトルに対応する分だけず
らしてデータを読み出し、予測画像データを生成する。
When the forward prediction mode is set,
The switch 53d is switched to the contact b, and the image (I-picture image in this case) data stored in the forward prediction image section 63a of the frame memory 63 is read out. Motion compensation is performed according to the motion vector output from the circuit 50. That is, the motion compensation circuit 64
4, when the setting of the forward prediction mode is instructed, the read address of the forward prediction image section 63a is set to correspond to the motion vector from the position corresponding to the position of the macroblock currently output by the motion vector detection circuit 50. The data is read out by shifting by an amount and predicted image data is generated.

【0083】動き補償回路64より出力された予測画像
データは、演算器53aに供給される。演算器53a
は、予測モード切り替え回路52より供給された参照画
像のマクロブロックのデータから、動き補償回路65よ
り供給された、このマクロブロックに対応する予測画像
データを減算し、その差分(予測誤差)を出力する。こ
の差分データは、DCTモード切り替え回路55、DCT回路
56、量子化回路57、可変長符号化回路58、および
送信バッファ59を介して伝送路に伝送される。また、
この差分データは、逆量子化回路60、およびIDCT回路
61により局所的に復号され、演算器62に入力され
る。
The predicted image data output from the motion compensation circuit 64 is supplied to a computing unit 53a. Arithmetic unit 53a
Subtracts the predicted image data corresponding to the macroblock supplied from the motion compensation circuit 65 from the macroblock data of the reference image supplied from the prediction mode switching circuit 52, and outputs the difference (prediction error). I do. The difference data is transmitted to the transmission path via the DCT mode switching circuit 55, the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59. Also,
The difference data is locally decoded by the inverse quantization circuit 60 and the IDCT circuit 61, and is input to the arithmetic unit 62.

【0084】この演算器62にはまた、演算器53aに
供給されている予測画像データと同一のデータが供給さ
れている。演算器62は、IDCT回路61が出力する差分
データに、動き補償回路64が出力する予測画像データ
を加算する。これにより、元の(復号した)Pピクチャ
の画像データが得られる。このPピクチャの画像データ
は、フレームメモリ63の後方予測画像部63bに供給
されて記憶される。
The arithmetic unit 62 is also supplied with the same data as the predicted image data supplied to the arithmetic unit 53a. The calculator 62 adds the prediction image data output from the motion compensation circuit 64 to the difference data output from the IDCT circuit 61. As a result, image data of the original (decoded) P picture is obtained. The P-picture image data is supplied to and stored in the backward prediction image section 63b of the frame memory 63.

【0085】動きベクトル検出回路50は、このよう
に、IピクチャとPピクチャのデータが前方予測画像部
63aと後方予測画像部63bにそれぞれ記憶された
後、次にBピクチャの処理を実行する。予測モード切り
替え回路52と予測判定回路54は、マクロブロック単
位でのフレーム間差分の絶対値和の大きさに対応して、
フレーム/フィールドモードを設定し、また、予測モー
ドを画像内予測モード、前方予測モード、後方予測モー
ド、または両方向予測モードのいずれかに設定する。
After the data of the I picture and the P picture are stored in the forward predicted image section 63a and the backward predicted image section 63b, respectively, the motion vector detection circuit 50 then executes the processing of the B picture. The prediction mode switching circuit 52 and the prediction determination circuit 54 correspond to the magnitude of the sum of absolute values of the differences between frames in macroblock units,
The frame / field mode is set, and the prediction mode is set to any of the intra prediction mode, the forward prediction mode, the backward prediction mode, and the bidirectional prediction mode.

【0086】上述したように、画像内予測モードまたは
前方予測モードの時、スイッチ53dは接点aまたはb
に切り替えられる。このとき、Pピクチャにおける場合
と同様の処理が行われ、データが伝送される。
As described above, in the intra prediction mode or the forward prediction mode, the switch 53d is set to the contact a or b.
Can be switched to At this time, the same processing as in the case of the P picture is performed, and the data is transmitted.

【0087】これに対して、後方予測モードまたは両方
向予測モードが設定された時、スイッチ53dは、接点
cまたはdにそれぞれ切り替えられる。
On the other hand, when the backward prediction mode or the bidirectional prediction mode is set, the switch 53d is switched to the contact point c or d.

【0088】スイッチ53dが接点cに切り替えられて
いる後方予測モードの時、後方予測画像部63bに記憶
されている画像(いまの場合、Pピクチャの画像)デー
タが読み出され、動き補償回路64により、動きベクト
ル検出回路50が出力する動きベクトルに対応して動き
補償される。すなわち、動き補償回路64は、予測判定
回路54より後方予測モードの設定が指令されたとき、
後方予測画像部63bの読み出しアドレスを、動きベク
トル検出回路50が、現在、出力しているマクロブロッ
クの位置に対応する位置から動きベクトルに対応する分
だけずらしてデータを読み出し、予測画像データを生成
する。
In the backward prediction mode in which the switch 53d is switched to the contact point c, the image (P-picture in this case) data stored in the backward prediction image section 63b is read out, and the motion compensation circuit 64 As a result, motion compensation is performed corresponding to the motion vector output from the motion vector detection circuit 50. That is, when the setting of the backward prediction mode is instructed by the prediction determination circuit 54,
The motion vector detection circuit 50 shifts the read address of the backward predicted image section 63b from the position corresponding to the position of the currently output macroblock by the amount corresponding to the motion vector, and reads the data to generate predicted image data. I do.

【0089】動き補償回路64より出力された予測画像
データは、演算器53bに供給される。演算器53b
は、予測モード切り替え回路52より供給された参照画
像のマクロブロックのデータから、動き補償回路64よ
り供給された予測画像データを減算し、その差分を出力
する。この差分データは、DCTモード切り替え回路5
5、DCT回路56、量子化回路57、可変長符号化回路
58、および送信バッファ59を介して伝送路に伝送さ
れる。
The predicted image data output from the motion compensation circuit 64 is supplied to a calculator 53b. Arithmetic unit 53b
Subtracts the predicted image data supplied from the motion compensation circuit 64 from the macroblock data of the reference image supplied from the prediction mode switching circuit 52, and outputs the difference. This difference data is supplied to the DCT mode switching circuit 5
5, transmitted to the transmission path via the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59.

【0090】スイッチ53dが接点dに切り替えられて
いる両方向予測モードの時、前方予測画像部63aに記
憶されている画像(いまの場合、Iピクチャの画像)デ
ータと、後方予測画像部63bに記憶されている画像
(いまの場合、Pピクチャの画像)データが読み出さ
れ、動き補償回路64により、動きベクトル検出回路5
0が出力する動きベクトルに対応して動き補償される。
In the bidirectional prediction mode in which the switch 53d is switched to the contact point d, the image data (in this case, the I-picture image) stored in the forward prediction image section 63a and the image data stored in the backward prediction image section 63b. Data (in this case, an image of a P picture) is read out, and the motion compensation circuit 64 outputs the motion vector detection circuit 5
Motion compensation is performed corresponding to the motion vector output by 0.

【0091】すなわち、動き補償回路64は、予測判定
回路54より両方向予測モードの設定が指令されたと
き、前方予測画像部63aと後方予測画像部63bの読
み出しアドレスを、動きベクトル検出回路50がいま出
力しているマクロブロックの位置に対応する位置から動
きベクトル(この場合の動きベクトルは、前方予測画像
用と後方予測画像用の2つとなる)に対応する分だけず
らしてデータを読み出し、予測画像データを生成する。
That is, when the setting of the bidirectional prediction mode is instructed by the prediction judgment circuit 54, the motion compensation circuit 64 stores the read addresses of the forward predicted image section 63a and the backward predicted image section 63b, and the motion vector detection circuit 50 The data is read out from the position corresponding to the position of the macroblock being output by shifting the data by an amount corresponding to the motion vector (in this case, two motion vectors for the forward predicted image and the backward predicted image). Generate data.

【0092】動き補償回路64より出力された予測画像
データは、演算器53cに供給される。演算器53c
は、動きベクトル検出回路50より供給された参照画像
のマクロブロックのデータから、動き補償回路64より
供給された予測画像データの平均値を減算し、その差分
を出力する。この差分データは、DCTモード切り替え回
路55、DCT回路56、量子化回路57、可変長符号化
回路58、および送信バッファ59を介して伝送路に伝
送される。
The predicted image data output from the motion compensation circuit 64 is supplied to a calculator 53c. Arithmetic unit 53c
Subtracts the average value of the predicted image data supplied from the motion compensation circuit 64 from the macroblock data of the reference image supplied from the motion vector detection circuit 50, and outputs the difference. The difference data is transmitted to the transmission path via the DCT mode switching circuit 55, the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59.

【0093】Bピクチャの画像は、他の画像の予測画像
とされることがないため、フレームメモリ63には記憶
されない。
The B picture is not stored in the frame memory 63 because it is not regarded as a predicted picture of another picture.

【0094】なお、フレームメモリ63において、前方
予測画像部63aと後方予測画像部63bは、必要に応
じてバンク切り替えが行われ、所定の参照画像に対し
て、一方または他方に記憶されているものを、前方予測
画像あるいは後方予測画像として切り替えて出力するこ
とができる。
In the frame memory 63, the forward prediction image section 63a and the backward prediction image section 63b are switched between banks as necessary, and are stored in one or the other for a predetermined reference image. Can be switched and output as a forward predicted image or a backward predicted image.

【0095】上述した説明においては、輝度ブロックを
中心として説明をしたが、色差ブロックについても同様
に、図8乃至図11に示すマクロブロックを単位として
処理されて伝送される。なお、色差ブロックを処理する
場合の動きベクトルは、対応する輝度ブロックの動きベ
クトルを垂直方向と水平方向に、それぞれ1/2にした
ものが用いられる。
In the above description, the luminance block has been mainly described, but the chrominance block is also processed and transmitted in units of the macroblocks shown in FIGS. As a motion vector for processing a chrominance block, a motion vector obtained by halving the motion vector of the corresponding luminance block in the vertical and horizontal directions is used.

【0096】図12は、図5のデコーダ31の構成を示
すブロック図である。伝送路(記録媒体3)を介して伝
送された符号化された画像データは、図示せぬ受信回路
で受信されたり、再生装置で再生され、受信バッファ8
1に一時記憶された後、復号回路90の可変長復号回路
82に供給される。可変長復号回路82は、受信バッフ
ァ81より供給されたデータを可変長復号し、動きベク
トル、予測モード、予測フラグ、およびDCTフラグを動
き補償回路87に出力し、量子化スケールを逆量子化回
路83に出力するとともに、復号された画像データを逆
量子化回路83に出力する。
FIG. 12 is a block diagram showing a configuration of the decoder 31 of FIG. The encoded image data transmitted via the transmission path (recording medium 3) is received by a receiving circuit (not shown) or reproduced by a reproducing device,
After being temporarily stored in the variable 1, it is supplied to the variable length decoding circuit 82 of the decoding circuit 90. The variable length decoding circuit 82 performs variable length decoding on the data supplied from the reception buffer 81, outputs a motion vector, a prediction mode, a prediction flag, and a DCT flag to the motion compensation circuit 87, and changes the quantization scale to an inverse quantization circuit. 83, and outputs the decoded image data to the inverse quantization circuit 83.

【0097】逆量子化回路83は、可変長復号回路82
より供給された画像データを、同じく可変長復号回路8
2より供給された量子化スケールに従って逆量子化し、
IDCT回路84に出力する。逆量子化回路83より出力さ
れたデータ(DCT係数)は、IDCT回路84により、逆離
散コサイン変換処理が施され、演算器85に供給され
る。
The inverse quantization circuit 83 includes a variable length decoding circuit 82
The image data supplied from the variable length decoding circuit 8
Inverse quantization according to the quantization scale supplied from 2,
Output to the IDCT circuit 84. The data (DCT coefficient) output from the inverse quantization circuit 83 is subjected to inverse discrete cosine transform processing by the IDCT circuit 84 and supplied to the arithmetic unit 85.

【0098】IDCT回路84より演算器85に供給された
画像データが、Iピクチャのデータである場合、そのデ
ータは演算器85より出力され、演算器85に後に入力
される画像データ(PまたはBピクチャのデータ)の予
測画像データ生成のために、フレームメモリ86の前方
予測画像部86aに供給されて記憶される。また、この
データは、フォーマット変換回路32(図5)に出力さ
れる。
When the image data supplied from the IDCT circuit 84 to the computing unit 85 is I-picture data, the data is output from the computing unit 85 and the image data (P or B) which is input to the computing unit 85 later. In order to generate predicted image data (picture data), the data is supplied to and stored in the forward predicted image section 86a of the frame memory 86. This data is output to the format conversion circuit 32 (FIG. 5).

【0099】IDCT回路84より供給された画像データ
が、その1フレーム前の画像データを予測画像データと
するPピクチャのデータであり、前方予測モードのデー
タである場合、フレームメモリ86の前方予測画像部8
6aに記憶されている、1フレーム前の画像データ(I
ピクチャのデータ)が読み出され、動き補償回路87で
可変長復号回路82より出力された動きベクトルに対応
する動き補償が施される。そして、演算器85におい
て、IDCT回路84より供給された画像データ(差分のデ
ータ)と加算され、出力される。この加算されたデー
タ、すなわち、復号されたPピクチャのデータは、演算
器85に後に入力される画像データ(Bピクチャまたは
Pピクチャのデータ)の予測画像データ生成のために、
フレームメモリ86の後方予測画像部86bに供給され
て記憶される。
When the image data supplied from the IDCT circuit 84 is P-picture data in which the image data one frame before that is the predicted image data and is data in the forward prediction mode, the forward predicted image in the frame memory 86 Part 8
6a, the image data (I
Picture data) is read out, and the motion compensation circuit 87 performs motion compensation corresponding to the motion vector output from the variable length decoding circuit 82. Then, the arithmetic unit 85 adds the image data (difference data) supplied from the IDCT circuit 84 and outputs the result. The added data, that is, the decoded P-picture data is used to generate predicted image data of image data (B-picture or P-picture data) to be input to the arithmetic unit 85 later.
It is supplied to and stored in the backward prediction image section 86b of the frame memory 86.

【0100】Pピクチャのデータであっても、画像内予
測モードのデータは、Iピクチャのデータと同様に、演
算器85において処理は行われず、そのまま後方予測画
像部86bに記憶される。
Even in the case of P-picture data, the data in the intra-prediction mode is not processed in the computing unit 85 as in the case of the I-picture data, and is stored in the backward prediction image section 86b as it is.

【0101】このPピクチャは、次のBピクチャの次に
表示されるべき画像であるため、この時点では、まだフ
ォーマット変換回路32へ出力されない(上述したよう
に、Bピクチャの後に入力されたPピクチャが、Bピク
チャより先に処理され、伝送されている)。
Since this P picture is an image to be displayed next to the next B picture, it is not yet output to the format conversion circuit 32 at this point (as described above, the P picture input after the B picture The picture is processed and transmitted before the B picture).

【0102】IDCT回路84より供給された画像データ
が、Bピクチャのデータである場合、可変長復号回路8
2より供給された予測モードに対応して、フレームメモ
リ86の前方予測画像部86aに記憶されているIピク
チャの画像データ(前方予測モードの場合)、後方予測
画像部86bに記憶されているPピクチャの画像データ
(後方予測モードの場合)、または、その両方の画像デ
ータ(両方向予測モードの場合)が読み出され、動き補
償回路87において、可変長復号回路82より出力され
た動きベクトルに対応する動き補償が施されて、予測画
像が生成される。但し、動き補償を必要としない場合
(画像内予測モードの場合)、予測画像は生成されな
い。
If the image data supplied from the IDCT circuit 84 is B picture data, the variable length decoding circuit 8
2, the picture data of the I picture stored in the forward predicted image section 86a of the frame memory 86 (in the case of the forward predicted mode) and the P stored in the backward predicted image section 86b. The picture data of the picture (in the case of the backward prediction mode) or both image data (in the case of the bidirectional prediction mode) are read out, and the motion compensation circuit 87 corresponds to the motion vector output from the variable length decoding circuit 82. Is performed, and a predicted image is generated. However, if motion compensation is not required (in the case of the intra-picture prediction mode), no predicted picture is generated.

【0103】このようにして、動き補償回路87で動き
補償が施されたデータは、演算器85において、IDCT回
路84の出力と加算される。この加算出力は、フォーマ
ット変換回路32に出力される。
The data subjected to the motion compensation by the motion compensation circuit 87 in this way is added to the output of the IDCT circuit 84 in the arithmetic unit 85. This addition output is output to the format conversion circuit 32.

【0104】ただし、この加算出力はBピクチャのデー
タであり、他の画像の予測画像生成のために利用される
ことがないため、フレームメモリ86には記憶されな
い。
However, the added output is data of a B picture and is not used for generating a predicted image of another image, and is not stored in the frame memory 86.

【0105】Bピクチャの画像が出力された後、後方予
測画像部86bに記憶されているPピクチャの画像デー
タが読み出され、動き補償回路87を介して演算器85
に供給される。但し、このとき、動き補償は行われな
い。
After the picture of the B picture is output, the picture data of the P picture stored in the backward prediction picture section 86b is read out, and the arithmetic unit 85 is output via the motion compensation circuit 87.
Supplied to However, at this time, no motion compensation is performed.

【0106】なお、このデコーダ31には、図5のエン
コーダ18における予測モード切り替え回路52とDCT
モード切り替え回路55に対応する回路が図示されてい
ないが、これらの回路に対応する処理、すなわち、奇数
フィールドと偶数フィールドのラインの信号が分離され
た構成を元の構成に必要に応じて戻す処理は、動き補償
回路87により実行される。
The decoder 31 includes a prediction mode switching circuit 52 in the encoder 18 shown in FIG.
Although circuits corresponding to the mode switching circuit 55 are not shown, processing corresponding to these circuits, that is, processing for returning the configuration in which the signals of the lines of the odd field and the even field are separated to the original configuration as necessary is performed. Is executed by the motion compensation circuit 87.

【0107】また、上述した説明においては、輝度信号
の処理について説明したが、色差信号の処理も同様に行
われる。ただし、この場合の動きベクトルは、輝度信号
用の動きベクトルを、垂直方向および水平方向に1/2
にしたものが用いられる。
In the above description, the processing of the luminance signal has been described, but the processing of the chrominance signal is similarly performed. However, the motion vector in this case is obtained by dividing the motion vector for the luminance signal by に in the vertical and horizontal directions.
Is used.

【0108】図13は、符号化された画像の品質を示し
ている。画像の品質(SNR:Signal toNoise Ratio)は、ピ
クチャタイプに対応して制御され、Iピクチャ、および
Pピクチャは高品質とされ、Bピクチャは、I,Pピク
チャに比べて劣る品質とされて伝送される。これは、人
間の視覚特性を利用した手法であり、全ての画像品質を
平均化するよりも、品質を振動させたほうが視覚上の画
質が良くなるためである。このピクチャタイプに対応し
た画質の制御は、図7の量子化回路57により実行され
る。
FIG. 13 shows the quality of an encoded image. The image quality (SNR: Signal to Noise Ratio) is controlled according to the picture type, the I and P pictures are of high quality, and the B picture is of poor quality compared to the I and P pictures. Is done. This is a method utilizing human visual characteristics, and the visual quality is better when the quality is vibrated than when all the image qualities are averaged. The control of the image quality corresponding to the picture type is executed by the quantization circuit 57 of FIG.

【0109】図14及び図15は、本発明を適用したト
ランスコーダ101の構成を示しており、図15は、図
14のさらに詳細な構成を示している。このトランスコ
ーダ101は、復号装置102に入力された符号化ビデ
オビットストリーム(encoded video bit stream)のGO
P構造及びビットレートを、オペレータの所望するGOP構
造及びビットレートに変換する。このトランスコーダ1
01の機能を説明するために、図15には図示されてい
ないが、このトランスコーダ101の前段に、このトラ
ンスコーダ101とほぼ同様の機能を有した3つのトラ
ンスコーダが接続されているものとする。つまり、ビッ
トストリームのGOP構造及びビットレートをさまざまに
変更するために、第1のトランスコーダ、第2のトラン
スコーダ、および第3のトランスコーダが順に直列に接
続され、その第3のトランスコーダの後ろに、この図1
5に示された第4のトランスコーダが接続されているも
のとする。
FIGS. 14 and 15 show a configuration of the transcoder 101 to which the present invention is applied, and FIG. 15 shows a more detailed configuration of FIG. The transcoder 101 performs the GO of the encoded video bit stream (encoded video bit stream) input to the decoding device 102.
The P structure and bit rate are converted into the GOP structure and bit rate desired by the operator. This transcoder 1
Although not shown in FIG. 15 for explaining the function of the transcoder 101, three transcoders having functions substantially similar to those of the transcoder 101 are connected in front of the transcoder 101. I do. That is, in order to variously change the GOP structure and bit rate of the bit stream, the first transcoder, the second transcoder, and the third transcoder are sequentially connected in series, and the third transcoder is connected to the first transcoder. Behind this figure 1
It is assumed that the fourth transcoder shown in FIG. 5 is connected.

【0110】本発明の以下の説明において、この第1の
トランスコーダにおいて行われた符号化処理を第1世代
の符号化処理と定義し、第1のトランスコーダの後ろに
接続された第2のトランスコーダにおいて行われた符号
化処理を第2世代の符号化処理と定義し、第2のトラン
スコーダの後ろに接続された第3のトランスコーダにお
いて行われた符号化処理を第3世代の符号化処理と定義
し、第3のトランスコーダの後ろに接続された第4のト
ランスコーダ(図15に示されたトランスコーダ10
1)において行われる符号化処理を第4世代の符号化処
理または現在の符号化処理と定義することにする。
In the following description of the present invention, the encoding process performed in the first transcoder is defined as a first generation encoding process, and the second transcoder connected after the first transcoder is defined. An encoding process performed in the transcoder is defined as a second generation encoding process, and an encoding process performed in a third transcoder connected after the second transcoder is defined as a third generation code. And a fourth transcoder connected after the third transcoder (transcoder 10 shown in FIG. 15).
The encoding process performed in 1) is defined as a fourth generation encoding process or a current encoding process.

【0111】また、第1世代の符号化処理において生成
された符号化パラメータを第1世代の符号化パラメータ
と呼び、第2世代の符号化処理において生成された符号
化パラメータを第2世代の符号化パラメータと呼び、第
3世代の符号化処理において生成された符号化パラメー
タを第3世代の符号化パラメータと呼び、第4世代の符
号化処理において生成された符号化パラメータを第4世
代の符号化パラメータまたは現在の符号化パラメータと
呼ぶことにする。
The encoding parameters generated in the first-generation encoding process are called first-generation encoding parameters, and the encoding parameters generated in the second-generation encoding process are referred to as second-generation encoding parameters. An encoding parameter generated in the third generation encoding process is referred to as a third generation encoding parameter, and an encoding parameter generated in the fourth generation encoding process is referred to as a fourth generation encoding parameter. Will be referred to as the encoding parameter or the current encoding parameter.

【0112】まず、この図15に示されたトランスコー
ダ101に供給される符号化ビデオストリームST(3r
d)について説明する。ST(3rd)は、このトランスコ
ーダ101の前段に設けられている第3のトランスコー
ダにおける第3世代の符号化処理において生成された第
3世代の符号化ストリームであることを表わしている。
この第3世代の符号化処理において生成された符号化ビ
デオストリームST(3rd)には、第3の符号化処理に
おいて生成された第3世代の符号化パラメータが、この
符号化符号化ビデオストリームST(3rd)のシーケン
ス層、GOP層、ピクチャ層、スライス層、及びマクロブ
ロック層に、sequence_header() 関数、sequence_exten
sion() 関数、group_of_pictures_header()関数、pictu
re_header()関数,picture_coding_extension()関数、p
icture_data()関数、slice() 関数、及びmacroblock()
関数として記述されている。このように第3の符号化処
理によって生成された第3の符号化ストリームに、第3
の符号化処理において使用した第3の符号化パラメータ
を記述することはMPEG2規格において定義されているこ
とであって、何ら新規性は無い。
First, the coded video stream ST (3r) supplied to the transcoder 101 shown in FIG.
Step d) will be described. ST (3rd) indicates that the stream is a third-generation encoded stream generated in the third-generation encoding process in the third transcoder provided in the preceding stage of the transcoder 101.
The encoded video stream ST (3rd) generated in the third-generation encoding process includes the third-generation encoding parameters generated in the third encoding process in the encoded encoded video stream ST (3rd). The sequence_header () function and sequence_exten are added to the (3rd) sequence layer, GOP layer, picture layer, slice layer, and macroblock layer.
sion () function, group_of_pictures_header () function, pictu
re_header () function, picture_coding_extension () function, p
icture_data () function, slice () function, and macroblock ()
Described as a function. The third encoded stream generated by the third encoding process as described above includes a third encoded stream.
The description of the third encoding parameter used in the encoding process of the above is defined in the MPEG2 standard, and has no novelty.

【0113】本発明のトランスコーダ101におけるユ
ニークな点は、この第3の符号化ストリームST(3r
d)中に、第3の符号化パラメータを記述するでけでな
く、第1世代及び第2世代の符号化処理において生成さ
れた第1世代及び第2世代の符号化パラメータも記述さ
れているという点である。
The unique point of the transcoder 101 of the present invention is that the third coded stream ST (3r
In d), not only the third encoding parameter is described, but also the first-generation and second-generation encoding parameters generated in the first-generation and second-generation encoding processes are described. That is the point.

【0114】具体的には、この第1世代及び第2世代の
符号化パラメータは、第3世代の符号化ビデオストリー
ムST(3rd)のピクチャ層のユーザデータエリアに、
ヒストリストリームhistory_stream()として記述されて
いる。本発明においては、第3世代の符号化ビデオスト
リームST(3rd)のピクチャ層のユーザデータエリア
に記述されているヒストリストリームを、「ヒストリ情
報」、または「履歴情報」と呼び、このヒストリストリ
ームとして記述されている符号化パラメータを「ヒスト
リパラメータ」、または「履歴パラメータ」と呼んでい
る。
Specifically, the first generation and second generation coding parameters are stored in the user data area of the picture layer of the third generation coded video stream ST (3rd).
This is described as a history stream history_stream (). In the present invention, the history stream described in the user data area of the picture layer of the third-generation encoded video stream ST (3rd) is referred to as “history information” or “history information”. The coding parameters described are called "history parameters" or "history parameters".

【0115】また別の呼び方として、第3世代の符号化
ストリームST(3rd)に記述されている第3世代の符
号化パラメータを「現在の符号化パラメータ」と呼んだ
場合には、第3世代の符号化処理からみて第1世代及び
第2世代の符号化処理は、過去に行なわれた符号化処理
であるので、第3世代の符号化ストリームST(3rd)
のピクチャ層のユーザデータエリアに記述されているヒ
ストリストリームとして記述されている符号化パラメー
タを「過去の符号化パラメータ」とも呼んでいる。
As another method, when the third-generation encoding parameter described in the third-generation encoded stream ST (3rd) is called “the current encoding parameter”, From the viewpoint of the generation encoding process, the first generation and second generation encoding processes are encoding processes performed in the past, and therefore, the third generation encoded stream ST (3rd)
The coding parameter described as the history stream described in the user data area of the picture layer is also referred to as “past coding parameter”.

【0116】このように、この第3の符号化ストリーム
ST(3rd)中に、第3の符号化パラメータを記述する
でけでなく、第1世代及び第2世代の符号化処理におい
て生成された第1世代及び第2世代の符号化パラメータ
を記述する理由は、トランスコーディング処理によって
符号化ストリームのGOP構造やビットレートの変更を繰
り返したとしても、画質劣化を防止することができるか
らである。
As described above, not only the third encoding parameter is described in the third encoded stream ST (3rd), but also generated in the first and second generation encoding processes. The reason why the first-generation and second-generation encoding parameters are described is that even if the GOP structure and the bit rate of the encoded stream are repeatedly changed by the transcoding process, it is possible to prevent image quality deterioration.

【0117】例えば、あるピクチャを第1世代の符号化
処理においてPピクチャとして符号化し、第1世代の符
号化ストリームのGOP構造を変更するために、第2世代
の符号化処理においてそのピクチャをBピクチャとして
符号化し、第2世代の符号化ストリームのGOP構造をさ
らに変更するために、第3世代の符号化処理において、
再度そのピクチャをPピクチャとして符号化することが
考えられる。MPEG規格に基づく符号化処理及び復号処理
は100%可逆の処理ではないので、符号化及び復号処
理を繰り返す毎に画質が劣化していくことは知られてい
る。
For example, in order to change a GOP structure of a first generation coded stream, a certain picture is coded as a P picture in a first generation coding process, and the picture is converted to a B picture in a second generation coding process. In order to further change the GOP structure of the encoded stream of the second generation, the encoding is performed as a picture.
It is conceivable that the picture is encoded as a P picture again. Since the encoding process and the decoding process based on the MPEG standard are not 100% reversible processes, it is known that the image quality is deteriorated every time the encoding process and the decoding process are repeated.

【0118】このような場合に、第3の世代の符号化処
理において、量子化スケール、動きベクトル、予測モー
ドなどの符号化パラメータをもう一度計算するのではな
くて、第1世代の符号化処理において生成された量子化
スケール、動きベクトル、予測モードなどの符号化パラ
メータを再利用する。第3世代の符号化処理によって新
しく生成された量子化スケール、動きベクトル、予測モ
ードなどの符号化パラメータよりも、第1世代の符号化
処理によって新しく生成された量子化スケール、動きベ
クトル、予測モードなどの符号化パラメータの方が、明
らかに精度が良いので、この第1世代のパラメータを再
利用することによって、符号化及び復号処理を繰り返し
たとしても画質劣化を少なくすることができる。
In such a case, in the third generation encoding process, instead of calculating the encoding parameters such as the quantization scale, the motion vector, and the prediction mode again, the first generation encoding process is performed. Reuse the generated coding parameters such as the generated quantization scale, motion vector, and prediction mode. Newly generated quantization scale, motion vector, prediction mode by the first generation encoding process, rather than encoding parameters such as quantization scale, motion vector, and prediction mode newly generated by the third generation encoding process. Since the encoding parameters such as are clearly higher in accuracy, by reusing the first generation parameters, even if the encoding and decoding processes are repeated, the image quality degradation can be reduced.

【0119】上述した本発明にかかる処理を説明するた
めに、図15に示された第4世代のトランスコーダ10
1の処理を例に挙げてより詳しく説明する。
In order to explain the processing according to the present invention, the fourth-generation transcoder 10 shown in FIG.
The process 1 will be described in more detail by way of example.

【0120】復号装置102は、第3世代の符号化ビッ
トストリームST(3rd)に含まれている符号化ビデオ
を第3世代の符号化パラメータを使用して復号し、復号
されたベースバンドのデジタルビデオデータを生成する
ための装置である。さらに、復号装置102は、第3世
代の符号化ビットストリームST(3rd)のピクチャ層
のユーザデータエリアにヒストリストリームとして記述
されている第1世代及び第2世代の符号化パラメータを
デコードするための装置でもある。
[0120] The decoding apparatus 102 decodes the encoded video included in the third-generation encoded bit stream ST (3rd) using the third-generation encoding parameters, and decodes the decoded baseband digital signal. This is a device for generating video data. Further, the decoding device 102 decodes the first-generation and second-generation encoding parameters described as a history stream in the user data area of the picture layer of the third-generation encoded bit stream ST (3rd). It is also a device.

【0121】具体的には、図16に示されているよう
に、復号装置102は、図5の復号装置2のデコーダ3
1(図12)と基本的に同様の構成とされ、供給された
ビットストリームをバッファリングするための受信バッ
ファ81、符号化ビットストリームを可変長復号するた
めの可変長復号回路112、可変長復号されたデータを
可変長復号回路112から供給された量子化スケールに
従って逆量子化する逆量子化回路83、逆量子化された
DCT係数を逆離散コサイン変換するIDCT回路84、及
び動き補償処理を行うための演算器85、フレームメモ
リ86及び動き補償回路87を備えている。
More specifically, as shown in FIG. 16, the decoding device 102 is the decoder 3 of the decoding device 2 shown in FIG.
1 (FIG. 12), a reception buffer 81 for buffering a supplied bit stream, a variable length decoding circuit 112 for variable length decoding of an encoded bit stream, and a variable length decoding. An inverse quantization circuit 83 that inversely quantizes the obtained data according to the quantization scale supplied from the variable length decoding circuit 112, an IDCT circuit 84 that performs an inverse discrete cosine transform of the inversely quantized DCT coefficient, and performs motion compensation processing. 85, a frame memory 86, and a motion compensation circuit 87.

【0122】可変長復号回路112は、第3世代の符号
化ビットストリームST(3rd)を復号処理するため
に、この第3世代の符号化ビットストリームST(3r
d)のピクチャ層、スライス層及びマクロブロック層に
記述されている第3世代の符号化パラメータを抽出す
る。たとえば、この可変長復号回路112において抽出
される第3世代の符号化パラメータは、ピクチャタイプ
を示すpicture_coding_type、量子化スケールステップ
サイズを示すquantiser_scale_code、予測モードを示す
macroblock_type、動きベクトルを示すmotion_vector、
Frame予測モードかField予測モードかを示すframe/fiel
d_motion_type、及びFrameDCTモードかField DCT
モードかを示すdct_type等である。この可変長復号回路
112において抽出されたquatntiser_scale_codeは、
逆量子化回路83に供給され、picture_coding_type、q
uatntiser_scale_code、macroblock_type、motion_vect
or、frame/field_motion_type、dct_type等のパラメー
タは、動き補償回路87に供給される。
The variable length decoding circuit 112 decodes the third generation coded bit stream ST (3rd) to decode the third generation coded bit stream ST (3rd).
d) Third-generation coding parameters described in the picture layer, slice layer, and macroblock layer are extracted. For example, the third-generation encoding parameters extracted by the variable-length decoding circuit 112 include picture_coding_type indicating a picture type, quantizer_scale_code indicating a quantization scale step size, and a prediction mode.
macroblock_type, motion_vector indicating motion vector,
Frame / fiel indicating Frame prediction mode or Field prediction mode
d_motion_type and Frame DCT mode or Field DCT
Dct_type indicating the mode. The quatntiser_scale_code extracted in the variable length decoding circuit 112 is
The picture_coding_type, q
uatntiser_scale_code, macroblock_type, motion_vect
Parameters such as or, frame / field_motion_type, and dct_type are supplied to the motion compensation circuit 87.

【0123】可変長復号回路112は、第3世代の符号
化ビットストリームST(3rd)を復号処理するために
必要なこれらの符号化パラメータだけではなく、後段の
第5世代のトランスコーダに第3世代のヒストリ情報と
して伝送されるべき符号化パラメータを、第3世代の符
号化ビットストリームST(3rd)のシーケンス層、GOP
層、ピクチャ層、スライス層、及びマクロブロック層か
ら抽出する。もちろん、第3世代の復号処理に使用され
たpicture_coding_type、quatntiser_scale_code、macr
oblock_type、motion_vector、frame/field_motion_typ
e、dct_type等の第3世代の符号化パラメータは、この
第3世代のヒストリ情報に含まれている。ヒストリ情報
としてどのような符号化パラメータを抽出するかについ
ては、伝送容量などに応じてオペレータやホストコンピ
ュータ側からあらかじめ設定されている。
The variable-length decoding circuit 112 outputs not only the encoding parameters necessary for decoding the encoded bit stream ST (3rd) of the third generation, but also the third-generation The coding parameters to be transmitted as the history information of the generation are stored in the sequence layer of the encoded bit stream ST (3rd) of the third generation, GOP
Extract from the layer, picture layer, slice layer, and macroblock layer. Of course, picture_coding_type, quatntiser_scale_code, and macr used in the third generation decoding process
oblock_type, motion_vector, frame / field_motion_typ
Third generation encoding parameters such as e and dct_type are included in the third generation history information. The type of encoding parameter to be extracted as the history information is preset by the operator or the host computer according to the transmission capacity or the like.

【0124】さらに、可変長復号回路112は、第3世
代の符号化ビットストリームST(3rd)のピクチャ層
のユーザデータエリアに記述されているユーザデータを
抽出し、そのユーザデータをヒストリデコーディング装
置104に供給する。
Further, the variable length decoding circuit 112 extracts the user data described in the user data area of the picture layer of the encoded bit stream ST (3rd) of the third generation, and extracts the user data from the history decoding device. 104.

【0125】このヒストリデコーディング装置104
は、第3世代の符号化ビットストリームST(3rd)の
ピクチャ層に記述されていたユーザデータから、ヒスト
リ情報として記述されている第1世代の符号化パラメー
タ及び第2世代の符号化パラメータ(直前の世代よりさ
らに前の世代の符号化パラメータ)を抽出するための回
路である。具体的には、ヒストリデコーディング装置1
04は、受け取ったユーザデータのシンタックスを解析
することによって、ユーザデータの中に記述されている
固有のHistory_Data_Idを検出し、これによって、conve
rted_history_stream()を抽出することができる。さら
に、ヒストリデコーディング装置104は、converted_
history_stream()中にある所定間隔に挿入されている1
ビットのマーカービット(marker_bit)を取りさること
によって、history_stream()を得、そして、そのhistor
y_stream()のシンタックスを解析することによって、hi
story_stream()中に記述されている第1世代及び第2世
代の符号化パラメータを得ることができる。このヒスト
リデコーディング装置104の詳しい動作については、
後述する。
The history decoding device 104
Are generated from the user data described in the picture layer of the third generation coded bit stream ST (3rd), using the first generation coding parameters and the second generation coding parameters This is a circuit for extracting the encoding parameters of the generations earlier than the generation (2). Specifically, the history decoding device 1
04 detects the unique History_Data_Id described in the user data by analyzing the syntax of the received user data.
rted_history_stream () can be extracted. Further, the history decoding apparatus 104 converts the converted_
1 inserted at a certain interval in history_stream ()
Get the history_stream () by removing the marker bit (marker_bit) of the bit and its history
By analyzing the syntax of y_stream (), hi
The first-generation and second-generation encoding parameters described in story_stream () can be obtained. For detailed operation of the history decoding device 104,
It will be described later.

【0126】ヒストリ情報多重化装置103は、第1世
代、第2世代及び第3世代の符号化パラメータを、第4
世代の符号化処理を行う符号化装置106に供給するた
めに、復号装置102においてデコードされたベースバ
ンドのビデオデータに、これらの第1世代、第2世代及
び第3世代の符号化パラメータを多重化するための回路
である。具体的には、ヒストリ情報多重化装置103
は、復号装置102の演算器85から出力されたベース
バンドのビデオデータ、復号装置102の可変長復号装
置112から出力された第3世代の符号化パラメータ、
並びに、ヒストリデコーディング装置104から出力さ
れた第1世代の符号化パラメータと第2世代の符号化パ
ラメータとを受け取り、このベースバンドのビデオデー
タに、これらの第1世代、第2世代及び第3世代の符号
化パラメータを多重化する。第1世代、第2世代及び第
3世代の符号化パラメータが多重化されたベースバンド
のビデオデータは、伝送ケーブルを介してヒストリ情報
分離装置105に供給される。
The history information multiplexing device 103 converts the first-generation, second-generation, and third-generation coding parameters into fourth-generation coding parameters.
These first-generation, second-generation, and third-generation encoding parameters are multiplexed on the baseband video data decoded by the decoding device 102 so as to be supplied to the encoding device 106 that performs the generation encoding process. It is a circuit for making the circuit. Specifically, the history information multiplexing device 103
Are the baseband video data output from the arithmetic unit 85 of the decoding device 102, the third-generation encoding parameters output from the variable-length decoding device 112 of the decoding device 102,
Also, the first-generation coding parameter and the second-generation coding parameter output from the history decoding device 104 are received, and the first-generation, second-generation and third-generation video data are added to the baseband video data. The generation coding parameters are multiplexed. The baseband video data in which the first generation, second generation, and third generation coding parameters are multiplexed is supplied to the history information separation device 105 via a transmission cable.

【0127】次に、これらの第1世代、第2世代及び第
3世代の符号化パラメータのベースバンドビデオデータ
への多重化の方法について、図17及び図18を参照し
て説明する。、図17は、MPEG規格において定義されて
いる、16ピクセル×16ピクセルからなる1つのマク
ロブロックを示している。この16ピクセル×16ピク
セルのマクロブロックは、輝度信号に関しては4つの8
ピクセル×8ピクセルからなるサブブロック(Y[0],
[1],[2]及びY[3])と、色差信号に関しては4つの8
ピクセル×8ピクセルからなるサブブロック(Cr
[0],r[1],b[0],及びCb[1])から構成されてい
る。
Next, a method of multiplexing the first generation, second generation, and third generation coding parameters into baseband video data will be described with reference to FIGS. FIG. 17 shows one macro block of 16 pixels × 16 pixels defined in the MPEG standard. The macroblock of 16 pixels × 16 pixels is composed of four 8
A sub-block consisting of pixels x 8 pixels (Y [0],
[1], [2] and Y [3]) and four 8
Sub-block consisting of pixels x 8 pixels (Cr
[0], r [1], b [0], and Cb [1]).

【0128】図18は、ビデオデータのあるフォーマッ
トを表している。このフォーマットは、ITU勧告-RDT6
01において定義されているフォーマットであって、放
送業界において使用されている所謂「D1フォーマッ
ト」をあらわしている。このD1フォーマットは、10
ビットのビデオデータを伝送するためのフォーマットと
して規格化されたので、ビデオデータの1ピクセルを1
0ビットで表現できるようになっている。
FIG. 18 shows a format of video data. This format conforms to ITU Recommendation-RDT6
01, which is the so-called “D1 format” used in the broadcasting industry. This D1 format is 10
Since one bit of video data is standardized as a format for transmitting video data of one bit, one pixel of video data is
It can be represented by 0 bits.

【0129】MPEG規格によってデコードされたベースバ
ンドのビデオデータは8ビットであるので、本発明のト
ランスコーダにおいては、図18に示したように、D1
フォーマットの10ビットのうち上位8ビット(D9乃
至D2)を使用して、MPEG規格にもとづいてデコードさ
れたベースバンドのビデオデータを伝送するようにして
いる。このように、復号された8ビットのビデオデータ
をD1フォーマットに書き込むと、下位2ビット(D1
とD0)は、空きビット(unallocated bits)となる。
本発明のトランスコーダではこの空きエリア(unalloca
ted area)を利用して、ヒストリ情報を伝送するように
している。
Since the baseband video data decoded according to the MPEG standard is 8 bits, the transcoder according to the present invention employs D1 as shown in FIG.
The upper 8 bits (D9 to D2) of the 10 bits of the format are used to transmit baseband video data decoded based on the MPEG standard. Thus, when the decoded 8-bit video data is written in the D1 format, the lower 2 bits (D1
And D0) are unallocated bits.
In the transcoder of the present invention, this empty area (unalloca
ted area) to transmit history information.

【0130】この図18に記載されたデータブロック
は、各サブブロック(Y[0],Y[1],Y[2],Y[3],C
r[0],Cr[1],Cb[0],Cb[1])における1ピクセ
ルを伝送するためのデータブロックであるので、1マク
ロブロックのデータを伝送するためには、この図18に
示されているデータブロックが64個伝送される。下位
2ビット(D1とD0)を使用すれば、1マクロブロッ
クのビデオデータに対して、合計で1024(=16×
64)ビットのヒストリ情報を伝送できる。従って、1
世代分のヒストリ情報は、256ビットとなるように生
成されているので、過去の4(=1024/256)世
代分のヒストリ情報を1マクロブロックのビデオデータ
に対して重畳することができる。図18に示した例で
は、第1世代のヒストリ情報、第2世代のヒストリ情
報、並びに、第3世代のヒストリ情報が重畳されてい
る。
The data blocks shown in FIG. 18 are composed of sub blocks (Y [0], Y [1], Y [2], Y [3], C
r [0], Cr [1], Cb [0], and Cb [1]) are data blocks for transmitting one pixel. Therefore, in order to transmit data of one macroblock, FIG. The 64 data blocks shown are transmitted. If the lower two bits (D1 and D0) are used, a total of 1024 (= 16 ×
64) bit of history information can be transmitted. Therefore, 1
Since the history information for the generation is generated to have 256 bits, the history information for the past 4 (= 1024/256) generations can be superimposed on the video data of one macroblock. In the example shown in FIG. 18, the first generation history information, the second generation history information, and the third generation history information are superimposed.

【0131】ヒストリ情報分離装置105は、D1フォ
ーマットとして伝送されたデータの上位8ビットから、
ベースバンドビデオデータを抽出し、下位2ビットから
ヒストリ情報を抽出するための回路である。図15に示
した例では、ヒストリ情報分離装置105は、伝送デー
タからベースバンドのビデオデータを抽出して、そのビ
デオデータを符号化装置106に供給するとともに、伝
送データから第1世代、第2世代及び第3世代のヒスト
リ情報を抽出して、符号化装置106とヒストリエンコ
ーディング装置107にそれぞれ供給する。
[0131] The history information separating apparatus 105 calculates the upper 8 bits of the data transmitted as the D1 format.
This is a circuit for extracting baseband video data and extracting history information from lower two bits. In the example shown in FIG. 15, the history information separating device 105 extracts baseband video data from the transmission data, supplies the video data to the encoding device 106, and outputs the first generation and second generation data from the transmission data. Generation and third generation history information is extracted and supplied to the encoding device 106 and the history encoding device 107, respectively.

【0132】符号化装置106は、ヒストリ情報分離装
置105から供給されたベースバンドのビデオデータ
を、オペレータまたはホストコンピュータから指定され
たGOP構造及びビットレートを有するビットストリーム
になるように符号化するための装置である。なお、GOP
構造を変更するとは、たとえば、GOPに含まれるピクチ
ャの数、IピクチャとIピクチャの間に存在するPピク
チャの数、及びIピクチャとPピクチャ(またはIピク
チャ)の間に存在するBピクチャの数を変更することを
意味する。
The encoding device 106 encodes the baseband video data supplied from the history information separating device 105 into a bit stream having a GOP structure and a bit rate specified by an operator or a host computer. Device. GOP
Changing the structure includes, for example, the number of pictures included in a GOP, the number of P pictures existing between I pictures and I pictures, and the number of B pictures existing between I pictures and P pictures (or I pictures). It means changing the number.

【0133】図15に示された例では、供給されたベー
スバンドのビデオデータには、第1世代、第2世代及び
第3世代のヒストリ情報が重畳されているので、この符
号化装置106は、再符号化処理による画質劣化が少な
くなるように、これらのヒストリ情報を選択的に再利用
して第4世代の符号化処理を行う。
In the example shown in FIG. 15, first-, second-, and third-generation history information is superimposed on the supplied baseband video data. The fourth generation encoding process is performed by selectively reusing these pieces of history information so that image quality deterioration due to the re-encoding process is reduced.

【0134】図19は、この符号化装置106に設けら
れているエンコーダ121の具体的な構成を示している
図である。このエンコーダ121は、基本的には、図7
に示したエンコーダ18と同様に構成され、動きベクト
ル検出回路50、フレーム/フィールド予測モード切り
替え回路52、演算器53、DCTモード切り替え回路
55、DCT回路56、量子化回路57、可変長符号化
回路58、伝送バッファ59、逆量子化回路60、逆D
CT回路61、演算器62、フレームメモリ63、並び
に動き補償回路64を備えている。これらの、各回路の
機能は、図7において説明したエンコーダ18における
場合の機能とほぼ同じであるので、その説明は省略す
る。以下に、このエンコーダ121と、図7において説
明したエンコーダ18との異なる点を中心に説明する。
FIG. 19 is a diagram showing a specific configuration of the encoder 121 provided in the encoding device 106. This encoder 121 basically has the configuration shown in FIG.
, A motion vector detecting circuit 50, a frame / field prediction mode switching circuit 52, a computing unit 53, a DCT mode switching circuit 55, a DCT circuit 56, a quantization circuit 57, a variable length encoding circuit 58, transmission buffer 59, inverse quantization circuit 60, inverse D
It includes a CT circuit 61, a computing unit 62, a frame memory 63, and a motion compensation circuit 64. The functions of these circuits are almost the same as the functions of the encoder 18 described with reference to FIG. 7, and thus description thereof is omitted. The following mainly describes differences between the encoder 121 and the encoder 18 described with reference to FIG.

【0135】このエンコーダ121は、上述した各回路
の動作及び機能を制御するためのコントローラ70を有
している。このコントローラ70は、オペレータまたは
ホストコンピュータからGOP構造に関するインストラク
ションを受け取って、そのGOP構造に対応するように各
ピクチャのピクチャタイプを決定する。また、このコン
トローラ70は、オペレータまたはホストコンピュータ
からタ−ゲットビットレートの情報を受け取り、このエ
ンコーダ121から出力されるビットレートがこの指定
されたターゲットビットレートになるように、量子化回
路57を制御する。
The encoder 121 has a controller 70 for controlling the operation and function of each circuit described above. The controller 70 receives an instruction regarding the GOP structure from the operator or the host computer, and determines a picture type of each picture so as to correspond to the GOP structure. The controller 70 receives information on the target bit rate from the operator or the host computer, and controls the quantization circuit 57 so that the bit rate output from the encoder 121 becomes the specified target bit rate. I do.

【0136】さらに、このコントローラ70は、ヒスト
リ情報分離装置105から出力された複数世代のヒスト
リ情報を受け取り、これらのヒストリ情報を再利用して
参照ピクチャの符号化処理を行う。以下に詳しく説明す
る。
Further, the controller 70 receives history information of a plurality of generations output from the history information separating device 105, and performs a reference picture encoding process by reusing the history information. This will be described in detail below.

【0137】まず、このコントローラ70は、オペレー
タによって指定されたGOP構造から決定された参照ピク
チャのピクチャタイプと、ヒストリ情報に含まれるピク
チャタイプが一致するか否かを判断する。つまり、指定
されたピクチャタイプと同じピクチャタイプでこの参照
ピクチャが過去において符号化されたことがあるか否か
を判断する。
First, the controller 70 determines whether or not the picture type of the reference picture determined from the GOP structure specified by the operator matches the picture type included in the history information. That is, it is determined whether or not this reference picture has been encoded in the past with the same picture type as the designated picture type.

【0138】図15に示された例をあげてよりわかりや
すく説明するのであれば、このコントローラ70は、第
4世代の符号化処理としてこの参照ピクチャにアサイン
されたピクチャタイプが、第1世代の符号化処理おける
この参照ピクチャのピクチャタイプ、第2世代の符号化
処理おけるこの参照ピクチャのピクチャタイプ、または
第3世代の符号化処理おけるこの参照ピクチャのピクチ
ャタイプのいずれかと一致するか否かを判断する。
To explain this more clearly with reference to the example shown in FIG. 15, the controller 70 determines that the picture type assigned to this reference picture as the fourth generation encoding process is the first generation Whether the picture type of the reference picture in the encoding process, the picture type of the reference picture in the second generation encoding process, or the picture type of the reference picture in the third generation encoding process is matched. to decide.

【0139】もし、第4世代の符号化処理としてこの参
照ピクチャに指定されたピクチャタイプが、過去の符号
化処理におけるどのピクチャタイプとも一致しないので
あれは、このコントローラ70は、「通常符号化処理」
を行う。つまり、この場合には、第1世代、第2世代ま
たは第3世代のどの世代の符号化処理においても、第4
世代の符号化処理としてアサインされたピクチャタイプ
で、この参照ピクチャが符号化処理されたことがないと
いうことになる。一方、もし、第4世代の符号化処理と
してこの参照ピクチャに指定されたピクチャタイプが、
過去の符号化処理におけるいずれかのピクチャタイプと
一致するのであれば、このコントローラ70は、「パラ
メータ再利用符号化処理」を行う。つまり、この場合に
は、第1世代、第2世代または第3世代のいずれかの世
代の符号化処理において、第4世代の符号化処理として
アサインされたピクチャタイプで、この参照ピクチャが
符号化処理されたことがあるということになる。
If the picture type designated as the reference picture as the fourth-generation encoding process does not match any of the picture types in the past encoding process, the controller 70 executes the “normal encoding process”. "
I do. That is, in this case, in any of the first generation, second generation, and third generation encoding processes, the fourth generation
This means that the reference picture has not been subjected to the encoding process with the picture type assigned as the encoding process of the generation. On the other hand, if the picture type specified as the fourth-generation encoding process for this reference picture is
If the picture type matches one of the picture types in the past encoding processing, the controller 70 performs the “parameter reuse encoding processing”. That is, in this case, in the encoding processing of any of the first generation, the second generation, and the third generation, the reference picture is encoded using the picture type assigned as the fourth generation encoding processing. It has been processed.

【0140】まず、最初にコントローラ70の通常符号
化処理について説明する。
First, the normal encoding process of the controller 70 will be described.

【0141】動きベクトル検出回路50は、フレーム予
測モードまたはフィールド予測モードのどちらが選択さ
れるべきかを判断するために、フレーム予測モードにお
ける予測誤差とフィールド予測モードおける予測誤差を
それぞれ検出し、その予測誤差の値をコントローラ70
に供給する。コントローラ70は、それらの予測誤差の
値を比較し、その予測誤差の値が小さい方の予測モード
を選択する。予測モード切り替え回路52は、コントロ
ーラ70によって選択された予測モードに対応するよう
に信号処理を行い、それを演算器53に供給する。
The motion vector detection circuit 50 detects a prediction error in the frame prediction mode and a prediction error in the field prediction mode to determine whether the frame prediction mode or the field prediction mode is to be selected. Error value of controller 70
To supply. The controller 70 compares the values of the prediction errors and selects the prediction mode with the smaller value of the prediction error. The prediction mode switching circuit 52 performs signal processing so as to correspond to the prediction mode selected by the controller 70, and supplies it to the arithmetic unit 53.

【0142】具体的には、予測モード切り替え回路52
は、フレーム予測モードが選択された場合には、図8を
参照して説明したように、輝度信号に関しては、入力さ
れた状態のまま演算器53に出力するように信号処理を
行い、色差信号に関しては、奇数フィールドラインと偶
数フィールドラインとが混在するように信号処理する。
一方、フィールド予測モードが選択された場合には、図
9を参照して説明したように、輝度信号に関しては、輝
度ブロックY[1]とY[2]を奇数フィールドラインで構成
し、輝度ブロックY[3]とY[4]を偶数フィールドライン
で構成するように信号処理し、色差信号に関しては、上
4ラインを奇数フィールドラインで構成し、下4ライン
を偶数フィールドラインで構成するように信号処理す
る。
More specifically, the prediction mode switching circuit 52
When the frame prediction mode is selected, as described with reference to FIG. 8, the luminance signal is subjected to signal processing so as to be output to the computing unit 53 as it is input, and the chrominance signal With regard to, the signal processing is performed so that the odd field lines and the even field lines are mixed.
On the other hand, when the field prediction mode is selected, as described with reference to FIG. 9, for the luminance signal, the luminance blocks Y [1] and Y [2] are configured by odd field lines, and Signal processing is performed so that Y [3] and Y [4] are composed of even-numbered field lines. Regarding the color difference signal, the upper four lines are composed of odd-numbered field lines, and the lower four lines are composed of even-numbered field lines. Perform signal processing.

【0143】さらに、動きベクトル検出回路50は、画
像内予測モード、前方予測モード、後方予測モード、ま
たは両方向予測モードのうちのいずれの予測モードを選
択するかを決定するために、各予測モードにおける予測
誤差を生成し、各予測モードにおける予測誤差をコント
ローラ70にそれぞれ供給する。コントローラ70は、
前方予測、後方予測および両方向予測の予測誤差のうち
の最も小さいものを、インタ予測の予測誤差として選択
する。さらに、このインタ予測の予測誤差と、画像内予
測の予測誤差とを比較し、その小さい方を選択し、この
選択した予測誤差に対応するモードを予測モードとして
選択する。すなわち、画像内予測の予測誤差の方が小さ
ければ、画像内予測モードが設定される。インタ予測の
予測誤差の方が小さければ、前方予測、後方予測または
両方向予測モードのうちの対応する予測誤差が最も小さ
かったモードが設定される。コントローラ70は、選択
した予測モードに対応するように、演算器53及び動き
補償回路64を制御する。
Further, the motion vector detecting circuit 50 determines whether to select any of the intra prediction mode, the forward prediction mode, the backward prediction mode, and the bidirectional prediction mode in each prediction mode. A prediction error is generated, and the prediction error in each prediction mode is supplied to the controller 70. The controller 70
The smallest one of the prediction errors of the forward prediction, the backward prediction, and the bidirectional prediction is selected as the prediction error of the inter prediction. Further, the prediction error of the inter prediction is compared with the prediction error of the intra prediction, and the smaller one is selected, and the mode corresponding to the selected prediction error is selected as the prediction mode. That is, if the prediction error of the intra prediction is smaller, the intra prediction mode is set. If the prediction error of the inter prediction is smaller, the mode with the smallest corresponding prediction error among the forward prediction, backward prediction, and bidirectional prediction modes is set. The controller 70 controls the arithmetic unit 53 and the motion compensation circuit 64 so as to correspond to the selected prediction mode.

【0144】DCTモード切り替え回路55は、フレー
ムDCTモードまたはフィールドDCTモードのいずれかを選
択するために、4個の輝度ブロックのデータを、奇数フ
ィールドラインと偶数フィールドラインが混在するよう
な信号形態(フレームDCTモード)に変換するととも
に、奇数フィールドラインと偶数フィールドラインが分
離された信号形態(フィールドDCTモード)に変換し
て、それぞれの信号をDCT回路56に供給する。DC
T回路56は、奇数フィールドと偶数フィールドを混在
してDCT処理した場合における符号化効率と、奇数フィ
ールドと偶数フィールドを分離した状態においてDCT処
理した場合の符号化効率を計算し、その結果をコントロ
ーラ70に供給する。コントローラ70は、DCT回路
56から供給されたそれぞれの符号化効率を比較し、符
号化効率の良い方のDCTモードを選択し、その選択し
たDCTモードとなるようにDCTモード切り替え回路
55を制御する。
The DCT mode switching circuit 55 converts the data of the four luminance blocks into a signal form in which an odd field line and an even field line are mixed in order to select either the frame DCT mode or the field DCT mode. In addition to the conversion into the frame DCT mode, the signal is converted into a signal form in which the odd field lines and the even field lines are separated (field DCT mode), and the respective signals are supplied to the DCT circuit 56. DC
The T circuit 56 calculates the coding efficiency when the odd field and the even field are mixed and performs the DCT processing, and calculates the coding efficiency when the odd field and the even field are separated and performs the DCT processing. 70. The controller 70 compares the respective coding efficiencies supplied from the DCT circuit 56, selects the DCT mode with the higher coding efficiency, and controls the DCT mode switching circuit 55 to be the selected DCT mode. .

【0145】コントローラ70は、オペレータまたはホ
ストコンピュータから供給された目標ビットレートを示
すターゲットビットレートと、送信バッファ59にバッ
ファリングされているビット量を示す信号、つまり、バ
ッファ残量を示す信号を受け取り、このターゲットビッ
トレートとバッファ残量に基づいて、量子化回路57の
量子化ステップサイズをコントロールするためのfeedba
ck_q_scale_code を生成する。このfeedback_q_scale_c
odeは、この送信バッファ59がオーバーフローまたは
アンダーフローしないように、この送信バッファ59の
バッファ残量に応じて生成される制御信号であって、ま
た、送信バッファ59から出力されるビットストリーム
のビットレートが、ターゲットビットレートになるよう
に制御する信号でもある。
The controller 70 receives the target bit rate indicating the target bit rate supplied from the operator or the host computer, and a signal indicating the amount of bits buffered in the transmission buffer 59, that is, a signal indicating the remaining buffer amount. , A feed buffer for controlling the quantization step size of the quantization circuit 57 based on the target bit rate and the remaining buffer capacity.
Generate ck_q_scale_code. This feedback_q_scale_c
ode is a control signal generated according to the remaining buffer capacity of the transmission buffer 59 so that the transmission buffer 59 does not overflow or underflow, and the bit rate of the bit stream output from the transmission buffer 59 Is a signal for controlling the target bit rate.

【0146】具体的には、例えば、送信バッファ59に
バッファリングされているビット量が少なくなってしま
った場合には、次に符号化するピクチャの発生ビット量
が増えるように、量子化ステップサイズを小さくし、一
方、送信バッファ59にバッファリングされているビッ
ト量が多くなってしまった場合には、次に符号化するピ
クチャの発生ビット量が少なくなるように、量子化ステ
ップサイズを大きくする。なお、feedback_q_scale_cod
eと量子化ステップサイズは比例し、feedback_q_scale_
codeを大きくすると、量子化ステップサイズは大きくな
り、feedback_q_scale_codeを小さくすると、量子化ス
テップサイズは小さくなる。
More specifically, for example, when the amount of bits buffered in the transmission buffer 59 is reduced, the quantization step size is set so that the amount of generated bits of the next picture to be encoded increases. If the amount of bits buffered in the transmission buffer 59 increases, the quantization step size is increased so that the number of bits generated in the next picture to be encoded decreases. . Feedback_q_scale_cod
e and the quantization step size are proportional, and feedback_q_scale_
The larger the code, the larger the quantization step size, and the smaller the feedback_q_scale_code, the smaller the quantization step size.

【0147】次に、このトランスコーダ101の特徴の
1つでもある、パラメータ再利用符号化処理について説
明する。この処理をより分かりやすく説明するために、
参照ピクチャは、第1世代の符号化処理においてPピク
チャとして符号化され、第2世代の符号化処理において
Iピクチャとして符号化処理され、第3世代の符号化処
理においてBピクチャとして符号化されていたものと
し、今回の第4世代の符号化処理において、この参照ピ
クチャをPピクチャとして符号化しなければいけないも
のとする。
Next, the parameter reuse encoding process, which is one of the features of the transcoder 101, will be described. To better explain this process,
The reference picture is coded as a P picture in the first generation coding process, is coded as an I picture in the second generation coding process, and is coded as a B picture in the third generation coding process. It is assumed that this reference picture must be coded as a P picture in the current fourth generation coding process.

【0148】この場合には、第4世代のピクチャタイプ
としてアサインされたピクチャタイプと同じピクチャタ
イプ(Iピクチャ)で、この参照ピクチャは第1世代の
符号化処理において符号化されているので、コントロー
ラ70は、供給されたビデオデータから符号化パラメー
タを新しく作成するのではなく、第1世代の符号化パラ
メータを使用して符号化処理を行う。この第4の符号化
処理において再利用する符号化パラメータは、代表的な
パラメータとしては、量子化スケールステップサイズを
示すquantiser_scale_code、予測方向モードを示すmacr
oblock_type、動きベクトルを示すmotion_vector、Fram
e予測モードかField予測モードかを示すframe/field_mo
tion_type、及びFrameDCTモードかField DCTモー
ドかを示すdct_type等である。
In this case, since the reference picture has the same picture type (I picture) as the picture type assigned as the fourth generation picture type and has been encoded in the first generation encoding process, the controller 70 performs an encoding process using the first-generation encoding parameters, instead of newly creating encoding parameters from the supplied video data. The encoding parameters to be reused in the fourth encoding process include, as representative parameters, quantizer_scale_code indicating a quantization scale step size and macr indicating a prediction direction mode.
oblock_type, motion_vector indicating motion vector, Fram
frame / field_mo indicating e prediction mode or Field prediction mode
and a dct_type indicating whether the DCT mode is the Frame DCT mode or the Field DCT mode.

【0149】コントローラ70は、ヒストリ情報として
伝送されたすべての符号化パラメータを再利用するわけ
ではなく、再利用した方が望ましいと想定される上述し
たような符号化パラメータについては再利用し、再利用
しない方が望ましいと考えられる符号化パラメータにつ
いては、新しく生成する。
The controller 70 does not reuse all the coding parameters transmitted as history information, but reuses the above-mentioned coding parameters for which it is assumed that it is desirable to reuse them. Encoding parameters that are considered to be desirably not used are newly generated.

【0150】次に、この符号化パラメータ再利用符号化
処理について、上述した通常符号化処理と異なる点を中
心に説明する。
Next, the encoding parameter reuse encoding process will be described focusing on the differences from the above-described normal encoding process.

【0151】動きベクトル検出回路50は、上述した通
常符号化処理においては、参照ピクチャの動きベクトル
の検出を行ったが、このパラメータ再利用符号化処理に
おいては、動きベクトルmotion_vectorの検出処理は行
わずに、第1世代のヒストリ情報として供給された動き
ベクトルmotion_vectorを再利用する。その理由につい
て説明する。
The motion vector detection circuit 50 detects the motion vector of the reference picture in the above-described normal encoding process, but does not perform the motion vector motion_vector detection process in the parameter reuse encoding process. Then, the motion vector motion_vector supplied as the first generation history information is reused. The reason will be described.

【0152】第3世代の符号化ストリームを復号したベ
ースバンドのビデオデータは、少なくとも3回の復号及
び符号化処理が行われているので、オリジナルビデオデ
ータに比べると、明らかに画質が劣化している。画質が
劣化しているビデオデータから動きベクトルを検出した
としても、正確な動きベクトルは検出できない。つま
り、第4世代の符号化処理において検出された動きベク
トルよりも、第1世代のヒストリ情報として供給されて
いる動きベクトルの方が、明らかに、精度の高い動きベ
クトルである。つまり、第1世代の符号化パラメータと
して伝送された動きベクトルを再利用することによっ
て、第4世代の符号化処理を行ったとしても画質が劣化
しない。コントローラ70は、この第1世代のヒストリ
情報として供給された動きベクトルmotion_vectorを、
第4世代の符号化処理において符号化されるこの参照ピ
クチャの動きベクトル情報として、動き補償回路64及
び可変長符号化回路58に供給する。
Since the baseband video data obtained by decoding the third generation coded stream has been decoded and coded at least three times, the image quality is clearly degraded as compared with the original video data. I have. Even if a motion vector is detected from video data having deteriorated image quality, an accurate motion vector cannot be detected. That is, the motion vector supplied as the first generation history information is clearly a higher-precision motion vector than the motion vector detected in the fourth generation encoding process. That is, by reusing the motion vector transmitted as the first generation encoding parameter, the image quality does not deteriorate even when the fourth generation encoding process is performed. The controller 70 converts the motion vector motion_vector supplied as the first generation history information into
The motion vector information is supplied to the motion compensation circuit 64 and the variable length coding circuit 58 as motion vector information of the reference picture to be coded in the fourth generation coding process.

【0153】さらに、動きベクトル検出回路50は、フ
レーム予測モードとフィールド予測モードのどちらが選
択されるかを判断するために、フレーム予測モードにお
ける予測誤差とフィールド予測モードおける予測誤差を
それぞれ検出したが、このパラメータ再利用符号化処理
においては、このフレーム予測モードにおける予測誤差
とフィールド予測モードおける予測誤差を検出する処理
は行わずに、第1世代のヒストリ情報として供給されて
いるFrame予測モードかField予測モードかを示すframe/
field_motion_typeを再利用する。なぜなら、第4世代
の符号化処理において検出された各予測モードにおける
予測誤差よりも、第1世代において検出された各予測モ
ードにおける予測誤差の方が精度が高いので、精度の高
い予測誤差によって決定された予測モードを選択した方
がより最適な符号化処理が行うことができるからであ
る。
Further, the motion vector detection circuit 50 detects the prediction error in the frame prediction mode and the prediction error in the field prediction mode in order to determine whether the frame prediction mode or the field prediction mode is selected. In the parameter reuse coding process, the process of detecting the prediction error in the frame prediction mode and the prediction error in the field prediction mode is not performed, and the frame prediction mode supplied as the first generation history information or the field prediction mode is not performed. Mode / frame /
Reuse field_motion_type. The reason is that the prediction error in each prediction mode detected in the first generation is higher in accuracy than the prediction error in each prediction mode detected in the fourth generation encoding process, so that the prediction error is determined by the highly accurate prediction error. This is because the more optimal encoding process can be performed by selecting the predicted mode.

【0154】具体的には、コントローラ70は、この第
1世代のヒストリ情報として供給されているframe/fiel
d_motion_typeに対応する制御信号を予測モード切り替
え回路52に供給し、予測モード切り替え回路52は、
この再利用されたframe/field_motion_typeに対応した
信号処理を行う。
More specifically, the controller 70 transmits the frame / fiel supplied as the first generation history information.
The control signal corresponding to d_motion_type is supplied to the prediction mode switching circuit 52, and the prediction mode switching circuit 52
The signal processing corresponding to the reused frame / field_motion_type is performed.

【0155】さらには、動きベクトル検出回路50は、
通常符号化処理においては、画像内予測モード、前方予
測モード、後方予測モード、または両方向予測モードの
うちのいずれの予測モード(以下、この予測モードを、
予測方向モードとも称する)を選択するかを決定するた
めに、各予測方向モードにおける予測誤差を計算してい
たが、このパラメータ再利用符号化処理においては、各
予測方向モードにおける予測誤差の計算は行わず、第1
世代のヒストリ情報として供給されたmacroblock_type
に基づいて予測方向モードを決定する。なぜなら、第4
世代の符号化処理における各予測方向モードにおける予
測誤差よりも、第1世代の符号化処理における各予測方
向モードにおける予測誤差の方がより精度が高いので、
より精度の高い予測誤差によって決定された予測方向モ
ードを選択した方が、より効率の良い符号化処理が行え
るからである。具体的には、コントローラ70は、第1
世代のヒストリ情報に含まれているmacroblock_typeに
よって示される予測方向モードを選択し、その選択した
予測方向モードに対応するように、演算器53及び動き
補償回路64をコントロールする。
Further, the motion vector detection circuit 50
In the normal encoding process, any one of the intra prediction mode, the forward prediction mode, the backward prediction mode, and the bidirectional prediction mode (hereinafter, this prediction mode is referred to as
In order to determine whether to select the prediction direction mode), the prediction error in each prediction direction mode is calculated. In this parameter reuse encoding process, the prediction error in each prediction direction mode is calculated. No, 1st
Macroblock_type supplied as generation history information
The prediction direction mode is determined based on. Because the fourth
Since the prediction error in each prediction direction mode in the first generation encoding process is more accurate than the prediction error in each prediction direction mode in the generation encoding process,
This is because the more efficient encoding process can be performed by selecting the prediction direction mode determined by the more accurate prediction error. Specifically, the controller 70
The prediction direction mode indicated by the macroblock_type included in the history information of the generation is selected, and the arithmetic unit 53 and the motion compensation circuit 64 are controlled so as to correspond to the selected prediction direction mode.

【0156】DCTモード切り替え回路55は、通常符
号化処理においては、フレームDCTモードの符号化効率
と、フィールドDCTモードの符号化効率を比較するため
に、フレームDCTモードの信号形態に変換した信号と、
フィールドDCTモードの信号形態に変換した信号の両方
をDCT回路56に供給していたが、このパラメータ再
利用符号化処理では、フレームDCTモードの信号形態に
変換した信号と、フィールドDCTモードの信号形態に変
換した信号の両方を生成する処理は行っておらず、第1
世代のヒストリ情報に含まれれているdct_typeによって
示されたDCTモードに対応する処理のみを行ってい
る。具体的には、コントローラ70は、第1世代のヒス
トリ情報に含まれているdct_typeを再利用し、DCTモ
ード切り替え回路55がこのdct_typeによって示される
DCTモードに対応した信号処理を行うように、DCT
モード切り替え回路55をコントロールする。
In the normal encoding process, the DCT mode switching circuit 55 compares a signal converted into a signal format in the frame DCT mode with a signal converted in the frame DCT mode in order to compare the encoding efficiency in the frame DCT mode with the encoding efficiency in the field DCT mode. ,
Although both the signal converted into the field DCT mode signal form are supplied to the DCT circuit 56, in this parameter reuse encoding processing, the signal converted into the frame DCT mode signal form and the field DCT mode signal form are used. No processing to generate both of the signals converted to
Only the processing corresponding to the DCT mode indicated by dct_type included in the history information of the generation is performed. Specifically, the controller 70 reuses the dct_type included in the first-generation history information, and performs the DCT so that the DCT mode switching circuit 55 performs signal processing corresponding to the DCT mode indicated by the dct_type.
The mode switching circuit 55 is controlled.

【0157】コントローラ70は、通常符号化処理で
は、オペレータによって指定されたターゲットビットレ
ートと送信バッファ残量に基づいて、量子化回路57の
量子化ステップサイズをコントロールしていたが、この
パラメータ再利用符号化処理では、ターゲットビットレ
ート、送信バッファ残量及びヒストリ情報に含まれてい
る過去の量子化スケールに基づいて、量子化回路57の
量子化ステップサイズをコントロールする。なお、以下
の説明において、ヒストリ情報に含まれている過去の量
子化スケールをhistory_q_scale_code と記述すること
にする。また、後述するヒストリストリームにおいて
は、この量子化スケールを、quantiser_scale_codeと記
述している。
In the normal encoding process, the controller 70 controls the quantization step size of the quantization circuit 57 based on the target bit rate and the remaining amount of the transmission buffer specified by the operator. In the encoding process, the quantization step size of the quantization circuit 57 is controlled based on the target bit rate, the remaining amount of the transmission buffer, and the past quantization scale included in the history information. In the following description, the past quantization scale included in the history information will be described as history_q_scale_code. In the history stream described later, this quantization scale is described as quantizer_scale_code.

【0158】まず、コントローラ70は、通常符号化処
理と同じように、現在の量子化スケールfeedback_q_sca
le_code を生成する。このfeedback_q_scale_codeは、
この送信バッファ59がオーバーフロー及びアンダーフ
ローしないように、この送信バッファ59のバッファ残
量に応じて決定される値である。続いて、第1世代のヒ
ストリストリームに含まれている過去の量子化スケール
history_q_scale_codeの値と、この現在の量子化スケー
ルfeedback_q_scale_codeの値を比較し、どちらの量子
化スケールの方が大きいかを判断する。量子化スケール
が大きいとは、量子化ステップが大きいことを意味す
る。もし、現在の量子化スケールfeedback_q_scale_cod
eが、過去の量子化スケールhistory_q_scale_codeより
も大きいのであれば、コントローラ70は、この現在の
量子化スケールfeedback_q_scale_codeを量子化回路5
7に供給する。一方、過去の量子化スケールhistory_q_
scale_codeが、現在の量子化スケールfeedback_q_scale
_codeよりも大きいのであれば、コントローラ70は、
この過去の量子化スケールhistory_q_scale_codeを量子
化回路57に供給する。
First, the controller 70 controls the current quantization scale feedback_q_sca in the same manner as in the normal encoding process.
Generate le_code. This feedback_q_scale_code is
This value is determined according to the remaining amount of the transmission buffer 59 so that the transmission buffer 59 does not overflow or underflow. Next, the past quantization scale included in the first generation history stream
The value of history_q_scale_code is compared with the value of the current quantization scale feedback_q_scale_code to determine which quantization scale is larger. A large quantization scale means that the quantization step is large. If the current quantization scale feedback_q_scale_cod
If e is larger than the past quantization scale history_q_scale_code, the controller 70 converts the current quantization scale feedback_q_scale_code into the quantization circuit 5
7 On the other hand, the past quantization scale history_q_
scale_code is the current quantization scale feedback_q_scale
If it is larger than _code, the controller 70
The past quantization scale history_q_scale_code is supplied to the quantization circuit 57.

【0159】つまり、コントローラ70は、ヒストリ情
報に含まれている複数の過去の量子化スケールと、送信
バッファの残量から計算された現在の量子化スケールの
中で、もっとも大きい量子化スケールコードを選択す
る。また、別の言葉で説明するのであれば、コントロー
ラ70は、過去(第1、第2及び第3世代)の符号化処
理における量子化ステップまたは現在(第4世代)の符
号化処理において使用された量子化ステップの中で、も
っとも大きい量子化ステップを使用して量子化を行うよ
うに量子化回路57を制御する。この理由を以下に説明
する。
That is, the controller 70 sets the largest quantization scale code among the plurality of past quantization scales included in the history information and the current quantization scale calculated from the remaining amount of the transmission buffer. select. In other words, the controller 70 is used in a quantization step in a past (first, second, and third generation) encoding process or in a current (fourth generation) encoding process. The quantization circuit 57 is controlled so as to perform quantization using the largest quantization step among the quantization steps. The reason will be described below.

【0160】たとえば、第3世代の符号化処理において
生成されたストリームのビットレートが4[Mbps]であっ
て、この第4世代の符号化処理を行うエンコーダ121
に対して設定されたターゲットビットレートが15[Mbp
s]であったとする。このときに、ターゲットビットレー
トが上がっているので、単純に量子化ステップを小さく
すれば良いかというと、実際にはそうではない。過去の
符号化処理において大きい量子化ステップで符号化処理
されたピクチャを、現在の符号化処理において、量子化
ステップを小さくして符号化処理を行ったとしても、こ
のピクチャの画質は向上することなない。つまり、過去
の符号化処理における量子化ステップよりも小さい量子
化ステップで符号化することは、単にビット量が増える
だけであって、画質を向上させることにはならない。よ
って、過去(第1、第2及び第3世代)の符号化処理に
おける量子化ステップまたは現在(第4世代)の符号化
処理において使用された量子化ステップの中で、もっと
も大きい量子化ステップを使用して量子化を行うと、も
っとも効率の良い符号化処理が行える。
For example, if the bit rate of the stream generated in the third generation encoding process is 4 [Mbps], and the encoder 121 performs the fourth generation encoding process,
Target bit rate set to 15 [Mbp
s]. At this time, since the target bit rate is increased, it is not actually the case that the quantization step should be simply reduced. Even if a picture coded in a large quantization step in a past coding process is coded with a small quantization step in a current coding process, the picture quality of the picture is improved. No. In other words, encoding with a quantization step smaller than the quantization step in the past encoding process merely increases the bit amount, but does not improve the image quality. Accordingly, the largest quantization step among the quantization steps in the past (first, second, and third generation) encoding processes or the quantization steps used in the current (fourth generation) encoding process is defined as When the quantization is performed using this, the most efficient encoding process can be performed.

【0161】次に、図15におけるヒストリデコーディ
ング装置104とヒストリエンコーディング装置107
についてさらに説明する。同図に示すように、ヒストリ
デコーディング装置104は、復号装置102より供給
されるユーザデータをデコードするユーザデータデコー
ダ201、ユーザデータデコーダ201の出力を変換す
るコンバータ202、およびコンバータ202の出力か
ら履歴情報を再生するヒストリVLD203により構成さ
れている。
Next, the history decoding device 104 and the history encoding device 107 in FIG.
Will be further described. As shown in the figure, the history decoding device 104 includes a user data decoder 201 for decoding user data supplied from the decoding device 102, a converter 202 for converting the output of the user data decoder 201, and a history from the output of the converter 202. It comprises a history VLD 203 for reproducing information.

【0162】また、ヒストリエンコーディング装置10
7は、ヒストリ情報分離装置105より供給される3世
代分の符号化パラメータをフォーマット化するヒストリ
VLC211、ヒストリVLC211の出力を変換するコンバ
ータ212、コンバータ212の出力をユーザデータの
フォーマットにフォーマットするユーザデータフォーマ
ッタ213により構成されている。
The history encoding device 10
Reference numeral 7 denotes a history for formatting the encoding parameters for three generations supplied from the history information separating device 105.
It comprises a VLC 211, a converter 212 for converting the output of the history VLC 211, and a user data formatter 213 for formatting the output of the converter 212 into a user data format.

【0163】ユーザデータデコーダ201は、復号装置
102より供給されるユーザデータをデコードして、コ
ンバータ202に出力する。詳細は図51を参照して後
述するが、ユーザデータ(user_data())は、user_data
_start_codeとuser_dataからなり、MPEG規格においては
user_dataの中に、連続する23ビットの”0”(start
_codeと同一のコード)を発生させることを禁止してい
る。これは、そのデータが、start_codeとして誤検出さ
れるのを防止するためである。履歴情報(history_stre
am())は、ユーザデータエリアに(MPEG規格のuser_dat
aの一種として)記述され、その中には、このような連
続する23ビット以上の”0”が存在することがあり得
るので、これを、連続する23ビット以上の”0”が発
生しないように、所定のタイミングで“1”を挿入処理
して、converted_history_stream()(後述する図38)
に変換する必要がある。この変換を行うのは、ヒストリ
エンコーディング装置107のコンバータ212であ
る。ヒストリデコーディング装置104のコンバータ2
02は、このコンバータ212と逆の変換処理を行う
(連続する23ビット以上の”0”を発生させないため
に挿入された”1”を除去する)ものである。
[0163] The user data decoder 201 decodes the user data supplied from the decoding device 102 and outputs it to the converter 202. Although details will be described later with reference to FIG. 51, the user data (user_data ())
_start_code and user_data. In the MPEG standard,
In user_data, continuous 23-bit “0” (start
(the same code as _code) is prohibited. This is to prevent that data from being erroneously detected as start_code. History information (history_stre
am ()) is the user data area (user_dat
a), and there may be such continuous “0” s of 23 bits or more, so that such “0” s of 23 bits or more are not generated. At this time, “1” is inserted at a predetermined timing, and converted_history_stream () (FIG. 38 described later)
Need to be converted to It is the converter 212 of the history encoding device 107 that performs this conversion. Converter 2 of the history decoding device 104
Numeral 02 performs a conversion process reverse to that of the converter 212 (removes “1” inserted in order not to generate consecutive “0” of 23 bits or more).

【0164】ヒストリVLD203は、コンバータ202
の出力から履歴情報(いまの場合、第1世代の符号化パ
ラメータと第2世代の符号化パラメータ)を生成し、ヒ
ストリ情報多重化装置103に出力する。
The history VLD 203 includes a converter 202
, The history information (in this case, the first-generation coding parameter and the second-generation coding parameter) is generated and output to the history information multiplexing device 103.

【0165】一方、ヒストリエンコーディング装置10
7においては、ヒストリVLC211がヒストリ情報分離
装置105より供給される3世代分の(第1世代、第2
世代、および第3世代の)符号化パラメータを履歴情報
のフォーマットに変換する。このフォーマットには、固
定長のもの(後述する図40乃至図46)と、可変長の
もの(後述する図47)とがある。これらの詳細につい
ては後述する。
On the other hand, the history encoding device 10
7, the history VLC 211 corresponds to three generations supplied from the history information separation device 105 (first generation, second generation).
The encoding parameters of the generation and the third generation are converted into the format of the history information. This format includes a fixed-length format (FIGS. 40 to 46 described later) and a variable-length format (FIG. 47 described later). Details of these will be described later.

【0166】ヒストリVLC211により、フォーマット
化された履歴情報は、コンバータ212において、conv
erted_history_stream()に変換される。これは、上述し
たように、user_data()のstart_codeが誤検出されない
ようにするための処理である。すなわち、履歴情報内に
は連続する23ビット以上の”0”が存在するが、user
_data中には連続する23ビット以上の”0”を配置す
ることができないので、この禁止項目に触れないように
コンバータ212によりデータを変換する(“1”を所
定のタイミングで挿入する)のである。
The history information formatted by the history VLC 211 is converted by the converter 212 into a conv
Converted to erted_history_stream (). This is a process for preventing the start_code of user_data () from being erroneously detected, as described above. That is, there are consecutive “0” s of 23 bits or more in the history information,
Since it is not possible to arrange consecutive “0” s of 23 bits or more in _data, the data is converted by the converter 212 (“1” is inserted at a predetermined timing) so as not to touch this prohibited item. .

【0167】ユーザデータフォーマッタ213は、コン
バータ212より供給されるconverted_history_stream
()に、後述する図38に基づいて、History_Data_IDを
付加し、さらに、user_data_stream_codeを付加して、v
ideo stream中に挿入できるMPEG規格のuser_dataを生成
し、符号化装置106に出力する。
The user data formatter 213 converts the converted_history_stream supplied from the converter 212.
(), History_Data_ID is added based on FIG. 38 described later, and further, user_data_stream_code is added, and v
It generates MPEG_standard user_data that can be inserted into the ideo stream and outputs it to the encoding device 106.

【0168】図20は、ヒストリVLC211の構成例を
表している。その符号語変換器301と符号長変換器3
05には、符号化パラメータ(今回、履歴情報として伝
送する符号化パラメータ)(項目データ)と、この符号
化パラメータを配置するストリームを特定する情報(例
えば、シンタックスの名称(例えば、後述するsequence
_headerの名称))(項目NO.)が、ヒストリ情報分離装
置105から供給されている。符号語変換器301は、
入力された符号化パラメータを、指示されたシンタック
スに対応する符号語に変換し、バレルシフタ302に出
力する。バレルシフタ302は、符号語変換器301よ
り入力された符号語を、アドレス発生回路306より供
給されるシフト量に対応する分だけシフトし、バイト単
位の符号語として、スイッチ303に出力する。アドレ
ス発生回路306が出力するビットセレクト信号により
切り換えられるスイッチ303は、ビット分設けられて
おり、バレルシフタ302より供給される符号語を、RA
M304に供給し、記憶させる。このときの書き込みア
ドレスは、アドレス発生回路306から指定される。ま
た、アドレス発生回路306から読み出しアドレスが指
定されたとき、RAM304に記憶されているデータ(符
号語)が読み出され、後段のコンバータ212に供給さ
れるとともに、必要に応じて、スイッチ303を介して
RAM304に再び供給され、記憶される。
FIG. 20 shows an example of the configuration of the history VLC 211. The code word converter 301 and the code length converter 3
05, an encoding parameter (an encoding parameter to be transmitted as history information this time) (item data) and information for specifying a stream in which the encoding parameter is arranged (for example, syntax name (for example, sequence
_header name)) (item No.) is supplied from the history information separation device 105. The codeword converter 301
The input encoding parameter is converted into a codeword corresponding to the specified syntax, and output to the barrel shifter 302. The barrel shifter 302 shifts the codeword input from the codeword converter 301 by an amount corresponding to the shift amount supplied from the address generation circuit 306, and outputs the result to the switch 303 as a codeword in byte units. A switch 303 that is switched by a bit select signal output from the address generation circuit 306 is provided for each bit, and converts a code word supplied from the barrel shifter 302 into RA.
It is supplied to M304 and stored. The write address at this time is specified by the address generation circuit 306. When a read address is specified from the address generation circuit 306, data (codeword) stored in the RAM 304 is read and supplied to the converter 212 at the subsequent stage. hand
The data is again supplied to the RAM 304 and stored.

【0169】符号長変換器305は、入力されるシンタ
ックスと符号化パラメータとから、その符号化パラメー
タの符号長を決定し、アドレス発生回路306に出力す
る。アドレス発生回路306は、入力された符号長に対
応して、上述したシフト量、ビットセレクト信号、書き
込みアドレス、または読み出しアドレスを生成し、それ
らを、それぞれバレルシフタ302、スイッチ303、
またはRAM304に供給する。
The code length converter 305 determines the code length of the coding parameter from the input syntax and the coding parameter, and outputs it to the address generation circuit 306. The address generation circuit 306 generates the above-described shift amount, bit select signal, write address, or read address in accordance with the input code length, and transfers them to the barrel shifter 302, the switch 303,
Alternatively, the data is supplied to the RAM 304.

【0170】以上のように、ヒストリVLC211は、い
わゆる可変長符号化器として構成され、入力された符号
化パラメータを可変長符号化して出力する。
As described above, the history VLC 211 is configured as a so-called variable-length coder, and performs variable-length coding on input coding parameters and outputs the result.

【0171】図21は、以上のようにしてヒストリフォ
ーマット化されたデータをデコードするヒストリVLD2
03の構成例を表している。このヒストリVLD203に
は、コンバータ202から供給された符号化パラメータ
のデータがRAM311に供給されて、記憶される。この
ときの書き込みアドレスは、アドレス発生回路315か
ら供給される。アドレス発生回路315はまた、所定の
タイミングで読み出しアドレスを発生し、RAM311に
供給する。このとき、RAM311は、読み出しアドレス
に記憶されているデータを読み出し、バレルシフタ31
2に出力する。バレルシフタ312は、アドレス発生回
路315が出力するシフト量に対応する分だけ、入力さ
れるデータをシフトし、逆符号長変換器313と逆符号
語変換器314に出力する。
FIG. 21 shows a history VLD2 for decoding the history-formatted data as described above.
03 shows a configuration example. In the history VLD 203, the data of the encoding parameter supplied from the converter 202 is supplied to the RAM 311 and stored. The write address at this time is supplied from the address generation circuit 315. The address generation circuit 315 also generates a read address at a predetermined timing and supplies it to the RAM 311. At this time, the RAM 311 reads the data stored at the read address, and
Output to 2. The barrel shifter 312 shifts the input data by an amount corresponding to the shift amount output from the address generation circuit 315, and outputs the data to the inverse code length converter 313 and the inverse code word converter 314.

【0172】逆符号長変換器313にはまた、コンバー
タ202から、符号化パラメータが配置されているスト
リームのシンタックスの名称(項目NO.)が供給されて
いる。逆符号長変換器313は、そのシンタックスに基
づいて、入力されたデータ(符号語)から符号長を求
め、求めた符号長をアドレス発生回路315に出力す
る。
The inverse code length converter 313 is also supplied from the converter 202 with the name of the syntax (item No.) of the stream in which the encoding parameters are arranged. The inverse code length converter 313 calculates the code length from the input data (code word) based on the syntax, and outputs the calculated code length to the address generation circuit 315.

【0173】また、逆符号語変換器314は、バレルシ
フタ312より供給されたデータを、シンタックスに基
づいて復号し(逆符号語化し)、ヒストリ情報多重化装
置103に出力する。
The inverse codeword converter 314 decodes the data supplied from the barrel shifter 312 based on the syntax (converts the data into an inverse codeword) and outputs the decoded data to the history information multiplexing device 103.

【0174】また、逆符号語変換器314は、どのよう
な符号語が含まれているのかを特定するのに必要な情報
(符号語の区切りを決定するのに必要な情報)を抽出
し、アドレス発生回路315に出力する。アドレス発生
回路315は、この情報と逆符号長変換器313より入
力された符号長に基づいて、書き込みアドレスおよび読
み出しアドレスを発生し、RAM311に出力するととも
に、シフト量を発生し、バレルシフタ312に出力す
る。
The inverse codeword converter 314 extracts information necessary for specifying what codeword is included (information necessary for determining a codeword delimiter). Output to the address generation circuit 315. The address generation circuit 315 generates a write address and a read address based on the information and the code length input from the inverse code length converter 313, outputs the write address and the read address to the RAM 311, generates a shift amount, and outputs the shift amount to the barrel shifter 312. I do.

【0175】図22は、コンバータ212の構成例を表
している。この例においては、ヒストリVLC211とコ
ンバータ212の間に配置されているバッファメモリ3
20の、コントローラ326が出力する読み出しアドレ
スから8ビットのデータが読み出され、D型フリップフ
ロップ(D−FF)321に供給され、保持されるよう
になされている。そして、D型フリップフロップ321
より読み出されたデータは、スタッフ回路323に供給
されるとともに、8ビットのD型フリップフロップ32
2にも供給され、保持される。D型フリップフロップ3
22より読み出された8ビットのデータは、D型フリッ
プフロップ321より読み出された8ビットのデータと
合成され、16ビットのパラレルデータとして、スタッ
フ回路323に供給される。
FIG. 22 shows a configuration example of the converter 212. In this example, the buffer memory 3 arranged between the history VLC 211 and the converter 212
The 8-bit data is read from the 20 read addresses output by the controller 326, supplied to a D-type flip-flop (D-FF) 321, and held therein. Then, the D-type flip-flop 321
The read data is supplied to the stuff circuit 323 and the D-type flip-flop 32
2 is also supplied and held. D-type flip-flop 3
The 8-bit data read from 22 is combined with the 8-bit data read from the D-type flip-flop 321 and supplied to the stuff circuit 323 as 16-bit parallel data.

【0176】スタッフ回路323は、コントローラ32
6より供給されるスタッフ位置を示す信号(stuff posi
tion)の位置に符号”1”を挿入し(スタッフィング
し)、合計17ビットのデータとして、バレルシフタ3
24に出力する。
The stuff circuit 323 includes the controller 32
Signal indicating staff position (stuff posi
1) is inserted (stuffing) into the position of the barrel shifter 3 as a total of 17 bits.
24.

【0177】バレルシフタ324は、コントローラ32
6より供給されるシフト量を示す信号(shift)に基づ
いて入力されたデータをシフトして、8ビットのデータ
を抽出し、8ビットのD型フリップフロップ325に出
力する。D型フリップフロップ325に保持されたデー
タは、そこから読み出され、バッファメモリ327を介
して、後段のユーザデータフォーマッタ213に供給さ
れる。この時、コントローラ326は、出力するデータ
とともに、書き込みアドレスを発生し、コンバータ21
2とユーザデータフォーマッタ213との間に介在する
バッファメモリ327に供給する。
The barrel shifter 324 includes the controller 32
The input data is shifted based on a signal (shift) indicating the shift amount supplied from 6 to extract 8-bit data, and output to the 8-bit D-type flip-flop 325. The data held in the D-type flip-flop 325 is read therefrom and supplied to the subsequent user data formatter 213 via the buffer memory 327. At this time, the controller 326 generates a write address together with the output data,
2 and a user data formatter 213.

【0178】図23は、スタッフ回路323の構成例を
表している。D型フリップフロップ322,321より
入力された16ビットのデータは、それぞれスイッチ3
31−16乃至331−1の接点aに入力されている。
スイッチ331−i(i=0乃至15)の接点cには、
MSB側(図中上方)に隣接するスイッチのデータが供給
されている。例えば、スイッチ331−12の接点cに
は、MSB側に隣接するスイッチ331−13の接点aに
供給されているLSBから13番目のデータが供給されて
おり、スイッチ331−13の接点cには、MSB側に隣
接するスイッチ331−14の接点aに供給されている
LSB側から14番目のデータが供給されている。
FIG. 23 shows a configuration example of the stuff circuit 323. The 16-bit data input from the D-type flip-flops 322 and 321
It is input to the contacts a of 31-16 to 331-1.
The contact c of the switch 331-i (i = 0 to 15)
The data of the adjacent switch is supplied to the MSB side (upper side in the figure). For example, to the contact c of the switch 331-12, the 13th data from the LSB supplied to the contact a of the switch 331-13 adjacent to the MSB side is supplied, and to the contact c of the switch 331-13. , MSB side, is supplied to the contact a of the switch 331-14 adjacent thereto.
The fourteenth data is supplied from the LSB side.

【0179】但し、LSBに対応するスイッチ331−1
よりさらに下側のスイッチ331−0の接点aは、開放
されている。また、MSBに対応するスイッチ331−1
6の接点cは、それより上位のスイッチが存在しないた
め、開放されている。
However, the switch 331-1 corresponding to the LSB
The contact a of the switch 331-0 on the lower side is open. Also, the switch 331-1 corresponding to the MSB
The contact c of No. 6 is open because there is no higher-order switch.

【0180】各スイッチ331−0乃至331−16の
接点bには、データ”1”が供給されている。
Data "1" is supplied to a contact point b of each of the switches 331-0 to 331-16.

【0181】デコーダ332は、コントローラ326よ
り供給されるデータ”1”を挿入する位置を示す信号st
uff positionに対応して、スイッチ331−0乃至33
1−16のうち、1つのスイッチを接点b側に切り替
え、それよりLSB側のスイッチは、接点c側にそれぞれ
切り替えさせ、それよりMSB側のスイッチは、接点a側
に切り替えさせる。
The decoder 332 outputs a signal st indicating the position at which the data "1" supplied from the controller 326 is to be inserted.
Switches 331-0 through 33 corresponding to the uff position
Of the switches 1-16, one switch is switched to the contact b side, the switch on the LSB side is switched to the contact c side, and the switch on the MSB side is switched to the contact a side.

【0182】図23は、LSB側から13番目にデータ”
1”を挿入する場合の例を示している。従って、この場
合、スイッチ331−0乃至スイッチ331−12は、
いずれも接点c側に切り替えられ、スイッチ331−1
3は、接点b側に切り替えられ、スイッチ331−14
乃至スイッチ331−16は、接点a側に切り替えられ
ている。
FIG. 23 shows the thirteenth data from the LSB side.
1 "is inserted. In this case, the switches 331-0 to 331-12 are
Both are switched to the contact c side, and the switch 331-1
3 is switched to the contact b side, and the switch 331-14
The switches 331-16 are switched to the contact a side.

【0183】図22のコンバータ212は、以上のよう
な構成により、22ビットの符号を23ビットに変換し
て、出力することになる。
The converter 212 shown in FIG. 22 converts a 22-bit code into 23 bits and outputs the converted code according to the above configuration.

【0184】図24は、図22のコンバータ212の各
部の出力データのタイミングを表している。コンバータ
212のコントローラ326がバイト単位のクロックに
同期して、読み出しアドレス(図24(A))を発生す
ると、バッファメモリ320から、それに対応するデー
タが、バイト単位で読み出され、D型フリップフロップ
321に一旦保持される。そして、D型フリップフロッ
プ321より読み出されたデータ(図24(B))は、
スタッフ回路323に供給されるとともに、D型フリッ
プフロップ322に供給され、保持される。D型フリッ
プフロップ322に保持されたデータは、そこからさら
に読み出され(図24(C))、スタッフ回路323に
供給される。
FIG. 24 shows the timing of the output data of each section of the converter 212 shown in FIG. When the controller 326 of the converter 212 generates a read address (FIG. 24A) in synchronization with a clock in units of bytes, data corresponding to the read address is read from the buffer memory 320 in units of bytes, and the D-type flip-flop is read. 321 is temporarily held. The data (FIG. 24B) read from the D-type flip-flop 321 is
The signal is supplied to the stuff circuit 323 and supplied to and held in the D-type flip-flop 322. The data held in the D-type flip-flop 322 is further read therefrom (FIG. 24C) and supplied to the stuff circuit 323.

【0185】従って、スタッフ回路323の入力(図2
4(D))は、読み出しアドレスA1のタイミングにお
いて、最初の1バイトのデータD0とされ、次の読み出
しアドレスA2のタイミングにおいて、1バイトのデー
タD0と1バイトのデータD1より構成される2バイト
のデータとなり、さらに読み出しアドレスA3のタイミ
ングにおいては、データD1とデータD2より構成され
る2バイトのデータとなる。
Therefore, the input of the stuff circuit 323 (FIG. 2)
4 (D)) is the first 1-byte data D0 at the timing of the read address A1, and 2 bytes composed of 1-byte data D0 and 1-byte data D1 at the next read address A2 timing. At the timing of the read address A3, and becomes 2-byte data composed of data D1 and data D2.

【0186】スタッフ回路323には、データ”1”を
挿入する位置を示す信号stuff position(図24
(E))がコントローラ326より供給される。スタッ
フ回路323のデコーダ332は、スイッチ331−1
6乃至331−0のうち、この信号stuff positionに対
応するスイッチを接点bに切り換え、それよりLSB側の
スイッチを接点c側に切り換え、さらにそれよりMSB側
のスイッチを接点a側に切り換える。これにより、デー
タ”1”が挿入されるので、スタッフ回路323から
は、信号stuff positionで示す位置に、データ”1”が
挿入されたデータ(図24(F))が出力される。
The stuff circuit 323 has a signal stuff position (FIG. 24) indicating the position where data "1" is to be inserted.
(E)) is supplied from the controller 326. The decoder 332 of the stuff circuit 323 includes a switch 331-1.
Among 6 to 331-0, the switch corresponding to the signal stuff position is switched to the contact b, the switch on the LSB side is switched to the contact c side, and the switch on the MSB side is further switched to the contact a side. As a result, since the data “1” is inserted, the stuff circuit 323 outputs data (FIG. 24F) with the data “1” inserted at the position indicated by the signal stuff position.

【0187】バレルシフタ324は、入力されたデータ
を、コントローラ326より供給される信号shift(図
24(G))で示される量だけバレルシフトして、出力
する(図24(H)) 。この出力がさらにD型フリッ
プフロップ325で一旦保持された後、後段に出力され
る(図24(I))。
The barrel shifter 324 barrel-shifts the input data by the amount indicated by the signal shift (FIG. 24 (G)) supplied from the controller 326 and outputs (FIG. 24 (H)). This output is once held by the D-type flip-flop 325 and then output to the subsequent stage (FIG. 24 (I)).

【0188】D型フリップフロップ325より出力され
るデータには、22ビットのデータの次に、データ”
1”が挿入されている。従って、データ”1”と、次の
データ”1”の間には、その間のビットが全て0であっ
たとしても、0のデータの連続する数は22となる。
The data output from the D-type flip-flop 325 includes data “22” next to data “22”.
Therefore, the number of consecutive 0s is 22 between the data "1" and the next data "1", even if all the bits between them are "0". .

【0189】図25は、コンバータ202の構成例を表
している。このコンバータ202のD型フリップフロッ
プ341乃至コントローラ346よりなる構成は、図2
2に示したコンバータ212のD型フリップフロップ3
21乃至コントローラ326と基本的に同様の構成であ
るが、コンバータ212におけるスタッフ回路323に
代えて、ディリート回路343が挿入されている点がコ
ンバータ212における場合と異なっている。その他の
構成は、図22のコンバータ212における場合と同様
である。
FIG. 25 shows a configuration example of the converter 202. The configuration of the converter 202 including the D flip-flop 341 to the controller 346 is the same as that shown in FIG.
D-type flip-flop 3 of converter 212 shown in FIG.
21 to the controller 326, except that the converter 212 has a delay circuit 343 in place of the stuff circuit 323. Other configurations are the same as those of converter 212 in FIG.

【0190】すなわち、このコンバータ202において
は、コントローラ346が出力する削除するビットの位
置を示す信号delete positionに従って、ディリート回
路343が、そのビット(図22のスタッフ回路323
で挿入されたデータ”1”)が削除される。
In other words, in converter 202, according to signal delete position indicating the position of the bit to be deleted output from controller 346, delete circuit 343 replaces the bit (stuff circuit 323 in FIG. 22).
The data "1") inserted in is deleted.

【0191】その他の動作は、図22のコンバータ21
2における場合と同様である。
Other operations are similar to those of converter 21 shown in FIG.
2 is the same as in the case of FIG.

【0192】図26は、ディリート回路343の構成例
を表している。この構成例においては、D型フリップフ
ロップ342,341より入力された16ビットのデー
タのうち、LSB側の15ビットが、それぞれ対応するス
イッチ351−0乃至351−14の接点aに供給され
ている。各スイッチの接点bには、1ビットだけMSB側
のデータが供給されている。デコーダ352は、コント
ローラ346より供給される信号delete positionによ
り指定されるビットを削除して、15ビットのデータと
して出力するようになされている。
FIG. 26 shows a configuration example of the delay circuit 343. In this configuration example, of the 16-bit data input from the D-type flip-flops 342 and 341, 15 bits on the LSB side are supplied to the contacts a of the corresponding switches 351-0 to 351-14. . Only one bit of data on the MSB side is supplied to the contact b of each switch. The decoder 352 deletes the bit specified by the signal delete position supplied from the controller 346 and outputs it as 15-bit data.

【0193】図26は、LSBから第13番目のビットが
ディリートされる状態を示している。従って、この場
合、スイッチ351−0乃至スイッチ351−11が接
点a側に切り替えられ、LSBから第12番目までの12
ビットが、そのまま選択、出力されている。また、スイ
ッチ351−12乃至351−14は、それぞれ接点b
側に切り替えられているので、第14番目乃至第16番
目のデータが、第13番目乃至第15番目のビットのデ
ータとして選択、出力される。
FIG. 26 shows a state where the 13th bit from the LSB is deleted. Therefore, in this case, the switches 351-0 to 351-11 are switched to the contact a side, and the 12th from the LSB to the twelfth is switched.
Bits are selected and output as they are. The switches 351-12 to 351-14 are respectively connected to the contact b
Side, the 14th to 16th data are selected and output as the 13th to 15th bit data.

【0194】図23のスタッフ回路323および図26
のディリート回路343の入力が16ビットとなってい
るのは、それぞれ図22のコンバータ212のスタッフ
回路323の入力が、D型フリップフロップ322,3
21より供給される16ビットとされており、また、図
25のコンバータ202においても、ディリート回路3
43の入力が、D型フリップフロップ342,341に
より16ビットとされているためである。図22におい
て、スタッフ回路323の出力する17ビットをバレル
シフタ324でバレルシフトすることにより、例えば8
ビットを最終的に選択、出力しているのと同様に、図2
5のコンバータ202においても、ディリート回路34
3の出力する15ビットのデータを、バレルシフタ34
4で所定量だけバレルシフトすることにより、8ビット
のデータとしている。
The stuff circuit 323 in FIG. 23 and FIG.
The input of the stuffing circuit 323 of the converter 212 in FIG.
The 16 bits are supplied from the converter 21 and the converter 202 in FIG.
This is because the input of 43 is made 16 bits by the D-type flip-flops 342 and 341. In FIG. 22, 17 bits output from the stuff circuit 323 are barrel-shifted by the barrel shifter 324, for example, to 8 bits.
As with the final selection and output of the bits, FIG.
In the converter 202 of FIG.
3 is output to the barrel shifter 34.
The data is barrel-shifted by a predetermined amount at 4 to obtain 8-bit data.

【0195】図27は、コンバータ212の他の構成例
を表している。この構成例においては、カウンタ361
が入力データのうち、連続する0のビットの数をカウン
トし、そのカウント結果をコントローラ326に出力す
るようになされている。コントローラ326は、例えば
カウンタ361が連続する0のビットを22個カウント
したとき、信号stuff positionをスタッフ回路323に
出力する。また、このとき、コントローラ326は、カ
ウンタ361をリセットし、再び連続する0のビットの
数をカウンタ361にカウントさせる。
FIG. 27 shows another configuration example of converter 212. In this configuration example, the counter 361
Counts the number of consecutive 0 bits in the input data, and outputs the count result to the controller 326. The controller 326 outputs a signal stuff position to the stuff circuit 323 when, for example, the counter 361 counts 22 consecutive 0 bits. At this time, the controller 326 resets the counter 361 and causes the counter 361 to count the number of consecutive 0 bits again.

【0196】その他の構成と動作は、図22における場
合と同様である。
Other structures and operations are the same as those in FIG.

【0197】図28は、コンバータ202の他の構成例
を表している。この構成例においては、入力データのう
ち、連続する0の数をカウンタ371がカウントし、そ
のカウント結果をコントローラ346に出力するように
なされている。カウンタ371のカウント値が22に達
したとき、コントローラ346は、信号delete positio
nをディリート回路343に出力するとともに、カウン
タ371をリセットし、再び新たな連続する0のビット
の数をカウンタ371にカウントさせる。その他の構成
は、図25における場合と同様である。
FIG. 28 shows another configuration example of converter 202. In this configuration example, the counter 371 counts the number of consecutive 0s in the input data, and outputs the count result to the controller 346. When the count value of the counter 371 reaches 22, the controller 346 sends the signal delete positio
n is output to the delete circuit 343, the counter 371 is reset, and the counter 371 again counts the number of new continuous 0 bits. Other configurations are the same as those in FIG.

【0198】このように、この構成例においては、所定
のパターン(データ”0”の連続する数)に基づいて、
マーカービットとしてのデータ”1”が挿入され、ま
た、削除されることになる。
As described above, in this configuration example, based on a predetermined pattern (a continuous number of data “0”),
Data "1" as a marker bit is inserted and deleted.

【0199】図27と図28に示す構成は、図22と図
25に示す構成よりも効率的な処理が可能となる。但
し、変換後の長さが元の履歴情報に依存することにな
る。
The configuration shown in FIGS. 27 and 28 enables more efficient processing than the configurations shown in FIGS. 22 and 25. However, the length after conversion depends on the original history information.

【0200】図29は、ユーザデータフォーマッタ21
3の構成例を表している。この例においては、コントロ
ーラ383がコンバータ212とユーザデータフォーマ
ッタ213との間に配置されているバッファメモリ(図
示せず)に読み出しアドレスを出力すると、そこから読
み出されたデータが、ユーザデータフォーマッタ213
のスイッチ382の接点a側に供給される。ROM381
には、ユーザデータスタートコード、データIDなどの
user_data()を生成するのに必要なデータが記憶されて
いる。コントローラ313は、所定のタイミングにおい
て、スイッチ382を接点a側または接点b側に切り替
え、ROM381に記憶されているデータ、またはコンバ
ータ212より供給されるデータを適宜選択し、出力す
る。これにより、user_data()のフォーマットのデータ
が符号化装置106に出力される。
FIG. 29 shows the user data formatter 21
3 shows a configuration example. In this example, when the controller 383 outputs a read address to a buffer memory (not shown) arranged between the converter 212 and the user data formatter 213, the data read therefrom is output to the user data formatter 213.
Is supplied to the contact a side of the switch 382 of FIG. ROM381
Contains user data start code, data ID, etc.
Data necessary to generate user_data () is stored. At a predetermined timing, the controller 313 switches the switch 382 to the contact a side or the contact b side, and appropriately selects and outputs data stored in the ROM 381 or data supplied from the converter 212. As a result, data in the format of user_data () is output to the encoding device 106.

【0201】なお、図示は省略するが、ユーザデータデ
コーダ201は、図29のROM381より読み出され、
挿入されたデータを削除するスイッチを介して、入力デ
ータを出力するようにすることで実現することができ
る。
Although not shown, the user data decoder 201 is read from the ROM 381 in FIG.
This can be realized by outputting input data via a switch for deleting inserted data.

【0202】図30は、例えば映像編集スタジオにおい
て、複数のトランスコーダ101−1乃至101−Nが
直列に接続されて使用される状態を示している。各トラ
ンスコーダ101−i(i=1乃至N)のヒストリ情報
多重化装置103−iは、上述した符号化パラメータ用
の領域の最も古い符号化パラメータが記録されている区
画に、自己が用いた最新の符号化パラメータを上書きす
る。このことにより、ベースバンドの画像データには、
同一のマクロブロックに対応する直近の4世代分の符号
化パラメータ(世代履歴情報)が記録されることになる
(図18)。
FIG. 30 shows a state in which a plurality of transcoders 101-1 to 101-N are connected in series and used, for example, in a video editing studio. The history information multiplexing device 103-i of each transcoder 101-i (i = 1 to N) uses the history information multiplexing device 103-i in a section where the oldest coding parameter in the above-described coding parameter area is recorded. Overwrite the latest encoding parameters. As a result, the baseband image data includes
The encoding parameters (generation history information) for the last four generations corresponding to the same macroblock are recorded (FIG. 18).

【0203】各符号化装置106−iのエンコーダ12
1−i(図19)は、その可変長符号化回路58におい
て、ヒストリ情報分離装置105−iから供給される今
回用いる符号化パラメータに基づいて、量子化回路57
より供給されるビデオデータを符号化する。このように
して生成されるビットストリーム(例えば、picture_he
ader())中に、その現符号化パラメータは多重化され
る。
The encoder 12 of each encoding device 106-i
1-i (FIG. 19) in the variable-length coding circuit 58 based on the currently used coding parameters supplied from the history information separation device 105-i.
Encoding the supplied video data. The bit stream generated in this way (for example, picture_he
During ader ()), the current coding parameters are multiplexed.

【0204】可変長符号化回路58はまた、ヒストリエ
ンコーディング装置107−iより供給されるユーザデ
ータ(世代履歴情報を含む)を、出力するビットストリ
ーム中に多重化する(図18に示すような埋め込み処理
ではなく、ビットストリーム中に多重化する)。そし
て、符号化装置106−iの出力するビットストリーム
は、SDTI(Serial Data Transfer Interface)108
−iを介して、後段のトランスコーダ101−(i+
1)に入力される。
The variable length coding circuit 58 also multiplexes user data (including generation history information) supplied from the history encoding device 107-i into a bit stream to be output (embedding as shown in FIG. 18). Multiplexing in the bitstream, not processing). Then, the bit stream output from the encoding device 106-i is converted into a serial data transfer interface (SDTI) 108.
-I, the subsequent transcoder 101- (i +
Input to 1).

【0205】トランスコーダ101−iとトランスコー
ダ101−(i+1)は、それぞれ図15に示すように
構成されている。従って、その処理は、図15を参照し
て説明した場合と同様となる。
The transcoder 101-i and the transcoder 101- (i + 1) are each configured as shown in FIG. Therefore, the processing is the same as that described with reference to FIG.

【0206】実際の符号化パラメータの履歴を利用した
符号化として、現在Iピクチャとして符号化されていた
ものを、PもしくはBピクチャに変更したい場合、過去
の符号化パラメータの履歴を見て、過去にPもしくはB
ピクチャであった場合を探し、これらの履歴が存在した
場合は、その動きベクトルなどのパラメータを利用し
て、ピクチャタイプを変更する。反対に過去に履歴がな
い場合は、動き検出を行わないピクチャタイプの変更を
断念する。もちろん履歴がない場合であっても、動き検
出を行えばピクチャタイプを変更できる。
When it is desired to change the encoding currently performed as an I picture to a P or B picture as the encoding using the actual encoding parameter history, the past encoding parameter history is checked. P or B
A search is made for a picture, and if these histories exist, the picture type is changed using parameters such as the motion vector. Conversely, if there is no history in the past, the change of the picture type for which no motion detection is performed is abandoned. Of course, even if there is no history, the picture type can be changed by performing motion detection.

【0207】図18に示すフォーマットの場合、4世代
分の符号化パラメータを埋め込むようにしたが、I、
P、Bの各ピクチャタイプのパラメータを埋め込むよう
にすることもできる。図31は、この場合のフォーマッ
トの例を示している。この例では、同一のマクロブロッ
クが、過去にピクチャタイプの変更を伴って符号化され
たときにおける、ピクチャタイプ毎に1世代分の符号化
パラメータ(ピクチャ履歴情報)が記録される。したが
って、図16に示したデコーダ111、および図19に
示したエンコーダ121は、現在(最新)、第3世代、
第2世代、および第1世代の符号化パラメータの代わり
に、Iピクチャ、Pピクチャ、およびBピクチャに対応
する1世代分の符号化パラメータを入出力することにな
る。
In the case of the format shown in FIG. 18, encoding parameters for four generations are embedded.
It is also possible to embed parameters of each picture type of P and B. FIG. 31 shows an example of the format in this case. In this example, one generation of encoding parameters (picture history information) are recorded for each picture type when the same macroblock was previously encoded with a change in picture type. Therefore, the decoder 111 shown in FIG. 16 and the encoder 121 shown in FIG.
Instead of the second-generation and first-generation coding parameters, one-generation coding parameters corresponding to I-pictures, P-pictures, and B-pictures are input and output.

【0208】また、この例の場合、Cb[1][x]とCr[1][x]
の空き領域は利用しないので、Cb[1][x]とCr[1][x]の領
域を有さない4:2:0フォーマットの画像データにも
本発明を適用することができる。
In the case of this example, Cb [1] [x] and Cr [1] [x]
The present invention can be applied to image data of 4: 2: 0 format which does not have the areas of Cb [1] [x] and Cr [1] [x].

【0209】この例の場合、復号装置102は、符号化
パラメータを復号と同時に取り出し、ピクチャタイプを
判定して、画像信号のピクチャタイプに対応した場所に
符号化パラメータを書き込んで(多重化して)ヒストリ
情報分離装置105に出力する。ヒストリ情報分離装置
105は、符号化パラメータを分離し、これから符号化
したいピクチャタイプと、入力された過去の符号化パラ
メータを考慮して、ピクチャタイプを変更しながら再符
号化を行うことができる。
In the case of this example, the decoding device 102 takes out the coding parameters at the same time as decoding, determines the picture type, writes the coding parameters in a location corresponding to the picture type of the image signal (multiplexes). Output to the history information separation device 105. The history information separation device 105 can separate the coding parameters and perform re-encoding while changing the picture type in consideration of a picture type to be coded and a past coding parameter input.

【0210】次に、各トランスコーダ101において、
変更が可能なピクチャタイプを判定する処理について、
図32のフローチャートを参照して説明する。なお、ト
ランスコーダ101におけるピクチャタイプの変更は、
過去の動きベクトルを利用するので、この処理は動き検
出を行わないで実行されることを前提としている。ま
た、以下に説明する処理は、ヒストリ情報分離装置10
5により実行される。
Next, in each transcoder 101,
Regarding the process of determining a picture type that can be changed,
This will be described with reference to the flowchart in FIG. The change of the picture type in the transcoder 101 is as follows.
Since a past motion vector is used, this process is assumed to be executed without performing motion detection. The processing described below is performed by the history information separating apparatus 10.
5 is performed.

【0211】ステップS1において、ピクチャタイプ毎
に1世代分の符号化パラメータ(ピクチャ履歴情報)が
ヒストリ情報分離装置105に入力される。
In step S 1, one generation of coding parameters (picture history information) for each picture type is input to the history information separating device 105.

【0212】ステップS2において、ヒストリ情報分離
装置105は、ピクチャ履歴情報の中に、Bピクチャに
変更したときの符号化パラメータが存在するか否かを判
定する。ピクチャ履歴情報にBピクチャに変更したとき
の符号化パラメータが存在すると判定された場合、ステ
ップS3に進む。
[0212] In step S2, the history information separating apparatus 105 determines whether or not the picture history information includes an encoding parameter when the picture is changed to a B picture. If it is determined in the picture history information that there is an encoding parameter when the picture is changed to the B picture, the process proceeds to step S3.

【0213】ステップS3において、ヒストリ情報分離
装置105は、ピクチャ履歴情報の中に、Pピクチャに
変更したときの符号化パラメータが存在するか否かを判
定する。ピクチャ履歴情報にPピクチャに変更したとき
の符号化パラメータが存在すると判定された場合、ステ
ップS4に進む。
[0213] In step S3, the history information separating apparatus 105 determines whether or not the picture history information includes an encoding parameter when changed to a P picture. If it is determined that the picture history information includes the encoding parameter used when the picture is changed to the P picture, the process proceeds to step S4.

【0214】ステップS4において、ヒストリ情報分離
装置105は、変更可能なピクチャタイプがIピクチ
ャ、Pピクチャ、およびBピクチャであると判断する。
In step S4, history information separating apparatus 105 determines that the changeable picture types are I picture, P picture, and B picture.

【0215】ステップS3において、ピクチャ履歴情報
にPピクチャに変更したときの符号化パラメータが存在
しないと判定された場合、ステップS5に進む。
[0215] If it is determined in step S3 that the picture history information does not include the encoding parameter used when the picture is changed to the P picture, the flow advances to step S5.

【0216】ステップS5において、ヒストリ情報分離
装置105は、変更可能なピクチャタイプがIピクチ
ャ、およびBピクチャであると判断する。さらに、ヒス
トリ情報分離装置105は、特殊処理(Bピクチャの履
歴情報に含まれる後方予測ベクトルを使わず、前方予測
ベクトルだけを使う)を施すことにより、擬似的にPピ
クチャに変更可能であると判断する。
In step S5, the history information separating device 105 determines that the changeable picture types are an I picture and a B picture. Furthermore, the history information separation device 105 can pseudo-change to a P picture by performing special processing (using only forward prediction vectors without using backward prediction vectors included in B picture history information). to decide.

【0217】ステップS2において、ピクチャ履歴情報
にBピクチャに変更したときの符号化パラメータが存在
しないと判定された場合、ステップS6に進む。
In step S2, when it is determined that the picture history information does not include the encoding parameter when the picture is changed to the B picture, the process proceeds to step S6.

【0218】ステップS6において、ヒストリ情報分離
装置105は、ピクチャ履歴情報にPピクチャに変更し
たときの符号化パラメータが存在するか否かを判定す
る。ピクチャ履歴情報にPピクチャに変更したときの符
号化パラメータが存在すると判定された場合、ステップ
S7に進む。
In step S6, the history information separating apparatus 105 determines whether or not the picture history information includes an encoding parameter when the picture is changed to the P picture. If it is determined in the picture history information that there is an encoding parameter for changing to the P picture, the process proceeds to step S7.

【0219】ステップS7において、ヒストリ情報分離
装置105は、変更可能なピクチャタイプがIピクチ
ャ、およびPピクチャであると判断する。さらに、ヒス
トリ情報分離装置105は、特殊処理(Pピクチャに履
歴情報に含まれる前方予測ベクトルだけを使う)を施す
ことにより、Bピクチャに変更可能であると判断する。
[0219] In step S7, the history information separating apparatus 105 determines that the changeable picture types are the I picture and the P picture. Further, the history information separating apparatus 105 determines that the picture can be changed to a B picture by performing a special process (using only the forward prediction vector included in the history information for the P picture).

【0220】ステップS6において、ピクチャ履歴情報
にPピクチャに変更したときの符号化パラメータが存在
しないと判定された場合、ステップS8に進む。ステッ
プS8において、ヒストリ情報分離装置105は、動き
ベクトルが存在しないので、変更可能なピクチャタイプ
がIピクチャだけである(IピクチャなのでIピクチャ
以外には変更できない)と判断する。
[0220] If it is determined in step S6 that the picture history information does not include the encoding parameter used when the picture is changed to the P picture, the flow advances to step S8. In step S8, the history information separating apparatus 105 determines that the changeable picture type is only the I picture since there is no motion vector.

【0221】ステップS4,S5,S7,S8の処理の
次にステップS9において、ヒストリ情報分離装置10
5は、変更可能なピクチャタイプを表示装置(図示せ
ず)に表示してユーザに通知する。
After the processing in steps S4, S5, S7, and S8, in step S9, the history information separating apparatus 10
5 displays a changeable picture type on a display device (not shown) to notify the user.

【0222】図33は、ピクチャタイプ変更の例を示し
ている。ピクチャタイプを変更する場合、GOPを構成す
るフレーム数が変更される。すなわち、この例の場合、
N=15(GOPのフレーム数N=15)、M=3(GOP内のI、また
はPピクチャの出現周期M=3)のフレームから構成される
4MbpsのLong GOP(第1世代)から、N=1,M=1のフレー
ムで構成される50MbpsのShort GOP(第2世代)に変
換され、再度、N=15,M=3のフレームから構成される4M
bpsのLong GOP(第3世代)に変換されている。なお、
図中において破線は、GOPの境界を示している。
FIG. 33 shows an example of changing the picture type. When changing the picture type, the number of frames forming the GOP is changed. That is, in this case,
From a 4 Mbps Long GOP (first generation) composed of N = 15 (the number of frames in a GOP N = 15) and M = 3 (the appearance cycle of an I or P picture in a GOP M = 3), N = 1, M = 1 is converted to a 50 Mbps Short GOP (2nd generation) composed of frames, and again 4M composed of N = 15, M = 3 frames
It is converted to bps Long GOP (3rd generation). In addition,
In the figure, broken lines indicate the boundaries of GOPs.

【0223】第1世代から第2世代にピクチャタイプが
変更される場合において、上述した変更可能ピクチャタ
イプ判定処理の説明から明らかなように、全てのフレー
ムは、ピクチャタイプをIピクチャに変更することが可
能である。このピクチャタイプ変更のとき、動画像(第
0世代)が第1世代に変換されたときに演算された全て
の動きベクトルは、ピクチャ履歴情報に保存された(残
された)状態となる。次に、再度Long GOPに変換される
(第2世代から第3世代にピクチャタイプが変更され
る)場合、第0世代から第1世代に変換されたときのピ
クチャタイプ毎の動きベクトルが保存されているので、
これを再利用することにより、画質劣化を抑えて、再
度、Long GOPに変換することが可能となる。
In the case where the picture type is changed from the first generation to the second generation, as is clear from the description of the changeable picture type determination processing, the picture type of all frames is changed to an I picture. Is possible. At the time of this picture type change, all motion vectors calculated when the moving image (0th generation) is converted to the 1st generation are stored (remaining) in the picture history information. Next, when converted to a Long GOP again (the picture type is changed from the second generation to the third generation), the motion vector for each picture type when converted from the 0th generation to the first generation is stored. So
By reusing this, it is possible to suppress the image quality degradation and convert it to a Long GOP again.

【0224】図34は、ピクチャタイプ変更の他の例を
示している。この例の場合、N=14,M=2である4MbpsのL
ong GOP(第1世代)から、N=2,M=2である18MbpsのS
hortGOP(第2世代)に変換され、さらに、N=1,M=1で
あるフレーム数が1の50MbpsのShort GOP(第3世
代)に変換されて、1Mbpsの、フレーム数Nがランダム
なGOP(第4世代)に変換される。
FIG. 34 shows another example of changing the picture type. In this example, N = 14, M = 2, 4Mbps L
18 Mbps S with N = 2 and M = 2 from ong GOP (1st generation)
The GOP is converted to a short GOP (2nd generation), and further converted to a 50 Mbps Short GOP (3rd generation) with N = 1 and M = 1 and the number of frames is 1; (4th generation).

【0225】この例においても、第0世代から第1世代
に変換されたときのピクチャタイプ毎の動きベクトル
が、第3世代から第4世代への変換のときまで保存され
る。そこで、図34に示すように、複雑にピクチャタイ
プを変更しても、保存されている符号化パラメータを再
利用されることにより、画質劣化を小さく抑えることが
できる。さらに、保存されている符号化パラメータの量
子化スケールを有効に利用すれば画質劣化の少ない符号
化を実現できる。
Also in this example, the motion vector for each picture type when converted from the 0th generation to the 1st generation is stored until the conversion from the 3rd generation to the 4th generation. Therefore, as shown in FIG. 34, even if the picture type is changed in a complicated manner, the stored encoding parameters are reused, so that the image quality deterioration can be suppressed to a small value. Furthermore, if the stored quantization scale of the encoding parameter is effectively used, encoding with less image quality degradation can be realized.

【0226】この量子化スケールの再利用について、図
35を参照して説明する。図35は、所定のフレーム
が、第1世代から第4世代まで常に、Iピクチャに変換
されており、ビットレートだけが、4Mbps,18Mbps、
または50Mbpsに変更されていることを示している。
Reuse of the quantization scale will be described with reference to FIG. FIG. 35 shows that a predetermined frame is always converted to an I picture from the first generation to the fourth generation, and only the bit rate is 4 Mbps, 18 Mbps,
Or, it has been changed to 50 Mbps.

【0227】例えば、第1世代(4Mbps)から第2世代
(18Mbps)への変換の際に、ビットレートの高速化に伴
って、細かい量子化スケールで再符号化しても画質は向
上しない。なぜならば、過去において粗い量子化ステッ
プで量子化されたデータは、復元しないからである。し
たがって、図35に示すように、途中でビットレートが
高速化しても、それに伴って細かい量子化ステップで量
子化することは、情報量が増加するだけであって画質の
向上には繋がらない。したがって、過去のもっとも粗い
(大きい)量子化スケールを維持するように制御すれ
ば、最も無駄が無く、効率的な符号化が可能となる。
For example, from the first generation (4 Mbps) to the second generation
At the time of conversion to (18 Mbps), the image quality does not improve even if re-encoding is performed with a fine quantization scale as the bit rate increases. This is because data that has been quantized in the past in a coarse quantization step is not restored. Therefore, as shown in FIG. 35, even if the bit rate is increased on the way, quantizing with a fine quantization step only increases the amount of information and does not lead to improvement in image quality. Therefore, if the control is performed so as to maintain the past coarsest (larger) quantization scale, the most efficient coding can be performed with the least waste.

【0228】なお、第3世代から第4世代への変更時に
は、ビットレートは、50Mbpsから4Mbpsに低下されて
いるが、この場合にも、過去のもっとも粗い(大きい)
量子化スケールが維持される。
At the time of changing from the third generation to the fourth generation, the bit rate is reduced from 50 Mbps to 4 Mbps.
The quantization scale is maintained.

【0229】上述したように、ビットレートが変更され
るときは、過去の量子化スケールの履歴を利用して符号
化することは非常に有効である。
As described above, when the bit rate is changed, it is very effective to perform encoding using the history of the past quantization scale.

【0230】この量子化制御処理について、図36のフ
ローチャートを参照して説明する。ステップS11にお
いて、ヒストリ情報分離装置105は、入力されたピク
チャ履歴情報に、いまから変換するピクチャタイプの符
号化パラメータが存在するか否かを判定する。変換する
ピクチャタイプの符号化パラメータが存在すると判定さ
れた場合、ステップS12に進む。
This quantization control processing will be described with reference to the flowchart in FIG. In step S11, the history information separation device 105 determines whether or not the input picture history information includes an encoding parameter of a picture type to be converted. If it is determined that there is a coding parameter of the picture type to be converted, the process proceeds to step S12.

【0231】ステップS12において、ヒストリ情報分
離装置105は、ピクチャ履歴情報の対象となる符号化
パラメータから、history_q_scale_codeを抽出する。
[0231] In step S12, the history information separation device 105 extracts history_q_scale_code from the coding parameter to be the target of the picture history information.

【0232】ステップS13において、ヒストリ情報分
離装置105は、送信バッファ59から量子化回路57
にフィードバックされるバッファ残量に基づいて、feed
back_q_scale_codeを演算する。
In step S13, the history information separation device 105 sends the quantization information from the transmission buffer 59 to the quantization circuit 57.
Feed based on the remaining buffer
Calculate back_q_scale_code.

【0233】ステップS14において、ヒストリ情報分
離装置105は、history_q_scale_codeがfeedback_q_s
cale_codeよりも大きい(粗い)か否かを判定する。his
tory_q_scale_codeがfeedback_q_scale_codeよりも大き
いと判定された場合、ステップS15に進む。
[0233] In step S14, the history information separating apparatus 105 sets the history_q_scale_code to feedback_q_s
It is determined whether it is larger (coarse) than cale_code. his
When it is determined that tory_q_scale_code is larger than feedback_q_scale_code, the process proceeds to step S15.

【0234】ステップS15において、ヒストリ情報分
離装置105は、量子化スケールとしてhistory_q_scal
e_code を量子化回路57に出力する。量子化回路57
は、history_q_scale_code を用いて量子化を実行す
る。
[0234] In step S15, the history information separating apparatus 105 sets history_q_scal as the quantization scale.
e_code is output to the quantization circuit 57. Quantization circuit 57
Performs quantization using history_q_scale_code.

【0235】ステップS16において、フレームに含ま
れる全てのマクロブロックが量子化されたか否かが判定
される。全てのマクロブロックがまだ量子化されていな
いと判定された場合、ステップS12に戻り、ステップ
S12乃至S16の処理が、全てのマクロブロックが量
子化されるまで繰り返される。
In step S16, it is determined whether or not all the macro blocks included in the frame have been quantized. If it is determined that all the macroblocks have not been quantized yet, the process returns to step S12, and the processes of steps S12 to S16 are repeated until all the macroblocks are quantized.

【0236】ステップS14において、history_q_scal
e_codeがfeedback_q_scale_codeよりも大きくない(細
かい)いと判定された場合、ステップS17に進む。
At step S14, history_q_scal
If it is determined that e_code is not larger (fine) than feedback_q_scale_code, the process proceeds to step S17.

【0237】ステップS17において、ヒストリ情報分
離装置105は、量子化スケールとしてfeedback_q_sca
le_codeを量子化回路57に出力する。量子化回路57
は、feedback_q_scale_codeを用いて量子化を実行す
る。
[0237] In step S17, the history information separating device 105 sets feedback_q_sca as the quantization scale.
The le_code is output to the quantization circuit 57. Quantization circuit 57
Performs quantization using feedback_q_scale_code.

【0238】ステップS11において、変換するピクチ
ャタイプの符号化パラメータが、ヒストリ情報中に存在
しないと判定された場合、ステップS18に進む。
If it is determined in step S11 that the encoding parameter of the picture type to be converted does not exist in the history information, the process proceeds to step S18.

【0239】ステップS18において、ヒストリ情報分
離装置105は、送信バッファ59から量子化回路57
にフィードバックされるバッファ残量に基づいて、feed
back_q_scale_codeを演算する。
[0239] In step S18, the history information separation device 105 sends the
Feed based on the remaining buffer
Calculate back_q_scale_code.

【0240】ステップS19において、量子化回路57
は、Feedback_q_scale_codeを用いて量子化を実行す
る。
In step S19, the quantization circuit 57
Performs quantization using Feedback_q_scale_code.

【0241】ステップS20において、フレームに含ま
れる全てのマクロブロックが量子化されたか否かが判定
される。全てのマクロブロックがまだ量子化されていな
いと判定された場合、ステップS18に戻り、ステップ
S18乃至S20の処理が、全てのマクロブロックが量
子化されるまで繰り返される。
In step S20, it is determined whether or not all the macro blocks included in the frame have been quantized. When it is determined that all the macroblocks have not been quantized, the process returns to step S18, and the processes of steps S18 to S20 are repeated until all the macroblocks are quantized.

【0242】なお、本実施の形態におけるトランスコー
ダ101の内部においては、上述したように、復号側と
符号側が粗結合されており、符号化パラメータを画像デ
ータに多重化させて伝送させたが、図37に示すよう
に、復号装置102と符号化装置106を直接接続する
(密結合する)ようにしてもよい。
Note that, as described above, the decoding side and the code side are roughly coupled inside the transcoder 101 in the present embodiment, and the coding parameters are multiplexed with the image data and transmitted. As shown in FIG. 37, the decoding device 102 and the encoding device 106 may be directly connected (closely coupled).

【0243】図15において説明したトランスコーダ1
01は、第1世代から第3世代の過去の符号化パラメー
タを符号化装置106に供給するために、ベースバンド
ビデオデータに過去の符号化パラメータを多重化して伝
送するようにしていた。しかしながら、本発明において
は、ベースバンドビデオデータに過去の符号化パラメー
タを多重化する技術は必須ではなく、図37に示された
ように、ベースバンドビデオデータとは異なる伝送路
(たとえばデータ転送バス)を使用して、過去の符号化
パラメータを伝送するようにしても良い。
Transcoder 1 described with reference to FIG.
No. 01 multiplexes the past encoding parameters to the baseband video data and transmits the same to supply the encoding apparatus 106 with the first to third generation past encoding parameters. However, in the present invention, the technique of multiplexing the past coding parameters to the baseband video data is not essential, and as shown in FIG. 37, a transmission path different from the baseband video data (for example, a data transfer bus). ) May be used to transmit the past coding parameters.

【0244】つまり、図37に示した、復号装置10
2、ヒストリデコーディング装置104、符号化装置1
06及びヒストリエンコーディング装置107は、図1
5において説明した復号装置102、ヒストリデコーデ
ィング装置104、符号化装置106及びヒストリエン
コーディング装置107とまったく同じ機能及び構成を
有している。
That is, the decoding apparatus 10 shown in FIG.
2. History decoding device 104, coding device 1
06 and the history encoding device 107 are shown in FIG.
5 has exactly the same functions and configurations as the decoding device 102, the history decoding device 104, the encoding device 106, and the history encoding device 107 described in FIG.

【0245】復号装置102の可変長復号回路112
は、第3世代の符号化ストリームST(3rd)のシーケン
ス層、GOP層、ピクチャ層、スライス層及びマクロブロ
ック層から、第3世代の符号化パラメータを抽出し、そ
れを、ヒストリエンコーディング装置107及び符号化
装置106のコントローラ70にそれぞれ供給する。ヒ
ストリエンコーディング装置107は、受け取った第3
世代の符号化パラメータをピクチャ層のユーザデータエ
リアに記述できるようにconverted_history_stream()に
変換し、converted_history_stream()をユーザデータと
して符号化装置106の可変長符号化回路58に供給す
る。
Variable Length Decoding Circuit 112 of Decoding Device 102
Extracts the third-generation coding parameters from the sequence layer, GOP layer, picture layer, slice layer, and macroblock layer of the third-generation encoded stream ST (3rd), and extracts them from the history encoding device 107 and It is supplied to the controller 70 of the encoding device 106, respectively. The history encoding device 107 receives the third
The coding parameter of the generation is converted into converted_history_stream () so that it can be described in the user data area of the picture layer, and the converted_history_stream () is supplied to the variable length coding circuit 58 of the coding device 106 as user data.

【0246】さらに可変長復号回路112は、第3世代
の符号化ストリームのピクチャ層のユーザデータエリア
から、第1世代の符号化パラメータ及び第2の符号化パ
ラメータを含んでいるユーザデータuser_data を抽出
し、ヒストリデコーディング装置104及び符号化装置
106の可変長符号化回路58に供給する。ヒストリデ
コーディング装置104は、ユーザデータエリアにconv
erted_history_stream()として記述されたヒストリスト
リームから、第1世代の符号化パラメータ及び第2世代
の符号化パラメータを抽出し、それを符号化装置106
のコントローラに供給する。
Further, the variable length decoding circuit 112 extracts user data user_data including the first generation coding parameter and the second coding parameter from the user data area of the picture layer of the third generation coded stream. Then, the data is supplied to the history decoding device 104 and the variable length coding circuit 58 of the coding device 106. The history decoding device 104 stores conv in the user data area.
First-generation coding parameters and second-generation coding parameters are extracted from the history stream described as erted_history_stream (), and are extracted by the coding apparatus 106.
To the controller.

【0247】符号化装置106のコントローラ70は、
ヒストリデコーディング装置104から受け取った第1
世代及び第2世代の符号化パラメータと、符号化装置1
02から受け取った第3世代の符号化パラメータとに基
づいて、符号化装置106の符号化処理をコントロール
する。
The controller 70 of the encoding device 106
The first received from the history decoding device 104
Generation and second generation coding parameters and the coding device 1
Based on the third-generation encoding parameters received from the H.02, the encoding processing of the encoding device 106 is controlled.

【0248】符号化装置106の可変長符号化回路58
は、復号装置102から第1世代の符号化パラメータ及
び第2の符号化パラメータを含んでいるユーザデータus
er_dataを受け取るとともに、ヒストリエンコーディン
グ装置107から第3世代の符号化パラメータを含んで
いるユーザデータuser_dataを受け取り、それらのユー
ザデータをヒストリ情報として、第4世代の符号化スト
リームのピクチャ層のユーザデータエリアに記述する。
Variable length coding circuit 58 of coding apparatus 106
Is the user data us containing the first-generation encoding parameter and the second encoding parameter from the decoding device 102.
er_data as well as user data user_data including third-generation encoding parameters from the history encoding device 107, and using the user data as history information, a user data area in a picture layer of a fourth-generation encoded stream. Describe in.

【0249】図38は、MPEGのビデオストリームをデコ
ードするためのシンタックスを表わした図である。デコ
ーダは、このシンタックスに従ってMPEGビットストリー
ムをデコードすることによって、ビットストリームから
意味のある複数のデータ項目(データエレメント)を抽
出する。以下に説明するシンタックスは、図において、
その関数や条件文は細活字で表わされ、そのデータエレ
メントは、太活字で表されている。データ項目は、その
名称、ビット長、及びそのタイプと伝送順序を示すニー
モニック(Mnemonic)で記述されている。
FIG. 38 is a diagram showing the syntax for decoding an MPEG video stream. The decoder extracts a plurality of meaningful data items (data elements) from the bit stream by decoding the MPEG bit stream according to this syntax. The syntax described below is
The functions and conditional statements are shown in fine print, and the data elements are shown in bold print. Each data item is described by a mnemonic (Mnemonic) indicating its name, bit length, and its type and transmission order.

【0250】まず、この図38に示されているシンタッ
クスにおいて使用されている関数について説明する。
First, the function used in the syntax shown in FIG. 38 will be described.

【0251】next_start_code()関数は、ビットストリ
ーム中に記述されているスタートコードを探すための関
数である。この図38に示されたシンタックスにおい
て、このnext_start_code()関数の次に、sequence_head
er()関数とsequence_extension()関数とが順に配置され
ているので、このビットストリームには、このsequence
_header()関数とsequence_extension()関数によって定
義されたデータエレメントが記述されている。従って、
ビットストリームのデコード時には、このnext_start_c
ode()関数によって、sequence_header()関数とsequence
_extension()関数の先頭に記述されているスタートコー
ド(データエレメントの一種)をビットストリーム中か
ら見つけ、それを基準にして、 sequence_header()関数
とsequence_extension()関数をさらに見つけ、それらに
よって定義された各データエレメントをデコードする。
The next_start_code () function is a function for searching for a start code described in a bit stream. In the syntax shown in FIG. 38, next to this next_start_code () function, sequence_head
Since the er () function and the sequence_extension () function are arranged in order, this bit stream includes the sequence
A data element defined by the _header () function and the sequence_extension () function is described. Therefore,
When decoding the bit stream, this next_start_c
sequence_header () function and sequence
The start code (a kind of data element) described at the beginning of the _extension () function is found in the bit stream, and based on that, the sequence_header () function and the sequence_extension () function are further found and defined by them. Decode each data element.

【0252】尚、sequence_header()関数は、MPEGビッ
トストリームのシーケンス層のヘッダデータを定義する
ための関数であって、sequence_extension()関数は、MP
EGビットストリームのシーケンス層の拡張データを定義
するための関数である。
The sequence_header () function is a function for defining the header data of the sequence layer of the MPEG bit stream, and the sequence_extension () function is
This is a function for defining extension data of the sequence layer of the EG bitstream.

【0253】sequence_extension()関数の次に配置され
ている do{ }while構文は、while文によって定義されて
いる条件が真である間、do文の{ }内の関数に基いて記
述されたデータエレメントをデータストリーム中から抽
出するための構文である。すなわち、 do{ }while構文
によって、while文によって定義されている条件が真で
ある間、ビットストリーム中から、do文内の関数に基い
て記述されたデータエレメントを抽出するデコード処理
が行われる。
The do {} while syntax located next to the sequence_extension () function is a data described based on the function in {} of the do statement while the condition defined by the while statement is true. This is a syntax for extracting an element from a data stream. That is, while the condition defined by the while statement is true, the decoding process of extracting the data element described based on the function in the do statement from the bit stream is performed by the do {} while syntax.

【0254】このwhile文に使用されているnextbits()
関数は、ビットストリーム中に現れるビット又はビット
列と、次にデコードされるデータエレメントとを比較す
るための関数である。この図38のシンタックスの例で
は、nextbits()関数は、ビットストリーム中のビット列
とビデオシーケンスの終わりを示すsequence_end_code
とを比較し、ビットストリーム中のビット列とsequence
_end_codeとが一致しないときに、このwhile文の条件が
真となる。従って、sequence_extension()関数の次に配
置されている do{ }while構文は、ビットストリーム中
に、ビデオシーケンスの終わりを示すsequence_end_cod
eが現れない間、do文中の関数によって定義されたデー
タエレメントがビットストリーム中に記述されているこ
とを示している。
Nextbits () used in this while statement
The function is a function for comparing a bit or a bit string appearing in a bit stream with a data element to be decoded next. In the example of the syntax shown in FIG. 38, the nextbits () function includes a bit string in the bit stream and a sequence_end_code indicating the end of the video sequence.
Is compared with the bit sequence in the bit stream and sequence
When the _end_code does not match, the condition of this while statement is true. Therefore, the do {} while syntax located next to the sequence_extension () function uses sequence_end_cod indicating the end of the video sequence in the bit stream.
While e does not appear, it indicates that the data element defined by the function in the do statement is described in the bit stream.

【0255】ビットストリーム中には、sequence_exten
sion()関数によって定義された各データエレメントの次
には、extension_and_user_data(0)関数によって定義さ
れたデータエレメントが記述されている。このextensio
n_and_user_data(0)関数は、MPEGビットストリームのシ
ーケンス層の拡張データとユーザデータを定義するため
の関数である。
[0255] In the bit stream, sequence_exten
Following each data element defined by the sion () function, a data element defined by the extension_and_user_data (0) function is described. This extensio
The n_and_user_data (0) function is a function for defining extended data of the sequence layer of the MPEG bit stream and user data.

【0256】このextension_and_user_data(0)関数の次
に配置されている do{ }while構文は、while文によって
定義されている条件が真である間、do文の{ }内の関数
に基いて記述されたデータエレメントを、ビットストリ
ーム中から抽出するための関数である。このwhile文に
おいて使用されているnextbits()関数は、ビットストリ
ーム中に現れるビット又はビット列と、picture_start_
code又はgroup_start_codeとの一致を判断するための関
数であって、ビットストリーム中に現れるビット又はビ
ット列と、picture_start_code又はgroup_start_codeと
が一致する場合には、while文によって定義された条件
が真となる。よって、このdo{ }while構文は、ビットス
トリーム中において、picture_start_code又はgroup_st
art_codeが現れた場合には、そのスタートコードの次
に、do文中の関数によって定義されたデータエレメント
のコードが記述されているので、このpicture_start_co
de又はgroup_start_codeによって示されるスタートコー
ドを探し出すことによって、ビットストリーム中からdo
文中に定義されたデータエレメントを抽出することがで
きる。
The do {} while syntax placed next to the extension_and_user_data (0) function is described based on the function in the {} of the do statement while the condition defined by the while statement is true. This is a function for extracting the data element from the bit stream. The nextbits () function used in this while statement is used to determine the bits or bit strings appearing in the bit stream and the picture_start_
A function for determining a match with code or group_start_code. If a bit or a bit string appearing in a bit stream matches picture_start_code or group_start_code, the condition defined by the while statement is true. Therefore, this do {} while syntax is used in the bit stream for picture_start_code or group_st
If art_code appears, the code of the data element defined by the function in the do statement is described after the start code, so this picture_start_co
By finding the start code indicated by de or group_start_code, do
Data elements defined in the sentence can be extracted.

【0257】このdo文の最初に記述されているif文は、
ビットストリーム中にgroup_start_codeが現れた場合、
という条件を示しいる。このif文による条件が真である
場合には、ビットストリーム中には、このgroup_start_
codeの次にgroup_of_picture_header(1)関数及びextens
ion_and_user_data(1)関数によって定義されているデー
タエレメントが順に記述されている。
The if statement described at the beginning of the do statement is
If group_start_code appears in the bitstream,
The condition is shown. If the condition by this if statement is true, the group_start_
After code, group_of_picture_header (1) function and extens
Data elements defined by the ion_and_user_data (1) function are described in order.

【0258】このgroup_of_picture_header(1)関数は、
MPEGビットストリームのGOP層のヘッダデータを定義す
るための関数であって、 extension_and_user_data(1)
関数は、MPEGビットストリームのGOP層の拡張データ(e
xtension_data)及びユーザデータ(user_data)を定義
するための関数である。
The group_of_picture_header (1) function is
Extension_and_user_data (1) is a function for defining the header data of the GOP layer of the MPEG bit stream.
The function is the GOP layer extension data (e
xtension_data) and user data (user_data).

【0259】さらに、このビットストリーム中には、gr
oup_of_picture_header(1)関数及びextension_and_user
_data(1)関数によって定義されているデータエレメント
の次に、picture_header()関数とpicture_coding_exten
sion()関数によって定義されたデータエレメントが記述
されている。もちろん、先に説明したif文の条件が真と
ならない場合には、 group_of_picture_header(1)関数
及びextension_and_user_data(1)関数によって定義され
ているデータエレメントは記述されていないので、 ext
ension_and_user_data(0)関数によって定義されている
データエレメントの次に、 picture_header()関数とpic
ture_coding_extension()関数によって定義されたデー
タエレメントが記述されている。
Further, in this bit stream, gr
oup_of_picture_header (1) function and extension_and_user
After the data element defined by the _data (1) function, the picture_header () function and picture_coding_exten
Describes the data element defined by the sion () function. Of course, if the condition of the if statement described above is not true, the data element defined by the group_of_picture_header (1) function and the extension_and_user_data (1) function is not described.
After the data element defined by the extension_and_user_data (0) function, the picture_header () function and pic
A data element defined by the ture_coding_extension () function is described.

【0260】このpicture_header()関数は、 MPEGビッ
トストリームのピクチャ層のヘッダデータを定義するた
めの関数であって、 picture_coding_extension()関数
は、MPEGビットストリームのピクチャ層の第1の拡張デ
ータを定義するための関数である。
[0260] The picture_header () function is for defining the header data of the picture layer of the MPEG bit stream, and the picture_coding_extension () function is for defining the first extension data of the picture layer of the MPEG bit stream. Function.

【0261】次のwhile文は、このwhile文によって定義
されている条件が真である間、次のif文の条件判断を行
うための関数である。このwhile文において使用されて
いるnextbits()関数は、ビットストリーム中に現れるビ
ット列と、extension_start_code又はuser_data_start_
codeとの一致を判断するための関数であって、ビットス
トリーム中に現れるビット列と、 extension_start_cod
e又はuser_data_start_codeとが一致する場合には、こ
のwhile文によって定義された条件が真となる。
The next while statement is a function for determining the condition of the next if statement while the condition defined by the while statement is true. The nextbits () function used in this while statement includes a bit string appearing in the bit stream and extension_start_code or user_data_start_
A function to determine the match with code, a bit string appearing in the bit stream, and extension_start_cod
If e or user_data_start_code matches, the condition defined by this while statement is true.

【0262】第1のif文は、ビットストリーム中に現れ
るビット列とextension_start_codeとの一致を判断する
ための関数である。ビットストリーム中に現れるビット
列と32ビットのextension_ start_codeとが一致する
場合には、ビットストリーム中において、extension_st
art_codeの次にextension_data(2)関数によって定義さ
れるデータエレメントが記述されている。
The first if sentence is a function for judging whether a bit string appearing in the bit stream matches extension_start_code. If the bit string appearing in the bit stream matches the 32-bit extension_start_code, the extension_st
Following the art_code, a data element defined by the extension_data (2) function is described.

【0263】第2のif文は、ビットストリーム中に現れ
るビット列とuser_data_start_codeとの一致を判断する
ための構文であって、ビットストリーム中に現れるビッ
ト列と32ビットのuser_data_start_codeとが一致する
場合には、第3のif文の条件判断が行われる。このuser
_data_start_codeは、MPEGビットストリームのピクチャ
層のユーザデータエリアの開始を示すためのスタートコ
ードである。
The second if sentence is a syntax for judging a match between a bit string appearing in the bit stream and user_data_start_code. When the bit string appearing in the bit stream matches a 32-bit user_data_start_code, The condition determination of the third if statement is performed. This user
_data_start_code is a start code indicating the start of the user data area in the picture layer of the MPEG bit stream.

【0264】第3のif文は、ビットストリーム中に現れ
るビット列とHistory_Data_IDとの一致を判断するため
の構文である。ビットストリーム中に現れるビット列と
この32ビットのHistory_Data_IDとが一致する場合に
は、このMPEGビットストリームのピクチャ層のユーザデ
ータエリアにおいて、この32ビットのHistory_Data_I
Dによって示されるコードの次に、converted_history_s
tream()関数によって定義されるデータエレメントが記
述されている。
[0264] The third if sentence is a syntax for judging whether a bit string appearing in the bit stream matches History_Data_ID. When the bit string appearing in the bit stream matches the 32-bit History_Data_ID, the 32-bit History_Data_I is stored in the user data area of the picture layer of the MPEG bit stream.
Following the code indicated by D, converted_history_s
A data element defined by the tream () function is described.

【0265】converted_history_stream()関数は、MPEG
符号化時に使用したあらゆる符号化パラメータを伝送す
るための履歴情報及び履歴データを記述するための関数
である。このconverted_history_stream()関数によって
定義されているデータエレメントの詳細は、図40乃至
図47を参照して、history_stream()として後述する。
また、このHistory_Data_IDは、MPEGビットストリーム
のピクチャ層のユーザデータエリアに記述されたこの履
歴情報及び履歴データが記述されている先頭を示すため
のスタートコードである。
The converted_history_stream () function is
It is a function for describing history information and history data for transmitting all encoding parameters used at the time of encoding. Details of the data element defined by the converted_history_stream () function will be described later as history_stream () with reference to FIGS.
The History_Data_ID is a start code indicating the head of the history information and the history data described in the user data area of the picture layer of the MPEG bit stream.

【0266】else文は、第3のif文において、条件が非
真であることを示すための構文である。従って、このMP
EGビットストリームのピクチャ層のユーザデータエリア
において、converted_history_stream()関数によって定
義されたデータエレメントが記述されていない場合に
は、user_data()関数によって定義されたデータエレメ
ントが記述されている。
The else statement is a syntax for indicating that the condition is non-true in the third if statement. So this MP
If the data element defined by the converted_history_stream () function is not described in the user data area of the picture layer of the EG bit stream, the data element defined by the user_data () function is described.

【0267】図38において、履歴情報は、converted_
history_stream()に記述され、user_data()に記述され
る訳ではないが、このconverted_history_stream()は、
MPEG規格のuser_dataの一種として記述される。そこ
で、本明細書中においては、場合によって、履歴情報が
user_dataに記述されるとも説明するが、それは、MPEG
規格のuser_dataの一種として記述されるということを
意味する。
In FIG. 38, the history information is converted_converted_
Although described in history_stream () and not in user_data (), this converted_history_stream () is
It is described as a kind of user_data of the MPEG standard. Therefore, in this specification, the history information may
It is explained that it is described in user_data, but it is MPEG
It means that it is described as a kind of standard user_data.

【0268】picture_data()関数は、MPEGビットストリ
ームのピクチャ層のユーザデータの次に、スライス層及
びマクロブロック層に関するデータエレメントを記述す
るための関数である。通常は、このpicture_data()関数
によって示されるデータエレメントは、ビットストリー
ムのピクチャ層のユーザデータエリアに記述されたconv
erted_history_stream()関数によって定義されるデータ
エレメント又はuser_data()関数によって定義されたデ
ータエレメントの次に記述されているが、ピクチャ層の
データエレメントを示すビットストリーム中に、extens
ion_start_code又はuser_data_start_code が存在しな
い場合には、このpicture_data()関数によって示される
データエレメントは、 picture_coding_extension()関
数によって定義されるデータエレメントの次に記述され
ている。
[0268] The picture_data () function is a function for describing data elements related to the slice layer and the macroblock layer after the user data of the picture layer of the MPEG bit stream. Normally, the data element indicated by the picture_data () function is the conv. Described in the user data area of the picture layer of the bit stream.
Although described next to the data element defined by the erted_history_stream () function or the data element defined by the user_data () function, the extens
If there is no ion_start_code or user_data_start_code, the data element indicated by the picture_data () function is described next to the data element defined by the picture_coding_extension () function.

【0269】このpicture_data()関数によって示される
データエレメントの次には、sequence_header()関数とs
equence_extension()関数とによって定義されたデータ
エレメントが順に配置されている。このsequence_heade
r()関数とsequence_extension()関数によって記述され
たデータエレメントは、ビデオストリームのシーケンス
の先頭に記述されたsequence_header()関数とsequence_
extension()関数によって記述されたデータエレメント
と全く同じである。このように同じデータをストリーム
中に記述する理由は、ビットストリーム受信装置側でデ
ータストリームの途中(例えばピクチャ層に対応するビ
ットストリーム部分)から受信が開始された場合に、シ
ーケンス層のデータを受信できなくなり、ストリームを
デコード出来なくなることを防止するためである。
The data element indicated by the picture_data () function is followed by the sequence_header () function and s
Data elements defined by the equence_extension () function are arranged in order. This sequence_heade
The data element described by the r () function and the sequence_extension () function is composed of the sequence_header () function and the sequence_
Exactly the same as the data element described by the extension () function. The reason for describing the same data in the stream in this way is that when the bit stream receiving apparatus starts receiving data in the middle of the data stream (for example, the bit stream portion corresponding to the picture layer), the data in the sequence layer is received. This is to prevent a situation in which the stream cannot be decoded and the stream cannot be decoded.

【0270】この最後のsequence_header()関数とseque
nce_extension()関数とによって定義されたデータエレ
メントの次、つまり、データストリームの最後には、シ
ーケンスの終わりを示す32ビットのsequence_end_cod
eが記述されている。
This last sequence_header () function and sequence
After the data element defined by the nce_extension () function, that is, at the end of the data stream, a 32-bit sequence_end_cod indicating the end of the sequence
e is described.

【0271】以上のシンタックスの基本的な構成の概略
を示すと、図39に示すようになる。
The basic structure of the above syntax is schematically shown in FIG.

【0272】次に、converted_history_stream()関数に
よって定義されたヒストリストリームに関して説明す
る。
Next, a history stream defined by the converted_history_stream () function will be described.

【0273】このconverted_history_stream()は、MPEG
のピクチャ層のユーザデータエリアに履歴情報を示すヒ
ストリストリームを挿入するための関数である。尚、
「converted」の意味は、スタートエミュレーションを
防止するために、ユーザエリアに挿入すべき履歴データ
から構成される履歴ストリームの少なくとも22ビット
毎にマーカービット(1ビット)を挿入する変換処理を
行ったストリームであることを意味している。
This converted_history_stream () is an MPEG
Is a function for inserting a history stream indicating history information into the user data area of the picture layer. still,
“Converted” means a stream that has undergone a conversion process of inserting a marker bit (1 bit) at least every 22 bits of a history stream composed of history data to be inserted into the user area in order to prevent start emulation. It means that

【0274】このconverted_history_stream()は、以下
に説明する固定長の履歴ストリーム(図40乃至図4
6)又は可変長の履歴ストリーム(図47)のいずれか
の形式で記述される。エンコーダ側において固定長の履
歴ストリームを選択した場合には、デコーダ側において
履歴ストリームから各データエレメントをデコードする
ための回路及びソフトウエアが簡単になるというメリッ
トがある。一方、エンコーダ側において可変長の履歴ス
トリームを選択した場合には、エンコーダにおいてピク
チャ層のユーザエリアに記述される履歴情報(データエ
レメント)を必要に応じて任意に選択することができる
ので、履歴ストリームのデータ量を少なくすることがで
き、その結果、符号化されたビットストリーム全体のデ
ータレートを低減することができる。
This converted_history_stream () is a fixed-length history stream described below (FIGS. 40 to 4).
6) or a variable-length history stream (FIG. 47). When a fixed-length history stream is selected on the encoder side, there is an advantage that a circuit and software for decoding each data element from the history stream on the decoder side are simplified. On the other hand, when a variable-length history stream is selected on the encoder side, the history information (data element) described in the user area of the picture layer can be arbitrarily selected as needed by the encoder. Can be reduced, and as a result, the data rate of the entire coded bit stream can be reduced.

【0275】本発明において説明する「履歴ストリー
ム」、「ヒストリストリーム」、「履歴情報」、「ヒス
トリ情報」、「履歴データ」、「ヒストリデータ」、
「履歴パラメータ」、「ヒストリパラメータ」とは、過
去の符号化処理において使用した符号化パラメータ(又
はデータエレメント)を意味し、現在の(最終段の)符
号化処理において使用した符号化パラメータを意味する
ものではない。例えば、第1世代の符号化処理におい
て、あるピクチャをIピクチャで符号化して伝送し、次
なる第2世代の符号化処理において、このピクチャを今
度はPピクチャとして符号化して伝送し、さらに、第3
世代の符号化処理において、このピクチャをBピクチャ
で符号化して伝送する例をあげて説明する。
In the present invention, “history stream”, “history stream”, “history information”, “history information”, “history data”, “history data”,
The “history parameters” and “history parameters” mean the coding parameters (or data elements) used in the past coding process, and mean the coding parameters used in the current (last stage) coding process. It does not do. For example, in a first generation encoding process, a certain picture is encoded and transmitted by an I picture, and in a subsequent second generation encoding process, this picture is encoded and transmitted as a P picture, and further, Third
In the generation encoding process, an example will be described in which this picture is encoded with a B picture and transmitted.

【0276】第3世代の符号化処理において使用した符
号化パラメータが、第3世代の符号化処理において生成
された符号化ビットストリームのシーケンス層、GOP
層、ピクチャ層、スライス層及びマクロブロック層の所
定位置に記述されている。一方、過去の符号化処理であ
る第1世代及び第2世代の符号化処理において使用した
符号化パラメータは、第3世代の符号化処理において使
用した符号化パラメータが記述されるシーケンス層やGO
P層に記述されるのでは無く、既に説明したシンタック
スに従って、符号化パラメータの履歴情報として、ピク
チャ層のユーザデータエリアに記述される。
The encoding parameters used in the third generation encoding process are the sequence layer of the encoded bit stream generated in the third generation encoding process, the GOP
Layer, picture layer, slice layer, and macroblock layer are described at predetermined positions. On the other hand, the encoding parameters used in the first-generation and second-generation encoding processes, which are the past encoding processes, are a sequence layer or GO that describes the encoding parameters used in the third-generation encoding process.
Instead of being described in the P layer, it is described in the user data area of the picture layer as coding parameter history information in accordance with the syntax described above.

【0277】まず、固定長の履歴ストリームシンタック
スについて図40乃至図46を参照して説明する。
First, the fixed-length history stream syntax will be described with reference to FIGS.

【0278】最終段(例えば第3世代)の符号化処理に
おいて生成されたビットストリームのピクチャ層のユー
ザデータエリアには、まず最初に、過去(例えば第1世
代及び第2世代)の符号化処理において使用されていた
シーケンス層のシーケンスヘッダに含められる符号化パ
ラメータが、履歴ストリームとして挿入される。尚、過
去の符号化処理において生成されたビットストリームの
シーケンス層のシーケンスヘッダ等の履歴情報は、最終
段の符号化処理において生成されたビットストリームの
シーケンス層のシーケンスヘッダに挿入されることは無
いという点に注意すべきである。
First, in the user data area of the picture layer of the bit stream generated in the encoding process of the final stage (for example, the third generation), the past (for example, the first generation and the second generation) encoding processes are performed. The coding parameter included in the sequence header of the sequence layer used in is inserted as a history stream. Note that history information such as the sequence header of the sequence layer of the bit stream generated in the past encoding process is not inserted into the sequence header of the sequence layer of the bit stream generated in the last-stage encoding process. It should be noted that.

【0279】過去の符号化処理で使用したシーケンスヘ
ッダ(sequence_header)に含められるデータエレメン
トは、sequence_header_code、sequence_header_presen
t_flag、horizontal_size_value、marker_bit、vertica
l_size_value、aspect_ratio_information、frame_rate
_code、bit_rate_value、VBV_buffer_size_value、cons
trained_parameter_flag、load_intra_quantiser_matri
x、load_non_intra_quantiser_matrix、intra_quantise
r_matrix、及びnon_intra_quantiser_matrix等から構成
される。
The data elements included in the sequence header (sequence_header) used in the past encoding process are sequence_header_code, sequence_header_presen
t_flag, horizontal_size_value, marker_bit, vertica
l_size_value, aspect_ratio_information, frame_rate
_code, bit_rate_value, VBV_buffer_size_value, cons
trained_parameter_flag, load_intra_quantiser_matri
x, load_non_intra_quantiser_matrix, intra_quantise
r_matrix, non_intra_quantiser_matrix, etc.

【0280】sequence_header_codeは、シーケンス層の
スタート同期コードを表すデータである。sequence_hea
der_present_flagは、sequence_header内のデータが有
効か無効かを示すデータである。 horizontal_size_val
ueは、画像の水平方向の画素数の下位12ビットから成る
データである。marker_bitは、スタートコードエミュレ
ーションを防止するために挿入されるビットデータであ
る。vertical_size_valueは、画像の縦のライン数の下
位12ビットからなるデータである。aspect_ratio_infor
mationは、画素のアスペクト比(縦横比)または表示画
面アスペクト比を表すデータである。frame_rate_code
は、画像の表示周期を表すデータである。
[0280] sequence_header_code is data representing a start synchronization code of the sequence layer. sequence_hea
der_present_flag is data indicating whether data in sequence_header is valid or invalid. horizontal_size_val
ue is data consisting of the lower 12 bits of the number of pixels in the horizontal direction of the image. marker_bit is bit data inserted to prevent start code emulation. vertical_size_value is data composed of lower 12 bits of the number of vertical lines of the image. aspect_ratio_infor
“mation” is data representing an aspect ratio (aspect ratio) or a display screen aspect ratio of a pixel. frame_rate_code
Is data representing a display cycle of an image.

【0281】bit_rate_valueは、発生ビット量に対する
制限のためのビット・レートの下位18ビット(400bsp単
位で切り上げる)データである。VBV_buffer_size_value
は、発生符号量制御用の仮想バッファ(ビデオバッファ
ベリファイヤー)の大きさを決める値の下位10ビットデ
ータである。constrained_parameter_flagは、各パラメ
ータが制限以内であることを示すデータである。load_i
ntra_quantiser_matrixは、イントラMB用量子化マトリ
ックス・データの存在を示すデータである。load_non_i
ntra_quantiser_matrixは、非イントラMB用量子化マ
トリックス・データの存在を示すデータである。intra_
quantiser_matrixは、イントラMB用量子化マトリック
スの値を示すデータである。non_intra_quantiser_matr
ixは、非イントラMB用量子化マトリックスの値を表す
データである。
Bit_rate_value is lower 18 bits (rounded up in units of 400 bsp) of the bit rate for limiting the amount of generated bits. VBV_buffer_size_value
Is the lower 10-bit data of the value that determines the size of the virtual buffer (video buffer verifier) for controlling the generated code amount. constrained_parameter_flag is data indicating that each parameter is within the limit. load_i
ntra_quantiser_matrix is data indicating the existence of intra MB quantization matrix data. load_non_i
ntra_quantiser_matrix is data indicating the existence of non-intra MB quantization matrix data. intra_
quantiser_matrix is data indicating the value of the intra MB quantization matrix. non_intra_quantiser_matr
ix is data representing the value of the non-intra MB quantization matrix.

【0282】最終段の符号化処理において生成されたビ
ットストリームのピクチャ層のユーザデータエリアに
は、過去の符号化処理において使用されたシーケンス層
のシーケンスエクステンションを表わすデータエレメン
トが、履歴ストリームとして記述される。
[0282] In the user data area of the picture layer of the bit stream generated in the encoding process at the last stage, a data element representing the sequence extension of the sequence layer used in the past encoding process is described as a history stream. You.

【0283】この過去の符号化処理で使用したシーケン
スエクステンション(sequence_extension)を表わすデ
ータエレメントは、 extension_start_code、extension
_start_code_identifier、sequence_extension_present
_flag、profile_and_level_indication、progressive_s
equence、chroma_format、horizontal_size_extensio
n、vertical_size_extension、bit_rate_extension、vb
v_buffer_size_extension、low_delay、frame_rate_ext
ension_n 、及び frame_rate_extension_d等のデータエ
レメントである。
The data elements representing the sequence extension (sequence_extension) used in the past encoding process are extension_start_code, extension
_start_code_identifier, sequence_extension_present
_flag, profile_and_level_indication, progressive_s
equence, chroma_format, horizontal_size_extensio
n, vertical_size_extension, bit_rate_extension, vb
v_buffer_size_extension, low_delay, frame_rate_ext
data elements such as extension_n and frame_rate_extension_d.

【0284】extension_start_codeは、エクステンショ
ンデータのスタート同期コードを表すデータである。ex
tension_start_code_identifierは、どの拡張データが
送られるかを示すデータである。sequence_extension_p
resent_flagは、シーケンスエクステンション内のデー
タが有効であるか無効であるかを示すデータである。pr
ofile_and_level_indicationは、ビデオデータのプロフ
ァイルとレベルを指定するためのデータである。progre
ssive_sequenceは、ビデオデータが順次走査であること
を示すデータである。chroma_formatは、ビデオデータ
の色差フォーマットを指定するためのデータである。
[0284] extension_start_code is data representing a start synchronization code of extension data. ex
tension_start_code_identifier is data indicating which extension data is sent. sequence_extension_p
resent_flag is data indicating whether the data in the sequence extension is valid or invalid. pr
ofile_and_level_indication is data for specifying the profile and level of video data. progre
ssive_sequence is data indicating that video data is sequentially scanned. chroma_format is data for specifying a color difference format of video data.

【0285】horizontal_size_extensionは、シーケン
スヘッダのhorizntal_size_valueに加える上位2ビット
のデータである。vertical_size_extensionは、シーケ
ンスヘッダのvertical_size_valueに加える上位2ビッ
トのデータである。bit_rate_extensionは、シーケンス
ヘッダのbit_rate_valueに加える上位12ビットのデー
タである。vbv_buffer_size_extensionは、シーケンス
ヘッダのvbv_buffer_size_valueに加える上位8ビット
のデータである。low_delayは、Bピクチャを含まない
ことを示すデータである。frame_rate_extension_nは、
シーケンスヘッダのframe_rate_codeと組み合わせてフ
レームレートを得るためのデータである。frame_rate_e
xtension_dは、シーケンスヘッダのframe_rate_codeと
組み合わせてフレームレートを得るためのデータであ
る。
[0285] horizontal_size_extension is high-order 2 bits of data to be added to horizontal_size_value of the sequence header. vertical_size_extension is upper two bits of data added to vertical_size_value of the sequence header. bit_rate_extension is upper 12 bits of data to be added to bit_rate_value of the sequence header. vbv_buffer_size_extension is upper 8 bits of data added to vbv_buffer_size_value of the sequence header. low_delay is data indicating that a B picture is not included. frame_rate_extension_n is
This is data for obtaining a frame rate in combination with frame_rate_code of the sequence header. frame_rate_e
xtension_d is data for obtaining a frame rate in combination with frame_rate_code of the sequence header.

【0286】続いて、ビットストリームのピクチャ層の
ユーザエリアには、過去の符号化処理において使用され
たシーケンス層のシーケンスディスプレイエクステンシ
ョンを表わすデータエレメントが、履歴ストリームとし
て記述される。
Subsequently, in the user area of the picture layer of the bit stream, a data element representing the sequence display extension of the sequence layer used in the past encoding processing is described as a history stream.

【0287】このシーケンスディスプレイエクステンシ
ョン(sequence_display_extension)として記述されて
いるデータエレメントは、extension_start_code、exte
nsion_start_code_identifier、sequence_display_exte
nsion_present_flag、video_format、colour_descripti
on、colour_primaries、transfer_characteristics、ma
trix_coeffients、display_horizontal_size、及びdisp
lay_vertical_sizeから構成される。
The data elements described as the sequence display extension (sequence_display_extension) are extension_start_code, exte
nsion_start_code_identifier, sequence_display_exte
nsion_present_flag, video_format, colour_descripti
on, colour_primaries, transfer_characteristics, ma
trix_coeffients, display_horizontal_size, and disp
It consists of lay_vertical_size.

【0288】extension_start_codeは、エクステンショ
ンデータのスタート同期コードを表すデータである。ex
tension_start_code_identifierは、どの拡張データが
送られるかを示すコードである。sequence_display_ext
ension_present_flagは、シーケンスディスプレイエク
ステンション内のデータエレメントが有効か無効かを示
すデータである。video_formatは、原信号の映像フォー
マットを表すデータである。color_descriptionは、色
空間の詳細データがあることを示すデータである。colo
r_primariesは、原信号の色特性の詳細を示すデータで
ある。transfer_characteristicsは、光電変換がどのよ
うに行われたのかの詳細を示すデータである。matrix_c
oeffientsは、原信号が光の三原色からどのように変換
されたかの詳細を示すデータである。display_horizont
al_sizeは、意図するディスプレイの活性領域(水平サ
イズ)を表すデータである。display_vertical_size
は、意図するディスプレイの活性領域(垂直サイズ)を
表すデータである。
[0288] The extension_start_code is data representing the start synchronization code of the extension data. ex
tension_start_code_identifier is a code indicating which extension data is sent. sequence_display_ext
The extension_present_flag is data indicating whether a data element in the sequence display extension is valid or invalid. video_format is data representing the video format of the original signal. color_description is data indicating that there is detailed data of a color space. colo
r_primaries is data indicating details of the color characteristics of the original signal. transfer_characteristics is data indicating details of how the photoelectric conversion was performed. matrix_c
The oeffients are data showing details of how the original signal was converted from the three primary colors of light. display_horizont
al_size is data representing the intended active area (horizontal size) of the display. display_vertical_size
Is data representing the intended active area (vertical size) of the display.

【0289】続いて、最終段の符号化処理において生成
されたビットストリームのピクチャ層のユーザエリアに
は、過去の符号化処理において生成されたマクロブロッ
クの位相情報を示すマクロブロックアサイメントデータ
(macroblock_assignment_in_user_data)が、履歴スト
リームとして記述される。
Subsequently, macroblock assignment data (macroblock_assignment_in_user_data) indicating the phase information of the macroblock generated in the past encoding process is provided in the user area of the picture layer of the bit stream generated in the final stage encoding process. ) Is described as a history stream.

【0290】このマクロブロックの位相情報を示すmacr
oblock_assignment_in_user_dataは、macroblock_assig
nment_present_flag、v_phase、h_phase等のデータエレ
メントから構成される。
Macr indicating phase information of this macroblock
oblock_assignment_in_user_data is macroblock_assig
It is composed of data elements such as nment_present_flag, v_phase, and h_phase.

【0291】このmacroblock_assignment_present_flag
は、macroblock_assignment_in_user_data内のデータエ
レメントが有効か無効かを示すデータである。 v_phase
は、画像データからマクロブロックを切り出す際の垂直
方向の位相情報を示すデータである。 h_phaseは、画像
データからマクロブロックを切り出す際の水平方向の位
相情報を示すデータである。
This macroblock_assignment_present_flag
Is data indicating whether a data element in macroblock_assignment_in_user_data is valid or invalid. v_phase
Is data indicating vertical phase information when a macroblock is cut out from image data. h_phase is data indicating horizontal phase information when a macroblock is cut out from image data.

【0292】続いて、最終段の符号化処理によって生成
されたビットストリームのピクチャ層のユーザエリアに
は、過去の符号化処理において使用されたGOP層のGOPヘ
ッダを表わすデータエレメントが、履歴ストリームとし
て記述されている。
Subsequently, in the user area of the picture layer of the bit stream generated by the encoding process at the last stage, a data element indicating the GOP header of the GOP layer used in the past encoding process is stored as a history stream. It has been described.

【0293】このGOPヘッダ(group_of_picture_heade
r)を表わすデータエレメントは、group_start_code、g
roup_of_picture_header_present_flag、time_code、cl
osed_gop、及びbroken_linkから構成される。
The GOP header (group_of_picture_heade)
The data element representing r) is group_start_code, g
roup_of_picture_header_present_flag, time_code, cl
osed_gop and broken_link.

【0294】group_start_codeは、GOP層の開始同期コ
ードを示すデータである。 group_of_picture_header_p
resent_flagは、 group_of_picture_header内のデータ
エレメントが有効であるか無効であるかを示すデータで
ある。 time_codeは、GOPの先頭ピクチャのシーケンス
の先頭からの時間を示すタイムコードである。closed_g
opは、GOP内の画像が他のGOPから独立再生可能なことを
示すフラグデータである。broken_linkは、編集などの
ためにGOP内の先頭のBピクチャが正確に再生できない
ことを示すフラグデータである。
[0294] group_start_code is data indicating the start synchronization code of the GOP layer. group_of_picture_header_p
resent_flag is data indicating whether a data element in group_of_picture_header is valid or invalid. time_code is a time code indicating the time from the beginning of the sequence of the first picture of the GOP. closed_g
op is flag data indicating that an image in a GOP can be reproduced independently from another GOP. broken_link is flag data indicating that the first B picture in the GOP cannot be accurately reproduced due to editing or the like.

【0295】続いて、最終段の符号化処理によって生成
されたビットストリームのピクチャ層のユーザエリアに
は、過去の符号化処理において使用されたピクチャ層の
ピクチャヘッダを表わすデータエレメントが、履歴スト
リームとして記述されている。
Subsequently, in the user area of the picture layer of the bit stream generated by the encoding process at the last stage, a data element representing the picture header of the picture layer used in the past encoding process is stored as a history stream. It has been described.

【0296】このピクチャヘッダ(picture_header)に
関するデータエレメントは、picture_start_code、temp
oral_reference、picture_coding_type、vbv_delay、fu
ll_pel_forward_vector、forward_f_code、full_pel_ba
ckward_vector、及び backward_f_codeから構成され
る。
Data elements related to the picture header (picture_header) are picture_start_code, temp
oral_reference, picture_coding_type, vbv_delay, fu
ll_pel_forward_vector, forward_f_code, full_pel_ba
It consists of ckward_vector and backward_f_code.

【0297】具体的には、picture_start_codeは、ピク
チャ層の開始同期コードを表すデータである。temporal
_referenceは、ピクチャの表示順を示す番号でGOPの先
頭でリセットされるデータである。picture_coding_typ
eは、ピクチャタイプを示すデータである。vbv_delay
は、ランダムアクセス時の仮想バッファの初期状態を示
すデータである。full_pel_forward_vectorは、順方向
動きベクトルの精度が整数単位か半画素単位かを示すデ
ータである。forward_f_codeは、順方向動きベクトル探
索範囲を表すデータである。full_pel_backward_vector
は、逆方向動きベクトルの精度が整数単位か半画素単位
かを示すデータである。backward_f_codeは、逆方向動
きベクトル探索範囲を表すデータである。
[0297] Specifically, picture_start_code is data representing the start synchronization code of the picture layer. temporal
_reference is data indicating the display order of pictures and is reset at the beginning of the GOP. picture_coding_typ
e is data indicating a picture type. vbv_delay
Is data indicating the initial state of the virtual buffer at the time of random access. full_pel_forward_vector is data indicating whether the accuracy of the forward motion vector is an integer unit or a half pixel unit. forward_f_code is data representing a forward motion vector search range. full_pel_backward_vector
Is data indicating whether the accuracy of the backward motion vector is an integer unit or a half pixel unit. backward_f_code is data representing a backward motion vector search range.

【0298】続いて、最終段の符号化処理によって生成
されたビットストリームのピクチャ層のユーザエリアに
は、過去の符号化処理において使用されたピクチャ層の
ピクチャコーディングエクステンションが、履歴ストリ
ームとして記述されている。
Subsequently, in the user area of the picture layer of the bit stream generated by the encoding process at the last stage, the picture coding extension of the picture layer used in the past encoding process is described as a history stream. I have.

【0299】このピクチャコーディングエクステンショ
ン(picture_coding_extension)に関するデータエレメ
ントは、extension_start_code、extension_start_code
_identifier、f_code[0][0]、f_code[0][1]、f_code[1]
[0]、f_code[1][1]、intra_dc_precision、picture_str
ucture、top_field_first、frame_predictive_frame_dc
t、concealment_motion_vectors、q_scale_type、intra
_vlc_format、alternate_scan、repeat_firt_field、ch
roma_420_type、progressive_frame、composite_displa
y_flag、v_axis、field_sequence、sub_carrier、burst
_amplitude、及びsub_carrier_phaseから構成される。
The data elements related to the picture coding extension (picture_coding_extension) are extension_start_code, extension_start_code
_identifier, f_code [0] [0], f_code [0] [1], f_code [1]
[0], f_code [1] [1], intra_dc_precision, picture_str
ucture, top_field_first, frame_predictive_frame_dc
t, concealment_motion_vectors, q_scale_type, intra
_vlc_format, alternate_scan, repeat_firt_field, ch
roma_420_type, progressive_frame, composite_displa
y_flag, v_axis, field_sequence, sub_carrier, burst
_amplitude and sub_carrier_phase.

【0300】extension_start_codeは、ピクチャ層のエ
クステンションデータのスタートを示す開始コードであ
る。extension_start_code_identifierは、どの拡張デ
ータが送られるかを示すコードである。 f_code[0][0]
は、フォワード方向の水平動きベクトル探索範囲を表す
データである。f_code[0][1]は、フォワード方向の垂直
動きベクトル探索範囲を表すデータである。f_code[1]
[0]は、バックワード方向の水平動きベクトル探索範囲
を表すデータである。f_code[1][1]は、バックワード方
向の垂直動きベクトル探索範囲を表すデータである。
[0300] The extension_start_code is a start code indicating the start of extension data in the picture layer. extension_start_code_identifier is a code indicating which extension data is sent. f_code [0] [0]
Is data indicating a horizontal motion vector search range in the forward direction. f_code [0] [1] is data representing the vertical motion vector search range in the forward direction. f_code [1]
[0] is data representing a horizontal motion vector search range in the backward direction. f_code [1] [1] is data representing the vertical motion vector search range in the backward direction.

【0301】intra_dc_precisionは、DC係数の精度を表
すデータである。picture_structureは、フレームスト
ラクチャかフィールドストラクチャかを示すデータであ
る。フィールドストラクチャの場合は、上位フィールド
か下位フィールドかもあわせて示すデータである。top_
field_firstは、フレームストラクチャの場合、最初の
フィールドが上位か下位かを示すデータである。frame_
predictive_frame_dctは、フレーム・ストラクチャの場
合、フレーム・モードDCTの予測がフレーム・モードだ
けであることを示すデータである。concealment_motion
_vectorsは、イントラマクロブロックに伝送エラーを隠
蔽するための動きベクトルがついていることを示すデー
タである。
[0301] intra_dc_precision is data representing the precision of the DC coefficient. picture_structure is data indicating a frame structure or a field structure. In the case of the field structure, it is data indicating the upper field or the lower field. top_
field_first is data indicating whether the first field is higher or lower in the case of a frame structure. frame_
predictive_frame_dct is data indicating that, in the case of a frame structure, the prediction of the frame mode DCT is only the frame mode. concealment_motion
_vectors is data indicating that a motion vector for concealing a transmission error is attached to an intra macroblock.

【0302】q_scale_typeは、線形量子化スケールを利
用するか、非線形量子化スケールを利用するかを示すデ
ータである。intra_vlc_formatは、イントラマクロブロ
ックに、別の2次元VLCを使うかどうかを示すデータで
ある。alternate_scanは、ジグザグスキャンを使うか、
オルタネート・スキャンを使うかの選択を表すデータで
ある。repeat_firt_fieldは、2:3プルダウンの際に
使われるデータである。chroma_420_typeは、信号フォ
ーマットが4:2:0の場合、次のprogressive_frame
と同じ値、そうでない場合は0を表すデータである。pr
ogressive_frameは、このピクチャが、順次走査できて
いるかどうかを示すデータである。composite_display_
flagは、ソース信号がコンポジット信号であったかどう
かを示すデータである。
[0302] q_scale_type is data indicating whether to use a linear quantization scale or a non-linear quantization scale. intra_vlc_format is data indicating whether another two-dimensional VLC is used for an intra macroblock. alternate_scan uses zigzag scan,
This is data indicating whether to use an alternate scan. repeat_firt_field is data used at the time of 2: 3 pull-down. chroma_420_type is the next progressive_frame when the signal format is 4: 2: 0.
Is the same value as, otherwise 0. pr
ogressive_frame is data indicating whether or not this picture has been sequentially scanned. composite_display_
The flag is data indicating whether the source signal is a composite signal.

【0303】v_axisは、ソース信号が、PALの場合に使
われるデータである。field_sequenceは、ソース信号
が、PALの場合に使われるデータである。sub_carrier
は、ソース信号が、PALの場合に使われるデータであ
る。burst_amplitudeは、ソース信号が、PALの場合に使
われるデータである。sub_carrier_phaseは、ソース信
号が、PALの場合に使われるデータである。
[0303] v_axis is data used when the source signal is PAL. field_sequence is data used when the source signal is PAL. sub_carrier
Is data used when the source signal is PAL. burst_amplitude is data used when the source signal is PAL. sub_carrier_phase is data used when the source signal is PAL.

【0304】続いて、最終段の符号化処理によって生成
されたビットストリームのピクチャ層のユーザエリアに
は、過去の符号化処理において使用された量子化マトリ
ックスエクステンションが、履歴ストリームとして記述
されている。
Subsequently, in the user area of the picture layer of the bit stream generated by the encoding process at the last stage, the quantization matrix extension used in the past encoding process is described as a history stream.

【0305】この量子化マトリックスエクステンション
(quant_matrix_extension)に関するデータエレメント
は、extension_start_code、extension_start_code_ide
ntifier、quant_matrix_extension_present_flag、load
_intra_quantiser_matrix、intra_quantiser_matrix[6
4]、load_non_intra_quantiser_matrix、non_intra_qua
ntiser_matrix[64]、load_chroma_intra_quantiser_mat
rix、chroma_intra_quantiser_matrix[64]、load_chrom
a_non_intra_quantiser_matrix、及びchroma_non_intra
_quantiser_matrix[64] から構成される。
Data elements related to the quantization matrix extension (quant_matrix_extension) are extension_start_code and extension_start_code_ide.
ntifier, quant_matrix_extension_present_flag, load
_intra_quantiser_matrix, intra_quantiser_matrix [6
4], load_non_intra_quantiser_matrix, non_intra_qua
ntiser_matrix [64], load_chroma_intra_quantiser_mat
rix, chroma_intra_quantiser_matrix [64], load_chrom
a_non_intra_quantiser_matrix and chroma_non_intra
_quantiser_matrix [64].

【0306】extension_start_codeは、この量子化マト
リックスエクステンションのスタートを示す開始コード
である。extension_start_code_identifierは、どの拡
張データが送られるかを示すコードである。 quant_mat
rix_extension_present_flagは、この量子化マトリック
スエクステンション内のデータエレメントが有効か無効
かを示すためのデータである。load_intra_quantiser_m
atrixは、イントラマクロブロック用の量子化マトリッ
クスデータの存在を示すデータである。intra_quantise
r_matrixは、イントラマクロブロック用の量子化マトリ
ックスの値を示すデータである。
Extension_start_code is a start code indicating the start of this quantization matrix extension. extension_start_code_identifier is a code indicating which extension data is sent. quant_mat
rix_extension_present_flag is data for indicating whether a data element in the quantization matrix extension is valid or invalid. load_intra_quantiser_m
atrix is data indicating the existence of quantization matrix data for an intra macroblock. intra_quantise
r_matrix is data indicating the value of a quantization matrix for an intra macroblock.

【0307】load_non_intra_quantiser_matrixは、非
イントラマクロブロック用の量子化マトリックスデータ
の存在を示すデータである。non_intra_quantiser_matr
ixは、非イントラマクロブロック用の量子化マトリック
スの値を表すデータである。load_chroma_intra_quanti
ser_matrixは、色差イントラマクロブロック用の量子化
マトリックス・データの存在を示すデータである。chro
ma_intra_quantiser_matrixは、色差イントラマクロブ
ロック用の量子化マトリックスの値を示すデータであ
る。load_chroma_non_intra_quantiser_matrixは、色差
非イントラマクロブロック用の量子化マトリックス・デ
ータの存在を示すデータである。chroma_non_intra_qua
ntiser_matrixは、色差非イントラマクロブロック用の
量子化マトリックスの値を示すデータである。
[0307] load_non_intra_quantiser_matrix is data indicating the existence of quantization matrix data for a non-intra macroblock. non_intra_quantiser_matr
ix is data representing a value of a quantization matrix for a non-intra macroblock. load_chroma_intra_quanti
ser_matrix is data indicating the existence of quantization matrix data for a chrominance intra macroblock. chro
ma_intra_quantiser_matrix is data indicating a value of a quantization matrix for a chroma intra macroblock. load_chroma_non_intra_quantiser_matrix is data indicating the existence of quantization matrix data for a chrominance non-intra macroblock. chroma_non_intra_qua
ntiser_matrix is data indicating a value of a quantization matrix for a color difference non-intra macroblock.

【0308】続いて、最終段の符号化処理によって生成
されたビットストリームのピクチャ層のユーザエリアに
は、過去の符号化処理において使用されたコピーライト
エクステンションが、履歴ストリームとして記述されて
いる。
[0308] Subsequently, in the user area of the picture layer of the bit stream generated by the encoding process at the last stage, the copyright extension used in the past encoding process is described as a history stream.

【0309】このコピーライトエクステンション(copy
right_extension)に関するデータエレメントは、exten
sion_start_code、extension_start_code_itentifier、
copyright_extension_present_flag、copyright_flag、
copyright_identifier、original_or_copy、copyright_
number_1、copyright_number_2、及び copyright_numbe
r_3から構成される。
The copyright extension (copy
data element for right_extension) is exten
sion_start_code, extension_start_code_itentifier,
copyright_extension_present_flag, copyright_flag,
copyright_identifier, original_or_copy, copyright_
number_1, copyright_number_2, and copyright_numbe
Consists of r_3.

【0310】extension_start_codeは、コピーライトエ
クステンションのスタート示す開始コードである。exte
nsion_start_code_itentifierのどのエクステンション
データが送られるかを示すコードである。 copyright_e
xtension_present_flagは、このコピーライトエクステ
ンション内のデータエレメントが有効か無効かを示すた
めのデータである。copyright_flagは、次のコピーライ
トエクステンション又はシーケンスエンドまで、符号化
されたビデオデータに対してコピー権が与えられている
か否かを示す。
[0310] The extension_start_code is a start code indicating the start of the copyright extension. exte
This code indicates which extension data of nsion_start_code_itentifier is sent. copyright_e
xtension_present_flag is data for indicating whether a data element in the copyright extension is valid or invalid. copyright_flag indicates whether or not a copy right has been granted to the encoded video data until the next copyright extension or sequence end.

【0311】copyright_identifierは、ISO/IEC JTC/SC
29によって指定されたコピー権の登録機関を識別するた
めのデータである。original_or_copyは、ビットストリ
ーム中のデータが、オリジナルデータであるかコピーデ
ータであるかを示すデータである。copyright_number_1
は、コピーライトナンバーのビット44から63を表わ
すデータである。copyright_number_2は、コピーライト
ナンバーのビット22から43を表わすデータである。
copyright_number_3は、コピーライトナンバーのビット
0から21を表わすデータである。
[0311] copyright_identifier is ISO / IEC JTC / SC
This is data for identifying the registration authority of the copy right specified by 29. original_or_copy is data indicating whether the data in the bit stream is original data or copy data. copyright_number_1
Is data representing bits 44 to 63 of the copyright number. copyright_number_2 is data representing bits 22 to 43 of the copyright number.
copyright_number_3 is data representing bits 0 to 21 of the copyright number.

【0312】続いて、最終段の符号化処理によって生成
されたビットストリームのピクチャ層のユーザエリアに
は、過去の符号化処理において使用されたピクチャディ
スプレイエクステンション( picture_display_extensi
on )が、履歴ストリームとして記述されている。
[0312] Subsequently, the user area of the picture layer of the bit stream generated by the encoding process at the last stage includes the picture display extension (picture_display_extensi) used in the past encoding process.
on) is described as a history stream.

【0313】このピクチャディスプレイエクステンショ
ンを表わすデータエレメントは、extension_start_cod
e、extension_start_code_identifier、picture_displa
y_extension_present_flag、frame_center_horizontal_
offset_1、frame_center_vertical_offset_1、frame_ce
nter_horizontal_offset_2、frame_center_vertical_of
fset_2、frame_center_horizontal_offset_3、及びfram
e_center_vertical_offset_3から構成される。
The data element representing this picture display extension is extension_start_cod
e, extension_start_code_identifier, picture_displa
y_extension_present_flag, frame_center_horizontal_
offset_1, frame_center_vertical_offset_1, frame_ce
nter_horizontal_offset_2, frame_center_vertical_of
fset_2, frame_center_horizontal_offset_3, and fram
It consists of e_center_vertical_offset_3.

【0314】extension_start_codeは、ピクチャディス
プレイエクステンションのスタートを示すための開始コ
ードである。extension_start_code_identifierは、ど
の拡張データが送られるかを示すコードである。pictur
e_display_extension_present_flagは、ピクチャディス
プレイエクステンション内のデータエレメントが有効か
無効かを示すデータである。frame_center_horizontal_
offsetは、表示エリアの水平方向のオフセットを示すデ
ータであって、3つのオフセット値まで定義することが
できる。frame_center_vertical_offsetは、表示エリア
を垂直方向のオフセットを示すデータであって、3つの
オフセット値まで定義することができる。
[0314] The extension_start_code is a start code for indicating the start of the picture display extension. extension_start_code_identifier is a code indicating which extension data is sent. pictur
e_display_extension_present_flag is data indicating whether the data element in the picture display extension is valid or invalid. frame_center_horizontal_
The offset is data indicating a horizontal offset of the display area, and can be defined up to three offset values. frame_center_vertical_offset is data indicating a vertical offset of the display area, and can define up to three offset values.

【0315】最終段の符号化処理において生成されたビ
ットストリームのピクチャ層のユーザエリアには、既に
説明したピクチャディスプレイエクステンションを表わ
す履歴情報の次に、過去の符号化処理において使用され
たユーザデータ(user_data)が、履歴ストリームとし
て記述されている。
In the user area of the picture layer of the bit stream generated in the encoding process of the final stage, the user information (user data used in the past encoding process) user_data) is described as a history stream.

【0316】このユーザデータの次には、過去の符号化
処理において使用されたマクロブロック層に関する情報
が、履歴ストリームとして記述されている。
Following the user data, information on the macroblock layer used in the past encoding processing is described as a history stream.

【0317】このマクロブロック層に関する情報は、ma
croblock_address_h、macroblock_address_v、slice_he
ader_present_flag、skipped_macroblock_flag等のマク
ロブロック(macroblock)の位置に関するデータエレメ
ントと、macroblock_quant、macroblock_motion_forwar
d、macroblock_motion_backward、mocroblock_patter
n、macroblock_intra、spatial_temporal_weight_code_
flag、frame_motion_type、及びdct_type等のマクロブ
ロックモード(macroblock_modes[])に関するデータエ
レメントと、quantiser_scale_code等の量子化ステップ
制御に関するデータエレメントと、PMV[0][0][0]、PMV
[0][0][1]、motion_vertical_field_select[0][0]、PMV
[0][1][0]、PMV[0][1][1]、motion_vertical_field_sel
ect[0][1]、PMV[1][0][0]、PMV[1][0][1]、motion_vert
ical_field_select[1][0]、PMV[1][1][0]、PMV[1][1]
[1]、motion_vertical_field_select[1][1]等の動き補
償に関するデータエレメントと、coded_block_pattern
等のマクロブロックパターンに関するデータエレメント
と、num_mv_bits、num_coef_bits、及びnum_other_bits
等の発生符号量に関するデータエレメントから構成され
ている。
The information on the macroblock layer is ma
croblock_address_h, macroblock_address_v, slice_he
ader_present_flag, skipped_macroblock_flag, and other data elements related to the position of the macroblock, and macroblock_quant, macroblock_motion_forwar
d, macroblock_motion_backward, macroblock_patter
n, macroblock_intra, spatial_temporal_weight_code_
Data elements related to macroblock modes (macroblock_modes []) such as flag, frame_motion_type, and dct_type, data elements related to quantization step control such as quantizer_scale_code, and PMV [0] [0] [0], PMV
[0] [0] [1], motion_vertical_field_select [0] [0], PMV
[0] [1] [0], PMV [0] [1] [1], motion_vertical_field_sel
ect [0] [1], PMV [1] [0] [0], PMV [1] [0] [1], motion_vert
ical_field_select [1] [0], PMV [1] [1] [0], PMV [1] [1]
Data elements related to motion compensation such as [1], motion_vertical_field_select [1] [1], and coded_block_pattern
Data elements related to macroblock patterns such as num_mv_bits, num_coef_bits, and num_other_bits
And so on.

【0318】以下にマクロブロック層に関するデータエ
レメントについて詳細に説明する。
The data elements relating to the macroblock layer will be described in detail below.

【0319】macroblock_address_hは、現在のマクロブ
ロックの水平方向の絶対位置を定義するためのデータで
ある。macroblock_address_vは、現在のマクロブロック
の垂直方向の絶対位置を定義するためのデータである。
slice_header_present_flagは、このマクロブロックが
スライス層の先頭であり、スライスヘッダを伴なうか否
かを示すデータである。skipped_macroblock_flagは、
復号処理においてこのマクロブロックをスキップするか
否かを示すデータでる。
[0319] macroblock_address_h is data for defining the absolute position of the current macroblock in the horizontal direction. macroblock_address_v is data for defining the vertical absolute position of the current macroblock.
slice_header_present_flag is data indicating whether or not this macroblock is the head of a slice layer and has a slice header. skipped_macroblock_flag is
This data indicates whether to skip this macroblock in the decoding process.

【0320】macroblock_quantは、後述する図63と図
64に示されたマクロブロックタイプ( macroblock_ty
pe )から導かれるデータであって、quantiser_scale_c
odeがビットストリーム中に現れるか否かを示すデータ
である。macroblock_motion_forwardは、図63と図6
4に示されたマクロブロックタイプから導かれるデータ
であって、復号処理で使用されるデータである。macrob
lock_motion_backwardは、図63と図64に示されたマ
クロブロックタイプから導かれるデータであって、復号
処理で使用されるデータである。mocroblock_pattern
は、図63と図64に示されたマクロブロックタイプか
ら導かれるデータであって、coded_block_patternがビ
ットストリーム中に現れるか否かを示すデータである。
The macroblock_quant is a macroblock type (macroblock_ty) shown in FIGS.
pe) data, quantizer_scale_c
This is data indicating whether or not ode appears in the bit stream. macroblock_motion_forward is shown in FIG. 63 and FIG.
4 is data derived from the macroblock type shown in FIG. 4 and used in the decoding process. macrob
lock_motion_backward is data derived from the macroblock type shown in FIGS. 63 and 64, and is data used in the decoding process. mocroblock_pattern
Is data derived from the macroblock types shown in FIGS. 63 and 64, and is data indicating whether or not coded_block_pattern appears in the bit stream.

【0321】macroblock_intraは、図63と図64に示
されたマクロブロックタイプから導かれるデータであっ
て、復号処理で使用されるデータである。spatial_temp
oral_weight_code_flagは、図63と図64に示された
マクロブロックタイプから導かれるデータであって、時
間スケーラビリティで下位レイヤ画像のアップサンプリ
ング方法を示すspatial_temporal_weight_codeは、ビッ
トストリーム中に存在するか否かを示すデータである。
The macroblock_intra is data derived from the macroblock type shown in FIGS. 63 and 64, and is data used in the decoding process. spatial_temp
oral_weight_code_flag is data derived from the macroblock types shown in FIGS. 63 and 64, and spatial_temporal_weight_code indicating a method of upsampling a lower layer image with temporal scalability is data indicating whether or not the bitstream exists. It is.

【0322】frame_motion_typeは、フレームのマクロ
ブロックの予測タイプを示す2ビットのコードである。
予測ベクトルが2個でフィールドベースの予測タイプで
あれば「00」であって、予測ベクトルが1個でフィー
ルドベースの予測タイプであれば「01」であって、予
測ベクトルが1個でフレームベースの予測タイプであれ
ば「10」であって、予測ベクトルが1個でディアルプ
ライムの予測タイプであれば「11」である。field_mo
tion_typeは、フィールドのマクロブロックの動き予測
を示す2ビットのコードである。予測ベクトルが1個で
フィールドベースの予測タイプであれば「01」であっ
て、予測ベクトルが2個で18×8マクロブロックベー
スの予測タイプであれば「10」であって、予測ベクト
ルが1個でディアルプライムの予測タイプであれば「1
1」である。dct_typeは、DCTがフレームDCTモードか、
フィールドDCTモードかを示すデータである。quantiser
_scale_codeはマクロブロックの量子化ステップサイズ
を示すデータである。
[0324] frame_motion_type is a 2-bit code indicating the prediction type of the macroblock of the frame.
If the number of prediction vectors is two and the field-based prediction type is “00”, if the number of prediction vectors is one and the field-based prediction type is “01”, the number of prediction vectors is one and the frame is base Is "10" for the prediction type of "1", and "11" for the prediction type of one prediction vector and dual prime. field_mo
tion_type is a 2-bit code indicating motion prediction of a macroblock in the field. If the number of prediction vectors is one and the field-based prediction type is “01”, if the number of prediction vectors is two and the prediction type is a 18 × 8 macroblock-based “10”, the prediction vector is one If it is a forecast type of dual prime, "1
1 ". dct_type indicates whether the DCT is in frame DCT mode
This is data indicating whether the mode is the field DCT mode. quantiser
_scale_code is data indicating the quantization step size of the macroblock.

【0323】次に動きベクトルに関するデータエレメン
トについて説明する。動きベクトルは、復号時に必要な
動きベクトルを減少させるために、先に符号化されたベ
クトルに関し差分として符号化される。動きベクトルの
復号を行うために復号器は、4個の動きベクトル予測値
(それぞれ水平及び垂直成分を伴なう)を維持しなけれ
ばいけない。この予測動きベクトルをPMV[r][s][v]と表
わすことにしている。[r]は、マクロブロックにおける
動きベクトルが第1のベクトルであるのか、第2のベク
トルであるのかを示すフラグであって、マクロブロック
におけるベクトルが第1のベクトルである場合には
「0」となって、マクロブロックにおけるベクトルが第
2のベクトルである場合には「1」となる。[s]は、マ
クロブロックにおける動きベクトルの方向が、前方向で
あるのか後方向であるのかを示すフラグであって、前方
向動きベクトルの場合には「0」となって、後方向動き
ベクトルの場合には「1」となる。[v]は、マクロブロ
ックにおけるベクトルの成分が、水平方向であるのか垂
直方向であるのかを示すフラグであって、水平方向成分
の場合には「0」となって、垂直方向成分の場合には
「1」となる。
Next, a data element relating to a motion vector will be described. The motion vector is coded as a difference with respect to the previously coded vector in order to reduce the motion vector required for decoding. In order to perform motion vector decoding, the decoder must maintain four motion vector predictions, each with a horizontal and vertical component. This predicted motion vector is represented as PMV [r] [s] [v]. [r] is a flag indicating whether the motion vector in the macroblock is the first vector or the second vector, and is “0” when the vector in the macroblock is the first vector. Becomes “1” when the vector in the macro block is the second vector. [s] is a flag indicating whether the direction of the motion vector in the macroblock is forward or backward. In the case of a forward motion vector, the flag is set to “0”, and the backward motion vector In this case, it becomes "1". [v] is a flag indicating whether the vector component in the macroblock is horizontal or vertical, and is “0” in the case of a horizontal component, and is “0” in the case of a vertical component. Becomes “1”.

【0324】従って、PMV[0][0][0]は、第1のベクトル
の前方向の動きベクトルの水平方向成分のデータを表わ
し、PMV[0][0][1]は、第1のベクトルの前方向の動きベ
クトルの垂直方向成分のデータを表わし、PMV[0][1][0]
は、第1のベクトルの後方向の動きベクトルの水平方向
成分のデータを表わし、PMV[0][1][1]は、第1のベクト
ルの後方向の動きベクトルの垂直方向成分のデータを表
わし、 PMV[1][0][0]は、第2のベクトルの前方向の動
きベクトルの水平方向成分のデータを表わし、PMV[1]
[0][1]は、第2のベクトルの前方向の動きベクトルの垂
直方向成分のデータを表わし、 PMV[1][1][0]は、第2
のベクトルの後方向の動きベクトルの水平方向成分のデ
ータを表わし、PMV[1][1][1] は、第2のベクトルの後
方向の動きベクトルの垂直方向成分のデータを表わして
いる。
Therefore, PMV [0] [0] [0] represents the data of the horizontal component of the forward motion vector of the first vector, and PMV [0] [0] [1] represents the first component. Represents the vertical component data of the motion vector in the forward direction of the vector of PMV [0] [1] [0]
Represents the data of the horizontal component of the backward motion vector of the first vector, and PMV [0] [1] [1] represents the data of the vertical component of the backward motion vector of the first vector. PMV [1] [0] [0] represents the horizontal component data of the forward motion vector of the second vector, and PMV [1]
[0] [1] represents the data of the vertical component of the forward motion vector of the second vector, and PMV [1] [1] [0] represents the second component.
Represents the horizontal component data of the backward motion vector of the second vector, and PMV [1] [1] [1] represents the vertical component data of the second motion vector of the second vector.

【0325】motion_vertical_field_select[r][s]は、
予測の形式にいずれの参照フィールドを使用するのかを
示すデータである。このmotion_vertical_field_select
[r][s]が「0」の場合には、トップ参照フィールドを使
用し、「1」の場合には、ボトム参照フィールドを使用
することを示している。
[0325] motion_vertical_field_select [r] [s] is
This is data indicating which reference field is used for the prediction format. This motion_vertical_field_select
When [r] [s] is “0”, it indicates that the top reference field is used, and when “1”, the bottom reference field is used.

【0326】よって、motion_vertical_field_select
[0][0]は、第1のベクトルの前方向の動きベクトルを生
成する際の参照フィールドを示し、motion_vertical_fi
eld_select[0][1]は、第1のベクトルの後方向の動きベ
クトルを生成する際の参照フィールドを示し、motion_v
ertical_field_select[1][0]は、第2のベクトルの前方
向の動きベクトルを生成する際の参照フィールドを示
し、motion_vertical_field_select[1][1]は、第2ベク
トルの後方向の動きベクトルを生成する際の参照フィー
ルドを示している。
Therefore, motion_vertical_field_select
[0] [0] indicates a reference field when a forward motion vector of the first vector is generated, and motion_vertical_fi
eld_select [0] [1] indicates a reference field when a backward motion vector of the first vector is generated, and motion_v
ertical_field_select [1] [0] indicates a reference field when a forward motion vector of the second vector is generated, and motion_vertical_field_select [1] [1] generates a backward motion vector of the second vector. Reference field at the time is shown.

【0327】coded_block_patternは、DCT係数を格納す
る複数のDCTブロックのうち、どのDCTブロックに、有意
係数(非0係数)があるかを示す可変長のデータであ
る。num_mv_bitsは、マクロブロック中の動きベクトル
の符号量を示すデータである。num_coef_bitsは、マク
ロブロック中のDCT係数の符号量を示すデータである。n
um_other_bitsは、マクロブロックの符号量で、動きベ
クトル及びDCT係数以外の符号量を示すデータである。
[0327] The coded_block_pattern is variable-length data indicating which DCT block has a significant coefficient (non-zero coefficient) among a plurality of DCT blocks storing DCT coefficients. num_mv_bits is data indicating the code amount of a motion vector in a macroblock. num_coef_bits is data indicating the code amount of the DCT coefficient in the macro block. n
um_other_bits is the code amount of the macroblock and is data indicating the code amount other than the motion vector and the DCT coefficient.

【0328】次に、可変長の履歴ストリームから各デー
タエレメントをデコードするためのシンタックスについ
て、図47乃至図67を参照して説明する。
Next, the syntax for decoding each data element from the variable-length history stream will be described with reference to FIGS.

【0329】この可変長の履歴ストリームは、next_sta
rt_code()関数、sequence_header()関数、sequence_ext
ension()関数、extension_and_user_data(0)関数、grou
p_of_picture_header()関数、extension_and_user_data
(1)関数、picture_header()関数、picture_coding_exte
nsion()関数、re_coding_stream_info()関数、extensio
n_and_user_data(2)関数、及びpicture_data()関数によ
って定義されたデータエレメントによって構成される。
The variable-length history stream is next_sta
rt_code () function, sequence_header () function, sequence_ext
extension () function, extension_and_user_data (0) function, grou
p_of_picture_header () function, extension_and_user_data
(1) function, picture_header () function, picture_coding_exte
nsion () function, re_coding_stream_info () function, extensio
It is composed of data elements defined by n_and_user_data (2) function and picture_data () function.

【0330】next_start_code()関数は、ビットストリ
ーム中に存在するスタートコードを探すための関数であ
るので、履歴ストリームの最も先頭には、図48に示す
ような、過去の符号化処理において使用されたデータエ
レメントであってsequence_header()関数によって定義
されたデータエレメントが記述されている。
Since the next_start_code () function is a function for searching for a start code existing in the bit stream, the next_start_code () function is used in the past encoding process as shown in FIG. A data element, which is a data element defined by the sequence_header () function, is described.

【0331】sequence_header()関数によって定義され
たデータエレメントは、sequence_header_code、sequen
ce_header_present_flag、horizontal_size_value、ver
tical_size_value、aspect_ratio_information、frame_
rate_code、bit_rate_value、marker_bit、VBV_buffer_
size_value、constrained_parameter_flag、load_intra
_quantiser_matrix、intra_quantiser_matrix、load_no
n_intra_quantiser_matrix、及びnon_intra_quantiser_
matrix等である。
The data elements defined by the sequence_header () function are sequence_header_code, sequence
ce_header_present_flag, horizontal_size_value, ver
tical_size_value, aspect_ratio_information, frame_
rate_code, bit_rate_value, marker_bit, VBV_buffer_
size_value, constrained_parameter_flag, load_intra
_quantiser_matrix, intra_quantiser_matrix, load_no
n_intra_quantiser_matrix and non_intra_quantiser_
matrix.

【0332】sequence_header_codeは、シーケンス層の
スタート同期コードを表すデータである。sequence_hea
der_present_flagは、sequence_header内のデータが有
効か無効かを示すデータである。 horizontal_size_val
ueは、画像の水平方向の画素数の下位12ビットから成る
データである。vertical_size_valueは、画像の縦のラ
イン数の下位12ビットからなるデータである。aspect_r
atio_informationは、画素のアスペクト比(縦横比)ま
たは表示画面アスペクト比を表すデータである。frame_
rate_codeは、画像の表示周期を表すデータである。bit
_rate_valueは、発生ビット量に対する制限のためのビ
ット・レートの下位18ビット(400bsp単位で切り上げる)
データである。
[0332] sequence_header_code is data representing a start synchronization code of the sequence layer. sequence_hea
der_present_flag is data indicating whether data in sequence_header is valid or invalid. horizontal_size_val
ue is data consisting of the lower 12 bits of the number of pixels in the horizontal direction of the image. vertical_size_value is data composed of lower 12 bits of the number of vertical lines of the image. aspect_r
atio_information is data representing the pixel aspect ratio (aspect ratio) or the display screen aspect ratio. frame_
rate_code is data representing a display cycle of an image. bit
_rate_value is the lower 18 bits of the bit rate for limiting the amount of generated bits (rounded up to the nearest 400 bsp)
Data.

【0333】marker_bitは、スタートコードエミュレー
ションを防止するために挿入されるビットデータであ
る。VBV_buffer_size_valueは、発生符号量制御用の仮
想バッファ(ビデオバッファベリファイヤー)の大きさ
を決める値の下位10ビットデータである。constrained_
parameter_flagは、各パラメータが制限以内であること
を示すデータである。load_intra_quantiser_matrix
は、イントラMB用量子化マトリックス・データの存在を
示すデータである。intra_quantiser_matrixは、イント
ラMB用量子化マトリックスの値を示すデータである。
load_non_intra_quantiser_matrixは、非イントラMB
用量子化マトリックス・データの存在を示すデータであ
る。non_intra_quantiser_matrixは、非イントラMB用
量子化マトリックスの値を表すデータである。
Marker_bit is bit data inserted to prevent start code emulation. VBV_buffer_size_value is lower 10-bit data of a value that determines the size of a virtual buffer (video buffer verifier) for controlling the generated code amount. constrained_
parameter_flag is data indicating that each parameter is within the limit. load_intra_quantiser_matrix
Is data indicating the presence of intra MB quantization matrix data. intra_quantiser_matrix is data indicating the value of the quantization matrix for intra MB.
load_non_intra_quantiser_matrix is a non-intra MB
This is data indicating the existence of quantization matrix data for use. non_intra_quantiser_matrix is data representing the value of the non-intra MB quantization matrix.

【0334】sequence_header()関数によって定義され
たデータエレメントの次には、図49で示すような、se
quence_extension()関数によって定義されたデータエレ
メントが、履歴ストリームとして記述されている。
Next to the data element defined by the sequence_header () function, as shown in FIG.
The data element defined by the quence_extension () function is described as a history stream.

【0335】sequence_extension()関数によって定義さ
れたデータエレメントとは、extension_start_code、ex
tension_start_code_identifier、sequence_extension_
present_flag、profile_and_level_indication、progre
ssive_sequence、chroma_format、horizontal_size_ext
ension、vertical_size_extension、bit_rate_extensio
n、vbv_buffer_size_extension、low_delay、frame_rat
e_extension_n 、及びframe_rate_extension_d等のデー
タエレメントである。
The data elements defined by the sequence_extension () function are extension_start_code, ex
tension_start_code_identifier, sequence_extension_
present_flag, profile_and_level_indication, progre
ssive_sequence, chroma_format, horizontal_size_ext
tension, vertical_size_extension, bit_rate_extensio
n, vbv_buffer_size_extension, low_delay, frame_rat
Data elements such as e_extension_n and frame_rate_extension_d.

【0336】extension_start_codeは、エクステンショ
ンデータのスタート同期コードを表すデータである。ex
tension_start_code_identifierは、どの拡張データが
送られるかを示すデータである。sequence_extension_p
resent_flagは、シーケンスエクステンション内のデー
タが有効であるか無効であるかを示すスデータである。
profile_and_level_indicationは、ビデオデータのプロ
ファイルとレベルを指定するためのデータである。prog
ressive_sequenceは、ビデオデータが順次走査であるこ
とを示すデータである。chroma_formatは、ビデオデー
タの色差フォーマットを指定するためのデータである。
horizontal_size_extensionは、シーケンスヘッダのhor
izntal_size_valueに加える上位2ビットのデータであ
る。vertical_size_extensionは、シーケンスヘッダのv
ertical_size_value加える上位2ビットのデータであ
る。bit_rate_extensionは、シーケンスヘッダのbit_ra
te_valueに加える上位12ビットのデータである。vbv_
buffer_size_extensionは、シーケンスヘッダのvbv_buf
fer_size_valueに加える上位8ビットのデータである。
[0336] The extension_start_code is data representing a start synchronization code of extension data. ex
tension_start_code_identifier is data indicating which extension data is sent. sequence_extension_p
resent_flag is data indicating whether the data in the sequence extension is valid or invalid.
profile_and_level_indication is data for specifying the profile and level of video data. prog
ressive_sequence is data indicating that video data is sequentially scanned. chroma_format is data for specifying a color difference format of video data.
horizontal_size_extension is hor in the sequence header
Upper 2 bits of data to be added to izntal_size_value. vertical_size_extension is the v in the sequence header
Upper 2 bits of data to be added to ertical_size_value. bit_rate_extension is bit_ra of the sequence header
Upper 12 bits of data to be added to te_value. vbv_
buffer_size_extension is the sequence header vbv_buf
Upper 8 bits of data to be added to fer_size_value.

【0337】low_delayは、Bピクチャを含まないこと
を示すデータである。frame_rate_extension_nは、シー
ケンスヘッダのframe_rate_codeと組み合わせてフレー
ムレートを得るためのデータである。frame_rate_exten
sion_dは、シーケンスヘッダのframe_rate_codeと組み
合わせてフレームレートを得るためのデータである。
[0337] low_delay is data indicating that a B picture is not included. frame_rate_extension_n is data for obtaining a frame rate in combination with frame_rate_code of the sequence header. frame_rate_exten
sion_d is data for obtaining a frame rate in combination with frame_rate_code of the sequence header.

【0338】sequence_extension()関数によって定義さ
れたデータエレメントの次には、図50に示すようなex
tension_and_user_data(0)関数によって定義されたデー
タエレメントが、履歴ストリームとして記述されてい
る。 extension_and_user_data(i)関数は、「i」が1以
外のときは、extension_data()関数によって定義される
データエレメントは記述せずに、user_data()関数によ
って定義されるデータエレメントのみを履歴ストリーム
として記述する。よって、 extension_and_user_data
(0)関数は、 user_data()関数によって定義されるデー
タエレメントのみを履歴ストリームとして記述する。
The data element defined by the sequence_extension () function is followed by ex as shown in FIG.
The data element defined by the tension_and_user_data (0) function is described as a history stream. When "i" is other than 1, the extension_and_user_data (i) function describes only the data element defined by the user_data () function as a history stream without describing the data element defined by the extension_data () function. . Therefore, extension_and_user_data
The (0) function describes only a data element defined by the user_data () function as a history stream.

【0339】user_data()関数は、図51に示されたよ
うなシンタックスに基いて、ユーザデータを履歴ストリ
ームとして記述する。
The user_data () function describes user data as a history stream based on the syntax as shown in FIG.

【0340】extension_and_user_data(0)関数によって
定義されたデータエレメントの次には、図52に示すよ
うなgroup_of_picture_header()関数によって定義され
たデータエレメント、及びextension_and_user_data(1)
関数によって定義されるデータエレメントが、履歴スト
リームとして記述されている。但し、履歴ストリーム中
に、GOP層のスタートコードを示すgroup_start_codeが
記述されている場合にのみ、 group_of_picture_header
()関数によって定義されたデータエレメント、及びexte
nsion_and_user_data(1)関数によって定義されるデータ
エレメントが記述されている。
Following the data element defined by the extension_and_user_data (0) function, the data element defined by the group_of_picture_header () function as shown in FIG. 52, and the extension_and_user_data (1)
The data element defined by the function is described as a history stream. However, only when group_start_code indicating the start code of the GOP layer is described in the history stream, group_of_picture_header
Data elements defined by the () function, and exte
A data element defined by the nsion_and_user_data (1) function is described.

【0341】group_of_picture_header()関数によって
定義されたデータエレメントは、group_start_code、gr
oup_of_picture_header_present_flag、time_code、clo
sed_gop、及びbroken_linkから構成される。
The data elements defined by the group_of_picture_header () function are group_start_code, gr
oup_of_picture_header_present_flag, time_code, clo
It consists of sed_gop and broken_link.

【0342】group_start_codeは、GOP層の開始同期コ
ードを示すデータである。 group_of_picture_header_p
resent_flagは、 group_of_picture_header内のデータ
エレメントが有効であるか無効であるかを示すデータで
ある。 time_codeは、GOPの先頭ピクチャのシーケンス
の先頭からの時間を示すタイムコードである。closed_g
opは、GOP内の画像が他のGOPから独立再生可能なことを
示すフラグデータである。broken_linkは、編集などの
ためにGOP内の先頭のBピクチャが正確に再生できない
ことを示すフラグデータである。
Group_start_code is data indicating the start synchronization code of the GOP layer. group_of_picture_header_p
resent_flag is data indicating whether a data element in group_of_picture_header is valid or invalid. time_code is a time code indicating the time from the beginning of the sequence of the first picture of the GOP. closed_g
op is flag data indicating that an image in a GOP can be reproduced independently from another GOP. broken_link is flag data indicating that the first B picture in the GOP cannot be accurately reproduced due to editing or the like.

【0343】extension_and_user_data(1)関数は、 ext
ension_and_user_data(0)関数と同じように、user_data
()関数によって定義されるデータエレメントのみを履歴
ストリームとして記述する。
The extension_and_user_data (1) function is called ext
As in the case of the extension_and_user_data (0) function, user_data
Describe only the data elements defined by the () function as a history stream.

【0344】もし、履歴ストリーム中に、GOP層のスタ
ートコードを示すgroup_start_codeが存在しない場合に
は、これらのgroup_of_picture_header()関数及びexten
sion_and_user_data(1)関数によって定義されるデータ
エレメントは、履歴ストリーム中には記述されていな
い。その場合には、 extension_and_user_data(0)関数
によって定義されたデータエレメントの次に、picture_
headr()関数によって定義されたデータエレメントが履
歴ストリームとして記述されている。
If there is no group_start_code indicating the start code of the GOP layer in the history stream, the group_of_picture_header () function and the exten
The data elements defined by the sion_and_user_data (1) function are not described in the history stream. In that case, after the data element defined by the extension_and_user_data (0) function,
The data element defined by the headr () function is described as a history stream.

【0345】picture_headr()関数によって定義された
データエレメントは、図53に示すように、picture_st
art_code、temporal_reference、picture_coding_typ
e、vbv_delay、full_pel_forward_vector、forward_f_c
ode、full_pel_backward_vector、backward_f_code、ex
tra_bit_picture、及びextra_information_pictureであ
る。
The data element defined by the picture_headr () function is, as shown in FIG.
art_code, temporal_reference, picture_coding_typ
e, vbv_delay, full_pel_forward_vector, forward_f_c
ode, full_pel_backward_vector, backward_f_code, ex
tra_bit_picture and extra_information_picture.

【0346】具体的には、picture_start_codeは、ピク
チャ層の開始同期コードを表すデータである。temporal
_referenceは、ピクチャの表示順を示す番号でGOPの先
頭でリセットされるデータである。picture_coding_typ
eは、ピクチャタイプを示すデータである。vbv_delay
は、ランダムアクセス時の仮想バッファの初期状態を示
すデータである。full_pel_forward_vectorは、順方向
動きベクトルの精度が整数単位か半画素単位かを示すデ
ータである。forward_f_codeは、順方向動きベクトル探
索範囲を表すデータである。full_pel_backward_vector
は、逆方向動きベクトルの精度が整数単位か半画素単位
かを示すデータである。backward_f_codeは、逆方向動
きベクトル探索範囲を表すデータである。 extra_bit_p
ictureは、後続する追加情報の存在を示すフラグであ
る。このextra_bit_pictureが「1」の場合には、次にe
xtra_information_pictureが存在し、extra_bit_pictur
eが「0」の場合には、これに続くデータが無いことを
示している。extra_information_pictureは、規格にお
いて予約された情報である。
[0346] Specifically, picture_start_code is data representing the start synchronization code of the picture layer. temporal
_reference is data indicating the display order of pictures and is reset at the beginning of the GOP. picture_coding_typ
e is data indicating a picture type. vbv_delay
Is data indicating the initial state of the virtual buffer at the time of random access. full_pel_forward_vector is data indicating whether the accuracy of the forward motion vector is an integer unit or a half pixel unit. forward_f_code is data representing a forward motion vector search range. full_pel_backward_vector
Is data indicating whether the accuracy of the backward motion vector is an integer unit or a half pixel unit. backward_f_code is data representing a backward motion vector search range. extra_bit_p
“icture” is a flag indicating the presence of the following additional information. If this extra_bit_picture is "1", then e
xtra_information_picture exists and extra_bit_pictur
When e is “0”, it indicates that there is no data following this. extra_information_picture is information reserved in the standard.

【0347】picture_headr()関数によって定義された
データエレメントの次には、図54に示すようなpictur
e_coding_extension()関数によって定義されたデータエ
レメントが、履歴ストリームとして記述されている。
The data element defined by the picture_headr () function is followed by a pictur as shown in FIG.
The data element defined by the e_coding_extension () function is described as a history stream.

【0348】このpicture_coding_extension()関数によ
って定義されたデータエレメントとは、extension_star
t_code、extension_start_code_identifier、f_code[0]
[0]、f_code[0][1]、f_code[1][0]、f_code[1][1]、int
ra_dc_precision、picture_structure、top_field_firs
t、frame_predictive_frame_dct、concealment_motion_
vectors、q_scale_type、intra_vlc_format、alternate
_scan、repeat_firt_field、chroma_420_type、progres
sive_frame、composite_display_flag、v_axis、field_
sequence、sub_carrier、burst_amplitude、及びsub_ca
rrier_phaseから構成される。
The data element defined by the picture_coding_extension () function is extension_star
t_code, extension_start_code_identifier, f_code [0]
[0], f_code [0] [1], f_code [1] [0], f_code [1] [1], int
ra_dc_precision, picture_structure, top_field_firs
t, frame_predictive_frame_dct, concealment_motion_
vectors, q_scale_type, intra_vlc_format, alternate
_scan, repeat_firt_field, chroma_420_type, progres
sive_frame, composite_display_flag, v_axis, field_
sequence, sub_carrier, burst_amplitude, and sub_ca
It is composed of rrier_phase.

【0349】extension_start_codeは、ピクチャ層のエ
クステンションデータのスタートを示す開始コードであ
る。extension_start_code_identifierは、どの拡張デ
ータが送られるかを示すコードである。 f_code[0][0]
は、フォワード方向の水平動きベクトル探索範囲を表す
データである。f_code[0][1]は、フォワード方向の垂直
動きベクトル探索範囲を表すデータである。f_code[1]
[0]は、バックワード方向の水平動きベクトル探索範囲
を表すデータである。f_code[1][1]は、バックワード方
向の垂直動きベクトル探索範囲を表すデータである。in
tra_dc_precisionは、DC係数の精度を表すデータであ
る。
[0349] extension_start_code is a start code indicating the start of extension data in the picture layer. extension_start_code_identifier is a code indicating which extension data is sent. f_code [0] [0]
Is data indicating a horizontal motion vector search range in the forward direction. f_code [0] [1] is data representing the vertical motion vector search range in the forward direction. f_code [1]
[0] is data representing a horizontal motion vector search range in the backward direction. f_code [1] [1] is data representing the vertical motion vector search range in the backward direction. in
tra_dc_precision is data representing the accuracy of the DC coefficient.

【0350】picture_structureは、フレームストラク
チャかフィールドストラクチャかを示すデータである。
フィールドストラクチャの場合は、上位フィールドか下
位フィールドかもあわせて示すデータである。top_fiel
d_firstは、フレームストラクチャの場合、最初のフィ
ールドが上位か下位かを示すデータである。frame_pred
ictive_frame_dctは、フレーム・ストラクチャの場合、
フレーム・モードDCTの予測がフレーム・モードだけで
あることを示すデータである。concealment_motion_vec
torsは、イントラマクロブロックに伝送エラーを隠蔽す
るための動きベクトルがついていることを示すデータで
ある。q_scale_typeは、線形量子化スケールを利用する
か、非線形量子化スケールを利用するかを示すデータで
ある。intra_vlc_formatは、イントラマクロブロック
に、別の2次元VLCを使うかどうかを示すデータであ
る。
[0350] The picture_structure is data indicating a frame structure or a field structure.
In the case of the field structure, it is data indicating the upper field or the lower field. top_fiel
In the case of a frame structure, d_first is data indicating whether the first field is higher or lower. frame_pred
ictive_frame_dct is the frame structure
This is data indicating that the prediction of the frame mode DCT is only the frame mode. concealment_motion_vec
tors is data indicating that a motion vector for concealing a transmission error is attached to an intra macroblock. q_scale_type is data indicating whether to use a linear quantization scale or a non-linear quantization scale. intra_vlc_format is data indicating whether another two-dimensional VLC is used for an intra macroblock.

【0351】alternate_scanは、ジグザグスキャンを使
うか、オルタネート・スキャンを使うかの選択を表すデ
ータである。repeat_firt_fieldは、2:3プルダウン
の際に使われるデータである。chroma_420_typeは、信
号フォーマットが4:2:0の場合、次のprogressive_
frame と同じ値、そうでない場合は0を表すデータであ
る。progressive_frameは、このピクチャが、順次走査
できているかどうかを示すデータである。composite_di
splay_flagは、ソース信号がコンポジット信号であった
かどうかを示すデータである。v_axisは、ソース信号
が、PALの場合に使われるデータである。field_sequenc
eは、ソース信号が、PALの場合に使われるデータであ
る。sub_carrierは、ソース信号が、PALの場合に使われ
るデータである。burst_amplitudeは、ソース信号が、P
ALの場合に使われるデータである。sub_carrier_phase
は、ソース信号が、PALの場合に使われるデータであ
る。
[0351] "alternate_scan" is data representing a choice between using a zigzag scan or an alternate scan. repeat_firt_field is data used at the time of 2: 3 pull-down. chroma_420_type is the next progressive_type when the signal format is 4: 2: 0.
The same value as frame, otherwise it represents 0. progressive_frame is data indicating whether or not this picture has been sequentially scanned. composite_di
splay_flag is data indicating whether or not the source signal was a composite signal. v_axis is data used when the source signal is PAL. field_sequenc
e is data used when the source signal is PAL. sub_carrier is data used when the source signal is PAL. burst_amplitude indicates that the source signal is P
Data used in the case of AL. sub_carrier_phase
Is data used when the source signal is PAL.

【0352】picture_coding_extension()関数によって
定義されたデータエレメントの次には、re_coding_stre
am_info()関数によって定義されたデータエレメントが
履歴ストリームとして記述されている。このre_coding_
stream_info()関数は、主に履歴情報の組み合わせを記
述する場合に用いられるものであり、その詳細について
は、図71を参照して後述する。
[0352] After the data element defined by the picture_coding_extension () function, re_coding_stre
The data element defined by the am_info () function is described as a history stream. This re_coding_
The stream_info () function is mainly used when describing a combination of history information, and details thereof will be described later with reference to FIG.

【0353】re_coding_stream_info()関数によって定
義されたデータエレメントの次には、extensions_and_u
ser_data(2)によって定義されたデータエレメントが、
履歴ストリームとして記述されている。このextension_
and_user_data(2)関数は、図50に示したように、ビッ
トストリーム中にエクステンションスタートコード(ex
tension_start_code)が存在する場合には、extension_
data()関数によって定義されるデータエレメントが記述
されている。このデータエレメントの次には、ビットス
トリーム中にユーザデータスタートコード(user_data_
start_code)が存在する場合には、user_data()関数に
よって定義されるデータエレメントが記述されている。
但し、ビットストリーム中にエクステンションスタート
コード及びユーザデータスタートコードが存在しない場
合には extension_data()関数 及びuser_data()関数に
よって定義されるデータエレメントはビットトリーム中
には記述されていない。
After the data element defined by the re_coding_stream_info () function, extensions_and_u
The data element defined by ser_data (2)
It is described as a history stream. This extension_
The and_user_data (2) function includes, as shown in FIG. 50, an extension start code (ex
tension_start_code) if present
Describes a data element defined by the data () function. Following this data element, the user data start code (user_data_
If start_code) exists, a data element defined by the user_data () function is described.
However, when the extension start code and the user data start code do not exist in the bit stream, the data elements defined by the extension_data () function and the user_data () function are not described in the bit stream.

【0354】extension_data()関数は、図55に示すよ
うに、extension_start_codeを示すデータエレメント
と、quant_matrix_extension()関数、copyright_extens
ion()関数、及びpicture_display_extension()関数によ
って定義されるデータエレメンエトとを、ビットストリ
ーム中に履歴ストリームとして記述するための関数であ
る。
As shown in FIG. 55, the extension_data () function includes a data element indicating extension_start_code, a quant_matrix_extension () function, and a copyright_extens
This is a function for describing a data element defined by an ion () function and a picture_display_extension () function as a history stream in a bit stream.

【0355】quant_matrix_extension()関数によって定
義されるデータエレメントは、図56に示すように、ex
tension_start_code、extension_start_code_identifie
r、quant_matrix_extension_present_flag、load_intra
_quantiser_matrix、intra_quantiser_matrix[64]、loa
d_non_intra_quantiser_matrix、non_intra_quantiser_
matrix[64]、load_chroma_intra_quantiser_matrix、ch
roma_intra_quantiser_matrix[64]、load_chroma_non_i
ntra_quantiser_matrix、及びchroma_non_intra_quanti
ser_matrix[64] である。
The data element defined by the quant_matrix_extension () function is, as shown in FIG.
tension_start_code, extension_start_code_identifie
r, quant_matrix_extension_present_flag, load_intra
_quantiser_matrix, intra_quantiser_matrix [64], loa
d_non_intra_quantiser_matrix, non_intra_quantiser_
matrix [64], load_chroma_intra_quantiser_matrix, ch
roma_intra_quantiser_matrix [64], load_chroma_non_i
ntra_quantiser_matrix and chroma_non_intra_quanti
ser_matrix [64].

【0356】extension_start_codeは、この量子化マト
リックスエクステンションのスタートを示す開始コード
である。extension_start_code_identifierは、どの拡
張データが送られるかを示すコードである。 quant_mat
rix_extension_present_flagは、この量子化マトリック
スエクステンション内のデータエレメントが有効か無効
かを示すためのデータである。load_intra_quantiser_m
atrixは、イントラマクロブロック用の量子化マトリッ
クスデータの存在を示すデータである。intra_quantise
r_matrixは、イントラマクロブロック用の量子化マトリ
ックスの値を示すデータである。
The extension_start_code is a start code indicating the start of the quantization matrix extension. extension_start_code_identifier is a code indicating which extension data is sent. quant_mat
rix_extension_present_flag is data for indicating whether a data element in the quantization matrix extension is valid or invalid. load_intra_quantiser_m
atrix is data indicating the existence of quantization matrix data for an intra macroblock. intra_quantise
r_matrix is data indicating the value of a quantization matrix for an intra macroblock.

【0357】load_non_intra_quantiser_matrixは、非
イントラマクロブロック用の量子化マトリックスデータ
の存在を示すデータである。non_intra_quantiser_matr
ixは、非イントラマクロブロック用の量子化マトリック
スの値を表すデータである。load_chroma_intra_quanti
ser_matrixは、色差イントラマクロブロック用の量子化
マトリックス・データの存在を示すデータである。chro
ma_intra_quantiser_matrixは、色差イントラマクロブ
ロック用の量子化マトリックスの値を示すデータであ
る。load_chroma_non_intra_quantiser_matrixは、色差
非イントラマクロブロック用の量子化マトリックス・デ
ータの存在を示すデータである。chroma_non_intra_qua
ntiser_matrixは、色差非イントラマクロブロック用の
量子化マトリックスの値を示すデータである。
[0357] load_non_intra_quantiser_matrix is data indicating the existence of quantization matrix data for a non-intra macroblock. non_intra_quantiser_matr
ix is data representing a value of a quantization matrix for a non-intra macroblock. load_chroma_intra_quanti
ser_matrix is data indicating the existence of quantization matrix data for a chrominance intra macroblock. chro
ma_intra_quantiser_matrix is data indicating a value of a quantization matrix for a chroma intra macroblock. load_chroma_non_intra_quantiser_matrix is data indicating the existence of quantization matrix data for a chrominance non-intra macroblock. chroma_non_intra_qua
ntiser_matrix is data indicating a value of a quantization matrix for a color difference non-intra macroblock.

【0358】copyright_extension()関数によって定義
されるデータエレメントは、図57に示すように、 ext
ension_start_code、extension_start_code_itentifie
r、copyright_extension_present_flag、copyright_fla
g、copyright_identifier、original_or_copy、copyrig
ht_number_1、copyright_number_2、及び copyright_nu
mber_3から構成される。
The data element defined by the copyright_extension () function is, as shown in FIG.
extension_start_code, extension_start_code_itentifie
r, copyright_extension_present_flag, copyright_fla
g, copyright_identifier, original_or_copy, copyrig
ht_number_1, copyright_number_2, and copyright_nu
Consists of mber_3.

【0359】extension_start_codeは、コピーライトエ
クステンションのスタート示す開始コードである。exte
nsion_start_code_itentifierどのエクステンションデ
ータが送られるかを示すコードである。 copyright_ext
ension_present_flagは、このコピーライトエクステン
ション内のデータエレメントが有効か無効かを示すため
のデータである。
[0359] extension_start_code is a start code indicating the start of the copyright extension. exte
nsion_start_code_itentifier This is a code indicating which extension data is sent. copyright_ext
The extension_present_flag is data for indicating whether the data element in the copyright extension is valid or invalid.

【0360】copyright_flagは、次のコピーライトエク
ステンション又はシーケンスエンドまで、符号化された
ビデオデータに対してコピー権が与えられているか否か
を示す。copyright_identifierは、ISO/IEC JTC/SC29に
よって指定されたコピー権の登録機関を識別するための
データである。original_or_copyは、ビットストリーム
中のデータが、オリジナルデータであるかコピーデータ
であるかを示すデータである。copyright_number_1は、
コピーライトナンバーのビット44から63を表わすデ
ータである。copyright_number_2は、コピーライトナン
バーのビット22から43を表わすデータである。copy
right_number_3は、コピーライトナンバーのビット0か
ら21を表わすデータである。
[0360] copyright_flag indicates whether or not the copy right has been granted to the encoded video data until the next copyright extension or sequence end. copyright_identifier is data for identifying the registration authority of the copy right specified by ISO / IEC JTC / SC29. original_or_copy is data indicating whether the data in the bit stream is original data or copy data. copyright_number_1
Data representing bits 44 to 63 of the copyright number. copyright_number_2 is data representing bits 22 to 43 of the copyright number. copy
right_number_3 is data representing bits 0 to 21 of the copyright number.

【0361】picture_display_extension()関数によっ
て定義されるデータエレメントは、図58に示すよう
に、extension_start_code_identifier、frame_center_
horizontal_offset、frame_center_vertical_offset等
である。
As shown in FIG. 58, the data elements defined by the picture_display_extension () function are extension_start_code_identifier, frame_center_
horizontal_offset, frame_center_vertical_offset, etc.

【0362】extension_start_code_identifierは、ど
の拡張データが送られるかを示すコードである。 frame
_center_horizontal_offsetは、表示エリアの水平方向
のオフセットを示すデータであって、number_of_frame_
center_offsetsによって定義される数のオフセット値を
定義することができる。frame_center_vertical_offset
は、表示エリアを垂直方向のオフセットを示すデータで
あって、 number_of_frame_center_offsetsによって定
義される数のオフセット値を定義することができる。
[0362] The extension_start_code_identifier is a code indicating which extension data is to be sent. frame
_center_horizontal_offset is data indicating the horizontal offset of the display area, and number_of_frame_
You can define a number of offset values defined by center_offsets. frame_center_vertical_offset
Is data indicating the vertical offset of the display area, and can define the number of offset values defined by number_of_frame_center_offsets.

【0363】再び図47に戻って、extension_and_user
_data(2)関数によって定義されるデータエレメントの次
には、picture_data()関数によって定義されるデータエ
レメントが、履歴ストリームとして記述されている。但
し、このpicture_data()関数は、red_bw_flagが1では
ないか、または、red_bw_indicatorが2以下である場合
に存在する。このred_bw_flagとred_bw_indicatorは、r
e_coding_stream_info()関数に記述されており、これら
については、図71と図72を参照して後述する。
Returning to FIG. 47 again, extension_and_user
Following the data element defined by the _data (2) function, the data element defined by the picture_data () function is described as a history stream. However, this picture_data () function exists when red_bw_flag is not 1 or red_bw_indicator is 2 or less. This red_bw_flag and red_bw_indicator are r
These are described in the e_coding_stream_info () function, which will be described later with reference to FIGS. 71 and 72.

【0364】picture_data()関数によって定義されるデ
ータエレメントは、図59に示すように、slice()関数
によって定義されるデータエレメントである。このslic
e()関数によって定義されるデータエレメントはビット
ストリーム中に少なくとも1個記述されている。
The data element defined by the picture_data () function is a data element defined by the slice () function, as shown in FIG. This slic
At least one data element defined by the e () function is described in the bit stream.

【0365】slice()関数は、図60に示されるよう
に、slice_start_code、slice_quantiser_scale_code、
intra_slice_flag、intra_slice、reserved_bits、extr
a_bit_slice、extra_information_slice、及びextra_bi
t_slice 等のデータエレメントと、macroblock()関数に
よって定義されるデータエレメントを、履歴ストリーム
として記述するための関数である。
[0365] As shown in Fig. 60, the slice () function includes slice_start_code, slice_quantiser_scale_code,
intra_slice_flag, intra_slice, reserved_bits, extr
a_bit_slice, extra_information_slice, and extra_bi
This is a function for describing a data element such as t_slice and a data element defined by the macroblock () function as a history stream.

【0366】slice_start_codeは、slice()関数によっ
て定義されるデータエレメントのスタートを示すスター
トコードである。slice_quantiser_scale_codeは、この
スライス層に存在するマクロブロックに対して設定され
た量子化ステップサイズを示すデータである。しかし、
各マクロブロック毎に、quantiser_scale_codeが設定さ
れている場合には、各マクロブロックに対して設定され
たmacroblock_quantiser_scale_codeのデータが優先し
て使用される。
[0366] slice_start_code is a start code indicating the start of a data element defined by the slice () function. slice_quantiser_scale_code is data indicating a quantization step size set for a macroblock existing in this slice layer. But,
When quantizer_scale_code is set for each macroblock, the macroblock_quantiser_scale_code data set for each macroblock is used with priority.

【0367】intra_slice_flagは、ビットストリーム中
にintra_slice及びreserved_bitsが存在するか否かを示
すフラグである。intra_sliceは、スライス層中にノン
イントラマクロブロックが存在するか否かを示すデータ
である。スライス層におけるマクロブロックのいずれか
がノンイントラマクロブロックである場合には、intra_
sliceは「0」となり、スライス層におけるマクロブロ
ックの全てがノンイントラマクロブロックである場合に
は、intra_sliceは「1」となる。reserved_bitsは、7
ビットのデータであって「0」の値を取る。extra_bit_
sliceは、履歴ストリームとして追加の情報が存在する
ことを示すフラグであって、次にextra_information_sl
iceが存在する場合には「1」に設定される。追加の情
報が存在しない場合には「0」に設定される。
[0367] The intra_slice_flag is a flag indicating whether or not intra_slice and reserved_bits exist in the bit stream. intra_slice is data indicating whether or not a non-intra macroblock exists in the slice layer. If any of the macroblocks in the slice layer is a non-intra macroblock, intra_
slice is “0”, and when all of the macroblocks in the slice layer are non-intra macroblocks, intra_slice is “1”. reserved_bits is 7
It is bit data and takes a value of "0". extra_bit_
slice is a flag indicating that additional information exists as a history stream, and then extra_information_sl
If ice exists, it is set to “1”. If there is no additional information, it is set to “0”.

【0368】これらのデータエレメントの次には、macr
oblock()関数によって定義されたデータエレメントが、
履歴ストリームとして記述されている。
Following these data elements, macr
The data element defined by the oblock () function
It is described as a history stream.

【0369】macroblock()関数は、図61に示すよう
に、macroblock_escape、macroblock_address_incremen
t、及びmacroblock_quantiser_scale_code、及びmarker
_bit等のデータエレメントと、macroblock_modes()関
数、motion_vectors(s)関数、及びcode_block_patter
n()関数によって定義されたデータエレメントを記述す
るための関数である。
As shown in FIG. 61, the macroblock () function includes macroblock_escape and macroblock_address_incremen.
t, macroblock_quantiser_scale_code, and marker
data elements such as _bit, macroblock_modes () function, motion_vectors (s) function, and code_block_patter
This is a function for describing the data element defined by the n () function.

【0370】macroblock_escapeは、参照マクロブロッ
クと前のマクロブロックとの水平方向の差が34以上で
あるか否かを示す固定ビット列である。参照マクロブロ
ックと前のマクロブロックとの水平方向の差が34以上
の場合には、macroblock_address_incrementの値に33
をプラスする。macroblock_address_incrementは、参照
マクロブロックと前のマクロブロックとの水平方向の差
を示すデータである。もし、このmacroblock_address_i
ncrementの前にmacroblock_escapeが1つ存在するので
あれば、このmacroblock_address_incrementの値に33
をプラスした値が、実際の参照マクロブロックと前のマ
クロブロックとの水平方向の差分を示すデータとなる。
[0370] macroblock_escape is a fixed bit string indicating whether or not the horizontal difference between the reference macroblock and the previous macroblock is 34 or more. If the horizontal difference between the reference macroblock and the previous macroblock is 34 or more, the macroblock_address_increment value is set to 33.
Plus macroblock_address_increment is data indicating a horizontal difference between the reference macroblock and the previous macroblock. If this macroblock_address_i
If there is one macroblock_escape before ncrement, the value of this macroblock_address_increment is 33
Is the data indicating the horizontal difference between the actual reference macroblock and the previous macroblock.

【0371】macroblock_quantiser_scale_codeは、各
マクロブロック毎に設定された量子化ステップサイズで
あり、macroblock_quantが”1”のときだけ存在する。
各スライス層には、スライス層の量子化ステップサイズ
を示すslice_quantiser_scale_codeが設定されている
が、参照マクロブロックに対してmacroblock_quantiser
_scale_codeが設定されている場合には、この量子化ス
テップサイズを選択する。
[0371] macroblock_quantiser_scale_code is a quantization step size set for each macroblock, and exists only when macroblock_quant is "1".
In each slice layer, slice_quantiser_scale_code indicating the quantization step size of the slice layer is set, but macroblock_quantiser
If _scale_code is set, this quantization step size is selected.

【0372】macroblock_address_incrementの次には、
macroblock_modes()関数によって定義されるデータエレ
メントが記述されている。macroblock_modes()関数は、
図62に示すように、macroblock_type、frame_motion_
type、field_motion_type、dct_type等のデータエレメ
ントを、履歴ストリームとして記述するための関数であ
る。
After macroblock_address_increment,
Describes a data element defined by the macroblock_modes () function. macroblock_modes () function
As shown in FIG. 62, macroblock_type, frame_motion_
This is a function for describing data elements such as type, field_motion_type, and dct_type as a history stream.

【0373】macroblock_typeは、マクログブロックの
符号化タイプを示すデータである。その詳細は、図65
乃至図67を参照して後述する。
[0373] macroblock_type is data indicating the coding type of the macroblock. The details are shown in FIG.
It will be described later with reference to FIG.

【0374】もし、macroblock_motion_forward又はmac
roblock_motion_backwardが「1」であり、ピクチャ構
造がフレームであり、さらにframe_pred_frame_dctが
「0」である場合には、macroblock_typeを表わすデー
タエレメントの次にframe_motion_typeを表わすデータ
エレメントが記述されている。尚、このframe_pred_fra
me_dctは、 frame_motion_typeがビットストリーム中に
存在するか否かを示すフラグである。
If macroblock_motion_forward or mac
When roblock_motion_backward is “1”, the picture structure is a frame, and frame_pred_frame_dct is “0”, a data element representing frame_motion_type is described next to a data element representing macroblock_type. This frame_pred_fra
me_dct is a flag indicating whether or not frame_motion_type exists in the bit stream.

【0375】frame_motion_typeは、フレームのマクロ
ブロックの予測タイプを示す2ビットのコードである。
予測ベクトルが2個でフィールドベースの予測タイプで
あれば「00」であって、予測ベクトルが1個でフィー
ルドベースの予測タイプであれば「01」であって、予
測ベクトルが1個でフレームベースの予測タイプであれ
ば「10」であって、予測ベクトルが1個でディアルプ
ライムの予測タイプであれば「11」である。
[0375] frame_motion_type is a 2-bit code indicating the prediction type of the macroblock of the frame.
If the number of prediction vectors is two and the field-based prediction type is “00”, if the number of prediction vectors is one and the field-based prediction type is “01”, the number of prediction vectors is one and the frame is base Is "10" for the prediction type of "1", and "11" for the prediction type of one prediction vector and dual prime.

【0376】frame_motion_typeを記述する条件が満足
されない場合には、macroblock_typeを表わすデータエ
レメントの次にfield_motion_typeを表わすデータエレ
メントが記述されている。
If the condition for describing frame_motion_type is not satisfied, a data element representing field_motion_type is described next to a data element representing macroblock_type.

【0377】field_motion_typeは、フィールドのマク
ロブロックの動き予測を示す2ビットのコードである。
予測ベクトルが1個でフィールドベースの予測タイプで
あれば「01」であって、予測ベクトルが2個で18×
8マクロブロックベースの予測タイプであれば「10」
であって、予測ベクトルが1個でディアルプライムの予
測タイプであれば「11」である。
[0377] field_motion_type is a 2-bit code indicating motion prediction of a field macroblock.
If the number of prediction vectors is one and the field-based prediction type is “01”, the prediction vector is 18 ×
"10" for prediction type based on 8 macroblocks
And if the number of prediction vectors is one and the prediction type is dual prime, it is “11”.

【0378】もし、ピクチャ構造がフレームで、 frame
_pred_frame_dctがframe_motion_typeがビットストリー
ム中に存在することを示し、且つ、frame_pred_frame_d
ctがdct_typeがビットストリーム中に存在することを示
している場合には、macroblock_typeを表わすデータエ
レメントの次にdct_typeを表わすデータエレメントが記
述されている。尚、dct_typeは、DCTがフレームDCTモー
ドか、フィールドDCTモードかを示すデータである。
If the picture structure is a frame,
_pred_frame_dct indicates that frame_motion_type exists in the bit stream, and frame_pred_frame_d
When ct indicates that dct_type exists in the bit stream, a data element representing dct_type is described next to a data element representing macroblock_type. Note that dct_type is data indicating whether the DCT is a frame DCT mode or a field DCT mode.

【0379】再び図61に戻って、もし、参照マクロブ
ロックが前方予測マクロブロックであるか、又は参照マ
クロブロックがイントラマクロブロックであって且つコ
ンシール処理のマクロブロックのいずれかの場合には、
motion_vectors(0)関数によって定義されるデータエレ
メントが記述される。また、参照マクロブロックが後方
予測マクロブロックである場合には、motion_vectors
(1)関数によって定義されるデータエレメントが記述さ
れる。尚、 motion_vectors(0)関数は、第1番目の動き
ベクトルに関するデータエレメントを記述するための関
数であって、motion_vectors(1)関数は、第2番目の動
きベクトルに関するデータエレメントを記述するための
関数である。
Referring back to FIG. 61, if the reference macroblock is a forward prediction macroblock, or if the reference macroblock is an intra macroblock and any of the concealed macroblocks,
A data element defined by the motion_vectors (0) function is described. If the reference macroblock is a backward prediction macroblock, motion_vectors
(1) A data element defined by a function is described. The motion_vectors (0) function is a function for describing a data element relating to a first motion vector, and the motion_vectors (1) function is a function for describing a data element relating to a second motion vector. It is.

【0380】motion_vectors(s)関数は、図63に示さ
れるように、動きベクトルに関するデータエレメントを
記述するための関数である。
The motion_vectors (s) function is a function for describing a data element relating to a motion vector, as shown in FIG.

【0381】もし、動きベクトルが1個でディアルプラ
イム予測モードを使用していない場合には、motion_ver
tical_field_select[0][s]とmotion_vector(0,s)によっ
て定義されるデータエレメントが記述される。
If the number of motion vectors is one and the dual prime prediction mode is not used, motion_ver
A data element defined by tical_field_select [0] [s] and motion_vector (0, s) is described.

【0382】このmotion_vertical_field_select[r][s]
は、第1番目の動きベクトル(前方又は後方のどちらの
ベクトルであっても良い)が、ボトムフィールドを参照
して作られたベクトルであるかトップフィールドを参照
して作られたベクトルであるかを示すフラグである。こ
の指標“r”は、第1番めのベクトル又は第2番めのベ
クトルのいずれのベクトルであるかを示す指標であっ
て、“s”は、予測方向が前方又は後方予測のいずれで
あるかを示す指標である。
[0382] This motion_vertical_field_select [r] [s]
Indicates whether the first motion vector (whichever vector is forward or backward) is a vector created with reference to the bottom field or a vector created with reference to the top field Is a flag that indicates The index “r” is an index indicating which vector is the first vector or the second vector, and “s” is whether the prediction direction is forward or backward prediction. It is an index that indicates

【0383】motion_vector(r,s)関数は、図64に示さ
れるように、motion_code[r][s][t]に関するデータ列
と、motion_residual[r][s][t]に関するデータ列と、dm
vector[t]を表わすデータとを記述するための関数であ
る。
As shown in FIG. 64, the motion_vector (r, s) function includes a data string relating to motion_code [r] [s] [t], a data string relating to motion_residual [r] [s] [t], dm
This is a function for describing data representing vector [t].

【0384】motion_code[r][s][t]は、動きベクトルの
大きさを−16〜+16の範囲で表わす可変長のデータ
である。 motion_residual[r][s][t]は、動きベクトル
の残差を表わす可変長のデータである。よって、このmo
tion_code[r][s][t]と motion_residual[r][s][t]との
値によって詳細な動きベクトルを記述することができ
る。 dmvector[t]は、ディユアルプライム予測モードの
ときに、一方のフィールド(例えばボトムフィールドに
対してトップフィールドを一方のフィールドとする)に
おける動きベクトルを生成するために、時間距離に応じ
て既存の動きベクトルがスケールされると共に、トップ
フィールドとボトムフィールドとのライン間の垂直方向
のずれを反映させるために垂直方向に対して補正を行う
データである。この指標“r”は、第1番めのベクトル
又は第2番めのベクトルのいずれのベクトルであるかを
示す指標であって、“s”は、予測方向が前方又は後方
予測のいずれであるかを示す指標である。“s”は、動
きベクトルが垂直方向の成分であるか水平方向の成分で
あるかを示すデータである。
[0384] motion_code [r] [s] [t] is variable-length data representing the magnitude of a motion vector in the range of -16 to +16. motion_residual [r] [s] [t] is variable-length data representing a residual of a motion vector. So this mo
A detailed motion vector can be described by the values of tion_code [r] [s] [t] and motion_residual [r] [s] [t]. dmvector [t] is used in dual prime prediction mode to generate a motion vector in one field (for example, the top field is one field with respect to the bottom field). Are scaled, and are corrected in the vertical direction to reflect the vertical shift between the lines of the top field and the bottom field. The index “r” is an index indicating which vector is the first vector or the second vector, and “s” is whether the prediction direction is forward or backward prediction. It is an index that indicates “S” is data indicating whether the motion vector is a vertical component or a horizontal component.

【0385】図64に示されmotion_vector(r,s)関数に
よって、まず、水平方向のmotion_coder[r][s][0]を表
わすデータ列が、履歴ストリームとして記述される。mo
tion_residual[0][s][t]及びmotion_residual[1][s][t]
の双方のビット数は、f_code[s][t]で示されるので、 f
_code[s][t]が1でない場合には、 motion_residual[r]
[s][t] がビットストリーム中に存在することを示すこ
とになる。水平方向成分のmotion_residual[r][s][0]が
「1」でなくて、水平方向成分のmotion_code[r][s][0]
が「0」でないということは、ビットストリーム中にmo
tion_residual[r][s][0]を表わすデータエレメントが存
在し、動きベクトルの水平方向成分が存在するというこ
とを意味しているので、その場合には、水平方向成分の
motion_residual[r][s][0]を表わすデータエレメントが
記述されている。
First, a data string representing motion_coder [r] [s] [0] in the horizontal direction is described as a history stream by the motion_vector (r, s) function shown in FIG. mo
tion_residual [0] [s] [t] and motion_residual [1] [s] [t]
Since the number of bits of both is indicated by f_code [s] [t], f
motion_residual [r] if _code [s] [t] is not 1
This indicates that [s] [t] is present in the bitstream. Motion_residual [r] [s] [0] of the horizontal component is not “1” and motion_code [r] [s] [0] of the horizontal component
Is not "0" means that mo
data_residual [r] [s] [0] exists, which means that the horizontal component of the motion vector exists.
A data element representing motion_residual [r] [s] [0] is described.

【0386】続いて、垂直方向のmotion_coder[r][s]
[1]を表わすデータ列が、履歴ストリームとして記述さ
れる。同じようにmotion_residual[0][s][t]及びmotion
_residual[1][s][t]の双方のビット数は、f_code[s][t]
で示されるので、 f_code[s][t]が1でない場合には、
motion_residual[r][s][t] がビットストリーム中に存
在することを表わすことになる。motion_residual[r]
[s][1]が「1」でなくて、motion_code[r][s][1]が
「0」でないということは、ビットストリーム中にmoti
on_residual[r][s][1]を表わすデータエレメントが存在
し、動きベクトルの垂直方向成分が存在するということ
を意味しているので、その場合には、垂直方向成分のmo
tion_residual[r][s][1]を表わすデータエレメントが記
述されている。
Subsequently, motion_coder [r] [s] in the vertical direction
A data string representing [1] is described as a history stream. Similarly, motion_residual [0] [s] [t] and motion
The number of bits of both _residual [1] [s] [t] is f_code [s] [t]
In the case that f_code [s] [t] is not 1,
This indicates that motion_residual [r] [s] [t] is present in the bitstream. motion_residual [r]
That [s] [1] is not “1” and motion_code [r] [s] [1] is not “0” means that the moti
Since there is a data element representing on_residual [r] [s] [1], which means that the vertical component of the motion vector exists, in that case, the mo component of the vertical component
A data element representing tion_residual [r] [s] [1] is described.

【0387】次に、図65乃至図67を参照して、macr
oblock_typeについて説明する。macroblock_typeは、ma
croblock_quant、dct_type_flag、macroblock_motion_f
orward、及びmacroblock_motion_backwardなどのフラグ
から生成された可変長データである。 macroblock_quan
tは、マクロブロックに対して量子化ステップサイズを
設定するためのmacroblock_quantiser_scale_codeが設
定されているか否かを示すフラグあって、ビットストリ
ーム中にmacroblock_quantiser_scale_codeが存在する
場合には、 macroblock_quantは「1」の値を取る。
Next, referring to FIG. 65 to FIG.
The oblock_type will be described. macroblock_type is ma
croblock_quant, dct_type_flag, macroblock_motion_f
Variable length data generated from flags such as orward and macroblock_motion_backward. macroblock_quan
t is a flag indicating whether or not macroblock_quantiser_scale_code for setting a quantization step size for a macroblock is set. If macroblock_quantiser_scale_code is present in the bit stream, macroblock_quant is a value of “1”. I take the.

【0388】dct_type_flagは、参照マクロブロックが
フレームDCT又はフィールドDCTで符号化されているかを
示すdct_typeが存在するか否かを示すためのフラグ(言
い換えるとDCTされているか否かを示すフラグ)であっ
て、ビットストリーム中にdct_typeが存在する場合に
は、このdct_type_flagは「1」の値を取る。 macroblo
ck_motion_forwardは、参照マクロブロックが前方予測
されているか否かを示すフラグであって、前方予測され
ている場合には「1」の値を取る。macroblock_motion_
backwardは、参照マクロブロックが後方予測されている
か否かを示すフラグであって、後方予測されている場合
には「1」の値を取る。
[0388] dct_type_flag is a flag indicating whether there is a dct_type indicating whether the reference macroblock is encoded by the frame DCT or the field DCT (in other words, a flag indicating whether the reference macroblock is DCT). If dct_type exists in the bit stream, dct_type_flag takes a value of “1”. macroblo
ck_motion_forward is a flag indicating whether or not the reference macroblock is predicted forward, and takes a value of “1” when the reference macroblock is predicted forward. macroblock_motion_
backward is a flag indicating whether or not the reference macroblock is backward predicted, and takes a value of “1” when backward predicted.

【0389】なお、可変長フォーマットにおいては、伝
送するビットレートを減少させるために、履歴情報を削
減することができる。
In the variable-length format, history information can be reduced in order to reduce the bit rate to be transmitted.

【0390】すなわち、macroblock_typeとmotion_vect
ors()は転送するが、quantiser_scale_codeを転送しな
い場合には、slice_quantiser_scale_codeを”0000
0”とすることで、ビットレートを減少させることがで
きる。
That is, the macroblock_type and motion_vect
When ors () is transferred but quantizer_scale_code is not transferred, slice_quantiser_scale_code is set to “0000”.
By setting it to 0 ", the bit rate can be reduced.

【0391】また、macroblock_typeのみ転送し、motio
n_vectors()、quantiser_scale_code、およびdct_type
を転送しない場合には、macroblock_typeとして、”not
coded”を使用することで、ビットレートを減少するこ
とができる。
Also, only macroblock_type is transferred, and motio
n_vectors (), quantiser_scale_code, and dct_type
Is not transferred, macroblock_type is set to "not
By using "coded", the bit rate can be reduced.

【0392】さらにまた、picture_coding_typeのみ転
送し、slice()以下の情報は全て転送しない場合には、s
lice_start_codeを持たないpicture_data()を使用する
ことで、ビットレートを減少させることができる。
Further, when only picture_coding_type is transferred and all information after slice () is not transferred, s
By using picture_data () without lice_start_code, the bit rate can be reduced.

【0393】以上においては、user_data内の23ビッ
トの連続する”0”が出ないようにする場合に、22ビ
ット毎に”1”を挿入するようにしたが、22ビット毎
でなくてもよい。また、連続する”0”の個数を数え
て”1”を挿入するのではなく、Byte_allignを調べて
挿入するようにすることも可能である。
In the above description, in order to prevent consecutive 23-bit "0" in user_data from being output, "1" is inserted every 22 bits, but it is not limited to every 22 bits. . Also, instead of counting the number of consecutive “0” and inserting “1”, Byte_allign can be checked and inserted.

【0394】さらに、MPEGにおいては、23ビットの連
続する”0”の発生を禁止しているが、実際には、バイ
トの先頭から23ビット連続する場合だけが問題とさ
れ、バイトの先頭ではなく、途中から0が23ビット連
続する場合は、問題とされない。従って、例えば24ビ
ット毎に、LSB以外の位置に”1”を挿入するようにし
てもよい。
Furthermore, in MPEG, the generation of consecutive 23-bit "0" is prohibited. However, in practice, only the case where 23 bits continue from the head of a byte is considered as a problem. If 0 bits continue for 23 bits from the middle, no problem occurs. Therefore, for example, "1" may be inserted at a position other than the LSB every 24 bits.

【0395】また、以上においては、履歴情報を、vide
o elementary streamに近い形式にしたが、packetized
elementary streamやtransport streamに近い形式にし
てもよい。また、Elementary Streamのuser_dataの場所
を、picture_dataの前としたが、他の場所にすることも
できる。
In the above description, the history information is stored in vide
o Format is close to elementary stream, but packetized
The format may be close to the elementary stream or the transport stream. Although the location of the user_data of the Elementary Stream is before the picture_data, it can be another location.

【0396】図15のトランスコーダ101において
は、4世代分の符号化パラメータを履歴情報として後段
に出力するようにしたが、実際には、履歴情報の全てが
必要となるわけではなく、アプリケーション毎に必要な
履歴情報は異なってくる。また、実際の伝送路あるいは
記録媒体(伝送メディア)には、容量に制限があり、圧
縮しているとはいえ、全ての履歴情報を伝送するように
すると、容量的に負担となり、結果的に画像ビットスト
リームのビットレートを抑圧してしまい、履歴情報伝送
の有効性が損なわれることになる。
In the transcoder 101 shown in FIG. 15, the encoding parameters for four generations are output as history information at the subsequent stage. However, not all of the history information is actually required. The required history information will be different. In addition, the capacity of an actual transmission path or recording medium (transmission medium) is limited. Even if the history information is compressed, transmitting all the history information imposes a load on the capacity. The bit rate of the image bit stream is suppressed, and the effectiveness of history information transmission is impaired.

【0397】そこで、履歴情報として伝送する項目の組
み合わせを記述する記述子を履歴情報に組み込んで後段
に送信するようにし、全ての履歴情報を伝送するのでは
なく、様々なアプリケーションに対応した情報を伝送す
るようにすることができる。図68は、このような場合
のトランスコーダ101の構成例を表している。
[0397] Therefore, a descriptor describing a combination of items to be transmitted as history information is incorporated in the history information and transmitted at a later stage, so that information corresponding to various applications is transmitted instead of transmitting all the history information. It can be transmitted. FIG. 68 illustrates a configuration example of the transcoder 101 in such a case.

【0398】図68において、図15における場合と対
応する部分には同一の符号を付してあり、その説明は適
宜省略する。図68の構成例においては、ヒストリ情報
分離装置105と符号化装置106の間、及びヒストリ
エンコーディング装置107と符号化装置106の間
に、符号化パラメータ選択回路501が挿入されてい
る。
In FIG. 68, portions corresponding to those in FIG. 15 are denoted by the same reference numerals, and description thereof will be omitted as appropriate. In the configuration example of FIG. 68, an encoding parameter selection circuit 501 is inserted between the history information separating device 105 and the encoding device 106 and between the history encoding device 107 and the encoding device 106.

【0399】符号化パラメータ選択回路501は、ヒス
トリ情報分離装置105が出力するベースバンドビデオ
信号から符号化パラメータを算出する符号化パラメータ
算出部512、ヒストリ情報分離装置105が出力す
る、このトランスコーダ101において、符号化するの
に最適と判定された符号化パラメータ(例えば、第2世
代の符号化パラメータ)に関する情報から、符号化パラ
メータと記述子(red_bw_flag,red_bw_indicator)
(図72を参照して後述する)を分離する組合せ記述子
分離部511、並びに符号化パラメータ算出部512が
出力する符号化パラメータと、組合せ記述子分離部51
1が出力する符号化パラメータのうち、いずれか一方
を、組合せ記述子分離部511で分離された記述子に対
応して選択し、符号化装置106に出力するスイッチ5
13を有している。その他の構成は、図15における場
合と同様である。
An encoding parameter selection circuit 501 calculates an encoding parameter from a baseband video signal output from the history information separating device 105, and an encoding parameter calculating section 512. The transcoder 101 outputs from the history information separating device 105. , The coding parameters and the descriptors (red_bw_flag, red_bw_indicator) are obtained from information on the coding parameters determined to be optimal for coding (for example, second-generation coding parameters).
(To be described later with reference to FIG. 72), a combination descriptor separation unit 511, a coding parameter output from the coding parameter calculation unit 512, and a combination descriptor separation unit 51.
1 is selected according to the descriptor separated by the combination descriptor separation unit 511, and the switch 5 is output to the coding device 106.
13. Other configurations are the same as those in FIG.

【0400】ここで、履歴情報として伝送する項目の組
み合わせについて説明する。履歴情報は、分類すると、
picture単位の情報と、macroblock単位の情報に分ける
ことができる。slice単位の情報は、それに含まれるmac
roblockの情報を収集することで得ることができ、GOP単
位の情報は、それに含まれるpicture単位の情報を収集
することで得ることができる。
[0400] Here, the combination of items transmitted as history information will be described. Historical information can be categorized as
The information can be divided into picture unit information and macroblock unit information. The information of the slice unit is the mac included in it.
The information can be obtained by collecting the information of the roblock, and the information of the GOP unit can be obtained by collecting the information of the picture unit included therein.

【0401】picture単位の情報は、1フレーム毎に1
回伝送されるだけなので、情報伝送に占めるビットレー
トは、それほど大きくはない。これに対して、macroblo
ck単位の情報は、各macroblock毎に伝送されるため、例
えば1フレームの走査線数が525本で、フィールドレ
ートが60フィールド/秒のビデオシステムの場合、1
フレームの画素数を720×480とすると、macroblo
ck単位の情報は、1フレームあたり1350(=(72
0/16)×(480/16))回伝送することが必要と
なる。このため、履歴情報の相当の部分がmacroblock毎
の情報で占められることになる。そこで、履歴情報とし
ては、少なくともpicture単位の情報は常に伝送する
が、macroblock単位の情報は、アプリケーションに応じ
て選択して伝送するようにすることで、伝送する情報量
を抑制することができる。
[0401] The information in picture units is one for each frame.
Since the data is transmitted only once, the bit rate occupying the information transmission is not so large. In contrast, macroblo
Since information in units of ck is transmitted for each macroblock, for example, in a video system in which the number of scanning lines in one frame is 525 and the field rate is 60 fields / sec, 1
If the number of pixels in the frame is 720 × 480, macroblo
The information in units of ck is 1350 (= (72
0/16) × (480/16)) transmissions. Therefore, a considerable part of the history information is occupied by information for each macroblock. Therefore, as the history information, at least the information in picture units is always transmitted, but the information in macroblock units is selected and transmitted according to the application, so that the amount of information to be transmitted can be suppressed.

【0402】履歴情報として転送されるmacroblock単位
の情報には、例えばnum_coef_bits,num_mv_bits,num_
other_bits,q_scale_code,q_scale_type,motion_typ
e,mv_vert_field_sel[][],mv[][][],mb_mfwd,mb_mb
wd,mb_pattern,coded_block_pattern,mb_intra,sli
ce_start,dct_type,mb_quant,skipped_mbなどがあ
る。これらは、macroblock rate informationの要素を
用いて表現されたものである。
[0402] Information in macroblock units transferred as history information includes, for example, num_coef_bits, num_mv_bits, num_
other_bits, q_scale_code, q_scale_type, motion_typ
e, mv_vert_field_sel [] [], mv [] [] [], mb_mfwd, mb_mb
wd, mb_pattern, coded_block_pattern, mb_intra, sli
There are ce_start, dct_type, mb_quant, skipped_mb, etc. These are expressed using elements of macroblock rate information.

【0403】num_coef_bitsは、macroblockの符号量の
うち、DCT係数に要した符号量を表す。num_mv_bitsは、
macroblockの符号量のうち、動きベクトルに要した符号
量を表す。num_other_bitsは、macroblockの符号量のう
ち、num_coef_bits及びnum_mv_bits以外の符号量を表
す。
Num_coef_bits represents the code amount required for the DCT coefficient among the code amounts of the macroblock. num_mv_bits is
Indicates the amount of code required for the motion vector among the amounts of code of the macroblock. num_other_bits represents a code amount other than num_coef_bits and num_mv_bits in the code amount of the macroblock.

【0404】q_scale_codeは、macroblockに適用された
q_scale_codeを表す。motion_typeは、macroblockに適
用された動きベクトルのtypeを表す。mv_vert_field_se
l[][]は、macroblockに適用された動きベクトルのfield
selectを表す。
[0404] The q_scale_code is applied to the macroblock.
Represents q_scale_code. motion_type represents the type of the motion vector applied to the macroblock. mv_vert_field_se
l [] [] is the field of the motion vector applied to the macroblock
Represents select.

【0405】mv[][][]は、macroblockに適用された動き
ベクトルを表す。mb_mfwdは、macroblockの予測モード
が前方向予測であることを示すフラグである。mb_mbwd
は、macroblockの予測モードが後方向予測であることを
示すフラグである。mb_patternは、macroblockのDCT係
数の非0のものの有無を示すフラグである。
[0405] mv [] [] [] represents a motion vector applied to a macroblock. mb_mfwd is a flag indicating that the prediction mode of the macroblock is forward prediction. mb_mbwd
Is a flag indicating that the prediction mode of the macroblock is backward prediction. mb_pattern is a flag indicating the presence or absence of a non-zero DCT coefficient of the macroblock.

【0406】coded_block_patternは、macroblockのDCT
係数の非0のものの有無をDCTブロック毎に示すフラグ
である。mb_intraは、macroblockがintra_macroかそう
でないかを示すフラグである。slice_startは、macrobl
ockがsliceの先頭であるか否かを示すフラグである。dc
t_typeは、macroblockがfield_dctかflame_dctかを示す
フラグである。
The coded_block_pattern is the DCT of the macroblock.
This flag indicates whether or not there is a non-zero coefficient for each DCT block. mb_intra is a flag indicating whether the macroblock is intra_macro or not. slice_start is macrobl
This is a flag indicating whether or not ock is the head of slice. dc
t_type is a flag indicating whether the macroblock is field_dct or flame_dct.

【0407】mb_quantは、macroblockがquantiser_scal
e_codeを伝送するか否かを示すフラグである。skipped_
mbは、macroblockがskipped macroblockであるか否かを
示すフラグである。
[0407] For mb_quant, the macroblock is quantizer_scal.
This is a flag indicating whether or not to transmit e_code. skipped_
mb is a flag indicating whether the macroblock is a skipped macroblock.

【0408】これらの項目は、常に全て必要であるわけ
ではなく、アプリケーションに応じて必要となる項目が
変化する。例えば、num_coef_bitsやslice_startといっ
た項目は、再エンコードした際のビットストリームをで
きる限り元の形に戻したいというtransparentという要
求を有するアプリケーションにおいて必要となる。換言
すれば、ビットレートを変更するようなアプリケーショ
ンにおいては、これらの項目は必要ではない。また、非
常に伝送路の制限が厳しい場合には、各ピクチャの符号
化タイプが判るだけでもよいようなアプリケーションも
存在する。このような状況から、履歴情報を伝送する項
目の組み合わせの例として、例えば図69に示すような
組み合わせが考えられる。
[0408] All these items are not always necessary, and the necessary items change depending on the application. For example, items such as num_coef_bits and slice_start are necessary for an application having a request of “transparent” to restore a bit stream after re-encoding as much as possible. In other words, these items are not necessary in an application that changes the bit rate. Also, there are applications in which when the transmission path is extremely restricted, it is only necessary to know the coding type of each picture. From such a situation, for example, a combination as shown in FIG. 69 can be considered as an example of a combination of items for transmitting history information.

【0409】図69において、各組み合わせの中の項目
に対応する値「2」は、その情報が存在し、利用可能で
あることを意味し、「0」は、その情報が存在しないこ
とを意味する。「1」は、他の情報の存在を補助する目
的のため、あるいは、構文上存在するが、元のビットス
トリーム情報とは関係がないなど、その情報自身には意
味がないことを表している。例えば、slice_startは、
履歴情報を伝送する際のsliceの先頭のmacroblockにお
いて、「1」になるが、本来のビットストリームに対し
て、sliceが必ずしも同一位置関係にあるわけではない
場合には、履歴情報としては無意味になる。
In FIG. 69, a value “2” corresponding to an item in each combination means that the information exists and can be used, and “0” means that the information does not exist. I do. “1” indicates that the information itself has no meaning, such as for the purpose of assisting the existence of other information or in the syntax, but having no relation to the original bit stream information. . For example, slice_start is
In the macroblock at the head of the slice when transmitting the history information, it becomes “1”. However, if the slice is not necessarily in the same positional relationship with the original bit stream, it is meaningless as the history information. become.

【0410】図69の例においては、(num_coef_bit
s,num_mv_bits,num_other_bits),(q_scale_code,
q_scale_type),(motion_type,mv_vert_field_sel[]
[],mv[][][]),(mb_mfwd,mb_mbwd),(mb_patter
n),(coded_block_pattern),(mb_intra),(slic
e_start),(dct_type),(mb_quant),(skipped_m
b)の各項目の有無により、組み合わせ1乃至組み合わ
せ5の5つの組み合わせが用意されている。
In the example of FIG. 69, (num_coef_bit
s, num_mv_bits, num_other_bits), (q_scale_code,
q_scale_type), (motion_type, mv_vert_field_sel []
[], Mv [] [] []), (mb_mfwd, mb_mbwd), (mb_patter
n), (coded_block_pattern), (mb_intra), (slic
e_start), (dct_type), (mb_quant), (skipped_m)
Five combinations of combinations 1 to 5 are prepared depending on the presence or absence of each item of b).

【0411】組み合わせ1は、完全にtransparentなビ
ットストリームを再構成することを目的とした組み合わ
せである。この組み合わせによれば、発生符号量情報を
用いることによる精度の高いトランスコーディングが実
現できる。組み合わせ2も、完全にtransparentなビッ
トストリームを再構成することを目的とした組み合わせ
である。組み合わせ3は、完全にtransparentなビット
ストリームを再構成することはできないが、視覚的にほ
ぼtransparentなビットストリームを再構成できるよう
にするための組み合わせである。組み合わせ4は、tran
sparentという観点からは組み合わせ3よりも劣るが、
視覚上問題がないビットストリームの再構成ができる組
み合わせである。組み合わせ5は、transparentという
観点からは組み合わせ4よりも劣るが、少ない履歴情報
でビットストリームの完全ではない再構成ができる組み
合わせである。
[0411] The combination 1 is a combination for reconstructing a completely transparent bit stream. According to this combination, highly accurate transcoding by using the generated code amount information can be realized. The combination 2 is also a combination for reconstructing a completely transparent bit stream. Combination 3 is a combination that cannot completely reconstruct a completely transparent bit stream, but allows a visually almost transparent bit stream to be reconstructed. Combination 4 is tran
Inferior to combination 3 in terms of sparent,
This is a combination that can reconstruct the bit stream without any visual problem. The combination 5 is inferior to the combination 4 from the viewpoint of transparency, but is a combination that allows incomplete reconstruction of the bit stream with a small amount of history information.

【0412】これらの組み合わせのうち、組み合わせの
番号の数字が小さいものほど、機能的には上位である
が、履歴を転送するのに必要となる容量が多くなる。従
って、想定するアプリケーションと履歴に使用できる容
量を考慮することによって、伝送する組み合わせを決定
する必要がある。
[0412] Among these combinations, the smaller the number of the combination number is, the higher in function, but the larger the capacity required to transfer the history becomes. Therefore, it is necessary to determine the combination to be transmitted by considering the assumed application and the capacity available for the history.

【0413】次に、図70のフローチャートを参照し
て、図68のトランスコーダ101の動作について説明
する。ステップS41において、トランスコーダ101
の復号装置102は、入力されたビットストリームを復
号し、そのビットストリームを符号化する際に使用され
た符号化パラメータ(4th)を抽出し、その符号化パラ
メータ(4th)をヒストリ情報多重化装置103に出力
するとともに、復号したビデオデータをやはりヒストリ
情報多重化装置103に出力する。ステップS42にお
いて、復号装置102はまた、入力されたビットストリ
ームからuser_dataを抽出し、ヒストリデコーディング
装置104に出力する。ヒストリデコーディング装置1
04は、ステップS43において、入力されたuser_dat
aから、組み合わせ情報(記述子)を抽出し、さらにそ
れを用いて、履歴情報としての符号化パラメータ(1s
t,2nd,3rd)を抽出し、ヒストリ情報多重化装置1
03に出力する。
Next, the operation of the transcoder 101 shown in FIG. 68 will be described with reference to the flowchart shown in FIG. In step S41, the transcoder 101
Decoding apparatus 102 decodes an input bit stream, extracts an encoding parameter (4th) used when encoding the bit stream, and uses the encoding parameter (4th) as a history information multiplexing apparatus. 103, and also outputs the decoded video data to the history information multiplexing device 103. In step S42, the decoding device 102 also extracts user_data from the input bit stream and outputs the user_data to the history decoding device 104. History decoding device 1
04 is the user_dat input in step S43.
Extract the combination information (descriptor) from a, and further use it to encode the coding parameter (1s
t, 2nd, 3rd) to extract the history information multiplexing device 1
03 is output.

【0414】ヒストリ情報多重化装置103は、ステッ
プS44において、ステップS41で取り出された復号
装置102から供給される現在の符号化パラメータ(4
th)と、ステップS43でヒストリデコーディング装置
104が出力した過去の符号化パラメータ(1st,2n
d,3rd)とを、復号装置102から供給されるベース
バンドのビデオデータに、図18または図31に示すよ
うなフォーマットに従って多重化し、ヒストリ情報分離
装置105に出力する。
[0414] In step S44, the history information multiplexing apparatus 103 outputs the current encoding parameter (4) supplied from the decoding apparatus 102 extracted in step S41.
th) and the past encoding parameters (1st, 2n) output by the history decoding device 104 in step S43.
d, 3rd) are multiplexed with the baseband video data supplied from the decoding device 102 according to the format shown in FIG. 18 or FIG. 31 and output to the history information separating device 105.

【0415】ヒストリ情報分離装置105は、ステップ
S45において、ヒストリ情報多重化装置103より供
給されたベースバンドのビデオデータから符号化パラメ
ータを抽出し、その中から今回の符号化に最も適してい
る符号化パラメータ(例えば、第2世代の符号化パラメ
ータ)を選択し、記述子とともに、組合せ記述子分離部
511に出力する。また、ヒストリ情報分離装置105
は、今回の符号化に最適と判定された符号化パラメータ
以外の符号化パラメータ(例えば、最適な符号化パラメ
ータが第2世代の符号化パラメータであると判定された
場合には、それ以外の第1世代、第3世代、及び第4世
代の符号化パラメータ)をヒストリエンコーディング装
置107に出力する。ヒストリエンコーディング装置1
07は、ヒストリ情報分離装置105より入力された符
号化パラメータをステップS46において、user_data
に記述し、そのuser_data(converted_history_strea
m())を符号化装置106に出力する。
[0415] In step S45, the history information separation device 105 extracts coding parameters from the baseband video data supplied from the history information multiplexing device 103, and from there, encodes a code most suitable for the current coding. An encoding parameter (for example, a second-generation encoding parameter) is selected and output to the combination descriptor separating unit 511 together with the descriptor. Also, the history information separation device 105
Are the encoding parameters other than the encoding parameters determined to be optimal for the current encoding (for example, if the optimal encoding parameter is determined to be the second-generation encoding parameter, the other The first-generation, third-generation, and fourth-generation encoding parameters are output to the history encoding device 107. History encoding device 1
07, the encoding parameter input from the history information separating device 105 is stored in the user_data
And user_data (converted_history_strea
m ()) is output to the encoding device 106.

【0416】符号化パラメータ選択回路501の組合せ
記述子分離部511は、ヒストリ情報分離装置105よ
り供給されたデータから、符号化パラメータと記述子を
分離し、符号化パラメータ(2nd)をスイッチ513の
一方の接点に供給する。スイッチ513の他方の接点に
は、符号化パラメータ算出部512が、ヒストリ情報分
離装置105が出力するベースバンドのビデオデータか
ら、符号化パラメータを算出し、供給している。スイッ
チ513は、ステップS48において、組合せ記述子分
離部511が出力した記述子に対応して、組合せ記述子
分離部511が出力した符号化パラメータ、または符号
化パラメータ算出部512が出力した符号化パラメータ
のいずれかを選択し、符号化装置106に出力する。す
なわち、スイッチ513では、組合せ記述子分離部51
1から供給された符号化パラメータが有効である場合に
は、組合せ記述子分離部511が出力する符号化パラメ
ータが選択されるが、組合せ記述子分離部511が出力
する符号化パラメータが無効であると判定された場合に
は、符号化パラメータ算出部512がベースバンドビデ
オを処理することで算出した符号化パラメータが選択さ
れる。この選択は、伝送メディアの容量に対応して行わ
れる。
[0416] The combination descriptor separation unit 511 of the coding parameter selection circuit 501 separates the coding parameter and the descriptor from the data supplied from the history information separation device 105, and sets the coding parameter (2nd) of the switch 513. Supply to one contact. To the other contact of the switch 513, an encoding parameter calculation unit 512 calculates and supplies an encoding parameter from baseband video data output by the history information separation device 105. The switch 513 determines in step S48 the encoding parameter output from the combination descriptor separating unit 511 or the encoding parameter output from the encoding parameter calculating unit 512, corresponding to the descriptor output from the combination descriptor separating unit 511. And outputs it to the encoding device 106. That is, in the switch 513, the combination descriptor separating unit 51
If the coding parameter supplied from 1 is valid, the coding parameter output from the combination descriptor separation unit 511 is selected, but the coding parameter output from the combination descriptor separation unit 511 is invalid. Is determined, the encoding parameter calculated by the encoding parameter calculation unit 512 processing the baseband video is selected. This selection is made according to the capacity of the transmission medium.

【0417】符号化装置106は、ステップS49にお
いて、スイッチ513から供給された符号化パラメータ
に基づいて、ヒストリ情報分離装置105より供給され
たベースバンドビデオ信号を符号化する。また、ステッ
プS50において、符号化装置106は、符号化したビ
ットストリームに、ヒストリエンコーディング装置10
7より供給されたuser_dataを多重化し、出力する。
[0417] In step S49, the encoding device 106 encodes the baseband video signal supplied from the history information separating device 105 based on the encoding parameter supplied from the switch 513. In addition, in step S50, the encoding device 106 adds the history encoding device 10 to the encoded bit stream.
7 is multiplexed and output from the user_data supplied from 7.

【0418】このようにして、各履歴によって得られる
符号化パラメータの組み合わせが異なっているような場
合でも、支障なくトランスコーディングすることが可能
となる。
[0418] In this way, even when the combinations of the encoding parameters obtained by the respective histories are different, transcoding can be performed without any trouble.

【0419】このように、履歴情報は、図38に示した
ように、ビデオストリームのuser_data()関数の一種と
してのhistory_stream()(より正確には、converted_hi
story_stream())で伝送される。そのhistory_stream()
のシンタックスは、図47に示した通りである。履歴情
報の項目の組み合わせを表す記述子(red_bw_flag,red
_bw_indicator)、およびMPEGのストリームではサポー
トされていない項目(num_other_bits,num_mv_bits,n
um_coef_bits)は、この図47の中のre_coding_stream
_info()関数により伝送される。
[0419] As described above, the history information is, as shown in Fig. 38, history_stream () as a kind of user_data () function of the video stream (more precisely, converted_hi
transmitted by story_stream ()). That history_stream ()
Is as shown in FIG. Descriptors (red_bw_flag, red
_bw_indicator) and items that are not supported in MPEG stream (num_other_bits, num_mv_bits, n
um_coef_bits) is re_coding_stream in FIG.
It is transmitted by the _info () function.

【0420】re_coding_stream_info()関数は、図71
に示すように、user_data_start_code,re_coding_stre
am_info_ID,red_bw_flag,red_bw_indicator,marker_
bit,num_other_bits,num_mv_bits,num_coef_bitsな
どのデータエレメントより構成される。
[0420] The re_coding_stream_info () function is shown in FIG.
User_data_start_code, re_coding_stre
am_info_ID, red_bw_flag, red_bw_indicator, marker_
It is composed of data elements such as bit, num_other_bits, num_mv_bits, and num_coef_bits.

【0421】user_data_start_codeは、user_dataが開
始することを表すスタートコードである。re_coding_st
ream_info_IDは、16ビットの整数であり、re_coding_
stream_info()関数の識別のために用いられる。その値
は、具体的には、”1001 00011110 1100”(0x91ec)と
される。
[0421] user_data_start_code is a start code indicating that user_data starts. re_coding_st
ream_info_ID is a 16-bit integer.
Used to identify the stream_info () function. Specifically, the value is set to “1001 00011110 1100” (0x91ec).

【0422】red_bw_flagは、1ビットのフラグであ
り、履歴情報が全ての項目を伝送する場合には0とさ
れ、このフラグの値が1である場合、このフラグに続く
red_bw_indicatorを調べることにより、図69に示した
5個の組み合わせのうち、どの組み合わせで項目が送ら
れているのかを決定することができる。
[0422] red_bw_flag is a 1-bit flag, and is set to 0 when the history information transmits all items. When the value of this flag is 1, the flag follows this flag.
By examining red_bw_indicator, it is possible to determine which of the five combinations shown in FIG. 69 is sending an item.

【0423】red_bw_indicatorは、2ビットの整数であ
り、項目の組み合わせを図72に示すように記述する。
[0423] red_bw_indicator is a 2-bit integer, and describes a combination of items as shown in FIG.

【0424】即ち、図69に示した5つの組み合わせの
うち、組み合わせ1の場合、red_bw_flagは0とされ、
組み合わせ2乃至組み合わせ5のとき、red_bw_flagは
1とされる。これに対して、red_bw_indicatorは、組み
合わせ2の場合0とされ、組み合わせ3の場合1とさ
れ、組み合わせ4の場合2とされ、組み合わせ5の場合
3とされる。
That is, in the case of combination 1 among the five combinations shown in FIG. 69, red_bw_flag is set to 0,
For combinations 2 to 5, red_bw_flag is set to 1. On the other hand, red_bw_indicator is set to 0 for combination 2, 1 for combination 3, 2 for combination 4, and 3 for combination 5.

【0425】従って、red_bw_indicatorは、red_bw_fla
gが1の場合に(組み合わせ2乃至組み合わせ5の場合
に)規定される。
[0425] Therefore, red_bw_indicator is equivalent to red_bw_fla
It is defined when g is 1 (for combinations 2 to 5).

【0426】さらに、図71に示すように、red_bw_fla
gが0である場合(組み合わせ1の場合)、マクロブロ
ック毎に、marker_bit,num_other_bits,num_mv_bit
s,num_coef_bitsが記述される。これら4つのデータエ
レメントは、組み合わせ2乃至組み合わせ5の場合(re
d_bw_flagが1の場合)規定されない。
Further, as shown in FIG. 71, red_bw_fla
When g is 0 (in the case of combination 1), marker_bit, num_other_bits, num_mv_bit
s and num_coef_bits are described. These four data elements are used in combination 2 to combination 5 (re
Not specified if d_bw_flag is 1).

【0427】図59に示したように、picture_data()関
数は、1個以上のslice()関数から構成される。しかし
ながら、組み合わせ5の場合、picture_data()関数を含
めて、それ以下のシンタックス要素は伝送されない(図
69)。この場合、履歴情報は、picture_typeなどのpi
cture単位の情報の伝送を意図したものとなる。
As shown in FIG. 59, the picture_data () function is composed of one or more slice () functions. However, in the case of the combination 5, syntax elements lower than that including the picture_data () function are not transmitted (FIG. 69). In this case, the history information is pi such as picture_type.
This is intended to transmit information in units of cture.

【0428】組み合わせ1乃至組み合わせ4の場合、図
60に示したslice()関数が存在する。しかしながら、
このslice()関数によって決定されるsliceの位置情報
と、元のビットストリームのsliceの位置情報は、履歴
情報の項目の組み合わせに依存する。組み合わせ1また
は組み合わせ2の場合、履歴情報の元となったビットス
トリームのsliceの位置情報と、slice()関数によって決
定されるsliceの位置情報とは、同一である必要があ
る。
In the case of combinations 1 to 4, the slice () function shown in FIG. 60 exists. However,
The slice position information determined by the slice () function and the slice position information of the original bit stream depend on a combination of items of history information. In the case of combination 1 or combination 2, the position information of the slice of the bit stream that is the source of the history information and the position information of the slice determined by the slice () function need to be the same.

【0429】図61に示すmacroblock()関数のシンタッ
クス要素は、履歴情報の項目の組み合わせに依存する。
macroblock_escape,macroblock_address_increment,m
acroblock_modes()関数は、常に存在する。しかしなが
ら、macroblock_escapeとmacroblock_address_incremen
tの情報としての有効性は、組み合わせによって決定さ
れる。履歴情報の項目の組み合わせが、組み合わせ1ま
たは組み合わせ2の場合、元のビットストリームのskip
ped_mb情報と同じものが伝送される必要がある。
The syntax element of the macroblock () function shown in FIG. 61 depends on the combination of items of history information.
macroblock_escape, macroblock_address_increment, m
The acroblock_modes () function always exists. However, macroblock_escape and macroblock_address_incremen
The validity of t as information is determined by the combination. When the combination of items of history information is combination 1 or combination 2, skip of the original bit stream
The same ped_mb information needs to be transmitted.

【0430】組み合わせ4の場合、motion_vectors()関
数は存在しない。組み合わせ1乃至組み合わせ3の場
合、macroblock_modes()関数のmacroblock_typeによっ
て、motion_vectors()関数の存在が決定される。組み合
わせ3または組み合わせ4の場合には、coded_block_pa
ttern()関数は存在しない。組み合わせ1と組み合わせ
2の場合、macroblock_modes()関数のmacroblock_type
によって、coded_block_pattern()関数の存在が決定さ
れる。
In the case of the combination 4, there is no motion_vectors () function. In the case of the combinations 1 to 3, the existence of the motion_vectors () function is determined by the macroblock_type of the macroblock_modes () function. In the case of combination 3 or combination 4, coded_block_pa
There is no ttern () function. In case of combination 1 and combination 2, macroblock_type of macroblock_modes () function
Determines the existence of the coded_block_pattern () function.

【0431】図62に示したmacroblock_modes()関数の
シンタックス要素は、履歴情報の項目の組み合わせに依
存する。macroblock_typeは、常に存在する。組み合わ
せが組み合わせ4である場合、flame_motion_type,fie
ld_motion_type,dct_typeは存在しない。
[0431] The syntax element of the macroblock_modes () function shown in Fig. 62 depends on the combination of items of history information. macroblock_type always exists. If the combination is combination 4, flame_motion_type, fie
ld_motion_type and dct_type do not exist.

【0432】macroblock_typeより得られるパラメータ
の情報としての有効性は、履歴情報の項目の組み合わせ
によって決定される。
The validity of the parameter obtained from macroblock_type as information is determined by the combination of items of history information.

【0433】履歴情報の項目の組み合わせが組み合わせ
1または組み合わせ2である場合、macroblock_quant
は、元のビットストリームと同じである必要がある。組
み合わせ3または組み合わせ4の場合、macroblock_qua
ntは、macroblock()関数内のquantiser_scale_codeの存
在を表し、元のビットストリームと同じである必要はな
い。
If the combination of the items of the history information is combination 1 or combination 2, macroblock_quant
Must be the same as the original bitstream. Macroblock_qua for combination 3 or combination 4
nt indicates the presence of quantizer_scale_code in the macroblock () function, and need not be the same as the original bitstream.

【0434】組み合わせが組み合わせ1乃至組み合わせ
3である場合、macroblock_motion_forwardとmacrobloc
k_motion_backwardは、元のビットストリームと同一で
ある必要がある。組み合わせが組み合わせ4または組み
合わせ5である場合、その必要はない。
If the combination is combination 1 to combination 3, macroblock_motion_forward and macrobloc
k_motion_backward needs to be the same as the original bitstream. If the combination is combination 4 or combination 5, it is not necessary.

【0435】組み合わせが組み合わせ1または組み合わ
せ2である場合、macroblock_patternは、元のビットス
トリームと同一である必要がある。組み合わせ3の場
合、macroblock_patternは、dct_typeの存在を示すのに
用いられる。組み合わせが組み合わせ4である場合、組
み合わせ1乃至組み合わせ3における場合のような関係
は成立しない。
When the combination is combination 1 or combination 2, macroblock_pattern needs to be the same as the original bit stream. In the case of combination 3, macroblock_pattern is used to indicate the presence of dct_type. When the combination is combination 4, the relationship as in the case of combinations 1 to 3 is not established.

【0436】履歴情報の項目の組み合わせが組み合わせ
1乃至組み合わせ3の場合、macroblock_intraは、元の
ビットストリームと同一である必要がある。組み合わせ
4の場合には、その限りでない。
When the combination of items of the history information is combination 1 to combination 3, macroblock_intra needs to be the same as the original bit stream. In the case of combination 4, this is not always the case.

【0437】図47のhistory_stream()は、履歴情報を
可変長とする場合のシンタックスであるが、図40乃至
図46に示すように、固定長のシンタックスとする場
合、固定長の履歴情報内に、伝送される項目中のどれが
有効であるかを示す情報としての記述子(red_bw_flag
とred_bw_indicator)をベースバンド画像に重畳し、伝
送するようにする。その結果、この記述子を調べること
により、フィールドとして存在するが、その内容は無効
であるといった判断をすることが可能となる。
[0437] The history_stream () in Fig. 47 is the syntax when the history information is of variable length. As shown in Figs. 40 to 46, when the syntax is of fixed length, the history information is of a fixed length. In the descriptor (red_bw_flag) as information indicating which of the transmitted items is valid
And red_bw_indicator) are superimposed on the baseband image and transmitted. As a result, by examining this descriptor, it is possible to determine that the field exists as a field but its contents are invalid.

【0438】このため、図44に示すように、re_codin
g_stream_informationとして、user_data_start_code,
re_coding_stream_info_ID,red_bw_flag,red_bw_indi
cator,marker_bitが配置されている。それぞれの意味
は、図71における場合と同様である。
Therefore, as shown in FIG. 44, re_codin
As g_stream_information, user_data_start_code,
re_coding_stream_info_ID, red_bw_flag, red_bw_indi
cator and marker_bit are arranged. Each meaning is the same as in FIG. 71.

【0439】このように履歴として伝送する符号化パラ
メータの要素をアプリケーションに応じた組み合わせで
伝送するようにすることで、アプリケーションに応じた
履歴を適当なデータ量で伝送するようにすることができ
る。
As described above, by transmitting the elements of the encoding parameter transmitted as the history in a combination corresponding to the application, the history corresponding to the application can be transmitted with an appropriate data amount.

【0440】以上のように、履歴情報を可変長符号とし
て伝送する場合、re_coding_stream_info()関数は、図
71に示すように構成され、図47に示すように、hist
ory_stream()関数の一部として伝送される。これに対し
て、履歴情報を固定長符号として伝送する場合には、図
44に示したように、history_stream()関数の一部とし
て、re_coding_stream_information()が伝送される。図
44の例では、re_coding_stream_informationとして、
user_data_start_code,re_coding_stream_info_ID,re
d_bw_flag,red_bw_indicatorが伝送される。
As described above, when transmitting the history information as a variable-length code, the re_coding_stream_info () function is configured as shown in FIG. 71, and as shown in FIG.
Transmitted as part of the ory_stream () function. On the other hand, when the history information is transmitted as a fixed-length code, re_coding_stream_information () is transmitted as a part of the history_stream () function, as shown in FIG. In the example of FIG. 44, as re_coding_stream_information,
user_data_start_code, re_coding_stream_info_ID, re
d_bw_flag and red_bw_indicator are transmitted.

【0441】また、図68のヒストリ情報多重化装置1
03が出力するベースバンドの信号中における履歴情報
の伝送のために、図73に示すようなRe_Coding inform
ation Bus macroblock formatが規定される。このマク
ロブロックは、16×16(=256)ビットで構成さ
れる。そして、そのうちの図73において上から3行目
と4行目に示す32ビットが、picrate_elementとされ
る。このpicrate_elementには、図74乃至図76に示
すPicture rate elementsが記述される。図74の上か
ら2行目に1ビットのred_bw_flagが規定されており、
また、3行目に3ビットのred_bw_indicatorが規定され
ている。即ち、これらのフラグred_bw_flag,red_bw_in
dicatorは、図73のpicrate_elementとして伝送され
る。
Also, the history information multiplexing device 1 shown in FIG.
03 for transmitting the history information in the baseband signal output by Re_Coding inform shown in FIG.
ation Bus macroblock format is specified. This macro block is composed of 16 × 16 (= 256) bits. Then, in FIG. 73, 32 bits shown in the third and fourth rows from the top are set as picrate_element. The picture rate elements shown in FIGS. 74 to 76 are described in the picrate_element. A 1-bit red_bw_flag is defined in the second row from the top in FIG.
In the third row, a 3-bit red_bw_indicator is defined. That is, these flags red_bw_flag, red_bw_in
The indicator is transmitted as picrate_element in FIG.

【0442】図73のその他のデータについて説明する
と、SRIB_sync_codeは、このフォーマットのマクロブロ
ックの最初の行が左詰めにアライメントされていること
を表すコードであり、具体的には、”11111”に設
定される。fr_fl_SRIBは、picture_structureがフレー
ムピクチャ構造の場合(その値が”11”である場
合)、1に設定され、Re_Coding Information Bus macr
oblockが16ラインを超えて伝送されることを表し、pi
cture_structureがフレーム構造ではない場合、0に設
定され、Re_Coding Information Busが16ラインを超
えて伝送されることを意味する。この機構により、Re_C
oding Information Busが、空間的かつ時間的にデコー
ドされたビデオフレームまたはフィールドの対応する画
素にロックされる。
Referring to the other data shown in FIG. 73, SRIB_sync_code is a code indicating that the first row of a macro block in this format is left-aligned, and specifically, is set to “11111”. Is done. fr_fl_SRIB is set to 1 when picture_structure is a frame picture structure (when its value is “11”), and Re_Coding Information Bus macr
Indicates that oblock is transmitted over 16 lines, and pi
If the structure_structure is not a frame structure, it is set to 0, which means that the Re_Coding Information Bus is transmitted over 16 lines. By this mechanism, Re_C
The oding information bus is locked to the corresponding pixels of the video frame or field that have been decoded spatially and temporally.

【0443】SRIB_top_field_firstは、元のビットスト
リームに保持されているtop_field_firstと同じ値に設
定され、関連するビデオのRe_Coding Information Bus
の時間的アライメントをrepeat_first_fieldとともに表
している。SRIB_repeat_first_fieldは、元のビットス
トリームに保持されているrepeat_first_fieldと同じ値
に設定される。first fieldのRe_Coding Information B
usの内容は、このフラグに示されるように繰り返される
必要がある。
[0443] SRIB_top_field_first is set to the same value as top_field_first held in the original bit stream, and the Re_Coding Information Bus of the related video is set.
Is shown together with repeat_first_field. SRIB_repeat_first_field is set to the same value as repeat_first_field held in the original bit stream. Re_Coding Information B of first field
The contents of us need to be repeated as indicated by this flag.

【0444】422_420_chromaは、元のビットストリーム
が4:2:2または4:2:0のいずれであるかを表
す。その値の0は、ビットストリームが4:2:0であ
り、色差信号のアップサンプリングが、4:2:2のビ
デオが出力されるように行われたことを表す。その値の
0は、色差信号のフィルタリング処理が実行されていな
いことを表す。
[0444] 422_420_chroma indicates whether the original bit stream is 4: 2: 2 or 4: 2: 0. A value of 0 indicates that the bit stream is 4: 2: 0 and that the up-sampling of the chrominance signal has been performed such that a 4: 2: 2 video is output. The value 0 indicates that the filtering process of the color difference signal has not been executed.

【0445】rolling_SRIB_mb_refは、16ビットのモ
ジュロ65521を表し、この値は、毎マクロブロック毎に
インクリメントされる。この値は、フレームピクチャ構
造のフレームに渡って連続している必要がある。さもな
くば、この値は、フィールドに渡って連続している必要
がある。この値は、0から65520の間の所定の値に初期
化される。これにより、レコーダのシステムに、ユニー
クなRe_Coding Information Busの識別子を組み込むこ
とが許容される。
[0445] rolling_SRIB_mb_ref represents a 16-bit modulo 65521, and this value is incremented for each macroblock. This value needs to be continuous over the frames of the frame picture structure. Otherwise, this value must be contiguous across fields. This value is initialized to a predetermined value between 0 and 65520. This allows a unique Re_Coding Information Bus identifier to be incorporated into the recorder system.

【0446】Re_Coding Information Bus macroblockの
その他のデータの意味は、上述した通りであるので、こ
こでは省略する。
[0446] The meanings of the other data of the Re_Coding Information Bus macroblock are as described above, and are therefore omitted here.

【0447】図77に示すように、図73の256ビッ
トのRe_Coding Information Busのデータは、1ビット
ずつ、色差データのLSBであるCb[0][0],Cr[0][0],Cb
[1][0],Cr[1][0]に配置される。図77に示すフォーマ
ットにより、4ビットのデータを送ることができるの
で、図73の256ビットのデータは、図77のフォー
マットを64(=256/4)個送ることで伝送するこ
とができる。
As shown in FIG. 77, the data of the 256-bit Re_Coding Information Bus of FIG. 73 is Cb [0] [0], Cr [0] [0], and Cb, which are LSBs of color difference data one bit at a time.
[1] [0], Cr [1] [0]. Since 4-bit data can be transmitted by the format shown in FIG. 77, the 256-bit data shown in FIG. 73 can be transmitted by transmitting 64 (= 256/4) data in the format shown in FIG.

【0448】本発明のトランスコーダによれば、過去の
符号化処理において生成された符号化パラメータを、現
在の符号化処理において再利用するようにしているの
で、復号処理及び符号化処理を繰り返したとしても画質
劣化が発生しない。つまり、復号処理及び符号化処理の
繰り返しによる画質劣化の蓄積を低減することができ
る。
According to the transcoder of the present invention, since the encoding parameters generated in the past encoding process are reused in the current encoding process, the decoding process and the encoding process are repeated. No image quality degradation occurs. That is, it is possible to reduce accumulation of image quality deterioration due to repetition of decoding processing and encoding processing.

【0449】本発明のトランスコーダによれば、過去の
符号化処理において生成された符号化パラメータを、現
在の符号化処理において生成された符号化ストリームの
ユーザデータエリアに記述するようにし、生成されたビ
ットストリームは、MPEG規格に準じた符号化ストリーム
であるので、既存のどのデコーダでも復号処理を行うこ
とができる。さらには、本発明のトランスコーダによれ
ば、過去の符号化処理における符号化パラメータを伝送
するために専用線のようなものを設ける必要がないの
で、従来のデータストリーム伝送環境をそのまま使用し
て、過去の符号化パラメータを伝送することができる。
According to the transcoder of the present invention, the coding parameters generated in the past coding process are described in the user data area of the coded stream generated in the current coding process. Since the bit stream is a coded stream conforming to the MPEG standard, any existing decoder can perform decoding processing. Furthermore, according to the transcoder of the present invention, it is not necessary to provide a kind of dedicated line for transmitting the coding parameters in the past coding process, so that the conventional data stream transmission environment can be used as it is. , Past coding parameters can be transmitted.

【0450】本発明のトランスコーダによれば、過去の
符号化処理において生成された符号化パラメータを、選
択的に現在の符号化処理において生成された符号化スト
リーム中に記述するようにしているので、出力されるビ
ットストリームのビットレートを極端に上げることな
く、過去の符号化パラメータを伝送することができる。
According to the transcoder of the present invention, the coding parameters generated in the past coding process are selectively described in the coded stream generated in the current coding process. The past encoding parameters can be transmitted without extremely increasing the bit rate of the output bit stream.

【0451】本発明のトランスコーダによれば、過去の
符号化パラメータと現在の符号化ラメータの中から、現
在の符号化処理に最適な符号化パラメータを選択して符
号化処理を行うようにしているので、復号処理及び符号
化処理を繰り返したとしても、画質劣化が蓄積されるこ
とはない。
According to the transcoder of the present invention, an encoding parameter optimum for the current encoding process is selected from the past encoding parameters and the current encoding parameters, and the encoding process is performed. Therefore, even if the decoding process and the encoding process are repeated, the image quality degradation is not accumulated.

【0452】本発明のトランスコーダによれば、過去の
符号化パラメータの中から、ピクチャタイプに応じて現
在の符号化処理に最適な符号化パラメータを選択して符
号化処理を行うようにしているので、復号処理及び符号
化処理を繰り返したとしても、画質劣化が蓄積されるこ
とはない。
According to the transcoder of the present invention, the encoding process is performed by selecting the most suitable encoding parameter for the current encoding process from the past encoding parameters according to the picture type. Therefore, even if the decoding process and the encoding process are repeated, the image quality does not deteriorate.

【0453】本発明のトランスコーダによれば、過去の
符号化パラメータに含まれるピクチャタイプに基づい
て、過去の符号化パラメータを再利用するか否かを決定
しているので、最適な符号化処理を行うことができる。
According to the transcoder of the present invention, whether to reuse past coding parameters is determined based on the picture type included in past coding parameters. It can be performed.

【0454】なお、上記各処理を行うコンピュータプロ
グラムは、磁気ディスク、光ディスク、光磁気ディス
ク、半導体メモリなどの記録媒体に記録して提供するほ
か、インターネット、デジタル衛星などのネットワーク
を介して伝送し、ユーザの記録媒体に記録させることで
提供することができる。
The computer program for performing each of the above processes is provided by being recorded on a recording medium such as a magnetic disk, an optical disk, a magneto-optical disk, or a semiconductor memory, and transmitted via a network such as the Internet or a digital satellite. It can be provided by recording on a user's recording medium.

【0455】[0455]

【発明の効果】以上の如く、請求項1に記載のストリー
ム生成装置、請求項4に記載のストリーム生成方法、お
よび請求項5に記載の記録媒体のプログラムによれば、
第2の符号化ストリームに対して、それまでの符号化処
理における符号化履歴の組み合わせを表す組み合わせ情
報を記述するようにしたので、少ない容量の伝送路を介
して伝送可能な履歴情報を含むストリームを生成するこ
とが可能となる。
As described above, according to the stream generating apparatus of claim 1, the stream generating method of claim 4, and the program of the recording medium of claim 5,
Since the combination information indicating the combination of the coding histories in the previous coding processing is described in the second coded stream, the stream including the history information that can be transmitted through the transmission path with a small capacity is used. Can be generated.

【0456】請求項6に記載のストリーム伝送装置、請
求項9に記載のストリーム伝送方法、および請求項10
に記載の記録媒体のプログラムによれば、過去の符号化
処理において使用された複数の符号化パラメータを、選
択的に組み合わせて、その符号化履歴情報を生成し、符
号化ストリームに重乗するようにしたので、再符号化に
伴う画像の劣化を抑制可能なストリームを、少ない容量
のメディアを介して伝送することが可能となる。
[0456] The stream transmitting apparatus according to claim 6, the stream transmitting method according to claim 9, and the stream transmitting apparatus according to claim 9.
According to the program of the recording medium described in the above, a plurality of encoding parameters used in the past encoding process are selectively combined, to generate the encoding history information, and to multiply the encoded stream Therefore, it is possible to transmit a stream that can suppress the deterioration of an image due to re-encoding via a small-capacity medium.

【0457】請求項11に記載の符号化装置、請求項1
4に記載の符号化方法、および請求項15に記載の記録
媒体のプログラムによれば、組み合わせ情報に基づい
て、符号化パラメータを抽出し、抽出した符号化パラメ
ータに基づいて、第1の符号化ストリームを第2の符号
化ストリームに符号化するようにしたので、再符号化に
伴う画像の劣化を抑制した、少ない伝送容量の伝送メデ
ィアに伝送可能なストリームを符号化することが可能と
なる。
[0457] The encoding apparatus according to the eleventh aspect, the first aspect.
According to the encoding method of the fourth aspect and the program of the recording medium of the fifteenth aspect, an encoding parameter is extracted based on the combination information, and the first encoding is performed based on the extracted encoding parameter. Since the stream is encoded into the second encoded stream, it is possible to encode a stream that can be transmitted to a transmission medium with a small transmission capacity while suppressing image degradation due to re-encoding.

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

【図1】高効率符号化の原理を説明する図である。FIG. 1 is a diagram illustrating the principle of high-efficiency coding.

【図2】画像データを圧縮する場合におけるピクチャタ
イプを説明する図である。
FIG. 2 is a diagram illustrating a picture type when image data is compressed.

【図3】画像データを圧縮する場合におけるピクチャタ
イプを説明する図である。
FIG. 3 is a diagram illustrating a picture type when image data is compressed.

【図4】動画像信号を符号化する原理を説明する図であ
る。
FIG. 4 is a diagram illustrating the principle of encoding a moving image signal.

【図5】動画像信号を符号化し、復号する装置の構成を
示すブロック図である。
FIG. 5 is a block diagram illustrating a configuration of an apparatus that encodes and decodes a moving image signal.

【図6】画像データの構成を説明する図である。FIG. 6 is a diagram illustrating a configuration of image data.

【図7】図5のエンコーダ18の構成を示すブロック図
である。
FIG. 7 is a block diagram showing a configuration of an encoder 18 of FIG.

【図8】図7の予測モード切換回路52の動作を説明す
る図である。
8 is a diagram for explaining the operation of the prediction mode switching circuit 52 of FIG.

【図9】図7の予測モード切換回路52の動作を説明す
る図である。
FIG. 9 is a diagram illustrating the operation of the prediction mode switching circuit 52 of FIG.

【図10】図7の予測モード切換回路52の動作を説明
する図である。
FIG. 10 is a diagram illustrating the operation of the prediction mode switching circuit 52 of FIG.

【図11】図7の予測モード切換回路52の動作を説明
する図である。
11 is a diagram illustrating the operation of the prediction mode switching circuit 52 of FIG.

【図12】図5のデコーダ31の構成を示すブロック図
である。
FIG. 12 is a block diagram showing a configuration of a decoder 31 of FIG.

【図13】ピクチャタイプに対応したSNR制御を説明す
る図である。
FIG. 13 is a diagram illustrating SNR control corresponding to a picture type.

【図14】本発明を適用したトランスコーダ101の構
成を示すブロック図である。
FIG. 14 is a block diagram illustrating a configuration of a transcoder 101 to which the present invention has been applied.

【図15】図14のトランスコーダ101のより詳細な
構成を示すブロック図である。
FIG. 15 is a block diagram showing a more detailed configuration of the transcoder 101 of FIG.

【図16】図14の復号装置102に内蔵されるデコー
ダ111の構成を示すブロック図である。
16 is a block diagram illustrating a configuration of a decoder 111 built in the decoding device 102 in FIG.

【図17】マクロブロックの画素を説明する図である。FIG. 17 is a diagram illustrating pixels of a macroblock.

【図18】符号化パラメータが記録される領域を説明す
る図である。
FIG. 18 is a diagram illustrating an area where an encoding parameter is recorded.

【図19】図14の符号化装置106に内蔵されるエン
コーダ121の構成を示すブロック図である。
19 is a block diagram showing a configuration of an encoder 121 built in the encoding device 106 in FIG.

【図20】図15のヒストリVLC211の構成例を示す
ブロック図である。
20 is a block diagram illustrating a configuration example of a history VLC 211 in FIG.

【図21】図15のヒストリVLD203の構成例を示す
ブロック図である。
21 is a block diagram illustrating a configuration example of a history VLD 203 in FIG.

【図22】図15のコンバータ212の構成例を示すブ
ロック図である。
FIG. 22 is a block diagram illustrating a configuration example of a converter 212 in FIG.

【図23】図22のスタッフ回路323の構成例を示す
ブロック図である。
23 is a block diagram illustrating a configuration example of a stuff circuit 323 in FIG.

【図24】図22のコンバータ212の動作を説明する
タイミングチャートである。
24 is a timing chart illustrating the operation of converter 212 in FIG.

【図25】図15のコンバータ202の構成例を示すブ
ロック図である。
25 is a block diagram illustrating a configuration example of a converter 202 in FIG.

【図26】図25のディリート回路343の構成例を示
すブロック図である。
26 is a block diagram illustrating a configuration example of a delay circuit 343 of FIG.

【図27】図15のコンバータ212の他の構成例を示
すブロック図である。
FIG. 27 is a block diagram showing another configuration example of converter 212 in FIG.

【図28】図15のコンバータ202の他の構成例を示
すブロック図である。
FIG. 28 is a block diagram showing another configuration example of converter 202 in FIG.

【図29】図15のユーザデータフォーマッタ213の
構成例を示すブロック図である。
FIG. 29 is a block diagram illustrating a configuration example of a user data formatter 213 in FIG.

【図30】図14のトランスコーダ101が実際に使用
される状態を示す図である。
FIG. 30 is a diagram showing a state where the transcoder 101 of FIG. 14 is actually used.

【図31】符号化パラメータが記録される領域を説明す
る図である。
FIG. 31 is a diagram illustrating an area where an encoding parameter is recorded.

【図32】図14の符号化装置106の変更可能ピクチ
ャタイプ判定処理を説明するフローチャートである。
32 is a flowchart illustrating a changeable picture type determination process of the encoding device 106 in FIG.

【図33】ピクチャタイプが変更される例を示す図であ
る。
FIG. 33 is a diagram illustrating an example in which a picture type is changed.

【図34】ピクチャタイプが変更される他の例を示す図
である。
FIG. 34 is a diagram illustrating another example in which the picture type is changed.

【図35】図14の符号化装置106の量子化制御処理
を説明する図である。
FIG. 35 is a diagram illustrating quantization control processing of the encoding device 106 in FIG. 14;

【図36】図14の符号化装置106の量子化制御処理
を説明するフローチャートである。
FIG. 36 is a flowchart illustrating a quantization control process of the encoding device 106 in FIG. 14;

【図37】密結合されたトランスコーダ101の構成を
示すブロック図である。
FIG. 37 is a block diagram illustrating a configuration of a transcoder 101 that is tightly coupled.

【図38】ビデオシーケンスのストリームのシンタック
スを説明する図である。
FIG. 38 is a diagram illustrating the syntax of a stream of a video sequence.

【図39】図38のシンタックスの構成を説明する図で
ある。
FIG. 39 is a diagram illustrating the configuration of the syntax in FIG. 38.

【図40】固定長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 40 history_stream for recording fixed-length history information
It is a figure explaining the syntax of ().

【図41】固定長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 41 history_stream for recording fixed-length history information
It is a figure explaining the syntax of ().

【図42】固定長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 42 history_stream for recording fixed-length history information
It is a figure explaining the syntax of ().

【図43】固定長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 43: history_stream for recording fixed-length history information
It is a figure explaining the syntax of ().

【図44】固定長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 44 history_stream for recording fixed-length history information
It is a figure explaining the syntax of ().

【図45】固定長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 45: history_stream for recording fixed-length history information
It is a figure explaining the syntax of ().

【図46】固定長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 46 shows history_stream for recording fixed-length history information.
It is a figure explaining the syntax of ().

【図47】可変長の履歴情報を記録するhistory_stream
()のシンタックスを説明する図である。
FIG. 47 history_stream for recording variable-length history information
It is a figure explaining the syntax of ().

【図48】sequence_header()のシンタックスを説明す
る図である。
[Fig. 48] Fig. 48 is a diagram for describing the syntax of sequence_header ().

【図49】sequence_extension()のシンタックスを説明
する図である。
Fig. 49 is a diagram for describing the syntax of sequence_extension ().

【図50】extension_and_user_data()のシンタックス
を説明する図である。
[Fig. 50] Fig. 50 is a diagram for describing the syntax of extension_and_user_data ().

【図51】user_data()のシンタックスを説明する図で
ある。
Fig. 51 is a diagram for describing the syntax of user_data ().

【図52】group_of_pictures_header()のシンタックス
を説明する図である。
Fig. 52 is a diagram for describing the syntax of group_of_pictures_header ().

【図53】picture_header()のシンタックスを説明する
図である。
Fig. 53 is a diagram for describing the syntax of picture_header ().

【図54】picture_coding_extension()のシンタックス
を説明する図である。
Fig. 54 is a diagram for describing the syntax of picture_coding_extension ().

【図55】extension_data()のシンタックスを説明する
図である。
[Fig. 55] Fig. 55 is a diagram for describing the syntax of extension_data ().

【図56】quant_matrix_extension()のシンタックスを
説明する図である。
Fig. 56 is a diagram for describing the syntax of quant_matrix_extension ().

【図57】copyright_extension()のシンタックスを説
明する図である。
[Fig. 57] Fig. 57 is a diagram for describing the syntax of copyright_extension ().

【図58】picture_display_extension()のシンタック
スを説明する図である。
Fig. 58 is a diagram for describing the syntax of picture_display_extension ().

【図59】picture_data()のシンタックスを説明する図
である。
Fig. 59 is a diagram for describing the syntax of picture_data ().

【図60】slice()のシンタックスを説明する図であ
る。
Fig. 60 is a diagram for describing the syntax of slice ().

【図61】macroblock()のシンタックスを説明する図で
ある。
Fig. 61 is a diagram for describing the syntax of macroblock ().

【図62】macroblock_modes()のシンタックスを説明す
る図である。
Fig. 62 is a diagram for describing the syntax of macroblock_modes ().

【図63】motion_vectors(s)のシンタックスを説明す
る図である。
Fig. 63 is a diagram for describing the syntax of motion_vectors (s).

【図64】motion_vector(r,s)のシンタックスを説明す
る図である。
Fig. 64 is a diagram for describing the syntax of motion_vector (r, s).

【図65】Iピクチャに対するmacroblock_typeの可変
長符号を説明する図である。
[Fig. 65] Fig. 65 is a diagram for describing a macroblock_type variable-length code for an I picture.

【図66】Pピクチャに対するmacroblock_typeの可変
長符号を説明する図である。
[Fig. 66] Fig. 66 is a diagram for describing a macroblock_type variable-length code for a P picture.

【図67】Bピクチャに対するmacroblock_typeの可変
長符号を説明する図である。
[Fig. 67] Fig. 67 is a diagram illustrating a macroblock_type variable length code for a B picture.

【図68】本発明を適用したトランスコーダ101の他
の構成を示すブロック図である。
FIG. 68 is a block diagram showing another configuration of the transcoder 101 to which the present invention is applied.

【図69】履歴情報の項目の組み合わせを説明する図で
ある。
FIG. 69 is a diagram illustrating a combination of items of history information.

【図70】図68のトランスコーダ101の動作を説明
するフローチャートである。
70 is a flowchart illustrating the operation of the transcoder 101 in FIG. 68.

【図71】re_coding_stream_info()のシンタックスを
説明する図である。
Fig. 71 is a diagram for describing the syntax of re_coding_stream_info ().

【図72】red_bw_flag,red_bw_indicatorを説明する
図である。
FIG. 72 is a view for explaining red_bw_flag and red_bw_indicator.

【図73】Re_Coding Information Bus macroblock for
mationを説明する図である。
FIG. 73: Re_Coding Information Bus macroblock for
It is a figure explaining mation.

【図74】Picture rate elementsを説明する図であ
る。
FIG. 74 is a diagram illustrating Picture rate elements.

【図75】Picture rate elementsを説明する図であ
る。
Fig. 75 is a diagram for describing Picture rate elements.

【図76】Picture rate elementsを説明する図であ
る。
FIG. 76 is a view for explaining Picture rate elements.

【図77】Re_Coding Information Busが記録される領
域を説明する図である。
Fig. 77 is a diagram illustrating an area where a Re_Coding Information Bus is recorded.

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

1 符号化装置, 2 復号装置, 3 記録媒体,
12,13 A/D変換器, 14 フレームメモリ,
15 輝度信号フレームメモリ, 16 色差信号フレ
ームメモリ, 17 フォーマット変換回路, 18
エンコーダ,31 デコーダ, 32 フォーマット変
換回路, 33 フレームメモリ,34 輝度信号フレ
ームメモリ, 35 色差信号フレームメモリ, 3
6,37 D/A変換器, 50 動きベクトル検出回
路, 51 フレームメモリ,52 予測モード切り替
え回路, 53 演算器, 54 予測判定回路, 5
5 DCTモード切り替え回路, 56 DCT回路, 57
量子化回路, 58可変長符号化回路, 59 送信
バッファ, 60 逆量子化回路, 61 IDCT回路,
62 演算器, 63 フレームメモリ, 64 動
き補償回路,81 受信バッファ, 82 可変長復号
回路, 83 逆量子化回路, 84IDCT回路, 85
演算器, 86 フレームメモリ, 87 動き補償
回路, 101 トランスコーダ, 102 復号装
置, 103 ヒストリ情報多重化装置, 105 ヒ
ストリ情報分離装置, 106 符号化装置, 11
1 デコーダ, 112 可変長復号回路, 121
エンコーダ,
1 encoding device, 2 decoding device, 3 recording medium,
12, 13 A / D converter, 14 frame memory,
15 luminance signal frame memory, 16 color difference signal frame memory, 17 format conversion circuit, 18
Encoder, 31 decoder, 32 format conversion circuit, 33 frame memory, 34 luminance signal frame memory, 35 color difference signal frame memory, 3
6, 37 D / A converter, 50 motion vector detection circuit, 51 frame memory, 52 prediction mode switching circuit, 53 arithmetic unit, 54 prediction judgment circuit, 5
5 DCT mode switching circuit, 56 DCT circuit, 57
Quantization circuit, 58 variable length coding circuit, 59 transmission buffer, 60 inverse quantization circuit, 61 IDCT circuit,
62 arithmetic unit, 63 frame memory, 64 motion compensation circuit, 81 reception buffer, 82 variable length decoding circuit, 83 inverse quantization circuit, 84 IDCT circuit, 85
Arithmetic unit, 86 frame memory, 87 motion compensation circuit, 101 transcoder, 102 decoding device, 103 history information multiplexing device, 105 history information separating device, 106 encoding device, 11
1 decoder, 112 variable length decoding circuit, 121
Encoder,

─────────────────────────────────────────────────────
────────────────────────────────────────────────── ───

【手続補正書】[Procedure amendment]

【提出日】平成11年12月10日(1999.12.
10)
[Submission date] December 10, 1999 (1999.12.
10)

【手続補正1】[Procedure amendment 1]

【補正対象書類名】図面[Document name to be amended] Drawing

【補正対象項目名】図3[Correction target item name] Figure 3

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【図3】 FIG. 3

【手続補正2】[Procedure amendment 2]

【補正対象書類名】図面[Document name to be amended] Drawing

【補正対象項目名】図12[Correction target item name] FIG.

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【図12】 FIG.

【手続補正3】[Procedure amendment 3]

【補正対象書類名】図面[Document name to be amended] Drawing

【補正対象項目名】図20[Correction target item name] FIG.

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【図20】 FIG.

【手続補正4】[Procedure amendment 4]

【補正対象書類名】図面[Document name to be amended] Drawing

【補正対象項目名】図39[Correction target item name] FIG.

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【図39】 FIG. 39

Claims (15)

【特許請求の範囲】[Claims] 【請求項1】 入力された第1の符号化ストリームから
第2の符号化ストリームを生成し、出力するストリーム
生成装置において、 前記第1の符号化ストリームの過去の符号化処理におけ
る符号化履歴を検出する検出手段と、 前記検出手段の検出結果を利用して、前記第1の符号化
ストリームを符号化して前記第2の符号化ストリームを
生成する符号化手段と、 前記第2の符号化ストリームに対して、それまでの符号
化処理における符号化履歴の組み合わせを表す組み合わ
せ情報を記述する記述手段とを備えることを特徴とする
ストリーム生成装置。
1. A stream generating apparatus for generating and outputting a second encoded stream from an input first encoded stream, wherein the encoding history in a past encoding process of the first encoded stream is Detecting means for detecting; coding means for coding the first coded stream to generate the second coded stream by using the detection result of the detecting means; and the second coded stream And a description unit for describing combination information indicating a combination of encoding histories in the encoding process up to that time.
【請求項2】 前記符号化手段は、MPEG方式で符号化を
行うことを特徴とする請求項1に記載のストリーム生成
装置。
2. The stream generating apparatus according to claim 1, wherein said encoding means performs encoding by an MPEG system.
【請求項3】 前記記述手段は、前記符号化履歴の組み
合わせを表す組み合わせ情報を、前記MPEG方式の前記第
2のストリームのuser_dataとして記述することを特徴
とする請求項2に記載のストリーム生成装置。
3. The stream generation apparatus according to claim 2, wherein the description unit describes combination information indicating a combination of the encoding histories as user_data of the second stream of the MPEG system. .
【請求項4】 入力された第1の符号化ストリームから
第2の符号化ストリームを生成し、出力するストリーム
生成装置のストリーム生成方法において、 前記第1の符号化ストリームの過去の符号化処理におけ
る符号化履歴を検出する検出ステップと、 前記検出ステップでの検出結果を利用して、前記第1の
符号化ストリームを符号化して前記第2の符号化ストリ
ームを生成する符号化ステップと、 前記第2の符号化ストリームに対して、それまでの符号
化処理における符号化履歴の組み合わせを表す組み合わ
せ情報を記述する記述ステップとを含むことを特徴とす
るストリーム生成方法。
4. A stream generation method of a stream generation device for generating and outputting a second coded stream from an input first coded stream, wherein the stream generation method includes the steps of: A detecting step of detecting an encoding history; an encoding step of encoding the first encoded stream to generate the second encoded stream by using a detection result in the detecting step; A description step of describing combination information indicating a combination of encoding histories in the encoding process up to that time for the two encoded streams.
【請求項5】 入力された第1の符号化ストリームから
第2の符号化ストリームを生成し、出力するストリーム
生成装置を制御するプログラムにおいて、 前記第1の符号化ストリームの過去の符号化処理におけ
る符号化履歴を検出する検出ステップと、 前記検出ステップでの検出結果を利用して、前記第1の
符号化ストリームを符号化して前記第2の符号化ストリ
ームを生成する符号化ステップと、 前記第2の符号化ストリームに対して、それまでの符号
化処理における符号化履歴の組み合わせを表す組み合わ
せ情報を記述する記述ステップとを含むことを特徴とす
るコンピュータが読み取り可能なプログラムが記録され
ている記録媒体。
5. A program for controlling a stream generation device that generates and outputs a second coded stream from an input first coded stream, the program comprising: A detecting step of detecting an encoding history; an encoding step of encoding the first encoded stream to generate the second encoded stream by using a detection result in the detecting step; A description step of describing combination information indicating a combination of encoding histories in the encoding process up to that time with respect to the second encoded stream. Medium.
【請求項6】 所定のメディアを介して符号化ストリー
ムを伝送するストリーム伝送装置において、 過去の符号化処理において使用された複数の符号化パラ
メータから所定の符号化パラメータを選択的に組み合わ
せる組み合わせ手段と、 前記組み合わせ手段により組み合わされた前記符号化パ
ラメータの履歴を表す符号化履歴情報を生成する生成手
段と、 前記生成手段により生成された前記符号化履歴情報を、
前記符号化ストリームに重乗して前記メディアに伝送す
る伝送手段とを備えることを特徴とするストリーム伝送
装置。
6. A stream transmitting apparatus for transmitting an encoded stream via a predetermined medium, comprising: a combination means for selectively combining predetermined encoding parameters from a plurality of encoding parameters used in past encoding processing; Generating means for generating encoding history information indicating the history of the encoding parameters combined by the combination means, the encoding history information generated by the generating means,
A transmission means for multiplying the coded stream and transmitting the multiplexed stream to the medium.
【請求項7】 前記符号化ストリームは、MPEG方式で符
号化されていることを特徴とする請求項6に記載のスト
リーム伝送装置。
7. The stream transmission device according to claim 6, wherein the encoded stream is encoded by an MPEG method.
【請求項8】 前記重乗手段は、前記符号化履歴情報
を、前記符号化ストリームにuser_dataとして重乗する
ことを特徴とする請求項6に記載のストリーム生成装
置。
8. The stream generation apparatus according to claim 6, wherein the multiplication unit multiplies the encoding history information as the user_data on the encoded stream.
【請求項9】 所定のメディアを介して符号化ストリー
ムを伝送するストリーム伝送装置のストリーム伝送方法
において、 過去の符号化処理において使用された複数の符号化パラ
メータから所定の符号化パラメータを選択的に組み合わ
せる組み合わせステップと、 前記組み合わせステップの処理により組み合わされた前
記符号化パラメータの履歴を表す符号化履歴情報を生成
する生成ステップと、 前記生成ステップの処理により生成された前記符号化履
歴情報を、前記符号化ストリームに重乗して前記メディ
アに伝送する伝送ステップとを含むことを特徴とするス
トリーム伝送方法。
9. A stream transmission method of a stream transmission apparatus for transmitting an encoded stream via a predetermined medium, wherein the predetermined encoding parameter is selectively selected from a plurality of encoding parameters used in a past encoding process. A combining step of combining, a generating step of generating coding history information representing a history of the coding parameters combined by the processing of the combining step, and the coding history information generated by the processing of the generating step, Transmitting the encoded stream to the medium by multiplying the encoded stream.
【請求項10】 所定のメディアを介して符号化ストリ
ームを伝送するストリーム伝送装置を制御するプログラ
ムにおいて、 過去の符号化処理において使用された複数の符号化パラ
メータから所定の符号化パラメータを選択的に組み合わ
せる組み合わせステップと、 前記組み合わせステップの処理により組み合わされた前
記符号化パラメータの履歴を表す符号化履歴情報を生成
する生成ステップと、 前記生成ステップの処理により生成された前記符号化履
歴情報を、前記符号化ストリームに重乗して前記メディ
アに伝送する伝送ステップとを含むことを特徴とするコ
ンピュータが読み取り可能なプログラムが記録されてい
る記録媒体。
10. A program for controlling a stream transmission apparatus for transmitting an encoded stream via a predetermined medium, wherein the program selectively selects a predetermined encoding parameter from a plurality of encoding parameters used in a past encoding process. A combining step of combining, a generating step of generating coding history information representing a history of the coding parameters combined by the processing of the combining step, and the coding history information generated by the processing of the generating step, And transmitting the encoded stream to the medium by superimposing the encoded stream on the encoded stream.
【請求項11】 入力された第1の符号化ストリームを
符号化して第2の符号化ストリームを生成する符号化装
置において、 前記第1の符号化ストリームに記述されている、その第
1の符号化ストリームのそれまでの符号化処理における
符号化パラメータの組み合わせを表す組み合わせ情報を
検出する検出手段と、 前記検出手段により検出された前記組み合わせ情報に基
づいて、前記第1の符号化ストリームのそれまでの符号
化処理における符号化パラメータを抽出する抽出手段
と、 前記抽出手段により抽出された符号化パラメータに基づ
いて、前記第1の符号化ストリームを第2の符号化スト
リームに符号化する符号化手段とを備えることを特徴と
する符号化装置。
11. An encoding device that encodes an input first coded stream to generate a second coded stream, wherein the first code described in the first coded stream is Detecting means for detecting combination information representing a combination of encoding parameters in the encoding process up to that of the first encoded stream, based on the combination information detected by the detecting means, Extracting means for extracting an encoding parameter in the encoding processing of the above, and encoding means for encoding the first encoded stream into a second encoded stream based on the encoding parameter extracted by the extracting means. An encoding device comprising:
【請求項12】 前記符号化手段は、MPEG方式で符号化
を行うことを特徴とする請求項11に記載の符号化装
置。
12. The encoding apparatus according to claim 11, wherein said encoding means performs encoding by an MPEG method.
【請求項13】 前記検出手段は、前記組み合わせ情報
を、前記第1の符号化ストリームのuser_dataから検出
することを特徴とする請求項11に記載の符号化装置。
13. The encoding apparatus according to claim 11, wherein the detection unit detects the combination information from user_data of the first encoded stream.
【請求項14】 入力された第1の符号化ストリームを
符号化して第2の符号化ストリームを生成する符号化装
置の符号化方法において、 前記第1の符号化ストリームに記述されている、その第
1の符号化ストリームのそれまでの符号化処理における
符号化パラメータの組み合わせを表す組み合わせ情報を
検出する検出ステップと、 前記検出ステップの処理により検出された前記組み合わ
せ情報に基づいて、前記第1の符号化ストリームのそれ
までの符号化処理における符号化パラメータを抽出する
抽出ステップと、 前記抽出ステップの処理により抽出された符号化パラメ
ータに基づいて、前記第1の符号化ストリームを第2の
符号化ストリームに符号化する符号化ステップとを含む
ことを特徴とする符号化方法。
14. An encoding method of an encoding device for encoding an input first encoded stream to generate a second encoded stream, wherein the encoding method is described in the first encoded stream. A detecting step of detecting combination information indicating a combination of encoding parameters in the previous encoding processing of the first encoded stream; and the first step based on the combination information detected by the processing of the detecting step An extraction step of extracting an encoding parameter in a previous encoding process of the encoded stream, and a second encoding process of the first encoded stream based on the encoding parameter extracted by the extraction step. Encoding step of encoding the stream.
【請求項15】 入力された第1の符号化ストリームを
符号化して第2の符号化ストリームを生成する符号化装
置を制御するプログラムにおいて、 前記第1の符号化ストリームに記述されている、その第
1の符号化ストリームのそれまでの符号化処理における
符号化パラメータの組み合わせを表す組み合わせ情報を
検出する検出ステップと、 前記検出ステップの処理により検出された前記組み合わ
せ情報に基づいて、前記第1の符号化ストリームのそれ
までの符号化処理における符号化パラメータを抽出する
抽出ステップと、 前記抽出ステップの処理により抽出された符号化パラメ
ータに基づいて、前記第1の符号化ストリームを第2の
符号化ストリームに符号化する符号化ステップとを含む
ことを特徴とするコンピュータが読み取り可能なプログ
ラムが記録されている記録媒体。
15. A program for controlling an encoding device that encodes an input first encoded stream to generate a second encoded stream, the program including a description of the first encoded stream. A detecting step of detecting combination information indicating a combination of encoding parameters in the previous encoding processing of the first encoded stream; and the first step based on the combination information detected by the processing of the detecting step An extraction step of extracting an encoding parameter in a previous encoding process of the encoded stream, and a second encoding process of the first encoded stream based on the encoding parameter extracted by the extraction step. Encoding the stream into a stream. A recording medium on which a program is recorded.
JP34315699A 1999-02-09 1999-12-02 Encoded stream conversion apparatus, encoded stream conversion method, stream output apparatus, and stream output method Expired - Fee Related JP4139983B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP34315699A JP4139983B2 (en) 1999-02-09 1999-12-02 Encoded stream conversion apparatus, encoded stream conversion method, stream output apparatus, and stream output method

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
JP11-31944 1999-02-09
JP3194499 1999-02-09
JP34315699A JP4139983B2 (en) 1999-02-09 1999-12-02 Encoded stream conversion apparatus, encoded stream conversion method, stream output apparatus, and stream output method

Publications (3)

Publication Number Publication Date
JP2000299856A true JP2000299856A (en) 2000-10-24
JP2000299856A5 JP2000299856A5 (en) 2006-06-15
JP4139983B2 JP4139983B2 (en) 2008-08-27

Family

ID=26370462

Family Applications (1)

Application Number Title Priority Date Filing Date
JP34315699A Expired - Fee Related JP4139983B2 (en) 1999-02-09 1999-12-02 Encoded stream conversion apparatus, encoded stream conversion method, stream output apparatus, and stream output method

Country Status (1)

Country Link
JP (1) JP4139983B2 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006502605A (en) * 2002-01-22 2006-01-19 マイクロソフト コーポレーション Method and system for preventing start code emulation and filling data
JP2015122768A (en) * 2005-03-09 2015-07-02 クゥアルコム・インコーポレイテッドQualcomm Incorporated Region-of-interest extraction for video telephony
WO2019053932A1 (en) * 2017-09-13 2019-03-21 株式会社Jvcケンウッド Transcoding device, transcoding method and transcoding program
US10271069B2 (en) 2016-08-31 2019-04-23 Microsoft Technology Licensing, Llc Selective use of start code emulation prevention

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006502605A (en) * 2002-01-22 2006-01-19 マイクロソフト コーポレーション Method and system for preventing start code emulation and filling data
JP2009246995A (en) * 2002-01-22 2009-10-22 Microsoft Corp Methods and systems for start code emulation prevention and data stuffing
JP2015122768A (en) * 2005-03-09 2015-07-02 クゥアルコム・インコーポレイテッドQualcomm Incorporated Region-of-interest extraction for video telephony
US10271069B2 (en) 2016-08-31 2019-04-23 Microsoft Technology Licensing, Llc Selective use of start code emulation prevention
WO2019053932A1 (en) * 2017-09-13 2019-03-21 株式会社Jvcケンウッド Transcoding device, transcoding method and transcoding program
JP2019054335A (en) * 2017-09-13 2019-04-04 株式会社Jvcケンウッド Transcoding device, transcoding method, and transcoding program
US11375216B2 (en) 2017-09-13 2022-06-28 Jvckenwood Corporation Transcoding apparatus, transcoding method, and transcoding program

Also Published As

Publication number Publication date
JP4139983B2 (en) 2008-08-27

Similar Documents

Publication Publication Date Title
KR100571307B1 (en) Coding Systems and Methods, Coding Devices and Methods, Decoding Devices and Methods, Recording Devices and Methods, and Reproducing Devices and Methods
KR100729541B1 (en) Transcoding System Using Coding History Information
JP2001169292A (en) Device and method for processing information, and storage medium
JP3724205B2 (en) Decoding device and method, and recording medium
JP3874153B2 (en) Re-encoding device and re-encoding method, encoding device and encoding method, decoding device and decoding method, and recording medium
JP3724203B2 (en) Encoding apparatus and method, and recording medium
JP3724204B2 (en) Encoding apparatus and method, and recording medium
JP3890838B2 (en) Encoded stream conversion apparatus, encoded stream conversion method, and recording medium
JP4139983B2 (en) Encoded stream conversion apparatus, encoded stream conversion method, stream output apparatus, and stream output method
JP4016290B2 (en) Stream conversion device, stream conversion method, encoding device, encoding method, and recording medium
JP4539637B2 (en) Stream recording apparatus and stream recording method, stream reproduction apparatus and stream reproduction method, stream transmission apparatus and stream transmission method, and program storage medium
JP3817951B2 (en) Stream transmission apparatus and method, and recording medium
JP3817952B2 (en) Re-encoding device and method, encoding device and method, and recording medium
JP4543321B2 (en) Playback apparatus and method
JP4482811B2 (en) Recording apparatus and method
JP4016294B2 (en) Encoding apparatus and encoding method, stream conversion apparatus and stream conversion method, and recording medium
JP4478630B2 (en) Decoding device, decoding method, program, and recording medium
JP3724202B2 (en) Image data processing apparatus and method, and recording medium
JP4016293B2 (en) Encoding apparatus, encoding method, and recording medium
JP4016348B2 (en) Stream conversion apparatus, stream conversion method, and recording medium
JP4016349B2 (en) Stream conversion apparatus, stream conversion method, and recording medium
JP4016347B2 (en) Stream conversion apparatus, stream conversion method, and recording medium
JP2000059770A (en) Data transmitter and its transmitting method, and providing medium
JP2007124704A (en) Decoder and decoding method, transmitter and transmitting method, and recording medium

Legal Events

Date Code Title Description
A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20060413

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20060413

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20080513

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: 20080515

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080528

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

Free format text: PAYMENT UNTIL: 20110620

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20110620

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20120620

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20120620

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20130620

Year of fee payment: 5

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees