JP2015195470A - encoding device, encoding method and encoding program - Google Patents
encoding device, encoding method and encoding program Download PDFInfo
- Publication number
- JP2015195470A JP2015195470A JP2014071915A JP2014071915A JP2015195470A JP 2015195470 A JP2015195470 A JP 2015195470A JP 2014071915 A JP2014071915 A JP 2014071915A JP 2014071915 A JP2014071915 A JP 2014071915A JP 2015195470 A JP2015195470 A JP 2015195470A
- Authority
- JP
- Japan
- Prior art keywords
- encoding
- prediction
- motion vector
- image
- block
- 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
Links
Images
Abstract
Description
本発明は、符号化装置、符号化方法及び符号化プログラムに関する。 The present invention relates to an encoding device, an encoding method, and an encoding program.
動画像コンテンツを配信するサービスの分野において、利用者が動画像を視聴するために用いる様々な種類の端末装置に動画像データを配信するために、1つの動画像コンテンツを複数種類の画面サイズやフレームレートで符号化する技術がある。この種の技術では、例えば、テレビジョン受像機の画面サイズで符号化された第1の符号化データを、スマートホンなど別の画面サイズを持つ端末装置で視聴可能な第2の符号化データに変換するトランスコードが行われる場合がある。 In the field of services for distributing moving image content, in order to distribute moving image data to various types of terminal devices used by users to view moving images, a single moving image content can be divided into a plurality of types of screen sizes. There is a technique for encoding at a frame rate. In this type of technology, for example, first encoded data encoded with the screen size of a television receiver is converted into second encoded data that can be viewed on a terminal device having another screen size such as a smartphone. Transcoding to convert may be performed.
また、動画像を符号化する予測符号化モードを高い精度で特定するために、処理量の少ない予測処理で得たコストに基づいて画面内予測モード又は画面間予測モードを選択し、選択したモードで動画像を符号化する技術が提案されている(例えば、特許文献1参照)。 In addition, in order to specify a predictive coding mode for encoding a moving image with high accuracy, an intra-screen prediction mode or an inter-screen prediction mode is selected based on a cost obtained by a prediction process with a small amount of processing, and the selected mode is selected. A technique for encoding a moving image has been proposed (see, for example, Patent Document 1).
ところで、動画像の符号化に用いる予測符号化モードを特定するための従来技術は、前段の予測処理の対象となる動画像と、後段の符号化処理の対象となる動画像とが同一であることを前提としている。したがって、後段の符号化処理で符号化される動画像と、前段の予測処理で用いられた動画像とで画面サイズやフレームレートが異なる場合に、上述の従来技術を用いて符号化に用いるモードを特定することは困難である。 By the way, in the conventional technique for specifying the prediction encoding mode used for encoding a moving image, the moving image that is the target of the preceding stage encoding process and the moving image that is the target of the subsequent stage encoding process are the same. It is assumed that. Therefore, when the video size encoded in the subsequent encoding process and the video image used in the preceding prediction process have different screen sizes and frame rates, the mode used for encoding using the above-described conventional technology It is difficult to specify.
一方、画面サイズやフレームレートが異なる複数種類の端末装置に動画像を提供するために、元の動画像データを端末装置の種類毎に符号化することで生成する場合、1種類の符号化データを生成するための時間に端末装置の種類の数を乗じた時間がかかってしまう。 On the other hand, when the original moving image data is generated by encoding each type of terminal device in order to provide moving images to a plurality of types of terminal devices having different screen sizes and frame rates, one type of encoded data It takes time to multiply the time for generating the number of types of terminal devices.
しかしながら、例えば、テレビジョン受像機用の符号化データをスマートホン用の符号化データに変換した場合に、変換で得られた動きベクトルが、画面サイズを縮小した画像について動き探索を行った場合に得られる動きベクトルから乖離してしまう場合がある。この場合に、トランスコードで得られた符号化データから復元される画像の画質は、画面サイズを縮小した後の画像についての動き探索で得られた動きベクトルを用いて符号化することで得られた符号化データから復元される画像の画質に比べて低下してしまう。 However, for example, when encoded data for a television receiver is converted into encoded data for a smartphone, the motion vector obtained by the conversion performs a motion search for an image with a reduced screen size. There is a case where it deviates from the obtained motion vector. In this case, the image quality of the image restored from the encoded data obtained by transcoding can be obtained by encoding using the motion vector obtained by the motion search for the image after reducing the screen size. The quality of the image restored from the encoded data is lowered.
本件開示の符号化装置、符号化方法及び符号化プログラムは、一つの動画像から複数種類の画面サイズやフレームレートで再生可能な符号化データを生成するための処理時間の低減と画質の劣化の抑制を両立させる技術を提供することを目的とする。 The encoding apparatus, encoding method, and encoding program disclosed herein reduce processing time and image quality degradation for generating encoded data that can be reproduced from a single moving image at a plurality of types of screen sizes and frame rates. It aims at providing the technology which makes suppression compatible.
一つの観点によれば、符号化装置は、第1の動画像に含まれる複数の第1画像のそれぞれを分割して得られる複数の第1ブロックのそれぞれについて、画面間予測及び画面内予測の少なくとも一方を行うことで、動きベクトル及び予測方向の少なくとも一方を探索する探索部と、第1の動画像から生成される、フレームレート及び画面サイズの少なくとも一方が第1の動画像と異なる第2の動画像に含まれる複数の第2画像のそれぞれを、第2画像を分割して得られる第2ブロックごとに符号化する符号化部と、探索部によって得られた動きベクトル及び予測方向の少なくとも一方を示す第1情報と、第1情報で示される予測画像と第1ブロックとの違いである予測誤差を示す第1コストとのそれぞれから、各第2画像に含まれる第2ブロックのそれぞれについて画面間予測及び画面内予測の少なくとも一方を行った場合に得ることが予想される動きベクトル及び予測方向の少なくとも一方を示す第2情報と、第2情報で示される予測画像と第2ブロックとの間に予想される予測誤差を示す第2コストとのそれぞれを求める変換部と、変換部で所定の第1閾値以下の第2コストが求められた第2ブロックを符号化する場合に、変換部で得られた第2情報を用いて符号化部に符号化させる制御部とを有する。 According to one aspect, the encoding device performs inter-screen prediction and intra-screen prediction for each of the plurality of first blocks obtained by dividing each of the plurality of first images included in the first moving image. A search unit that searches for at least one of a motion vector and a prediction direction by performing at least one, and a second generated at least one of a frame rate and a screen size that is generated from the first moving image is different from that of the first moving image. An encoding unit that encodes each of a plurality of second images included in the moving image for each second block obtained by dividing the second image, and at least a motion vector and a prediction direction obtained by the search unit From each of the first information indicating one and the first cost indicating the prediction error that is the difference between the predicted image indicated by the first information and the first block, the second block included in each second image. Second information indicating at least one of a motion vector and a prediction direction that are expected to be obtained when at least one of inter-screen prediction and intra-screen prediction is performed for each of the two, a predicted image indicated by the second information, and a second When encoding a conversion unit that obtains each of a second cost indicating a prediction error expected between the block and a second block for which the conversion unit obtains a second cost that is equal to or less than a predetermined first threshold. And a control unit that causes the encoding unit to encode using the second information obtained by the conversion unit.
また、別の観点によれば、符号化方法は、第1の動画像に含まれる複数の第1画像のそれぞれを分割して得られる複数の第1ブロックのそれぞれについて、画面間予測及び画面内予測の少なくとも一方を行うことで、動きベクトル及び予測方向の少なくとも一方を探索し、第1の動画像から生成される、フレームレート及び画面サイズの少なくとも一方が第1の動画像と異なる第2の動画像に含まれる複数の第2画像のそれぞれを、第2画像を分割して得られる第2ブロックごとに符号化する場合に、探索によって得られた動きベクトル及び予測方向の少なくとも一方を示す第1情報と、第1情報で示される予測画像と第1ブロックとの違いである予測誤差を示す第1コストとのそれぞれから、各第2画像に含まれる第2ブロックのそれぞれについて画面間予測及び画面内予測の少なくとも一方を行った場合に得ることが予想される動きベクトル及び予測方向の少なくとも一方を示す第2情報と、第2情報で示される予測画像と第2ブロックとの間に予想される予測誤差を示す第2コストとのそれぞれを求め、所定の第1閾値以下の第2コストが求められた第2ブロックを、第2ブロックについて得られた第2情報を用いて符号化する。 According to another aspect, the encoding method performs inter-screen prediction and intra-screen prediction for each of a plurality of first blocks obtained by dividing each of a plurality of first images included in the first moving image. By performing at least one of the predictions, at least one of the motion vector and the prediction direction is searched, and at least one of the frame rate and the screen size generated from the first moving image is different from the first moving image. When encoding each of the plurality of second images included in the moving image for each second block obtained by dividing the second image, the second image indicating at least one of the motion vector obtained by the search and the prediction direction. Each of the second block included in each second image from one information and a first cost indicating a prediction error that is a difference between the predicted image indicated by the first information and the first block. Second information indicating at least one of a motion vector and a prediction direction expected to be obtained when at least one of inter-screen prediction and intra-screen prediction is performed; a predicted image indicated by the second information; and a second block Each of the second cost indicating a prediction error expected during the period is obtained, and the second information obtained for the second block is used for the second block for which the second cost equal to or lower than the predetermined first threshold is obtained. To encode.
更に、別の観点によれば、符号化プログラムは、第1の動画像に含まれる複数の第1画像のそれぞれを分割して得られる複数の第1ブロックのそれぞれについて、画面間予測及び画面内予測の少なくとも一方を行うことで、動きベクトル及び予測方向の少なくとも一方を探索し、第1の動画像から生成される、フレームレート及び画面サイズの少なくとも一方が第1の動画像と異なる第2の動画像に含まれる複数の第2画像のそれぞれを、第2画像を分割して得られる第2ブロックごとに符号化する場合に、探索によって得られた動きベクトル及び予測方向の少なくとも一方を示す第1情報と、第1情報で示される予測画像と第1ブロックとの違いである予測誤差を示す第1コストとのそれぞれから、各第2画像に含まれる第2ブロックのそれぞれについて画面間予測及び画面内予測の少なくとも一方を行った場合に得ることが予想される動きベクトル及び予測方向の少なくとも一方を示す第2情報と、第2情報で示される予測画像と第2ブロックとの間に予想される予測誤差を示す第2コストとのそれぞれを求め、所定の第1閾値以下の第2コストが求められた第2ブロックを、第2ブロックについて得られた第2情報を用いて符号化する、処理をコンピュータに実行させる。 Further, according to another aspect, the encoding program performs inter-screen prediction and intra-screen prediction for each of the plurality of first blocks obtained by dividing each of the plurality of first images included in the first moving image. By performing at least one of the predictions, at least one of the motion vector and the prediction direction is searched, and at least one of the frame rate and the screen size generated from the first moving image is different from the first moving image. When encoding each of the plurality of second images included in the moving image for each second block obtained by dividing the second image, the second image indicating at least one of the motion vector obtained by the search and the prediction direction. 1 information and the first cost indicating the prediction error, which is the difference between the predicted image indicated by the first information and the first block, of the second block included in each second image. Second information indicating at least one of a motion vector and a prediction direction expected to be obtained when at least one of inter-screen prediction and intra-screen prediction is performed for each, a predicted image indicated by the second information, and a second The second information obtained for the second block is obtained with respect to each of the second costs indicating the prediction error expected between the blocks and the second block for which the second cost equal to or lower than the predetermined first threshold is obtained. The computer executes the process of encoding using.
本件開示の符号化装置、符号化方法及び符号化プログラムは、一つの動画像から複数種類の画面サイズやフレームレートで再生可能な符号化データを生成するための処理時間の低減と画質の劣化の抑制を両立させることができる。 The encoding apparatus, encoding method, and encoding program disclosed herein reduce processing time and image quality degradation for generating encoded data that can be reproduced from a single moving image at a plurality of types of screen sizes and frame rates. It is possible to achieve both suppression.
以下、図面に基づいて、実施形態を説明する。 Hereinafter, embodiments will be described with reference to the drawings.
図1は、符号化装置の一実施形態を示す。図1に示した符号化装置10は、探索部11と、符号化部12と、変換部13と、制御部14とを含んでいる。
FIG. 1 shows an embodiment of an encoding device. The
図1に示した探索部11および符号化部12は、動画像データベースDBに接続されており、動画像データベースDBに蓄積された動画像Vinを受ける。動画像Vinは、例えば、所定の時間間隔を置いて連続的に被写体を撮影することで得られる動画像であり、複数の画像を含んでいる。符号化部12は、配信装置DTに接続されており、符号化部12によって生成された符号化データC1〜Cn(nは、2以上の整数)は、配信装置DTを介してネットワークNWに送出され、n種類の端末装置UEのそれぞれに配信される。図1に示したテレビジョン装置UE1、パーソナルコンピュータUE2,タブレット型端末UE3及びスマートホンUE4は、符号化部12によって生成された符号化データC1〜Cnのそれぞれの配信を受けるn種類の端末装置UEの例である。
The
なお、n種類の端末装置UEは、テレビジョン装置UE1、パーソナルコンピュータUE2,タブレット型端末UE3及びスマートホンUE4に限られず、動画像を再生する機能を有する端末装置であればよく、例えば、携帯電話や携帯型ゲーム機等でもよい。また、符号化装置10に含まれる符号化部12によって生成された符号化データC1〜Cnのそれぞれは、配信装置DTにより、同じ種類の複数の端末装置UEに並行して配信されてもよい。また、動画像データベースDB、符号化装置10および配信装置DTは、図1に示したように、それぞれ個別の装置としてもよいし、一つの装置として一体化されてもよい。
Note that the n types of terminal devices UE are not limited to the television device UE1, the personal computer UE2, the tablet terminal UE3, and the smart phone UE4, and may be any terminal device that has a function of reproducing moving images. Or a portable game machine. Also, each of the encoded data C1 to Cn generated by the
図1に示した符号化装置10において、探索部11は、例えば、動画像Vinに含まれる複数の画像のそれぞれを分割して得られるマクロブロック毎に、画面間予測及び画面内予測の少なくとも一方により、動きベクトル及び予測方向の少なくとも一方を探索する。ここで、動画像Vinに含まれる複数の画像のそれぞれは、探索部11による探索の対象となる第1画像の一例である。また、動画像Vin中の各画像に含まれるマクロブロックは、第1画像を分割して得られる複数の第1ブロックの一例である。
In the
なお、探索部11は、例えば、H.264規格に基づいて、各マクロブロックを分割したサブブロック毎に画面内予測及び画面間予測を行うことにより、各サブブロックの動きベクトル及び予測方向を探索してもよい。
The
以下では、説明の簡単のため、探索部11において、動画像Vinに含まれる各画像のマクロブロック毎に、動画像Vinにおいてマクロブロックを含む画像より前に撮影された画像を参照画像とする画面間予測で動きベクトルを探索する場合について説明する。例えば、動画像Vinに含まれる各画像に撮影順を示す画像番号が与えられる場合に、探索部11では、画像番号kの画像に含まれる各マクロブロックの動きベクトルを、画像番号k−1の画像を参照画像とする画面間予測を行うことで探索する。
In the following, for simplicity of explanation, the
この場合に、探索部11は、動画像Vinに含まれる各画像のマクロブロックに順次に注目し、注目するマクロブロックを含む画像の撮影順で一つ前の画像である参照画像において、注目するマクロブロックに類似する箇所を探索する。そして、参照画像において注目するマクロブロックに対応する位置を基準として、探索で特定した箇所の位置を示す動きベクトルを求め、求めた動きベクトル及び参照画像を示す情報を含む第1情報を変換部13に渡す。また、探索部11は、例えば、参照画像における探索で特定した箇所の画像と注目するマクロブロックとの差分の絶対値の総和を、動きベクトルで示される予測画像と注目するマクロブロックとの違いである予測誤差を示す第1コストとして変換部13に渡す。
In this case, the
図1に示した符号化部12は、例えば、配信先の端末装置UEの種類毎に設定された符号化条件に基づいて動画像Vinから生成される、動画像Vinとはフレームレート及び画面サイズの少なくとも一方が異なる第2の動画像を符号化する。符号化部12は、例えば、符号化部12の内部において、符号化条件で示されたフレームレートに応じて動画像Vinに含まれる画像を間引くとともに、符号化条件で示される画面サイズに従って画像のそれぞれを縮小することで、第2の動画像を生成する。そして、符号化部12は、制御部14からの指示に従って、第2の動画像に含まれる複数の第2画像である縮小された画像のそれぞれにおけるマクロブロック毎に画面間予測を行うことで得られる情報と変換部13で得られる情報との何れかを用いた符号化を行う。ここで、配信先の端末装置UEの種類毎の符号化条件で示された画面サイズに従って縮小された画像は、動画像Vinとはフレームレート及び画面サイズの少なくとも一方が異なる第2の動画像に含まれる第2画像の一例である。また、縮小された画像に含まれる各マクロブロックは、第2画像を分割することで得られる複数の第2ブロックの一例である。
The
なお、端末装置UEの種類毎の符号化条件で設定される第1画像と第2画像とのサイズの比率は、端末装置UEのそれぞれに搭載された表示部で表示可能な画像のサイズ等に基づいて、画像の縦方向と横方向とでそれぞれ独立に設定されてもよい。 In addition, the ratio of the size of the first image and the second image set in the encoding condition for each type of the terminal device UE is the size of the image that can be displayed on the display unit mounted on each of the terminal devices UE. Based on this, the vertical direction and the horizontal direction of the image may be set independently.
以下の説明では、配信先の端末装置UEの種類毎に設定された符号化条件で示される画面サイズに従って縮小された画像は、縮小画像と称される場合がある。また、以下では、説明の簡単のため、符号化部12において、動画像Vinからの画像の間引きが行われず、動画像Vinに含まれる全ての画像が符号化条件で指定された画面サイズに基づいて縮小される場合について説明する。また、符号化条件で指定された第1画像に対する第2画像のサイズの比率を縮小率と称する。
In the following description, an image reduced according to the screen size indicated by the encoding condition set for each type of terminal apparatus UE as a distribution destination may be referred to as a reduced image. In the following description, for simplification of description, the
図1に示した変換部13は、探索部11から受けた第1情報に含まれる動きベクトルから、縮小画像のマクロブロック毎に、撮影順で一つ前の縮小画像を参照画像とした画面間予測で求められることが予想される動きベクトルを示す第2情報を求める。例えば、変換部13は、符号化条件で指定された縮小率に基づいて、縮小画像のマクロブロック毎に、当該マクロブロックに対応付けられる縮小前のマクロブロックを特定する。そして、変換部13は、例えば、特定したマクロブロックのそれぞれについて求められた動きベクトルを、指定された縮小率を用いて縮小し、縮小された動きベクトルの何れかを選択することで、縮小画像のマクロブロックの動きベクトルを求める。なお、変換部13において、縮小画像のマクロブロック毎に予想される動きベクトルを求める手法は、縮小画像のマクロブロックに対応して特定された縮小前のマクロブロックの動きベクトルを縮小したベクトルの何れかを選択する手法に限られない。例えば、変換部13は、縮小画像のマクロブロックに対応して特定された縮小前のマクロブロックの動きベクトルを縮小したベクトルに重みを付けて平均することで得られたベクトルを、縮小画像のマクロブロックの動きベクトルとして求めてもよい。縮小画像のマクロブロックについて予想される動きベクトルを、重み付平均により求める場合に用いる重みとして好適な例は、図2を用いて後述される。
The
また、変換部13は、例えば、探索部11から受けた第1コストから、縮小画像のマクロブロック毎に、第2情報として求めた動きベクトルで示される予測画像と縮小画像のマクロブロックとの間に予想される予測誤差を示す第2コストを求める。例えば、変換部13は、縮小画像のマクロブロックに対応付けられる縮小前のマクロブロックの動きベクトルと縮小画像のマクロブロックについて求められた動きベクトルとの方向の違いに応じて大きくなる、1以上の値を持つ係数を求める。そして、変換部13は、例えば、縮小前のマクロブロックのそれぞれに対応して探索部11から受けた第1コストに、求めた係数及び縮小率を乗じ、係数及び縮小率が乗じられた第1コストを互いに加算することで第2コストを求める。
For example, the
ここで、縮小画像のマクロブロックに対応して特定される縮小前のマクロブロックは、例えば、図2を用いて後述するように、縮小前の画像において互いに隣接しているので、特定された各マクロブロックの動きベクトルは互いに類似している場合が多い。そして、特定された各マクロブロックの動きベクトルが互いに類似している場合に、これらの動きベクトルを画像の縮小率で縮小したベクトルは、縮小画像のマクロブロックについて実際に画面間予測を行った場合に得られる動きベクトルに類似する可能性が高い。即ち、特定された各マクロブロックの動きベクトルが互いに類似している場合に、変換部13により特定された各マクロブロックの動きベクトルから求められる動きベクトルは、縮小画像のマクロブロックについて実際に画面間予測を行った場合とほぼ同等となる。
Here, the macroblocks before reduction specified corresponding to the macroblocks of the reduced image are adjacent to each other in the image before reduction as described later with reference to FIG. 2, for example. The motion vectors of macroblocks are often similar to each other. When the motion vectors of the identified macroblocks are similar to each other, the vectors obtained by reducing these motion vectors at the image reduction rate are actually obtained when inter-screen prediction is performed for the macroblocks of the reduced image Is likely to be similar to the motion vector obtained. That is, when the motion vectors of the specified macroblocks are similar to each other, the motion vector obtained from the motion vector of each macroblock specified by the
また、以上に説明した変換部13によって縮小画像のマクロブロック毎に求められる第2コストは、縮小画像のマクロブロックに対応付けられた縮小前のマクロブロックの動きベクトルが互いに類似している場合に、他の場合に比べて小さい値となる。即ち、変換部13によって求められた第2コストが小さいほど、変換部13によって第2情報として求められた動きベクトルは、縮小画像のマクロブロックの動きベクトルとして確からしい。
In addition, the second cost obtained for each macroblock of the reduced image by the
そこで、図1に示した制御部14は、縮小画像のマクロブロック毎に変換部13から受けた第2コストが所定の第1閾値以下である場合に、第2情報で示される動きベクトルと、縮小画像についての画面間予測で実際に得られる動きベクトルとが類似すると判断する。ここで、制御部14において第2コストと比較される第1閾値は、例えば、画面間予測で得られる予測誤差の平均値程度に設定される。なお、第1閾値の値は、符号化部12によって生成される符号化データの配信先となる端末装置UE毎に、個々の端末装置UEについて予め設定された画質や処理速度についての仕様を達成可能な値に設定されてもよい。
Therefore, the control unit 14 illustrated in FIG. 1, when the second cost received from the
そして、制御部14は、第2コストが所定の第1閾値以下である場合に、符号化部12に対して、変換部13から受けた第2情報で示される動きベクトルを用いた符号化処理の実行を指示する。この場合に、符号化部12は、縮小画像のマクロブロックについて動きベクトルを求める処理を省略し、変換部13による変換で得られた動きベクトルを用いて、縮小画像のマクロブロックを符号化する。変換部13において説明したように、第2コストが小さいほど、変換部13によって第2情報として求められた動きベクトルは、縮小画像のマクロブロックの動きベクトルとして確からしい。したがって、制御部14は、第2コストが第1閾値以下である場合に、第2情報で示される動きベクトルを用いた符号化を符号化部12に行わせることで、縮小画像のマクロブロックの符号化に確からしい動きベクトルを用いさせることができる。
Then, the control unit 14 uses the motion vector indicated by the second information received from the
一方、第2コストが第1閾値よりも大きい場合に、制御部14は、変換部13で得られた第2情報に含まれる動きベクトルは、縮小画像のマクロブロックについて画面間予測を行うことで得られる動きベクトルと異なっている可能性があると判断する。この場合に、制御部14は、符号化部12に対して、縮小画像のマクロブロックについての画面間予測の実行を指示し、画面間予測で得られた動きベクトルを用いた符号化を実行させる。
On the other hand, when the second cost is greater than the first threshold, the control unit 14 performs inter-screen prediction on the macroblock of the reduced image for the motion vector included in the second information obtained by the
ここで、縮小画像のマクロブロックと縮小前の画像におけるマクロブロックとの対応関係について、図2を用いて説明する。 Here, the correspondence between the macroblock of the reduced image and the macroblock in the image before reduction will be described with reference to FIG.
図2は、縮小画像のマクロブロックと縮小前のマクロブロックとの対応関係の例を示す。図2(A)は、縮小前の画像における4つのマクロブロックMB11,MB12,MB21,MB22が、縮小画像の一つのマクロブロックmb11に対応付けられる場合を示す。また、図2(B)は、縮小前の画像における4つのマクロブロックMB11,MB12,MB21,MB22のそれぞれの一部を含む領域Rが、縮小画像において一つのマクロブロックmb11に対応付けられる場合を示す。 FIG. 2 shows an example of a correspondence relationship between a macroblock of a reduced image and a macroblock before reduction. FIG. 2A shows a case where four macroblocks MB11, MB12, MB21, and MB22 in the image before reduction are associated with one macroblock mb11 in the reduction image. FIG. 2B shows a case where a region R including a part of each of the four macroblocks MB11, MB12, MB21, and MB22 in the image before reduction is associated with one macroblock mb11 in the reduction image. Show.
図2(A)の例は、図1に示した変換部13により、マクロブロックMB11〜MB22のうち、左上のマクロブロックMB11の動きベクトルVp11を縮小したベクトルVcが、マクロブロックmb11の動きベクトルとして選択される場合を示す。なお、図2(A)において、実線の矢印Vp12,Vp21,Vp22のそれぞれは、図1に示した探索部11により、マクロブロックMB12,MB21,MB22のそれぞれについて求められた動きベクトルを示す。また、図2(A)に示したマクロブロックMB12,MB21,MB22において、マクロブロックmb11の動きベクトルVcに相当するベクトルを点線の矢印で示した。
In the example of FIG. 2A, the vector Vc obtained by reducing the motion vector Vp11 of the macroblock MB11 in the upper left among the macroblocks MB11 to MB22 by the
この場合に、変換部13により、例えば、動きベクトルVp11〜Vp22のそれぞれについて、動きベクトルVcとの方向の違いの大きさを示す係数が求められ、マクロブロックmb11の第2コストを求める処理に用いられる。図2(A)の例では、マクロブロックMB11〜MB22のそれぞれの全体がマクロブロックmb11に対応付けられている。この場合に、変換部13は、動きベクトルVp11〜Vp22のそれぞれにつき求めた方向の違いを示す係数及び画像の縮小率と、マクロブロックMB11〜MB22のそれぞれの第1コストとの積の総和を、マクロブロックmb11の第2コストとして求める。
In this case, for example, for each of the motion vectors Vp11 to Vp22, the
一方、図2(B)の例は、縮小前のマクロブロックMB11〜MB22のそれぞれにおいて、マクロブロックmb11に対応付けられた部分の占める割合が互いに異なる場合を示す。この場合に、変換部13は、マクロブロックMB11〜MB22のそれぞれにおいて領域Rに含まれる部分の面積と一つのマクロブロックの面積との比等を示す重みを用いた加重平均により、マクロブロックmb11の動きベクトルVcを求めてもよい。なお、図2(B)に示したマクロブロックMB11,MB12,MB21,MB22において、点線の矢印Vcは、変換部13により、動きベクトルVp11〜Vp22の加重平均で求められたマクロブロックmb11の動きベクトルを示す。また、この場合に、変換部13は、動きベクトルVcの算出で用いた重みを用いて、第2コストの算出を行うことが望ましい。
On the other hand, the example of FIG. 2B shows a case where the proportions of the portions associated with the macroblock mb11 are different from each other in the macroblocks MB11 to MB22 before the reduction. In this case, the
図1に示した符号化装置10において、制御部14は、変換部13によって縮小画像のマクロブロック毎に求められた第2コストが第1閾値以下である場合に、第2情報で示される動きベクトルを用いて縮小画像のマクロブロックを符号化させる。これにより、変換部13により、縮小画像のマクロブロックの動きベクトルとして確からしい動きベクトルが得られた場合に、符号化部12における画面間予測処理を省略させ、符号化処理の高速化を図ることができる。以上で説明したように、縮小画像の任意のマクロブロックについて求められた第2コストが第1閾値以下の場合に、変換部13で求められた第2情報で示される動きベクトルは、当該マクロブロックについての画面間予測で得られる動きベクトルとほぼ同等である。したがって、第1閾値以下の第2コストが得られた場合に、縮小画像のマクロブロックを第2情報で示される動きベクトルを用いて符号化することで、縮小画像のマクロブロックについて画面間予測を行った場合と同様の画質で再生可能な符号化データが得られる。即ち、図1に示した符号化装置10は、一つの動画像Vinから複数種類の画面サイズやフレームレートで再生可能な符号化データを生成する符号化処理のための処理時間の低減と画質の劣化の抑制を両立させることができる。
In the
図3は、図1に示した符号化装置10の動作を示す。図3に示したステップS301〜ステップS306の処理は、図1に示した符号化装置10の動作を示すとともに、符号化方法および符号化プログラムの例を示す。例えば、図3に示す処理は、符号化装置10に搭載されたプロセッサが符号化プログラムを実行することで実現される。なお、図3に示す処理は、符号化装置10に搭載されるハードウェアによって実行されてもよい。
FIG. 3 shows the operation of the
ステップS301において、探索部11は、動画像Vinに含まれる縮小前の画像に基づいて、縮小前の画像におけるマクロブロック毎の第1情報及び第1コストとして、例えば、動きベクトル及び予測誤差を求める。
In step S301, the
ステップS302において、変換部13は、ステップS301の処理で得られた動きベクトル及び予測誤差に基づいて、縮小画像の各マクロブロックについて予想される動きベクトルを示す第2情報及び予想される予測誤差を示す第2コストを求める。変換部13は、ステップS302の処理において、図2で説明したように、縮小画像の各マクロブロックに対応付けられる縮小前のマクロブロックについて得られた動きベクトル及び予測誤差を用いる。なお、縮小画像の各マクロブロックと縮小前のマクロブロックとの対応関係は、動画像Vinに含まれる各画像から縮小画像を生成する際の縮小率に基づいて特定される。
In step S302, the
以下に説明するステップS303〜ステップS306の各処理は、縮小画像に含まれる各マクロブロックを順次に注目するマクロブロックとし、変換部13、制御部14および符号化部12により、注目するマクロブロック毎に実行される。
In each of the processes in steps S303 to S306 described below, each macroblock included in the reduced image is set as a macroblock to be noticed in order, and each macroblock to be noticed is converted by the
ステップS303において、制御部14は、注目するマクロブロックについて、ステップS302の処理で得られた第2コストが第1閾値以下であるか否かを判定する。 In step S303, the control unit 14 determines whether or not the second cost obtained in the process of step S302 is equal to or less than the first threshold for the macro block of interest.
ステップS302の処理で第1閾値以下の値を持つ第2コストが得られた場合に(ステップS303の肯定判定(YES))、制御部14は、ステップS302の処理で得られた動きベクトルは注目するマクロブロックの動きベクトルとして確からしいと判断する。この場合に、制御部14は、ステップS304の処理に進む。 When the second cost having a value equal to or smaller than the first threshold value is obtained in the process of step S302 (Yes determination in step S303), the control unit 14 pays attention to the motion vector obtained in the process of step S302. It is determined that the motion vector of the macro block is likely. In this case, the control unit 14 proceeds to the process of step S304.
ステップS304において、制御部14は、注目するマクロブロックの動きベクトルとして、ステップS302の処理で得られた動きベクトルを符号化部12に渡し、渡した動きベクトルを用いた符号化処理を符号化部12に実行させる。この場合に、符号化部12において、第1閾値以下の値を持つ第2コストが得られたマクロブロックについて動きベクトルを探索する処理は省略される。
In step S304, the control unit 14 passes the motion vector obtained in the process of step S302 as the motion vector of the target macroblock to the
一方、ステップS302で得られた第2コストが第1閾値よりも大きい場合に(ステップS303の否定判定(NO))、制御部14は、ステップS302で得られた動きベクトルは注目するマクロブロックの動きベクトルとして確からしくないと判断する。この場合に、制御部14は、ステップS305の処理に進む。 On the other hand, when the second cost obtained in step S302 is larger than the first threshold value (No determination in step S303 (NO)), the control unit 14 determines that the motion vector obtained in step S302 is the macro block of interest. It is determined that the motion vector is not accurate. In this case, the control unit 14 proceeds to the process of step S305.
ステップS305において、制御部14は、注目するマクロブロックについて、符号化部12に例えば画面間予測処理による動きベクトルの探索を実行させる。
In step S305, the control unit 14 causes the
そして、ステップS306において、符号化部12は、ステップS305で実行した画面間予測処理等で得られた動きベクトルを用いて、注目するマクロブロックを符号化する。
In step S306, the
以上に説明したように、図1に示した符号化装置10は、変換部13の処理で予想された縮小画像のマクロブロックの動きベクトルが確からしいとされた場合に、予想された動きベクトルを用いて縮小画像のマクロブロックを符号化する。ここで、人物や風景を撮影した動画像は、階調の変化が緩やかな箇所を多く含んでいる。そして、階調変化が緩やかな箇所に含まれるマクロブロックに対応付けられた縮小画像のマクロブロックについては、図2で説明した変換部13の処理により、確からしい動きベクトルを予想することができる。したがって、図1に示した符号化装置10は、人物や風景を撮影した動画像に含まれる階調の変化が緩やかな箇所に対応付けられる縮小画像のマクロブロックについての動きベクトルの探索を省略することで、符号化処理を高速化することが可能である。一方、予想された動きベクトルが確からしくないとされた場合に、符号化装置10の符号化部12は、制御部14からの指示に応じて、縮小画像のマクロブロックについての動き探索で得られた動きベクトルを用いて符号化処理を行う。したがって、図1に示した符号化装置10によって得られる符号化データは、予想された動きベクトルの確からしさにかかわらず予想された動きベクトルを用いて符号化を行った場合に比べて、高い画質の動画像を再生可能である。即ち、図1に示した符号化装置10は、元の動画像Vinを符号化して得られる符号化データを用いて、動画像Vinとは画面サイズ等が異なる第2の動画像を再生するための符号化データを生成する用途において、画質の維持と符号化処理の高速化を両立できる。
As described above, the
なお、図1〜図3で説明した動画像Vinの各画像を縮小した縮小画像についての符号化処理は、動画像Vinについて得られた符号化データから、配信先の端末装置UEの仕様で動画像を再生可能な符号化データを生成するトランスコードの一例である。図1に示した符号化装置10は、図2に示した例に限らず、様々なサイズ比で縮小された縮小画像を含む動画像や、様々なフレームレートに従って動画像Vinの画像を間引いて得られる動画像に対応する符号化データを生成することが可能である。即ち、図1に示した符号化装置10は、例えば、テレビジョン受像機である端末装置UE1の仕様に合わせて生成された符号化データに対するトランスコードを行うことで、他の端末装置UEで再生可能な複数種類の符号化データを生成する用途において有用である。
The encoding process for the reduced image obtained by reducing each image of the moving image Vin described with reference to FIGS. 1 to 3 is performed based on the specification of the distribution destination terminal device UE from the encoded data obtained for the moving image Vin. It is an example of the transcode which produces | generates the encoding data which can reproduce | regenerate an image. The
また、図1に示した探索部11は、動画像Vinに含まれる各画像におけるマクロブロックのそれぞれを、例えばH.264規格で規定された複数種類のパーテーションタイプ(分割タイプ)で分割したブロック毎に画面間予測及び画面内予測を行ってもよい。この場合に、図1に示した変換部13は、縮小画像におけるマクロブロックを分割する分割タイプ毎に、探索部11での画面間予測及び画面内予測の結果から、分割されたブロックそれぞれについて予想される動きベクトル及び予測方向を求めてもよい。
In addition, the
図4は、図1に示した変換部13による動きベクトルの変換例を示す。なお、図4に示す要素のうち、図2に示した要素と同等のものは、同一の符号で示すとともに要素の説明を省略する場合がある。
FIG. 4 shows an example of motion vector conversion by the
図4(A)は、図1に示した探索部11により、図2(A)に示したマクロブロックMB11,MB12,MB21,MB22のそれぞれについて得られた動きベクトルの例を示す。また、図4(B)は、図4(A)に示したマクロブロックMB11〜MB22のそれぞれについて得られた動きベクトルに基づいて、図1に示した変換部13により、縮小画像のマクロブロックmb11の動きベクトルとして予想されるベクトルの例を示す。
FIG. 4A shows an example of motion vectors obtained for each of the macroblocks MB11, MB12, MB21, and MB22 shown in FIG. 2A by the
図4(A)に示した実線の矢印Vp11及び破線の矢印Vf11のそれぞれは、マクロブロックMB11について、例えば、撮影順で一つ前の画像と一つ後の画像とのそれぞれを参照画像とする画面間予測で求められた動きベクトルである。同様に、図4(A)に示した実線の矢印Vp12及び破線の矢印Vf12のそれぞれは、マクロブロックMB12について、撮影順で一つ前の画像と一つ後の画像とをそれぞれ前側参照画像及び後側参照画像として用いた画面間予測で求められた動きベクトルである。また、図4(A)に示した実線の矢印Vp21及び破線の矢印Vf21のそれぞれは、マクロブロックMB21について、撮影順で一つ前の画像と一つ後の画像とをそれぞれ前側参照画像及び後側参照画像として用いた画面間予測で求められた動きベクトルである。そして、図4(A)に示した実線の矢印Vp22及び破線の矢印Vf22のそれぞれは、マクロブロックMB22について、撮影順で一つ前の画像と一つ後の画像とをそれぞれ前側参照画像及び後側参照画像として用いた画面間予測で求められた動きベクトルである。 Each of the solid-line arrow Vp11 and the broken-line arrow Vf11 shown in FIG. 4A indicates, for example, each of the previous image and the next image in the shooting order for the macroblock MB11. This is a motion vector obtained by inter-screen prediction. Similarly, each of the solid-line arrow Vp12 and the broken-line arrow Vf12 shown in FIG. 4A indicates the previous reference image and the next image in the shooting order for the macroblock MB12, respectively. It is a motion vector calculated | required by the inter-screen prediction used as a back side reference image. Also, each of the solid-line arrow Vp21 and the broken-line arrow Vf21 shown in FIG. 4A indicates the front reference image and the rear image for the macroblock MB21, respectively, one image before and one image in the shooting order. This is a motion vector obtained by inter-screen prediction used as a side reference image. The solid line arrow Vp22 and the broken line arrow Vf22 shown in FIG. 4 (A) respectively indicate the previous reference image and the subsequent image for the macroblock MB22 in the shooting order. This is a motion vector obtained by inter-screen prediction used as a side reference image.
また、図4(B)に示した矩形Typ1,Typ2,Typ3,Typ4のそれぞれは、各分割タイプで分割されたマクロブロックmb11を示す。なお、図4(B)の例では、マクロブロックmb11を分割しない場合を分割タイプTyp1として示し、横方向に2分割する場合を分割タイプTyp2として示している。また、図4(B)の例では、マクロブロックmb11を縦方向に2分割する場合を分割タイプTyp3として示し、縦方向及び横方向にそれぞれ2分割する場合を分割タイプTyp4として示している。 Each of the rectangles Typ1, Typ2, Typ3, and Typ4 illustrated in FIG. 4B indicates a macroblock mb11 that is divided according to each division type. In the example of FIG. 4B, the case where the macroblock mb11 is not divided is shown as a division type Typ1, and the case where it is divided into two in the horizontal direction is shown as a division type Typ2. In the example of FIG. 4B, a case where the macroblock mb11 is divided into two in the vertical direction is shown as a division type Typ3, and a case where the macroblock mb11 is divided into two in the vertical direction and the horizontal direction is shown as a division type Typ4.
そして、図4(B)において実線で示した矢印Vpc11,Vpc12,Vpc21,Vpc22のそれぞれは、図4(A)に示した縮小前の動きベクトルVp11,Vp12,Vp21,Vp22のそれぞれを縮小したベクトルを示す。同様に、図4(B)において実線で示した矢印Vfc11,Vfc12,Vfc21,Vfc22のそれぞれは、図4(A)に示した縮小前の動きベクトルVf11,Vf12,Vf21,Vf22のそれぞれを縮小したベクトルを示す。 The arrows Vpc11, Vpc12, Vpc21, and Vpc22 indicated by solid lines in FIG. 4B are vectors obtained by reducing the respective motion vectors Vp11, Vp12, Vp21, and Vp22 before reduction shown in FIG. Indicates. Similarly, arrows Vfc11, Vfc12, Vfc21, and Vfc22 indicated by solid lines in FIG. 4B reduce the respective motion vectors Vf11, Vf12, Vf21, and Vf22 before reduction shown in FIG. Indicates a vector.
図4(B)の例は、図2の例と同様に、変換部13により、各分割タイプで分割されたブロックの動きベクトルを、当該ブロックに対応付けられる縮小前のマクロブロックのうち、左上に位置するマクロブロックの動きベクトルに基づいて決定する場合を示す。例えば、図4(B)に分割タイプTyp1として示した縮小画像のマクロブロックmb11の動きベクトルVpc11,Vfc11は、変換部13により、動きベクトルVp11,Vf11のそれぞれを縮小することで得られている。同様に、図4(B)にて、分割タイプTyp2でマクロブロックmb11を分割した場合の上側のブロックの動きベクトルVpc11,Vfc11は、変換部13により、動きベクトルVp11,Vf11のそれぞれを縮小することで得られている。一方、図4(B)にて、分割タイプTyp2でマクロブロックmb11を分割した場合の下側のブロックの動きベクトルVpc21,Vfc21は、変換部13により、動きベクトルVp21,Vf21のそれぞれを縮小することで得られている。また、図4(B)で、分割タイプTyp3でマクロブロックmb11を分割した場合の左側のブロックの動きベクトルVpc11,Vfc11は、変換部13により、動きベクトルVp11,Vf11のそれぞれを縮小することで求められる。一方、図4(B)で、分割タイプTyp3でマクロブロックmb11を分割した場合の右側のブロックの動きベクトルVpc12,Vfc12は、変換部13により、動きベクトルVp12,Vf12のそれぞれを縮小することで求められる。そして、図4(B)で、分割タイプTyp4でマクロブロックmb11を分割した場合の左上のブロックの動きベクトルVpc11,Vfc11は、変換部13により、動きベクトルVp11,Vf11のそれぞれを縮小することで求められる。また、図4(B)で、分割タイプTyp4でマクロブロックmb11を分割した場合の右上のブロックの動きベクトルVpc12,Vfc12は、変換部13により、動きベクトルVp12,Vf12のそれぞれを縮小することで求められる。また、図4(B)で、分割タイプTyp4でマクロブロックmb11を分割した場合の左下のブロックの動きベクトルVpc21,Vfc21は、変換部13により、動きベクトルVp21,Vf21のそれぞれを縮小することで求められる。そして、図4(B)で、分割タイプTyp4でマクロブロックmb11を分割した場合の右下のブロックの動きベクトルVpc22,Vfc22は、変換部13により、動きベクトルVp22,Vf22のそれぞれを縮小することで求められる。
In the example of FIG. 4B, as in the example of FIG. 2, the motion vector of the block divided by each division type by the
また、変換部13は、図2で説明したようにして、図4(B)に示した各分割タイプTyp1〜Typ4でマクロブロックmb11を分割した各ブロックについて求めた動きベクトルで示される予測画像と各ブロックとの予測誤差の総和を第2コストとして求める。図4を用いて説明したようにして、変換部13は、分割タイプが異なる画面間予測モード毎に、縮小画像の各マクロブロックについての第2コストを求めることができる。
Further, as described with reference to FIG. 2, the
図5は、図1に示した変換部13による予測方向の変換例を示す。なお、図5に示す要素のうち、図2及び図4に示した要素と同等のものは、同一の符号で示すとともに要素の説明を省略する場合がある。
FIG. 5 shows a conversion example of the prediction direction by the
図5(A)は、図1に示した探索部11により、図2(A)に示したマクロブロックMB11,MB12,MB21,MB22のそれぞれについて画面内予測を行うことで得られた予測方向の例を示す。また、図5(B)は、図5(A)に示したマクロブロックMB11〜MB22のそれぞれについて得られた予測方向に基づいて、図1に示した変換部13により、縮小画像のマクロブロックmb11の予測方向として予想される方向の例を示す。
FIG. 5A shows a prediction direction obtained by performing intra prediction for each of the macroblocks MB11, MB12, MB21, and MB22 shown in FIG. 2A by the
図5(A)に示した破線の矢印Vr11、Vr12,Vr21,Vr22のそれぞれは、探索部11によるマクロブロックMB11、MB12,MB21,MB22のそれぞれについての画面内予測で他の方向よりも予測誤差が少ないとされた予測方向を示す。探索部11により、H.264規格で規定された画面内予測が行われる場合に、予測方向Vr11、Vr12,Vr21,Vr22のそれぞれは、H.264規格で規定された9つの方向の一つとなる。
The broken arrows Vr11, Vr12, Vr21, and Vr22 shown in FIG. 5A indicate prediction errors in the intra prediction for each of the macroblocks MB11, MB12, MB21, and MB22 by the
図5(B)の例は、各分割タイプでマクロブロックmb11を分割して得られるブロックの予測方向を、当該ブロックに対応付けられる縮小前のマクロブロックのうち、左上に位置するマクロブロックについて得られた予測方向とする場合を示している。 In the example of FIG. 5B, the prediction direction of the block obtained by dividing the macroblock mb11 by each division type is obtained for the macroblock located at the upper left among the macroblocks before reduction associated with the block. In this case, the predicted direction is set.
例えば、図5(B)に分割タイプTyp1として示した例で、変換部13により、マクロブロックmb11の予測方向として得られる方向は、図5(A)に示したマクロブロックMB11について得られた予測方向Vr11となる。同様に、図5(B)にて分割タイプTyp2でマクロブロックmb11を分割した場合の上側のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB11について得られた予測方向Vr11となる。一方、図5(B)にて分割タイプTyp2でマクロブロックmb11を分割した場合の下側のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB21について得られた予測方向Vr21となる。また、図5(B)にて分割タイプTyp3でマクロブロックmb11を分割した場合の左側のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB11について得られた予測方向Vr11となる。一方、図5(B)にて分割タイプTyp3でマクロブロックmb11を分割した場合の右側のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB12について得られた予測方向Vr12となる。そして、図5(B)にて分割タイプTyp4でマクロブロックmb11を分割した場合の左上のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB11について得られた予測方向Vr11となる。また、図5(B)にて分割タイプTyp4でマクロブロックmb11を分割した場合の右上のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB12について得られた予測方向Vr12となる。また、図5(B)にて分割タイプTyp4でマクロブロックmb11を分割した場合の左下のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB21について得られた予測方向Vr21となる。そして、図5(B)にて分割タイプTyp4でマクロブロックmb11を分割した場合の右下のブロックについて、変換部13により予測方向として得られる方向は、図5(A)に示したマクロブロックMB22について得られた予測方向Vr22となる。
For example, in the example shown as the division type Typ1 in FIG. 5B, the direction obtained as the prediction direction of the macroblock mb11 by the
また、変換部13は、図5(B)に分割タイプTyp1として示したマクロブロックmb11について予想された予測方向Vr11を用いてマクロブロックmb11を画面内符号化した場合に、予想される予測誤差を示す第2コストを次のようにして求める。例えば、変換部13は、マクロブロックMB11〜MB22のそれぞれについて画面内予測を行った際に予測方向Vr11について得た予測誤差を探索部11から受け、受けた予測誤差に縮小率に応じた係数を乗じた上で互いに加算することで第2コストを求める。ここで、マクロブロックMB11〜MB22のそれぞれについて画面内予測を行った際に予測方向Vr11について得た予測誤差は、第1コストの一例である。
Further, the
同様にして、変換部13は、マクロブロックmb11を分割タイプTyp2〜Typ4のそれぞれで分割した各ブロックについて予想される予測誤差を求め、求めた予測誤差から、分割タイプTyp2〜Typ4のそれぞれでの第2コストを求めることができる。即ち、変換部13は、分割タイプが異なる画面内符号化モード毎に、縮小前のマクロブロックについて得られた第1コストから、縮小画像の各マクロブロックについての第2コストを求めることができる。
Similarly, the
図4及び図5で説明したように、図1に示した変換部13は、例えば、H.264規格で規定された分割タイプのそれぞれで縮小画像のマクロブロックを分割して画面間予測及び画面内予測を行った場合について、それぞれ第2コストを求めることができる。即ち、変換部13は、画面間予測と画面内予測とから選択される予測手法と選択された予測手法で用いられる分割タイプとの組み合わせで示される複数のモード毎に、当該モードでの予測誤差を示す第2コストを求めることができる。
As described with reference to FIGS. 4 and 5, the
そして、複数のモードの何れかについて求められた第2コストが第1閾値以下である場合に、制御部14は、第2コストが第1閾値以下とされたモードについて得られた動きベクトルあるいは予測方向を用いた符号化処理を符号化部12に実行させてもよい。これにより、符号化部12において、例えば、H.264規格に従う符号化処理を行う場合にも、符号化データから再生される動画像の画質を維持しつつ、符号化処理にかかる時間の短縮を図ることができる。
And when the 2nd cost calculated | required about any of several modes is below a 1st threshold value, the control part 14 is a motion vector or prediction obtained about the mode by which the 2nd cost was below the 1st threshold value. You may make the
ところで、例えばH.264規格に従った符号化処理によって動画像を符号化した際に得られる各モードの符号化データの量と、変換部13により各モードについて求められる第2コストとの間には大まかな相関関係がある。なぜなら、最終的な符号化データの量は、予測誤差を直交変換した係数を量子化することで得られる情報量と、動きベクトルや予測方向を示す情報をエントロピー符号化することで得られる情報量との和であり、前者の情報量は後者に比べて大きいからである。しかしながら、複数のモードのそれぞれについて求められた第2コストの差が小さい場合には、動きベクトルなどの情報をエントロピー符号化することで得られる情報量の大きさにより、最終的な符号化データの量を最小とするモードが逆転してしまう可能性がある。
By the way, for example, H.H. A rough correlation between the amount of encoded data of each mode obtained when encoding a moving image by encoding processing according to the H.264 standard and the second cost obtained for each mode by the
図6及び図7では、最終的な符号化データの量が複数のモード間で逆転する可能性を考慮して、トランスコードによって得られる動きベクトルあるいは予測方向を採用するか否かを判断する手法が説明される。 6 and 7, a method for determining whether to adopt a motion vector or a prediction direction obtained by transcoding in consideration of the possibility that the final amount of encoded data is reversed between a plurality of modes. Is explained.
図6は、符号化装置の別実施形態を示す。なお、図6に示す構成要素のうち、図1に示した構成要素と同等のものは、同一の符号で示すとともに構成要素の説明を省略する場合がある。 FIG. 6 shows another embodiment of the encoding device. 6 that are equivalent to the components shown in FIG. 1 are denoted by the same reference numerals and description of the components may be omitted.
図6に示した符号化装置10aは、探索部11aと、符号化部12aと、変換部13aと、制御部14aとを含む。探索部11aは、図1に示した探索部11に相当する構成要素であり、動画像データベースDBから符号化処理の対象となる動画像Vinを受ける。同様に、符号化部12aは、図1に示した符号化部12に相当する構成要素であり、動画像データベースDBから符号化処理の対象となる動画像Vinを受ける。また、符号化部12aは、制御部14aからの指示に従って、受けた動画像Vinから、画面サイズやフレームレートなどが異なるn種類の符号化条件のそれぞれで再生可能な符号化データC1〜Cnを生成する。そして、符号化部12aで生成された符号化データC1〜Cnは、配信装置DTを介して、例えば、図1に示した端末装置UE1〜UE4などに配信される。
The
探索部11aは、例えば、H.264規格などに従って、図4及び図5で説明したモードごとに、動画像Vinに含まれる各画像における各マクロブロックの動きベクトルあるいは予測方向を示す第1情報と、予測誤差を示す第1コストとを求める。探索部11aによってモード毎に求められた第1情報及び第1コストは、変換部13aに渡される。
The
変換部13aは、図1に示した変換部13に相当する構成要素である。変換部13aは、探索部11aから受けた第1情報に基づいて、n種類の符号化条件のそれぞれに従ってサイズ等が変換された画像におけるマクロブロック毎に、図4及び図5で説明した各モードで予想される動きベクトルまたは予測方向を示す第2情報を求める。また、変換部13aは、変換部13aは、探索部11aから受けた第1コストに基づいて、各符号化条件に従ってサイズ等が変換された画像におけるマクロブロック毎に、図4及び図5で説明した各モードで予想される予測誤差を示す第2コストを求める。
The
図6に示した制御部14aは、図1に示した制御部14に相当する構成要素であり、選択部141と抑止部142とを含む。
The
選択部141は、例えば、各符号化条件に対応して予め設定された第1閾値(Th1)を配信装置DTから受ける。また、選択部141は、受けた第1閾値Th1のそれぞれと、同じ符号化条件に従ってサイズ等が変換された画像のマクロブロックについて変換部13aによりモード毎に求められた第2コストとを比較する。例えば、選択部141は、スマートホンなどである端末装置UE3の画面サイズ等に応じて設定された第1閾値Th1と、端末装置UE3の画面サイズ等に縮小された縮小画像のマクロブロックについて求められた各モードの第2コストとを比較する。そして、選択部141は、何れかのモードについて変換部13aで求められた第2コストが第1閾値Th1以下である場合に、第2コストが第1閾値Th1以下とされたモードで求められた動きベクトル又は予測方向を示す第2情報を選択する。例えば、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて変換部13aで求められた第2コストのそれぞれが第1閾値Th1以下である場合に、選択部141は、2つのモードのそれぞれでの動きベクトルを示す第2情報を選択する。選択部141によって選択された第2情報は、対応する第2コストとともに抑止部142に渡される。
For example, the
抑止部142は、符号化条件毎に設定された第1閾値を用いた選択で、少なくとも一つの第2情報が選択された場合に、変換部13で求められた第2コストの中で、他の第2コストよりも小さい2つの第2コストの差を求める。例えば、選択部141により、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて求められた第2情報が選択された場合に、選択された2つのモードに対応して求められた第2コストは他の第2コストよりも小さい2つの第2コストとなる。この場合に、抑止部142は、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて求められた2つの第2コストの差を求める。そして、抑止部142は、求めた第2コストの差が、予め設定された第2閾値(Th2)よりも大きい場合に、選択部141によって選択された第2情報を符号化部12aに渡す。この場合に、符号化部12aにより、第2情報で示される動きベクトル又は予測方向を用いた符号化処理が実行される。一方、求めた第2コストの差が第2閾値Th2以下である場合に、抑止部142は、例えば、選択部141で選択された第2情報を符号化部12aに渡さずに廃棄することで、符号化部12aによる利用を抑止する。
In the second cost obtained by the
抑止部142において用いられる第2閾値Th2は、例えば、動きベクトルや予測方向を示す情報をエントロピー符号化した場合に得られる符号量のばらつき程度の値に予め設定されることが望ましい。また、予め設定された第2閾値Th2は、制御部14aに含まれるメモリなどの記憶部に保持されていてもよい。
For example, the second threshold Th2 used in the
図7は、図6に示した抑止部142で第2閾値Th2と比較される第2コストの差の例を示す。図7(A)は、図6に示した選択部141によって選択された2つのモードに対応する第2コストの差が第2閾値Th2よりも大きい場合を示す。また、図7(B)は、図6に示した選択部141によって選択された2つのモードに対応する第2コストの差が第2閾値Th2以下である場合を示す。なお、図7(A),(B)に示した棒グラフにおいて、横軸mdは、選択部141によって第2情報が選択されたモードを示し、縦軸Ctは、選択されたモードについて変換部13aで求められた第2コストの大きさを示す。
FIG. 7 shows an example of the difference in the second cost compared with the second threshold Th2 by the
図7(A)に示した白色の矩形Cpa1,Cpa4のそれぞれは、例えば、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて変換部13aで求められた第2コストの例を示す。また、図7(A)に示した網掛けされた矩形Cta1,Cta4のそれぞれは、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて変換部13aで求められた動きベクトルを用いた符号化によって生成される符号量の例を示す。なお、図7(A)において、矢印dは、分割タイプTyp1で画面間予測を行うモードの第2コストCpa1と分割タイプTyp4で画面間予測を行うモードの第2コストCpa4との差を示す。
Each of the white rectangles Cpa1 and Cpa4 illustrated in FIG. 7A represents an example of the second cost obtained by the
符号量Cta1は、分割タイプTyp1で画面間予測を行うモードについて変換部13aで求められた動きベクトルを用いた場合の予測誤差を示す情報の量と、動きベクトル等をエントロピー符号化した情報の量との和で示される。同様に、符号量Cta4は、分割タイプTyp4で画面間予測を行うモードについて変換部13aで求められた動きベクトルを用いた場合の予測誤差を示す情報の量と、動きベクトル等をエントロピー符号化した情報の量との和で示される。
The code amount Cta1 is the amount of information indicating a prediction error when the motion vector obtained by the
ここで、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて変換部13aで求められた動きベクトルを用いた場合の予測誤差は、変換部13aにより、同じモードについて求められた第2コストとほぼ同等である。一方、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて変換部13aで求められた動きベクトル等をエントロピー符号化することで得られる符号化情報の量は、第2コストの大きさにかかわらず、所定の範囲で変動する。
Here, the prediction error when the motion vector obtained by the
図7(A)の例では、第2コストCpa1と第2コストCpa4との差dは、符号化された動きベクトル等を示す情報の量のばらつきと同程度に設定された第2閾値Th2よりも大きい。このため、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードでの動きベクトル等を示す符号化情報の量の違いにかかわらず、第2コストCpa1,Cpa4の大小関係は符号量Cta1,Cta4の大小関係において維持されている。 In the example of FIG. 7A, the difference d between the second cost Cpa1 and the second cost Cpa4 is based on the second threshold value Th2 set to the same degree as the variation in the amount of information indicating the encoded motion vector or the like. Is also big. For this reason, the magnitude relationship of the second costs Cpa1, Cpa4 is the code amount Cta1, Cta4 regardless of the difference in the amount of encoded information indicating the motion vector or the like in the inter-frame prediction mode in each of the division types Typ1, Typ4. Is maintained in a large and small relationship.
したがって、選択部141によって選択された2つのモードに対応する第2コストの差が第2閾値Th2よりも大きい場合に、第2コストが他のモードよりも小さいモードは、他のモードを用いた符号化よりも少ない情報量で符号化可能なベストモードを示す。即ち、この場合に、選択部141による選択で得られた第2情報で示される動きベクトル等を用いた符号化処理を符号化部12aに実行させることで、画質の維持と符号化処理の高速化を両立させつつ、更に、生成される符号量を低減できる。
Therefore, when the difference between the second costs corresponding to the two modes selected by the
一方、図7(B)に示した白色の矩形Cpb1,Cpb4のそれぞれは、例えば、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて変換部13aで求められた第2コストの別例を示す。また、図7(B)に示した網掛けされた矩形Ctb1,Ctb4のそれぞれは、分割タイプTyp1,Typ4のそれぞれで画面間予測を行うモードについて変換部13aで求められた動きベクトルを用いた符号化によって生成される符号量の別例を示す。なお、図7(B)において、矢印dは、分割タイプTyp1で画面間予測を行うモードの第2コストCpb1と分割タイプTyp4で画面間予測を行うモードの第2コストCpb4との差を示す。
On the other hand, each of the white rectangles Cpb1 and Cpb4 shown in FIG. 7B is another example of the second cost obtained by the
図7(B)の例では、第2コストCpb1と第2コストCpb4との差dは、動きベクトル等をエントロピー符号化した情報の量のばらつきと同程度に設定された第2閾値Th2よりも小さい。このため、分割タイプTyp4を用いたモードの動きベクトル等の符号量が分割タイプTyp1を用いたモードの動きベクトル等の符号量よりも大きい場合に、符号量Ctb4が符号量Ctb1よりも大きくなる場合がある。つまり、複数のモードについて得られた第2コストの差が第2閾値Th2よりも小さい場合には、第2コストが第1閾値以下であっても、第2コストが最小となるモードがベストモードであるとは限らない。したがって、この場合に、図6に示した抑止部142により、選択部141で選択された第2情報を廃棄し、符号化部12aに、動きベクトル等の探索を実行させることで、パラメータを示す符号化情報の量を含めた最終的な符号量を低減することができる。
In the example of FIG. 7B, the difference d between the second cost Cpb1 and the second cost Cpb4 is larger than the second threshold Th2 set to be approximately the same as the variation in the amount of information obtained by entropy encoding motion vectors and the like. small. For this reason, the code amount Ctb4 is larger than the code amount Ctb1 when the code amount such as the motion vector of the mode using the division type Typ4 is larger than the code amount such as the motion vector of the mode using the division type Typ1. There is. That is, when the difference between the second costs obtained for a plurality of modes is smaller than the second threshold Th2, the mode in which the second cost is the smallest is the best mode even if the second cost is equal to or less than the first threshold. Not necessarily. Therefore, in this case, the
即ち、図6に示した抑止部142を有する制御部14は、動きベクトル等のパラメータを示す符号化情報の量のばらつきを考慮しない場合に比べて、符号化部12aによって生成される符号化データの量を低減することができる。したがって、図6に示した符号化装置10aは、例えば、符号化データの伝送に利用可能な帯域に制限がある場合のように、符号化データの量を抑制することが望まれる用途において有用である。
That is, the control unit 14 having the
図1及び図6に示した本件開示の符号化装置10は、コンピュータ装置等を用いて実現することができる。
The
図8は、図6に示した符号化装置10aのハードウェア構成の一例を示す。なお、図8に示した構成要素のうち、図6に示した構成要素と同等のものについては、同一の符号を付して示し、その説明は省略する。
FIG. 8 illustrates an example of a hardware configuration of the
コンピュータ装置20は、プロセッサ21と、メモリ22と、ストレージ装置23と、ネットワークインタフェース24と、ビデオインタフェース25と、符号化エンジン26と、光学ドライブ装置27とを含んでいる。図8に示したプロセッサ21と、メモリ22と、ストレージ装置23と、ネットワークインタフェース24と、ビデオインタフェース25と、符号化エンジン26と、光学ドライブ装置27とは、バスを介して互いに接続されている。また、プロセッサ21、メモリ22、ストレージ装置23、ビデオインタフェース25及び符号化エンジン26は、符号化装置10aに含まれる。一方、プロセッサ21、メモリ22、ストレージ装置23及びネットワークインタフェース24は、配信装置DTに含まれる。即ち、図8に示した例は、符号化装置10aと配信装置DTとを一つの装置とした場合のハードウェア構成を示す。
The
図8に示したコンピュータ装置20は、ネットワークインタフェース24を介してインターネットなどのネットワークNWに接続されており、ネットワークNWに接続されたサーバ装置SV及び端末装置UEとの間で情報の授受が可能である。
The
また、図8に示したビデオインタフェース25は、例えば、ビデオカメラCAMに接続されており、ビデオカメラCAMで撮影された動画像を、符号化装置10aによる符号化の対象となる動画像Vinとして取得する。
The
符号化エンジン26は、図6に示した探索部11a及び符号化部12aに相当する構成要素である。符号化エンジン26は、プロセッサ21からの指示に応じて、例えば、H.264規格等に従って動画像Vinを符号化するための処理として、画面間予測による動きベクトルの探索及び画面内予測による予測方向の探索を含む処理を実行する。なお、図6に示した探索部11a及び符号化部12aの機能は、プロセッサ21がプログラムを実行することで実現されてもよい。
The
また、図8に示した光学ドライブ装置27は、光ディスクなどのリムーバブルディスク28を装着可能であり、装着したリムーバブルディスク28に記録された情報の読出および記録を行う。
Further, the
図8に示したメモリ22は、コンピュータ装置20のオペレーティングシステムとともに、プロセッサ21が、後述する図9に示す符号化処理を実行するためのアプリケーションプログラムを格納している。なお、図9に示す符号化処理を実行するためのアプリケーションプログラムは、例えば、光ディスクなどのリムーバブルディスク28に記録して頒布することができる。そして、リムーバブルディスク28を光学ドライブ装置27に装着して読み込み処理を行うことにより、符号化処理を実行するためのアプリケーションプログラムを、メモリ22およびストレージ装置23に格納させてもよい。また、ネットワークインタフェース24を介して、符号化処理を実行するためのアプリケーションプログラムをダウンロードし、ダウンロードしたアプリケーションプログラムをメモリ22およびストレージ装置23に読み込ませてもよい。
The
そして、プロセッサ21は、メモリ22に格納されたアプリケーションプログラムを実行することにより、図6に示した変換部13a及び制御部14aの機能を果たす。
Then, the
つまり、図6に示した符号化装置10aは、例えば、図8に示したコンピュータ装置20に含まれるプロセッサ21とメモリ22とストレージ装置23とビデオインタフェース25と符号化エンジン26との協働によって実現することができる。
That is, the
図9は、図8に示した符号化装置10aの動作を示す。図9に示したステップS311〜ステップS322の各処理は、符号化処理のためのアプリケーションプログラムに含まれる処理の一例である。また、ステップS311〜ステップS322の各処理は、図8に示したプロセッサ21及びプロセッサ21からの指示に応じて動作する符号化エンジン26によって実行される。
FIG. 9 shows the operation of the
ステップS311において、プロセッサ21は、ビデオインタフェース25から受けた動画像Vinを符号化エンジン26に渡し、動画像Vinの各画像におけるマクロブロック毎に、図4、図5で説明した各モードの画面間予測及び画面内予測処理を実行させる。プロセッサ21は、例えば、ビデオインタフェース25を介してビデオカメラCAMから1以上のGOP(Group of Picture)を受ける毎に、ステップS311の処理を実行する。プロセッサ21は、ステップS311の処理の過程において、符号化エンジン26で画面間予測処理を行うことで得られた各モードの動きベクトル及び予測誤差を示す情報を、例えば、ストレージ装置23に蓄積し、以降の処理で利用してもよい。同様に、プロセッサ21は、符号化エンジン26で画面内予測処理を行うことで得られた各モードの予測方向及び予測誤差とを示す情報をストレージ装置23に蓄積し、以降の処理で利用してもよい。
In step S311, the
ステップS312において、プロセッサ21は、配信先となる端末装置UEに対応して予め設定されたn種類の符号化条件毎に、ステップS311の処理で受けた動画像Vinの画像のサイズ及びフレームレートを変換した動画像を生成する。例えば、プロセッサ21は、n種類の符号化条件を順次に選択し、選択した符号化条件で指定されたフレームレートに従って動画像Vinから画像を間引く。そして、プロセッサ21は、間引き後に残された画像のそれぞれを、選択した符号化条件で指定された縮小率で縮小することにより第2の動画像を生成する。
In step S312, the
ステップS313において、プロセッサ21は、図2で説明したようにして、ステップS312の処理で生成された第2の動画像に含まれる縮小画像における各マクロブロックに、縮小前の動画像Vinに含まれる画像におけるマクロブロックを対応付ける。
In step S313, as described with reference to FIG. 2, the
ステップS314において、プロセッサ21は、図4、図5で説明したようにして、縮小画像のマクロブロック毎に、画面間予測及び画面内予測の各モードで予想される、動きベクトルあるいは予測方向を示す第2情報及び予測誤差を示す第2コストを求める。
In step S314, the
ステップS315において、プロセッサ21は、ステップS314の処理で、図6において説明した第1閾値Th1以下の第2コストが求められたモードがあるか否かを判定する。
In step S315, the
少なくとも一つのモードについて、ステップS314の処理で第1閾値以下の第2コストが求められた場合に(ステップS315の肯定判定(YES))、プロセッサ21は、ステップS316に進む。
For at least one mode, when the second cost equal to or lower than the first threshold is obtained in the process of step S314 (Yes determination in step S315), the
ステップS316において、プロセッサ21は、ステップS314の処理で各モードについて求められた第2コストの中で、他の第2コストよりも小さい値を持つ2つの第2コストの差を求め、求めた差が図7で説明した第2閾値以下であるか否かを判定する。
In step S316, the
図7(A)の例のように、他の第2コストよりも小さい値を持つ2つの第2コストの差が第2閾値Th2よりも大きい場合に(ステップS316の否定判定(NO))、プロセッサ21は、ステップS317の処理を実行する。
As in the example of FIG. 7A, when the difference between two second costs having a value smaller than the other second costs is larger than the second threshold Th2 (No determination in step S316 (NO)). The
ステップS317において、プロセッサ21は、例えば、ステップS314の処理で最も小さい第2コストが得られたモードに対応する第2情報を符号化エンジン26に渡し、第2情報で示されるパラメータ用いた符号化を符号化エンジン26に実行させる。例えば、図7(A)の例では、プロセッサ21は、分割タイプTyp4を用いた画面間予測で得られた動きベクトルおよび参照画像を示す第2情報を符号化エンジン26に渡す。この場合に、符号化エンジン26は、縮小画像のマクロブロックについての画面間予測処理及び画面内予測処理を省略し、プロセッサ21から受けた第2情報で示される動きベクトル及び参照画像を用いた符号化処理を実行する。
In step S317, for example, the
一方、ステップS314の処理で第1閾値以下の値を持つ第2コストが求められなかった場合に(ステップS315の否定判定(NO))、プロセッサ21は、ステップS318及びステップS319の処理を実行する。また、ステップS316の処理で、他の第2コストよりも小さい値を持つ2つの第2コストの差が第2閾値Th2以下であるとされた場合に(ステップS316の肯定判定(YES))、プロセッサ21は、ステップS318及びステップS319の処理を実行する。
On the other hand, when the second cost having a value equal to or less than the first threshold value is not obtained in the process of step S314 (No determination in step S315 (NO)), the
ステップS318において、プロセッサ21は、符号化エンジン26に、縮小画像のマクロブロックについての画面間予測及び画面内予測を実行させる。
In step S318, the
ステップS319において、プロセッサ21は、ステップS318における画面間予測及び画面内予測で得られた情報を用いた符号化を、符号化エンジン26に実行させる。
In step S319, the
以上に説明したステップS316の処理の終了後、あるいは、ステップS318及びステップS319の処理の終了後に、プロセッサ21は、ステップS320の処理を実行する。
After the process of step S316 described above is completed, or after the processes of step S318 and step S319 are completed, the
ステップS320において、プロセッサ21は、縮小画像の全てのマクロブロックについて、ステップS314〜ステップS319で説明した符号化処理を実行したか否かを判定する。
In step S320, the
符号化が完了していないマクロブロックがある場合に(ステップS320の否定判定(NO))、プロセッサ21は、ステップS314に戻り、新たなマクロブロックについての符号化処理を開始する。
When there is a macroblock for which encoding has not been completed (No at Step S320 (NO)), the
一方、縮小画像に含まれる全てのマクロブロックについての符号化処理が完了した場合に(ステップS320の肯定判定(YES))、プロセッサ21は、ステップS321の処理に進む。
On the other hand, when the encoding process for all macroblocks included in the reduced image is completed (Yes in step S320), the
ステップS321において、プロセッサ21は、ステップS312の処理で符号化条件に基づく変換によって生成された動画像に含まれる全ての縮小画像についての符号化が完了したか否かを判定する。
In step S321, the
符号化が完了していない縮小画像がある場合に(ステップS321の否定判定(NO))、プロセッサ21は、ステップS313に戻り、新たな縮小画像についての符号化処理を開始する。
When there is a reduced image for which encoding has not been completed (No in step S321 (NO)), the
一方、符号化条件に基づく変換によって生成された動画像に含まれる全ての縮小画像についての符号化処理が完了した場合に(ステップS321の肯定判定(YES))、プロセッサ21は、ステップS322の処理に進む。
On the other hand, when the encoding process has been completed for all the reduced images included in the moving image generated by the conversion based on the encoding condition (Yes in step S321 (YES)), the
ステップS322において、プロセッサ21は、予め設定されたn種類の符号化条件のそれぞれで変換された動画像の全てについての符号化処理が完了したか否かを判定する。
In step S322, the
符号化が完了していない符号化条件がある場合に(ステップS321の否定判定(NO))、プロセッサ21は、ステップS312に戻り、新たな符号化条件で変換された動画像についての符号化処理を開始する。
When there is an encoding condition for which encoding has not been completed (No in step S321 (NO)), the
一方、n種類の符号化条件のそれぞれに基づく変換によって生成された動画像の全てについての符号化処理が完了した場合に(ステップS322の肯定判定(YES))、プロセッサ21は、処理を終了する。
On the other hand, when the encoding process for all the moving images generated by the conversion based on each of the n types of encoding conditions is completed (Yes in step S322 (YES)), the
以上に説明した処理を実行することで、図8に示した符号化装置10aは、例えば、ビデオカメラCAMによる撮影で得られる動画像Vinから、各種類の符号化条件に従って変換された動画像に対応する符号化データをほぼリアルタイムで生成することができる。これにより、図8に示した配信装置DTは、ビデオカメラCAMによる撮影で得られる動画像Vinまたは動画像Vinを端末装置UEのそれぞれの画面サイズなどに合わせて変換した動画像を、各端末装置UEにほぼリアルタイムで配信することが可能となる。
By executing the processing described above, the
以上の詳細な説明により、実施形態の特徴点及び利点は明らかになるであろう。これは、特許請求の範囲が、その精神および権利範囲を逸脱しない範囲で、前述のような実施形態の特徴点および利点にまで及ぶことを意図するものである。また、当該技術分野において通常の知識を有する者であれば、あらゆる改良および変更を容易に想到できるはずである。したがって、発明性を有する実施形態の範囲を前述したものに限定する意図はなく、実施形態に開示された範囲に含まれる適当な改良物および均等物に拠ることも可能である。 From the above detailed description, features and advantages of the embodiment will become apparent. It is intended that the scope of the claims extend to the features and advantages of the embodiments as described above without departing from the spirit and scope of the right. Any person having ordinary knowledge in the technical field should be able to easily come up with any improvements and changes. Therefore, there is no intention to limit the scope of the inventive embodiments to those described above, and appropriate modifications and equivalents included in the scope disclosed in the embodiments can be used.
10,10a…符号化装置;11,11a…探索部;12,12a…符号化部;13,13a…変換部;14,14a…制御部;141…選択部;142…抑止部;20…コンピュータ装置;21…プロセッサ;22…メモリ;23…ストレージ装置;24…ネットワークインタフェース;25…ビデオインタフェース;26…符号化エンジン;27…光学ドライブ装置;28…リムーバブルディスク;DB…動画像データベース;DT…配信装置;NW…ネットワーク;UE,UE1,UE2,UE3,UE4…端末装置;SV…サーバ装置;CAM…ビデオカメラ
DESCRIPTION OF
Claims (5)
前記第1の動画像から生成される、フレームレート及び画面サイズの少なくとも一方が前記第1の動画像と異なる第2の動画像に含まれる複数の第2画像のそれぞれを、前記第2画像を分割して得られる第2ブロックごとに符号化する符号化部と、
前記探索部によって得られた動きベクトル及び予測方向の少なくとも一方を示す第1情報と、前記第1情報で示される予測画像と前記第1ブロックとの違いである予測誤差を示す第1コストとのそれぞれから、前記各第2画像に含まれる前記第2ブロックのそれぞれについて画面間予測及び画面内予測の少なくとも一方を行った場合に得ることが予想される動きベクトル及び予測方向の少なくとも一方を示す第2情報と、前記第2情報で示される予測画像と前記第2ブロックとの間に予想される予測誤差を示す第2コストとのそれぞれを求める変換部と、
前記変換部で所定の第1閾値以下の第2コストが求められた前記第2ブロックを符号化する場合に、前記変換部で得られた第2情報を用いて前記符号化部に符号化させる制御部と
を備えたことを特徴とする符号化装置。 By performing at least one of inter-screen prediction and intra-screen prediction for each of the plurality of first blocks obtained by dividing each of the plurality of first images included in the first moving image, the motion vector and the prediction direction A search unit that searches for at least one of
Each of a plurality of second images included in a second moving image that is generated from the first moving image and has at least one of a frame rate and a screen size different from that of the first moving image is defined as the second image. An encoding unit for encoding each second block obtained by the division;
First information indicating at least one of a motion vector and a prediction direction obtained by the search unit, and a first cost indicating a prediction error that is a difference between the predicted image indicated by the first information and the first block A first indicating at least one of a motion vector and a prediction direction expected to be obtained when performing at least one of inter-frame prediction and intra-screen prediction for each of the second blocks included in each of the second images. A conversion unit for obtaining each of two information and a second cost indicating a prediction error predicted between the prediction image indicated by the second information and the second block;
When encoding the second block for which a second cost equal to or lower than a predetermined first threshold is encoded by the conversion unit, the encoding unit is encoded using the second information obtained by the conversion unit. An encoding device comprising: a control unit.
前記変換部は、画面間予測及び画面内予測の少なくとも一方を用いた探索において、前記第2ブロックを少なくとも一つの第3ブロックに分割する種類が異なる複数のモードのそれぞれで、前記動きベクトル及び前記予測方向の少なくとも一方を示す第3情報を含む第2情報と、前記第3情報で示される箇所と前記第3ブロックとの違いの大きさを示す第3コストの和で示される第2コストとを求め、
前記制御部は、前記変換部により前記複数のモードのそれぞれで求められた前記第2コストのうち、他の第2コストよりも小さい二つの第2コストの差が前記第1閾値よりも小さい第2閾値以下である場合に、前記符号化部による前記第2情報の利用を抑止する抑止部を有する
ことを特徴とする符号化装置。 The encoding device according to claim 1, wherein
In the search using at least one of inter-frame prediction and intra-screen prediction, the conversion unit is configured to divide the second block into at least one third block in each of a plurality of different modes, and the motion vector and the Second information including third information indicating at least one of the prediction directions, a second cost indicated by a sum of third costs indicating a difference between the location indicated by the third information and the third block; Seeking
The control unit has a second difference between the second costs obtained by the conversion unit in each of the plurality of modes, the difference between two second costs being smaller than the other second costs is smaller than the first threshold value. An encoding apparatus comprising: a suppression unit that suppresses the use of the second information by the encoding unit when the threshold value is 2 or less.
前記抑止部は、前記第2閾値として、前記符号化部におけるエントロピー符号化により前記第2情報を符号化した場合に生成される符号量の分散を示す値を用いる
ことを特徴とする符号化装置。 The encoding device according to claim 2,
The said suppression part uses the value which shows dispersion | distribution of the code amount produced | generated when the said 2nd information is encoded by the entropy encoding in the said encoding part as said 2nd threshold value. .
前記第1の動画像から生成される、フレームレート及び画面サイズの少なくとも一方が前記第1の動画像と異なる第2の動画像に含まれる複数の第2画像のそれぞれを、前記第2画像を分割して得られる第2ブロックごとに符号化する場合に、
前記探索によって得られた動きベクトル及び予測方向の少なくとも一方を示す第1情報と、前記第1情報で示される予測画像と前記第1ブロックとの違いである予測誤差を示す第1コストとのそれぞれから、前記各第2画像に含まれる前記第2ブロックのそれぞれについて画面間予測及び画面内予測の少なくとも一方を行った場合に得ることが予想される動きベクトル及び予測方向の少なくとも一方を示す第2情報と、前記第2情報で示される予測画像と前記第2ブロックとの間に予想される予測誤差を示す第2コストとのそれぞれを求め、
所定の第1閾値以下の第2コストが求められた前記第2ブロックを、前記第2ブロックについて得られた第2情報を用いて符号化する
ことを特徴とする符号化方法。 By performing at least one of inter-screen prediction and intra-screen prediction for each of the plurality of first blocks obtained by dividing each of the plurality of first images included in the first moving image, the motion vector and the prediction direction Explore at least one of
Each of a plurality of second images included in a second moving image that is generated from the first moving image and has at least one of a frame rate and a screen size different from that of the first moving image is defined as the second image. When encoding every second block obtained by dividing,
First information indicating at least one of a motion vector and a prediction direction obtained by the search, and a first cost indicating a prediction error that is a difference between the predicted image indicated by the first information and the first block, respectively. To the second block indicating at least one of a motion vector and a prediction direction expected to be obtained when at least one of inter-frame prediction and intra-screen prediction is performed for each of the second blocks included in each of the second images. Each of the information and a second cost indicating a prediction error predicted between the predicted image indicated by the second information and the second block;
An encoding method comprising: encoding the second block for which a second cost equal to or less than a predetermined first threshold is obtained using second information obtained for the second block.
前記第1の動画像から生成される、フレームレート及び画面サイズの少なくとも一方が前記第1の動画像と異なる第2の動画像に含まれる複数の第2画像のそれぞれを、前記第2画像を分割して得られる第2ブロックごとに符号化する場合に、
前記探索によって得られた動きベクトル及び予測方向の少なくとも一方を示す第1情報と、前記第1情報で示される予測画像と前記第1ブロックとの違いである予測誤差を示す第1コストとのそれぞれから、前記各第2画像に含まれる前記第2ブロックのそれぞれについて画面間予測及び画面内予測の少なくとも一方を行った場合に得ることが予想される動きベクトル及び予測方向の少なくとも一方を示す第2情報と、前記第2情報で示される予測画像と前記第2ブロックとの間に予想される予測誤差を示す第2コストとのそれぞれを求め、
所定の第1閾値以下の第2コストが求められた前記第2ブロックを、前記第2ブロックについて得られた第2情報を用いて符号化する、
処理をコンピュータに実行させることを特徴とする符号化プログラム。 By performing at least one of inter-screen prediction and intra-screen prediction for each of the plurality of first blocks obtained by dividing each of the plurality of first images included in the first moving image, the motion vector and the prediction direction Explore at least one of
Each of a plurality of second images included in a second moving image that is generated from the first moving image and has at least one of a frame rate and a screen size different from that of the first moving image is defined as the second image. When encoding every second block obtained by dividing,
First information indicating at least one of a motion vector and a prediction direction obtained by the search, and a first cost indicating a prediction error that is a difference between the predicted image indicated by the first information and the first block, respectively. To the second block indicating at least one of a motion vector and a prediction direction expected to be obtained when at least one of inter-frame prediction and intra-screen prediction is performed for each of the second blocks included in each of the second images. Each of the information and a second cost indicating a prediction error predicted between the predicted image indicated by the second information and the second block;
The second block for which the second cost equal to or lower than a predetermined first threshold is obtained is encoded using the second information obtained for the second block.
An encoding program for causing a computer to execute processing.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014071915A JP6291971B2 (en) | 2014-03-31 | 2014-03-31 | Encoding apparatus, encoding method, and encoding program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014071915A JP6291971B2 (en) | 2014-03-31 | 2014-03-31 | Encoding apparatus, encoding method, and encoding program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2015195470A true JP2015195470A (en) | 2015-11-05 |
JP6291971B2 JP6291971B2 (en) | 2018-03-14 |
Family
ID=54434166
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2014071915A Active JP6291971B2 (en) | 2014-03-31 | 2014-03-31 | Encoding apparatus, encoding method, and encoding program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6291971B2 (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2002374536A (en) * | 2001-06-15 | 2002-12-26 | Victor Co Of Japan Ltd | Encoder |
JP2003309851A (en) * | 2002-04-16 | 2003-10-31 | Mitsubishi Electric Corp | Video data converter and video data converting method |
JP2004023444A (en) * | 2002-06-17 | 2004-01-22 | Hitachi Ltd | Moving picture encoding apparatus, and moving picture recording and reproducing apparatus |
JP2007243337A (en) * | 2006-03-06 | 2007-09-20 | Nec Corp | Moving image encoding method, moving image encoding device, program, and medium |
JP2014017621A (en) * | 2012-07-06 | 2014-01-30 | Kddi Corp | Video compression format converter, video compression format conversion method and program |
-
2014
- 2014-03-31 JP JP2014071915A patent/JP6291971B2/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2002374536A (en) * | 2001-06-15 | 2002-12-26 | Victor Co Of Japan Ltd | Encoder |
JP2003309851A (en) * | 2002-04-16 | 2003-10-31 | Mitsubishi Electric Corp | Video data converter and video data converting method |
JP2004023444A (en) * | 2002-06-17 | 2004-01-22 | Hitachi Ltd | Moving picture encoding apparatus, and moving picture recording and reproducing apparatus |
JP2007243337A (en) * | 2006-03-06 | 2007-09-20 | Nec Corp | Moving image encoding method, moving image encoding device, program, and medium |
JP2014017621A (en) * | 2012-07-06 | 2014-01-30 | Kddi Corp | Video compression format converter, video compression format conversion method and program |
Also Published As
Publication number | Publication date |
---|---|
JP6291971B2 (en) | 2018-03-14 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20230118198A1 (en) | Image encoder and related non-transitory computer readable medium for image decoding | |
KR102625609B1 (en) | Image encoding device, image decoding device, image encoding method and image decoding method | |
US8842926B2 (en) | Method and apparatus for encoding and decoding coding unit of picture boundary | |
US8571106B2 (en) | Digital video compression acceleration based on motion vectors produced by cameras | |
KR102059066B1 (en) | Motion vector field coding method and decoding method, and coding and decoding apparatuses | |
US8831101B2 (en) | Method and system for determining a metric for comparing image blocks in motion compensated video coding | |
US11611758B2 (en) | Image encoder, image decoder, image encoding method, and image decoding method | |
JP2014521272A (en) | Method and apparatus for reframing and encoding video signals | |
US20160057415A1 (en) | Image encoding method, image encoding apparatus, and related encoding medium, image decoding method, image decoding apparatus, and related decoding medium | |
CN111800653A (en) | Video decoding method, system, device and computer readable storage medium | |
CN110495168A (en) | Code device, decoding apparatus, coding method and coding/decoding method | |
US20220030241A1 (en) | Encoder, decoder, encoding method, and decoding method | |
JP2007228519A (en) | Image encoding device and image encoding method | |
JP6291971B2 (en) | Encoding apparatus, encoding method, and encoding program | |
US9491455B2 (en) | Picture encoding method, picture decoding method, picture encoding apparatus, picture decoding apparatus, picture encoding program, and picture decoding program | |
CN110495179A (en) | Code device, decoding apparatus, coding method and coding/decoding method | |
KR102287277B1 (en) | Encoding apparatus and control method thereof | |
KR101407719B1 (en) | Multi-view image coding method and apparatus using variable GOP prediction structure, multi-view image decoding apparatus and recording medium storing program for performing the method thereof | |
JP2009296363A (en) | Motion vector search apparatus, and motion vector search method | |
JP2005341093A (en) | Contents adaptating apparatus, contents adaptation system, and contents adaptation method | |
JP2022523440A (en) | Null tile coding in video coding | |
KR102235314B1 (en) | Video encoding/decoding method and apparatus using paddding in video codec | |
JP2012222460A (en) | Moving image encoding apparatus, moving image encoding method, and program | |
CN117812268A (en) | Video transcoding method, device, equipment and medium | |
CN112714312A (en) | Encoding mode selection method, device and readable storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20170110 |
|
RD01 | Notification of change of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7426 Effective date: 20170803 |
|
RD03 | Notification of appointment of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7423 Effective date: 20170803 |
|
RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20170804 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20171012 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20171017 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20171212 |
|
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: 20180116 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20180129 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 6291971 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |