KR20070050335A - An estimation method for cbp and a block mode decision method using estimated cbp on a moving picture encoding system - Google Patents

An estimation method for cbp and a block mode decision method using estimated cbp on a moving picture encoding system Download PDF

Info

Publication number
KR20070050335A
KR20070050335A KR1020060042834A KR20060042834A KR20070050335A KR 20070050335 A KR20070050335 A KR 20070050335A KR 1020060042834 A KR1020060042834 A KR 1020060042834A KR 20060042834 A KR20060042834 A KR 20060042834A KR 20070050335 A KR20070050335 A KR 20070050335A
Authority
KR
South Korea
Prior art keywords
cbp
block
block mode
blocks
mode
Prior art date
Application number
KR1020060042834A
Other languages
Korean (ko)
Other versions
KR100785773B1 (en
Inventor
석진욱
조창식
김범호
전형국
이정우
김은영
Original Assignee
한국전자통신연구원
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 한국전자통신연구원 filed Critical 한국전자통신연구원
Priority to US11/529,973 priority Critical patent/US8149918B2/en
Publication of KR20070050335A publication Critical patent/KR20070050335A/en
Application granted granted Critical
Publication of KR100785773B1 publication Critical patent/KR100785773B1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/12Selection from among a plurality of transforms or standards, e.g. selection between discrete cosine transform [DCT] and sub-band transform or selection between H.263 and H.264
    • H04N19/122Selection of transform size, e.g. 8x8 or 2x4x8 DCT; Selection of sub-band transforms of varying structure or type
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/176Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/189Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the adaptation method, adaptation tool or adaptation type used for the adaptive coding
    • H04N19/196Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the adaptation method, adaptation tool or adaptation type used for the adaptive coding being specially adapted for the computation of encoding parameters, e.g. by averaging previously computed encoding parameters
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/70Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by syntax aspects related to video coding, e.g. related to compression standards

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Discrete Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

본 발명은 인터넷프로토콜 티브이(IP-TV)를 위한 동영상 부호화기에서 부호 블록 패턴 (CBP; Coded Block Pattern)을 블록간 평균과 분산으로 예측하는 방법 및 그를 이용한 블록의 모드를 결정하는 방법이다. The present invention is a method of predicting a coded block pattern (CBP) with inter-block average and variance in a video encoder for Internet Protocol TV (IP-TV) and a method of determining a block mode using the same.

이러한 본 발명은 동영상 부호화에서 첫 번째 16x16 블록 연산만으로 블록의 모든 모드를 결정할 수 있으므로 모드 결정을 위한 추가적 연산이 필요 없기 때문에 연산량이 획기적으로 감소하고 이에 따라 계산 시간을 획기적으로 줄일 수 있다.In the present invention, since all modes of a block can be determined only by the first 16x16 block operation in video encoding, the amount of computation is drastically reduced and thus the computation time can be drastically reduced because no additional operation for mode determination is required.

CBP (Coded Block Pattern), 평균, 분산, 블록 모드 결정, H.264 Coded Block Pattern (CBP), Average, Variance, Block Mode Determination, H.264

Description

동영상 부호화기를 위한 부호 블록 패턴 예측 방법과 그를 적용한 블록 모드 결정 방법{An estimation method for CBP and a block mode decision method using estimated CBP on a moving picture encoding system}{An estimation method for CBP and a block mode decision method using estimated CBP on a moving picture encoding system}

도 1은 본 발명에 적용되는 IP-TV를 위한 동영상 부호화기 (H.264 and MPEG-4 Video Compression : Video Coding for Next-Generation Multimedia', Iain E. G. Richardson, Wiley, 2003)에 대한 블록도이다. 1 is a block diagram of a video encoder for IP-TV (H.264 and MPEG-4 Video Compression: Video Coding for Next-Generation Multimedia ', Iain E. G. Richardson, Wiley, 2003) applied to the present invention.

도 2는 H.264 비디오 코덱에서 사용되는 대블록 분할 모드를 나타내는 것으로, 본 발명에 적용되는 H.264 블록 모드를 설명하기 위한 다이어그램이다.2 is a diagram illustrating a large block division mode used in an H.264 video codec, and is a diagram for explaining an H.264 block mode applied to the present invention.

도 3은 본 발명에서 1차원 DCT 출력값과 가우시안 확률밀도함수와의 비교를 통하여, 주파수/분산값(X)과 DCT출력값(Y)이 교차되는 가장 높은 값을 가지는 부분인 평균 혹은 DCT의 DC 성분을 도시하는 그래프도로서, CBP 예측을 위한 DCT 및 확률밀도 함수의 유사성에 대한 개념도이다.3 is a DC component of an average or DCT which is a portion having the highest value where the frequency / distribution value (X) and the DCT output value (Y) intersect through comparison between the one-dimensional DCT output value and the Gaussian probability density function in the present invention. Is a graph showing the similarity of DCT and probability density function for CBP prediction.

도 4는 본 발명의 실제 구현에 따르는 CBP 예측을 이용한 모드 결정 방법을 설명하기 위한 순서도이다.4 is a flowchart illustrating a mode determination method using CBP prediction according to an actual implementation of the present invention.

도 5는 본 발명의 예측된 CBP에 의한 블록 모드 결정 방법을 설명하기 위한 다이어그램으로, 대블록에서 CBP를 예측했을 때 H.264 대블록 분할 모드에 따른 CBP 분포 예제를 도시하고 있다.FIG. 5 is a diagram illustrating a method of determining a block mode by predicted CBP according to the present invention. FIG. 5 is a diagram illustrating an example of CBP distribution according to H.264 large block partitioning mode when CBP is predicted in a large block.

도 6은 본 발명의 예측된 CBP에 의한 블록 모드 결정을 위한 클러스터링 개념도로서, 도 5와 같이 대블록 상에서 CBP가 예측되었을 때, 본 발명에 의해 대블록의 분할 모드가 결정되는 것을 설명하기 위한 도면이다. FIG. 6 is a conceptual diagram of clustering for determining a block mode by predicted CBP according to the present invention. When CBP is predicted on a large block as shown in FIG. 5, a diagram illustrating a split mode of a large block is determined by the present invention. to be.

본 발명은 동영상 부호화기에서 부호 블록 패턴 (CBP; Coded Block Pattern) 예측 방법 및 그를 이용한 블록의 모드를 결정하는 방법으로, 보다 상세하게는 IP-TV를 위한 동영상 부호화기에서 CPB의 블록간 평균과 분산으로 수행되는 CBP 예측방법 및 그를 이용한 H.264 부호화 연산을 최소한으로 줄이면서 화질 저하를 피하기 위한 블록 모드 결정 방법에 관한 것이다.The present invention relates to a method of predicting a coded block pattern (CBP) in a video encoder and a mode of a block using the same, and more particularly, to an average and variance of CPBs in a video encoder for IP-TV. The present invention relates to a CBP prediction method performed and a block mode determination method for avoiding image degradation while minimizing H.264 encoding operations using the same.

화상회의, 고화질 텔레비전, 주문형 동영상(VOD) 수신기, MPEG(Moving Picture Experts Group) 영상을 지원하는 퍼스널 컴퓨터, 게임기, 지상파 디지털 방송 수신기, 디지털 위성 방송 수신기 및 케이블 텔레비전(CATV) 등에서 사용되는 디지털 영상 데이터는 영상 자체의 특성과 아날로그 신호를 디지털화하는 과정에서 데이터량이 크게 늘어나기 때문에 그대로 사용되기보다는 효율적인 압축방법에 의해 압축된다.Digital video data used in video conferencing, high-definition television, video-on-demand (VOD) receivers, personal computers that support Moving Picture Experts Group (MPEG) video, game consoles, terrestrial digital broadcast receivers, digital satellite broadcast receivers, and cable television (CATV) Compression is compressed by an efficient compression method rather than being used as it increases the amount of data in the process of digitizing the analog signal and the characteristics of the image itself.

디지털 영상 데이터의 압축은 크게 3가지 방법을 이용하고 있다. 시간적인 중복성(temporal redundancy)을 줄이는 방법과 공간적인 중복성(spatial redundancy)을 줄이는 방법 그리고 발생 부호의 통계적 특성을 이용하여 줄이는 방 법이 주로 이용된다. 이중에서 시간적인 중복성을 줄이는 대표적인 방법이 바로 움직임 추정 및 보상 방법으로서 MPEG, H.263 등 대부분의 동영상 압축 표준안에서 사용되고 있다.The compression of digital image data uses three methods. The method of reducing temporal redundancy, the method of reducing spatial redundancy, and the method using the statistical characteristics of the generated code are mainly used. Among them, a representative method of reducing temporal redundancy is motion estimation and compensation, which is used in most video compression standards such as MPEG and H.263.

현재 화면의 특정 부분에 대해 이전 또는 이후의 기준 화면으로부터 가장 유사한 부분을 찾고, 두 부분의 차이 성분만을 전송하는 움직임 추정 및 보상 방법은, 가능한 한 움직임 벡터를 정밀하게 찾을수록 전송할 차이 성분이 줄어들어 데이터를 더욱 효과적으로 줄일 수 있지만 이전 또는 이후의 화면에서 가장 유사한 부분을 찾기 위해서는 상당한 추정 시간과 계산량이 요구되어 진다. 따라서 동영상의 부호화시 시간이 가장 많이 소요되는 움직임 추정시간을 줄이는 노력이 계속되고 있다.The motion estimation and compensation method that finds the most similar part from a previous or subsequent reference screen for a specific part of the current screen, and transmits only the difference component of the two parts, the more precisely the motion vector is found, the less the difference component to be transmitted. Can be reduced more effectively, but significant estimation time and computation is required to find the most similar part of the previous or subsequent screen. Therefore, efforts have been made to reduce the motion estimation time, which takes the most time when encoding a video.

한편, 움직임 추정 방법은 크게 화소 단위(pixel-by-pixel basis)의 추정방법과 블록 단위(block-by-block basis)의 추정방법이 있으며, 이 중에서 블록 단위 추정방법이 가장 많이 사용되는 대표적인 알고리즘이다.On the other hand, the motion estimation method includes a pixel-by-pixel basis and a block-by-block basis. Among them, the block-based estimation method is the most popular algorithm. to be.

블록 단위 추정방법은 영상을 일정한 크기의 블록으로 분할하고 이전 영상의 탐색 영역내에서 현재 영상의 블록과 가장 잘 정합되는 블록을 찾는 방법이다. 찾은 블록과 현재 영상블록과의 차를 움직임 벡터라고 하는데 이를 부호화하여 처리한다. 두 블록간의 정합계산에는 여러 가지 정합함수들이 사용될 수 있는데 가장 일반적으로 사용되는 것은 두 블록간 화소들 차의 절대값을 모두 합한 값인 SAD(Sum of Absolute Difference)이다.The block unit estimation method divides an image into blocks of a predetermined size and finds a block that best matches a block of the current image in a search region of a previous image. The difference between the found block and the current video block is called a motion vector, which is encoded and processed. Various matching functions can be used to calculate the matching between two blocks. The most commonly used function is sum of absolute difference (SAD), which is a sum of absolute values of the difference between pixels between two blocks.

H.264 코덱의 경우에는 기존의 SAD 위주의 탐색 방법 대신 RDO(Rate Distortion Optimization)에 기반한 Cost 함수를 통해 탐색을 수행한다. H.264에서 사용하는 Cost 함수는 기존의 SAD 값에 부호화된 계수의 개수에 라그랑지안 멀티플라이어를 곱한 것의 합으로 이루어진 Rate-Distortion Cost를 사용하여 탐색을 하게된다. 이때 부호화된 계수의 개수는 양자화 계수값에 비례하는 값으로 치환되어 결정되며 여기에 고정된 라그랑지안 멀티플라이어 값을 곱하여 Cost값을 결정하여 탐색을 수행한다.In the case of the H.264 codec, the search is performed through the Cost function based on Rate Distortion Optimization (RDO) instead of the conventional SAD-oriented search method. The Cost function used in H.264 searches using the Rate-Distortion Cost, which is the sum of the number of encoded coefficients multiplied by the Lagrangian multiplier. In this case, the number of encoded coefficients is determined by substituting a value proportional to the quantization coefficient value, and the search is performed by determining the Cost value by multiplying the fixed Lagrangian multiplier value.

또한, H.264 동영상 부호화에서는 압축효율과 높은 화질을 동시에 얻기 위하여 기존의 동영상 부호화에서의 16 대 16 대블록 혹은 8 대 8 대블록 단위로 부호화를 수행한 것과 달리, 모두 8가지의 서로 다른 블록화 모드를 가지고 각각의 블록중에서 최소 값을 가지는 모드를 선택하도록 구성되어 있다.In addition, in the H.264 video encoding, in order to simultaneously obtain compression efficiency and high image quality, 8 different blocks are all formed, unlike encoding of 16 to 16 large blocks or 8 to 8 large blocks in the existing video encoding. It is configured to have a mode and to select a mode having a minimum value among each block.

그러나 8가지의 서로 다른 블록화 모드를 결정하기 위해서 각 모드에 대하여 정화소, 부화소 탐색뿐 아니라, 각종 부호화 연산이 모두 독립적으로 수행되어야 하기 때문에 기존의 동영상 부호화 알고리즘에 비하여 많은 계산량과 계산시간을 소비한다. 그러므로 블록 모드 결정을 위한 연산을 최소로 줄여 연산시간을 줄이면서 화질 저하를 피할 수 있어야 IP-TV를 위한 동영상 부호화기를 실제로 구현할 수 있다.However, in order to determine eight different blocking modes, each encoding operation as well as a refinement search and a subpixel search must be performed independently for each mode, which consumes much computation and computation time compared to the existing video encoding algorithm. . Therefore, the video encoder for IP-TV can be actually implemented only when the operation for determining the block mode is minimized to reduce the operation time and avoid the degradation of the image quality.

선행기술로서 미국공개특허 2003-633273(2005. 2. 3), 미국특허 6,628,845(2003. 9. 30), 한국공개특허 01-75406(2004. 4. 29), 한국공개특허 02-69129(2000. 10. 16) 및 한국공개특허 03-42350(2003. 6. 27) 등이 제시되었으나, 이들 모두는 본 발명에서와 같이 CBP(coded Block Pattern) 값을 미리 예측하여 P, B 블록 모드 예측 및 블록 결정하는 기술을 가르치고 있지 않다.As a prior art, US Patent Publication 2003-633273 (February 3, 2005), US Patent 6,628,845 (September 30, 2003), Korea Patent Publication 01-75406 (April 29, 2004), Korea Patent Publication 02-69129 (2000) 10. 16) and Korean Patent Laid-Open Publication No. 03-42350 (June 27, 2003) and the like, but all of them predict the PBP code mode by predicting the coded block pattern (CBP) values as in the present invention. Blocks are not taught the skills to determine.

따라서, 본 발명은 상술한 종래의 문제점을 해결하기 위한 것으로서, 본 발명이 이루고자 하는 기술적 과제는 IP-TV를 위한 동영상 부호화기에서 부호 블록 패턴 (CBP; Coded Block Pattern) 예측방법을 제공함을 목적으로 한다.Accordingly, an aspect of the present invention is to solve the above-described problems, and an object of the present invention is to provide a coded block pattern (CBP) prediction method in a video encoder for IP-TV. .

본 발명이 이루고자 하는 다른 기술적 과제는 IP-TV를 위한 동영상 부호화기에서 부호 블록 패턴 (CBP; Coded Block Pattern) 예측방법을 통해 블록 모드를 결정하여, H.264 부호화 연산을 최소한으로 줄이면서 화질 저하를 피하기 위한 블록 모드 결정 방법을 제공함을 목적으로 한다.Another technical problem to be solved by the present invention is to determine a block mode through a coded block pattern (CBP) prediction method in a video encoder for IP-TV, thereby reducing image quality while minimizing H.264 coding operations. It is an object of the present invention to provide a method of determining a block mode to avoid.

본 발명은 상술한 목적을 달성하기 위해 H.264 동영상 부호화기에서 부호 블록 패턴 (CBP; Coded Block Pattern)의 정의에 의한 CBP 예측 방법을 도출하고 예측된 CBP를 통해 8가지 모드의 블록 결정을 수행한다.In order to achieve the above object, the present invention derives a CBP prediction method by defining a coded block pattern (CBP) in an H.264 video encoder, and performs block determination in eight modes through the predicted CBP. .

본 발명의 바람직한 실시예에 의하면, 본 발명의 CBP 예측 방법은 16x16화소크기의 매크로블록단위로 움직임 추정을 행하여, 현재 매크로블록 및 대응하는 참조 매크로블록을 결정하는 단계; 현재 매크로블록 내의 개별 4x4블록과 참조 매크로볼록 내의 대응하는 개별 4x4블록 사이의 평균 및 분산을 계산하는 단계; 및 계산된 평균 및 분산을 이용하여 현재 매크로블록 내의 4x4블록들의 CBP값들을 예측하는 단계를 포함하는 CBP 예측 방법을 제공한다.According to a preferred embodiment of the present invention, the CBP prediction method of the present invention comprises: determining a current macroblock and a corresponding reference macroblock by performing motion estimation in units of 16 × 16 pixel macroblocks; Calculating an average and a variance between individual 4x4 blocks in the current macroblock and corresponding individual 4x4 blocks in the reference macroconvex; And predicting CBP values of 4 × 4 blocks in the current macroblock using the calculated mean and variance.

바람직하기로는 상기 평균 및 분산을 계산하는 단계에서,Preferably in the step of calculating the mean and variance,

상기 평균은, 다음 수학식(수학식 2)The average is the following equation (Equation 2)

Figure 112006033282839-PAT00001
Figure 112006033282839-PAT00001

을 이용하여 계산되며,Is calculated using

상기 분산은, 다음 수학식(수학식 3)The variance is the following equation (Equation 3)

Figure 112006033282839-PAT00002
Figure 112006033282839-PAT00002

을 이용하여 계산되며,Is calculated using

상기 수학식들에서,

Figure 112006033282839-PAT00003
는 단위 4x4 블록에서 시간 t-k, i 번째 열과 j 번째 행에서의 화소 값이며
Figure 112006033282839-PAT00004
Figure 112006033282839-PAT00005
를 통해 예측된 4x4 블록의 i 번째 열과 j 번째 행에서의 화소 값임을 특징으로 한다.In the above equations,
Figure 112006033282839-PAT00003
Is the pixel value in the time tk, the i th column and the j th row in the unit 4x4 block
Figure 112006033282839-PAT00004
Is
Figure 112006033282839-PAT00005
It is characterized in that the pixel value in the i th column and j th row of the 4x4 block predicted through.

바람직하기로는 상기 CBP값들을 예측하는 단계는,Preferably the step of predicting the CBP values,

다음 수학식(수학식 4)Next Equation (Equation 4)

Figure 112006033282839-PAT00006
Figure 112006033282839-PAT00006

를 이용하여 예측CBP값을 계산하는 단계를 포함하며,Calculating a predicted CBP value using

상기 수학식에서

Figure 112006033282839-PAT00007
Figure 112006033282839-PAT00008
이면 1, 그렇지 않으면 0의 값을 갖는 단위 계단 함수이며
Figure 112006033282839-PAT00009
는 CBP 예측을 위해 도입된 파라미터로서 다음 수학식(수학식 6)과 같이 적응적으로 갱신되며,In the above equation
Figure 112006033282839-PAT00007
Is
Figure 112006033282839-PAT00008
Is a unit step function with a value of 1, otherwise 0
Figure 112006033282839-PAT00009
Is a parameter introduced for CBP prediction, and is adaptively updated as shown in Equation 6 below.

Figure 112006033282839-PAT00010
Figure 112006033282839-PAT00010

여기서

Figure 112006033282839-PAT00011
은 적응 계수로서 0.1에서 0.25 사이의 임의 값이 선택되며 CBP는 블록 모드가 결정된 후 DCT 및 양자화를 거친후 구해지는 실제 CBP 값이며 함수
Figure 112006033282839-PAT00012
Figure 112006033282839-PAT00013
로서 계수
Figure 112006033282839-PAT00014
는 4.6 이상의 임의의 값이다.here
Figure 112006033282839-PAT00011
Is an adaptation coefficient and a random value between 0.1 and 0.25 is chosen, and CBP is the actual CBP value obtained after DCT and quantization after the block mode is determined.
Figure 112006033282839-PAT00012
Is
Figure 112006033282839-PAT00013
Coefficient as
Figure 112006033282839-PAT00014
Is any value greater than or equal to 4.6.

본 발명의 다른 태양에 의하면, 상술한 CBP 예측 방법을 이용하여 예측된 CBP값들을 이용하여 동보상을 위한 블록모드를 결정하기 위한 방법에 있어서, 현재 매크로블록의 예측CBP값들에 기초하여, 현재 매크로블록을 구성하는 4x4블록들에 의해 구성가능한 블록모드들 중에서, 추가의 움직임추정이 필요없는 블록모드 및 대응하는 4x4블록들을 결정하는 제1단계; 추가의 움직임 추정이 필요한 블록모드에 대응하는 4x4블록들에 대해 추가의 움직임추정을 행하는 제2단계; 제2단계에서 추가의 움직임 추정이 행해진 4x4블록들에 대해 CBP값들을 예측하는 제3단계; 및 제3단계에 의해 얻어진 예측CBP값들을 포함한 현재 매크로블록의 예측CBP값들에 기초하여, 현재 매크로블록을 구성하는 4x4블록들에 의해 구성가능한 블록모드들 중에서, 추가의 움직임추정이 필요없는 블록모드 및 대응하는 4x4블록들을 결정하는 제4단계를 포함하는 블록모드 결정방법을 제공한다.According to another aspect of the present invention, in a method for determining a block mode for dynamic compensation using CBP values predicted using the above-described CBP prediction method, based on the prediction CBP values of the current macroblock, the current macro A first step of determining among the block modes configurable by the 4x4 blocks constituting the block, a block mode that does not require additional motion estimation and corresponding 4x4 blocks; Performing a further motion estimation on 4x4 blocks corresponding to a block mode in which additional motion estimation is needed; A third step of predicting CBP values for 4 × 4 blocks for which additional motion estimation has been performed in a second step; And among the block modes configurable by the 4x4 blocks constituting the current macroblock, based on the prediction CBP values of the current macroblock including the prediction CBP values obtained by the third step, a block mode that does not require additional motion estimation. And a fourth step of determining corresponding 4x4 blocks.

바람직하기로는 상기 4x4블록들에 의해 구성가능한 블록모드들은, 16x16블록모드, 16x8블록모드, 8x16블록모드, 8x8블록모드, 8x4블록모드 및 4x8블록모드이며, 상기 제1단계는 16x16블록모드, 16x8블록모드, 8x16블록모드, 8x8블록모드 , 8x4블록모드 및 4x8블록모드의 각각에 대응하는 4x4블록들의 예측CBP값들 중에서 1의 갯수가 소정 수 이하이면, 당해 블록모드를 추가의 움직임추정이 필요없는 블 록모드로 결정하는 단계를 포함한다.Preferably, the block modes configurable by the 4x4 blocks are 16x16 block mode, 16x8 block mode, 8x16 block mode, 8x8 block mode, 8x4 block mode and 4x8 block mode, and the first step is 16x16 block mode, 16x8 block mode. If the number of 1s among the predicted CBP values of 4x4 blocks corresponding to each of the block mode, 8x16 block mode, 8x8 block mode, 8x4 block mode, and 4x8 block mode is less than or equal to a predetermined number, the block mode does not require additional motion estimation. Determining the block mode.

이하, 본 발명에 따른 실시예에 의한 동영상 부호화기를 위한 부호 블록 패턴 예측 방법과 그를 적용한 블록 모드 결정 방법을 첨부한 도면을 참조하여 상세히 설명하기로 한다.Hereinafter, a code block pattern prediction method for a video encoder and a block mode determination method using the same according to an embodiment of the present invention will be described in detail with reference to the accompanying drawings.

도 1은 본 발명에 적용되는 IP-TV를 위한 동영상 부호화기 (H.264 and MPEG-4 Video Compression : Video Coding for Next-Generation Multimedia', Iain E. G. Richardson, Wiley, 2003)에 대한 블록도로서, 이 중 움직임 추정기는 정화소 단위의 움직임 벡터를 추정하는 정화소 추정기와, 찾아낸 정화소의 움직임 벡터를 근거로 하여 최적의 반화소 및 1/4화소 단위의 움직임 벡터를 추정하는 부화소 추정기로 구성된다. FIG. 1 is a block diagram of a video encoder (H.264 and MPEG-4 Video Compression: Video Coding for Next-Generation Multimedia ', Iain EG Richardson, Wiley, 2003) applied to the present invention. The middle motion estimator is composed of a refiner estimator for estimating a motion vector of a refinery unit and a subpixel estimator for estimating an optimal half pixel and a motion pixel of a quarter pixel based on the found motion vector of the refinery.

도 1에서, 현재 영상 (100)은 Fn (Current) 로 표기되고, 1 단위 시간 전에 인코더내의 MC (움직임 보상기)등 에 의하여 복원된 영상들 (102)은 F'n-1 (Referenced) 로 표기되고, 현재 영상에 대한 복원 영상 (디코더에서 디코딩 영상과 동일한 영상)(112)은 F'n 로 표기되고, 여기서 n은 시간 인덱스이다. In FIG. 1, the current image 100 is denoted as Fn (Current), and the images 102 reconstructed by MC (motion compensator) in the encoder one unit time ago are denoted as F'n-1 (Referenced). The reconstructed image (the same image as the decoded image in the decoder) 112 for the current image is denoted as F'n, where n is a time index.

도 1에서 ME로 표시된 블록은 움직임 추정기 (Motion Estimation)(103)이고, MC로 표시된 블록은 움직임 보상기 (Motion Compensation)(107)이다. 또한, Choose INTRA Prediction으로 표기된 블록은 INTRA (I 영상) Prediction (인트라 예측)을 위한 예측 모드 결정기(105)이다. H.264의 경우는 16x16 휘도 영상과 8x8 색상 영상의 경우 4가지의 예측모드가 있으며 4x4의 경우는 9개의 예측 모드가 있다 이 중에서 하나의 예측 모드를 선택하여 이를 INTRA Prediction으로 보내 주어야 한다. 그 다음 INTRA Prediction으로 표기된 블록은 인트라 예측기(108)로서 Choose INTRA Prediction(105)에서 예측된 INTRA 예측 모드를 사용하여 INTRA 예측 값을 만들어 내는 부분이다. 스위치(113)는 인터모드일 때 움직임 보상기(107)에 접속되고 인트라모드일 때 인트라 예측기(108)에 접속된다.In FIG. 1, a block denoted by ME is a motion estimator 103 and a block denoted by MC is a motion compensation 107. Also, the block labeled Choose INTRA Prediction is a prediction mode determiner 105 for INTRA (I picture) Prediction (Intra prediction). In the case of H.264, there are four prediction modes in the case of 16x16 luminance image and 8x8 color image. In the case of 4x4, there are nine prediction modes. One of the prediction modes should be selected and sent to INTRA Prediction. The next block marked as an INTRA Prediction is an intra predictor 108 that generates an INTRA prediction value using the INTRA prediction mode predicted in the Choose INTRA Prediction 105. The switch 113 is connected to the motion compensator 107 when in inter mode and to the intra predictor 108 when in intra mode.

또한, T로 표시된 블록(116)은 DCT 변환을 수행하는 부분으로 H.264 에서는 정수형 4x4 예측을 기본으로 한다. Q로 표시된 블록(118)은 양자화기로 DCT 변환된 값을 양자화 시키는 부분이다. Reorder로 표시된 블록(120)은 양자화기(118)에서 나온 값을 가변장부호화(VLC)나 CABAC등으로 압축하기 위해 지그재그 스캔(Zigzag scan)하는 부분이다. In addition, block 116 denoted by T is a part for performing DCT transformation and based on integer 4x4 prediction in H.264. Block 118 denoted by Q is a part of quantizing the DCT transformed value with the quantizer. Block 120, denoted as Reorder, is a zigzag scan to compress the values from the quantizer 118 into variable length coding (VLC) or CABAC.

엔트로피 인코더(Entropy Encoder)(122)는 호프만 부호화나 CABAC에 의해 데이터를 압축하는 부분이다.Entropy encoder 122 is a part for compressing data by Huffman encoding or CABAC.

Q-1은 역 양자화기(119)로 앞에 설명한 양자화기(118)와 반대되는 기능을 수행한다. T-1은 역 DCT 변환기(117)로 역 양자화기(119)를 통과한 데이터를 역 DCT를 행하는 부분이다.Q −1 is an inverse quantizer 119 that performs the opposite function of quantizer 118 described above. T- 1 is a portion for performing inverse DCT on the data passed through the inverse quantizer 119 to the inverse DCT converter 117.

이를 통해 양자화 오차 만큼을 가진 데이터를 예측 데이터와 더하여 영상복원 (움직임 보상)을 수행하게 된다.Through this, image restoration (motion compensation) is performed by adding data having the same quantization error as the prediction data.

필터(110)(Filter)는 1차 복원된 영상에 대한 필터로서, 양자화 오차 혹은 블록 현상 등이 나타나는 영상을 필터를 통과시켜 화질 열화를 제거하는 역할을 한다. 필터(110)를 통과한 영상은 복원 영상으로서 디코더에서 디코딩된 영상과 동일 하며 이는 F'n(112)로서 저장되며 다음 영상을 인코딩할 때 F'n-1 로서 참조된다.The filter 110 is a filter for the first reconstructed image, and removes the deterioration of image quality by passing the image through which the quantization error or block phenomenon appears. The image passing through the filter 110 is the reconstructed image and is the same as the image decoded at the decoder, which is stored as F'n 112 and referred to as F'n-1 when encoding the next image.

DCT변환기(116)에 입력되는 신호 Dn은 차분 프레임(Difference Frame)으로 차영상, 즉 감산기(114)에서 원래 영상과 예측된 영상의 차로서 구해진다.The signal Dn input to the DCT converter 116 is obtained as a difference frame as a difference picture, that is, a difference between the original picture and the predicted picture in the subtractor 114.

가산기(115)의 출력 uF'n 은 필터링 되지 않은 복원 영상, 즉 차 영상에 역 양자화기(119)와 역 변환기(117)를 거친 데이터(Dn')의 합으로 구해진다.The output uF'n of the adder 115 is obtained as the sum of the data Dn 'passed through the inverse quantizer 119 and the inverse converter 117 to the unfiltered reconstructed image, that is, the difference image.

본 발명은 도 1에서 움직임 추정기(103) 및 움직임 보상기(107)와 관련되는 것으로, 움직임 추정기(103)는 정화소 탐색을 수행하는 정화소 추정기와 부화소 탐색을 수행하는 부화소 추정기로 분할되어, 정화소 추정 후 부화소 추정을 수행한다.The present invention relates to the motion estimator 103 and the motion compensator 107 in FIG. 1, wherein the motion estimator 103 is divided into a refiner estimator for performing a refinement search and a subpixel estimator for performing a subpixel search. After estimation, subpixel estimation is performed.

이하, 본 발명에 의한 적응적 CBP 예측 방법 및 그 적응적으로 예측된 CBP를 사용한 H.264 부호화기의 블록 결정 방법에 대해 설명하기로 한다. Hereinafter, an adaptive CBP prediction method and a block determination method of an H.264 encoder using the adaptively predicted CBP will be described.

먼저, 본 발명의 이해를 돕기 위하여 기존 기술과 본 발명의 차이점을 살펴보기로 한다. First, the difference between the existing technology and the present invention will be described to help understanding of the present invention.

기존에는 CBP 도출을 위해 4x4 DCT 및 양자화를 수행하고 그 결과를 통해 CBP를 구한 뒤 이를 사용하여 P 프레임에서 스킵(SKIP) 모드 혹은 B 프레임에서 다이렉트(Direct) 모드 판정에 이용하였다. 그리고 도 2에서 나타난 나머지 모드에 대해서는 정화소 및 부화소 추정을 수행하고 그에 따른 레이트 왜곡(Rate Distortion) 연산을 수행하여 최소의 레이트 왜곡 값을 가지는 모드를 선택하는 방식이었다.Conventionally, 4x4 DCT and quantization are performed to derive the CBP, and the resultant CBP is used to determine the skip mode in the P frame or the direct mode in the B frame. For the remaining modes shown in FIG. 2, a refinement and a subpixel estimation are performed, and a rate distortion calculation is performed to select a mode having a minimum rate distortion value.

도 2는 단순히 H.264 대 블록의 블록 모드를 도시한 것에 지나지 않는다. 기 존의 블록 모드 선택방식은 16x16 블록에 대한 움직임 예측(ME)을 수행하고 다시 16x8 블록 모드에 대해 2번, 8x16 블록 모드에 대해서 2번, 8x8 블록 모드에 대하여 4번, 8x4 블록 모드에 대해 8번, 4x8 블록 모드에 대해 8번, 4x4 블록 모드에 대해 16번으로, 총 41회의 ME를 수행하여 이 중에서 가장 작은 SAD이나 MSE를 가지는 블록 모드를 선택하는 방식이며 이는 H.264 인코딩 속도를 떨어뜨리는 주요 요인이 된다.2 is merely a block mode of H.264 vs. block. The existing block mode selection method performs motion prediction (ME) for 16x16 blocks and again performs 2 times for 16x8 block mode, 2 times for 8x16 block mode, 4 times for 8x8 block mode and 4 times for 8x4 block mode. Eight times, eight times for 4x8 block mode and 16 times for 4x4 block mode, 41 MEs are performed in total to select the block mode with the smallest SAD or MSE. It is a major factor.

반면에, 본 발명에서는 첫 번째 16x16 블록 모드의 정화소 및 부화소 움직임 추정이 끝난 후 별도의 DCT 연산을 수행하지 않고 추정을 통해 결정된 블록에 대하여 평균값과 분산을 구한 후 이를 통해 CBP값을 예측하고 예측된 CBP값을 가지고 블록 모드를 결정한다. 이에 의해 각 모드별 정화소, 부화소, 레이트 왜곡 연산 대신 CBP가 1로 나타나는 4x4 블록의 결합을 통해 블록 모드를 결정하게 된다.On the other hand, in the present invention, after the first 16x16 block mode refinement and subpixel motion estimation are finished, the average value and the variance of the blocks determined by the estimation are calculated without performing a separate DCT operation. The block mode is determined using the set CBP value. As a result, the block mode is determined through the combination of the 4x4 blocks in which CBP is represented by 1 instead of the refiner, the subpixel, and the rate distortion operation for each mode.

본 발명의 원리를 수학식을 통해 자세히 살펴보도록 한다. 일반적으로 CBP는 다음과 같이 결정된다.Let us look at the principle of the present invention in detail through the equation. In general, CBP is determined as follows.

먼저 X∈R4X4를 움직임 보상된 4x4 화소 데이터의 DCT 결과라고 하자. 이때 CBP는 X∈R4X4의 한 요소를 수학식 1과 같은 양자화 과정을 통해 결정된다.First, let X∈R 4X4 be the DCT result of the motion compensated 4x4 pixel data. In this case, the CBP is determined through a quantization process such that Equation 1 is an element of X∈R 4X4 .

Figure 112006033282839-PAT00015
Figure 112006033282839-PAT00015

수학식 1에서 i, j는 X∈R4X4의 i 번째 열 요소, j 번째 행 요소를 나타내는 첨자이며

Figure 112006033282839-PAT00016
는 양자화된 X∈R4X4의 i 번째 열 요소, j 번째 행 요소 이며
Figure 112006033282839-PAT00017
는 양자화 되기 전 X∈R4X4의 i 번째 열 요소, j 번째 행 요소 이며
Figure 112006033282839-PAT00018
는 H.264의 양자화 계수이다.
Figure 112006033282839-PAT00019
는 QP, i, j의 함수로서 양자화 계수에 12을 더한 것을 6으로 나눈 나머지와 i, j의 요소에 따라 결정되는 양자화 함수이며 f는 양자화 레벨 오프셋 값이다. In Equation 1, i and j are subscripts representing the i th column element and the j th row element of X∈R 4X4 .
Figure 112006033282839-PAT00016
Is the i th column element, the j th row element of quantized X∈R 4X4
Figure 112006033282839-PAT00017
Is the i th column element, the j th row element of X∈R 4X4 before quantization
Figure 112006033282839-PAT00018
Is the quantization coefficient of H.264.
Figure 112006033282839-PAT00019
Is a function of QP, i, and j, which is a quantization function determined according to the remainder of quantization coefficient plus 12 divided by 6 and the elements of i and j, and f is a quantization level offset value.

수학식 1에서 양자화 계수 QP가 하나라도 0이 아니면 4x4 블록의 CBP값은 1이 되며 그렇지 않으면 0이다. In Equation 1, if any one of the quantization coefficients QP is not 0, the CBP value of the 4x4 block is 1, otherwise it is 0.

CBP 예측은 DCT 연산의 결과를 2차원 확률 밀도 함수의 결과로 생각하고 평균과 분산으로 CBP를 도 3과 같이 예측하는 것이다.CBP prediction considers the result of the DCT operation as a result of the two-dimensional probability density function and predicts the CBP as an average and variance as shown in FIG. 3.

즉, 도 3에 도시한 바와 같이, 1 차원 DCT 출력값과 가우시안 확률밀도함수와의 비교 X, Y 가 교차되는 가장 높은 값을 가지는 부분은 평균 혹은 DCT의 DC 성분이 된다.That is, as shown in Fig. 3, the portion having the highest value where the comparison between the one-dimensional DCT output value and the Gaussian probability density function X and Y intersects is the average or DC component of the DCT.

이때 평균의 경우는 4x4 DCT 연산의 DC 성분과 같은 값이며 DC 성분을 제외한 나머지 AC 성분의 경우 분산값이 적응적으로 결정되는 임계(Threshold) 값을 넘어가면 CBP를 1, 그렇지 않으면 0으로 예측한다.In this case, the average value is the same as the DC component of the 4x4 DCT operation. For the other AC components except the DC component, the CBP is predicted to be 1 if the variance exceeds an adaptively determined threshold value, and 0 otherwise. .

평균은 수학식 2과 같이 계산되며 분산은 수학식 3과 같이 계산된다.The average is calculated as in Equation 2 and the variance is calculated as in Equation 3.

Figure 112006033282839-PAT00020
Figure 112006033282839-PAT00020

Figure 112006033282839-PAT00021
Figure 112006033282839-PAT00021

수학식 2과 3에서

Figure 112006033282839-PAT00022
는 단위 4x4 블록에서 시간 t-k, i 번째 열과 j 번째 행에서의 화소 값이며
Figure 112006033282839-PAT00023
Figure 112006033282839-PAT00024
를 통해 예측된 4x4 블록의 i 번째 열과 j 번째 행에서의 화소 값이다. CBP 예측은 수학식 4와 같이 수행되며 예측된 CBP인 ECBP가 0이 아니면 1의 값을 가진다. In Equations 2 and 3
Figure 112006033282839-PAT00022
Is the pixel value in the time tk, the i th column and the j th row in the unit 4x4 block
Figure 112006033282839-PAT00023
Is
Figure 112006033282839-PAT00024
Pixel values in the i th column and the j th row of the 4x4 block predicted through. The CBP prediction is performed as shown in Equation 4, and the predicted CBP has a value of 1 if the ECBP is not 0.

Figure 112006033282839-PAT00025
Figure 112006033282839-PAT00025

수학식 5에서

Figure 112006033282839-PAT00026
Figure 112006033282839-PAT00027
이면 1, 그렇지 않으면 0의 값을 갖는 단위 계단 함수이며
Figure 112006033282839-PAT00028
는 CBP 예측을 위해 도입된 파라미터로서 수학식 5와 같이 적응적으로 갱신된다.In equation (5)
Figure 112006033282839-PAT00026
Is
Figure 112006033282839-PAT00027
Is a unit step function with a value of 1, otherwise 0
Figure 112006033282839-PAT00028
Is adaptively updated as shown in Equation 5 as a parameter introduced for CBP prediction.

Figure 112006033282839-PAT00029
Figure 112006033282839-PAT00029

수학식 5에서

Figure 112006033282839-PAT00030
은 적응 계수로서 0.1에서 0.25 사이의 임의 값이 선택되며 CBP는 블록 모드가 결정된 후 DCT 및 양자화를 거친후 구해지는 실제 CBP 값이며 함수
Figure 112006033282839-PAT00031
Figure 112006033282839-PAT00032
로서 계수
Figure 112006033282839-PAT00033
는 4.6 이상의 임의의 값이다.In equation (5)
Figure 112006033282839-PAT00030
Is an adaptation coefficient and a random value between 0.1 and 0.25 is chosen, and CBP is the actual CBP value obtained after DCT and quantization after the block mode is determined.
Figure 112006033282839-PAT00031
Is
Figure 112006033282839-PAT00032
Coefficient as
Figure 112006033282839-PAT00033
Is any value greater than or equal to 4.6.

도 4를 참조하여 상기 설명한 CBP예측방법에 대하여 상세히 설명하기로 한다. 도 4에서, 동영상부호화기(도 1)에서 대블록 부호화를 위한 초기화를 수행한 후(400), 16x16 블록의 동벡터(MV)를 예측하고(410), 16x16 정화소/부화소 탐색을 통하여 CBP를 예측한다(420). 단계 420에서 16x16 탐색 후 예측된 블록에 대하여 CBP예측하고 동벡터를 미분한 값이 0이고(dMV=0), 16개의 CBP가 모두 0이면 스킵/다이렉트 모드로 판정한다(425).The CBP prediction method described above with reference to FIG. 4 will be described in detail. In FIG. 4, after performing initialization for large block encoding in a video encoder (FIG. 1) (400), a motion vector (MV) of a 16 × 16 block is predicted (410), and a CBP is searched through a 16 × 16 refiner / subpixel search. Prediction 420. In step 420, if the CBP prediction is performed on the predicted block after the 16x16 search and the derivative of the motion vector is 0 (dMV = 0), and all 16 CBPs are 0, it is determined as a skip / direct mode (425).

단계 430에서 스킵/다이렉트 체크 결과, 즉 예측된 CBP가 모두 0이면 단계 490으로 진행하여 대블록 관련 파라미터를 H.264 시퀀스에 기록한다.In step 430, if the skip / direct check result, that is, the predicted CBP is all 0, the process proceeds to step 490 to record the large block related parameter in the H.264 sequence.

단계 430에서 스킵/다이렉트 체크 결과, 즉 예측된 CBP가 모두 0이 아니면 단계 440으로 진행하여 I블록을 예측하여 예(yes)이면 단계 470으로 진행한다. 단계 440에서는 칼만 필터(Kalman filter)를 사용하여 예측한다(445).If the result of the skip / direct check in step 430, that is, the predicted CBP is not all zeros, proceeds to step 440 to predict the I block, and if yes, to step 470. In operation 440, the prediction is performed using a Kalman filter (445).

그 다음 단계 450에서 RD_cost 평가를 수행한다. 그 후 단계 460에서 모드를 결정한다. 이때 ECBP=0이면 추가연산은 불필요하다. 이 경우, 예측된 CBP를 사용하여 모드 클러스터링을 통해 모드 결정 CPB가 1인 경우 해당 블록에서 탐색 수행한다(465). 단계 470에서는 단계 460을 거친 후 또는 단계 440에서 예이면 DCT Q/IQ IDCT 와 DC 하다마드(Hadamard)를 구한다. 여기서 실제 CBP를 구한다(475). 단계 480에서 CBP예측을 위한 파라미터를 갱신하고 단계 490에서 대블록 관련 파라미터를 H.264 시퀀스에 기록하고, 단계 500으로 진행하여 대블록 파라미터 세팅을 진행한다.Next, in step 450, the RD_cost evaluation is performed. The mode is then determined in step 460. If ECBP = 0, no further operation is required. In this case, when the mode determination CPB is 1 through mode clustering using the predicted CBP, a search is performed in the corresponding block (465). In step 470, DCT Q / IQ IDCT and DC Hadamard are obtained after the step 460 or in step 440. Here, the actual CBP is obtained (475). In step 480, the parameters for CBP prediction are updated, and in step 490, the large block related parameters are recorded in the H.264 sequence.

한편, 수학식 5과 같은 CBP 예측은 도 2와 같은 단계를 거쳐 모드 결정을 수 행하게 되며 DCT 및 양자화 과정을 통해 구해지는 실제 CBP를 통해 파라미터를 갱신하게 된다. 예측된 CBP를 통해 블록 모드는 도 5와 같이 나타날 수 있으므로 도 6과 같은 클러스터링 알고리즘을 도입하면 예측된 CBP가 0인 블록의 경우 블록 모드는 별도의 추가적인 연산 없이 블록 모드가 결정되며 예측된 CBP가 1인 블록에 대하여만 추가적인 탐색과정을 수행하여 보다 압축효율이 높은 블록 모드를 결정하게 된다.On the other hand, the CBP prediction as shown in Equation 5 performs the mode decision through the steps shown in FIG. 2 and updates the parameter through the actual CBP obtained through the DCT and the quantization process. Since the block mode may be shown as shown in FIG. 5 through the predicted CBP, when the clustering algorithm as shown in FIG. 6 is introduced, the block mode is determined without any additional operation and the predicted CBP is determined in the case of the block having the predicted CBP of 0. An additional search process is performed on only one block to determine a block mode with higher compression efficiency.

도 5에서, 좌측 상단 블록 모드 패턴(510)은 16x16 대 블록에 대한 ME 과정이 끝난 후 MC 과정에서 구해진 CBP를 나타낸 것이다. CBP는 4x4 블록 단위로 1 혹은 0의 값을 가지므로 16x16 대 블록에서 좌측 최상단과 같이 값을 가질 수 있다. CBP가 0이라는 것은 4x4 블록의 DCT-양자화 과정에서 나타난 데이터 값이 모두 0이라는 의미이다. 그러므로 CBP가 0인 경우에는 추가적인 다음 블록 모드에 대한 움직임 추정(ME)을 수행할 필요가 없다. 나머지 그림들은 각 대 블록 모드에 대한 CBP 분포이다. 만일 각 대블록 모드에서 CBP가 1인 경우가 1 혹은 2 보다 작다면 블록 모드별 ME를 추가적으로 수행할 필요가 없다. 도 5에서 상단 두 번째 블록 모드 패턴(520)은 16x8 블록 모드에 대한 CBP 분포이다. 16x16 블록 모드의 경우와 비교하면 16x8의 경우 상단 16x8 블록의 CBP는 2개만 1이고 나머지는 0이다. 그러므로 상단 16x8의 경우 추가적인 모드 별 ME가 불필요할 수 있다. 상단 우측 블록 모드 패턴(530)은 8x16에 대한 것이다. 좌측 우측 8x16 블록의 경우 CBP는 각각 4 개, 3 개가 1 이므로 8x16 모드는 선택할 수 없다. In FIG. 5, the upper left block mode pattern 510 shows the CBP obtained in the MC process after the end of the ME process for 16 × 16 blocks. Since the CBP has a value of 1 or 0 in 4x4 block units, the CBP may have a value such as the top left corner in a 16x16 large block. CBP equals 0 means that all data values in the DCT-quantization process of the 4x4 block are all zero. Therefore, when CBP is 0, it is not necessary to perform motion estimation (ME) for an additional next block mode. The remaining figures show the CBP distribution for each large block mode. If CBP is less than 1 or 2 in each large block mode, there is no need to perform additional block mode ME. The upper second block mode pattern 520 in FIG. 5 is the CBP distribution for the 16 × 8 block mode. Compared to the 16x16 block mode, 16x8 has only 1 CBP of the top 16x8 block and 0 the rest. Therefore, for the top 16x8, additional mode-specific ME may be unnecessary. The upper right block mode pattern 530 is for 8 × 16. In the case of the left and right 8x16 blocks, 4 and 3 CBPs are 1 respectively, so 8x16 mode cannot be selected.

도 5에서, 좌측 하단 블록 모드 패턴(540)은 8x8 블록 모드에 대한 패턴이 다. 상단 두 개의 8x8블록은 CBP 값이 1이므로 추가적인 ME를 할 필요가 없으나 하단의 경우는 각각 3개, 2개가 1이므로 추가 ME가 필요하다. 하단 두 번째 패턴(550)은 8x4 블록 모드에 관한 것이다. 8x8 보다 작은 블록 모드의 경우에는 CBP가 0일 때만 추가 ME를 하지 않는다고 하면 추가적인 ME를 할 필요가 없는 블록은 단 두 개만 있는 셈이다. 세 번째 블록 모드 패턴(560)은 4x8블록에 관한 것이다. 3개의 4x8 블록이 추가 ME를 할 필요가 없다. 네 번째 블록 모드 패턴(570)은 4x4 블록에 관한 것이다. 16개의 4x4 블록 중 CBP가 0인 9개는 움직임 추정을 할 필요가 없다.In FIG. 5, the lower left block mode pattern 540 is a pattern for an 8 × 8 block mode. The upper two 8x8 blocks do not need additional ME because the CBP value is 1, but the lower two require 3 and 2 respectively so that additional ME is required. Bottom second pattern 550 is for 8x4 block mode. In block mode smaller than 8x8, if you do not perform additional ME only when CBP is zero, there are only two blocks that do not require additional ME. The third block mode pattern 560 relates to a 4x8 block. Three 4x8 blocks do not require additional ME. The fourth block mode pattern 570 relates to a 4x4 block. Nine of 16 4x4 blocks with zero CBP do not need motion estimation.

이러한 정보를 토대로 도 6을 살펴보면 상단 16x8 블록(610)과 우측 하단의 위쪽 4x8 블록(630)은 추가 ME를 할 필요가 없다. 이를 나타낸 것이 두 번째 그림(600)이다. 따라서 좌측 하단 8x8블록(640)과 우측 최하단 4x8블록(650)은 추가 ME를 수행해야 한다. 추가 ME의 결과 8x8블록(640)의 CBP가 모두 1에서 0으로 변했다고 가정하고 4x8 블록(650)은 추가 ME를 수행했음에도 여전히 1이 두 개인 상황이라고 가정하자. 그러면 각 모드별 구성을 다시 묶어 줄 수 있는데 좌측 8x16 모드(660)는 CBP가 1개만 1이므로 이를 선택할 수 있다. 그러면 반대쪽 8x16블록은 상단 8x8블록(670)의 경우는 CBP가 1개만 1이므로 역시 선택가능하며 하단 8x8의 경우 상단 8x4블록(680)은 CBP가 두 개 모두 0이므로 선택되고 하단 8x4블록(690)의 경우에는 ME를 수행했음에도 불구하고 CBP가 모두 1이므로 이 상태에서 추가적인 ME를 수행하지 않는다. Referring to FIG. 6 based on this information, the upper 16x8 block 610 and the upper 4x8 block 630 at the lower right do not need to perform additional ME. This is illustrated in the second picture 600. Therefore, the lower left 8x8 block 640 and the lower right 4x8 block 650 must perform additional ME. As a result of the additional ME, assume that the CBP of the 8x8 block 640 has all changed from 1 to 0, and assume that the 4x8 block 650 still has two 1s even though the additional ME has performed the additional ME. Then, the configuration of each mode can be combined again. The left 8x16 mode 660 can be selected since only one CBP is 1. Then, the opposite 8x16 block is also selectable because only one CBP is 1 for the upper 8x8 block 670, and the upper 8x4 block 680 for the lower 8x8 is selected because both CBPs are 0 and the lower 8x4 block 690 In the case of C, although CBP is all 1, no additional ME is performed in this state.

상술한 바와 같이, 본 발명의 IP-TV를 위한 동영상 부호화기에서 부호 블록 패턴 (CBP; Coded Block Pattern)을 블록간 평균과 분산으로 예측하는 방법 및 그를 이용한 블록의 모드를 결정하는 방법은 동영상 부호화에서 첫 번째 16x16 블록 연산만으로 블록의 모든 모드를 결정할 수 있으므로 모드 결정을 위한 추가적 연산이 필요 없기 때문에 연산량이 획기적으로 감소하고 이에 따라 계산 시간을 획기적으로 줄일 수 있다.As described above, a method of predicting a coded block pattern (CBP) by inter-block average and variance in a video encoder for IP-TV according to the present invention and a method of determining a mode of a block using the same are used in video encoding. Since all the modes of the block can be determined by the first 16x16 block operation alone, there is no need for additional operation to determine the mode, which greatly reduces the amount of computation and thus greatly reduces the computation time.

Claims (5)

16x16화소크기의 매크로블록단위로 움직임 추정을 행하여, 현재 매크로블록 및 대응하는 참조 매크로블록을 결정하는 단계;Performing motion estimation in units of 16 × 16 pixel size macroblocks to determine the current macroblock and the corresponding reference macroblock; 현재 매크로블록 내의 개별 4x4블록과 참조 매크로볼록 내의 대응하는 개별 4x4블록 사이의 평균 및 분산을 계산하는 단계; 및Calculating an average and a variance between individual 4x4 blocks in the current macroblock and corresponding individual 4x4 blocks in the reference macroconvex; And 계산된 평균 및 분산을 이용하여 현재 매크로블록 내의 4x4블록들의 CBP값들을 예측하는 단계를 포함하는 CBP 예측 방법.Predicting CBP values of 4x4 blocks in the current macroblock using the calculated mean and variance. 제1항에 있어서, 상기 평균 및 분산을 계산하는 단계에서,The method of claim 1, wherein in calculating the mean and variance: 상기 평균은, 다음 수학식(수학식 2)The average is the following equation (Equation 2)
Figure 112006033282839-PAT00034
Figure 112006033282839-PAT00034
을 이용하여 계산되며,Is calculated using 상기 분산은, 다음 수학식(수학식 3)The variance is the following equation (Equation 3)
Figure 112006033282839-PAT00035
Figure 112006033282839-PAT00035
을 이용하여 계산되며,Is calculated using 상기 수학식들에서,
Figure 112006033282839-PAT00036
는 단위 4x4 블록에서 시간 t-k, i 번째 열과 j 번째 행에서의 화소 값이며
Figure 112006033282839-PAT00037
Figure 112006033282839-PAT00038
를 통해 예측된 4x4 블록의 i 번째 열과 j 번째 행에서의 화소 값인 CBP 예측 방법.
In the above equations,
Figure 112006033282839-PAT00036
Is the pixel value in the time tk, the i th column and the j th row in the unit 4x4 block
Figure 112006033282839-PAT00037
Is
Figure 112006033282839-PAT00038
The CBP prediction method which is the pixel value in the i th column and the j th row of the 4x4 block predicted through.
제2항에 있어서, 상기 CBP값들을 예측하는 단계는,The method of claim 2, wherein predicting the CBP values comprises: 다음 수학식(수학식 4)Next Equation (Equation 4)
Figure 112006033282839-PAT00039
Figure 112006033282839-PAT00039
를 이용하여 예측CBP값을 계산하는 단계를 포함하며,Calculating a predicted CBP value using 상기 수학식에서
Figure 112006033282839-PAT00040
Figure 112006033282839-PAT00041
이면 1, 그렇지 않으면 0의 값을 갖는 단위 계단 함수이며
Figure 112006033282839-PAT00042
는 CBP 예측을 위해 도입된 파라미터로서 다음 수학식(수학식 6)과 같이 적응적으로 갱신되며,
In the above equation
Figure 112006033282839-PAT00040
Is
Figure 112006033282839-PAT00041
Is a unit step function with a value of 1, otherwise 0
Figure 112006033282839-PAT00042
Is a parameter introduced for CBP prediction, and is adaptively updated as shown in Equation 6 below.
Figure 112006033282839-PAT00043
Figure 112006033282839-PAT00043
여기서
Figure 112006033282839-PAT00044
은 적응 계수로서 0.1에서 0.25 사이의 임의 값이 선택되며 CBP는 블록 모드가 결정된 후 DCT 및 양자화를 거친후 구해지는 실제 CBP 값이며 함수
Figure 112006033282839-PAT00045
Figure 112006033282839-PAT00046
로서 계수
Figure 112006033282839-PAT00047
는 4.6 이상의 임의의 값인 CBP 예측 방법.
here
Figure 112006033282839-PAT00044
Is an adaptation coefficient and a random value between 0.1 and 0.25 is chosen, and CBP is the actual CBP value obtained after DCT and quantization after the block mode is determined.
Figure 112006033282839-PAT00045
Is
Figure 112006033282839-PAT00046
Coefficient as
Figure 112006033282839-PAT00047
Is an arbitrary value of 4.6 or greater.
제1항에 기재된 CBP 예측 방법을 이용하여 예측된 CBP값들을 이용하여 동보상을 위한 블록모드를 결정하기 위한 방법에 있어서,A method for determining a block mode for dynamic compensation using CBP values predicted using the CBP prediction method according to claim 1, 현재 매크로블록의 예측CBP값들에 기초하여, 현재 매크로블록을 구성하는 4x4블록들에 의해 구성가능한 블록모드들 중에서, 추가의 움직임추정이 필요없는 블록모드 및 대응하는 4x4블록들을 결정하는 제1단계;Determining, based on the predicted CBP values of the current macroblock, among the block modes configurable by the 4x4 blocks constituting the current macroblock, a block mode that does not require additional motion estimation and corresponding 4x4 blocks; 추가의 움직임 추정이 필요한 블록모드에 대응하는 4x4블록들에 대해 추가의 움직임추정을 행하는 제2단계;Performing a further motion estimation on 4x4 blocks corresponding to a block mode in which additional motion estimation is needed; 제2단계에서 추가의 움직임 추정이 행해진 4x4블록들에 대해 CBP값들을 예측하는 제3단계; 및A third step of predicting CBP values for 4 × 4 blocks for which additional motion estimation has been performed in a second step; And 제3단계에 의해 얻어진 예측CBP값들을 포함한 현재 매크로블록의 예측CBP값들에 기초하여, 현재 매크로블록을 구성하는 4x4블록들에 의해 구성가능한 블록모드들 중에서, 추가의 움직임추정이 필요없는 블록모드 및 대응하는 4x4블록들을 결정하는 제4단계를 포함하는 블록모드 결정방법.Among the block modes configurable by the 4x4 blocks constituting the current macroblock, based on the prediction CBP values of the current macroblock including the prediction CBP values obtained by the third step, a block mode that does not require additional motion estimation and And a fourth step of determining corresponding 4x4 blocks. 제4항에 있어서, 상기 4x4블록들에 의해 구성가능한 블록모드들은, 16x16블록모드, 16x8블록모드, 8x16블록모드, 8x8블록모드, 8x4블록모드 및 4x8블록모드이며,The method according to claim 4, wherein the block modes configurable by the 4x4 blocks are 16x16 block mode, 16x8 block mode, 8x16 block mode, 8x8 block mode, 8x4 block mode, and 4x8 block mode. 상기 제1단계는 16x16블록모드, 16x8블록모드, 8x16블록모드, 8x8블록모드 , 8x4블록모드 및 4x8블록모드의 각각에 대응하는 4x4블록들의 예측CBP값들 중에서 1의 갯수가 소정 수 이하이면, 당해 블록모드를 추가의 움직임추정이 필요없는 블록모드로 결정하는 단계를 포함하는 블록모드 결정방법.The first step may be performed if the number of 1's is less than or equal to a predetermined number of 4x4 blocks corresponding to each of 16x16 block mode, 16x8 block mode, 8x16 block mode, 8x8 block mode, 8x4 block mode, and 4x8 block mode. Determining a block mode as a block mode that does not require additional motion estimation.
KR1020060042834A 2005-11-10 2006-05-12 An estimation method for CBP and a block mode decision method using estimated CBP on a moving picture encoding system KR100785773B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US11/529,973 US8149918B2 (en) 2005-11-10 2006-09-29 Method of estimating coded block pattern and method of determining block mode using the same for moving picture encoder

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
KR1020050107616 2005-11-10
KR20050107616 2005-11-10

