KR101433169B1 - Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction - Google Patents

Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction Download PDF

Info

Publication number
KR101433169B1
KR101433169B1 KR1020080000576A KR20080000576A KR101433169B1 KR 101433169 B1 KR101433169 B1 KR 101433169B1 KR 1020080000576 A KR1020080000576 A KR 1020080000576A KR 20080000576 A KR20080000576 A KR 20080000576A KR 101433169 B1 KR101433169 B1 KR 101433169B1
Authority
KR
South Korea
Prior art keywords
block
intra
mode
prediction
intra mode
Prior art date
Application number
KR1020080000576A
Other languages
Korean (ko)
Other versions
KR20090074886A (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 KR1020080000576A priority Critical patent/KR101433169B1/en
Publication of KR20090074886A publication Critical patent/KR20090074886A/en
Application granted granted Critical
Publication of KR101433169B1 publication Critical patent/KR101433169B1/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/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/103Selection of coding mode or of prediction mode
    • H04N19/11Selection of coding mode or of prediction mode among a plurality of spatial predictive coding modes
    • 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/124Quantisation
    • 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/129Scanning of coding units, e.g. zig-zag scan of transform coefficients or flexible macroblock ordering [FMO]
    • 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/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/157Assigned coding mode, i.e. the coding mode being predefined or preselected to be further used for selection of another element or parameter
    • H04N19/159Prediction type, e.g. intra-frame, inter-frame or bidirectional frame prediction

Abstract

1. 청구범위에 기재된 발명이 속한 기술분야 1. Technical field to which the invention described in the claims belongs

본 발명은 비디오 코딩에서 인트라 예측 시 보이는 방향성에 따라 인트라 예측을 하고 이 후 가변적 양자화 매트릭스와 스캐닝을 적용하여 성능을 향상시키는 방법 및 장치에 관한 것임.The present invention relates to a method and apparatus for intraprediction according to a visible direction in intra-prediction in video coding, and then improving performance by applying a variable quantization matrix and scanning.

2. 발명이 해결하려고 하는 기술적 과제 2. Technical Challenges to be Solved by the Invention

본 발명에서는 비디오 코딩의 인트라 예측 시, 방향성이 보이는 새로운 인트라 예측방법과 DCT계수 값들의 일정한 패턴을 이용하여 코딩의 성능을 향상토록 하는 양자화와 스캐닝 방법을 제안한다.The present invention proposes a new intraprediction method that shows directionality in intra-prediction of video coding and a quantization and scanning method that improves the coding performance by using a certain pattern of DCT coefficient values.

3. 발명의 해결방법의 요지3. The point of the solution of the invention

본 발명은 비디오 코딩의 인트라 예측 시, 인트라 모드의 방향성이 보이게 되는데 이를 이용하여 높은 예측 성능을 가진 인트라 모드 예측 방법을 적용하며, 이에 따른 방향성이 보이는 인트라 모드에서 DCT계수 값들의 일정한 패턴을 통해 만든 양자화 매트릭스를 이용하여 양자화 한 후, 패턴에 맞는 스캐닝 방법까지 적용하여 코딩 효율을 향상시키는 방법을 포함함.The present invention adopts an intra mode prediction method having a high prediction performance by using the intra mode prediction method in intra-prediction of video coding, and makes use of a constant pattern of DCT coefficient values in an intra mode in which directionality is observed And a method of quantizing using a quantization matrix and then applying a scanning method suitable for the pattern to improve the coding efficiency.

4. 발명의 중요한 용도4. Important Uses of the Invention

본 발명은 영상에 대한 코딩효율 향상에 이용된다.The present invention is used for improving the coding efficiency for an image.

MPEG, 인트라코딩, 인트라 모드, 양자화 매트릭스 MPEG, intra coding, intra mode, quantization matrix

Description

인트라 방향성에 따른 모드 예측 및 양자화 매트릭스와 스캐닝 적용 방법 및 장치{Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction}BACKGROUND OF THE INVENTION 1. Field of the Invention [0001] The present invention relates to a mode prediction method, a mode prediction method, and a quantization matrix,

본 발명은 동영상 코덱에 관한 것으로, 보다 구체적으로 비디오 코딩에서 인트라 예측 시 보이는 방향성에 따라 인트라 예측을 하고 이후 가변적 양자화 매트릭스와 스캐닝을 적용하여 성능을 향상시키는 방법 및 장치에 관한 것이다.The present invention relates to a video codec, and more particularly, to a method and apparatus for enhancing performance by performing intra prediction according to the directionality in intra prediction in video coding and then applying a variable quantization matrix and scanning.

현재 ITU-T(International Telecommunication Union)의 연구그룹인 VCEG(Video Coding Experts Group)에서는 기존의 동영상 국제표준인 MPEG-4 part 10 Advanced Video Coding (AVC; H.264)을 바탕으로 코덱에 좀 더 향상된 코딩 성능을 가진 여러가지 툴 들을 포함 시켜 표준화를 준비하고자 노력하고 있다. The Video Coding Experts Group (VCEG), a research group of the International Telecommunication Union (ITU-T), is now working on the MPEG-4 part 10 Advanced Video Coding (AVC) We are trying to prepare standardization by including various tools with coding ability.

H.264에서는 블록간의 화소상관도를 사용하여 압축률을 향상시키는 화면 내 예측 부호화를 수행한다. 이 때 화면 내 예측 부호화는 인트라 코딩이라 하며 예측 가능한 참조블록을 그림1과 같이 좌측(A), 상단(B), 우측상단(C), 좌측상단(D)의 네가지를 두고 있다. 또한 블록마다 적절한 예측 방향을 선택해서 부호화하며, 복잡한 영상은 4x4화소와 같은 작은 블록단위로 예측하고 평탄한 영상은 16x16화소와 같은 큰 매크로블록 단위로 예측하고 있다.In H.264, intraprediction coding is used to improve the compression ratio by using the pixel correlation between blocks. In this case, intra prediction coding is called intra coding and there are four reference blocks that can be predicted: left (A), upper (B), upper right (C), and upper left (D) In addition, an appropriate prediction direction is selected and encoded for each block, and a complex image is predicted by a small block unit such as a 4x4 pixel, and a flat image is predicted by a large macroblock unit such as a 16x16 pixel.

4x4 화소단위 화면내 예측 부호화에서는 그림 2와 같이 16x16화소를 구성하는 0~15의 블록 순서에 따라 부호화를 수행한다. 예를 들면, 그림 2에 보이는 12번째 블록의 경우 그림 1과 같이 좌측 블록(그림1의 A는 그림 2의 블록 9에 해당)속의 4화소, 상단블록(그림 1의 B는 그림 2의 블록 6에 해당)속의 4화소, 우측상단블록(그림 1의 C는 그림 2의 블록 7에 해당)속의 4화소, 좌측상단블록(그림 1의 D는 그림 2의 블록 3에 해당)속의 1화소를 사용하여 블록내의 4x4화소의 값을 예측부호화 한다. 주변값을 참조하여 부호화하려는 현재 블록의 화소는 디블록킹 필터를 적용하기 전의 화소값을 의미한다.In the 4x4 pixel intra-picture prediction coding, coding is performed according to the block order of 0 to 15 constituting 16x16 pixels as shown in Fig. For example, in the case of the 12th block shown in Fig. 2, 4 pixels in the left block (A in Fig. 1 corresponds to block 9 in Fig. 2) and an upper block (B in Fig. 4 pixels in the upper right block (C in Fig. 1 corresponds to block 7 in Fig. 2), and 1 pixel in the upper left block (D in Fig. 1 corresponds to block 3 in Fig. 2) And predictively encodes the value of 4x4 pixels in the block. The pixel of the current block to be encoded with reference to the surrounding value means the pixel value before applying the deblocking filter.

또, 그림 3의 각 예측방향에 기재된 번호가 예측 모드 번호이고, 예측방향의 발생빈도가 높을수록 작은 번호가 할당된다. 예측 방향은 그림 3의 9가지 예측 방향 중 가장 적절한 예측방향을 4x4화소 블록마다 1개씩 선택하고, 선택된 예측 방향(예측모드)을 4x4화소의 블록단위로 부호화한다. 예측모드 2가 의미하는 평균값은 좌측블록(그림 1의 A화소)의 4화소와 상단블록(그림 1의 B화소)의 4화소, 즉 총 8화소의 평균값을 구해 대상블록의 4x4화소 모두를 예측하는 방법이다. The number described in each prediction direction in Fig. 3 is a prediction mode number, and a smaller number is assigned as the frequency of occurrence of the prediction direction is higher. In the prediction direction, one of the nine prediction directions shown in FIG. 3 is selected for each 4x4 pixel block, and the selected prediction direction (prediction mode) is encoded in units of 4x4 pixels. The average value of the prediction mode 2 is obtained by finding the average value of 4 pixels of the left block (A pixel in FIG. 1) and 4 pixels of the upper block (B pixel of FIG. 1) .

픽처의 좌측 경계에 위치하는 블록과 픽처의 상단경계에 위치하는 블록의 경우 좌측블록과 상단블록이 각각 픽쳐 바깥쪽에 위치하게 된다. 이 경우 픽처경계를 벗어난 블록을 참조할 수 없기 때문에 예측방향의 사용이 제한된다. 예를 들어, 픽처의 최상단 위치의 블록에서는 그림 1의 B또는 C의 화소를 참조하는 모드 0, 모드 3, 모드 4, 모드 5, 모드 6, 모드 7의 예측 방향은 사용할수 없다(모드1, 모드8은 B와 C의 화소를 포함하지 않기 때문에 사용 가능). 예외적으로 모드 2 평균치 예측의 경우, 픽처의 경계를 벗어나지 않는 화소만을 참조해서 평균치를 계산하는 예측을 수행한다. 즉, 픽처의 최상단에 위치하는 블록에서는 좌측블록 4화소 평균치를 예측값으로 하고, 픽처의 좌측경계에 위치하는 블록에서는 상단블록 4화소의 평균치를 예측값으로 한다. In the case of a block located at the left boundary of the picture and a block located at the upper boundary of the picture, the left block and the upper block are located outside the picture, respectively. In this case, the use of the prediction direction is restricted because the block outside the picture boundary can not be referred to. For example, in the block at the top of the picture, the prediction directions of the mode 0, mode 3, mode 4, mode 5, mode 6, and mode 7 referring to the pixel B or C in FIG. 1 can not be used (modes 1, Mode 8 can be used because it does not include pixels of B and C). Exceptionally, in the case of mode 2 average prediction, prediction is performed to calculate an average value referring only to pixels that do not deviate from the boundary of a picture. That is, in the block located at the uppermost end of the picture, the average value of the four pixels of the left block is used as the predicted value, and in the block located at the left boundary of the picture, the average value of the four uppermost blocks is used as the predicted value.

모드 예측 방법은 이웃한 블록의 예측 방향과 상관관계가 높은 점을 이용하여 부호화된 주변 블록의 방향으로부터 현재 블록의 예측 방향을 예측한다. 그림 1의 A블록의 모드와 B블록의 모드를 비교해서 작은 번호의 예측 모드를 현재 블록의 적용할 예측방향의 예측값으로 한다. The mode prediction method predicts the prediction direction of the current block from the direction of the encoded neighboring block using a point having a high correlation with the prediction direction of the neighboring block. The mode of block A in Fig. 1 is compared with the mode of block B, and the small number of prediction modes is used as a prediction value of the prediction direction to be applied to the current block.

16x16화소 단위의 화면내 예측 부호화에서는 4가지 예측 모드(수직예측, 수평예측, 평균치 예측, 평면예측)를 두고 하나를 선택해서 예측부호화 하고 있다. In intra-picture prediction coding of 16x16 pixel units, one of four prediction modes (vertical prediction, horizontal prediction, average prediction, and plane prediction) is selected and predictive coding is performed.

H.264는 화면내 예측 부호화 후에 4x4화소단위의 직교변환을 사용한다. 이전에 쓰이던 8x8화소 단위의 직교변환과 비교하면 다루는 데이터 수가 적교 연산의 유효자리수가 적기 때문에 구현이 용이하다. 또한 화면내 예측과 움직임 보상의 최소 단위가 4x4화소 이기 때문에 직교변환의 4x4화소 단위와 정확히 일치하게 된다. H .264에 도입된 직교변환은 정수단위 연산을 사용한다. 기존의 DCT(Discrete Cosine Transform)에서는 실수 단위의 연산을 사용하였기 때문에 직교변환 이전과 직교변환 이후의 결과가 일치하지 않았다는 문제가 발생하였다. 그러나 H.264는 정수단위 연산을 사용하기 때문에 직교변환 전후의 결과가 완전히 일치한다. 즉, 모든 복호기에서 복호영상이 완전히 일치한다는 것을 의미한다. 또 정수정밀도 직교변환은 소수점이하 계산이 불필요하기 때문에 연산과정에서 적은 비트수만을 필요로 하여 하드웨어로 구현하기 쉽게 된다.H.264 uses 4x4 pixel orthogonal transform after intra prediction coding. Compared with the previous 8x8 pixel orthogonal transform, it is easy to implement because the number of data to be handled is small. In addition, since the minimum unit of intra prediction and motion compensation is 4x4 pixels, it is exactly matched with 4x4 pixel unit of orthogonal transformation. The orthogonal transformation introduced in H.264 uses integer unit operations. In the conventional DCT (Discrete Cosine Transform), since the real number unit operation is used, the result before the orthogonal transformation and the result after the orthogonal transformation are inconsistent. However, since H.264 uses integer unit operations, the results before and after the orthogonal transformation are completely matched. That is, it means that the decoded images are completely matched in all decoders. In addition, the integer precision orthogonal transformation requires only a small number of bits in the calculation process since it is unnecessary to calculate the decimal point.

4x4 DCT(Discrete Cosine Transform)는 다음의 수학식 1과 같이 정의할 수 다. The 4x4 DCT (Discrete Cosine Transform) can be defined as Equation (1).

Figure 112008000346465-pat00001
Figure 112008000346465-pat00001

여기서,

Figure 112008000346465-pat00002
이다.here,
Figure 112008000346465-pat00002
to be.

그리고 이 행렬 곱셈은 수학식 2와 같은 등가의 식으로 인수분해 된다. And this matrix multiplication is factorized into an equivalent equation as shown in equation (2).

Figure 112008000346465-pat00003
Figure 112008000346465-pat00003

여기서,

Figure 112008000346465-pat00004
이다.here,
Figure 112008000346465-pat00004
to be.

E는 스케일링 계수이고 d는 0.5로 근사화된 것이다. 행령 C의 두번째와 네번째 행 그리고 CT 의 두번째와 네번째 열은 2의 계수에 의해 스케일되고, Post-스케일링 행렬 E는 이것을 보상하기 위해 스케일링을 감소시킨다. 이렇게 하여 수학식 3과 같이 4x4 DCT를 근사화시킬 수 있다.E is the scaling factor and d is approximated by 0.5. The second and fourth rows of C and the second and fourth columns of C T are scaled by a factor of 2, and the post-scaling matrix E reduces the scaling to compensate for this. In this way, the 4x4 DCT can be approximated as shown in Equation (3).

Figure 112008000346465-pat00005
Figure 112008000346465-pat00005

DCT 이후 양자화를 하게 되는데 H.264는 스칼라 양자화(예:소수점을 가지는 수를 가장 가까운 정수로 반올림하는 것)를 사용한다. 양자화의 방법은 나눗셈과 부동소수점 연산을 사용하지 않고 post-스케일링 방법을 사용한다. 기본적인 양자화 연산은 수학식 4와 같이 표현할 수 있다. After DCT, quantization is performed. H.264 uses scalar quantization (for example, rounding a decimal number to the nearest integer). The quantization method uses a post-scaling method without using division and floating-point operations. The basic quantization operation can be expressed by Equation (4).

Figure 112008000346465-pat00006
Figure 112008000346465-pat00006

여기서, Yij는 위에서 설명된 변환의 계수이고, Qstep은 양자화 스텝사이즈이고, Zij는 양자화 된 계수이다. Here, Yij is a coefficient of the transformation described above, Qstep is a quantization step size, and Zij is a quantized coefficient.

총 52개의 Qstep 값(표 1)이 H.264에서 지원되며 양자화 파라미터 QP에 의해 지시된다. Qstep는 QP가 6 증가할 때마다 두 배가 된다.A total of 52 Qstep values (Table 1) are supported in H.264 and are indicated by the quantization parameter QP. Qstep doubles every time QP increases by 6.

Figure 112008000346465-pat00007
Figure 112008000346465-pat00007

인코더에서 양자화가 끝나면 스캐닝을 한 후 엔트로피 코딩을 하여 디코더에 전송하게 된다. 각각의 양자화된 변환 계수들의 4x4 블럭은 16개의 요소를 갖는 배열에 지그재그 순서(그림 4)로 배치된다. 16x16 인트라 모드로 인코딩된 매크로블럭에서 각 4x4 휘도 블록의 DC 계수 들이 먼저 스캔되고 이 DC 계수들은 그림 4의 순서로 스캔된 4x4배열을 형성한다. 이 과정을 거치면 각 휘도 블록에 15개의 AC계수들이 남게 되며, 그림 4의 두번째 위치부터 시작하여 스캔하게 된다.When the quantization is completed in the encoder, the signal is subjected to entropy coding after the scanning, and is transmitted to the decoder. A 4x4 block of each quantized transform coefficient is arranged in a zigzag order (Figure 4) in an array with 16 elements. In the 16x16 intra mode macroblock, the DC coefficients of each 4x4 luminance block are scanned first, and these DC coefficients form a 4x4 array scanned in the order of Fig. After this process, 15 AC coefficients remain in each luminance block, and the scan starts from the second position in Fig.

본 발명에서는 비디오 코딩의 인트라 예측 시, 방향성이 보이는 새로운 인트라 예측방법과 DCT 계수 값들의 일정한 패턴을 이용하여 코딩의 성능을 향상토록 하는 양자화와 스캐닝 방법을 제안한다.The present invention proposes a new intraprediction method that shows directionality in intra-prediction of video coding and a quantization and scanning method that improves the coding performance by using a certain pattern of DCT coefficient values.

현재 H.264에서는 인트라 코딩을 할 때 4x4 블록에 대해서 9가지 모드(그림 5)를 두고 있다. 각각의 블록에 9가지 모드 정보를 보낼 때 비트정보를 절약하여 압축률을 높이기 위해서 인트라 모드 예측을 하고 있는데, 예측이 되면 1비트(bit)를 보내고 예측이 되지 않으면 안되는 1비트(bit)와 모드번호 3비트(bit)로 표현하고 있다. Currently, H.264 has nine modes (Figure 5) for 4x4 blocks when performing intra coding. In order to increase the compression rate by saving the bit information when transmitting 9 mode information to each block, intra mode prediction is performed. When prediction is performed, 1 bit (bit) And is represented by 3 bits.

인트라 모드 예측을 하기 위해서 그림 1의 A(좌)블록과 B(상)블록의 모드만을 보고, 작은 번호를 예측 모드라 정하고 있다. 이 때 작은 번호를 예측 하는 이유는 H.264에서는 통계적으로 각각의 인트라 모드 번호가 나올 확률이 높은 순으로 번호를 정렬하여 예측에 사용되도록 했기 때문이다.In order to perform intra mode prediction, only the mode of A (left) block and B (upper) block in Fig. 1 are reported, and a small number is set as a prediction mode. The reason for predicting a small number at this time is that, in H.264, the numbers are arranged in the order of the probability that each intra mode number is statistically statistically used for prediction.

Figure 112008000346465-pat00008
Figure 112008000346465-pat00008

표 2는 각각의 영상 시퀀스 별 인트라 모드가 블록에서 선택되어지는 확률을 표시하고 있다. 하지만 표 2를 보면 여러 영상 시퀀스의 인트라 모드 확률이 각각 다름을 알 수 있게 된다. 이것은 현재 인트라 예측에서 사용 되는 모드 예측 방법의 문제점을 보여주고 있다. Table 2 shows the probability that the intra mode for each video sequence is selected in the block. However, Table 2 shows that the intra mode probabilities of different image sequences are different. This shows the problem of the mode prediction method currently used in intraprediction.

그림 6는 인트라 예측 때 최적의 인트라 모드로 정해진 번호를 화살표로 표시하고 있다. 그림 6를 보면 영상의 경계면(뒷 배경의 경사면, 모자 모양 경계, 사람 얼굴 경계…)에서는 인트라 모드의 방향이 이어지는 현상을 볼 수 있다. 이러한 인트라 모드의 방향성을 보고 예측에 이용 한다면 더 좋은 성능을 기대 할 수가 있다. 즉 그림 1에서의 위치에 해당하는 블록 A(좌), 블록 B(상), 블록 C(우상), 블록 D(좌상)와 더 넓게 주변블록의 모드 번호를 보고 예측을 하게 되면 예측 효율을 더 높일 수 있게 됨을 알 수 있다.Figure 6 shows the arrows with the number assigned to the optimal intra mode for intraprediction. In Fig. 6, we can see the direction of the intra mode in the boundary of the image (the backside slope, the cap shape boundary, the human face boundary ...). If the direction of the intra mode is used for prediction, better performance can be expected. That is, if prediction is performed by looking at the mode number of the block A (left), block B (upper), block C (upper right), block D (upper left) As shown in FIG.

H.264에서는 인트라 예측을 한 후 4x4 DCT(Discrete Cosine Transform)를 하고 있다. 이 때 공간 영역의 화소 값들이 주파수 영역의 계수 값들로 변환되게 되는데, 그림 7을 보면 주파수 영역에서 어떤 패턴들의 주파수가 분포하게 되는지를 알 수 있다. 그림 7의 가장 윗줄은 세로방향의 형태를 띄는 주파수들을 나타내고 있으며, 가장 왼쪽줄은 가로 방향의 형태를 띄는 주파수들을 나타내고 있다. 또한 왼쪽 위는 저주파를 나타내고 오른쪽아래는 고주파를 표현하고 있다.In H.264, 4x4 DCT (Discrete Cosine Transform) is performed after intraprediction. In this case, the pixel values of the spatial domain are transformed into the frequency domain coefficient values. FIG. 7 shows which patterns are distributed in the frequency domain. The uppermost line in Figure 7 shows the frequencies in the vertical direction, and the leftmost line shows the frequencies in the horizontal direction. The upper left shows low frequency and the lower right shows high frequency.

보통 자연 영상에서는 DCT(Discrete Cosine Transform)후에 왼쪽 위 부분인 저주파쪽에 계수 값들이 모이게 된다. 하지만 인트라 예측 후에는 인트라 모드에 따라 일정한 패턴으로 DCT(Discrete Cosine Transform) 계수 값들이 분포함을 생각 할 수 있다. 예를 들어 0번 모드(아래방향)로 인트라 예측이 되어 지게 되면 세로 방향으로 잔여 데이터가 남을 확률이 커지게 됨을 위의 그림 7을 보면서 생각 할 수가 있다. 이와 같이 인트라 예측 후 인트라 모드에 따라 DCT(Discrete Cosine Transform) 계수 값들이 분포하게 되는데, 인트라 모드의 방향성을 이용한 예측을 한 후에는 더욱더 패턴의 형태가 뚜렷하게 된다. 이는 영상에서 경계의 부분이 연속적일 확률이 높으므로 방향성에 따른 인트라 모드 예측에 적응적인 도구가 코덱에 필요함을 알 수 있다.In the natural image, the DCT (Discrete Cosine Transform) is used to collect the coefficient values at the lower left part of the low frequency side. However, after the intra prediction, DCT (Discrete Cosine Transform) coefficient values may be considered to be included in a certain pattern according to the intra mode. For example, if intra prediction is performed in the 0-th mode (downward direction), the probability that the residual data remains in the vertical direction becomes larger. As described above, the DCT (Discrete Cosine Transform) coefficient values are distributed according to the intra mode after the intra prediction. After the prediction using the directionality of the intra mode, the pattern becomes more distinct. This is because the probability that the boundary part of the image is continuous is high, so that it is necessary to use an adaptive tool for the intra mode prediction according to the directionality.

그림 8은 방향성에 따른 인트라 모드 예측을 한 후 DCT(Discrete Cosine Transform) 계수들의 분포를 보여주고 있다. 이것은 일반적인 DCT(Discrete Cosine Transform) 계수들의 패턴과 인트라 모드의 방향에 따라 패턴이 다름을 보여주고 있다. 또한 인트라 모드 예측을 할 때 방향성이 있고 없음에 따라 패턴이 더욱더 선명하게 나타남을 알 수 있다.Figure 8 shows the distribution of DCT (Discrete Cosine Transform) coefficients after intra mode prediction according to directionality. This shows that the pattern is different according to the pattern of general DCT (Discrete Cosine Transform) coefficients and the direction of the intra mode. In addition, when intra mode prediction is performed, it can be seen that the pattern appears more clearly according to the presence or absence of directionality.

현재 H.264는 인트라 예측 후 DCT(Discrete Cosine Transform) 계수 패턴에 대해 효과적으로 성능을 높이는 양자화 방법을 사용하지 않고 있다. Currently, H.264 does not use a quantization method that effectively improves the performance of DCT (Discrete Cosine Transform) coefficient patterns after intraprediction.

또한, 그림 4의 지그재그 스캔은 일반적인 영상에서 DCT(Discrete Cosine Transform) 계수 패턴이 저주파에 집중되는 현상을 이용하여 먼저 스캐닝을 할 수 있도록 하는 방법이다. 이것을 통해 엔트로피 코딩(Entropy coding)에서 성능을 향상시킨다. 하지만 이 것 또한 방향성이 보인 인트라 모드에 대한 DCT 계수들의 패턴에는 적합하지 않아 다른 스캐닝 방법이 필요하다.In addition, the zigzag scan in Fig. 4 is a method of scanning first using a DCT (Discrete Cosine Transform) coefficient pattern concentrated on a low frequency in a general image. This improves performance in entropy coding. However, this is also not suitable for the pattern of DCT coefficients for directional intra mode, and other scanning methods are needed.

비디오 코딩의 인트라 예측 후 방향성이 보이는 인트라 모드에서 DCT계수 값들의 일정한 패턴이 보이게 되는데, 이 때 일정한 패턴에 맞는 양자화 매트릭스를 이용하여 양자화 한 후, 패턴에 맞는 스캐닝 방법까지 적용하여 코딩 효율을 향상시키는 효과가 있다.In the intra mode in which the directionality is predicted after the intra prediction of video coding, a certain pattern of the DCT coefficient values is visible. At this time, quantization is performed using a quantization matrix suitable for a certain pattern, It is effective.

따라서 본 발명에서는 기존의 H.264에서 적용되지 않았던 방향성에 따른 인트라 모드의예측을 사용함으로써 발생되는 인트라 모드별 DCT(Discrete Cosine Transform) 계수의 패턴을 이용하는 적응적 양자화 매트릭스 적용과 스캐닝 방법 및 장치를 제안한다. Therefore, in the present invention, adaptive quantization matrix application and scanning method and apparatus using a pattern of DCT (Discrete Cosine Transform) coefficients for each intra mode, which is generated by using prediction of intra mode according to directionality which is not applied in existing H.264 I suggest.

그림 9는 방향성 인트라 예측 코딩의 전체 블록도를 나타낸다. 인코더는 입 력받은 영상을 보고, 각각의 9가지 인트라 모드 중 방향성 유무를 판단하여 최적의 인트라 모드를 예측 하게 되고 화면내 예측 부호화를 하게 된다. Figure 9 shows an overall block diagram of directional intra prediction coding. The encoder looks at the input image, determines the directionality of each of the nine intra modes, predicts the optimal intra mode, and performs intra prediction encoding.

인트라 예측은 정해진 현재 블록의 인트라 예측 모드와 주변 블록의 인트라 예측 모드를 보고 방향성 유무를 판별하였다. 이 때 주변 블록의 인트라 예측 모드를 보는 방법은 현재 블록의 인트라 모드가 몇 번인지에 따라(예:현재 블록이 0번이면 주변블록은 윗 블록이다) 어떤 주변 블록을 볼지 정하며, 정해진 인트라 예측 모드번호를 봐서 같으면 방향성이 있다고 판단하게 된다. 인트라 예측 과정이 끝난 후에는, 인트라 예측 모드의 방향성이 있는 DCT(Discrete Cosine Transform) 계수와 방향성 없는 DCT(Discrete Cosine Transform) 계수가 상대적으로 분포의 차이를 보이는 점을 이용하여 분포에 맞는 양자화 매트릭스를 적용하여 양자화를 하게 된다. 이 때 인트라 예측 경우에는 DCT(Discrete Cosine Transform) 계수 값이 인트라 예측 모드별로 일정하게 분포하므로 추가적인 정보를 보내지 않고도 적응적인 양자화 매트릭스를 이용 할 수 있게 된다. 양자화 매트릭스는 인코더와 디코더 내에 공유하여 인트라 모드의 방향성에 맞게 알맞은 양자화 매트릭스가 선택되면 이 매트릭스를 양자화 과정에 적용되도록 한다.Intra prediction determines the directionality by referring to the intra prediction mode of the current block and the intra prediction mode of the neighboring block. In this case, the method of viewing the intra-prediction mode of the neighboring block determines how many neighboring blocks are to be viewed according to the intra mode of the current block (e.g., the neighboring block is the upper block if the current block is 0) If you look at the number, you will be judged to have directionality. After the intra prediction process is completed, a directional DCT (Discrete Cosine Transform) coefficient and a non-directional DCT (Discrete Cosine Transform) coefficient in the intraprediction mode are relatively different in distribution, And quantization is performed. In this case, since the DCT (Discrete Cosine Transform) coefficient values are uniformly distributed in the intra prediction mode, an adaptive quantization matrix can be used without sending additional information. The quantization matrix is shared among the encoder and the decoder so that a suitable quantization matrix is selected according to the direction of the intra mode so that the matrix is applied to the quantization process.

양자화 과정이 끝나고 남은 양자화 계수들은 지그재그 스캐닝을 하게 되는데, 인트라 예측 모드의 방향성에 따라 분포되는 패턴을 최대한 이용하여 성능을 올리기 위해서는 계수가 많이 분포 하는 순에서 적게 분포하는 순으로 스캐닝을 하도록 순서를 바꾸게 되면 엔트로피 코딩에서 성능 향상이 있게 된다.After the quantization process, the remaining quantization coefficients are subjected to zigzag scanning. In order to maximize the performance of the patterns distributed according to the direction of the intra-prediction mode, the order of scanning is changed from the order of a large number of coefficients to the order of a small number of coefficients , There is a performance improvement in entropy coding.

그림 10는 Foreman QCIF 시퀀스를 QP 22로 코딩 하였을 때 인트라 예측 모드 가 방향성을 보이는 위치를 보여주고 있다. Fig. 10 shows the intra prediction mode where the Foreman QCIF sequence is coded with QP22.

인트라 예측 모드의 방향성이 보이는 위치를 보면, 현재 블록의 인트라 예측 모드의 화살표를 따라 가고 있는 점을 발견 할 수 있다. 예를 들어 인트라 모드4(오른쪽아래방향 모드)번의 경우에는 그림 1에서의 블록 D(좌상)의 위치에 있는 블록의 모드를 예측하면 좋다는 것을 알 수 있다. It can be seen that the direction in which the direction of the intra prediction mode is seen is along the arrow of the intra prediction mode of the current block. For example, in the case of intra mode 4 (right downward mode), it can be seen that the mode of the block at the position of block D (upper left) in FIG. 1 can be predicted.

이와 같이 영상 시퀀스의 인트라 예측 모드의 분포를 분석한 결과, 인트라 모드 방향성 유무 판별 블록도는 그림 11과 같다. 알고리즘은 다음과 같다.As a result of analyzing the intra-prediction mode distribution of the video sequence, the intra-mode directionality determination block diagram is shown in FIG. The algorithm is as follows.

Step 1) 현재 블록이 인트라 예측 모드 "0"인 경우는 위에 블록의 인트라 예측 모드와 비교를 한다.Step 1) If the current block is the intra prediction mode "0", it is compared with the intra prediction mode of the above block.

