KR20050047871A - Method for fast filtering in moving picture decoding, and apparatus for the same - Google Patents

Method for fast filtering in moving picture decoding, and apparatus for the same Download PDF

Info

Publication number
KR20050047871A
KR20050047871A KR1020030081671A KR20030081671A KR20050047871A KR 20050047871 A KR20050047871 A KR 20050047871A KR 1020030081671 A KR1020030081671 A KR 1020030081671A KR 20030081671 A KR20030081671 A KR 20030081671A KR 20050047871 A KR20050047871 A KR 20050047871A
Authority
KR
South Korea
Prior art keywords
filtering
filter unit
boundary
frame
predetermined value
Prior art date
Application number
KR1020030081671A
Other languages
Korean (ko)
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 KR1020030081671A priority Critical patent/KR20050047871A/en
Publication of KR20050047871A publication Critical patent/KR20050047871A/en

Links

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/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/44Decoders specially adapted therefor, e.g. video decoders which are asymmetric with respect to the encoder
    • 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/593Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving spatial prediction techniques
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/80Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/85Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using pre-processing or post-processing specially adapted for video compression

Abstract

본 발명은 동영상 디코딩에서 화질 개선을 위한 고속 필터링 알고리즘에 관한 것이다.The present invention relates to a fast filtering algorithm for improving image quality in video decoding.

본 발명에 따른 디코더는 프레임을 구성하는 블록간 경계를 필터링하고 필터링된 프레임들을 시간적 필터링을 하는 시간적 필터부를 포함하는 필터부를 포함하는 것을 특징으로 한다. 한편, 종전의 동영상 디코더와 호환할 수 있도록 필터 선택부를 포함하여 구현할 수 있다. 본 발명에 따른 디코딩방법은 프레임을 구성하는 블록간 경계를 필터링하고 필터링된 프레임들을 시간적 필터링을 하는 것을 특징으로 한다.The decoder according to the present invention is characterized by including a filter unit including a temporal filter unit for filtering inter-block boundaries constituting the frame and temporally filtering the filtered frames. On the other hand, it can be implemented including a filter selector to be compatible with the previous video decoder. The decoding method according to the present invention is characterized in that the inter-block boundary constituting the frame is filtered and the filtered frames are temporally filtered.

Description

동영상 디코딩에서 고속 필터링 방법과 이를 위한 장치{METHOD FOR FAST FILTERING IN MOVING PICTURE DECODING, AND APPARATUS FOR THE SAME}High speed filtering method in video decoding and apparatus for it {METHOD FOR FAST FILTERING IN MOVING PICTURE DECODING, AND APPARATUS FOR THE SAME}

본 발명은 동영상 디코딩에서 화질 개선을 위한 고속 필터링 알고리즘에 관한 것이다.The present invention relates to a fast filtering algorithm for improving image quality in video decoding.

최근에 디지털 기술과 더불어 동영상에 관한 기술이 급격히 발전하고 있다. In recent years, along with digital technology, technology for moving pictures has been rapidly developed.

기본적으로 동영상 데이터는 그 양이 방대하여 대용량의 저장매체를 필요로하며 전송시에 넓은 대역폭을 필요로 한다. 예를 들면 640*480의 해상도를 갖는 24 bit 트루컬러의 이미지는 한 프레임당 640*480*24 bit의 용량 다시 말해서 약 7.37Mbit의 데이터가 필요하다. 이를 초당 30 프레임으로 재생되는 동영상이라면 초당 221Mbit의 정보가 필요하며 90분 동안 상영되는 영화를 저장하려면 약 1200G bit의 저장공간을 필요로 한다. 그러므로 동영상을 압축하는 기술은 필수적이며 다양한 압축기법이 이용되고 있다. 동영상 압축의 기본 원리는 프레임간의 비교를 통해 시간적 중복을 제거하고 변환과정에 의해 공간적인 중복을 제거하여 그 데이터 양을 줄인다. 대부분의 동영상 압축 알고리즘에 있어서 프레임간의 시간적 중복을 제거할 때는 높은 압축율을 달성하기 위하여 움직임 벡터를 통한 움직임 보상과정을 거친다.Basically, the amount of video data is huge and requires a large amount of storage media and a large bandwidth in transmission. For example, a 24-bit true-color image with a resolution of 640 * 480 would require a capacity of 640 * 480 * 24 bits per frame, or about 7.37 Mbits of data. If a video is played at 30 frames per second, it needs 221 Mbits of information per second, and about 1200 Gbits of storage space is needed to store a 90-minute movie. Therefore, a technique for compressing a video is essential and various compressor methods are used. The basic principle of video compression is to reduce the amount of data by eliminating temporal redundancy through frame comparison and spatial redundancy by the conversion process. In most video compression algorithms, when the temporal overlap between frames is removed, motion compensation is performed through motion vectors to achieve high compression ratio.

압축과정은 매크로블록과 같은 일정한 단위별로 수행되는데 인위적인 화면 처리에 의한 부자연스러움(Artifacts)이 나타나게 된다. 특히 낮은 비트율로 압축할 때는 이러한 부자연스러움은 더욱 심해지게 된다. 따라서, 동영상 디코딩 과정에서는 이러한 부자연스러움을 개선하기 위한 필터링 과정을 거치는 것이 바람직한다. 필터링은 인코딩과 디코딩에 각각 사용되는 루프 필터(Loop Filter)와 디코딩에서만 사용되는 후처리 필터로 나눌 수 있다.The compression process is performed by a certain unit such as a macroblock, and the artifacts caused by artificial screen processing appear. Especially when compressed at low bit rates, this unnaturalness is exacerbated. Therefore, in the video decoding process, it is desirable to go through a filtering process to improve the unnaturalness. Filtering can be divided into a loop filter used for encoding and decoding, and a post-processing filter used only for decoding.

H.264와 같은 블록기반의 동영상 알고리즘에 있어서는 루프필터를 사용하고 있으며 필터링 과정은 크게 블록화 현상 검색과정과 필터링 과정으로 나눌 수 있다. 블록화 현상 검색과정은 각 블록의 코딩 형태에 따라 블록화 정도가 다르게 표현되는데 블록화 정도에 따라 "경계 세기(Boundary Strength)" 값인 Bs가 할당된다.In block-based video algorithms such as H.264, loop filters are used, and the filtering process can be largely divided into the blocking phenomenon searching process and the filtering process. In the blocking phenomenon retrieval process, the degree of blocking is expressed differently according to the coding type of each block, and Bs, which is a "Boundary Strength" value, is allocated according to the degree of blocking.

도 1은 H.264 동영상 디코딩 과정에서 필터링될 매크로블록의 경계를 보여주는 도면이다. 도면에서 실선은 루마(Luma)의 경계를 나타내고 점선은 크로마(Chroma)의 경계를 나타낸다. 이웃하는 4*4 루마 블록 사이의 각 경계에 대하여 Bs가 할당된다. 경계 세기에 따라 다른 형태의 필터링이 수행되는데, 이 때 사용되는 필터는 양자화 파라메터 등 코딩 정보를 이용한 적응 필터를 사용한다.1 illustrates a boundary of a macroblock to be filtered in the H.264 video decoding process. In the drawing, the solid line represents the border of Luma and the dotted line represents the border of Chroma. Bs is assigned to each boundary between neighboring 4 * 4 luma blocks. Different types of filtering are performed according to the boundary strength. In this case, an adaptive filter using coding information such as a quantization parameter is used.

경계 세기를 결정하는 과정은 도 2를 통해 설명한다. 경계 세기를 결정하기 위하여 먼저 블록 p 및 q 사이의 경계를 입력받는다. 블록 p 또는 q가 인트라 코딩되었고 그 경계가 매크로블록의 경계인 경우에 Bs는 4가 된다. 블록 p 또는 q가 인트라 코딩되었으나 그 경계가 매크로블록의 경계가 아닌 경우에 Bs는 3이 된다. The process of determining the boundary strength will be described with reference to FIG. 2. In order to determine the boundary strength, a boundary between blocks p and q is first input. If block p or q is intra coded and its boundary is the boundary of the macroblock, then Bs is 4. If block p or q is intra coded but its boundary is not the boundary of the macroblock, then Bs is 3.

한편, 블록 p와 q가 모두 인트라 코딩되지 않은 경우에는 블록 p 또는 q 안에 0이 아닌 변환계수가 포함된 경우에 Bs는 2가 된다. 그렇지 않은 경우에는 p의 샘플들의 예측이 q의 샘플들의 예측과 다른 참조 픽쳐들 또는 참조 픽쳐들의 다른 숫자를 사용하는 경우이거나 p와 q의 움직임 벡터의 x성분 또는 y성분의 차이가 1픽셀보다 크거나 같은 경우에는 Bs는 1이 되고, 그 외의 경우에 Bs는 0이 된다.On the other hand, when both blocks p and q are not intra coded, Bs becomes 2 when a non-zero transform coefficient is included in the block p or q. Otherwise, the prediction of samples of p uses a different number of reference pictures or reference pictures than the prediction of samples of q, or the difference between the x and y components of the motion vector of p and q is greater than 1 pixel. Or Bs equals 1 in all other cases and Bs equals 0 in other cases.

도 3은 4*4 블록의 수평 또는 수직 경계를 가로지른 샘플들을 설명하기 위한 도면이다. 그림과 같이 수평 또는 수직으로 인접된 4*4 블록내의 4개 화소로 구성된 값을 각각 p={p3, p2, p1, p0}, q={q0, q1, q2, q3}라고 할 때, 도 2를 통해 설명한 Bs의 내용은 다음과 같이 요약할 수 있다. 즉, Bs가 4인 것은 p와 q가 인트라 코딩 되었고 p와 q의 경계는 매크로블록의 경계다. Bs가 3인 것은 p와 q는 인트라 코딩되었으나 p와 q의 경계는 매크로 블록의 경계가 아니다. Bs가 2인 것은 p와 q가 인터 코딩되었고 p 또는 q에 코딩된 변환 계수가 존재한다. Bs가 1인 것은 p와 q가 인터 코딩되었고, p와 q에 코딩된 변환 계수가 존재하지 않으며, p 및 q의 움직임 벡터 참조 프레임이 다른 경우이다. 마지막으로 Bs가 0인 것은 위 네 가지에 해당하지 않는 경우이다.FIG. 3 is a diagram for explaining samples across a horizontal or vertical boundary of a 4 * 4 block. As shown in the figure, a value consisting of four pixels in a horizontally or vertically adjacent 4 * 4 block is p = {p3, p2, p1, p0} and q = {q0, q1, q2, q3}, respectively. The contents of Bs described through 2 can be summarized as follows. That is, for Bs 4, p and q are intra coded, and the boundary between p and q is a macroblock boundary. When Bs is 3, p and q are intra coded, but the boundary between p and q is not the boundary of the macro block. For Bs 2, p and q are inter coded and there are transform coefficients coded in p or q. Bs is 1 when p and q are inter coded, there are no transform coefficients coded in p and q, and the motion vector reference frames of p and q are different. Finally, Bs equals zero does not correspond to the above four.

필터링 과정은 Bs의 크기에 따라 다른 형태의 필터링 과정을 거치는데 블록 경계 영역의 화소간의 차이 및 블록 내부의 화소간의 차이 값에 따라 4가지 모드로 구분할 수 있다. 모드 1은 Bs가 0인 경우로서 필터링 과정을 수행하지 않는다. The filtering process undergoes a different filtering process according to the size of Bs. The filtering process can be classified into four modes according to the difference between the pixels in the block boundary region and the difference between the pixels in the block. Mode 1 is a case where Bs is 0 and does not perform a filtering process.

모드 2는 Bs가 0이 아닌 경우로서 p0와 q0의 차이가 α보다 작고 p1과 q0의 차이 및 p0와 q1의 차이가 모두 β보다 작은 경우에 블록 경계 영역에 있는 화소 p0와 q0만을 필터링 시킨다. 모드 3은 Bs가 4보다 작은 경우로서 최대 4개의 화소(p1, p0, q0, q1)를 필터링 시킨다. 마지막으로 모드 4는 Bs가 4인 경우로서 최대 6개의 화소(p2, p1, p0, q0, q1, q2)를 필터링 시킨다. α와 β는 다음과 같은 표 1에 기술된 바와 같이 양자화 크기에 따라 설정된 임계치를 나타낸다.Mode 2 filters only the pixels p0 and q0 in the block boundary region when Bs is not 0 and the difference between p0 and q0 is smaller than α, and the difference between p1 and q0 and the difference between p0 and q1 is smaller than β. Mode 3 is a case where Bs is less than 4, and filters up to four pixels p1, p0, q0 and q1. Finally, mode 4 is a case where Bs is 4 and filters up to six pixels (p2, p1, p0, q0, q1, q2). α and β represent thresholds set according to quantization magnitudes as described in Table 1 below.

QPavQPav 7 이하7 or less 88 99 1010 1111 1212 1313 1414 1515 1616 1717 1818 1919 2020 2121 2222 αα 00 44 44 55 66 77 99 1010 1212 1414 1717 2020 2424 2828 3333 3939 ββ 00 33 33 33 44 44 44 66 66 77 77 88 88 99 99 1010 QPavQPav 2323 2424 2525 2626 2727 2828 2929 3030 3131 3232 3333 3434 3535 3636 3737 3838 3939 αα 4646 5555 6565 7676 9090 106106 126126 148148 175175 207207 245245 255255 255255 255255 255255 255255 255255 ββ 1010 1111 1111 1212 1212 1313 1313 1414 1414 1515 1515 1616 1616 1717 1717 1818 1818

모드 1은 블록화 현상이 존재하지 않는 영역으로 판단하므로 필터링 과정을 수행하지 않고, 모드 2는 p0와 q0 값 만을 처리하며, 모드 3은 기본 모드(Default Mode)이며 특정 조건에 따라 최대 4개의 화소 또는 2개의 화소를 처리하도록 되어 있다. 한편, 모드 4는 블록화 현상이 상당히 존재하는 영역으로 판별되어 특정 조건에 따라 최대 6개의 화소 또는 최소 2개의 화소를 처리하도록 되어 있으며, 필터 계수도 표 1과는 다르게 설정되어 있다. 필터 계수를 참조하여 모드마다 정해진 공식에 따라 필터링을 수행한다.Since mode 1 determines that the blocking phenomenon does not exist, the filtering process is not performed, and mode 2 processes only p0 and q0 values, and mode 3 is a default mode, and according to a specific condition, up to four pixels or It is supposed to process two pixels. On the other hand, mode 4 is determined to be a region where the blocking phenomenon considerably exists to process up to six pixels or at least two pixels according to a specific condition, and the filter coefficients are set differently from those in Table 1. Filtering is performed according to a formula determined for each mode by referring to the filter coefficients.

이러한 과정에 의해 화질은 개선되지만 과도한 연산량을 필요로 한다는 점에서 문제가 있다. 즉, 디코딩과정에서 이러한 필터링 과정을 수행하는 디블록 필터가 전체 프로세싱 시간의 20~30%를 차지할 정도로 연산량이 많다. 하드웨어로 이러한 디블록 필터를 구현하는 경우에 매크로블록 단위로 필터링을 수행하므로 병렬처리를 할 수가 없게 된다. 한편, 조건 판단에 따라 서로 다른 필터링을 하므로 필터링 과정이 복잡하게 된다. 또한 압축 손실 현상의 하나인 출렁임 현상(Ringing Artifact 또는 Flickering)의 경우에는 시간적 중복성을 제거하는 과정에서 나타나는 것으로서 상기와 같은 필터링의 경우로는 해결할 수 없는 문제점을 갖는다.This process improves image quality, but has a problem in that it requires an excessive amount of computation. In other words, the deblocking filter that performs this filtering process in the decoding process has a large amount of calculation so that it takes 20 to 30% of the total processing time. In case of implementing such a deblock filter in hardware, since the filtering is performed in units of macroblocks, parallel processing cannot be performed. Meanwhile, the filtering process becomes complicated because different filtering is performed according to the condition determination. In addition, the ringing phenomenon (ringing artifact or flickering), which is one of compression loss phenomenon, appears in the process of eliminating temporal redundancy and has a problem that cannot be solved by the above filtering.

상술한 이유에 따라 동영상 디코딩에 있어 적은 계산량을 갖는 고속 필터링 메커니즘이 필요하다.For the above reasons, there is a need for a fast filtering mechanism with a small amount of computation in video decoding.

본 발명은 상술한 필요성에 의해 안출된 것으로서, 고속 필터링 과정을 갖는 동영상 디코딩 방법과 이를 위한 장치를 제공하는 것을 그 기술적 과제로 한다.SUMMARY OF THE INVENTION The present invention has been made in view of the above-described necessity, and a technical object of the present invention is to provide a video decoding method having a fast filtering process and an apparatus therefor.

또한, 출렁임 현상을 제거할 수 있는 방법과 이를 위한 장치를 제공하는 것을 다른 기술적 과제로 한다.In addition, it is another technical problem to provide a method and an apparatus for eliminating the slump phenomenon.

상기 목적을 달성하기 위하여, 본 발명에 따른 블록기반의 동영상 알고리즘으로 엔코딩된 이미지를 디코딩하는 디코더는 프레임을 구성하는 블록간 수평 및 수직 경계를 필터링하고 필터링된 프레임들을 시간적 필터링을 하는 필터부를 포함하는 것을 특징으로 한다.In order to achieve the above object, the decoder for decoding an image encoded by the block-based video algorithm according to the present invention includes a filter unit for filtering the horizontal and vertical boundaries between blocks constituting the frame and temporally filtered the filtered frames. It is characterized by.

상기 필터부는 두 블록의 경계를 중심으로 블록길이만큼의 픽셀들의 값을 보정하여 필터링하는 공간적 필터부, 및 상기 공간적 필터부에 필터링된 프레임들의 소정의 부분에 대하여 중간값 필터링을 수행하는 시간적 필터부를 포함한다.The filter unit is a spatial filter unit for correcting and filtering the values of the pixels by the block length around the boundary of the two blocks, and the temporal filter unit for performing the intermediate value filtering for a predetermined portion of the frames filtered by the spatial filter unit Include.

상기 공간적 필터부는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 블록간의 경계에 대해서 블록간 경계 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 블록길이만큼의 픽셀들을 필터링하는 한다. 상기 시간적 필터부는 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링한다.The spatial filter unit filters pixels corresponding to the block length when the difference between the block-to-block boundary pixel values is smaller than a predetermined value with respect to the boundary between blocks having a motion vector of a refiner unit of an intra-coded frame. The temporal filter unit filters the macroblocks of the preceding and following frames corresponding to the macroblocks with respect to macroblocks coded with a macroblock type, whose motion vector is smaller than a predetermined value, and whose quantization coefficient is smaller than a predetermined value. .

상기 목적을 달성하기 위하여, 본 발명에 따른 H.264 디코더는 루프필터부와 후처리필터부를 포함하며 상기 루프필터부 또는 후처리필터부 중 어느 하나를 선택할 수 있도록 하는 필터 선택부를 포함하는 것을 특징으로 한다.In order to achieve the above object, the H.264 decoder according to the present invention includes a loop filter unit and a post-processing filter unit and includes a filter selection unit to select any one of the loop filter unit and the post-processing filter unit. It is done.

상기 후처리필터부는 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 필터링하도록 구현할 수 있다. 이 때, 상기 후처리필터부는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 서브 블록간의 경계에 대해서 상기 두 서브블록의 경계에 맞닿은 2개의 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 4개의 픽셀 값들의 분포된 형태에 따라 상기 4개의 픽셀 값들을 보정하는 것이 바람직하다.The post-processing filter may be configured to filter the horizontal or vertical boundary between the sub-blocks constituting the frame by correcting four pixel values based on the horizontal or vertical boundary of the two sub-blocks. In this case, the post-processing filter unit may set the value of 4 when the difference between two pixel values abutting the boundary of the two subblocks with respect to the boundary between the subblocks having the motion vector of the refiner unit of the intra-coded frame is smaller than a predetermined value. It is preferable to correct the four pixel values according to the distributed form of the pixel values.

한편, 상기 후처리필터부는 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 공간적 필터링하고 상기 공간적 필터링된 프레임들에 대하여 시간적 필터링을 수행하도록 구현할 수 있다. 상기 후처리필터부가 수행하는 시간적 필터링은 상기 공간적 필터링된 프레임 중에서 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링한다. Meanwhile, the post-processing filter unit performs spatial filtering by correcting values of four pixels based on horizontal or vertical boundaries of the two subblocks in filtering horizontal or vertical boundaries between subblocks constituting the frame. Can be implemented to perform temporal filtering on these components. The temporal filtering performed by the post-processing filter unit corresponds to the macroblock for macroblocks coded in a macroblock type among the spatially filtered frames and whose motion vectors are smaller than a predetermined value and whose quantization coefficient is smaller than a predetermined value. Filter the macroblocks and the median of the before and after frames.

상기 목적을 달성하기 위하여, 본 발명에 따른 블록기반의 동영상 알고리즘으로 엔코딩된 이미지를 디코딩하는 동영상 디코딩 방법은 프레임을 구성하는 블록간 수평 및 수직 경계를 필터링하고 필터링된 프레임들을 시간적 필터링을 하는 단계를 포함하는 것을 특징으로 한다.In order to achieve the above object, a video decoding method for decoding an image encoded by the block-based video algorithm according to the present invention includes filtering horizontal and vertical boundaries between blocks constituting a frame and temporally filtering the filtered frames. It is characterized by including.

상기 단계는 두 블록의 경계를 중심으로 블록길이만큼의 픽셀들의 값을 보정하여 필터링하는 공간적 필터링 단계, 및 상기 공간적 필터부에 필터링된 프레임들의 소정의 부분에 대하여 중간값 필터링을 수행하는 시간적 필터링 단계를 포함한다.The step may include: a spatial filtering step of correcting and filtering values of pixels by a block length around a boundary of two blocks; and a temporal filtering step of performing intermediate value filtering on a predetermined portion of frames filtered by the spatial filter unit. It includes.

상기 공간적 필터링 단계는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 블록간의 경계에 대해서 블록간 경계 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 블록길이만큼의 픽셀들을 필터링한다.The spatial filtering step filters the pixels of the block length when the difference in the inter-block boundary pixel value is smaller than a predetermined value with respect to the boundary between blocks having a motion vector of a refiner unit of an intra coded frame.

상기 시간적 필터링 단계는 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링한다.The temporal filtering step is to filter the macroblocks and the intermediate value of the preceding and following frames corresponding to the macroblocks for the macroblocks coded with the macroblock type, the motion vector is smaller than the predetermined value, and the quantization coefficient is smaller than the predetermined value. do.

상기 목적을 달성하기 위하여, 본 발명에 따른 H.264 디코딩 방법은 디코딩된 이미지를 루프필터링하는 루프필터링 단계 또는 디코딩된 이미지를 후처리하는 후처리필터링 단계 중 어느 하나를 선택할 수 있는 것을 특징으로 한다.In order to achieve the above object, the H.264 decoding method according to the present invention is characterized in that it can select any one of a loop filtering step of loop filtering the decoded image or a post-processing filtering step of post-processing the decoded image. .

상기 후처리필터링 단계는 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 필터링하도록 구현할 수 있다. 이 때 상기 후처리필터링 단계는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 서브 블록간의 경계에 대해서 상기 두 서브블록의 경계에 맞닿은 2개의 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 4개의 픽셀 값들의 분포된 형태에 따라 상기 4개의 픽셀 값들을 보정하는 것이 바람직하다.The post-processing filtering step may be implemented to correct and filter values of four pixels around the horizontal or vertical boundary of the two sub-blocks in filtering the horizontal or vertical boundary between the sub-blocks constituting the frame. In this case, the post-processing filtering step may be performed when the difference between two pixel values that are in contact with the boundary of the two subblocks is smaller than a predetermined value with respect to the boundary between the subblocks having the motion vector of the refiner unit of the intra-coded frame. It is preferable to correct the four pixel values according to the distributed form of the pixel values.

상기 후처리필터링 단계는 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 공간적 필터링하고 상기 공간적 필터링된 프레임들에 대하여 시간적 필터링을 수행하도록 구현할 수 있다. 상기 시간적 필터링은 상기 공간적 필터링된 프레임 중에서 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링을 한다.In the post-processing filtering step, in filtering horizontal or vertical boundaries between sub-blocks constituting a frame, spatial filtering is performed by correcting values of four pixels around the horizontal or vertical boundaries of the two sub-blocks. It can be implemented to perform temporal filtering for. The temporal filtering is a macroblock of a front and back frame corresponding to the macroblock for macroblocks coded in a macroblock type among the spatially filtered frames and whose motion vectors are smaller than a predetermined value and whose quantization coefficient is smaller than a predetermined value. And median filtering.

이하, 첨부된 도면을 참조하여 본 발명의 바람직한 실시예를 상세히 설명한다. 동일한 부분에 대해서는 동일한 참조번호를 부여한다.Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings. Like reference numerals refer to like parts.

도 4는 본 발명의 일 실시예에 따른 H.264 디코더의 기능성 블록도이다.4 is a functional block diagram of an H.264 decoder according to an embodiment of the present invention.

H.264의 디코더는 H.264의 엔코더에 의해 엔코딩된 비디오 이미지를 복원한다. 먼저 디코딩 과정을 살펴보면, 엔트로피 디코딩을 수행하고, 재순서화와, 역양자화 및 역변환을 거쳐 이미지를 복원한다. 복원된 이미지는 루프필터에 의해 블록화에 의한 부자연스러움을 제거한다. 움직임 보상은 움직임 벡터를 이용하여 인터 예측된 복수의 참조프레임들에게 적용되나, 인트라 예측된 프레임에 대해서는 움직임 보상 과정을 거치지 않는다. H.264의 엔트로피 코딩방식은 CABAC(Context-based Adaptive Binary Arithmetic Coding) 방식을 이용하여 확률적 중복을 제거하고 변환은 정수변환을 이용하여 공간적 중복을 제거하는 것을 특징으로 하고 움직임 보상은 1/4 픽셀까지 수행한다. 본 발명은 H.264의 루프필터와 같이 필터링과정을 거치는 동영상 디코딩에 있어서 필터링 과정을 개선하는 것을 특징으로 한다. The decoder of H.264 reconstructs the video image encoded by the H.264 encoder. First, the decoding process is performed by performing entropy decoding, and reconstructing the image through reordering, inverse quantization, and inverse transformation. The reconstructed image removes the unnaturalness due to blocking by the loop filter. Motion compensation is applied to a plurality of reference frames that are inter predicted using the motion vector, but does not undergo a motion compensation process for the intra predicted frame. H.264's entropy coding method uses CABAC (Context-based Adaptive Binary Arithmetic Coding) to remove probabilistic redundancy, and transform uses spatial transformation to remove spatial redundancy and motion compensation is 1/4. Perform up to pixels. The present invention is characterized in that the filtering process is improved in video decoding through a filtering process like the H.264 loop filter.

한편, 본 발명의 상세한 설명에서는 H.264를 기준으로 실시예를 설명하고 있으나, 본 발명의 기술적 사상은 이에 한정되지 않는다. 도 4에서 본 발명에 의해 개선되는 부분은 필터부(100)이고 필터부의 보다 자세한 구조에 대해서는 도 5a, 5b, 5c를 통해 설명한다.Meanwhile, in the detailed description of the present invention, an embodiment is described based on H.264, but the technical spirit of the present invention is not limited thereto. The part improved by the present invention in FIG. 4 is the filter part 100, and the detailed structure of the filter part will be described with reference to FIGS. 5A, 5B and 5C.

도 5a, 5b, 5c는 각각 도 4의 필터부를 보다 상세히 보여주는 기능성 블록도이다.5A, 5B, and 5C are functional block diagrams showing the filter part of FIG. 4 in more detail, respectively.

필터부(100)는 기존의 디코딩 과정과 호환되도록 구현하는 것이 바람직하다. The filter unit 100 may be implemented to be compatible with an existing decoding process.

도 5a의 필터부(100)는 필터 선택부(110)를 통해 기존의 디코더에 존재하는 필터와 본 발명에 의해 새로 제공되는 필터를 선택할 수 있도록 하고 있다. 즉, 필터 선택부(110)는 사용자의 세팅 등에 의해 본 발명에 의해 새로 제공된 공간 및 시간적 필터부(120)와 H.264 필터부(130) 중 어느 하나를 선택할 수 있도록 하며, 도 5a는 공간 및 시간적 필터부(120)가 선택된 것을 보여주고 있다. 필터부(100)부에 입력되는 이미지는 공간 및 시간적 필터부(120)를 통해 필터링되어 출력된다.The filter unit 100 of FIG. 5A allows the filter selector 110 to select a filter existing in an existing decoder and a filter newly provided by the present invention. That is, the filter selector 110 may select one of the space and the temporal filter 120 and the H.264 filter 130 newly provided by the present invention by the user's setting or the like, and FIG. 5A shows the space. And the temporal filter unit 120 is selected. The image input to the filter unit 100 is filtered and output through the spatial and temporal filter unit 120.

도 5b의 필터부(100)는 도 5a와 마찬가지로 기존의 H.264 필터부(130)을 사용할 수 있도록 하고 있다. H.264 필터부(130)의 경우에 블록화에 따른 부자연스러움을 제거할 뿐이고 시간적인 출렁임에 대해서는 필터링을 할 수 없기 때문에 도 5b에 도시된 실시예는 H.264 필터부(130)를 통과한 이미지의 시간적 출렁임을 줄이기 위한 시간적 필터부(150)를 제공한다. 한편, 필터 선택부(110)에 의해 도시된 바와같이 공간적 필터부(140)가 선택된 경우에는 공간적 필터부(140)를 통해 이미지의 블록화에 따른 부자연스러움을 줄이고 시간적 필터부(150)를 통해 시간적 출렁임을 제거할 수 있다.The filter unit 100 of FIG. 5B allows the existing H.264 filter unit 130 to be used as in FIG. 5A. In the case of the H.264 filter unit 130, only the unnaturalness due to the block is removed and the filtering cannot be performed on temporal fluctuations. Thus, the embodiment illustrated in FIG. 5B passes through the H.264 filter unit 130. A temporal filter unit 150 is provided to reduce temporal blurring of an image. Meanwhile, when the spatial filter unit 140 is selected as shown by the filter selecting unit 110, the spatial filter unit 140 reduces the unnaturalness due to the blocking of the image and temporally through the temporal filter unit 150. You can get rid of slack.

도 5c의 필터부(100)는 블록화에 따른 부자연스러움은 기존의 H.264 필터부(130)를 이용하도록 하고 H.264 필터부(130)를 통해 필터링된 이미지의 시간적 출렁임을 줄이도록 시간적 필터부(160)를 통해 시간적 출렁임을 제거한 이미지를 출력한다.The filter unit 100 of FIG. 5C uses the existing H.264 filter unit 130 to reduce the unnaturalness due to the block, and reduces the temporal rung of the image filtered through the H.264 filter unit 130. The unit 160 outputs an image from which temporal rung is removed.

도 5a 내지 도 5c는 모두 기존의 디코더 표준을 만족시키도록 구현되었으며, 기존의 디코더가 수행할 수 없었던 시간적 필터링을 수행할 수 있다. 이 중에서 도 5a 또는 도 5b의 경우에는 엔코딩 과정에서 루프필터를 통과하여 디코딩 과정에서도 루프필터를 필요로 하는 경우에는 H.264 필터부(130)를 사용하도록 하고 그 외의 경우에는 본 발명에 따라 계산량을 획기적으로 줄일 수 있는 공간적 필터링을 수행하여 블록화에 따른 부자연스러움을 제거할 수 있다. 한편, 도 5a 내지 5c는 모두 시간적 출렁임을 제거할 수 있다. 블록화에 따른 부자연스러움을 줄이는 과정에 대한 바람직한 실시예는 도 6a와 6b를 통해 설명하고, 시간적 출렁임을 줄이는 과정은 도 7과 도 8을 통해 설명한다.5A to 5C are all implemented to satisfy the existing decoder standard, and may perform temporal filtering that the conventional decoder could not perform. In the case of FIG. 5A or 5B, the H.264 filter unit 130 is used when the loop filter is required in the encoding process and the loop filter is required in the decoding process. Spatial filtering can be performed to significantly reduce the unnaturalness caused by blocking. On the other hand, Figures 5a to 5c can all eliminate the temporal haze. A preferred embodiment of the process of reducing unnaturalness due to blocking will be described with reference to FIGS. 6A and 6B, and a process of reducing temporal rung will be described with reference to FIGS. 7 and 8.