Publications (2)

Publication Number Publication Date
KR20070050335A true KR20070050335A (en) 2007-05-15
KR100785773B1 KR100785773B1 (en) 2007-12-18

Family

ID=38273973

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020060042834A KR100785773B1 (en) 2005-11-10 2006-05-12 An estimation method for CBP and a block mode decision method using estimated CBP on a moving picture encoding system

Country Status (1)

Country Link
KR (1) KR100785773B1 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100845644B1 (en) * 2006-12-14 2008-07-10 한국정보통신대학교 산학협력단 Fast motion mode decision method
WO2012033343A2 (en) * 2010-09-07 2012-03-15 에스케이텔레콤 주식회사 Intra-prediction encoding/decoding apparatus and method for omitting the transmission of prediction mode information using characteristics of reference pixels
KR101337410B1 (en) * 2010-12-23 2013-12-05 한국전자통신연구원 bit-rate control method for a macro-block
US8811474B2 (en) 2010-07-29 2014-08-19 Samsung Electronics Co., Ltd. Encoder and encoding method using coded block pattern estimation

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR0136491B1 (en) * 1994-09-27 1998-11-16 양승택 Apparatus for checking coding block pattern in image codec apparatus
KR100290562B1 (en) * 1999-04-30 2001-05-15 박종섭 Apparatus for calculating minimum macro block variance in system used MPEG-2 macro block
JP2003324731A (en) 2002-04-26 2003-11-14 Sony Corp Encoder, decoder, image processing apparatus, method and program for them

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100845644B1 (en) * 2006-12-14 2008-07-10 한국정보통신대학교 산학협력단 Fast motion mode decision method
US8811474B2 (en) 2010-07-29 2014-08-19 Samsung Electronics Co., Ltd. Encoder and encoding method using coded block pattern estimation
WO2012033343A2 (en) * 2010-09-07 2012-03-15 에스케이텔레콤 주식회사 Intra-prediction encoding/decoding apparatus and method for omitting the transmission of prediction mode information using characteristics of reference pixels
WO2012033343A3 (en) * 2010-09-07 2012-05-31 에스케이텔레콤 주식회사 Intra-prediction encoding/decoding apparatus and method for omitting the transmission of prediction mode information using characteristics of reference pixels
KR101337410B1 (en) * 2010-12-23 2013-12-05 한국전자통신연구원 bit-rate control method for a macro-block

Also Published As

Publication number Publication date
KR100785773B1 (en) 2007-12-18

Similar Documents

Publication Publication Date Title
JP6193432B2 (en) Video coding using large macro blocks
US8149918B2 (en) Method of estimating coded block pattern and method of determining block mode using the same for moving picture encoder
KR101246294B1 (en) Method of and apparatus for video intraprediction encoding/decoding
KR100842558B1 (en) Determining method of block mode, and the apparatus therefor video encoding
KR102024516B1 (en) Image encoding device, image decoding device, image encoding method, image decoding method and recording medium
JP5219089B2 (en) Image data generation method
US20050114093A1 (en) Method and apparatus for motion estimation using variable block size of hierarchy structure
WO2011053655A9 (en) Global motion parameter estimation using block-based motion vectors
WO2006124885A2 (en) Codec for iptv
WO2010135609A1 (en) Adaptive picture type decision for video coding
KR20120051639A (en) Image processing apparatus and method
WO2004030369A1 (en) Real-time video coding/decoding
KR101615643B1 (en) Compression of pictures
JP2006094081A (en) Coding device, coding method, program of coding method, and recording medium with program of coding method recorded thereon
JP2008503177A (en) Method for color difference deblocking
US20120218432A1 (en) Recursive adaptive intra smoothing for video coding
KR100949475B1 (en) Apparatus and method for determining scan pattern, and Apparatus and method for encoding image data using the same, and method for decoding image data using the same
KR100845303B1 (en) Video compressing encoding device based on feed-back structure for a fast encoding and Decision method of optimal mode
KR100905059B1 (en) The method and apparatus for block mode decision using predicted bit generation possibility in video coding
WO2015015436A2 (en) System and method for performing optimal temporal predictive mode decision in h.264 video coding
US8767830B2 (en) Neighbor management module for use in video encoding and methods for use therewith
KR100785773B1 (en) An estimation method for CBP and a block mode decision method using estimated CBP on a moving picture encoding system
Kalva et al. The VC-1 video coding standard
Milicevic et al. H. 264/AVC standard: A proposal for selective intra-and optimized inter-prediction
KR101337410B1 (en) bit-rate control method for a macro-block

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20111129

Year of fee payment: 5

LAPS Lapse due to unpaid annual fee