Step 2) 위에 블록의 인트라 예측 모드가 "0"이면 방향성이 있고, "0" 이외의 모드는 방향성이 없다고 판단한다.Step 2) If the intra prediction mode of the block is "0 ", it is determined that the direction has the direction, and that the modes other than" 0 "

Figure 112008000346465-pat00009
Figure 112008000346465-pat00009

Step 3) 현재 블록이 인트라 예측 모드 "1"인 경우는 좌측 블록의 인트라 예측 모드와 비교를 한다.Step 3) When the current block is the intra prediction mode "1", it is compared with the intra prediction mode of the left block.

Step 4) 좌측 블록의 인트라 예측 모드가 "1"이면 방향성이 있고, "1" 이외의 모드는 방향성이 없다고 판단한다.Step 4) If the intra prediction mode of the left block is "1 ", it is determined that there is directionality, and that modes other than" 1 "

Figure 112008000346465-pat00010
Figure 112008000346465-pat00010

Step 5) 현재 블록이 인트라 예측 모드 "2"인 경우는 방향성이 없는 DC 모드이므로 인트라 모드의 방향을 찾을 수 없다고 판단한다.Step 5) When the current block is the intra prediction mode "2", it is determined that the direction of the intra mode can not be found because it is the DC mode having no directionality.

Figure 112008000346465-pat00011
Figure 112008000346465-pat00011

Step 6) 현재 블록이 인트라 예측 모드 "3"인 경우는 우상측 블록의 인트라 예측 모드와 비교를 한다.Step 6) When the current block is the intra prediction mode "3", it is compared with the intra prediction mode of the upper right side block.

Step 7) 우상측 블록의 인트라 예측 모드가 "3"이면 방향성이 있고, "3" 이외의 모드는 방향성이 없다고 판단한다.Step 7) If the intra prediction mode of the upper right block is "3 ", it is determined that there is directionality, and that modes other than" 3 "

Figure 112008000346465-pat00012
Figure 112008000346465-pat00012

Step 8) 현재 블록이 인트라 예측 모드 "4"인 경우는 좌상측 블록의 인트라 예측 모드와 비교를 한다.Step 8) When the current block is the intra prediction mode "4", it is compared with the intra prediction mode of the upper left side block.

Step 9) 좌상측에 블록의 인트라 예측 모드가 "4"이면 방향성이 있고, "4" 이외의 모드는 방향성이 없다고 판단한다.Step 9) If the intra prediction mode of the block on the upper left side is "4 ", it is determined that there is directionality, and that modes other than" 4 "

Figure 112008000346465-pat00013
Figure 112008000346465-pat00013