도 6a는 공간적 필터링의 대상이 되는 인접된 4*4 서브블록들 사이의 샘플들을 보여주고 있으며, 도 6b는 바람직한 실시예에 따라 구분된 공간적 필터링의 케이스를 보여준다.6A shows samples between adjacent 4 * 4 subblocks subject to spatial filtering, and FIG. 6B shows a case of spatial filtering separated according to a preferred embodiment.

도 6a에서는 수평 방향으로 인접한 두 개의 4*4 서브블록을 보여주고 있다. FIG. 6A shows two 4 * 4 subblocks adjacent in the horizontal direction.

두 서브블록의 경계를 기준으로 최대 4개의 픽셀을 기준으로 필터링을 하여 서브블록들간의 필터링이 서로 겹치는 것을 방지하여 필터링 과정을 병렬처리할 수 있도록 한 것이 특징이다. 한편, 8*8 블록을 단위로 움직임 벡터를 구하여 동영상을 압축하는 알고리즘에 의한 이미지를 필터링하는 경우라면 최대 8개의 픽셀을 기준으로 필터링할 때 블록들간의 필터링이 서로 겹치지 않게 되고 따라서 필터링 과정을 병렬로 처리할 수 있게 된다. 즉, 두 블록의 경계에 대해 필터링할 때는 블록길이 만큼의 픽셀들을 기준으로 필터링하는 것이 바람직하다. 본 발명의 바람직한 실시에에 있어서 계산량을 줄이기 위해 인트라 코딩된 프레임에서만 블록화에 따른 부자연스러움을 줄이는 것이 바람직하다. 왜냐하면 인터 프레임의 경우에는 이전 프레임의 영상에서 예측을 구하게 되는데, 이 때 보간과정(Interpolation)을 수행하게 되기 때문이다. H.264의 움직임 보상은 1/4 픽셀까지 수행되므로 1/2 픽셀과 1/4 픽셀에 대해서도 필터링을 한다. 1/2 픽셀에 대해서는 (1, -5, 20, 20, -5, 1)의 6 탭 필터를 사용하고 1/4 픽셀의 경우에는 1/2 픽셀의 평균을 구하여 사용한다. 따라서, 움직임 보상을 하기 위해 만든 참조 영상이 이미 필터링 과정을 수행하게 되므로 정화소 단위의 움직임 벡터가 아니라면 블록화의 부자연스러움을 줄이는 디블록 필터링 과정이 필요없게 된다. 이하에서는 공간적 필터링(디블록 필터링)에 대해 설명한다. 필터링은 가로방향과 세로방향으로 수행되는데, 가로방향과 세로방향의 필터링은 거의 유사하게 수행되므로 실시예에서는 가로방향에 대해서만 설명한다. 필터링은 우선 필터링을 수행할지 여부를 판단하는 단계와 실제 필터링을 하는 단계로 나눌 수 있다. 도 6a를 참고하면 필터링을 수행할지 여부는 B, C 픽실 값의 차이와 양자화 값을 가지고 결정한다. 즉 B와 C의 차이가 일정한 기준값(Threshold)보다 작은 경우라면 필터링을 수행하고 그렇지 않은 경우에는 필터링을 수행하지 않는다. 필터링 수행여부를 결정하는 기준은 표 2를 참조한다.The filtering is performed based on a boundary of two subblocks based on a maximum of four pixels to prevent overlapping filtering between subblocks so that the filtering process can be parallelized. On the other hand, if the image is filtered by an algorithm that compresses a video by obtaining a motion vector based on 8 * 8 blocks, filtering between blocks does not overlap each other when filtering based on a maximum of 8 pixels, and thus the filtering process is parallel. Can be processed as That is, when filtering on the boundary of two blocks, it is preferable to filter based on the pixels of the block length. In a preferred embodiment of the present invention, it is desirable to reduce unnaturalness due to blocking only in intra-coded frames in order to reduce the amount of computation. In the case of an inter frame, prediction is obtained from an image of a previous frame, because interpolation is performed at this time. Since H.264's motion compensation is performed up to 1/4 pixel, it also filters 1/2 and 1/4 pixels. For a half-pixel, use a six-tap filter of (1, -5, 20, 20, -5, 1), and for a quarter-pixel, use the average of half-pixels. Therefore, since the reference image made for motion compensation has already performed the filtering process, the deblocking filtering process that reduces the unnaturalness of the blocking is not necessary unless the motion vector of the refinery unit is used. Hereinafter, spatial filtering (deblocking filtering) will be described. The filtering is performed in the horizontal direction and the vertical direction. Since the filtering in the horizontal direction and the vertical direction is performed almost similarly, only the horizontal direction will be described in the embodiment. The filtering may be divided into a step of determining whether to perform filtering first and a step of performing actual filtering. Referring to FIG. 6A, whether to perform filtering is determined based on a difference between B and C pixel values and a quantization value. That is, if the difference between B and C is smaller than a certain threshold, filtering is performed. Otherwise, filtering is not performed. See Table 2 for the criteria for determining whether to perform filtering.

QP(양자화값)QP (quantization value) 1~191-19 20~2520-25 26~3126-31 32~3632-36 37~4437-44 45~5045-50 기준값Reference value 필터링 수행 안함Do not perform filtering 55 1010 2020 4040 5050

두 픽셀 B와 C의 차이가 기준값보다 작은 경우에 필터링을 수행하는 이유는 두 픽셀의 차이가 큰 경우에 이는 블록화에 의한 차이라기보다는 원래 이미지에서의 차이로 판단할 수 있고 이러한 경우에는 필터링을 수행하지 않는 것이 합당하기 때문이다. 한편, 디블록 필터링은 블록화에 따른 부자연스러움을 줄이는 과정이므로 일종의 저역통과 필터와 같은 기능을 수행하므로 필터의 특성은 수학식 1로 모델링할 수 있다.When the difference between two pixels B and C is smaller than the reference value, the reason for performing filtering is that when the difference between two pixels is large, it can be judged as the difference in the original image rather than the difference due to blocking, and in this case, the filtering is performed. It is proper not to do it. On the other hand, since deblocking filtering is a process of reducing unnaturalness due to blocking, it performs a function as a kind of lowpass filter, so that the characteristics of the filter can be modeled by Equation 1.

그러나, 수학식 1을 이용하여 디블록 필터링을 계산하는 것보다는 연산량을 줄이기 위해 수학식 1을 근사화해서 사용한다. 도 6b는 디블록 필터링이 4가지 경우를 보여준다. 4가지의 케이스는 픽셀 C의 값이 픽셀 B의 값보다 큰 경우를 가정하여 보여주고 있으며, 픽셀 C의 값이 픽셀 B의 값보다 작은 경우에도 마찬가지로 생각할 수 있다. However, rather than calculating deblocking filtering using Equation 1, Equation 1 is approximated to reduce the amount of computation. 6B shows four cases of deblocking filtering. The four cases show the case where the value of pixel C is larger than the value of pixel B, and the same can be considered when the value of pixel C is smaller than the value of pixel B.

먼저 케이스 1 내지 케이스 4는 각각 수학식 2 내지 수학식 5로 근사화할 수 있다.First, cases 1 to 4 may be approximated by Equations 2 to 5, respectively.

A'=A+(D-A)/16, B'=B+(D-A)/4, C'=C-(D-A)/4, D'=D-(D-A)/16A '= A + (D-A) / 16, B' = B + (D-A) / 4, C '= C- (D-A) / 4, D' = D- (D-A) / 16

A'=A, B'=A+(D-A)/4, C'=D-(D-A)/4, D'=DA '= A, B' = A + (D-A) / 4, C '= D- (D-A) / 4, D' = D

A'=A+(D-A)/16, B'=B+(D-A)/4, C'=D-(D-A)/4, D'=DA '= A + (D-A) / 16, B' = B + (D-A) / 4, C '= D- (D-A) / 4, D' = D

A'=A, B'=A+(D-A)/4, C'=C-(D-A)/4, D'=D-(D-A)/16A '= A, B' = A + (D-A) / 4, C '= C- (D-A) / 4, D' = D- (D-A) / 16

여기서, A', B', C', D'는 각각 필터링된 후의 각 픽셀들의 값을 의미하고, A, B, C, D는 각각 필터링 전의 각 픽셀들의 값을 의미한다.Here, A ', B', C ', and D' denote values of respective pixels after filtering, and A, B, C, and D denote values of respective pixels before filtering.

수학식 2를 참조하여 케이스 1을 살펴보면 A, B, C, D 순서로 값이 커지고 있는 상태이다. B와 C의 격차를 줄이면서 블록화를 감소시키는데 이로 인하여 A와 D도 각각 B와 C와 격차가 더 벌어지게 된다. 이를 완화시키기 위하여 A도 B의 경우보다는 작지만 약간이나마 값을 증가시키고 D도 C의 경우보다 작지만 약간이나마 값을 감소시킨다. 이렇게 함으로써 전체적으로 부드럽게 연결되도록 한다. 수학식 2에서 경계에 있는 B와 C의 보정정도는 A와 D의 보정정도와 4배 차이나도록 하였다.Referring to Case 1 with reference to Equation 2, the values are increasing in the order of A, B, C, and D. As the gap between B and C is reduced, blocking is reduced, which causes A and D to be wider with B and C, respectively. To alleviate this, A is smaller than B but increases slightly, while D is smaller than C but slightly lower. This ensures a smooth overall connection. In Equation 2, the correction degree of B and C at the boundary is four times the correction degree of A and D.

수학식 3을 참조하여 케이스 2를 살펴보면 A와 D는 중심에서 크게 떨어지지 않았으므로 이 경우에는 값을 그대로 두고 B와 C를 보정한다. 이 때 B와 C는 각각 이들간의 중심에서 가까운 A와 D를 기준 값으로 해서 보정을 한다.Referring to Case 2 with reference to Equation 3, A and D are not significantly separated from the center, so in this case, the values are left as they are and B and C are corrected. At this time, B and C are corrected by using A and D close to their centers as reference values, respectively.

수학식 4를 참조하여 케이스 3을 살펴보면 D의 경우에는 중심에서 가까운 값을 가지므로 그대로 두고 나머지 A, B, C 값을 보정한다. A와 B 값은 케이스 1의 경우와 마찬가지로 보정하면되고 C의 경우에는 케이스 2의 경우와 마찬가지로 보정한다.Referring to Case 3 with reference to Equation 4, since D has a value close to the center, it is left as it is and the remaining A, B, and C values are corrected. A and B values are corrected as in case 1, and in C, as in case 2.

수학식 5를 참조하여 케이스 4를 살펴보면 A와 B는 케이스 2와 같이 처리하고 C와 D는 케이스 1과 같이 처리한다.Referring to Case 4 with reference to Equation 5, A and B are treated like Case 2 and C and D are processed as Case 1.

만일 B의 값이 C의 값보다 큰 경우에도 상기 케이스 1 내지 케이스 4의 경우와 마찬가지 방법으로 디블록 필터링을 수행할 수 있다. 디블록 필터링이 끝나면 시간적인 출렁임(Flickering)을 줄이기 위한 시간적 필터링을 한다. 시간적인 출렁임 현상은 배경 영역에서 나타날 때 눈에 잘 띄고 이는 영상의 화질을 떨어뜨리는 효과를 낳는다. 따라서 영상이 배경 영역인지 아니면 움직임이 영역인지를 판단할 부분이 필요하다. 일반적인 움직임 검출은 연속적인 2개의 프레임 사이의 차이에 기반을 두고 있다. 연속 프레임간의 차이는 움직임이나 노이즈가 있을 때 나타난다. 움직임을 검출하기 위하여 필립스에서 제안한 방법은 두장의 연속 프레임의 차를 구하고 저역통과 필터를 2회 통과 시킨다. 이러한 움직임 검출방법은 많은 계산량을 필요로 하기 때문에 본 발명의 실시예에서는 움직임벡터와 블록 타입을 이용하여 검출하며 움직임 검출을 통해 시간적 필터링을 하는 과정은 도 7과 도 8을 통해 설명한다. If the value of B is larger than the value of C, deblocking filtering may be performed in the same manner as in Cases 1 to 4. After deblocking filtering, temporal filtering is performed to reduce temporal flickering. Temporal wobble is noticeable when appearing in the background area, which results in a deterioration of the image quality. Therefore, it is necessary to determine whether the image is a background area or a motion area. Typical motion detection is based on the difference between two consecutive frames. Differences between successive frames appear when there is motion or noise. To detect motion, Philips's method finds the difference between two consecutive frames and passes the lowpass filter twice. Since such a motion detection method requires a large amount of computation, a process of detecting using a motion vector and a block type and performing temporal filtering through motion detection will be described with reference to FIGS. 7 and 8.

도 7은 움직임 보상을 거친 차분영상의 일 예를 보여주는 도면이다.7 is a diagram illustrating an example of a differential image that undergoes motion compensation.

도 7의 영상은 움직임 보상을 한 후에 영상간의 차를 구한 차분영상을 표시한 것이다. 도시된 바와 같이 배경 영상은 16*16의 매크로블록으로 되어 있고 차분 영상의 크기도 매우 작다는 것을 알 수 있다. 즉, 배경부분은 움직임의 단위가 되는 블록의 크기가 큰 것을 알 수 있으며, 차분 영상의 값은 매우 작은 값을 갖는 특성을 갖는다. 따라서, 가장 큰 블록 타입이며 움직임 벡터 값이 일정한 기준 값보다 작으면 이에 대해 시간적 필터링을 수행한다. H.264 영상의 경우라면 16*16 매크로 블록 타입이면서 움직임 벡터 값이 3보다 작으며, 양자화 계수가 10 이내의 것으로 제한하는 것이 바람직하다. 이러한 조건을 만족한다면 시간적 필터링을 수행하며 이 때 사용하는 것은 중간값 필터(Median Filter)를 사용한다.The image of FIG. 7 shows a difference image obtained by obtaining a difference between images after motion compensation. As shown, it can be seen that the background image is made of 16 * 16 macroblocks and the size of the difference image is very small. That is, it can be seen that the background part has a large block size that is a unit of motion, and the difference image has a very small value. Therefore, if the largest block type and the motion vector value is smaller than a predetermined reference value, the temporal filtering is performed. In the case of an H.264 image, it is preferable to limit the quantization coefficient to a 16 * 16 macroblock type with a motion vector less than 3 and a quantization coefficient of 10 or less. If this condition is satisfied, temporal filtering is performed. The median filter is used here.

도 8은 본 발명의 일 실시예에 따른 시간적 필터링의 대상이 되는 인접한 프레임들을 보여주는 도면이다. 도 8에 도시된 바와같이 상기 시간적 필터링 조건을 만족하는 매크로블록에 대한 시간적 필터링은 세 프레임간의 중간 값으로 결정한다.8 is a diagram illustrating adjacent frames that are subjected to temporal filtering according to an embodiment of the present invention. As shown in FIG. 8, temporal filtering for a macroblock satisfying the temporal filtering condition is determined as an intermediate value between three frames.

본 발명이 속하는 기술분야의 통상의 지식을 가진 자는 본 발명이 그 기술적 사상이나 필수적인 특징을 변경하지 않고서 다른 구체적인 형태로 실시될 수 있다는 것을 이해할 수 있을 것이다. 예컨대, H.264를 중심으로 실시예를 설명하였으나, 다른 동영상 압축 알고리즘을 사용한 영상에 대한 디코딩에 대해서도 본 발명을 적용할 수 있다. 그러므로 이상에서 기술한 실시예들은 모든 면에서 예시적인 것이며 한정적이 아닌 것으로 이해해야만 한다. 본 발명의 범위는 상기 상세한 설명보다는 후술하는 특허청구의 범위에 의하여 나타내어지며, 특허청구의 범위의 의미 및 범위 그리고 그 균등 개념으로부터 도출되는 모든 변경 또는 변형된 형태가 본 발명의 범위에 포함되는 것으로 해석되어야 한다.Those skilled in the art will appreciate that the present invention can be embodied in other specific forms without changing the technical spirit or essential features of the present invention. For example, although an embodiment has been described based on H.264, the present invention can also be applied to decoding of an image using another video compression algorithm. Therefore, it should be understood that the embodiments described above are exemplary in all respects and not restrictive. The scope of the present invention is indicated by the scope of the following claims rather than the detailed description, and all changes or modifications derived from the meaning and scope of the claims and the equivalent concept are included in the scope of the present invention. Should be interpreted.

