JP2015171114A - Moving image encoder - Google Patents
Moving image encoder Download PDFInfo
- Publication number
- JP2015171114A JP2015171114A JP2014047043A JP2014047043A JP2015171114A JP 2015171114 A JP2015171114 A JP 2015171114A JP 2014047043 A JP2014047043 A JP 2014047043A JP 2014047043 A JP2014047043 A JP 2014047043A JP 2015171114 A JP2015171114 A JP 2015171114A
- Authority
- JP
- Japan
- Prior art keywords
- picture
- encoding
- buffer
- failure
- buffer failure
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Landscapes
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
本発明は、MPEG−2方式やH.264方式による動画像符号化装置に関し、特に、高解像度の動画像データを複数の圧縮符号化装置を用いて並列処理し、得られた複数のビットストリームを一つのビットストリームに多重する符号化方法および装置に関するものである。 The present invention relates to the MPEG-2 system and H.264. More particularly, the present invention relates to a video encoding apparatus using the H.264 method, and in particular, an encoding method for processing high-resolution video data in parallel using a plurality of compression encoding apparatuses and multiplexing a plurality of obtained bit streams into one bit stream. And the apparatus.
近年、デジタル信号処理の進歩により、動画像や静止画像、音声等、大量のデジタル情報を高能率で符号化し、小型の記録媒体へ記録したり、通信媒体による伝送を行ったりすることが可能になっている。 Recent advances in digital signal processing enable high-efficiency encoding of large amounts of digital information, such as moving images, still images, and audio, to be recorded on a small recording medium or transmitted via a communication medium. It has become.
このような技術を応用して、テレビ放送やビデオカメラで撮影した動画像をストリームに変換できる動画像符号化装置の開発が行われている。 By applying such technology, a moving image encoding apparatus capable of converting a moving image taken by a television broadcast or a video camera into a stream has been developed.
さらに近年、業務用の映像機器や大型テレビでは、映像信号の画面サイズを、従来のHDTV(1920ピクセルx1080ライン)よりもさらに大きな4k2k(4096x2160あるいは3840x2160)や8k4k(7680x4320)まで高解像度化したり、フレームレートを120Hzや240Hz等の高フレームレート化したりすることによって画質を向上する技術が提案されている。 In recent years, in video equipment for business use and large televisions, the screen size of video signals has been increased to 4k2k (4096x2160 or 3840x2160) or 8k4k (7680x4320), which is larger than conventional HDTV (1920 pixels x 1080 lines), Techniques have been proposed for improving the image quality by increasing the frame rate to 120 Hz or 240 Hz.
一般に、このような業務用映像機器の動画符号化装置は、編集環境の利便性を考慮し、画面内予測(イントラピクチャ)のみを用いた符号化が行われることが多い。 In general, such a moving image encoding device for professional video equipment is often encoded using only intra prediction (intra-picture) in consideration of the convenience of the editing environment.
しかし上記の大きな画面解像度や、高速なフレームレートの映像信号を符号化処理する場合、従来の映像信号より情報量が増大することから、高速処理可能な高性能の動画像符号化装置が必要になってしまうという問題が発生する。 However, when encoding video signals with the above large screen resolution and high frame rate, the amount of information increases compared to conventional video signals, so a high-performance video encoding device capable of high-speed processing is required. The problem of becoming.
上記の問題を解決し、高解像度あるいは高フレームレートの映像信号が入力された場合でも従来の符号化装置を利用して、符号化ストリーム出力を実現する手段として以下の先行技術が提案されている。 The following prior art has been proposed as means for realizing the encoded stream output using the conventional encoding apparatus even when a video signal having a high resolution or a high frame rate is input, in order to solve the above problems. .
特許文献1では、入力画像を複数の画像信号に画面分割し、分割画像毎に複数の符号化装置を用いた符号化を行う。 In Patent Document 1, an input image is divided into a plurality of image signals, and encoding using a plurality of encoding devices is performed for each divided image.
この時、それぞれの符号化装置のビットレートの総和が、所定の値となるようにビットレート割り当てを行うという構成が開示されている。 At this time, a configuration is disclosed in which the bit rate is assigned so that the sum of the bit rates of the respective encoding devices becomes a predetermined value.
割り当てるビットレートは、バッファ(VBVバッファ)をアンダーフローさせないために常に少な目に目標符号量を設定する。 The target bit rate is always set to a small bit rate so that the buffer (VBV buffer) does not underflow.
特許文献2では、高フレームレートの映像入力を、複数の符号化装置へフレーム毎に分配して一本のビットストリームを出力する構成を有し、半分のフレームレートで分配した映像入力を、従来のフレームレート期間で並列符号化するという構成が開示されている。 In Patent Document 2, a high frame rate video input is distributed to a plurality of encoding devices for each frame and a single bit stream is output, and a video input distributed at a half frame rate is conventionally used. A configuration is disclosed in which parallel encoding is performed in the frame rate period.
そして、一つのビットストリームとして多重化する時、各符号化装置のフレーム参照関係が正しく保たれるようにヘッダ情報を更新する手段を有することを特徴としている。 And when multiplexing as one bit stream, it has the means to update a header information so that the frame reference relationship of each encoding apparatus may be maintained correctly.
このように上記の先行技術によれば、従来よりも大きな高解像度あるいは高フレームレートの入力映像であっても、複数の符号化装置を並列処理することで符号化に伴う処理負荷を分散させることが実現できるようになる。 As described above, according to the above-described prior art, even if the input video has a higher resolution or higher frame rate than the conventional one, the processing load associated with the encoding can be distributed by parallel processing a plurality of encoding devices. Can be realized.
しかしながら特許文献1においては、画面全体のピクチャデータ符号量を、画面分割数に応じて平均的に各動画像符号化装置に目標符号量を割り当てている。 However, in Patent Document 1, the target code amount is assigned to each moving image encoding device on the average with respect to the picture data code amount of the entire screen according to the number of screen divisions.
そのため、一部の領域だけが高周波成分の多い複雑な絵柄の場合、その領域だけ画質劣化が目立ってしまう可能性がある。 For this reason, when only a part of the region is a complex picture with many high-frequency components, image quality degradation may be noticeable only in that region.
また、特許文献2による入力画像を分配して並列処理する構成の場合、上述のような画面分割した一部の領域での画質劣化は回避されるものの、次の問題が新たに発生する。
その問題を下図1および2を用いて説明する。
Further, in the case of the configuration in which the input image according to Patent Document 2 is distributed and processed in parallel, the image quality degradation in the partial area divided as described above is avoided, but the following problem newly occurs.
The problem will be described with reference to FIGS. 1 and 2 below.
図1には、二つの符号化装置で符号化した場合の動作タイミング例を、図2には当該動作時にバッファアンダーフローが発生してしまった場合のバッファ遷移を図示した。 FIG. 1 illustrates an example of operation timing when encoding is performed by two encoding apparatuses, and FIG. 2 illustrates buffer transition when a buffer underflow occurs during the operation.
図1の動作タイミングのように、入力画像が一画面単位にフレーム周期で入力され、各符号化装置に一画面ずつ交互に転送される。 As in the operation timing of FIG. 1, an input image is input in a frame period in units of one screen, and is alternately transferred to each encoding device one screen at a time.
そのため、符号化装置単体にとっては、最大2倍のフレーム周期期間を符号化処理時間として使用することができるようになる。 Therefore, for a single encoding apparatus, a maximum frame period of twice can be used as the encoding processing time.
一方、符号化対象画像の符号化順番で見ると、Pic2と3、Pic3と4のように同じフレーム周期期間に二つのピクチャ符号化を同時に行っている。 On the other hand, when viewed in the encoding order of the encoding target images, two picture encodings are simultaneously performed in the same frame period period as Pic 2 and 3 and Pic 3 and 4.
このことから、一方の符号化器でピクチャ符号化をしている途中にも、同時にもう一方の符号化器で、ストリーム出力時を仮定したバッファモデルシミュレーションを行わなければならない。 For this reason, even while picture encoding is being performed by one encoder, a buffer model simulation assuming the stream output time must be performed simultaneously by the other encoder.
そのため、図2のように一方の符号化装置においてバッファをアンダーフローしてしまうピクチャデータが発生してしまった時(201)、並列処理中の他方の符号化ピクチャにおいても、符号化開始前のバッファモデルシミュレーション結果と実際のバッファ占有量が異なり、図中dt1とdt2のタイミングで連続してアンダーフローしてしまう(202)問題が発生する。 Therefore, when picture data that causes the buffer to underflow in one encoding device as shown in FIG. 2 occurs (201), the other encoded picture that is being processed in parallel is also in the state before the start of encoding. The buffer model simulation result and the actual buffer occupancy amount are different, and a problem arises that the underflow continuously occurs at the timings dt1 and dt2 in the figure (202).
一般的に、1パス構成の符号化装置においてバッファアンダーフローするピクチャ発生時は、当該ピクチャのビットストリーム出力を破棄し、予め用意した全てのマクロブロックが前方フレーム参照するコピーピクチャに置換する回避方法が知られている。 In general, when a picture that causes buffer underflow occurs in a one-pass encoding device, a method for avoiding the bitstream output of the picture being discarded and replacing all prepared macroblocks with copy pictures that refer to the forward frame It has been known.
しかしながら、前述のような業務用の映像機器で使用される符号化装置では、編集時に利便性の高いイントラピクチャのみで符号化しているため、フレーム参照予測を用いたコピーピクチャによるバッファ破綻回避策は実施できない制約がある。 However, since the encoding apparatus used in the above-mentioned professional video equipment encodes only with an intra picture that is highly convenient at the time of editing, there is no buffer failure avoidance measure by copy picture using frame reference prediction. There are restrictions that cannot be implemented.
本発明では上述の点に鑑み、複数の符号化器を用いた動画像符号化装置において、バッファ破綻から即時復帰できるようにすることを目的とする。 In view of the above-described points, an object of the present invention is to make it possible to immediately recover from a buffer failure in a video encoding apparatus using a plurality of encoders.
上述の課題を解決するため、本発明の動画像符号化装置は、一つの入力映像信号を複数の符号化器に分配し、各符号化器でピクチャ単位の画面内符号化処理を並列に実行した後、複数のビットストリームの多重化された一つのビットストリームを出力する動画像符号化装置であって、前記符号化器による符号化処理時にバッファ破綻を検出するバッファ破綻検知手段と、バッファ破綻発生の情報を他方の符号化器に送信するバッファ破綻送信手段と、前記バッファ破綻発生の情報を受信するバッファ破綻受信手段と、符号化ピクチャの次のピクチャに対して、前記バッファ破綻発生の後の発生符号量を抑制して、符号化を行わせる符号化制御手段と、バッファ破綻が発生した符号化ピクチャデータのビットストリーム出力を破棄するピクチャデータ破棄手段と、符号化ピクチャの次のピクチャを、繰り返しビットストリームとして出力するピクチャデータリピート出力手段とを具備することを特徴とする。 In order to solve the above-described problems, the moving image encoding apparatus of the present invention distributes one input video signal to a plurality of encoders, and performs intra-picture encoding processing in units of pictures in each encoder in parallel. And a buffer failure detection means for detecting a buffer failure during the encoding process by the encoder, and a buffer failure detection device for outputting a single bitstream in which a plurality of bitstreams are multiplexed. A buffer failure transmitting means for transmitting the generated information to the other encoder; a buffer failure receiving means for receiving the information on the occurrence of the buffer failure; Encoding control means for performing encoding while suppressing the generated code amount, and a picture for discarding the bitstream output of encoded picture data in which a buffer failure has occurred And over data discarding means, the next picture coded picture, characterized by comprising a picture data repeat outputting means for outputting a repeated bit stream.
本発明によれば、複数の符号化器を用いた動画像符号化装置において、バッファ破綻から即時復帰できるようになる。 According to the present invention, in a video encoding apparatus using a plurality of encoders, it is possible to immediately recover from a buffer failure.
(実施形態1)
<システム構成>
図3には、本実施形態に係る動画像符号化装置のシステム構成を示した。
(Embodiment 1)
<System configuration>
FIG. 3 shows a system configuration of the video encoding apparatus according to the present embodiment.
当該符号化装置は、分配器301、第一の符号化器302、フレームバッファメモリ303、第二の符号化器304、バッファ破綻送受信ポート305、そして多重化器306から構成される。 The encoding apparatus includes a distributor 301, a first encoder 302, a frame buffer memory 303, a second encoder 304, a buffer failure transmission / reception port 305, and a multiplexer 306.
分配器301は、入力映像フレームレートを符号化装置の個数で分周した期間毎に、入力映像データを後段の符号化装置へ分配する。 The distributor 301 distributes the input video data to the subsequent encoding apparatus for each period obtained by dividing the input video frame rate by the number of encoding apparatuses.
例えば、60Hzの入力映像を30Hzの周期で、符号化装置301と304へ交互に転送するような動作をする。 For example, an operation is performed in which 60 Hz input video is alternately transferred to the encoding devices 301 and 304 at a cycle of 30 Hz.
符号化器302は、分配器301から転送された1画面分の映像データを内部のフレームバッファメモリ303へ蓄積し、当該メモリに蓄積した映像データを現画像として、前述の各種フォーマットによる符号化を行う。 The encoder 302 stores the video data for one screen transferred from the distributor 301 in the internal frame buffer memory 303, and uses the video data stored in the memory as the current image to perform encoding in the various formats described above. Do.
本発明の符号化器では特に断りの無い限り、H.264(AVC)方式の画面内予測モードのみを使用して符号化するものとする。 Unless otherwise specified, the encoder of the present invention is an H.264 standard. It is assumed that encoding is performed using only the intra-screen prediction mode of the H.264 (AVC) system.
同様に第二の符号化器304は、入力された映像データを圧縮符号化し、符号化ピクチャデータを出力する。 Similarly, the second encoder 304 compresses and encodes the input video data and outputs encoded picture data.
また、符号化器302および304の間では、後述するバッファ破綻の有無を相互に送受信するため専用ポート305を備える。 In addition, a dedicated port 305 is provided between the encoders 302 and 304 in order to transmit / receive the presence / absence of a buffer failure described later.
実施形態1、実施形態2、実施形態3では、特に断りの無い限り二つの符号化装置を並列処理する前提で動作内容を記載する。 In the first embodiment, the second embodiment, and the third embodiment, the operation content is described on the premise that two coding apparatuses are processed in parallel unless otherwise specified.
多重化器306は、前記各符号化器から出力された符号化ピクチャデータを、入力映像順の並びになるように一本のビットストリームとして多重化を行う。 The multiplexer 306 multiplexes the encoded picture data output from each of the encoders as one bit stream so as to be in the order of input video.
以上が本発明の実施形態1におけるシステム構成となる。 The above is the system configuration in Embodiment 1 of the present invention.
<ブロック構成>
続いて図4には前記システム構成で説明した、複数構成から成る符号化器302および304共通の内部処理ブロックを示した。
<Block configuration>
Next, FIG. 4 shows internal processing blocks common to the encoders 302 and 304 having a plurality of configurations described in the system configuration.
当該符号化装置は、リピート出力制御部401、バッファ破綻受信部402、ピクチャ符号化部403、目標符号量設定部404、ビットストリーム出力部405、バッファ破綻送信部406から構成される。 The encoding apparatus includes a repeat output control unit 401, a buffer failure receiving unit 402, a picture encoding unit 403, a target code amount setting unit 404, a bit stream output unit 405, and a buffer failure transmitting unit 406.
以下、各ブロックの機能、およびブロック間の制御内容について説明する。 Hereinafter, the function of each block and the control content between the blocks will be described.
尚、本発明を適用する上記のブロックは、ASIC等の専用ハードウェアとして実現しても良いし、符号化装置内に具備された図示せぬCPU等のプロセッサ上で動作するプログラムとして実現しても良いものとし、特に限定しないものとする。 The above blocks to which the present invention is applied may be realized as dedicated hardware such as an ASIC, or as a program operating on a processor such as a CPU (not shown) provided in the encoding apparatus. It shall be good and not particularly limited.
リピート出力制御部401は、バッファ破綻受信部402からのバッファ破綻有無通知に基づいて、次回当該符号化装置において符号化するピクチャデータを、繰り返し出力する制御信号を、ビットストリーム出力部401へ発行する。 The repeat output control unit 401 issues, to the bit stream output unit 401, a control signal for repeatedly outputting the picture data to be encoded in the encoding device next time based on the buffer failure presence / absence notification from the buffer failure receiving unit 402. .
バッファ破綻受信部402は、符号化装置間で割り込み信号等の専用ポートを用いて、他方の符号化装置においてバッファ破綻してしまうほどの大きなピクチャデータが発生したことを検出する。 The buffer failure receiving unit 402 uses a dedicated port such as an interrupt signal between the encoding devices to detect that large picture data is generated so as to cause a buffer failure in the other encoding device.
バッファ破綻を検出した時は、リピート出力制御部401と目標符号量設定部404に即時に当該破綻の有無を通知する。 When a buffer failure is detected, the repeat output control unit 401 and the target code amount setting unit 404 are immediately notified of the presence or absence of the failure.
ピクチャ符号化部403は、バッファメモリ302に格納された入力画像に対して画面内符号化モードで画像圧縮を行い、符号化ピクチャデータをビットストリーム出力部405へ転送する。 The picture encoding unit 403 performs image compression on the input image stored in the buffer memory 302 in the in-screen encoding mode, and transfers the encoded picture data to the bit stream output unit 405.
またピクチャ符号化403は、目標符号量設定部404からの符号化パラメタ設定に基づき、量子化制御や予測モード選択、エントロピー符号化を内部動作として切り替える。 The picture encoding 403 switches quantization control, prediction mode selection, and entropy encoding as internal operations based on the encoding parameter setting from the target code amount setting unit 404.
そして、符号化開始時に予め設定されたバッファ上のピクチャデータ占有量と目標発生符号量を監視し、バッファアンダーフローとなるデータサイズのピクチャデータを符号化してしまった場合には、その旨をバッファ破綻送信部406に通知する。 When the picture data occupancy and the target generated code quantity in the buffer set in advance at the start of encoding are monitored and picture data having a data size that causes buffer underflow is encoded, this is indicated in the buffer. The failure transmitting unit 406 is notified.
目標符号量設定部404は、バッファ破綻受信部402からの他方の符号化装置でのバッファ破綻情報、バッファ破綻送信部406からの当該符号化でのバッファ破綻発生情報、およびピクチャ符号化部403からピクチャ単位で符号化完了ピクチャの発生符号量を受け取る。 The target code amount setting unit 404 receives the buffer failure information in the other encoding device from the buffer failure receiving unit 402, the buffer failure occurrence information in the encoding from the buffer failure transmitting unit 406, and the picture encoding unit 403. Receives a generated code amount of a picture that has been encoded in units of pictures.
上記バッファ破綻情報と、符号化ピクチャの発生符号量を元に、バッファモデルの占有位置をシミュレーションし、次回符号化するピクチャ、または、現在符号化途中のピクチャがバッファアンダーフローおよびオーバフローしないように目標となる発生符号量の計算と設定を行う。 Based on the above buffer failure information and the amount of code generated in the encoded picture, the buffer model occupancy position is simulated, and the target is to prevent the next encoded picture or the picture currently being encoded from overflowing or overflowing the buffer. The generated code amount is calculated and set.
ビットストリーム出力部405は、ピクチャ符号化部403が出力した符号化済みピクチャデータを受信し、リピート出力制御部401からの当該ピクチャデータの繰り返し出力制御信号、およびバッファ破綻送信部406からの当該ピクチャデータの出力停止制御信号に基づいて、後段の多重化器106へビットストリーム出力を行う。 The bitstream output unit 405 receives the encoded picture data output from the picture encoding unit 403, repeats the output control signal of the picture data from the repeat output control unit 401, and the picture from the buffer failure transmission unit 406 Based on the data output stop control signal, a bit stream is output to the subsequent multiplexer 106.
バッファ破綻送信部406は、ピクチャ符号化部403で発生したバッファ破綻を受信し、ビットストリーム出力部405へ当該ピクチャデータのビットストリーム出力をスキップする制御信号の発行と、他方の符号化装置および目標符号量設定部404に対して、当該符号化装置でのバッファ破綻発生を通知する。 The buffer failure transmitting unit 406 receives the buffer failure generated in the picture encoding unit 403, issues a control signal for skipping the bit stream output of the picture data to the bit stream output unit 405, and the other encoding device and target The code amount setting unit 404 is notified of the occurrence of a buffer failure in the encoding apparatus.
他方の符号化装置への前記バッファ破綻送信手段としては、上述のバッファ破綻受信部402と同様にハードウェアによる専用ポート等によって瞬時に送受信可能な手段が望ましい。 As the buffer failure transmitting means to the other encoding device, a means capable of instantaneously transmitting and receiving via a dedicated port by hardware, etc., as in the above-described buffer failure receiving unit 402 is desirable.
以上が、本発明を適用する符号化装置を構成するブロックの説明である。 The above is the description of the blocks constituting the encoding device to which the present invention is applied.
<破綻送信フロー>
続いて、本発明の特徴となる前述の機能ブロックを用いて実現する破綻検出と、他の符号化装置への送信処理について、図5の各フローチャートを用いて説明する。
<Failure transmission flow>
Next, failure detection realized by using the above-described functional blocks, which is a feature of the present invention, and transmission processing to another encoding apparatus will be described with reference to each flowchart of FIG.
図5(a)において、はじめにステップS501では、当該動画像符号化装置のピクチャ符号化器403においてバッファ破綻が発生したか否かを判断する。 In FIG. 5A, first in step S501, it is determined whether or not a buffer failure has occurred in the picture encoder 403 of the moving picture encoding apparatus.
バッファ破綻が発生していない場合(ステップS501のFALSE)は、本動作フローを終了し当該ピクチャの符号化が完了後、そのままビットストリーム出力部405からピクチャデータを出力する。 If no buffer failure has occurred (FALSE in step S501), the operation flow is terminated, and after the encoding of the picture is completed, the picture data is output from the bitstream output unit 405 as it is.
一方、バッファ破綻が発生した場合(ステップS501のTRUE)は、バッファ破綻送信部406から、即時に他方の符号化装置にバッファ破綻送信を行う(ステップS502)。 On the other hand, when a buffer failure occurs (TRUE in step S501), the buffer failure transmission unit 406 immediately performs buffer failure transmission to the other encoding device (step S502).
バッファ破綻送信後、破綻ピクチャの符号化が終了したかを判断し、符号化が終了するまで待機する(ステップS503)。 After the buffer failure transmission, it is determined whether or not the failure picture has been encoded, and waits until the encoding ends (step S503).
本発明では特に限定しないが、後の破綻復帰処理のフィードバック制御を即時に実行できるためにも、例えばマクロブロック単位等のタイミングで破綻発生が判明した時点で符号化を中断することが望ましい。 Although not particularly limited in the present invention, it is desirable to interrupt the encoding when the occurrence of a failure is found, for example, at the timing of a macroblock unit or the like, so that the feedback control of the subsequent failure recovery process can be executed immediately.
破綻ピクチャの符号化終了後(ステップS503のTRUE)、当該ピクチャデータのビットストリーム出力をスキップする制御信号を、バッファ破綻送信部406からビットストリーム出力部405へ設定し、当該符号化ピクチャを多重化器306への転送を停止する(ステップS504)。 After encoding the failed picture (TRUE in step S503), a control signal for skipping the bit stream output of the picture data is set from the buffer failed transmitting unit 406 to the bit stream output unit 405, and the encoded picture is multiplexed. The transfer to the device 306 is stopped (step S504).
最後に、当該符号化装置で次回符号化するピクチャの目標符号量を設定する(ステップS505)。 Finally, a target code amount of a picture to be encoded next time by the encoding apparatus is set (step S505).
この時設定する目標符号量は、当該符号化装置でバッファ破綻するまでの発生符号量を取得し、当該符号量よりも十分小さいピクチャデータを、他方の符号化装置にて繰り返し出力した後の予測バッファ位置を求めて設定する。 The target code amount to be set at this time is the prediction after the code amount generated until the buffer failure occurs in the encoding device, and the picture data sufficiently smaller than the code amount is repeatedly output in the other encoding device. Find and set the buffer position.
上記ステップによる目標符号量の再計算を行うことで、通常動作時に設定する他方の符号化装置にて符号化中の前ピクチャ発生符号量から導出したバッファ占有量を用いないため、連続したバッファ破綻を事前に回避する。 By recalculating the target code amount according to the above steps, the buffer occupancy derived from the previous picture generation code amount being encoded by the other encoding device set during normal operation is not used, so continuous buffer failure Avoid in advance.
以上が、バッファ破綻送信時の処理フローである。 The processing flow at the time of buffer failure transmission is as described above.
<破綻受信フロー>
続いて、本発明の特徴となる前述の機能ブロックを用いて実現する破綻受信時の処理について、図5(b)のフローチャートを用いて説明する。
<Failure reception flow>
Next, a process at the time of failure reception realized by using the above-described functional block, which is a feature of the present invention, will be described with reference to a flowchart of FIG.
ステップS506では、前記ステップS503にて他方の符号化装置が発行したバッファ破綻の受信処理を行う。 In step S506, reception processing for a buffer failure issued by the other encoding device in step S503 is performed.
バッファ破綻受信が無い場合(ステップS506のFALSE)は、本動作フローを終了し、通常動作の符号化処理を継続する。 If there is no buffer failure reception (FALSE in step S506), the operation flow is terminated and the normal operation encoding process is continued.
一方、バッファ破綻を受信した場合(ステップS506のTRUE)、現在符号化中のピクチャが符号化完了するまで待機する(ステップS507)。 On the other hand, when a buffer failure is received (TRUE in step S506), the process waits until the current encoding picture is completely encoded (step S507).
ピクチャ符号化完了後(ステップS507のTURE)、当該ピクチャの発生符号量からバッファ占有量を更新し、次に符号化するピクチャの目標符号量の割り当てを計算する(ステップS508)。 After completion of picture encoding (TURE in step S507), the buffer occupancy is updated from the generated code amount of the picture, and the allocation of the target code amount of the picture to be encoded next is calculated (step S508).
上記の目標符号量は、破綻発生ピクチャ発生後のバッファ占有量を用いず、当該符号化装置において前回ピクチャ符号化が完了した時点でのバッファ占有量を用いて、バッファ破綻を発生しない十分小さな目標符号量を設定する。 The target code amount is not a buffer occupancy amount after occurrence of a failed picture, but a sufficiently small target that does not cause a buffer failure by using the buffer occupancy amount at the time when the previous picture encoding is completed in the encoding device. Set the code amount.
例えば、現在のバッファ占有量と符号化ビットレートとフレーム周期から計算した蓄積データ量から、今回符号化するピクチャのデコード時間におけるバッファ占有量を予測し、当該占有量の半分に収まるような目標符号量を割り当てる方法等が有効である。 For example, a target code that predicts the buffer occupancy at the decoding time of the picture to be encoded this time from the accumulated amount of data calculated from the current buffer occupancy, the encoding bit rate, and the frame period, and fits in half of the occupancy A method of allocating the amount is effective.
そして、上記目標符号量および各種符号化パラメタを符号化器403へ設定し、ピクチャの符号化処理を開始する(ステップS509)。 Then, the target code amount and various encoding parameters are set in the encoder 403, and the picture encoding process is started (step S509).
続いて発生符号量を抑制するパラメタ設定を行った当該破綻回避用の符号化ピクチャの符号化完了を待ち(ステップS510)、ピクチャ符号化が完了した時点で(ステップS510のTRUE)、リピート出力制御部401に対して当該ピクチャの繰り返し制御を許可する信号を発行する。 Subsequently, the process waits for the completion of coding of the picture for avoiding the failure for which the parameter setting for suppressing the generated code amount is set (step S510), and when the picture coding is completed (TRUE of step S510), repeat output control is performed. A signal for permitting the repetition control of the picture is issued to the unit 401.
前記制御信号によって符号化ピクチャデータをビットストリーム出力部405にて、2回繰り返して出力する(ステップS511)。 According to the control signal, the encoded picture data is output twice repeatedly at the bitstream output unit 405 (step S511).
以上が、本発明によるバッファ破綻受信時の符号化装置における処理フローである。 The above is the processing flow in the encoding apparatus at the time of buffer failure reception according to the present invention.
<出力データ構造>
続いて、本発明による上記動作フローを適用した、各符号化装置の動作タイミング(図6(a))と、出力ビットストームのデータ構造(図6(b))を図6に示した。
<Output data structure>
Next, FIG. 6 shows the operation timing (FIG. 6 (a)) of each encoding apparatus to which the above-described operation flow according to the present invention is applied, and the data structure of the output bit storm (FIG. 6 (b)).
動作タイミング例は、上述の動作フローに従い、符号化器1と符号化器2の二つの符号化装置も用いて、それぞれPic1,3,5,7,9の順番と、Pic2,4,6,8の順番でピクチャ符号化を行った場合である。 The operation timing examples are in accordance with the above-described operation flow, using the two encoding devices of the encoder 1 and the encoder 2, and the order of Pic1, 3, 5, 7, 9 and Pic2, 4, 6, 6, respectively. This is a case where picture coding is performed in the order of 8.
この時、図中の網掛けで示したPic3(601)に相当するピクチャ符号化時にバッファのアンダーフローが発生したものとする。 At this time, it is assumed that an underflow of the buffer has occurred at the time of picture encoding corresponding to Pic3 (601) indicated by shading in the drawing.
アンダーフロー発生直後、符号化器1での符号化は即時に終了し、バッファ破綻発生を符号化器2に、図中602の矢印で示したタイミングで送信する。 Immediately after the occurrence of the underflow, the encoding in the encoder 1 is immediately terminated, and the occurrence of the buffer failure is transmitted to the encoder 2 at the timing indicated by the arrow 602 in the figure.
そして符号化器2は、上記バッファ破綻を受信し、Pic2の符号化完了を待った後、後続ピクチャであるPic4について、破綻受信から符号化完了までに発生する図中603の期間に相当する符号量を前記ステップS507およびS508に基づいて抑制する。 Then, the encoder 2 receives the buffer failure, waits for the completion of the encoding of Pic2, and then, for the subsequent picture Pic4, the code amount corresponding to the period 603 in the figure that occurs from the failure reception to the completion of the encoding Is suppressed based on steps S507 and S508.
上記動作タイミングによって符号化したピクチャデータは、ビットストリーム出力部405での出力制御によって、図中(b)で示した。 The picture data encoded according to the operation timing is indicated by (b) in the figure by the output control in the bit stream output unit 405.
本図では、バッファ破綻ピクチャPic3の出力はスキップし、代わりに発生符号量を抑制してバッファ破綻回避したピクチャPic4を図中604と、605の構造になるように2回繰り返して出力した例である。 In this figure, the output of the buffer failure picture Pic3 is skipped, and instead, the picture Pic4 in which the generated code amount is suppressed and the buffer failure is avoided is output twice so as to have the structure of 604 and 605 in the figure. is there.
以上が、本発明による符号化装置の動作タイミングと、出力ビットストリームのデータ構造例である。 The above is the operation timing of the encoding apparatus according to the present invention and the data structure example of the output bit stream.
<バッファ遷移図>
続いて、本発明による上述の動作フローと動作例を適用して出力したビットストームのバッファ遷移を図7に示した。
<Buffer transition diagram>
Next, FIG. 7 shows a buffer transition of a bit storm output by applying the above-described operation flow and operation example according to the present invention.
本図では、太い実線が符号化器1で符号化したピクチャ符号量であり、破線が符号化器2において符号化したピクチャ符号量として図示した。 In this figure, the bold solid line is the picture code amount encoded by the encoder 1, and the broken line is the picture code amount encoded by the encoder 2.
図6における符号化器2で符号化して、2回繰り返しビットストリーム出力したバッファ破綻回避ピクチャPic4がデコードされるタイミングがdt1とdt2のタイミング(図中701の区間)となる。 The timing at which the buffer failure avoidance picture Pic4 encoded by the encoder 2 in FIG. 6 and output twice as a bitstream is decoded is the timing of dt1 and dt2 (interval 701 in the figure).
この時、バッファ遷移としては2回繰り返して同じ小さなピクチャ符号量を持ったデコードバッファからのピクチャ掃引が行われ、バッファ占有量がアンダーフローと、次ピクチャ符号化時の空き容量を十分確保できるようになる。 At this time, as the buffer transition, the picture sweep from the decoding buffer having the same small picture code amount is repeated twice, so that the buffer occupancy amount is underflow and a sufficient free space can be secured at the next picture encoding. become.
これにより連続したバッファ破綻の回避と、後続する符号化ピクチャへの画質劣化の伝搬を最小限に防止できるようにしている。 As a result, continuous buffer failure can be avoided and propagation of image quality degradation to the subsequent encoded picture can be prevented to a minimum.
以上が、本発明による符号化装置で出力したビットストリームのバッファ遷移例である。 The above is the buffer transition example of the bit stream output by the encoding apparatus according to the present invention.
(実施形態2)
実施形態1では、バッファ破綻を受信した際、後続するピクチャを符号化する際に符号量を抑制して符号化を行い、符号化後のピクチャデータを繰り返しビットストリーム出力する方法を説明した。
(Embodiment 2)
In the first embodiment, when a buffer failure is received, a method has been described in which encoding is performed while suppressing the amount of code when a subsequent picture is encoded, and the encoded picture data is repeatedly output as a bitstream.
実施形態2では、バッファ破綻を受信した時点で、入力ピクチャ順として前のピクチャを符号化実行中だった場合は、破綻受信時点以降のピクチャ符号化の目標符号量を更新し、当該符号化ピクチャを繰り返しビットストリーム出力する。 In the second embodiment, when the previous picture is being encoded as the input picture order when the buffer failure is received, the target code amount of picture encoding after the failure reception time is updated, and the encoded picture Is repeatedly output as a bitstream.
一方、後続ピクチャの符号化実行中だった場合、同様に破綻受信時点以降の発生符号量を更新し、後続ピクチャを繰り返しビットストリーム出力することを、さらに異なる動作として実施する。 On the other hand, when the subsequent picture is being encoded, the generated code amount after the failed reception time is similarly updated, and the subsequent picture is repeatedly output as a bit stream as a further different operation.
これにより、バッファ破綻受信が符号化開始直後に判明すれば、後続ピクチャの画面全部に対して発生符号量を抑制して符号化することなく、即時に前ピクチャの画面途中から符号量の抑制が可能になるため、出力画面としての符号化劣化範囲の低減を実現できる。 As a result, if the buffer failure reception is found immediately after the start of encoding, the code amount can be immediately suppressed from the middle of the previous picture without suppressing the generated code amount for the entire subsequent picture screen. Therefore, it is possible to reduce the encoding deterioration range as the output screen.
以下、本発明の実施形態2について、図を用いて説明する。 Hereinafter, Embodiment 2 of the present invention will be described with reference to the drawings.
なお、実施形態2の説明において、上述した実施形態1と共通する部分について、同一の符号を付して適宜説明を省略する。 In the description of the second embodiment, portions common to the above-described first embodiment are denoted by the same reference numerals, and description thereof is omitted as appropriate.
<ブロック構成>
実施形態2を適用可能な動画像符号化装置のブロック構成を図8に示した。
<Block configuration>
FIG. 8 shows a block configuration of a video encoding apparatus to which the second embodiment can be applied.
当該符号化装置は、実施形態1のブロックに加えて、符号化ピクチャ順番判断部801から構成されることを特徴とする。 The encoding apparatus includes an encoded picture order determination unit 801 in addition to the blocks of the first embodiment.
符号化ピクチャ順判断部801は、バッファ破綻を受信した時、バッファ破綻ピクチャと、符号化ピクチャ部403で符号化中のピクチャの符号化順を判断する。 When the encoded picture order determining unit 801 receives a buffer failure, the encoded picture order determining unit 801 determines the encoding order of the buffer-failed picture and the picture being encoded by the encoded picture unit 403.
上記判断部の結果に基づいて、破綻ピクチャよりも前のピクチャ符号化時は、前ピクチャの発生符号量抑制とリピート出力制御をし、後続ピクチャの時は後続ピクチャの発生符号量抑制とリピート出力制御をするよう切り替える。 Based on the result of the determination unit, when the picture before the failed picture is coded, the generated code amount of the previous picture is suppressed and the repeat output is controlled. When the subsequent picture is generated, the generated code amount of the subsequent picture is suppressed and the repeat output is controlled. Switch to control.
その他のブロック機能については、実施形態1と同様であるため説明を省略する。 Other block functions are the same as those in the first embodiment, and thus the description thereof is omitted.
<破綻受信フロー>
図9には、前述の機能ブロックを用いて実現する破綻受信時の動作フローを示した。
<Failure reception flow>
FIG. 9 shows an operation flow at the time of failure reception realized using the above-described functional blocks.
尚、バッファ破綻送信時の動作フローは実施形態1と同様のため省略する。 Note that the operation flow at the time of buffer failure transmission is the same as that of the first embodiment, and is therefore omitted.
最初にステップS506では、他方の符号化装置が発行したバッファ破綻の受信処理を行う。 First, in step S506, reception processing for a buffer failure issued by the other encoding device is performed.
バッファ破綻が受信されなかった場合(ステップS506のFALSE)は、本動作フローを終了し、通常動作の符号化処理を継続する。 If no buffer failure has been received (FALSE in step S506), the operation flow is terminated and the normal operation encoding process is continued.
一方、バッファ破綻を受信した場合(ステップS506のTRUE)、ピクチャ符号化器403の符号化動作を一時停止し、既に符号化完了済みの発生符号量を取得する(ステップS901)。 On the other hand, if a buffer failure is received (TRUE in step S506), the encoding operation of the picture encoder 403 is temporarily stopped, and the generated code amount that has already been encoded is acquired (step S901).
続いて,ステップS901で取得した符号化済みピクチャデータサイズに基づいて、当該符号化ピクチャの残りの発生符号量について、バッファをアンダーフローしないよう目標符号量の割り当てを再計算する(ステップS902)。 Subsequently, based on the encoded picture data size acquired in step S901, the allocation of the target code amount is recalculated so as not to underflow the buffer for the remaining generated code amount of the encoded picture (step S902).
上記の目標符号量は、破綻発生ピクチャ発生後のバッファ占有量を用いず、当該符号化ピクチャの符号化開始時のバッファ占有量と、前記ステップS901で取得した符号化済みピクチャデータの合計より現在のバッファ占有量を求め、バッファ破綻を発生しない十分小さな目標符号量を設定する。 The target code amount does not use the buffer occupancy amount after occurrence of the failed picture, but the current occupancy amount from the sum of the buffer occupancy amount at the start of encoding of the encoded picture and the encoded picture data acquired in step S901. And a sufficiently small target code amount that does not cause buffer failure is set.
例えば、現在のバッファ占有量と符号化ビットレートとフレーム周期から計算した蓄積データ量から、当該符号化ピクチャのデコード時間におけるバッファ占有量を予測し、当該占有量の半分に収まるような目標符号量を割り当てる方法等が有効である。 For example, a target code amount that predicts the buffer occupancy amount in the decoding time of the encoded picture from the accumulated data amount calculated from the current buffer occupancy amount, the encoding bit rate, and the frame period, and falls within half of the occupancy amount A method of assigning the value is effective.
そして、上記目標符号量および各種符号化パラメタを符号化器403へ設定し、当該ピクチャの符号化処理を再開する(ステップS903)。 Then, the target code amount and various encoding parameters are set in the encoder 403, and the encoding process of the picture is restarted (step S903).
以降、実施形態1と同様にステップS510、S511の処理を実行して、本動作フローを終了する。 Thereafter, the processing in steps S510 and S511 is executed in the same manner as in the first embodiment, and this operation flow is terminated.
以上が、バッファ破綻受信時の処理フローである。 The above is the processing flow at the time of buffer failure reception.
<出力データ構造>
続いて、本発明による上記動作フローを適用した、各符号化装置の動作タイミング図と、出力ビットストームのデータ構造を図10に示した。
<Output data structure>
Subsequently, FIG. 10 shows an operation timing chart of each encoding apparatus to which the above-described operation flow according to the present invention is applied and a data structure of an output bit storm.
図10(a)は、符号化器1でのPic3ピクチャ符号化時のバッファ破綻が、符号化器2のPic4符号化中に発生した場合であり、t2のフレーム期間でバッファ破綻を受信したケースである。 FIG. 10A shows a case where a buffer failure at the time of Pic3 picture encoding in the encoder 1 occurs during Pic4 encoding of the encoder 2, and a case where a buffer failure is received in the frame period of t2. It is.
一方、図10(b)は、符号化器1でのPic3ピクチャ符号化時のバッファ破綻が、符号化器2のPic2符号化中に発生した場合であり、t1のフレーム期間でバッファ破綻を受信したケースである。 On the other hand, FIG. 10B shows a case where a buffer failure at the time of Pic3 picture encoding in the encoder 1 occurs during Pic2 encoding of the encoder 2, and the buffer failure is received in the frame period of t1. This is the case.
上記のように、バッファ破綻発生のタイミングが、符号化器2で並列処理している符号化ピクチャの符号順によって、本動作フローを実行した時のビットストリーム出力が変化する。 As described above, the bitstream output when this operation flow is executed varies depending on the coding order of the coded pictures that are processed in parallel by the encoder 2 when the buffer failure occurs.
Pic4符号化中は、実施形態1の図6と同様に符号化ピクチャPic4を2回繰り返してビットリーム出力をする。 During Pic4 encoding, the encoded picture Pic4 is repeated twice in the same manner as in FIG.
そしてPic2符号化中であった場合は、符号化ピクチャPic2の発生符号量を抑制して繰り返してビットストリーム出力したデータ構造となる。 When Pic2 encoding is in progress, the data structure is such that the generated code amount of the encoded picture Pic2 is suppressed and the bitstream is output repeatedly.
実施形態1では、バッファ破綻の発生タイミングと関係なく、固定的に破綻ピクチャに続く後続ピクチャPic4を符号量抑制と繰り返し出力していたが、並列動作中のピクチャ符号化途中でも即時にフィードバックするよう変更した。 In the first embodiment, the subsequent picture Pic4 that follows the failed picture is repeatedly output with code amount suppression regardless of the occurrence timing of the buffer failure. However, feedback is immediately performed even during picture coding during parallel operation. changed.
以上が、本発明による符号化装置の動作タイミングと、出力ビットストリームのデータ構造例である。 The above is the operation timing of the encoding apparatus according to the present invention and the data structure example of the output bit stream.
<バッファ遷移図>
続いて、本発明による上記動作フローを適用して出力した、ビットストームのバッファ遷移を図11に示した。
<Buffer transition diagram>
Next, FIG. 11 shows a bit storm buffer transition output by applying the operation flow according to the present invention.
図11(a)は、実施形態1と同様に、破綻ピクチャPic3の後に続くPic4を符号量抑制し、繰り返しビットストリーム出力した場合のバッファ遷移である。dt0のタイミングではPic2がバッファから掃引され、dt1およびdt2のタイミングで符号量抑制したピクチャデータPic4がデコード出力されている。 FIG. 11A shows the buffer transition when the code amount of Pic4 following the failed picture Pic3 is suppressed and the bitstream is repeatedly output, as in the first embodiment. At the timing of dt0, Pic2 is swept from the buffer, and the picture data Pic4 with the code amount suppressed at the timing of dt1 and dt2 is decoded and output.
一方、図11(b)では、破綻ピクチャPic3の前にあるPic2について発生符号量を抑制して、繰り返しビットストリーム出力した場合のバッファ遷移である。 On the other hand, FIG. 11B shows buffer transition when the generated code amount is suppressed for Pic2 before the failed picture Pic3 and the bitstream is repeatedly output.
図11(a)と異なる点は、dt0とdt1のタイミングで、同じピクチャデータPic2が繰り返しバッファから掃引され、dt2のタイミングではピクチャPic4がデコード出力される遷移となる。 The difference from FIG. 11A is a transition in which the same picture data Pic2 is repeatedly swept from the buffer at the timing of dt0 and dt1, and the picture Pic4 is decoded and output at the timing of dt2.
どちらも、実施形態1と同様に連続したバッファアンダーフローを回避し、さらに図11(b)のように符号化途中でのPic2に対する符号量再設定を行うことで、後続ピクチャPic4への画面全体に及ぶような画質劣化を最小限に抑えることが可能となる。 In both cases, as in the first embodiment, continuous buffer underflow is avoided, and the code amount is reset for Pic2 in the middle of encoding as shown in FIG. It is possible to minimize image quality degradation that extends to.
以上が、本発明による符号化装置で出力したビットストリームのバッファ遷移例である。 The above is the buffer transition example of the bit stream output by the encoding apparatus according to the present invention.
(実施形態3)
実施形態2では、バッファ破綻を受信した時点での、符号化ピクチャ順を判断し、当該判断結果に基づいて現在符号化中ピクチャ、または後続ピクチャのどちらかの目標符号量を更新し、当該符号化ピクチャを繰り返しビットストリーム出力する方法を説明した。
(Embodiment 3)
In the second embodiment, the order of encoded pictures at the time of receiving a buffer failure is determined, and based on the determination result, the target code amount of either the current encoded picture or the subsequent picture is updated, and the code A method of repeatedly outputting a bitstream of a picture has been described.
実施形態3では、第二の構成に加えて、さらにバッファ破綻を前のピクチャ符号化中に受信した時、予めフレームバッファメモリに格納されている後続ピクチャに相当する符号化対象画像の画面難易度を計算し、現在符号化中のピクチャデータの画面難易度と比較を行う。 In the third embodiment, in addition to the second configuration, when a buffer failure is received during previous picture encoding, the screen difficulty level of the encoding target image corresponding to the subsequent picture stored in advance in the frame buffer memory Is compared with the screen difficulty level of the picture data currently being encoded.
そして前記比較結果に基づき、画面難易度の低いピクチャ画像を選択して発生符号量の抑制を適用することを、異なる動作として実施する。 Then, based on the comparison result, selecting a picture image with a low screen difficulty level and applying the generated code amount suppression is performed as a different operation.
これにより、発生符号量の抑制およびピクチャデータのリピート処理を実施しても、より再生時の画質劣化を目立ちにくい画像を用いた破綻回避を実現できる。 As a result, even if the generated code amount is suppressed and the picture data is repeated, it is possible to achieve failure avoidance using an image that is less prominent in image quality degradation during reproduction.
尚、本実施形態による動作は、符号化中のピクチャの符号化順が、破綻ピクチャよりも前のピクチャを符号化中である場合にのみ適用可能である。 Note that the operation according to the present embodiment is applicable only when the encoding order of the picture being encoded is encoding a picture preceding the corrupted picture.
以下、本発明の実施形態3について、図を用いて説明する。 Hereinafter, Embodiment 3 of the present invention will be described with reference to the drawings.
なお、実施形態3の説明において、上述した実施形態1,2と共通する部分について、同一の符号を付して適宜説明を省略する。 In the description of the third embodiment, the same reference numerals are given to portions common to the above-described first and second embodiments, and description thereof is omitted as appropriate.
実施形態3を適用可能な動画像符号化装置のブロック構成を図12に示した。 FIG. 12 shows a block configuration of a video encoding apparatus to which the third embodiment can be applied.
この動画像符号化装置は、実施形態2のブロックに加えて、画面難易度判定部1201から構成されることを特徴とする。 This moving image coding apparatus is characterized by comprising a screen difficulty level determination unit 1201 in addition to the blocks of the second embodiment.
画面難易度判定部1201は、符号化装置内のバッファメモリに予め蓄積されている次回符号化する現画像データを読み出し、当該画像の画面難易度を符号化に先立って計算し、当該符号化装置において現在符号化中のピクチャデータの画面難易度と比較判定する。 The screen difficulty level determination unit 1201 reads the current image data to be encoded next time stored in advance in the buffer memory in the encoding device, calculates the screen difficulty level of the image prior to encoding, and the encoding device The comparison is made with the screen difficulty level of the picture data currently being encoded.
そのため実施形態3の構成では、分配器301から入力された画像を格納するフレームバッファメモリ302の領域を、2画面以上の大きさ分確保しておく。 Therefore, in the configuration of the third embodiment, an area of the frame buffer memory 302 that stores the image input from the distributor 301 is secured for a size of two screens or more.
前記判定部1210で行う画面難易度の取得方法は、例えばMPEG-2のソフトウェアモデル「TM5(TestModel)」において採用されている符号量制御の、アクティビティ値を対象画像について導出する方法等が有効である。 As a method for obtaining the screen difficulty level performed by the determination unit 1210, for example, a method for deriving an activity value for a target image in code amount control employed in the MPEG-2 software model “TM5 (TestModel)” is effective. is there.
アクティビティ値は、4×4あるいは8×8等の画素ブロック単位で、ブロック内の輝度値変化の大小を求める。そのため高周波成分の多い画像か否かを判断する推定することができるため、間接的に符号化劣化が目立ちやすい画像化どうかを判断できる。 For the activity value, the magnitude of the change in the luminance value in the block is obtained in units of 4 × 4 or 8 × 8 pixel blocks. Therefore, since it can be estimated whether or not the image has a lot of high-frequency components, it can be determined whether or not the image is easily noticeable in encoding degradation.
すなわち前記アクティビティ値が小さいほど、画面内の絵柄が一様で平坦であると判断できる。 That is, it can be determined that the smaller the activity value is, the more uniform and flat the pattern in the screen is.
一般に、発生符号量の抑制を大きくすると、DCT(離散コサイン変換)等の直交変換を用いて周波数変換した画像データの高周波成分への量子化値が大きくなるため、原画像に高周波成分が多いと劣化が目立ちやすくなる。 In general, if the suppression of the amount of generated code is increased, the quantized value of the image data frequency-converted using orthogonal transform such as DCT (Discrete Cosine Transform) to the high-frequency component increases, so that the original image has a high frequency component Deterioration is conspicuous.
本発明の実施形態では、上記アクティビティ値を、バッファ破綻受信時に符号化しているピクチャ画像と、次回符号予定のピクチャ画像について求め、二つのアクティビティ値を比較する。 In the embodiment of the present invention, the activity value is obtained for the picture image encoded at the time of buffer failure reception and the picture image scheduled to be encoded next time, and the two activity values are compared.
そして上記理由より、アクティビティ値が小さいピクチャに対して符号量抑制を行い、再生時の劣化を目立たなくさせることを特徴とする。 For the above reason, the code amount is suppressed for a picture having a small activity value, and deterioration during reproduction is made inconspicuous.
その他のブロック機能については、実施形態1と同様であるため説明を省略する。 Other block functions are the same as those in the first embodiment, and thus the description thereof is omitted.
<破綻受信フロー>
図13には、前述の機能ブロックを用いて実現する破綻受信時の動作フローを示した。
<Failure reception flow>
FIG. 13 shows an operation flow at the time of failure reception realized using the above-described functional blocks.
尚、バッファ破綻送信時の動作フローは実施形態1,2と同様のため省略する。 Note that the operation flow at the time of buffer failure transmission is the same as in the first and second embodiments, and is omitted.
最初にステップS506では、他方の符号化装置が発行したバッファ破綻の受信処理を行う。 First, in step S506, reception processing for a buffer failure issued by the other encoding device is performed.
バッファ破綻が受信されなかった場合(ステップS506のFALSE)は、本動作フローを終了し、通常動作の符号化処理を継続する。 If no buffer failure has been received (FALSE in step S506), the operation flow is terminated and the normal operation encoding process is continued.
一方、バッファ破綻を受信した場合(ステップS506のTRUE)は、前記符号化ピクチャ判断部801にて、現在符号化中のピクチャが、破綻ピクチャを基準にして前か後にあるかを判断する(ステップS1201)。 On the other hand, if a buffer failure has been received (TRUE in step S506), the encoded picture determination unit 801 determines whether the picture currently being encoded is before or after the broken picture as a reference (step S506). S1201).
後続ピクチャを符号化中の場合(ステップS1201のFALSE)は、実施形態2と同様にステップS901、S902、S903、S510、S511の処理を行い、後続ピクチャの符号量抑制と、繰り返しビットストリーム出力し、本動作フローを終了する。 When the subsequent picture is being encoded (FALSE in step S1201), the processing in steps S901, S902, S903, S510, and S511 is performed in the same manner as in the second embodiment to suppress the code amount of the subsequent picture and output the repeated bitstream. This operation flow ends.
そして、前のピクチャを符号化中の場合(ステップS1201のTRUE)は、符号化器302内のフレームバッファメモリ303へアクセスし、既に格納されている次回符号化予定の現画像について、画面難易度を計算して取得する(ステップS1202)。 If the previous picture is being encoded (TRUE in step S1201), the frame buffer memory 303 in the encoder 302 is accessed, and the screen difficulty level of the current image to be encoded next time that has already been stored. Is calculated and acquired (step S1202).
そして前記画面難易度判定部1201ブロックにて、ステップS1202で取得した画面難易度と、現在符号化中ピクチャの画面難易度から、どちらが画面内の複雑さが小さいかを比較する(ステップS1203)。 Then, in the screen difficulty level determination unit 1201 block, the screen difficulty level acquired in step S1202 and the screen difficulty level of the currently-encoded picture are compared, which is less complex in the screen (step S1203).
前記ステップS1203の比較結果から、ステップS1202で取得した次回符号化予定のピクチャの方が画面内の複雑さが小さいかを判断する(ステップS1204)。 From the comparison result in step S1203, it is determined whether the picture to be encoded next time acquired in step S1202 has a smaller complexity in the screen (step S1204).
次回符号化予定のピクチャよりも、現在符号化中のピクチャの方が、低難易度である場合(ステップS1204のFALSE)は、ステップS901へ移行し、実施形態2と同様のフローによって現在符号化中ピクチャの符号量抑制と、ピクチャデータのストリーム出力を繰り返し行い、本動作フローを終了する。 If the picture currently being encoded is less difficult than the picture to be encoded next time (FALSE in step S1204), the process proceeds to step S901, and the current encoding is performed according to the same flow as in the second embodiment. This operation flow is finished by repeatedly suppressing the code amount of the middle picture and outputting the picture data stream.
反対に次回符号化予定ピクチャの方が、低難易度の場合(ステップS1204のTRUE)は、ステップS507へ移行し、実施形態1と同様のフローによって後続ピクチャの符号量抑制と、ピクチャデータのストリーム出力を繰り返し行い、本動作フローを終了する。 On the other hand, if the picture to be encoded next time is less difficult (TRUE in step S1204), the process proceeds to step S507, and the code amount suppression of the subsequent picture and the stream of picture data are performed by the same flow as in the first embodiment. Output is repeated, and this operation flow ends.
以上が、バッファ破綻受信時の処理フローである。 The above is the processing flow at the time of buffer failure reception.
上述の動作フローによって、出力されるビットストリームのデータ構造およびバッファ遷移は、図10および図11を用いて説明した内容と同様になる。 According to the above-described operation flow, the data structure and buffer transition of the output bit stream are the same as those described with reference to FIGS.
すなわち、符号化中のピクチャより次回符号化画像の方が、低難易度である場合は、後続ピクチャの符号量を抑制するケースになるので、図10の(a)および図11の(a)と同じデータ構造とバッファ遷移となる。 That is, when the next encoded image is less difficult than the picture being encoded, the code amount of the succeeding picture is suppressed, and therefore (a) in FIG. 10 and (a) in FIG. And the same data structure and buffer transition.
そして、符号化中のピクチャの方が、低い画面難易度である場合は、現在符号化中のピクチャ(破綻ピクチャの前のピクチャ)に対して符号量抑制と繰り返しビットストリーム出力するため、図10(b)および図11(b)と同等のデータ構造とバッファ遷移となる。 If the picture being coded has a lower screen difficulty level, code amount suppression and repeated bitstream output are performed for the picture currently being coded (the picture before the failed picture). The data structure and buffer transition are the same as in (b) and FIG.
ただし実施形態2の場合と異なる点として、発生符号量抑制を行う対象ピクチャを画面難易度判定によって選択しているため、上記出力ビットストリームの再生画面の画質劣化が目立ちにくくなる効果を実現できる。 However, as a difference from the case of the second embodiment, since the target picture for which the generated code amount is to be suppressed is selected by the screen difficulty level determination, it is possible to realize an effect that the image quality deterioration of the playback screen of the output bitstream is less noticeable.
(実施形態4)
実施形態1〜3では、二つの符号化装置を並列処理したシステム構成でのバッファ破綻送受信と、破綻復帰方法について説明した。
(Embodiment 4)
In the first to third embodiments, the buffer failure transmission / reception and the failure recovery method in a system configuration in which two encoding devices are processed in parallel have been described.
実施形態4では、三つの符号化装置を並列処理する場合のシステム構成を前提に、システム構成と破綻送受信方法をより汎用的に制御することを、異なる動作として実施する。 In the fourth embodiment, on the premise of a system configuration in the case where three encoding devices are processed in parallel, more general control of the system configuration and the failed transmission / reception method is performed as a different operation.
これにより、三つ以上の符号化装置を用いた大規模なエンコーダシステムにおいても破綻回避処理を実現することができる。 As a result, the failure avoidance process can be realized even in a large-scale encoder system using three or more encoding devices.
<システム構成>
図14には、本発明の実施形態4で適用する符号化装置のシステム構成を示した。
<System configuration>
FIG. 14 shows a system configuration of an encoding apparatus applied in the fourth embodiment of the present invention.
当該符号化装置は、実施形態1で記載のシステム構成に加えて、第三の符号化器1401および、バッファ破綻管理器1402から構成される。 The encoding apparatus includes a third encoder 1401 and a buffer failure manager 1402 in addition to the system configuration described in the first embodiment.
第三の符号化装置1401は、実施形態1と同様の動作を行う。 The third encoding device 1401 performs the same operation as in the first embodiment.
バッファ破綻管理器1402は、各符号化器302、304、および1401から送信されるバッファ破綻の受信と、各符号化器へバッファ破綻情報を送信する機能を持つ。 The buffer failure manager 1402 has a function of receiving a buffer failure transmitted from each of the encoders 302, 304, and 1401 and transmitting buffer failure information to each encoder.
上述までの実施形態では、二つの符号化装置のみの構成を前提とし、符号化器間で、直接バッファ破綻信号を送受信していたが、三つ以上の符号化器を持つ構成の場合、バッファ破綻の送受信が同一の符号化器へループしてしまうことと、ピクチャデータの繰り返し出力する符号化装置が複数になってしまうことを回避する必要がある。 In the embodiments described above, on the premise of the configuration of only two encoding devices, the buffer failure signal is directly transmitted and received between the encoders. However, in the case of a configuration having three or more encoders, It is necessary to avoid that the failed transmission / reception loops to the same encoder and that there are multiple encoding apparatuses that repeatedly output picture data.
そのため本実施形態では、上記バッファ破綻管理器1402を用いて、どの符号化装置でバッファ破綻が発生したかを集中管理することを特徴とする。 Therefore, the present embodiment is characterized in that the buffer failure manager 1402 is used to centrally manage which encoding device has a buffer failure.
上記破綻管理器1402の動作として、例えば符号化器302でバッファ破綻発生を受信した時、バッファ破綻送信を第二の符号化器304あるいは第三の符号化器1401どちらか一方にだけ送信するようなマスク機能を有する。 As an operation of the failure manager 1402, for example, when a buffer failure occurrence is received by the encoder 302, a buffer failure transmission is transmitted only to either the second encoder 304 or the third encoder 1401. Has a good mask function.
そのため、各符号化器と前記破綻管理器1402間を結ぶ、バッファ破綻送受信情報(1403、1404)には、破綻の有無に加え、本システムにおいて予め一意に与えた符号化器を識別するための情報を伝送するものとする。 Therefore, in the buffer failure transmission / reception information (1403, 1404) connecting each encoder and the failure manager 1402, in addition to the presence / absence of failure, an identifier uniquely assigned in advance in this system is identified. Information shall be transmitted.
以上が本発明の実施形態4におけるシステム構成となる。 The above is the system configuration in Embodiment 4 of the present invention.
<実施形態4の動作例>
続いて、前記システム構成によるバッファ破綻ピクチャ発生時の、破綻復帰処理の動作タイミングと、データ構造例について図15と図16を用いて説明する。
<Operation Example of Embodiment 4>
Next, the operation timing of the failure recovery process and the data structure example when a buffer failure picture occurs in the system configuration will be described with reference to FIGS. 15 and 16.
尚、各符号化器内の処理ブロック、破綻送受信時の動作フローは上述の実施形態1〜3までと同様であるため省略する。 Note that the processing block in each encoder and the operation flow at the time of failed transmission / reception are the same as those in the first to third embodiments, and will be omitted.
図15は三つの符号化器を並列処理した場合の動作タイミングであり、入力映像のフレーム周期の3倍を符号化処理に割り当てながら、各符号化器でパイプラインに動作している例である。 FIG. 15 is an operation timing when three encoders are processed in parallel, and is an example in which each encoder operates in a pipeline while allocating three times the frame period of the input video to the encoding process. .
図15に示した符号化器1において、網かけで塗りつぶしたPic4(1501)に相当するピクチャ符号化時にバッファ破綻が発生した場合、一旦符号化器1から前述のバッファ破綻管理器1402へ破綻情報を送信し、符号化器2あるいは符号化器3にだけ、再度バッファ破綻を送信する。 In the encoder 1 shown in FIG. 15, when a buffer failure occurs during picture encoding corresponding to Pic4 (1501) filled with shading, the failure information is once sent from the encoder 1 to the buffer failure manager 1402 described above. And the buffer failure is transmitted again only to the encoder 2 or the encoder 3.
そして、符号化器2に対してバッファ破綻通が送信された場合は、バッファ破綻が発生ピクチャ以後のピクチャ、Pic5(1502)の発生符号量の抑制を、符号化器3に対して送信された場合は、Pic6(1503)の発生符号量の抑制を、実施形態1〜3までのバッファ破綻受信動作フローに従って行う。 Then, when a buffer failure is transmitted to the encoder 2, the suppression of the generated code amount of the picture after the picture where the buffer failure has occurred, Pic5 (1502), is transmitted to the encoder 3. In this case, the generated code amount of Pic6 (1503) is suppressed according to the buffer failure reception operation flow up to the first to third embodiments.
上記のタイミングで符号化処理を行った後に出力されるビットストリームは、バッファ破綻を受信した符号化器によって、図16に示したようなデータ構造となる。 The bit stream output after performing the encoding process at the above timing has a data structure as shown in FIG. 16 by the encoder that has received the buffer failure.
本図では、符号化器2のピクチャデータPic5を2回繰り返して出力した場合(図16(a))と、符号化器3のピクチャデータPic6を2回繰り返し出力した場合(図16(b))をそれぞれ示した。 In this figure, the picture data Pic5 from the encoder 2 is output twice (FIG. 16 (a)), and the picture data Pic6 from the encoder 3 is output twice (FIG. 16 (b)). ) Respectively.
本発明の実施形態では、破綻発生した符号化器以外のどちらの符号化器に破綻発生を送信するかは特に限定していないが、符号化システムとして予め定めた送信パスとしても良い。 In the embodiment of the present invention, it is not particularly limited to which encoder other than the encoder in which the failure has occurred, and the failure occurrence is transmitted. However, a transmission path predetermined as an encoding system may be used.
例えば、符号化器1が破綻した場合は符号化器2へ送信、符号化器2が破綻した場合は符号化器3へ送信、そして符号化器3が破綻した場合は符号化器1へ送信するなどの組み合わせでれば、バッファ破綻管理器の論理を簡素化できる。 For example, if the encoder 1 fails, the data is transmitted to the encoder 2. If the encoder 2 fails, the data is transmitted to the encoder 3. If the encoder 3 fails, the data is transmitted to the encoder 1. If it is a combination such as this, the logic of the buffer failure manager can be simplified.
尚、本実施形態は3つの符号化装置を用いたシステム構成において説明しているが、4つ以上の符号化装置を用いた並列動作システムでも汎用的に適用可能である。 Although the present embodiment has been described in a system configuration using three encoding devices, it can be applied universally to a parallel operation system using four or more encoding devices.
301:分配器
302:符号化器
303:バッファメモリ
304:第二の符号化器
305:バッファ破綻通信ポート
306:多重化器
401:リピート出力制御部
402:バッファ破綻受信部
403:ピクチャ符号化器
404:目標符号量設定部
405:ビットストリーム出力部
406:バッファ破綻送信部
301: Distributor 302: Encoder 303: Buffer memory 304: Second encoder 305: Buffer failure communication port 306: Multiplexer 401: Repeat output control unit 402: Buffer failure receiver 403: Picture encoder 404: Target code amount setting unit 405: Bit stream output unit 406: Buffer failure transmission unit
Claims (3)
前記符号化器による符号化処理時にバッファ破綻を検出するバッファ破綻検知手段と、
バッファ破綻発生の情報を他方の符号化器に送信するバッファ破綻送信手段と、
前記バッファ破綻発生の情報を受信するバッファ破綻受信手段と、
符号化ピクチャの次のピクチャに対して、前記バッファ破綻発生の後の発生符号量を抑制して、符号化を行わせる符号化制御手段と、
バッファ破綻が発生した符号化ピクチャデータのビットストリーム出力を破棄するピクチャデータ破棄手段と、
符号化ピクチャの次のピクチャを、繰り返しビットストリームとして出力するピクチャデータリピート出力手段と、
を具備することを特徴とする動画像符号化装置。 One input video signal is distributed to multiple encoders, and each encoder performs in-picture encoding processing in units of pictures in parallel, and then outputs a single bitstream multiplexed with multiple bitstreams. A moving image encoding device,
Buffer failure detection means for detecting a buffer failure during the encoding process by the encoder;
Buffer failure transmitting means for transmitting information on occurrence of buffer failure to the other encoder;
Buffer failure receiving means for receiving information on occurrence of the buffer failure; and
Coding control means for performing coding while suppressing the generated code amount after occurrence of the buffer failure with respect to the picture next to the coded picture;
Picture data discarding means for discarding a bitstream output of encoded picture data in which a buffer failure has occurred;
Picture data repeat output means for outputting the next picture of the encoded picture as a repeated bit stream;
A moving picture encoding apparatus comprising:
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2014047043A JP2015171114A (en) | 2014-03-11 | 2014-03-11 | Moving image encoder |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2014047043A JP2015171114A (en) | 2014-03-11 | 2014-03-11 | Moving image encoder |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JP2015171114A true JP2015171114A (en) | 2015-09-28 |
Family
ID=54203446
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2014047043A Pending JP2015171114A (en) | 2014-03-11 | 2014-03-11 | Moving image encoder |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2015171114A (en) |
Cited By (8)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2017123545A (en) * | 2016-01-06 | 2017-07-13 | 日本電信電話株式会社 | Video encoding method, video encoding apparatus, and video encoding program |
| US10365794B2 (en) | 2011-06-05 | 2019-07-30 | Apple Inc. | Systems and methods for displaying notifications received from multiple applications |
| US11079894B2 (en) | 2015-03-08 | 2021-08-03 | Apple Inc. | Device configuration user interface |
| US11343335B2 (en) | 2014-05-29 | 2022-05-24 | Apple Inc. | Message processing by subscriber app prior to message forwarding |
| US11477609B2 (en) | 2019-06-01 | 2022-10-18 | Apple Inc. | User interfaces for location-related communications |
| US11481094B2 (en) | 2019-06-01 | 2022-10-25 | Apple Inc. | User interfaces for location-related communications |
| US11907013B2 (en) | 2014-05-30 | 2024-02-20 | Apple Inc. | Continuity of applications across devices |
| US12405717B2 (en) | 2020-10-26 | 2025-09-02 | Apple Inc. | Methods and user interfaces for handling user requests |
-
2014
- 2014-03-11 JP JP2014047043A patent/JP2015171114A/en active Pending
Cited By (14)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US11487403B2 (en) | 2011-06-05 | 2022-11-01 | Apple Inc. | Systems and methods for displaying notifications received from multiple applications |
| US10365794B2 (en) | 2011-06-05 | 2019-07-30 | Apple Inc. | Systems and methods for displaying notifications received from multiple applications |
| US10908781B2 (en) | 2011-06-05 | 2021-02-02 | Apple Inc. | Systems and methods for displaying notifications received from multiple applications |
| US11921980B2 (en) | 2011-06-05 | 2024-03-05 | Apple Inc. | Systems and methods for displaying notifications received from multiple applications |
| US11442598B2 (en) | 2011-06-05 | 2022-09-13 | Apple Inc. | Systems and methods for displaying notifications received from multiple applications |
| US11343335B2 (en) | 2014-05-29 | 2022-05-24 | Apple Inc. | Message processing by subscriber app prior to message forwarding |
| US11907013B2 (en) | 2014-05-30 | 2024-02-20 | Apple Inc. | Continuity of applications across devices |
| US11079894B2 (en) | 2015-03-08 | 2021-08-03 | Apple Inc. | Device configuration user interface |
| JP2017123545A (en) * | 2016-01-06 | 2017-07-13 | 日本電信電話株式会社 | Video encoding method, video encoding apparatus, and video encoding program |
| US11481094B2 (en) | 2019-06-01 | 2022-10-25 | Apple Inc. | User interfaces for location-related communications |
| US11477609B2 (en) | 2019-06-01 | 2022-10-18 | Apple Inc. | User interfaces for location-related communications |
| US12299263B2 (en) | 2019-06-01 | 2025-05-13 | Apple Inc. | User interfaces for location-related communications |
| US12363505B2 (en) | 2019-06-01 | 2025-07-15 | Apple Inc. | User interfaces for location-related communications |
| US12405717B2 (en) | 2020-10-26 | 2025-09-02 | Apple Inc. | Methods and user interfaces for handling user requests |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JP2015171114A (en) | Moving image encoder | |
| KR101809306B1 (en) | Low latency rate control system and method | |
| US10425661B2 (en) | Method for protecting a video frame sequence against packet loss | |
| US20070009039A1 (en) | Video encoding and decoding methods and apparatuses | |
| EP0989755A2 (en) | A system and method for processing a video stream with a flash sequence | |
| CN102598673A (en) | Dynamic reference frame reordering for frame sequential stereoscopic video encoding | |
| JP5640979B2 (en) | Moving picture coding apparatus, moving picture coding method, and moving picture coding program | |
| CN111182310A (en) | Video processing method and device, computer readable medium and electronic equipment | |
| US20110299605A1 (en) | Method and apparatus for video resolution adaptation | |
| KR102424258B1 (en) | Method and encoder system for encoding video | |
| CN103733615B (en) | On-demand intra-refresh for end-to-end coded video transmission systems | |
| WO2021136783A1 (en) | Partial output of a decoded picture buffer in video coding | |
| US20250358417A1 (en) | Processing video using masking windows | |
| JP5791451B2 (en) | Encoding device and program | |
| JP6168672B1 (en) | Encoding device provided with video switching device and encoding method including video switching detection method | |
| WO2011108146A1 (en) | Image coding device, image coding/decoding system, image coding method, and image display method | |
| US20190200014A1 (en) | Method and a controller for adding comfort noise to a video sequence | |
| CN106131565B (en) | Video decoding and rendering using joint dithering-framebuffer | |
| Maung et al. | Error resilience aware rate control and mode selection for HEVC video transmission | |
| JPH0818959A (en) | Image signal encoding method and image signal encoding apparatus | |
| US8358694B2 (en) | Effective error concealment in real-world transmission environment | |
| KR20230027180A (en) | Image encoding/decoding method and apparatus for signaling picture output timing information, and computer readable recording medium storing bitstream | |
| HK1191485B (en) | Low latency rate control system and method | |
| HK1191485A (en) | Low latency rate control system and method | |
| JP2002058022A (en) | Statistical multiplexing system, statistical multiplexing control device, image coding device, statistical multiplexing method, and image coding method |