Step 10) 현재 블록이 인트라 예측 모드 "5"인 경우는 위에 블록의 인트라 예측 모드와 비교를 한다.Step 10) If the current block is the intra prediction mode "5", it is compared with the intra prediction mode of the above block.

Step 11) 위에 블록의 인트라 예측 모드가 "5"이면 방향성이 있고, "5" 이외의 모드는 방향성이 없다고 판단한다.Step 11) If the intra-prediction mode of the block is "5 ", it is determined that the direction is present, and the mode other than" 5 "

Figure 112008000346465-pat00014
Figure 112008000346465-pat00014

Step 12) 현재 블록이 인트라 예측 모드 "6"인 경우는 좌측 블록의 인트라 예측 모드와 비교를 한다.Step 12) When the current block is the intra prediction mode "6 ", it is compared with the intra prediction mode of the left block.

Step 13) 좌측 블록의 인트라 예측 모드가 "6"이면 방향성이 있고, "6" 이외의 모드는 방향성이 없다고 판단한다.Step 13) If the intra prediction mode of the left block is "6 ", it is determined that there is directionality, and that modes other than" 6 "

Figure 112008000346465-pat00015
Figure 112008000346465-pat00015

Step 14) 현재 블록이 인트라 예측 모드 "7"인 경우는 위에 블록의 인트라 예측 모드와 비교를 한다.Step 14) If the current block is the intra prediction mode "7", it is compared with the intra prediction mode of the above block.

Step 15) 위에 블록의 인트라 예측 모드가 "7"이면 방향성이 있고, "7" 이외의 모드는 방향성이 없다고 판단한다.Step 15) If the intra prediction mode of the block is "7 ", it is determined that there is directionality, and that modes other than" 7 "

Figure 112008000346465-pat00016
Figure 112008000346465-pat00016

Step 16) 현재 블록이 인트라 예측 모드 "8"인 경우는 좌측 블록의 인트라 예측 모드와 비교를 한다.Step 16) If the current block is the intra prediction mode "8 ", it is compared with the intra prediction mode of the left block.

Step 17) 좌측 블록의 인트라 예측 모드가 "8"이면 방향성이 있고, "8" 이외의 모드는 방향성이 없다고 판단한다.Step 17) If the intra prediction mode of the left block is "8 ", it is determined that there is directionality, and that modes other than" 8 "

Figure 112008000346465-pat00017
Figure 112008000346465-pat00017

방향성 유무가 판별되면 이에 따라 인트라 예측 부분에서는 이전 코덱과는 달리 방향성에 따른 최적의 예측 모드를 정하고 코딩하게 된다. 그리고 방향성 유무는 다음 양자화 매트릭스를 결정하기 위해서 쓰이게 된다.If the presence or absence of the direction is determined, the optimal prediction mode according to the direction is determined and coded in the intra prediction part unlike the previous codec. And directionality is used to determine the next quantization matrix.

<인트라 모드 방향성에 따른 양자화 매트릭스 적용 방법>&Lt; Method of applying quantization matrix according to intramode direction >

앞에서 인트라 모드의 방향성 유무를 알게 된 후 이에 적절한 양자화 매트릭 스를 적용하게 된다. 인트라 모드와 방향성 유무에 따라 각각 가중치가 다른 18개의 매트릭스로 분류가 되는데, 이 중 하나를 선택하여 양자화에 적용하게 된다.After the presence or absence of the directionality of the intra mode is known, an appropriate quantization matrix is applied. It is classified into 18 matrices with different weights according to the intra mode and directionality, and one of them is selected and applied to the quantization.

18개의 매트릭스는 각각 인트라 9개의 예측 모드에 방향성이 있는 것과 없는 것으로 분기되어, DCT 계수 분포의 패턴을 보고 미리 18개의 매트릭스를 만들게 된다. 이 것을 인코더와 디코더가 각각 공유하고 있어 따로 매트릭스나 선택하는 인덱스를 보낼 필요는 없게 된다.Each of the 18 matrices is branched into directional and non-directional prediction modes of the intra nine prediction modes, and 18 matrices are created in advance by looking at the pattern of the DCT coefficient distribution. This is shared by the encoder and the decoder, so there is no need to send a matrix or select indexes separately.

이와 같이 영상 시퀀스의 인트라 예측 모드의 분포를 분석한 결과 , 18개의 매트릭스는 그림 12(예시)와 같이 될 수 있으며, 만드는 알고리즘은 다음과 같다.As a result of analyzing the intra-prediction mode distribution of the video sequence, 18 matrices can be made as shown in FIG. 12 (example), and the algorithm to be created is as follows.

Step 1) 인트라 예측 모드 9가지를 각각의 방향 특성에 따라 0,5,7번과 1,6,8번과 2,3,4번으로 분기한다.Step 1) The intra prediction mode is divided into 0, 5, 7, 1, 6, 8, 2, 3, 4 according to the direction characteristics.

Step 2) 0,5,7번 인트라 예측 모드는 DCT 계수 분포가 블록 위쪽에 편중되므로, 매트릭스 위쪽의 양자화 스케일 값을 왼쪽의 양자화 스케일 값과 비교하여 더 작은 값으로 적용한다.Step 2) In the intraprediction modes 0, 5, and 7, the DCT coefficient distribution is biased toward the upper side of the block. Therefore, the quantization scale value above the matrix is compared with the quantization scale value on the left side.

Step 3) 1,6,8번 인트라 예측 모드는 DCT 계수 분포가 블록 왼쪽에 편중되므로, 매트릭스 왼쪽의 양자화 스케일 값을 위쪽의 양자화 스케일 값과 비교하여 더 작은 값으로 적용한다. Step 3) In the 1, 6, and 8 intraprediction modes, the DCT coefficient distribution is biased to the left of the block, so the quantization scale value on the left of the matrix is compared with the quantization scale value on the upper side.

Step 4) 2,3,4번 인트라 예측 모드는 DCT 계수 분포가 왼쪽과 위쪽에 고르게 분포하면서 비례하게 분포하므로, 매트릭스 내 양자화 스케일 값을 똑같이 적용하도록 한다.Step 4) Since the DCT coefficient distributions are distributed evenly on the left and upper sides in the second, third and fourth intra prediction modes, the quantization scale values in the matrix are equally applied.

Step 5) step(스텝) 2번, 3번과 4번의 과정으로 나뉘어 지는 매트릭스는 세세하게 양자화 스케일 값을 조절하여 인트라 예측 모드의 특성에 따라 각각 9개의 매트릭스가 만들어질 수 있다.Step 5) Step (Step) The matrix divided into the steps 2, 3 and 4 can finely adjust the quantization scale value so that 9 matrices can be respectively generated according to the characteristics of the intra prediction mode.

Step 6) 인트라 예측 모드 번호에 따라 모드 9개의 매트릭스가 만들어 진 후, 각각 인트라 예측 모드마다 2개씩 방향성이 보이는 것과 보이지 않는 것으로 분기된다.Step 6) According to the intra prediction mode number, nine modes are created. Then, two directions are shown for each intra prediction mode.

Step 7) 인트라 예측 모드의 방향성이 보인다면, DCT계수의 분포가 방향성이 안보이는 것보다 상대적으로 뚜렷하게 큰 격차가 있으므로, 매트릭스 안에 양자화 스케일 값의 차이를 방향성이 안보이는 것보다 더 크게 한다.Step 7) If the direction of the intra-prediction mode is seen, the distribution of the DCT coefficients is relatively larger than the directionality is not visible, so that the difference of the quantization scale values in the matrix is larger than that of the non-directional.

Step 8) 인트라 예측 모드의 방향성이 안 보인다면, DCT계수의 분포가 방향성이 보이는 것보다 상대적으로 작은 격차가 있으므로, 매트릭스 안에 양자화 스케일 값의 차이를 방향성이 보이는 것보다 더 작게 한다.Step 8) If the direction of the intra prediction mode is not visible, the distribution of the DCT coefficients is relatively smaller than that of the direction, so that the difference of the quantization scale values in the matrix is smaller than that of the direction.

Step 9) 앞의 모든 과정을 거치게 되면 모두 18개의 매트릭스가 만들어지게 된다.Step 9) After all the above steps, all 18 matrices are created.

양자화 매트릭스가 모두 만들어 지게 되면 인코더와 디코더는 각각 18개의 정해진 양자화 매트릭스를 공유하면서 가지고 있으며, 인트라 예측이 된 후, 인트라 예측 모드와 방향성 유무를 따져 그림 13과 같이 해당 매트릭스를 선택하고 이를 양자화에 사용하도록 하며, 사용된 양자화 매트릭스 인덱스는 다음 스캐닝을 할 때 참고가 되도록 한다.When all of the quantization matrices are created, the encoder and decoder share 18 fixed quantization matrices, and after intra prediction, the corresponding matrix is selected according to the intra prediction mode and directionality as shown in Fig. , And the quantization matrix index used is a reference for the next scanning.

<양자화 매트릭스에 따른 스캔 적용 방법>&Lt; Scanning Application Method According to Quantization Matrix >

양자화 매트릭스가 선택이 되어 인덱스를 받으면, 스캔을 할 때는 이에 알맞은 스캔을 선택하게 된다. 스캔 방법 또한 인코더와 디코더가 공유하고 있어 알맞은 것을 선택한다.When the quantization matrix is selected and the index is received, the scan is selected for the scan. The scan method is also shared by the encoder and the decoder, and the appropriate one is selected.

즉, 스캔 방법은 양자화 매트릭스내의 스케일 값의 작은 순부터 큰순으로 순서를 정해 스캐닝이 되도록 한다. 이로 인해 다음의 VLC(Variable Length Coding)코딩을 할 때 압축 효율을 높일 수 있게 된다. That is, the scanning method sets the order of the scale values in the quantization matrix from the smallest order to the greatest order to be scanned. Therefore, it is possible to increase the compression efficiency when the following Variable Length Coding (VLC) coding is performed.

이와 같이 양자화 매트릭스의 인덱스에 따라, 그림 14(예시)와 같이 될 수 있으며, 스캔을 선택하는 블록도는 그림 15와 같고, 스캔 순서를 정하는 알고리즘은 다음과 같다.As shown in Fig. 14 (example) according to the index of the quantization matrix, the block diagram for selecting the scan is as shown in Fig. 15, and the algorithm for determining the scan order is as follows.

Step 1) 모두 18개의 양자화 매트릭스 중 해당 인덱스를 통해 스캔 방법을 선택하도록 분기 된다.Step 1) All of the 18 quantization matrices are branched to select the scanning method through the corresponding index.

Step 2) 해당 양자화 매트릭스 내 스케일 값을 보고 작은 순부터 큰 순으로 스캐닝을 할 수 있도록 한다.Step 2) View the scale values in the quantization matrix and scan from smallest to largest.

위의 과정에서 알맞은 스캔을 선택하여 스캐닝을 한 후 VLC(Variable Length Coding)코딩을 하여 디코더에 전송하게 된다.In the above process, a proper scan is selected, scanning is performed, and variable length coding (VLC) coding is performed and transmitted to the decoder.

디코더는 그림 16과 같으며, 과정은 인코딩 과정과 반대로 하게 된다. The decoder is shown in Figure 16, and the process is reversed to the encoding process.

즉, 디코더에서 인트라 예측 모드를 알게 되면 이를 통해 방향성을 판별하게 되고, 인트라 예측 모드의 방향성 유무와 인트라 예측 모드 9개를 통해 알맞은 scan을 적용하고, 또 이에 알맞은 양자화 매트릭스를 선택하여 역 양자화를 하게 한다.In other words, when the decoder learns the intra-prediction mode, it determines the directionality and applies the appropriate scan through the intra-prediction mode with nine intra-prediction modes and selects the appropriate quantization matrix to perform inverse quantization do.

[발명의 장치] [Apparatus of the invention]

본 발명에서 동영상 인코더/디코더에 포함되는 인트라 방향성에 따른 모드 예측과 양자화 매트릭스 적용과 스캐닝의 수행부는 그림 17과 같다. 원본 영상을 입력 받아 인트라 예측을 하고 엔트로피 코딩된 비트스트림을 출력으로 한다. 인트라 방향성에 따른 모드 예측과 양자화 매트릭스 적용과 스캐닝의 수행부는 블록 단위로 처리를 수행하는데, "인트라 예측부", "인트라 모드 방향성 유무 판별부", DCT 변환부", "양자화부", "인트라 모드 방향성에 따른 양자화 매트릭스 적용부", "스캐닝부", "양자화 매트릭스에 따른 스캔 적용부", "엔트로피 코딩부"로 구성된다.In the present invention, a mode prediction unit, a quantization matrix application unit, and a scanning unit according to intra directionality included in a moving picture encoder / decoder are shown in FIG. Receives an original image, performs intra prediction, and outputs an entropy-coded bitstream. The mode prediction unit, the quantization matrix application unit, and the scanning unit perform processing on a block-by-block basis. The intra prediction unit, the intra mode directionality determination unit, the DCT conversion unit, the quantization unit, A quantization matrix applying section according to mode direction, a scanning section, a scanning application section according to a quantization matrix, and an entropy coding section.

인트라 예측부에서는 원본 영상을 입력 받아 인트라 예측을 하게 된다. 이때 인트라 모드 방향성 유무 판별부의 방향성에 따라 기존의 코덱보다 더 정확한 예측을 하게된다. 인트라 예측이 끝나면 주파수 공간으로 변호나하는 DCT변환부를 거치게 되며 이 후 양자화부에서 양자화를 하게 된다. 양자화를 할 때는 인트라모드 방 향성에 따른 양자화 매트릭스 적용부에서 방향성을 보고 알맞은 양자화 매트릭스를 선택하여 양자화에서 적용되도록 한다. 스캐닝부에서는 양자화부에서 나온 계수 값들을 양자화 매트릭스에 따른 스캔 적용부에서 정한 스캔 순서에 따라 스캔을 하도록 한다. 마지막으로 엔트로피 코딩부에서는 스캔 된 값들을 엔트로피 코딩하여 비트스트림을 만들게 된다.The intra prediction unit receives the original image and performs intra prediction. At this time, according to the direction of the intra mode direction presence / absence determination unit, more accurate prediction than the existing codec is performed. When the intra prediction is completed, the transformed DCT transformer is transformed into a frequency space. Then, the quantization unit performs quantization. When quantization is performed, the quantization matrix application unit according to the intra mode direction looks at the direction and selects an appropriate quantization matrix to be applied in the quantization. In the scanning unit, the coefficient values derived from the quantization unit are scanned according to the scanning order determined by the scanning application unit according to the quantization matrix. Finally, the entropy coding unit entropy-codes the scanned values to generate a bitstream.

도 1(그림 1)은 H.264의 부호화에서 참조하는 블록의 위치를 보여 준다.Figure 1 (Figure 1) shows the location of blocks referenced in H.264 encoding.

도 2(그림 2)는 4×4 블록의 부호화 순서를 보여 준다.FIG. 2 (FIG. 2) shows the coding sequence of the 4 × 4 block.

도 3(그림 3)은 4×4 블록의 화면내 예측 구조를 보여 준다.FIG. 3 (FIG. 3) shows an intra-picture prediction structure of a 4 × 4 block.

도 4(그림 4)는 4×4 블록을 위한 지그재그 스캔 구조를 보여 준다.FIG. 4 (FIG. 4) shows a zigzag scan structure for a 4 × 4 block.

도 5(그림 5)는 인트라 예측의 9가지 모드를 보여 준다.Fig. 5 (Fig. 5) shows nine modes of intra prediction.

도 6(그림 6)은 인트라 예측 모드의 방향성을 보여 준다.Figure 6 (Figure 6) shows the directionality of the intra prediction mode.

도 7(그림 7)은 DCT 기본 패턴을 보여 준다.Figure 7 (Figure 7) shows the DCT basic pattern.

도 8(그림 8)은 방향성 인트라 모드 예측 후 DCT 계수 분포의 예를 보여 준다.8 shows an example of DCT coefficient distribution after directional intra mode prediction.

도 9(그림 9)는 방향성 인트라 코딩 인코더의 블록도이다.9 is a block diagram of a directional intra-coded encoder.

도 10(그림 10)은 인트라 모드 방향성 판별 위치를 보여 준다.Fig. 10 (Fig. 10) shows the intra mode direction determination position.

도 11(그림 11)은 인트라 모드 방향성 유무 판별 블록도를 보여 준다.Fig. 11 (Fig. 11) shows a block diagram for determining intra mode directionality.

도 12(그림 12)는 양자화 매트릭스의 예시이다.Figure 12 (Figure 12) is an example of a quantization matrix.

도 13(그림 13)은 방향성에 따른 양자화 매트릭스 적용을 보여 준다.Fig. 13 (Fig. 13) shows the application of the quantization matrix according to the directionality.

도 14(그림 14)는 스캔 방법의 예시이다.Fig. 14 (Fig. 14) is an example of a scanning method.

도 15(그림 15)는 양자화 매트릭스에 따른 스캔 방법 적용 블록도이다.FIG. 15 is a block diagram illustrating a scanning method according to a quantization matrix. FIG.

도 16(그림 16)은 방향성 인트라 예측 코딩 디코더의 전체 블록도이다.16 is an overall block diagram of a directional intra prediction coding decoder.

도 17(그림 17)은 인트라 방향성 예측에 따른 양자화 매트릭스 적용과 스캐닝에 대한 장치를 보여 준다.Figure 17 (Figure 17) shows a device for quantization matrix application and scanning according to intra directional prediction.

Claims (7)