본 발명은 적은 계산량으로 블록화에 따른 부자연스러움을 제거할 수 있는 필터를 제공한다. 상기 필터는 기존의 디코딩 방법과 함께 사용할 수 있는 특징을 갖는다. 한편, 본 발명에 따르면 공간적 필터링을 수행하는 디블록 필터와 더불어 시간적 필터링을 수행하는 시간적 필터를 함께 사용할 수 있으므로 본 발명에 따르면 동영상의 시간적 출렁임 현상(Flickering)을 줄일 수 있는 장점을 갖는다.The present invention provides a filter capable of removing unnaturalness due to blocking with a small amount of calculation. The filter has a feature that can be used with a conventional decoding method. Meanwhile, according to the present invention, since the temporal filter for temporal filtering may be used together with the deblocking filter for performing spatial filtering, the present invention has an advantage of reducing temporal flickering of the video.

도 1은 필터링될 매크로블록의 경계를 보여주는 도면이다.1 shows a boundary of a macroblock to be filtered.

도 2는 종전의 기술에 따른 블록화 크기를 결정하는 과정을 보여주는 도면이다.2 is a diagram illustrating a process of determining a block size according to a conventional technique.

도 3은 수평 또는 수직방향으로 인접된 4*4 서브 블록내의 샘플들을 보여주는 도면이다.3 shows samples in adjacent 4 * 4 subblocks in a horizontal or vertical direction.

도 4는 본 발명의 일 실시예에 따른 H.264 디코더의 기능성 블록도이다.4 is a functional block diagram of an H.264 decoder according to an embodiment of the present invention.

도 5a, 5b, 5c는 각각 도 4의 필터부를 보다 상세히 보여주는 기능성 블록도이다.5A, 5B, and 5C are functional block diagrams showing the filter part of FIG. 4 in more detail, respectively.

도 6a는 본 발명의 일 실시예에 따른 공간적 필터링의 대상이 되는 인접된 4*4 서브블록들 사이의 샘플들을 보여주는 도면이다.FIG. 6A illustrates samples between adjacent 4 * 4 subblocks subject to spatial filtering according to an embodiment of the present invention.

도 6b는 본 발명의 일 실시예에 따른 공간적 필터링의 케이스를 보여주는 도면이다.6B illustrates a case of spatial filtering according to an embodiment of the present invention.

도 7은 움직임 보상을 거친 차분영상의 일 예를 보여주는 도면이다.7 is a diagram illustrating an example of a differential image that undergoes motion compensation.

도 8은 본 발명의 일 실시예에 따른 시간적 필터링의 대상이 되는 인접한 프레임들을 보여주는 도면이다.8 is a diagram illustrating adjacent frames that are subjected to temporal filtering according to an embodiment of the present invention.

Claims (18)

블록기반의 동영상 알고리즘으로 엔코딩된 이미지를 디코딩하는 디코더에 있어서,A decoder for decoding an image encoded with a block-based video algorithm, 프레임을 구성하는 블록간 수평 및 수직 경계를 필터링하고, 필터링된 프레임들을 시간적 필터링을 하는 필터부를 포함하는 것을 특징으로 하는 동영상 디코더A video decoder comprising a filter unit for filtering horizontal and vertical boundaries between blocks constituting a frame and temporally filtering the filtered frames. 제1항에 있어서, 상기 필터부는The method of claim 1, wherein the filter unit 두 블록의 경계를 중심으로 블록길이만큼의 픽셀들의 값을 보정하여 필터링하는 공간적 필터부; 및A spatial filter unit for correcting and filtering values of pixels corresponding to block lengths based on a boundary between two blocks; And 상기 공간적 필터부에 필터링된 프레임들의 소정의 부분에 대하여 중간값 필터링을 수행하는 시간적 필터부; 를 포함하는 것을 특징으로 하는 동영상 디코더A temporal filter unit performing intermediate value filtering on a predetermined portion of the frames filtered by the spatial filter unit; Video decoder comprising a 제2항에 있어서, 상기 공간적 필터부는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 블록간의 경계에 대해서 블록간 경계 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 블록길이만큼의 픽셀들을 필터링하는 것을 특징으로 하는 동영상 디코더3. The pixel filter of claim 2, wherein the spatial filter filters the pixels of the block length when the difference between the block-to-block boundary pixel values is smaller than a predetermined value with respect to the boundary between blocks having a motion vector of a refiner unit of an intra-coded frame. Video decoder, characterized in that 제2항에 있어서, 상기 시간적 필터부는 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링을 하는 것을 특징으로 하는 동영상 디코더The macroblock of claim 2, wherein the temporal filter unit is coded in a macroblock type, the motion vector is smaller than a predetermined value, and the quantization coefficient is smaller than the predetermined value. Video decoder characterized in that the median filtering with 엔코딩된 이미지를 디코딩하는 H.264 디코더에 있어서,A H.264 decoder for decoding an encoded image, 상기 디코딩된 이미지를 필터링하는 루프필터부와 후처리필터부를 포함하며 상기 루프필터부 또는 후처리필터부 중 어느 하나를 선택할 수 있도록 하는 필터 선택부를 포함하는 것을 특징으로 하는 H.264 디코더An H.264 decoder comprising a loop filter unit and a post-processing filter unit for filtering the decoded image, and a filter selection unit for selecting one of the loop filter unit and the post-processing filter unit. 제5항에 있어서, 상기 후처리필터부는The method of claim 5, wherein the post-processing filter unit 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 필터링하는 것을 특징으로 하는 H.264 디코더In filtering horizontal or vertical boundaries between sub-blocks constituting a frame, the H.264 decoder is characterized by correcting and filtering four pixel values based on the horizontal or vertical boundaries of the two sub-blocks. 제6항에 있어서, 상기 후처리필터부는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 서브 블록간의 경계에 대해서 상기 두 서브블록의 경계에 맞닿은 2개의 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 4개의 픽셀 값들의 분포된 형태에 따라 상기 4개의 픽셀 값들을 보정하는 것을 특징으로 하는 H.264 디코더7. The method of claim 6, wherein the post-processing filter unit is less than a predetermined value when a difference between two pixel values in contact with the boundary of the two subblocks with respect to the boundary between the subblocks having the motion vector of the refiner unit of the intra-coded frame is less than a predetermined value. H.264 decoder, characterized in that for correcting the four pixel values in accordance with the distributed form of the four pixel values in 제5항에 있어서, 상기 후처리필터부는 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 공간적 필터링하고 상기 공간적 필터링된 프레임들에 대하여 시간적 필터링을 수행하는 것을 특징으로 하는 H.264 디코더6. The method of claim 5, wherein the post-processing filter unit filters the horizontal or vertical boundaries between the sub-blocks constituting the frame, and spatially filters the four pixels by correcting values of the four pixels around the horizontal or vertical boundaries of the two sub-blocks. H.264 decoder characterized by performing temporal filtering on spatially filtered frames 제8항에 있어서, 상기 후처리필터부가 수행하는 시간적 필터링은 상기 공간적 필터링된 프레임 중에서 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링을 하는 것은 특징으로 하는 H.264 디코더The method of claim 8, wherein the temporal filtering performed by the post-processing filter is performed on macroblocks of the spatially filtered frame, coded in a macroblock type, having a motion vector smaller than a predetermined value, and having a quantization coefficient smaller than a predetermined value. H.264 decoder characterized in that the intermediate value filtering with the macroblocks of the front and back frames corresponding to the macroblocks. 블록기반의 동영상 알고리즘으로 엔코딩된 이미지를 디코딩하는 동영상 디코딩 방법에 있어서,In the video decoding method for decoding an image encoded with a block-based video algorithm, 프레임을 구성하는 블록간 수평 및 수직 경계를 필터링하고, 필터링된 프레임들을 시간적 필터링을 하는 단계를 포함하는 것을 특징으로 하는 동영상 디코딩 방법Filtering horizontal and vertical boundaries between blocks constituting the frame, and temporally filtering the filtered frames. 제10항에 있어서, 상기 단계는 두 블록의 경계를 중심으로 블록길이만큼의 픽셀들의 값을 보정하여 필터링하는 공간적 필터링 단계; 및11. The method of claim 10, wherein the step comprises: a spatial filtering step of correcting and filtering values of pixels by a block length around a boundary of two blocks; And 상기 공간적 필터부에 필터링된 프레임들의 소정의 부분에 대하여 중간값 필터링을 수행하는 시간적 필터링 단계; 를 포함하는 것을 특징으로 하는 동영상 디코딩 방법A temporal filtering step of performing intermediate value filtering on a predetermined portion of the frames filtered by the spatial filter unit; Video decoding method comprising a 제11항에 있어서, 상기 공간적 필터링 단계는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 블록간의 경계에 대해서 블록간 경계 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 블록길이만큼의 픽셀들을 필터링하는 것을 특징으로 하는 동영상 디코딩 방법12. The method of claim 11, wherein the spatial filtering step selects pixels equal to the block length when the difference in the inter-block boundary pixel value is smaller than a predetermined value with respect to the inter-block boundary having a motion vector of a refiner unit of an intra coded frame. Video decoding method characterized in that the filtering 제11항에 있어서, 상기 시간적 필터링 단계는 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링을 하는 것을 특징으로 하는 동영상 디코더12. The method of claim 11, wherein the temporal filtering step includes macros of preceding and following frames corresponding to the macroblocks for macroblocks coded with a macroblock type, motion vectors smaller than a predetermined value, and quantization coefficients smaller than a predetermined value. Video decoder characterized in that the median filtering with blocks 엔코딩된 이미지를 디코딩하는 H.264 디코딩 방법에 있어서,In the H.264 decoding method for decoding an encoded image, 디코딩된 이미지를 루프필터링하는 루프필터링 단계 또는 디코딩된 이미지를 후처리하는 후처리필터링 단계 중 어느 한 단계를 선택하는 단계를 포함하는 것을 특징으로 하는 H.264 디코딩 방법H.264 decoding method comprising the step of selecting a loop filtering step of loop filtering the decoded image or a post-processing filtering step of post-processing the decoded image. 제14항에 있어서, 상기 후처리필터링 단계는 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 필터링하는 것을 특징으로 하는 H.264 디코딩 방법15. The method of claim 14, wherein the post-processing filtering step comprises filtering four pixels by correcting values of horizontal or vertical boundaries between the two subblocks in filtering horizontal or vertical boundaries between subblocks constituting the frame. H.264 decoding method 제15항에 있어서, 상기 후처리필터링 단계는 인트라 코딩된 프레임의 정화소 단위의 움직임 벡터를 갖는 서브 블록간의 경계에 대해서 상기 두 서브블록의 경계에 맞닿은 2개의 픽셀 값의 차이가 소정의 값보다 작은 경우에 상기 4개의 픽셀 값들의 분포된 형태에 따라 상기 4개의 픽셀 값들을 보정하는 것을 특징으로 하는 H.264 디코딩 방법16. The method of claim 15, wherein the post-processing filtering step includes a difference between two pixel values abutting a boundary between the two subblocks with respect to a boundary between subblocks having a motion vector of a refiner unit of an intra coded frame is smaller than a predetermined value. H.264 decoding method, characterized in that for correcting the four pixel values in accordance with the distribution form of the four pixel values 제14항에 있어서, 상기 후처리필터링 단계는 프레임을 구성하는 서브 블록간 수평 또는 수직 경계를 필터링하는데 있어 상기 두 서브블록의 수평 또는 수직 경계를 중심으로 4 개의 픽셀들의 값을 보정하여 공간적 필터링하고 상기 공간적 필터링된 프레임들에 대하여 시간적 필터링을 수행하는 것을 특징으로 하는 H.264 디코딩 방법15. The method of claim 14, wherein the post-processing filtering step performs spatial filtering by correcting values of four pixels around the horizontal or vertical boundary of the two subblocks in filtering the horizontal or vertical boundary between the subblocks constituting the frame. H.264 decoding method for performing temporal filtering on the spatially filtered frames 제17항에 있어서, 상기 시간적 필터링은 상기 공간적 필터링된 프레임 중에서 매크로블록 타입으로 코딩되고 움직임 벡터가 소정의 값보다 작으며, 양자화 계수가 소정의 값보다 작은 매크로블록들에 대해서 상기 매크로블록에 대응되는 전후 프레임의 매크로블록들과 중간값 필터링을 하는 것은 특징으로 하는 H.264 디코딩 방법18. The method of claim 17, wherein the temporal filtering corresponds to the macroblock for macroblocks of the spatially filtered frame that are coded in a macroblock type and whose motion vector is less than a predetermined value and whose quantization coefficient is less than a predetermined value. H.264 decoding method characterized in that the median filtering with macroblocks of the frame before and after
KR1020030081671A 2003-11-18 2003-11-18 Method for fast filtering in moving picture decoding, and apparatus for the same KR20050047871A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020030081671A KR20050047871A (en) 2003-11-18 2003-11-18 Method for fast filtering in moving picture decoding, and apparatus for the same

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020030081671A KR20050047871A (en) 2003-11-18 2003-11-18 Method for fast filtering in moving picture decoding, and apparatus for the same