비디오 코딩 방법에 있어서,A video coding method comprising: 현재 블록의 인트라 모드와 주변 블록의 인트라 모드에 대한 방향성 유무를 판단하는 단계와;Determining whether an intra mode of a current block and an intra mode of a neighboring block are directional; 판단된 상기 방향성에 기초하여 상기 현재 블록에 대한 최적의 인트라 모드를 설정하는 단계와;Setting an optimal intra mode for the current block based on the determined directionality; 상기 방향성과 상기 최적의 인트라 모드에 기초하여 상기 현재 블록에 대한 양자화 매트릭스를 결정하는 단계와;Determining a quantization matrix for the current block based on the directionality and the optimal intra mode; 상기 양자화 매트릭스 내의 스케일값을 스캐닝하는 단계를 포함하는 것을 특징으로 하는 비디오 코딩 방법.And scanning the scale value in the quantization matrix. 제1항에 있어서,The method according to claim 1, 상기 방향성 유무를 판단하는 단계는,The step of determining the presence or absence of the directionality comprises: 상기 현재 블록의 인트라 모드와, 복수의 주변 블록 중 상기 현재 블록의 인트라 모드에 따라 결정되는 어느 하나의 주변 블록의 인트라 모드의 동일성 여부를 판단하는 단계와;Determining whether the intra mode of the current block and the intra mode of any one of neighboring blocks determined according to the intra mode of the current block among the plurality of neighboring blocks are the same; 상기 현재 블록의 인트라 모드와 상기 주변 블록의 인트라 모드가 동일하면 상기 방향성이 존재하는 것으로 판단하고, 상기 현재 블록의 인트라 모드와 상기 주변 블록의 인트라 모드가 동일하지 않으면 상기 방향성이 존재하지 않는 것으로 판단하는 단계를 포함하는 것을 특징으로 하는 비디오 코딩 방법.If the intra mode of the current block and the intra mode of the neighboring block are the same, it is determined that the directionality exists. If the intra mode of the current block and the intra mode of the neighboring block are not the same, The method comprising the steps &lt; RTI ID = 0.0 &gt; of: &lt; / RTI &gt; 제2항에 있어서,3. The method of claim 2, 상기 복수의 주변 블록은 상기 현재 블록의 좌측에 있는 좌측 블록, 상기 현재 블록의 상측에 있는 상측 블록, 상기 상측 블록의 좌측에 존재하는 우측 모서리 블록, 상기 좌측 블록과 상기 상측 블록 사이에 있는 좌측 모서리 블록을 포함하는 것을 특징으로 하는 비디오 코딩 방법.Wherein the plurality of neighboring blocks include a left block located on the left side of the current block, an upper block located on the upper side of the current block, a right corner block located on the left side of the upper block, a left corner located between the left block and the upper block, Wherein the block includes a block. 제2항에 있어서, 3. The method of claim 2, 상기 양자화 매트릭스를 결정하는 단계는,Wherein determining the quantization matrix comprises: 상기 인트라 모드 별로 상기 방향성 유무에 따라 두 개의 양자화 매트릭스를 설정하는 단계와;Setting two quantization matrices according to the presence or absence of directionality for each intra mode; 상기 방향성 유무에 기초하여 상기 최적의 인트라 모드에 대응하는 양자화 매트릭스를 선택하는 단계를 포함하는 것을 특징으로 하는 비디오 코딩 방법.And selecting a quantization matrix corresponding to the optimal intra mode based on the presence or absence of the direction. 제4항에 있어서,5. The method of claim 4, 상기 인트라 모드는 모두 9개이고, 상기 양자화 매트릭스는 18개로 설정되는 것을 특징으로 하는 비디오 코딩 방법.Wherein the intra modes are all nine, and the quantization matrix is set to eighteen. 제4항에 있어서,5. The method of claim 4, 상기 스캐닝하는 단계는,Wherein the scanning comprises: 상기 선택된 양자화 매트릭스에 따라 인덱스를 부여하는 단계와;Assigning an index according to the selected quantization matrix; 상기 인덱스에 따라 스캔 방법을 선택하는 단계와;Selecting a scanning method according to the index; 상기 스케일값이 작은 값에서부터 큰 값의 순서로 스캔하는 단계를 포함하는 것을 특징으로 하는 비디오 코딩 방법.And scanning the scale value in order from a small value to a large value. 삭제delete
KR1020080000576A 2008-01-03 2008-01-03 Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction KR101433169B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020080000576A KR101433169B1 (en) 2008-01-03 2008-01-03 Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020080000576A KR101433169B1 (en) 2008-01-03 2008-01-03 Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction

Publications (2)

Publication Number Publication Date
KR20090074886A KR20090074886A (en) 2009-07-08
KR101433169B1 true KR101433169B1 (en) 2014-08-28

Family

ID=41332142

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020080000576A KR101433169B1 (en) 2008-01-03 2008-01-03 Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction

Country Status (1)

Country Link
KR (1) KR101433169B1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2011010857A2 (en) * 2009-07-20 2011-01-27 Samsung Electronics Co., Ltd. Method and apparatus for coding and decoding color channels in layered video coding and decoding
AU2012200319B2 (en) * 2012-01-19 2015-11-26 Canon Kabushiki Kaisha Method, apparatus and system for encoding and decoding the significance map for residual coefficients of a transform unit
AU2012200345B2 (en) 2012-01-20 2014-05-01 Canon Kabushiki Kaisha Method, apparatus and system for encoding and decoding the significance map residual coefficients of a transform unit
EP3261349A4 (en) * 2015-02-17 2018-09-12 LG Electronics Inc. Method and device for encoding/decoding video signal by using adaptive scan order
CN113678453A (en) * 2019-04-12 2021-11-19 北京字节跳动网络技术有限公司 Context determination for matrix-based intra prediction
WO2021034161A1 (en) * 2019-08-22 2021-02-25 엘지전자 주식회사 Intra prediction device and method

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20070062146A (en) * 2005-12-12 2007-06-15 삼성전자주식회사 Method and apparatus for intra prediction of image

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20070062146A (en) * 2005-12-12 2007-06-15 삼성전자주식회사 Method and apparatus for intra prediction of image

Also Published As

Publication number Publication date
KR20090074886A (en) 2009-07-08

Similar Documents

Publication Publication Date Title
KR101373819B1 (en) Metohd of decoding intra prediction mode
KR20210131950A (en) Apparatus for decoding a moving picture
KR20190016982A (en) Method and apparatus for encoding intra prediction information
KR100882949B1 (en) Apparatus and method of encoding and decoding using adaptive scanning of DCT coefficients according to the pixel similarity
JP2016165128A (en) Video encoding device
KR20130045148A (en) Method and apparatus for encoding image in intra prediction mode
KR20130131424A (en) Image encoding device and method
KR101433169B1 (en) Mode prediction based on the direction of intra predictive mode, and method and apparatus for applying quantifization matrix and scanning using the mode prediction
WO2014049981A1 (en) Video encoding device, video decoding device, video encoding method and video decoding method
Elyousfi et al. Fast intra prediction algorithm for H. 264/AVC based on quadratic and gradient model
KR20130045151A (en) Method and apparatus for generating reconstruction block
KR101739580B1 (en) Adaptive Scan Apparatus and Method therefor
KR102422711B1 (en) Method for decoding partitioned block in video decoding
KR20130098254A (en) Prediction block generating apparatus
WO2015045301A1 (en) Video encoding device, video encoding method, and video encoding program
WO2014049982A1 (en) Video encoding device, video decoding device, video encoding method and video decoding method
KR20170088318A (en) Method and apparatus for image encoding, and computer-readable medium including encoded bitstream
Choi et al. A Multi-Dimensional Transform for Future Video Coding

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
N231 Notification of change of applicant
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20170725

Year of fee payment: 4

FPAY Annual fee payment

Payment date: 20190625

Year of fee payment: 6