Publications (1)

Publication Number Publication Date
KR20050047871A true KR20050047871A (en) 2005-05-23

Family

ID=37246754

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020030081671A KR20050047871A (en) 2003-11-18 2003-11-18 Method for fast filtering in moving picture decoding, and apparatus for the same

Country Status (1)

Country Link
KR (1) KR20050047871A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013066133A1 (en) * 2011-11-04 2013-05-10 엘지전자 주식회사 Method and apparatus for encoding/decoding image information
WO2013077714A1 (en) * 2011-11-27 2013-05-30 엘지전자 주식회사 Method and apparatus for encoding/decoding image information

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013066133A1 (en) * 2011-11-04 2013-05-10 엘지전자 주식회사 Method and apparatus for encoding/decoding image information
US10778975B2 (en) 2011-11-04 2020-09-15 Lg Electronics Inc. Method and apparatus for encoding/decoding image information
US11350090B2 (en) 2011-11-04 2022-05-31 Lg Electronics Inc. Method and apparatus for encoding/decoding image information
US11743460B2 (en) 2011-11-04 2023-08-29 Lg Electronics Inc Method and apparatus for encoding/decoding image information
WO2013077714A1 (en) * 2011-11-27 2013-05-30 엘지전자 주식회사 Method and apparatus for encoding/decoding image information

Similar Documents

Publication Publication Date Title
US7869523B2 (en) Low complexity deblocking filter
KR101000926B1 (en) Filter for removing blocking effect and filtering method thereof
US5850294A (en) Method and apparatus for post-processing images
EP2708027B1 (en) Method and apparatus for reduction of in-loop filter buffer
JP5396478B2 (en) Video coding method using adaptive loop filter
US5565921A (en) Motion-adaptive image signal processing system
RU2154918C1 (en) Method and device for loop filtration of image data
JP2529808B2 (en) Video signal band compression device for digital VTR
TWI709333B (en) A method of deblocking filtering
US20050281339A1 (en) Filtering method of audio-visual codec and filtering apparatus
CN103947208B (en) Reduce the method and device of deblocking filter
US7822125B2 (en) Method for chroma deblocking
WO2003061295A2 (en) Sharpness enhancement in post-processing of digital video signals using coding information and local spatial features
RU2305377C2 (en) Method for decreasing distortion of compressed video image and device for realization of the method
JP3365784B2 (en) Image signal decoding device
KR20050047871A (en) Method for fast filtering in moving picture decoding, and apparatus for the same
JP3800435B2 (en) Video signal processing device
US5734757A (en) Post-processing method and apparatus for use in an image signal decoding system
US7738726B2 (en) Block distortion reduction apparatus
JPH07131793A (en) Video signal high efficiency coding device
JPH1056646A (en) Video signal decoder
KR101063421B1 (en) Video decoder and video decoding method
JP3985567B2 (en) Encoding device and encoding method
KR100221308B1 (en) A device for eliminating blocking effects and a moving picture decoder using the device
Khan et al. MATLAB BASED IMPLEMENTATION AND COMPARATIVE ANALYSIS OF DE-BLOCKING ALGORITHMS

Legal Events

Date Code Title Description
WITN Withdrawal due to no request for examination