TW202002656A - Methods and devices for performing sample adaptive offset (SAO) filtering - Google Patents

Methods and devices for performing sample adaptive offset (SAO) filtering Download PDF

Info

Publication number
TW202002656A
TW202002656A TW108116392A TW108116392A TW202002656A TW 202002656 A TW202002656 A TW 202002656A TW 108116392 A TW108116392 A TW 108116392A TW 108116392 A TW108116392 A TW 108116392A TW 202002656 A TW202002656 A TW 202002656A
Authority
TW
Taiwan
Prior art keywords
offset
edge
sao
symbol
edge offset
Prior art date
Application number
TW108116392A
Other languages
Chinese (zh)
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 日商佳能股份有限公司
Publication of TW202002656A publication Critical patent/TW202002656A/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/80Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N13/00Stereoscopic video systems; Multi-view video systems; Details thereof
    • H04N13/10Processing, recording or transmission of stereoscopic or multi-view image signals
    • H04N13/106Processing image signals
    • H04N13/161Encoding, multiplexing or demultiplexing different image signal components
    • 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/117Filters, e.g. for pre-processing or post-processing
    • 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/154Measured or subjectively estimated visual quality after decoding, e.g. measurement of distortion
    • 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
    • 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
    • H04N19/86Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using pre-processing or post-processing specially adapted for video compression involving reduction of coding artifacts, e.g. of blockiness

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Image Processing (AREA)

Abstract

The present invention relates to methods for improving the coding efficiency of images subjected to the SAO filtering. According to a first aspect of the invention, there is provided a method of performing sample adaptive offset (SAO) filtering on an image comprising a plurality of image parts, the method comprising: obtaining an edge offset to perform a SAO filtering; applying an edge offset classification to at least one pixel of the image using a predetermined sign method for determining an index of the edge offset; wherein the predetermined sign method is signalled in the bitstream. Correspondingly, there is provided a method of providing an edge offset to perform a sample adaptive offset (SAO) filtering on an image, the method comprising: computing an edge offset to perform the SAO filtering; selecting a sign method among a plurality of possible sign methods for determining an index of the edge offset; and signalling the selected sign method in the bitstream thereby allowing the edge offset classification to be performed according to the selected sign method.

Description

用於執行取樣自適應偏移(SAO)濾波之方法和裝置Method and device for performing sampling adaptive offset (SAO) filtering

本發明關於視訊編碼與解碼。The invention relates to video encoding and decoding.

近年來,由MPEG與ITU-T研究群16’sVCEG所形成的協同組織聯合視訊專家小組(JVET)開始所謂多功能視訊編碼(VVC)的新視訊編碼標準的工作。VVC的目標為對現行HEVC標準的壓縮效能提供顯著改良(即,典型以前的兩倍)並且在2020年完成。主要目標應用與服務包括但並不限於360度及高動態範圍(HDR)視訊。總而言之,JVET評估使用來自獨立測試實驗室的進行的正式主觀測試的32個組織的回應。當相較於使用HEVC時,一些提案展現典型40%或更多的壓縮效率增益。特別功效係被顯現在超高解析(UHD)視訊測試材料上。因此,我們可以預期最終標準中,壓縮效率增益將遠超出目標50%以上。In recent years, the Joint Video Experts Group (JVET), a collaborative organization formed by MPEG and ITU-T research group 16’sVCEG, has begun work on a new video coding standard called multi-function video coding (VVC). The goal of VVC is to provide a significant improvement in the compression performance of the current HEVC standard (ie, typically twice that of the previous one) and be completed in 2020. The main target applications and services include but are not limited to 360-degree and high dynamic range (HDR) video. In summary, JVET evaluated the responses of 32 organizations that used formal subjective tests from independent test laboratories. When compared to the use of HEVC, some proposals exhibit a typical compression efficiency gain of 40% or more. The special effects are shown on ultra-high resolution (UHD) video test materials. Therefore, we can expect that in the final standard, the compression efficiency gain will far exceed the target by more than 50%.

JVET探索模型(JEM)使用所有HEVC工具。這些工具之一為取樣自適應偏移(SAO)濾波。然而,在JEM參考軟體中的SAO係較在HEVC參考軟體中者沒有效率。相較於其他環路濾波器,這是由更少的評估以及發信效率低造成。The JVET exploration model (JEM) uses all HEVC tools. One of these tools is sample adaptive offset (SAO) filtering. However, the SAO in the JEM reference software is less efficient than the HEVC reference software. Compared to other loop filters, this is caused by fewer evaluations and low signal transmission efficiency.

在文件JVET-J0024中,揭露了修改SAO邊緣偏移分類。此修改於測試低延遲P架構時給出了有趣結果,但對於在建立用於VVC標準的VTM軟體的頂部上的低延遲B架構則有損失。In the document JVET-J0024, it is disclosed to modify the SAO edge offset classification. This modification gave interesting results when testing the low-latency P architecture, but there was a loss for the low-latency B architecture on top of building VTM software for the VVC standard.

因此,想要改良受到SAO濾波的影像的編碼效率。Therefore, it is desired to improve the coding efficiency of SAO filtered video.

本發明已經過設計以解決前述的一或多個顧慮。The present invention has been designed to address one or more of the aforementioned concerns.

依據本發明第一態樣,提供一種對具有多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得邊緣偏移,以執行SAO濾波; 使用用以決定邊緣偏移的索引的預定符號法,將邊緣偏移分類施加至該影像的至少一像素; 其中該預定符號法被發信在位元流中。According to the first aspect of the present invention, a method for performing sample adaptive offset (SAO) filtering on an image having a plurality of image parts is provided. The method includes: Get the edge offset to perform SAO filtering; Using a predetermined symbol method to determine the index of the edge offset, apply the edge offset classification to at least one pixel of the image; The predetermined symbol method is sent in the bit stream.

對應地,其中提供一種提供邊緣偏移的方法,用以對影像執行取樣自適應偏移(SAO)濾波,該方法包含: 計算邊緣偏移,以執行SAO濾波; 由多數可能符號法中選擇一符號法,以決定該邊緣偏移的索引;及 在該位元流中,發信該所選擇符號法,以允許該邊緣偏移分類依據所選擇符號法加以執行。Correspondingly, there is provided a method for providing edge offset for performing sample adaptive offset (SAO) filtering on an image. The method includes: Calculate the edge offset to perform SAO filtering; Choose one of the most possible symbologies to determine the index of the edge offset; and In the bit stream, the selected symbol method is sent to allow the edge offset classification to be performed according to the selected symbol method.

因此,依據本發明第一態樣的方法,使得其可以改良受到SAO濾波的影像的編碼效率。Therefore, according to the method of the first aspect of the present invention, it can improve the coding efficiency of the image subjected to SAO filtering.

同時,它們也相較於對於所有邊緣偏移為相同的符號法的先前技藝能提供更佳的彈性。因此,這些方法係較佳適應於量化誤差與視訊內容。At the same time, they also provide better flexibility than previous techniques that use the same notation for all edge offsets. Therefore, these methods are better suited to quantization errors and video content.

第一態樣的選用特性更進一步界定於附屬項中。The selection characteristics of the first aspect are further defined in the ancillary items.

依據實施例,預定符號法被以CTU位準發信於位元流中。According to an embodiment, the predetermined symbol method is signaled in the bit stream at the CTU level.

以CTU位準發信邊緣符號法的優點為依據畫框/切片內容及量化誤差的有效適應,其相較於先前技藝產生編碼效率的改良。The advantages of the CTU level signal edge symbol method are based on the effective adaptation of the frame/slice content and quantization error, which results in an improvement in coding efficiency compared to previous techniques.

依據實施例,預定符號法被以畫框、切片或序列位準發信於位元流中。According to an embodiment, the predetermined symbol method is signaled in the bit stream in frame, slice, or sequence levels.

此實施例的優點可以是當畫框/切片內容及量化誤差在現行切片/畫框內為相對同質時,編碼效率可以被改良。在切片檔頭發信的主要優點為對於符號法的可能值的數目可能高於用於CTU位準發信法者。The advantage of this embodiment may be that when the frame/slice content and quantization error are relatively homogeneous within the current slice/picture frame, the coding efficiency may be improved. The main advantage of sending messages in a slice file is that the number of possible values for the symbol method may be higher than those used for CTU level signal sending methods.

依據實施例,該預定符號法被CABAC編碼。According to an embodiment, the predetermined symbol method is CABAC coded.

此實施法的優點可能是當畫框/切片內容及量化誤差在現行切片/畫框內相對同質時,編碼效率增加。結果,一種邊緣偏移符號法可以被選擇用於很多CTU。The advantage of this implementation method may be that when the content of the frame/slice and the quantization error are relatively homogeneous within the current slice/frame, the coding efficiency increases. As a result, an edge offset symbol method can be selected for many CTUs.

依據實施例,預定符號法被預測。According to the embodiment, the predetermined symbol method is predicted.

第二實施例及所有其子實施例的優點為由於信號內容的空間相關性及現行切片/畫框的CTU間的類似量化誤差的利用,所以,編碼效率增加。這是因為當現行切片的信號逐CTU地類似時及當量化誤差也類似時,在編碼器側的最佳選擇符號法通常也會類似。The advantage of the second embodiment and all its sub-embodiments is that due to the spatial correlation of the signal content and the use of similar quantization errors between the CTUs of the current slice/picture frame, the coding efficiency is increased. This is because when the signal of the current slice is similar by CTU and when the quantization error is also similar, the optimal symbol selection method on the encoder side is usually similar.

依據實施例,預定符號法也在編碼器側加以選擇,以最小化碼率-失真成本。According to an embodiment, the predetermined symbol method is also selected on the encoder side to minimize the rate-distortion cost.

此實施例的優點可以是其應到達用於切片/畫框位準發信的最大編碼效率。The advantage of this embodiment may be that it should reach the maximum coding efficiency for slice/picture frame level signaling.

依據實施例,在編碼器側的預定符號法係依據現行切片或畫框的參數加以選擇。According to the embodiment, the predetermined symbol method on the encoder side is selected according to the parameters of the current slice or picture frame.

依據實施例,預定符號法考量對應於限定值的數目N,來界定符號函數。According to an embodiment, the predetermined sign method considers the number N corresponding to the limit value to define the sign function.

依據實施例,預定符號法係在編碼器側根據非連續的多數限定值N加以選擇。According to the embodiment, the predetermined sign method is selected on the encoder side according to the discontinuous majority limit value N.

因為連續值並不對應於自然內容及相關量化誤差的統計,所以當以CTU位準或更低位準發信時,這些實施例可能很有趣。一個優點為編碼效率改良。Since continuous values do not correspond to the statistics of natural content and related quantization errors, these embodiments may be interesting when transmitting at the CTU level or lower. One advantage is improved coding efficiency.

依據實施例,預定符號法係在編碼器側依據取決切片型的多數限定值N加以選擇。According to the embodiment, the predetermined symbol method is selected on the encoder side according to the majority limit value N depending on the slice type.

依據實施例,預定符號法係在編碼器側依據取決於色彩成分的多數限定值N加以選擇。According to an embodiment, the predetermined symbol method is selected on the encoder side according to a majority limit value N that depends on color components.

此實施例的優點可以是由於各個顏色成分型的適應組N值的編碼效率改良。The advantage of this embodiment may be due to the improved coding efficiency of the N-value of the adaptation group of each color component type.

依據實施例,預定符號法係在編碼器側依據只取決於亮度的多數限定值N加以選擇。According to an embodiment, the predetermined symbol method is selected on the encoder side based on a majority limit value N that only depends on brightness.

此實施例的優點可以是藉由移除選擇用於色度成分的符號法的編碼效率改良。The advantage of this embodiment may be the improvement in coding efficiency by removing the symbology selected for chroma components.

依據實施例,預定符號法係在編碼器側依據在切片檔頭中發信的多數限定值N加以選擇。According to the embodiment, the predetermined symbol method is selected on the encoder side according to the majority limit value N transmitted in the slice header.

此實施例的優點可以是藉由在編碼器側設定用於各個切片的有用組而增加編碼效率。The advantage of this embodiment may be to increase the coding efficiency by setting a useful set for each slice on the encoder side.

依據實施例,預定符號法係在編碼器側依據多數限定值N加以選擇。According to the embodiment, the predetermined symbol method is selected on the encoder side according to the majority limit value N.

依據實施例,多數限定值N取決色彩成分。According to the embodiment, the majority limit value N depends on the color component.

依據本發明的第二態樣,其中提供一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中該多數邊緣偏移的至少一邊緣偏移的符號係被發信於位元流中。According to a second aspect of the present invention, there is provided a method of performing sample adaptive offset (SAO) filtering on an image including a plurality of image parts. The method includes: Obtain most edge offsets to perform SAO filtering; The symbol of at least one edge offset of the majority of edge offsets is transmitted in the bit stream.

依據實施例,此方法也可以包含對該影像的像素施加邊緣偏移分類,其中該邊緣偏移分類將發信於位元流中的多數邊緣偏移之至少一邊緣偏移的符號列入考量。According to an embodiment, the method may also include applying an edge offset classification to the pixels of the image, where the edge offset classification takes into account at least one edge offset symbol sent from the majority of edge offsets in the bitstream .

對應地,其中提供有一種提供邊緣偏移的方法,以對影像執行取樣自適應偏移(SAO)濾波,該方法包含: 取得多數邊緣偏移,以執行該SAO濾波; 藉由針對各個邊緣偏移施加符號法至一符號參數N,以計算該邊緣偏移的索引;及 將該多數邊緣偏移的至少一邊緣偏移的符號發信在該位元流中。Correspondingly, there is provided a method for providing edge offset to perform sample adaptive offset (SAO) filtering on an image. The method includes: Obtain the majority of edge offsets to perform the SAO filtering; Calculate the index of the edge offset by applying the sign method to a symbol parameter N for each edge offset; and At least one edge offset symbol of the majority edge offset is signaled in the bit stream.

因此,依據本發明的第二態樣的方法使其可能改良受到SAO濾波的影像的編碼效率。Therefore, the method according to the second aspect of the present invention makes it possible to improve the coding efficiency of the image subjected to SAO filtering.

第二態樣的選用特性被進一步界定在附屬項中。The optional features of the second aspect are further defined in the ancillary items.

依據實施例,邊緣偏移的符號係被發信,用於該多數邊緣偏移的所有邊緣偏移,其中被用於決定該邊緣偏移的索引的符號函數中的符號參數N為正時,該邊緣偏移的符號為嚴格正。According to an embodiment, the sign of the edge offset is sent for all edge offsets of the majority of edge offsets, where the sign parameter N in the sign function used to determine the index of the edge offset is positive, The sign of this edge shift is strictly positive.

依據實施例,如果用於決定邊緣偏移的索引的符號函數中的所有符號參數N高於預定臨限,則該邊緣偏移的符號被發信於該多數邊緣偏移的所有邊緣偏移。According to an embodiment, if all symbol parameters N in the symbol function used to determine the index of the edge offset are higher than a predetermined threshold, then the symbol of the edge offset is sent to all edge offsets of the majority of edge offsets.

此實施例的優點可以是當用於符號法中的值N為高時,相較於用於邊緣偏移分類的偏移的隱式符號發信有編碼效率增加。The advantage of this embodiment may be that when the value N used in the symbol method is high, the coding efficiency is increased compared to the implicit symbol signaling used for the offset for edge offset classification.

依據實施例,邊緣偏移的符號被發信的至少一邊緣偏移屬於峰及谷架構。According to an embodiment, at least one edge offset to which the symbol of the edge offset is signaled belongs to the peak and valley structure.

依據實施例,至少一邊緣偏移的符號係被發信,而不管什麼預定符號法被使用來決定該邊緣偏移的索引。According to an embodiment, at least one edge-shifted symbol is sent regardless of what predetermined symbol method is used to determine the index of the edge-shift.

依據實施例,該邊緣偏移的符號只對邊緣偏移發信,其中用以決定這些邊緣偏移的索引的符號參數N高於預定臨限者。According to an embodiment, the symbol of the edge offset only signals the edge offset, where the symbol parameter N used to determine the indexes of these edge offsets is higher than a predetermined threshold.

依據實施例,該邊緣偏移的符號只對邊緣偏移發信,其中用以決定這些邊緣偏移的索引的符號參數N不是零者。According to an embodiment, the symbol of the edge offset only signals the edge offset, where the symbol parameter N used to determine the index of these edge offsets is not zero.

依據實施例,該邊緣偏移的符號只對亮度成分發信。According to an embodiment, the edge-shifted symbol only signals the luminance component.

此實施例的優點可以是相較於對於所有色彩成分的符號發信者的編碼效率改良。這是因為對於色度成分,隱式發信可能較符號的顯式發信更有效率。The advantage of this embodiment may be improved coding efficiency compared to the symbol sender for all color components. This is because for chroma components, implicit signaling may be more efficient than explicit signaling of symbols.

依據本發明的第三實施例,提供一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中該多數邊緣偏移的至少一邊緣偏移的符號被發信於位元流中;及 其中取得多數邊緣偏移包含預測至少一邊緣偏移,其符號被發信於位元流中者。According to a third embodiment of the present invention, a method for performing sample adaptive offset (SAO) filtering on an image including a plurality of image parts is provided. The method includes: Obtain most edge offsets to perform SAO filtering; Where at least one edge-offset symbol of the majority of edge offsets is sent in the bitstream; and Obtaining the majority of edge offsets includes predicting at least one edge offset whose symbol is signaled in the bitstream.

對應地,其中提供一種提供邊緣偏移的方法,以對影像執行取樣自適應偏移(SAO)濾波,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 對各個邊緣偏移取得該邊緣偏移的符號; 其中該方法更包含將該多數邊緣偏移的至少一邊緣偏移的符號發信於該位元流中;及 其中取得多數邊緣偏移包含預測至少一邊緣偏移,其符號被發信於位元流中者。Correspondingly, there is provided a method for providing edge offset to perform sample adaptive offset (SAO) filtering on an image. The method includes: Obtain most edge offsets to perform SAO filtering; Obtain the sign of the edge offset for each edge offset; The method further includes signaling at least one edge-shifted symbol of the majority of edge shifts in the bitstream; and Obtaining the majority of edge offsets includes predicting at least one edge offset whose symbol is signaled in the bitstream.

因此,依據本發明第三態樣的方法有可能可改良受到SAO濾波的影像的編碼效率。Therefore, the method according to the third aspect of the present invention may improve the coding efficiency of the image subjected to SAO filtering.

第三態樣的選用特性被進一步界定於附屬項中。The optional features of the third aspect are further defined in the ancillary items.

依據實施例,至少一邊緣偏移係由預設值加以預測。According to an embodiment, at least one edge offset is predicted from a preset value.

依據實施例,預設值係被傳送於位元流中。According to an embodiment, the preset value is transmitted in the bit stream.

依據實施例,預設值係被預定用於至少一序列,例如所有序列。According to an embodiment, the preset value is predetermined for at least one sequence, for example all sequences.

依據實施例,該方法更包含設定該預設值的符號。According to an embodiment, the method further includes setting the symbol of the preset value.

依據實施例,該預設值取決於用於在決定邊緣偏移的索引的符號函數中的符號參數N。According to an embodiment, the preset value depends on the sign parameter N used in the sign function that determines the index of the edge offset.

此實施例的優點可以是相較於所有邊緣偏移符號法的固定值,編碼效率的增加。這是因為當符號法的N值增加時,絕對偏移值也增加。The advantage of this embodiment may be an increase in coding efficiency compared to a fixed value for all edge offset sign methods. This is because when the N value of the symbol method increases, the absolute offset value also increases.

依據實施例,該方法更包含對影像的像素施加邊緣偏移分類,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,及對應於峰及谷的相關於第一及最後類型的邊緣偏移的絕對預測子值係高於相關於其他類型的邊緣偏移的絕對預測子值。According to an embodiment, the method further includes applying an edge offset classification to the pixels of the image to classify the pixels into four types, each type related to a given edge offset, and corresponding to peaks and valleys related to the first and The absolute predictor value for the last type of edge offset is higher than the absolute predictor value for other types of edge offset.

此實施例可以特別有利,因為偏移O1及O4的絕對平均值通常大於偏移O2及O3的絕對平均值。因此,此實施例可以提供較佳編碼效率。This embodiment may be particularly advantageous because the absolute average of offsets O1 and O4 is generally greater than the absolute average of offsets O2 and O3. Therefore, this embodiment can provide better coding efficiency.

依據實施例,該方法更包含對影像的像素施加邊緣偏移分類,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,及對應於峰及谷的相關於第一及最後類型的邊緣偏移的絕對預測子值為相同。According to an embodiment, the method further includes applying an edge offset classification to the pixels of the image to classify the pixels into four types, each type related to a given edge offset, and corresponding to peaks and valleys related to the first and The absolute predictor value of the last type of edge offset is the same.

依據實施例,相關於其他類型的邊緣偏移的絕對預測子值為相同。According to an embodiment, the absolute predictor values related to other types of edge offsets are the same.

較佳地,該程序被簡化並配合偏移值的統計選擇。Preferably, the procedure is simplified and matched with the statistical selection of offset values.

依據實施例,邊緣偏移分類考量多數邊緣偏移的至少一邊緣偏移的符號,其係被發信在位元流中。According to an embodiment, the edge offset classification takes into account at least one edge offset symbol of most edge offsets, which is signaled in the bit stream.

依據實施例,該至少一邊緣偏移係由用於決定邊緣偏移的索引的符號函數中的符號參數N預測。According to an embodiment, the at least one edge offset is predicted by a symbol parameter N in a symbol function used to determine the index of the edge offset.

依據實施例,該多數邊緣偏移中的符號被發信於位元流中的至少一些邊緣偏移並未被預測。According to an embodiment, the symbols in the majority of edge offsets are signaled that at least some edge offsets in the bitstream are not predicted.

依據實施例,該方法更包含施加邊緣偏移分類至該影像的像素,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,並且只有對應於峰及谷的有關該第一與最後類型的邊緣偏移被預測。According to an embodiment, the method further includes applying an edge offset to the pixels of the image to classify the pixels into four types, each type is associated with a given edge offset, and only the peak and valley An edge offset from the last type is predicted.

此實施例的優點可以是增加編碼效率。這是因為偏移O1及O4的絕對平均值平均上大於偏移O2及O3。另外,O2及O3的絕對值經常低於1。結果,可能不需要預測它們並發信一符號。The advantage of this embodiment may be increased coding efficiency. This is because the absolute average of the offsets O1 and O4 is larger than the offsets O2 and O3 on average. In addition, the absolute values of O2 and O3 are often lower than 1. As a result, it may not be necessary to predict them and send a symbol.

依據實施例,邊緣偏移只針對亮度成分作預測。According to the embodiment, the edge offset is only predicted for the luminance component.

此實施例的優點可以是增加編碼效率。這是因為,用於亮度成分的絕對偏移值通常高於用於色度成分者。亮度成分的預測可能夠有效。因此,此實施例可以提供一簡化版,因為避免了色度偏移的預測。The advantage of this embodiment may be increased coding efficiency. This is because the absolute offset value used for the luma component is usually higher than that used for the chroma component. The prediction of the luminance component may be effective. Therefore, this embodiment can provide a simplified version because the prediction of chroma shift is avoided.

依據實施例,該方法更包含對影像的像素施加邊緣偏移分類,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,及只有對應於峰及谷的相關於第一與最後類型的邊緣偏移以及亮度成分的邊緣偏移被預測。According to an embodiment, the method further includes applying an edge offset classification to the pixels of the image to classify the pixels into four types, each type related to a given edge offset, and only the peaks and valleys related to the first The edge offset from the last type and the edge offset of the luminance component are predicted.

依據實施例,至少一邊緣偏移被由相鄰邊緣偏移值預測。According to an embodiment, at least one edge offset is predicted from adjacent edge offset values.

依據實施例,只有該相鄰邊緣偏移係使用相同符號法加以決定時,該至少一邊緣偏移才被由相鄰邊緣偏移值預測。According to an embodiment, only when the adjacent edge offset is determined using the same sign method, the at least one edge offset is predicted from the adjacent edge offset value.

依據本發明之第四態樣,其中提供一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中取得多數邊緣偏移包含預測至少一邊緣偏移;及 其中該至少一邊緣偏移的符號為隱式及該邊緣偏移的最小值係被設定為不是零的預設值。According to a fourth aspect of the present invention, there is provided a method for performing sample adaptive offset (SAO) filtering on an image including a plurality of image parts. The method includes: Obtain most edge offsets to perform SAO filtering; Wherein obtaining the majority of edge offsets includes predicting at least one edge offset; and The sign of the at least one edge offset is implicit and the minimum value of the edge offset is set to a preset value other than zero.

對應地,其中提供一種提供邊緣偏移的方法,以對影像執行取樣自適應偏移(SAO)濾波,該方法包含: 計算多數邊緣偏移,以執行SAO濾波; 其中計算多數邊緣偏移包含預測至少一邊緣偏移,及 其中該至少一邊緣偏移的符號係為隱式及該邊緣偏移的最小值係被設定為不是零的預設值。Correspondingly, there is provided a method for providing edge offset to perform sample adaptive offset (SAO) filtering on an image. The method includes: Calculate the majority of edge offsets to perform SAO filtering; Where calculating most edge offsets includes predicting at least one edge offset, and The sign system of the at least one edge offset is implicit and the minimum value of the edge offset is set to a preset value other than zero.

因此,依據本發明第四態樣的方法可能可改良受到SAO濾波的影像的編碼效率。Therefore, the method according to the fourth aspect of the present invention may improve the coding efficiency of SAO-filtered images.

因為並不需要增加該偏移的符號作為語法元件,所以依據此態樣的方法可以被視為相較於符號被傳送的實施例的簡化版。Since it is not necessary to add the offset symbol as a syntax element, the method according to this aspect can be regarded as a simplified version of the embodiment in which the symbol is transmitted.

第四實施例的選用特性被進一步界定於附屬項中。The optional feature of the fourth embodiment is further defined in the ancillary items.

依據實施例,該至少一邊緣偏移係由預設值預測。According to an embodiment, the at least one edge offset is predicted from a preset value.

依據實施例,該預設值被傳送於位元流中。According to an embodiment, the preset value is transmitted in the bit stream.

依據實施例,該預設值被決定用於至少一序列,例如所有的序列。According to an embodiment, the predetermined value is determined for at least one sequence, for example all sequences.

依據實施例,該方法更包含設定該預設值的符號。According to an embodiment, the method further includes setting the symbol of the preset value.

依據實施例,預設值取決於用於決定邊緣偏移的索引的符號函數中的符號參數N。According to an embodiment, the preset value depends on the sign parameter N in the sign function used to determine the index of the edge offset.

此實施例的優點可以是相較於用於所有邊緣偏移符號法的固定值,編碼效率的增加。這是因為當符號法的N值增加時,絕對偏移值也增加。The advantage of this embodiment may be an increase in coding efficiency compared to a fixed value used for all edge offset sign methods. This is because when the N value of the symbol method increases, the absolute offset value also increases.

依據實施例,該方法更包含對影像的像素施加邊緣偏移,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,及對應於峰與谷的相關於第一及最後類型的邊緣偏移的絕對預測子值係高於相關於其他類型的邊緣偏移的絕對預測子值。According to an embodiment, the method further includes applying an edge offset to the pixels of the image to classify the pixels into four types, each type related to a given edge offset, and corresponding to peaks and valleys related to the first and last The absolute predictor value of the type of edge offset is higher than that of other types of edge offset.

此實施例可以相當有利,因為偏移O1及O4的絕對平均值經常大於偏移O2及O3的絕對平均值。因此,此實施例可以提供較佳編碼效率。This embodiment can be quite advantageous because the absolute average of offsets O1 and O4 is often greater than the absolute average of offsets O2 and O3. Therefore, this embodiment can provide better coding efficiency.

依據實施例,該方法更包含對影像的像素施加邊緣偏移分類,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,及對應於峰及谷的與第一與最後類型相關的邊緣偏移的絕對預測子值為相同。According to an embodiment, the method further includes applying edge offset classification to the pixels of the image to classify the pixels into four types, each type related to a given edge offset, and the first and last corresponding to peaks and valleys The absolute predictor value of the type-dependent edge offset is the same.

依據實施例,有關於其他類型的邊緣偏移的絕對預測子值為相同。According to an embodiment, the absolute predictor values for other types of edge offsets are the same.

較佳地,該程序被簡化並被配合偏移值的統計選擇。Preferably, the procedure is simplified and adapted to the statistical selection of offset values.

依據實施例,邊緣偏移分類考量多數邊緣偏移的至少一邊緣偏移的被發信於位元流中的符號。According to an embodiment, the edge offset classification takes into account symbols of at least one edge offset of the majority of edge offsets that are signaled in the bitstream.

依據實施例,該至少一邊緣偏移由用以決定邊緣偏移的索引的符號函數中的符號參數N預測。According to an embodiment, the at least one edge offset is predicted by a symbol parameter N in a symbol function used to determine the index of the edge offset.

依據實施例,該多數邊緣偏移的至少一些邊緣偏移未被預測。According to an embodiment, at least some edge offsets of the majority of edge offsets are not predicted.

依據實施例,該方法更包含對影像的像素施加邊緣偏移分類,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,及只有相關於對應於峰及谷的第一與最後類型的邊緣偏移被預測。According to an embodiment, the method further includes applying an edge offset classification to the pixels of the image to classify the pixels into four types, each type related to a given edge offset, and only related to the first corresponding to peaks and valleys The edge offset from the last type is predicted.

此實施例的優點可以增加編碼效率。這是因為偏移O1及O4的絕對平均值平均上大於偏移O2及O3。另外,用於O2及O3的絕對值經常低於1。結果,可能不必要預測它們。The advantages of this embodiment can increase coding efficiency. This is because the absolute average of the offsets O1 and O4 is larger than the offsets O2 and O3 on average. In addition, the absolute values used for O2 and O3 are often below 1. As a result, it may not be necessary to predict them.

依據實施例,邊緣偏移只針對亮度成分預測。According to the embodiment, the edge offset is only predicted for the luminance component.

此實施例的優點可以增加編碼效率。這是因為對於亮度的絕對偏移值通常是高於用於色度成分的絕對偏移值。亮度成分的預測可能足夠有效。因為避免了色度偏移的預測,所以,此實施例可以因此提供一簡化版。The advantages of this embodiment can increase coding efficiency. This is because the absolute offset value for luminance is usually higher than the absolute offset value for chroma components. The prediction of the luminance component may be sufficiently effective. Since the prediction of chroma shift is avoided, this embodiment can therefore provide a simplified version.

依據實施例,該方法進一步包含對影像的像素施加邊緣偏移分類,以將像素分類為四個類型,各個類型相關於一給定邊緣偏移,並且只有對應於峰及谷的有關於第一與最後類型的邊緣偏移及亮度成分的邊緣偏移被預測。According to an embodiment, the method further includes applying an edge offset classification to the pixels of the image to classify the pixels into four types, each type is related to a given edge offset, and only the peaks and valleys related to the first The edge offset from the last type and the edge offset of the luminance component are predicted.

依據實施例,至少一邊緣偏移係由相鄰邊緣偏移值預測。According to an embodiment, at least one edge offset is predicted from adjacent edge offset values.

依據實施例,只有當相鄰邊緣偏移係使用相同符號法加以決定時,該至少一邊緣偏移係由相鄰邊緣偏移值預測。According to an embodiment, only when the adjacent edge offset is determined using the same sign method, the at least one edge offset is predicted from the adjacent edge offset value.

依據本發明的另一態樣,其中提供一種編碼影像的方法,包含使用前述方法之一來執行取樣自適應偏移(SAO)濾波。According to another aspect of the present invention, there is provided a method for encoding an image, which includes using one of the foregoing methods to perform sample adaptive offset (SAO) filtering.

依據本發明的另一態樣,其中提供一種解碼影像的方法,包含使用前述方法之一來執行取樣自適應偏移(SAO)濾波。According to another aspect of the present invention, a method for decoding an image is provided, which includes using one of the foregoing methods to perform sample adaptive offset (SAO) filtering.

依據本發明的另一態樣,其中提供一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的裝置,該裝置包含微處理器,被組態以執行前述方法之一的步驟。According to another aspect of the present invention, there is provided an apparatus for performing sample adaptive offset (SAO) filtering on an image including a plurality of image parts, the apparatus including a microprocessor configured to perform the steps of one of the aforementioned methods .

依據本發明之另一態樣,其中提供一種編碼器,包含前述之裝置。According to another aspect of the present invention, there is provided an encoder including the aforementioned device.

依據本發明之另一態樣,其中提供一種解碼器,包含前述之裝置。According to another aspect of the present invention, there is provided a decoder including the aforementioned device.

依據本發明之另一態樣,其中提供一種包含前述編碼器與前述解碼器的系統,被組態用以透過通訊網路通訊。According to another aspect of the present invention, there is provided a system including the aforementioned encoder and the aforementioned decoder, configured to communicate via a communication network.

本發明之其他態樣具有類似於前述第一、第二、第三及第四態樣的選用特性及優點。The other aspects of the present invention have similar characteristics and advantages as the aforementioned first, second, third, and fourth aspects.

因為本發明可以以軟體實施,所以,本發明可以實施為電腦可讀取碼,用以在任何適當承載媒體上提供給可程式設備,承載媒體更明確地說係適當有形的承載媒體或適當暫態承載媒體。有形承載媒體可以包含例如軟碟、CD-ROM、硬碟機、碟帶裝置或固態記憶體裝置等等的儲存媒體。暫態承載媒體可以包含例如電信號、電子信號、光學信號、聲音信號、磁信號或例如微波或RF信號的電磁信號的信號。Because the present invention can be implemented in software, the present invention can be implemented as a computer-readable code for providing to a programmable device on any suitable carrier media. The carrier media is more specifically a tangible carrier media or an appropriate temporary media. State media. The tangible carrier medium may include storage media such as a floppy disk, a CD-ROM, a hard disk drive, a tape device, a solid state memory device, or the like. The transient carrier medium may contain signals such as electrical signals, electronic signals, optical signals, sound signals, magnetic signals, or electromagnetic signals such as microwave or RF signals.

圖1有關於用於高效視訊編碼(HEVC)視訊標準中的編碼結構。視訊序列1係由一連續的數位影像i構成。各個如此的數位影像係為一或更多矩陣所表示。矩陣係數代表像素。Figure 1 relates to the coding structure used in the High Efficiency Video Coding (HEVC) video standard. The video sequence 1 consists of a continuous digital image i. Each such digital image is represented by one or more matrices. The matrix coefficients represent pixels.

該序列的影像2可以被切割為切片3。在一些例子中,切片可以構成整個影像。這些切片被切割為非重疊編碼樹單元(CTU)。編碼樹單元(CTU)為高效視訊編碼(HEVC)視訊標準的基本處理單元並且概念上結構對應於用於幾個先前視訊標準中的巨集塊單元。CTU同時有時被稱為最大編碼單元(LCU)。CTU具有亮度及色度成分部,其各個成分部被稱為編碼樹方塊(CTB)。這些不同顏色成分並未顯示於圖1中。The image 2 of this sequence can be cut into slices 3. In some examples, slices can constitute the entire image. These slices are cut into non-overlapping coding tree units (CTU). The coding tree unit (CTU) is the basic processing unit of the high efficiency video coding (HEVC) video standard and the conceptual structure corresponds to the macroblock unit used in several previous video standards. The CTU is also sometimes referred to as the largest coding unit (LCU). The CTU has luminance and chrominance component parts, and each component part is called a coding tree block (CTB). These different color components are not shown in Figure 1.

CTU通常大小為64像素×64像素。各個CTU隨後可以使用四元樹分解疊代地切割為更小可變尺寸編碼單元(CU)5。The CTU is usually 64 pixels by 64 pixels. Each CTU can then be split into smaller variable size coding units (CUs) 5 using quaternary tree decomposition and iteration.

編碼單元為基本編碼元件並由所謂預測單元(PU)及轉換單元(TU)的兩種子單元所構成。PU或TU的最大尺寸等於CU尺寸。預測單元對應於用於預測像素值的CU的分區。CU到PU的各種不同分區有可能如606所示,包含分區成4個正方PU及兩個不同分區成2個長方PU。轉換單元為受到使用DCT的空間轉換的基本單元。CU可以根據四元樹表示法607所分區成TU。The coding unit is a basic coding element and is composed of two subunits called a prediction unit (PU) and a conversion unit (TU). The maximum size of PU or TU is equal to CU size. The prediction unit corresponds to the partition of the CU used to predict the pixel value. Various partitions from CU to PU are possible as shown in 606, including partitioning into 4 square PUs and 2 different partitions into 2 rectangular PUs. The conversion unit is a basic unit subjected to spatial conversion using DCT. CUs can be partitioned into TUs according to quaternary tree representation 607.

各個切片被內藏於一個網路抽象層(NAL)單元中。另外,視訊序列的編碼參數係被儲存在稱為參數組的專用NAL單元中。在HEVC及H.264/AVC中,利用了兩種參數組NAL單元:第一,序列參數組(SPS)NAL單元,其收集在整個視訊序列中未改變的所有參數。典型地,其處理編碼設定檔、視訊畫框的尺寸及其他參數。第二,圖片參數組(PPS)NAL單元,其包含由一影像(或畫框)到序列的另一者改變的參數。HEVC同時也包含視訊參數組(VPS)NAL單元,其包含描述位元流的整個結構的參數。VPS為界定於HEVC中的新型的參數組,並應用至位元流的所有層中。一層可以包含多數時間子層,及所有版本1位元流被限制至單一層。HEVC具有某些分層擴充,用於縮放及多視觀看,並且,這些將使得多重層,具有向後相容版本1基礎層。Each slice is embedded in a network abstraction layer (NAL) unit. In addition, the coding parameters of the video sequence are stored in dedicated NAL units called parameter sets. In HEVC and H.264/AVC, two parameter group NAL units are used: first, a sequence parameter group (SPS) NAL unit, which collects all parameters that have not changed throughout the video sequence. Typically, it handles encoding profiles, the size of video frames, and other parameters. Second, the Picture Parameter Set (PPS) NAL unit, which contains parameters that change from one image (or picture frame) to another in the sequence. HEVC also contains Video Parameter Set (VPS) NAL units, which contain parameters describing the entire structure of the bitstream. VPS is a new type of parameter set defined in HEVC and applied to all layers of the bitstream. One layer can contain most time sublayers, and all versions of the 1-bit stream are restricted to a single layer. HEVC has certain layering extensions for zooming and multi-view viewing, and these will make multiple layers with a backward compatible version 1 base layer.

圖2例示資料通訊系統,其中可以實施本發明之一或更多實施例。資料通訊系統包含傳輸裝置,在此例中為伺服器201,其可以操作以透過資料通訊網路200傳送資料流的資料封包給接收裝置,接收裝置在本例中為客戶終端202。資料通訊網路200可以為廣域網路(WAN)或區域網路(LAN)。此網路可以例如是無線網路(Wifi/802.11a或b或g)、乙太網路、網際網路或由幾個不同網路構成的混合網路。在本發明之特定實施例中,資料通訊系統可以為數位電視廣播系統,其中伺服器201發送相同資料內容給多個客戶。FIG. 2 illustrates a data communication system in which one or more embodiments of the present invention can be implemented. The data communication system includes a transmission device, in this case a server 201, which is operable to transmit data packets of the data stream through the data communication network 200 to the receiving device, which in this example is the client terminal 202. The data communication network 200 may be a wide area network (WAN) or a local area network (LAN). This network can be, for example, a wireless network (Wifi/802.11a or b or g), an Ethernet network, an Internet network or a hybrid network composed of several different networks. In a specific embodiment of the present invention, the data communication system may be a digital television broadcasting system, in which the server 201 sends the same data content to multiple clients.

由伺服器201所提供的資料流204可以由代表視訊與音訊資料的多媒體資料構成。在本發明之一些實施例中,音訊與視訊資料流可以為分別使用麥克風或攝影機的伺服器201所捕獲。在一些實施例中,資料流可以被儲存在伺服器201中或來自另一資料提供者為伺服器201所接收、或在伺服器201產生。伺服器201被設有編碼器,用以編碼視訊與音訊流,更明確地說,提供用於傳輸的壓縮位元流,其係為被呈現給編碼器作為輸入的資料的更縮減表示法。The data stream 204 provided by the server 201 may be composed of multimedia data representing video and audio data. In some embodiments of the invention, the audio and video data streams can be captured by the server 201 using a microphone or a camera, respectively. In some embodiments, the data stream may be stored in the server 201 or received from the server 201 by another data provider or generated at the server 201. The server 201 is provided with an encoder for encoding video and audio streams, more specifically, a compressed bit stream for transmission, which is a reduced representation of the data presented to the encoder as input.

為了取得傳輸資料的質對傳輸資料的量的較佳比率,視訊資料的壓縮可以例如依據HEVC格式或H.264/AVC格式。In order to obtain a better ratio of the quality of the transmitted data to the amount of the transmitted data, the compression of the video data may be based on the HEVC format or H.264/AVC format, for example.

客戶202接收所發射的位元流並解碼該重建位元流,以在顯示裝置上播放視訊影像及在揚聲器上播放音訊資料。The client 202 receives the transmitted bit stream and decodes the reconstructed bit stream to play video images on the display device and audio data on the speaker.

雖然在圖2的例子中考量了串流情境,但將了解的是,在本發明的一些實施例中,在編碼器與解碼器間的資料通訊可以使用例如比如光碟的媒體儲存裝置加以執行。Although the streaming scenario is considered in the example of FIG. 2, it will be appreciated that in some embodiments of the invention, data communication between the encoder and the decoder may be performed using media storage devices such as optical discs, for example.

在本發明之一或更多實施例中,視訊影像係被與代表補償偏移的資料一起傳送,以施用至影像的重建像素,以在最終影像中提供濾波像素。In one or more embodiments of the invention, the video image is transmitted with data representing offset compensation to be applied to the reconstructed pixels of the image to provide filtered pixels in the final image.

圖3例示處理裝置300,其被組態以實施本發明的至少一實施例。處理裝置300可以為例如微電腦、工作站或輕型攜帶式裝置的裝置。裝置300包含通訊匯流排313,連接至: -中央處理單元311,例如標示為CPU的微處理器; -標示為ROM的唯讀記憶體307,用以儲存電腦程式,以實施本發明; -標示為RAM的隨機存取記憶體312,用以儲存本發明實施例方法的可執行碼,及適用以記錄實施方法所需的變數與參數的暫存器,所述方法包含依據本發明實施例編碼數位影像的序列及/或解碼位元流的方法;及 -連接至通訊網路303的通訊介面302,予以被處理的數位資料可以在其上被傳送或接收。FIG. 3 illustrates a processing device 300 configured to implement at least one embodiment of the present invention. The processing device 300 may be a device such as a microcomputer, a workstation, or a lightweight portable device. The device 300 includes a communication bus 313 connected to: -A central processing unit 311, such as a microprocessor labeled CPU; -Read-only memory 307 marked as ROM for storing computer programs to implement the present invention; -Random access memory 312 marked as RAM, used to store executable code of the method of the embodiment of the present invention, and a register suitable for recording variables and parameters required for the implementation of the method, the method including implementation according to the present invention Examples of methods for encoding sequences of digital images and/or decoding bit streams; and -The communication interface 302 connected to the communication network 303, on which the processed digital data can be transmitted or received.

選用地,該設備300也可以包含以下元件: -例如硬碟的資料儲存手段304,用以儲存用以實施本發明之一或更多實施例的方法的電腦程式及在本發明的一或更多實施例執行期間所使用或產生的資料; -用於碟片306的磁碟機305,磁碟機係適用以由碟片306讀取資料或將資料寫入至該碟片; -螢幕309藉由鍵盤310或其他指向手段,顯示資料及/或服務作為跟使用者的圖形界面。Optionally, the device 300 may also contain the following components: -Data storage means 304, such as a hard disk, for storing computer programs for implementing the method of one or more embodiments of the present invention and data used or generated during the execution of one or more embodiments of the present invention; -A disk drive 305 for the disk 306, which is suitable for reading data from the disk 306 or writing data to the disk; -The screen 309 uses the keyboard 310 or other pointing methods to display data and/or services as a graphical interface with the user.

設備300可以被連接至各種週邊,例如數位相機320或麥克風308,各個連接至輸入/輸出卡(未示出),以將多媒體資料供給設備300。The device 300 may be connected to various peripherals, such as a digital camera 320 or a microphone 308, each connected to an input/output card (not shown) to supply the multimedia material to the device 300.

通訊匯流排對包含於設備300中或連接至其上的各種元件間提供通訊及可交互運作性。匯流排的代表並不是限定性,特別的是,中央處理單元可操作以直接或藉由設備300的另一元件傳送指令給設備300的任一元件。The communication bus provides communication and interoperability between various components included in the device 300 or connected thereto. The representative of the bus is not limitative. In particular, the central processing unit is operable to send commands to any element of the device 300 directly or through another element of the device 300.

碟片306可以為任何資訊媒體所取代,例如,光碟(CD-ROM)、可寫光碟或不是、ZIP碟片或記憶卡,並且,以一般用語,藉由資訊儲存手段,其可以為微電腦或微處理器所讀取,整合或未整合入設備者,可能為可移除並適用以儲存一或更多程式,其執行使得依據本發明的編碼數位影像的序列的方法及/或解碼位元流的方法可以被執行。The disc 306 can be replaced by any information medium, for example, a CD-ROM, a writable disc or not, a ZIP disc or a memory card, and, in general terms, by means of information storage, it can be a microcomputer or Those read by the microprocessor, integrated or not integrated into the device, may be removable and suitable for storing one or more programs that perform methods and/or decoding bits that encode sequences of digital images according to the present invention The streaming method can be executed.

可執行碼可以被儲存在唯讀記憶體306中,或硬碟304上或可移除數位媒體上,例如如前述之碟片306。依據一變化例,程式的可執行碼可以由通訊網路303經由介面302加以接收,並在被執行之前,被儲存在設備300的儲存手段之一中,例如硬碟304中。The executable code may be stored in the read-only memory 306, or on the hard disk 304 or on the removable digital media, such as the disk 306 as described above. According to a variation, the executable code of the program may be received by the communication network 303 via the interface 302 and stored in one of the storage means of the device 300, such as the hard disk 304, before being executed.

中央處理單元311係被適用以依據本發明控制及指導指令的執行或程式或多數程式的軟體碼的部份的執行,指令係被儲存在前述儲存手段之一中。於開機時,儲存在非揮發記憶體,例如在硬碟304或者唯讀記憶體306中的程式或多數程式係被傳送入隨機存取記憶體312及用以儲存實施本發明所需的變數與參數的暫存器中,隨機存取記憶體312然後包含程式或多數程式的可執行碼。The central processing unit 311 is adapted to control and direct the execution of instructions or the execution of a program or part of the software code of most programs in accordance with the present invention. The instructions are stored in one of the aforementioned storage means. At startup, programs or most programs stored in non-volatile memory, such as hard disk 304 or read-only memory 306, are transferred into random access memory 312 and used to store variables and In the parameter register, the random access memory 312 then contains the executable code of the program or most programs.

在此實施例中,設備為可程式設備,其使用軟體以實施本發明。然而,或者,本發明可以以硬體(例如,以特殊應用積體電路或ASIC形式)實施。In this embodiment, the device is a programmable device that uses software to implement the present invention. However, alternatively, the present invention may be implemented in hardware (for example, in the form of an application specific integrated circuit or ASIC).

圖4例示依據本發明至少一實施例的編碼器的方塊圖。編碼器係為連接模組所表示,各個模組適用以例如以為裝置300的CPU 311所執行的規劃指令的形式來實施一方法的至少一對應步驟,該方法依據本發明之一或更多實施例,實施編碼一序列影像的一影像的至少一實施例。FIG. 4 illustrates a block diagram of an encoder according to at least one embodiment of the present invention. The encoder is represented by a connection module, and each module is suitable for implementing at least one corresponding step of a method in the form of planning instructions executed by the CPU 311 of the device 300, for example, according to one or more implementations of the present invention. For example, at least one embodiment implementing an image encoding a sequence of images.

原始序列數位影像i0至in 401係為編碼器400所接收作為輸入。各個數位影像係為稱為像素的一組取樣所表示。回想,一像素包含三個成分及一取樣指明其中之一。The original sequence digital images i0 to in 401 are received by the encoder 400 as input. Each digital image is represented by a set of samples called pixels. Recall that a pixel contains three components and a sample indicates one of them.

在實施編碼程序後,位元流410係為編碼器400所輸出。位元流410包含多數編碼單元或切片,各個切片包含切片檔頭及切片本體,切片檔頭用以傳輸用以編碼該切片的編碼參數的編碼值,該切片主體包含編碼視訊資料。After the encoding process is implemented, the bit stream 410 is output by the encoder 400. The bit stream 410 includes a plurality of coding units or slices. Each slice includes a slice file header and a slice body. The slice file header is used to transmit code values for coding parameters of the slice. The slice body includes coded video data.

輸入數位影像i0至in 401係被模組402所切割為像素方塊。方塊對應於影像部份並可以為可變尺寸(例如,4×4、8×8、16×16、32×32、64×64、128×128像素並且幾個長方方塊尺寸也可以被考慮)。各個輸入方塊的編碼模式可以被選擇。兩系列的編碼模式被提供:根據空間預測編碼(內(intra)預測)的編碼模式,及根據時間預測的編碼模式(間(inter)編碼、合併、跳過(SKIP))。可能編碼模式被測試。The input digital images i0 to in 401 are cut into pixel blocks by the module 402. The blocks correspond to the image part and can be of variable size (for example, 4×4, 8×8, 16×16, 32×32, 64×64, 128×128 pixels and several rectangular block sizes can also be considered ). The encoding mode of each input block can be selected. Two series of coding modes are provided: a coding mode based on spatial prediction coding (intra prediction), and a coding mode based on temporal prediction (inter coding, merge, skip (SKIP)). Maybe the coding mode is tested.

模組403實施內預測程序,其中予以編碼的給定方塊係為由該予以編碼的該方塊的相鄰像素所計算的預測子所預測。所選擇內預測子的指示及給定方塊與其預測子間之差係被編碼,以在如果內編碼被選擇時,提供殘值。The module 403 implements an intra-prediction process, in which a given block to be encoded is predicted by a predictor calculated by neighboring pixels of the block to be encoded. The indication of the selected intra-predictor and the difference between the given block and its predictor are coded to provide a residual value if the intra-coding is selected.

時間預測係為動作估計模組404及動作補償模組405所實施。首先,從一組參考影像/圖片416中選擇一參考影像/圖片,及該參考影像/圖片中也被稱為參考區域或影像部份的最接近予以編碼的給定方塊的區域的一部份係為動作估計模組404所選擇。動作補償模組405然後使用所選擇區域預測予以編碼的方塊。也稱為殘餘方塊的所選擇參考區域與給定方塊間之差係為動作補償模組405所計算。所選擇參考區域係為動作向量所指示。The time prediction is implemented by the motion estimation module 404 and the motion compensation module 405. First, a reference image/picture is selected from a set of reference images/pictures 416, and a portion of the reference image/picture that is also referred to as a reference area or image portion that is closest to the given block to be encoded It is selected by the motion estimation module 404. The motion compensation module 405 then uses the selected region to predict the block to be encoded. The difference between the selected reference area, also called the residual block, and the given block is calculated by the motion compensation module 405. The selected reference area is indicated by the motion vector.

因此,在兩情況中(空間及時間預測)中,殘值係藉由將原始方塊減去預測所計算。Therefore, in both cases (spatial and temporal prediction), the residual value is calculated by subtracting the original block from the prediction.

在為模組403所實施的內預測中,預測方向被編碼。在時間預測中,至少一動作向量被編碼。In the intra prediction implemented for the module 403, the prediction direction is coded. In temporal prediction, at least one motion vector is encoded.

如果間預測被選擇,則相關於動作向量與殘餘方塊的資訊係被編碼。為更進一步降低位元率,假設動作同質,則動作向量被有關於動作向量預測子的差所編碼。一組動作資訊預測子的動作向量預測子係由動作向量預測及編碼模組417從動作向量欄418取得。If inter prediction is selected, the information about the motion vector and the residual block is coded. In order to further reduce the bit rate, assuming that the actions are homogeneous, the action vector is encoded by the difference about the action vector predictor. The motion vector predictor of a set of motion information predictors is obtained from the motion vector field 418 by the motion vector prediction and encoding module 417.

編碼器400更包含選擇模組406,用以藉由應用例如碼率失真準則的編碼成本準則,而選擇編碼模式。為了更進一步降低冗餘,(例如DCT)轉換係為轉換模組407所施加至殘餘方塊,然後,所取得的轉換資料被量化模組408所量化及熵編碼模組409所熵編碼。最後,被編碼的現行方塊的被編碼殘餘方塊被插入位元流410中。The encoder 400 further includes a selection module 406 for selecting an encoding mode by applying an encoding cost criterion such as a rate distortion criterion. In order to further reduce redundancy, (for example, DCT) conversion is applied to the residual block by the conversion module 407, and then the obtained conversion data is quantized by the quantization module 408 and entropy encoded by the entropy encoding module 409. Finally, the encoded residual block of the encoded current block is inserted into the bit stream 410.

編碼器400也執行編碼影像的解碼,以產生後續影像的動作估計的參考影像。這使得接收位元流的編碼器及解碼器具有相同參考影像。去量化模組411執行量化資料的去量化,其後被逆轉換模組412所逆轉換。內預測模組413使用預測資訊以決定哪一預測子被用於給定方塊及動作補償模組414實際將模組412所取得的殘值加至由該組參考影像/圖片416所取得的參考區域。The encoder 400 also performs decoding of the encoded video to generate a reference video for subsequent motion estimation of the video. This allows the encoder and decoder receiving the bitstream to have the same reference image. The dequantization module 411 performs dequantization of the quantized data, and then is inversely converted by the inverse conversion module 412. The intra prediction module 413 uses prediction information to determine which predictor is used for a given block and the motion compensation module 414 actually adds the residual value obtained by the module 412 to the reference obtained by the set of reference images/pictures 416 area.

後濾波然後為模組415所施加,以過濾像素的重建畫框。在本發明之實施例中,SAO環路濾波器係被使用,其中,補償偏移係被施加至重建影像的重建像素的像素值上。Post-filtering is then applied by module 415 to filter the reconstructed frame of pixels. In an embodiment of the present invention, a SAO loop filter is used, in which a compensation offset is applied to the pixel values of the reconstructed pixels of the reconstructed image.

圖5為依據本發明至少一實施例的環路濾波程序的步驟流程圖。在初始步驟51中,編碼器產生全畫框的重建。再者,在步驟52中,解塊濾波器係被應用至此第一重建畫框,以在步驟53產生解塊重建畫框。解塊濾波器的目標為移除為殘餘量化及方塊動作補償或方塊內預測所產生的方塊假影(artifact)。這些假影在低位元率時是看得到並重要的。解塊濾波器操作以依據兩相鄰方塊的特徵,平順方塊邊界。各個方塊的編碼模式、用於殘餘編碼的量化參數、及在邊界的相鄰像素差係被列入考量。相同準則/分類被應用至所有畫框,並且,不必傳送額外資料。解塊濾波器藉由移除方塊假影而改良現行畫框的視覺品質,這也改良了用於後續畫框的動作估計及動作補償。確實,方塊假影的高頻被移除,並且,因此,這些高頻並不需要對隨後畫框的紋理殘餘補償。FIG. 5 is a flowchart of the steps of a loop filtering process according to at least one embodiment of the invention. In the initial step 51, the encoder generates a full frame reconstruction. Furthermore, in step 52, the deblocking filter is applied to this first reconstructed picture frame to generate a deblocked reconstructed picture frame in step 53. The goal of the deblocking filter is to remove block artifacts generated for residual quantization and block motion compensation or intra-block prediction. These artifacts are visible and important at low bit rates. The deblocking filter operates to smooth the boundary of the block according to the characteristics of two adjacent blocks. The coding mode of each block, the quantization parameter used for residual coding, and the adjacent pixel difference at the boundary are considered. The same criteria/category is applied to all frames, and no additional information needs to be sent. The deblocking filter improves the visual quality of the current frame by removing block artifacts, which also improves motion estimation and motion compensation for subsequent frames. Indeed, the high frequencies of the block artifacts are removed, and, therefore, these high frequencies do not require residual compensation for the texture of subsequent frames.

在解塊濾波器後,解塊重建畫框係在步驟54中為取樣自適應偏移(SAO)環路濾波器使用依據本發明實施例所決定的SAO參數所濾波。所得畫框55然後可以在步驟56中以適應環路濾波器(ALF)濾波,以產生重建畫框57,其將被顯示與使用給以下間畫框作為參考畫框。After the deblocking filter, the deblocking reconstruction frame is filtered in step 54 by using the SAO parameters determined according to the embodiment of the invention for the sample adaptive offset (SAO) loop filter. The resulting picture frame 55 can then be filtered with adaptive loop filter (ALF) in step 56 to produce a reconstructed picture frame 57 which will be displayed and used for the following picture frame as a reference picture frame.

在步驟54中,畫框區域的各個像素係被分類為一類或一群。相同偏移值被加至屬於某一類或群的各個像素值。In step 54, each pixel of the frame area is classified into a class or group. The same offset value is added to each pixel value belonging to a certain class or group.

在本發明之不同實施例中的取樣自適應偏移濾波的SAO參數的推導將如下參考圖12至38作更詳細解釋。The derivation of SAO parameters of the sample adaptive offset filtering in different embodiments of the present invention will be explained in more detail with reference to FIGS. 12 to 38 as follows.

圖6例示解碼器60的方塊圖,解碼器係可以被使用以自依據本發明實施例的編碼器接收資料。解碼器係以連接模組表示,各個模組被適用以例如以為裝置300的CPU 311所執行之程式指令的形式實施由解碼器60所實施的對應方法步驟。FIG. 6 illustrates a block diagram of a decoder 60. The decoder can be used to receive data from an encoder according to an embodiment of the present invention. The decoder is represented by connected modules, and each module is adapted to implement the corresponding method steps implemented by the decoder 60, for example, in the form of program instructions executed by the CPU 311 of the device 300.

解碼器60接收包含編碼單元的位元流61,各個編碼單元係由包含編碼參數的資訊的檔頭及包含編碼視訊資料的主體所構成。如同參考圖4所解釋,編碼視訊資料被熵編碼,及對於給定方塊而言,動作向量預測子索引被編碼於預定數目位元上。所接收編碼視訊資料為模組62所熵解碼。殘餘資料然後被模組63所去量化,然後,為模組64所執行逆轉換,以取得像素值。The decoder 60 receives a bit stream 61 including coding units, and each coding unit is composed of a header including information of coding parameters and a body including coding video data. As explained with reference to FIG. 4, the encoded video data is entropy encoded, and for a given block, the motion vector predictor index is encoded on a predetermined number of bits. The received encoded video data is entropy decoded by the module 62. The residual data is then dequantized by the module 63, and then inversely converted by the module 64 to obtain pixel values.

指示編碼模式的模式資料也被熵解碼並根據該模式,對影像資料的編碼方塊執行內(INTRA)型解碼或間(INTER)型解碼。The mode data indicating the encoding mode is also entropy decoded, and according to the mode, an INTRA type decoding or an INTER type decoding is performed on the encoding block of the image data.

在內模式中,內預測子係為內預測模組65根據在位元流中所指明的內預測模式加以決定。In the intra mode, the intra prediction sub-system is determined by the intra prediction module 65 according to the intra prediction mode specified in the bit stream.

如果模式為間,則動作預測資訊由該位元流抽出,以找出為編碼器所使用的參考區域。動作預測資訊由參考畫框索引及動作向量殘值所構成。動作向量預測子被加至動作向量殘值,以為動作向量解碼模組70所取得動作向量。If the mode is inter, the motion prediction information is extracted from the bit stream to find the reference area used by the encoder. The motion prediction information is composed of the reference frame index and the residual value of the motion vector. The motion vector predictor is added to the residual value of the motion vector to be the motion vector obtained by the motion vector decoding module 70.

動作向量解碼模組70對為動作預測所編碼的各個現行方塊施加動作向量解碼。一旦,用於現行方塊的動作向量預測子的索引已經取得,則與現行方塊有關的動作向量的實際值可以被解碼並被模組66所使用以執行動作補償。為解碼動作向量所指示的參考影像部係由參考影像68所抽出,以執行動作補償66。動作向量欄資料71被以解碼動作向量更新,以被用以作後續解碼動作向量的預測。The motion vector decoding module 70 applies motion vector decoding to each current block encoded for motion prediction. Once the index of the motion vector predictor for the current block has been obtained, the actual value of the motion vector related to the current block can be decoded and used by the module 66 to perform motion compensation. The reference video part indicated for decoding the motion vector is extracted from the reference video 68 to perform motion compensation 66. The motion vector column data 71 is updated with the decoded motion vector to be used for prediction of the subsequent decoded motion vector.

最後,取得解碼方塊。後濾波係為後濾波模組67所施加,其係類似於參考圖5所述地在編碼器所施加之後濾波模組815。解碼視訊信號69最後為解碼器60所提供。Finally, get the decoding block. The post filter is applied by the post filter module 67, which is similar to the filter module 815 after the encoder is applied as described with reference to FIG. The decoded video signal 69 is finally provided by the decoder 60.

相較於沒有資訊被傳送的解塊濾波器,SAO濾波的目標為藉由發送額外資料於位元流中,來改良重建畫框的品質。如上所述,各個像素被分類為預定類或群及相同偏移值係被加入至相同類/群的各個像素取樣。針對各個類,一偏移被編碼於位元流中。SAO環路濾波具有兩SAO型:邊緣偏移(EO)型及帶偏移(BO)型。邊緣偏移型的例子係示意例示於圖7A及7B中,及帶偏移型的例子係示意例示於圖8中。Compared to deblocking filters where no information is transmitted, the goal of SAO filtering is to improve the quality of the reconstructed frame by sending additional data in the bitstream. As described above, each pixel is classified into a predetermined class or group and the same offset value is added to each pixel sample of the same class/group. For each class, an offset is encoded in the bitstream. SAO loop filtering has two SAO types: edge offset (EO) type and band offset (BO) type. Examples of the edge shift type are schematically illustrated in FIGS. 7A and 7B, and examples of the band shift type are schematically illustrated in FIG. 8.

在HEVC中,SAO濾波係逐CTU地加以施加。在此情況中,執行SAO濾波所需的參數(SAO參數組)係被選擇用於在編碼器側的各個CTU並且在解碼器側,針對各個CTU,需要的參數被解碼及/或推導出來。這藉由立即處理各個CTU,而沒有在整個畫框處理中造成延遲,而提供容易編碼及解碼視訊序列的可能性。再者,當SAO濾波被致能時:依據針對各個分類的位元流中所傳送的相關參數,邊緣偏移型濾波器或帶偏移型濾波器中只有一個SAO型被使用。在HEVC中的SAO參數之一係為SAO型參數sao_type_idx,其指示針對該CTU,EO型、BO型或無SAO濾波係被選擇用於有關CTU。In HEVC, SAO filtering is applied on a CTU-by-CTU basis. In this case, the parameters required to perform SAO filtering (SAO parameter set) are selected for each CTU on the encoder side and on the decoder side, for each CTU, the required parameters are decoded and/or derived. This provides the possibility to easily encode and decode video sequences by processing each CTU immediately without causing a delay in the entire frame processing. Furthermore, when SAO filtering is enabled: according to the relevant parameters transmitted in the bitstream for each classification, only one SAO type of edge offset filter or band offset filter is used. One of the SAO parameters in HEVC is the SAO type parameter sao_type_idx, which indicates that for this CTU, the EO type, BO type, or SAO-free filtering system is selected for the relevant CTU.

對於給定CTU的SAO參數可以例如由上或左CTU拷貝,而不傳送所有的SAO資料。在HEVC中的SAO參數之一為sao_merge_up旗標,其設定時,表示主題CTU的SAO參數(除了sao_merge_up旗標以外)應由上CTU拷貝。在HEVC中的SAO參數的另一為sao_merge_left旗標,當其設定時,表示用於主題CTU的SAO參數應由左CTU拷貝。SAO parameters for a given CTU can be copied from the upper or left CTU, for example, without transmitting all SAO data. One of the SAO parameters in HEVC is the sao_merge_up flag. When it is set, the SAO parameters representing the subject CTU (except the sao_merge_up flag) should be copied by the upper CTU. The other of the SAO parameters in HEVC is the sao_merge_left flag. When it is set, it indicates that the SAO parameters used for the subject CTU should be copied by the left CTU.

SAO濾波可以個別地應用至畫框的不同顏色成分(例如,YUV)。例如,一組SAO參數可以提供用於亮度成分Y及另一組SAO參數可以共同被提供用於色度成分U與V兩者。同時,在該組SAO參數內,也可以使用一或更多SAO參數作為用於兩個或更多色彩成分的共同濾波參數,同時,其他SAO參數為用於色彩成分的專用(每成分)濾波參數。例如,在HEVC中,SAO型參數sao_type_idx為U及V所共用,並且,EO類參數也是如此,其表示用於EO濾波(見如下)的一類,而BO類參數,則表示用於BO濾波的一群分類的用於U及V的專用(每成分)SAO參數。SAO filtering can be individually applied to different color components of the picture frame (for example, YUV). For example, one set of SAO parameters may be provided for the luma component Y and another set of SAO parameters may be provided jointly for both the chroma components U and V. At the same time, within the set of SAO parameters, one or more SAO parameters can also be used as a common filtering parameter for two or more color components, while other SAO parameters are dedicated (per component) filtering for color components parameter. For example, in HEVC, the SAO type parameter sao_type_idx is shared by U and V, and the same is true for EO type parameters, which represent a type used for EO filtering (see below), and BO type parameters, which represent the type used for BO filtering A group of classified (per component) SAO parameters for U and V.

如圖10所述,當SAO型為邊緣型(603)時,偏移的符號為如圖7B所示隱式。因此,符號未讀取(610)。此隱式符號決定在HEVC標準化時被採用,因為,符號發信並不會改良SAO的編碼效率。在現行VTM軟體中,如果隱式符號為顯式符號所替換,如在初始版的HEVC中一般,可以看到編碼效率的降低。As shown in FIG. 10, when the SAO type is an edge type (603), the sign of the offset is implicit as shown in FIG. 7B. Therefore, the symbol is not read (610). This implicit symbol decision is adopted when HEVC is standardized, because the symbol transmission does not improve the coding efficiency of SAO. In the current VTM software, if the implicit symbols are replaced by explicit symbols, as in the original version of HEVC, you can see a reduction in coding efficiency.

HEVC中的邊緣偏移型的說明現參考圖7A及7B加以提供。A description of the edge shift type in HEVC is now provided with reference to FIGS. 7A and 7B.

邊緣偏移型涉及藉由將其像素值與兩相鄰像素的值作比較,而決定用於各個像素的邊緣索引。再者,這兩相鄰像素取決於一參數,其表示這兩相鄰像素相關於現行像素的方向。這些方向有0度(水平方向),45度(對角方向)、90度(垂直方向)及135度(第二對角方向)。這四個方向被示意於圖7A中。The edge shift type involves determining the edge index for each pixel by comparing its pixel value with the values of two adjacent pixels. Furthermore, the two adjacent pixels depend on a parameter, which indicates the direction of the two adjacent pixels relative to the current pixel. These directions are 0 degrees (horizontal direction), 45 degrees (diagonal direction), 90 degrees (vertical direction) and 135 degrees (second diagonal direction). These four directions are illustrated in Figure 7A.

圖7B的表給出依據在解碼器側的兩相鄰像素Cn1及Cn2的值,將要施加至特定像素“C”的像素值的偏移值。The table of FIG. 7B gives the offset value of the pixel value to be applied to the specific pixel "C" according to the values of two adjacent pixels Cn1 and Cn2 on the decoder side.

當C的值低於相鄰像素Cn1及Cn2的兩個值時,予以加至像素C的像素值的偏移為“+O1”。當C的像素值低於其相鄰像素(Cn1或Cn2)的一像素值及C等於其相鄰像素的一值時,予以加至此像素取樣值的偏移為“+O2”。When the value of C is lower than the two values of the adjacent pixels Cn1 and Cn2, the offset of the pixel value added to the pixel C is "+O1". When the pixel value of C is lower than a pixel value of its neighboring pixel (Cn1 or Cn2) and C is equal to a value of its neighboring pixel, the offset added to the sampling value of this pixel is "+O2".

當c的像素值低於相鄰像素(Cn1或Cn2)的像素值之一及C的像素值等於其相鄰像素的一值時,予以施加至像素取樣的偏移為“-O3”。當C的值大於Cn1或Cn2的兩值時,則予以應用至此像素取樣的偏移為“-O4”。When the pixel value of c is lower than one of the pixel values of the neighboring pixels (Cn1 or Cn2) and the pixel value of C is equal to a value of its neighboring pixels, the offset applied to the pixel sampling is "-O3". When the value of C is greater than the two values of Cn1 or Cn2, the offset applied to this pixel sample is "-O4".

當以上這些狀態都不符合現行取樣及其相鄰像素時,則沒有偏移值被增加至現行像素C,如同該表的邊緣索引值“2”所描繪。When none of the above states match the current sample and its neighboring pixels, no offset value is added to the current pixel C, as depicted by the edge index value "2" of the table.

重要的是,注意用於邊緣偏移型的特定情況中,各個偏移(O1、O2、O3、O4)的絕對值在位元流中被編碼。予以施加至各個偏移的符號係取決於現行像素所屬的邊緣索引(或在HEVC規格中的邊緣索引)。依據圖7B中所表示之表,對於邊緣索引0及對於邊緣索引1(O1、O2),施加正偏移。對於邊緣索引3及邊緣索引4(O3、O4),負偏移被應用至現行像素。It is important to note that in the specific case for the edge offset type, the absolute value of each offset (O1, O2, O3, O4) is encoded in the bitstream. The symbol to be applied to each offset depends on the edge index to which the current pixel belongs (or the edge index in the HEVC specification). According to the table shown in FIG. 7B, for edge index 0 and for edge index 1 (O1, O2), a positive offset is applied. For edge index 3 and edge index 4 (O3, O4), the negative offset is applied to the current pixel.

在HEVC規格中,邊緣偏移在圖7A的四個方向中的方向係被指明在位元流中,以“sao_eo_class_luma”欄表示亮度成分及“sao_se_class_chroma”欄表示色度成分U及V。In the HEVC specification, the direction of the edge shift among the four directions in FIG. 7A is indicated in the bit stream, and the "sao_eo_class_luma" column indicates the luminance component and the "sao_se_class_chroma" column indicates the chrominance components U and V.

對應於索引值的SAO邊緣索引係為以下公式所取得:EdgeIndex=sign(C-Cn2)-sign(Cn1-C)+2 其中函數sign(.)的定義係由以下關係給定: sign(x)=1,當x>0 sign(x)=-1,當x<0, sign(x)=0,當x=0。The SAO edge index corresponding to the index value is obtained by the following formula: EdgeIndex=sign(C-Cn2)-sign(Cn1-C)+2 The definition of the function sign(.) is given by the following relationship: sign(x)=1, when x>0 sign(x)=-1, when x<0, sign(x)=0, when x=0.

為了簡化針對各個像素的邊緣偏移決定,在C的像素值與兩相鄰像素Cn1及Cn2的像素值間之差可以為現行像素C與其相鄰所共享。的確,當使用現行CTU或畫框的像素的光域掃描順序而施加SAO邊緣偏移濾波時,項符號(Cn1-C)已經被計算用於先前像素(更精確地說,當現行像素C’在該時為現在相鄰像素Cn1及相鄰像素Cn2’為現在的現行像素C時,其被一次計算為C’-Cn2’)。結果,此符號(cn1-c)並不需被再次計算。To simplify the determination of the edge offset for each pixel, the difference between the pixel value of C and the pixel values of two adjacent pixels Cn1 and Cn2 can be shared by the current pixel C and its neighbors. Indeed, when the SAO edge offset filter is applied using the optical domain scanning order of the pixels of the current CTU or frame, the term symbol (Cn1-C) has been calculated for the previous pixel (more precisely, when the current pixel C' When the current adjacent pixel Cn1 and the adjacent pixel Cn2' are the current active pixel C at this time, it is calculated as C'-Cn2' at a time. As a result, this symbol (cn1-c) does not need to be calculated again.

帶偏移型的說明現將參考圖8加以提供。An explanation of the offset type will now be provided with reference to FIG. 8.

在SAO中的帶偏移型也取決於予以處理的取樣的像素值。在SAO帶偏移中的一類係被界定為一範圍像素值。傳統上,對於一範圍內的所有像素,相同偏移係被施加至像素值。在HEVC規格中,對於像素的各個重建方塊或畫框區域(CTU),用於帶偏移濾波器的偏移數目為四,如在圖8所示意。The band offset type in SAO also depends on the pixel value of the sample being processed. One type of SAO band offset is defined as a range of pixel values. Traditionally, for all pixels in a range, the same offset is applied to the pixel value. In the HEVC specification, for each reconstruction block or picture frame area (CTU) of a pixel, the number of offsets used for the band offset filter is four, as illustrated in FIG. 8.

SAO帶偏移的一實施法將全範圍像素值細分為相同尺寸的32個範圍。這32個範圍係為SAO帶偏移的帶(或類)。該範圍像素值的最小值為系統0及最大值係依據以下關係式Max=2位元深度 -1而取決於像素值的位元深度。將這些像素分類為32範圍的全區間包含5位元檢查,其係需要以分類用於快速實施法的像素值,即,只前5個位元(5最高效位元)係被檢查,以將像素分類成全範圍的32類/範圍之一。An implementation of SAO band offset subdivides the full range of pixel values into 32 ranges of the same size. These 32 ranges are SAO band offset bands (or classes). The minimum value of the pixel values in this range is system 0 and the maximum value depends on the bit depth of the pixel value according to the following relationship Max=2 bit depth -1. The full interval that classifies these pixels into 32 ranges contains a 5-bit check, which requires pixel values that are classified for fast implementation, that is, only the first 5 bits (5 most efficient bits) are checked to Classify pixels into one of 32 categories/ranges of the full range.

例如,當位元深度為每像素8位元時,一像素的最大值可以為255。因此,像素值的範圍為0至255之間。對於此8位元的位元深度,各個帶或類包含8個像素值。For example, when the bit depth is 8 bits per pixel, the maximum value of one pixel may be 255. Therefore, the range of pixel values is between 0 and 255. For this 8-bit bit depth, each band or class contains 8 pixel values.

依據HEVC規格,使用由灰色區域(40)所代表的一群40帶,該群具有四個連續帶41、42、43及44,並且,資訊係被發信於該位元流中,以指明該群的位置,例如該4個帶的第一個帶的位置。此位置的語法元件表示為在HEVC規格中之“sao_band_position”欄。此對應於在圖8中的帶41的開始。依據HEVC規格,分別代表對應於該四個帶的4個偏移被發信於位元流中。According to the HEVC specification, a group of 40 bands represented by the gray area (40) is used, the group has four consecutive bands 41, 42, 43, and 44, and the information system is sent in the bit stream to indicate the The position of the group, for example, the position of the first band of the four bands. The syntax element at this position is indicated in the "sao_band_position" column in the HEVC specification. This corresponds to the start of band 41 in FIG. 8. According to the HEVC specification, four offsets corresponding to the four bands are signaled in the bit stream.

圖9為依據HEVC規格的解碼SAO參數的程序步驟流程圖。圖9的程序被應用至每一CTU,以產生用於所有成分的一組SAO參數。為了避免每CTU編碼一組SAO參數(很耗成本),預測方案係被使用於CTU模式。此預測模式涉及檢查是否在現行CTU的左側上的CTU使用相同SAO參數(此係透過稱為“sao_merge_left_flag”的旗標所指明於位元流中)。如果不是,則針對現行CTU上的CTU執行第二檢查(此係透過稱為“sao_merge_up_flag”的旗標所指明於位元流中)。此預測技術使得代表用於CTU模式的SAO參數的資料量降低。程序的步驟係說明如下。FIG. 9 is a flowchart showing the procedure steps for decoding SAO parameters according to the HEVC specification. The procedure of FIG. 9 is applied to each CTU to generate a set of SAO parameters for all components. In order to avoid coding a set of SAO parameters per CTU (very expensive), the prediction scheme is used in the CTU mode. This prediction mode involves checking whether the CTU on the left side of the current CTU uses the same SAO parameters (this is indicated in the bitstream by a flag called "sao_merge_left_flag"). If not, a second check is performed on the CTU on the current CTU (this is indicated in the bitstream by a flag called "sao_merge_up_flag"). This prediction technique reduces the amount of data representing SAO parameters used in CTU mode. The steps of the program are described below.

在步驟503中,“sao_merge_left_flag”被由位元流502讀取並解碼。如果其值為真,則程序進行至步驟504,其中用於左CTU的SAO參數被拷貝用於現行CTU。這使得用於現行CTU的SAO濾波器的YUV的類型在步驟508中被決定。In step 503, "sao_merge_left_flag" is read and decoded by the bitstream 502. If its value is true, the procedure proceeds to step 504, where the SAO parameters for the left CTU are copied for the current CTU. This allows the type of YUV used for the SAO filter of the current CTU to be determined in step 508.

如果在步驟503中,結果為否,則 “sao_merge_up_flag”被由位元流讀出並解碼。如果其值為真,則程序進行至步驟505,其中上CTU的SAO參數被拷貝用於現行CTU。這使得用於現行CTU的SAO濾波器的類型在步驟508中決定。If in step 503 the result is no, then "Sao_merge_up_flag" is read out from the bit stream and decoded. If its value is true, the procedure proceeds to step 505, where the SAO parameters of the upper CTU are copied for the current CTU. This causes the type of SAO filter used for the current CTU to be determined in step 508.

如果在步驟505中,結果為否,則現行CTU的SAO參數係在步驟507中被由位元流讀出並解碼,用於亮度Y成分及兩U及V成分(501)(551)類型。色度的偏移為獨立的。If the result is no in step 505, the SAO parameters of the current CTU are read and decoded by the bit stream in step 507, and are used for the luminance Y component and the two U and V components (501) (551) type. The chromaticity shift is independent.

此步驟的細節隨後參考圖10加以描述。在此步驟後,參數被取得及SAO濾波器的類型係在步驟508中決定。The details of this step will be described later with reference to FIG. After this step, the parameters are obtained and the type of SAO filter is determined in step 508.

在後續步驟511中,執行是否現行CTU的三個色彩成分(Y及U&V)已經被處理的檢查。如果結果為是,則決定用於三成分的SAO參數已完成,並且下一CTU可以在步驟510中被處理。若否,(只有Y被處理)U及V被一起處理及程序由前述初始步驟512重新開始。In the subsequent step 511, a check is performed whether the three color components (Y and U&V) of the current CTU have been processed. If the result is yes, it is determined that the SAO parameters for the three components have been completed, and the next CTU may be processed in step 510. If not, (only Y is processed) U and V are processed together and the procedure restarts from the initial step 512 described above.

圖10為於解碼器側解析在位元流601中之SAO參數的程序步驟流程圖。在初始步驟602中, “sao_type_idx_X”語法元件被讀取及解碼。代表此語法元件的碼字元可以使用固定長度碼或可以使用任何算術編碼方法。語法元件sao_type_idx_X使得用於畫框區域的SAO的類型的決定被處理針對色彩成分Y或色度成分U&V兩者。例如,對於YUV 4:2:0序列,兩成分被考量:一個為用於Y,及一個為用於U及V。“sao_type_idx_X”可以如下取決於在位元流中所編碼的SAO型而採用3個值。‘0’對應於無SAO,‘1’對應於如圖8所示之帶偏移情況,及‘2’對應於圖3A及3B所示之邊緣偏移型濾波器。FIG. 10 is a flowchart showing the procedure of parsing the SAO parameters in the bit stream 601 on the decoder side. In the initial step 602, The "sao_type_idx_X" syntax element is read and decoded. The codeword representing this syntax element may use a fixed-length code or may use any arithmetic coding method. The syntax element sao_type_idx_X causes the decision of the type of SAO for the picture frame area to be processed for both the color component Y or the chroma component U&V. For example, for the YUV 4:2:0 sequence, two components are considered: one for Y and one for U and V. "Sao_type_idx_X" can take 3 values depending on the SAO type encoded in the bit stream as follows. '0' corresponds to no SAO, '1' corresponds to the band offset case shown in Fig. 8, and '2' corresponds to the edge offset type filter shown in Figs. 3A and 3B.

另外,雖然YUV色彩成分係被用於HEVC(有時稱為Y,Cr及Cb成分),但將了解的是,在其他視訊編碼方案中,也可以使用其他色彩成分,例如RGB色彩成分。本發明之技術並未限於與YUV色彩成分一起使用,並且,可以與RGB色彩成分或任何其他色彩成分一起使用。In addition, although YUV color components are used for HEVC (sometimes referred to as Y, Cr, and Cb components), it will be understood that other color components, such as RGB color components, can be used in other video encoding schemes. The technique of the present invention is not limited to use with YUV color components, and may be used with RGB color components or any other color components.

在相同步驟602中,執行測試以決定是否“sao_type_idx_X”嚴格為正。如果“sao_type_idx_X”等於“0”,表示如果X被設定為Y,對於Y的此畫框區域(CTU)沒有SAO,以及,如果X被設定為對於U及V,則對於U及V的此畫框區域沒有SAO。SAO參數的決定被完成及程序進行至步驟608。否則,如果“sao_type_idx”為嚴格為正,則此表示用於在位元流中之此CTU有SAO參數存在。In the same step 602, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that if X is set to Y, there is no SAO for this frame area (CTU) of Y, and, if X is set to U and V, then this picture for U and V There is no SAO in the box area. The determination of the SAO parameters is completed and the process proceeds to step 608. Otherwise, if "sao_type_idx" is strictly positive, this means that there is a SAO parameter for this CTU in the bitstream.

然後,處理進行至步驟606,其中環路係被執行四次疊代。該四次疊代係被執行於步驟607中,其中偏移j的絕對值被由位元流中讀取並解碼。此四個偏移對應於SAO邊緣偏移(見圖7B)的四個邊緣索引的偏移(O1、O2、O3及O4)的四個絕對值或者有關於SAO帶偏移(見圖8)的四個範圍的偏移的四個絕對值。Then, the process proceeds to step 606, where the loop system is executed four iterations. The fourth iteration is performed in step 607, where the absolute value of the offset j is read and decoded from the bit stream. These four offsets correspond to the four absolute values of the four edge index offsets (O1, O2, O3, and O4) of the SAO edge offset (see FIG. 7B) or are related to the SAO band offset (see FIG. 8) Four absolute values of the offset of the four ranges.

注意,對於SAO偏移的編碼,第一部係被傳送於對應於該偏移的絕對值的位元流中。此絕對值係以一元碼加以編碼。用於絕對值的最大值係由以下公式所給定:

Figure 02_image001
其中<<為左(位元)移位運算子。Note that for the encoding of the SAO offset, the first part is transmitted in the bit stream corresponding to the absolute value of the offset. This absolute value is encoded with a unary code. The maximum value used for the absolute value is given by the following formula:
Figure 02_image001
Where << is the left (bit) shift operator.

此公式表示對於8位元的像素值位元深度而言,偏移的最大絕對值為7,及對於10位元及以上的像素值位元深度的則為31。This formula means that for 8-bit pixel value bit depth, the maximum absolute value of the offset is 7, and for 10-bit and above pixel value bit depth is 31.

針對延伸位元深度視訊序列的現行HEVC標準修正對於具有12位元及以上的位元深度的像素值,提供類似的公式。所解碼的絕對值可以是一量化值,其在被應用至在解碼器的像素值作SAO濾波之前,先去量化。此量化的使用與否的指示係被傳送於切片檔頭中。The current HEVC standard modification for extended bit depth video sequences provides a similar formula for pixel values with a bit depth of 12 bits and above. The decoded absolute value may be a quantized value, which is dequantized before being applied to the pixel value at the decoder for SAO filtering. The indication of the use of this quantization is transmitted in the slice header.

對於邊緣偏移型,只有絕對值被傳送,因為符號可以被如前所述地推想。For the edge-offset type, only the absolute value is transmitted because the symbol can be inferred as described above.

對於帶偏移型,如果偏移的絕對值不等於0,則符號被發信於位元流中作為偏移的第二部。當CABAC被使用時,符號的位元被略過。For the offset type, if the absolute value of the offset is not equal to 0, the symbol is sent in the bit stream as the second part of the offset. When CABAC is used, the sign bit is skipped.

在步驟607後,程序進行至步驟603,其中執行測試以決定是否SAO的類型對應於帶偏移型 (sao_type_idx_X==1)。After step 607, the process proceeds to step 603, where a test is performed to determine whether the type of SAO corresponds to the band offset type (sao_type_idx_X==1).

如果結果為正,除非各個偏移具有零值外,否則在以下步驟604執行之前,用於帶偏移模式的偏移的符號將在步驟609及610中被解碼,以在位元流中讀取並解碼如圖8所示的SAO帶的位置“aso_band_position_X”。If the result is positive, the symbols used for the offset with offset mode will be decoded in steps 609 and 610 to be read in the bit stream before the following steps 604 are executed unless each offset has a value of zero. Take and decode the position "aso_band_position_X" of the SAO band as shown in FIG.

如果在步驟603中,結果為負 (“aso_type_idx_X”被設定等於2),這表示使用邊緣偏移型。因此,邊緣偏移類(對應於方向0、45、90及135度)係在步驟605中由位元流601抽出。如果X等於Y,則讀取語法元件為“sao_eo_class_luma”及如果X被設定為U及V,則讀取語法元件為“sao_eo_class_chroma”。If in step 603, the result is negative ("Aso_type_idx_X" is set equal to 2), which means that the edge offset type is used. Therefore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream 601 in step 605. If X is equal to Y, the read syntax element is "sao_eo_class_luma" and if X is set to U and V, the read syntax element is "sao_eo_class_chroma".

當四個偏移已經被解碼,SAO參數的讀取完成及程序進行至步驟608。When the four offsets have been decoded, the reading of the SAO parameters is completed and the process proceeds to step 608.

圖11為依據HEVC規格如何於影像部上執行SAO濾波的流程圖,例如,在圖6的步驟67期間。在HEVC中,此影像部為CTU。相同程序700也被應用至在編碼器的解碼環路(圖4中之步驟415)中,以產生用於以下畫框的動作評估及補償的參考畫框。此程序係有關於一色彩成分的SAO濾波(因此,在語法元件中之下標“_X”已經在以下省略)。FIG. 11 is a flowchart of how to perform SAO filtering on the video part according to the HEVC specification, for example, during step 67 of FIG. 6. In HEVC, this video part is CTU. The same procedure 700 is also applied to the decoding loop of the encoder (step 415 in FIG. 4) to generate reference frames for motion evaluation and compensation of the following frames. This program is related to SAO filtering of a color component (hence, the subscript "_X" in the syntax element has been omitted below).

初始步驟701包含依據在圖9及10所描述的程序決定SAO濾波參數。SAO濾波參數係為編碼器所決定及所編碼SAO參數被包含在位元流中。因此,在步驟701中,在解碼器側,解碼器讀取並解碼來自位元流的參數。步驟701取得sao_type_idx並且如果它等於1,步驟701也取得sao_band_position 702及如果它等於2,步驟701也(依據所處理的色彩成分)取得sao_eo_class_luma或 sao_eo_class_chroma。如果元件sao_type_idx等於0,則並未施加SAO濾波。步驟701也取得該4個偏移的偏移表703。The initial step 701 includes determining the SAO filtering parameters according to the procedures described in FIGS. 9 and 10. The SAO filtering parameters are determined by the encoder and the encoded SAO parameters are included in the bitstream. Therefore, in step 701, on the decoder side, the decoder reads and decodes the parameters from the bitstream. Step 701 obtains sao_type_idx and if it is equal to 1, step 701 also obtains sao_band_position 702 and if it is equal to 2, step 701 also obtains sao_eo_class_luma (depending on the color component being processed) or sao_eo_class_chroma. If the element sao_type_idx is equal to 0, no SAO filtering is applied. Step 701 also obtains the offset table 703 for the four offsets.

用於連續考量現行方塊或畫框區域(CTU)的每一像素Pi的變數i在步驟704中被設定為0。順便一提,“畫框區域”及“影像區域”在本說明書中被交換地使用。在此例子中,畫框區域為在HEVC標準中之CTU。在步驟706中,像素Pi 係由包含N像素的畫框區域705抽出。此像素Pi 係在步驟707中依據參考圖7A及7B所述的邊緣偏移分類或者參考圖8所述的帶偏移分類加以分類。決定模組708測試,Pi 是否予以被使用傳統SAO濾波加以濾波的一類。The variable i used to continuously consider each pixel Pi of the current block or frame area (CTU) is set to 0 in step 704. Incidentally, "frame area" and "image area" are used interchangeably in this manual. In this example, the frame area is the CTU in the HEVC standard. In step 706, the pixel P i is extracted from the frame area 705 containing N pixels. This pixel P i is classified in step 707 according to the edge offset classification described with reference to FIGS. 7A and 7B or the band offset classification described with reference to FIG. 8. The decision module 708 tests whether Pi is to be filtered using traditional SAO filtering.

如果Pi 為濾波類,則相關類數目j被識別及相關偏移值Offsetj 係在步驟710中由偏移表703抽出。於傳統SAO濾波中,此Offsetj 然後在步驟711中被加至像素值Pi ,以產生濾波像素值

Figure 02_image003
712。此濾波像素值
Figure 02_image003
在步驟713中被插入濾波畫框區域716中。If P i is a filtering class, the number of related classes j is identified and the related offset value Offset j is extracted from the offset table 703 in step 710. In traditional SAO filtering, this Offset j is then added to the pixel value P i in step 711 to generate a filtered pixel value
Figure 02_image003
712. This filtered pixel value
Figure 02_image003
In step 713, it is inserted into the filtered frame area 716.

如果Pi 並不是在要被SAO濾波的一類中,則Pi (709)在步驟713中被插入濾波畫框區域716中,而沒有濾波。If P i is not in the category to be filtered by SAO, then P i (709) is inserted into the filtered frame area 716 in step 713 without filtering.

在步驟713後,變數i在步驟714中增量,以濾波現行畫框區域705的後續像素(如果有-測試715)。在步驟715中,所有像素都被處理後(i>=N),則濾波畫框區域716被重建並可以被加至SAO重建畫框(見圖6的畫框68或圖4的畫框416)。After step 713, the variable i is incremented in step 714 to filter subsequent pixels of the current frame area 705 (if any-test 715). In step 715, after all pixels have been processed (i>=N), the filtered frame area 716 is reconstructed and can be added to the SAO reconstruction frame (see frame 68 in FIG. 6 or frame 416 in FIG. 4) ).

如上所提,用於未來VVC標準的JVET探索模型(JEM)使用所有HEVC工具。這些工具之一為取樣自適應偏移(SAO)濾波。然而,在JEM參考軟體中的SAO係比在HEVC參考軟體中者沒效率。這造成更少的評估及相較於其他環路濾波器的發信效率低。As mentioned above, the JVET exploration model (JEM) for the future VVC standard uses all HEVC tools. One of these tools is sample adaptive offset (SAO) filtering. However, the SAO in the JEM reference software is less efficient than the HEVC reference software. This results in fewer evaluations and lower signal transmission efficiency compared to other loop filters.

以下所述之本發明實施例係想要藉由使用各種技術來改良SAO的編碼效率,用以由在參考影像中之並列影像部的一或更多SAO參數,推導出在現行影像中之影像部的一或更多SAO參數。這些技術可以稱為用於SAO參數的時間推導技術。以下所述之進一步實施例想要藉由使用各種技術來改良SAO的編碼效率,用以由一影像的一影像部的一或更多SAO參數推導出在同一影像中之另一影像部的一或更多SAO參數。這些技術可以被稱為用於SAO參數的空間推導技術。The embodiments of the present invention described below are intended to improve the coding efficiency of SAO by using various techniques to derive the image in the current image from one or more SAO parameters of the parallel image portion in the reference image One or more SAO parameters. These techniques can be referred to as time derivation techniques for SAO parameters. The further embodiments described below are intended to improve the coding efficiency of SAO by using various techniques to derive one or more SAO parameters of one image part of an image from another image part of the same image. Or more SAO parameters. These techniques can be referred to as spatial derivation techniques for SAO parameters.

圖12為例示由編碼器所執行以決定用於一群(畫框或切片)CTU的SAO參數的步驟的流程圖。程序以現行CTU開始(1101)。首先,所有可能SAO型與類的統計被累積於變數CTUStats(1102)中。步驟1102的程序將如下參考圖13加以描述。依據在變數CTUStats中的值組中,如果左CTU係在現行切片中,則評估SAO左併的RD成本(1103),反之則評估用於SAO上併的RD成本(1104)。由於在CTUStats(1102)中之統計,新SAO參數係被評估用於亮度成分(1105)及兩色度成分(1109)。(兩色度成分,因為在HEVC標準中,色度成分共用相同SAO型)。對於各個SAO型(1106),最佳RD偏移及用於帶偏移分類的其他參數被取得(1107)。步驟1107及1110係被分別參考圖14及15針對邊緣及帶分類加以解釋如下。由於其個別SAO參數,所有RD成本被計算(1108)。對於兩色度成分,用相同方式選擇最佳RD偏移及參數(1111)。所有此RD成本係被比較,以選擇最佳SAO參數組(1115)。這些RD成本也被比較,以針對亮度與色度成分(1113,1114),獨立地解除SAO。新SAO參數組的使用(1115)係與來自左及上CTU的SAO參數組“合併”或共享(1116)作比較。FIG. 12 is a flowchart illustrating the steps performed by the encoder to determine the SAO parameters for a group (frame or slice) of CTUs. The procedure starts with the current CTU (1101). First, the statistics of all possible SAO types and classes are accumulated in the variable CTUStats (1102). The procedure of step 1102 will be described with reference to FIG. 13 as follows. According to the value group in the variable CTUStats, if the left CTU is in the current slice, the RD cost of the SAO left merge is evaluated (1103), otherwise, the RD cost for the SAO merge is evaluated (1104). Due to the statistics in CTUStats (1102), the new SAO parameters were evaluated for the luma component (1105) and the dichromatic component (1109). (Two chroma components, because in the HEVC standard, chroma components share the same SAO type). For each SAO type (1106), the best RD offset and other parameters for band offset classification are obtained (1107). Steps 1107 and 1110 are explained below with reference to FIGS. 14 and 15 for edge and band classification, respectively. Due to its individual SAO parameters, all RD costs are calculated (1108). For the two chroma components, the best RD offset and parameters are selected in the same way (1111). All this RD cost is compared to select the best SAO parameter set (1115). These RD costs are also compared to independently remove SAO for luminance and chrominance components (1113, 1114). The use of the new SAO parameter set (1115) is compared with the SAO parameter set "merging" or sharing (1116) from the left and upper CTU.

圖13為流程圖,例示出當傳統SAO濾波時,在編碼器側計算的統計可以被應用至邊緣偏移型濾波器的例子的步驟。類似方式也可以使用於帶偏移型濾波器。FIG. 13 is a flowchart illustrating steps of an example in which statistics calculated on the encoder side can be applied to an edge offset type filter when conventional SAO filtering is performed. A similar method can also be used for band offset filters.

圖13例示包含推導各個類的各個最佳碼率失真偏移所需的所有資訊的變數CTUStats的設定。再者,其例示用於現行CTU的最佳SAO參數組的選擇。對於各個色彩成分Y、U、V(或RGB)(811),各個SAO型被評估。對於各個SAO型(812),變數Sumj SumNbPixj 在初始步驟801中被設定為零。現行畫框區域803包含N個像素。j為現行範圍數,用以決定四個偏移(有關於用於邊緣偏移型的圖7B中所示之四個邊緣索引或者用於帶偏移型的圖8所示之像素值的32範圍)。Sumj 為在範圍j中之像素與其原始像素間之差的總和。SumNbPixj 為在畫框區域中之像素數目及其像素值屬於範圍j。FIG. 13 illustrates the setting of the variable CTUStats that contains all the information necessary to derive each optimal rate distortion offset for each class. Furthermore, it illustrates the selection of the best SAO parameter set for the current CTU. For each color component Y, U, V (or RGB) (811), each SAO type is evaluated. For each SAO type (812), the variables Sum j and SumNbPix j are set to zero in the initial step 801. The current picture frame area 803 contains N pixels. j is the current range number used to determine the four offsets (there are four edge indexes shown in FIG. 7B for the edge offset type or 32 for the pixel values shown in FIG. 8 with the offset type range). Sum j is the sum of the differences between the pixels in the range j and their original pixels. SumNbPix j is the number of pixels in the frame area and their pixel values belong to the range j.

在步驟802中,用以連續考量現行畫框區域的各個像素Pi的變數i係被設定為零。然後,畫框區域803的第一像素Pi 在步驟804中被抽出。在步驟805中,現行像素的類係藉由檢查在圖7B中定義的狀態而決定。然後,在步驟805中執行一測試。在步驟805期間,執行檢查以決定像素值Pi 的類是否對應於圖7B的值“以上皆非”。In step 802, the variable i used to continuously consider each pixel Pi of the current frame area is set to zero. Then, the first pixel P i of the picture frame area 803 is extracted in step 804. In step 805, the type of current pixel is determined by checking the state defined in FIG. 7B. Then, in step 805, a test is performed. During step 805, a check is performed to determine the class of the pixel values P i value corresponds to FIG. 7B "None of the above."

如果結果為正,則值“i”在步驟808中增量,以考量畫框區域803的後續像素。If the result is positive, the value "i" is incremented in step 808 to consider subsequent pixels of the frame area 803.

否則,如果在步驟806中結果為負,則下一步驟為807,其中,相關SumNbPixj (即,該類的像素數目的總和在步驟805中決定)被增量及在Pi 及其原始值

Figure 02_image006
間的差被加至Sumj 。在下一步驟808中,變數i被增量,以考量畫框區域803的後續像素。Otherwise, if the result is negative in step 806, the next step is 807, where the related SumNbPix j (ie, the sum of the number of pixels of this class is determined in step 805) is incremented and the original value of P i
Figure 02_image006
The difference between is added to Sum j . In the next step 808, the variable i is incremented to consider the subsequent pixels of the frame area 803.

然後,執行一測試,以決定是否所有像素已經被考量及分類。如果結果為負,則程序環路回到上述步驟804。否則,如果結果為正,則程序進行至步驟810,其中用於現行色彩成分X及SAO型SAO_type與現行類j的變數CTUStats對於第一值被設定等於Sumj ,對於第二值係被設定等於SumNbPixj 。這些變數可以被用以計算例如各個類j的最佳偏移參數Offsetj 。此偏移Offsetj 可以是在類j的像素與其原始值間之差的平均。因此,Offsetj 係由以下公式所給定:

Figure 02_image008
Then, a test is performed to determine whether all pixels have been considered and classified. If the result is negative, the program loops back to step 804 above. Otherwise, if the result is positive, the process proceeds to step 810, where the variables CTUStats for the current color component X and the SAO type SAO_type and the current class j are set equal to Sum j for the first value and equal to Sum j for the second value SumNbPix j . These variables can be used to calculate the optimal offset parameter Offset j for each class j, for example. This offset Offset j may be the average of the difference between pixels of class j and their original values. Therefore, Offset j is given by the following formula:
Figure 02_image008

注意偏移Offsetj 為整數值。因此,在此公式中所定義為碼率可以被捨入至最近值或者使用天花板或地板函數。Note that Offset j is an integer value. Therefore, the bit rate defined in this formula can be rounded to the nearest value or use the ceiling or floor function.

以失真表示,各個偏移Offsetj 為最佳偏移Ooptj。In terms of distortion, each offset Offset j is the optimal offset Ooptj.

為了評估用於合併SAO參數的RD成本,編碼器使用在表CTUCStats中的統計集。依據用於SAO左併並考量用於Luma Left_Type_Y的類型及四個相關偏移O_Left_0、O_Left_1、O_Left_2、O_Left_3,失真可以藉由以下公式所取得:

Figure 02_image010
To evaluate the RD cost for combining SAO parameters, the encoder uses the statistical set in the table CTUCStats. According to the type used for SAO left and considering the type used for Luma Left_Type_Y and the four related offsets O_Left_0, O_Left_1, O_Left_2, O_Left_3, the distortion can be obtained by the following formula:
Figure 02_image010

變數Shift係被設計用於失真調整。當SAO為後濾波時,失真應為負。The variable Shift system is designed for distortion adjustment. When SAO is post-filtering, the distortion should be negative.

相同計算被應用至色度成分。碼率失真成本的λ(Lambda)對於這三個成分是固定的。對於合併有左CTU的SAO參數,該碼率只有1旗標,其被CABAC編碼。The same calculation is applied to the chroma component. The rate distortion cost λ (Lambda) is fixed for these three components. For SAO parameters incorporating a left CTU, the code rate is only 1 flag, which is CABAC encoded.

例示於圖14的編碼程序被應用以找出以碼率失真準測表示的最佳偏移,偏移被稱為ORDj。此程序被應用在步驟1109至1112中。The coding procedure exemplified in FIG. 14 is applied to find the best offset expressed in terms of rate distortion criterion, and the offset is called ORDj. This procedure is applied in steps 1109 to 1112.

在圖14的編碼程序的初始步驟901中,碼率失真值Jj被初始化至最大可能值。然後,一個由Ooptj到0的Oj的環路在步驟902中被應用。注意,Oj在環路的每個新疊代被修改1。如果Ooptj為負,則值Oj被增量並且如果Ootpj為正,則值Oj被減量。有關於Oj的碼率失真成本係在步驟903中依據以下公式加以計算:

Figure 02_image012
其中λ為拉格朗日(Lagrange)參數及R(Oj)為一函數,其提供有關Oj的碼字元所需的位元數目。In the initial step 901 of the encoding procedure of FIG. 14, the rate distortion value Jj is initialized to the maximum possible value. Then, a loop of Oj from Ooptj to 0 is applied in step 902. Note that Oj is modified by 1 for each new iteration of the loop. If Ooptj is negative, the value Oj is incremented and if Ootpj is positive, the value Oj is decremented. The rate distortion cost for Oj is calculated in step 903 according to the following formula:
Figure 02_image012
Where λ is the Lagrange parameter and R(Oj) is a function, which provides the number of bits required for the codeword of Oj.

公式‘SumNbPixj×Oj×Oj-Sumj×Oj×2’給出依據由使用偏移Oj所提供的失真表示的改良。如果J(Oj)比Jj小,則在步驟904中,Jj=J(Oj)及ORDj等於Oj。如果在步驟905中,Oj等於0,則環路結束及用於類j的最佳ORDj被選擇。The formula'SumNbPixj×Oj×Oj-Sumj×Oj×2' gives an improvement based on the distortion representation provided by using the offset Oj. If J(Oj) is smaller than Jj, then in step 904, Jj=J(Oj) and ORDj is equal to Oj. If in step 905, Oj is equal to 0, the loop ends and the best ORDj for class j is selected.

圖18及19的演算法提供用於各個類j的最佳ORDj。此演算法係針對圖7A的四個方向的每一個加以重複。然後,提供最佳碼率失真成本(用於各方向的Jj的總和)的方向係被選擇作為予以用於現行CTU的方向。The algorithms of Figures 18 and 19 provide the best ORDj for each class j. This algorithm is repeated for each of the four directions of FIG. 7A. Then, the direction system that provides the best rate distortion cost (sum of Jj for each direction) is selected as the direction to be used for the current CTU.

為邊緣偏移工具的編碼器側所選擇偏移值(圖18及19)的演算法可以輕易應用至帶偏移濾波器,以選擇最佳位置(SAO_band_position),其中j為區間[0,32]而不是圖13中的區間[1,4]。它涉及將在模組801、810、811中之值4改變為32。更明確地說,對於圖8的32類,計算參數Sumj(j=[0,32])。此相當於計算每一範圍j、現行像素值(Pi)與其原始值(Porgi)間之差、及屬於單一範圍j的影像的各個像素。然後,使用如圖14所述的相同程序,計算用於32類的依據碼率失真ORDj的最佳偏移。The algorithm for the selected offset value (Figures 18 and 19) for the encoder side of the edge offset tool can be easily applied to the band offset filter to select the best position (SAO_band_position), where j is the interval [0,32 ] Instead of the interval [1,4] in Figure 13. It involves changing the value 4 in modules 801, 810, 811 to 32. More specifically, for the 32 categories in FIG. 8, the parameter Sumj (j=[0,32]) is calculated. This is equivalent to calculating each range j, the difference between the current pixel value (Pi) and its original value (Porgi), and each pixel of the image belonging to a single range j. Then, using the same procedure as described in FIG. 14, the optimal offset according to the rate-distortion ORDj for 32 classes is calculated.

下一步驟涉及尋找圖8的SAO帶位置的最佳位置。這是以圖15中所述之編碼程序加以決定。用於各個範圍的RD成本Jj已經根據碼率失真用最佳偏移ORDj以圖14的編碼程序加以計算。在圖15中,在初始步驟1001中,碼率失真值J被初始化為最大可能值。然後,四個連續類的28個位置j上的環路被執行於步驟1002中。再者,在步驟1003中,對應於(4個連續類的)帶的RD成本的變數Jj被初始化為0。然後,在四個連續偏移j的環路被執行於步驟1004中。在步驟1005中,Jj係為四類Jj的RD成本所增量(j=i至i+4)。The next step involves finding the best position for the SAO band position of Figure 8. This is determined by the coding procedure described in Figure 15. The RD cost Jj for each range has been calculated with the coding procedure of FIG. 14 using the optimal offset ORDj based on the rate distortion. In FIG. 15, in the initial step 1001, the rate distortion value J is initialized to the maximum possible value. Then, a loop at 28 positions j of four consecutive classes is executed in step 1002. Furthermore, in step 1003, the variable Jj corresponding to the RD cost of the (4 consecutive classes) band is initialized to zero. Then, four loops of successive offset j are executed in step 1004. In step 1005, Jj is incremented by the RD cost of four types of Jj (j=i to i+4).

如果此成本Ji低於最佳RD成本J,則J被設定為Ji,及在步驟1007中,sao_band_postion=i,及下一步驟為步驟1008。If this cost Ji is lower than the optimal RD cost J, then J is set to Ji, and in step 1007, sao_band_postion=i, and the next step is step 1008.

否則,下一步驟為步驟1008。Otherwise, the next step is step 1008.

在文件JVET-J0024中,提議修改SAO邊緣分類。下表例示新提議SAO邊緣分類。

Figure 02_image014
In the document JVET-J0024, it is proposed to modify the SAO edge classification. The following table illustrates the newly proposed SAO edge classification.
Figure 02_image014

在此表中,c為在圖7A及圖7B中的取樣c的值,a為對應於圖7A及圖7B中之Cn1的“左”取樣的值,及b為對應於圖7A及圖7B中之Cn1的“右”取樣的值。符號&&為運算子和(AND)。符號‖為運算子或(OR)。In this table, c is the value of sample c in FIGS. 7A and 7B, a is the value of the “left” sample corresponding to Cn1 in FIGS. 7A and 7B, and b is the value corresponding to FIGS. 7A and 7B The value of the "right" sample of Cn1. The symbol && is the operator AND. The symbol ‖ is the operator or (OR).

如果此提議修改與在下表中所提供之HEVC的SAO邊緣偏移分類相較,修改只是符號函數計算的修正。

Figure 02_image016
If this proposed modification is compared with the SAO edge offset classification of HEVC provided in the following table, the modification is only a modification of the sign function calculation.
Figure 02_image016

確實,為了取得由公式邊緣索引Edgelndex =sign(C-Cn2)-sign(Cn1-C)+2所給的邊緣索引值,符號函數係為以下公式所修改:

Figure 02_image018
其中函數sign(.)的定義由以下關係式所給定: sign(val)=-1,如果“val”<-3 sign(val)=0,如果-3=“val”<=3 sign(val)=+1,如果“val”>3。Indeed, in order to obtain the edge index value given by the formula edge index Edgelndex =sign(C-Cn2)-sign(Cn1-C)+2, the sign function is modified by the following formula:
Figure 02_image018
The definition of the function sign(.) is given by the following relationship: sign(val)=-1, if "val"<-3 sign(val)=0, if -3="val"<=3 sign( val)=+1, if "val">3.

並且,其中“test?val1:val2”為三元運算子。變數“test”為狀態,如果“test”為真,則“val1”為返回之值,如果“test”為假,則“val2”為返回之值。And, where "test?val1:val2" is a ternary operator. The variable "test" is the status. If "test" is true, then "val1" is the returned value. If "test" is false, then "val2" is the returned value.

不好的是,此方法並未改良對於所有編碼架構的VTM軟體的編碼效率。對於隨機存取及內,所取得增益係低於0.1%,對於低延遲B畫框,此方法提供具有VTM軟體的測試狀態的平均損失。可能可以改良的唯一架構為低延遲P架構。Unfortunately, this method does not improve the coding efficiency of VTM software for all coding architectures. For random access and internal, the gain obtained is less than 0.1%. For low-latency B frame, this method provides the average loss of test status with VTM software. The only architecture that may be improved is the low-latency P architecture.

第一群實施例(第一態樣)First group of embodiments (first aspect)

依據本發明第一態樣,其中提供一種取得邊緣偏移的方法,以執行取樣自適應偏移(SAO)濾波,其中,“符號”參數N係被發信以用於決定該偏移的索引。According to the first aspect of the present invention, a method for obtaining an edge offset is provided to perform sample adaptive offset (SAO) filtering, wherein the "symbol" parameter N is sent to determine the index of the offset .

換句話說,此第一態樣有關於對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得邊緣偏移,以執行SAO濾波; 使用用以決定該邊緣偏移的索引的預定符號方法,對該影像的至少一像素施加邊緣偏移分類; 預定用以決定該邊緣偏移的索引的符號方法; 其中預定符號方法係被發信於位元流中。In other words, this first aspect relates to a method of performing sample adaptive offset (SAO) filtering on an image including a majority of image parts. The method includes: Get the edge offset to perform SAO filtering; Using a predetermined symbol method to determine the index of the edge offset, applying an edge offset classification to at least one pixel of the image; The symbol method predetermined to determine the index of the edge offset; The predetermined symbol method is sent in the bit stream.

依據此第一態樣,編碼器在多數可能符號方法中選擇一符號方法。最佳符號方法被發信於位元流中,使得解碼器以此選擇符號方法應用相關邊緣偏移分類。According to this first aspect, the encoder selects a symbol method among the most possible symbol methods. The best symbol method is signaled in the bitstream, so that the decoder applies the relevant edge offset classification in this symbol selection method.

定義一符號方法有幾個可能性。可能性之一可以界定符號函數“sign”,其考量對應於該限定值的數目N。此符號函數可以例如由以下公式所給定: SignN(val,N)=(val<-N?-1:(val>N?1:0)) 其中函數signN(.,.)的定義可以由以下關係式給定: signN(val,N)=-1,如果“val”<-N, signN(val,N)=0,如果-N<=“val”<=N, signN(val,N)=+1,如果“val”>N。There are several possibilities to define a symbolic method. One of the possibilities may define the sign function "sign", whose consideration corresponds to the number N of this limit value. This symbolic function can be given, for example, by the following formula: SignN(val,N)=(val<-N?-1: (val>N?1:0)) The definition of the function signN(.,.) can be given by the following relationship: signN(val,N)=-1, if "val"<-N, signN(val,N)=0, if -N <= "val" <=N, signN(val,N)=+1, if "val">N.

在此時,SAO邊緣偏移分類的邊緣索引可以依據以下公式加以取得: 邊緣索引=signN(C-Cn2,N)-signN(C-Cn2,N)+2At this time, the edge index of the SAO edge offset classification can be obtained according to the following formula: Edge index=signN(C-Cn2,N)-signN(C-Cn2,N)+2

並且,因此SAO邊緣分類可以變成:

Figure 02_image020
And, the SAO edge classification can become:
Figure 02_image020

此實施例的優點可以是相較於傳統HEVC邊緣偏移分類,該編碼效率增加。因此,此第一實施例係先前技藝更富彈性。由此第一實施例所提供的編碼效率增加係由於額外彈性,該彈性係適用於量化誤差與視訊內容。The advantage of this embodiment may be that the coding efficiency is increased compared to traditional HEVC edge offset classification. Therefore, this first embodiment is more flexible in the prior art. Therefore, the increase in coding efficiency provided by the first embodiment is due to additional flexibility, which is suitable for quantization errors and video content.

函數signN只是一實施方式例子,及另一可能性可以保有與HEVC定義相同的符號函數並將輸入值“val”除以數目N。在此例子中,SAO邊緣偏移分類的邊緣索引可以依據以下公式加以取得: 邊緣索引=sign((C-Cn2)/N)-sign((C-Cn2)/N)+2。The function signN is just an example of an implementation, and another possibility may hold the same sign function as defined by HEVC and divide the input value "val" by the number N. In this example, the edge index of the SAO edge offset classification can be obtained according to the following formula: Edge index=sign((C-Cn2)/N)-sign((C-Cn2)/N)+2.

依據其他實施例,熟習於本技藝者可以藉由以乘法及如下的位移來改變此除法: 邊緣索引=sign(((C-Cn2)*R)>>L)-sign(((C-Cn2)*R)>>L)+2 其中R及L由N值推導出。According to other embodiments, those skilled in the art can change this division by multiplication and the following displacements: Edge index=sign(((C-Cn2)*R)>>L)-sign(((C-Cn2)*R)>>L)+2 Where R and L are derived from N values.

圖16為一流程圖,例示依據本發明第一態樣的第一實施例如何在影像部上執行SAO濾波。16 is a flowchart illustrating how to perform SAO filtering on the image portion according to the first embodiment of the first aspect of the present invention.

例如,程序1600可以在圖6中之步驟67期間被執行。其也可以在編碼器的解碼環路(在圖4中之步驟415)中被執行,以產生用於動作評估及後續畫框補償的參考畫框。此程序有關於用於一色彩成分的SAO濾波(因此,在語法元件中之上標“_X”可以如下省略)。For example, the procedure 1600 may be executed during step 67 in FIG. 6. It can also be executed in the decoder's decoding loop (step 415 in Fig. 4) to generate a reference frame for motion evaluation and subsequent frame compensation. This procedure is about SAO filtering for a color component (hence, the superscript "_X" in the syntax element can be omitted as follows).

在此第一實施例中,預定符號法以CTU位準發信於位元流中。因此,發信係被執行於CTU位準,即程序1600所應用的影像部為CTU。In this first embodiment, the predetermined symbology is transmitted in the bit stream at the CTU level. Therefore, the transmission system is executed at the CTU level, that is, the image part to which the program 1600 is applied is the CTU.

相較於圖11所示之程序,本程序包含如下所述的兩額外模組1617及1618。Compared with the procedure shown in FIG. 11, this procedure includes two additional modules 1617 and 1618 as described below.

初始步驟1601包含依據於圖9及10所描述的程序,決定SAO濾波參數。SAO濾波參數係由編碼器所決定及編碼SAO參數係包含在位元流中。因此,在步驟1601的解碼器側上,解碼器讀取及解碼來自位元流的該等參數。步驟1601取得sao_type_idx並且如果它等於1也取得sao_band_position 1602並且如果它等於2,也取得 sao_eo_class_luma或sao_eo_class_chroma(依據色彩成分處理)。如果元件sao_type_idx等於0,則並未應用SAO濾波。The initial step 1601 includes determining the SAO filtering parameters according to the procedures described in FIGS. 9 and 10. The SAO filtering parameters are determined by the encoder and the encoded SAO parameters are included in the bitstream. Therefore, on the decoder side of step 1601, the decoder reads and decodes the parameters from the bitstream. Step 1601 takes sao_type_idx and if it is equal to 1, also takes sao_band_position 1602 and if it equals 2, it also takes sao_eo_class_luma or sao_eo_class_chroma (according to the color component processing). If the element sao_type_idx is equal to 0, no SAO filtering is applied.

在步驟1601,解碼器也檢查是否SAO型為邊緣偏移(EO)。依據第一實施例,一旗標被插入位元流內,給在CTU位準的每一SAO邊緣偏移。為此目的,其定義代表值N的索引eo_sign_method,其將被使用作為現行CTB取樣的邊緣分類的signN函數的第二參數。再者,eo_sign_method係於1618在eo_sign_method_Luma與 eo_sign_method_Chroma之間識別。至於其他邊緣偏移參數,eo_sign_method_Luma可以與eo_sign_method_Chroma無關。步驟1601也取得4 個偏移的偏移表1603。At step 1601, the decoder also checks whether the SAO type is edge offset (EO). According to the first embodiment, a flag is inserted into the bit stream to offset each SAO edge at the CTU level. For this purpose, it defines the index eo_sign_method representing the value N, which will be used as the second parameter of the signN function of the edge classification of the current CTB sample. Furthermore, eo_sign_method was linked to eo_sign_method_Luma in 1618. between eo_sign_method_Chroma. As for other edge offset parameters, eo_sign_method_Luma can be independent of eo_sign_method_Chroma. Step 1601 also obtains an offset table 1603 for four offsets.

被用以連續考量現行方塊或畫框區域(CTU)的每一像素Pi的變數i在步驟1604中被設定為0。另外,“畫框區域”及“影像區域”在本說明書中被交換使用。在此例子中,畫框區域為CTU。在步驟1606中,像素Pi係由包含N個像素的畫框區域1605中抽出。此像素Pi在步驟1607中依據參考圖27A或27B所述之邊緣偏移分類或參考圖8所述的帶偏移分類加以分類。決定模組1608測試Pi是否在予以使用傳統SAO濾波加以過濾的類中。The variable i of each pixel Pi used to continuously consider the current block or frame area (CTU) is set to 0 in step 1604. In addition, "frame area" and "video area" are used interchangeably in this manual. In this example, the frame area is CTU. In step 1606, the pixel Pi is extracted from the frame area 1605 containing N pixels. This pixel Pi is classified in step 1607 according to the edge offset classification described with reference to FIG. 27A or 27B or the band offset classification described with reference to FIG. 8. It is decided that the module 1608 tests whether the Pi is in the class to be filtered using traditional SAO filtering.

如果Pi是在一濾波類中,則相關類數目j係被指明並且在步驟1610中,相關偏移值Offsetj由偏移表1603抽出。在傳統SAO濾波情況下,此Offsetj然後在步驟1611中被加入至像素值Pi中,以產生濾波像素值Pi’ 1612。在步驟1613中,此濾波像素Pi’被插入濾波畫框區域1616中。If Pi is in a filtering class, the number of relevant classes j is specified and in step 1610, the relevant offset value Offsetj is extracted from the offset table 1603. In the case of conventional SAO filtering, this Offsetj is then added to the pixel value Pi in step 1611 to produce a filtered pixel value Pi' 1612. In step 1613, this filtered pixel Pi' is inserted into the filtered picture frame area 1616.

如果Pi並未在予以作SAO濾波的一類中,則Pi(1609)將在步驟1613中被插入濾波畫框區域1616中,而沒有過濾。If Pi is not in the category for SAO filtering, Pi (1609) will be inserted into the filtering frame area 1616 in step 1613 without filtering.

在步驟1613後,變數i在步驟1614被增量,以濾波現行畫框區域1605的後續像素(如果有的話-測試1615)。在步驟1615,如果所有像素已經被處理(i>=N),則濾波畫框區域1616被重建並可以被加入至SAO重建畫框(見圖6的畫框68或圖4的畫框416)。After step 1613, the variable i is incremented in step 1614 to filter subsequent pixels of the current frame area 1605 (if any-test 1615). At step 1615, if all pixels have been processed (i>=N), the filtered frame area 1616 is reconstructed and can be added to the SAO reconstruction frame (see frame 68 in FIG. 6 or frame 416 in FIG. 4) .

圖17例示依據圖16所示之第一實施例在解碼器側解析在位元流1701中之SAO參數的程序步驟。FIG. 17 illustrates a procedure of parsing the SAO parameters in the bit stream 1701 on the decoder side according to the first embodiment shown in FIG. 16.

相較於圖10所示之程序,本程序包含如下所述之新模組1711。Compared with the procedure shown in FIG. 10, this procedure includes the following new module 1711.

在初始步驟1702中,“sao_type_idx_X”語法元件被讀取並解碼。代表此語法元件的碼字元可以使用固定長度碼或者可以使用任何算術編碼的方法。此語法元件sao_type_idx_X完成施加於畫框區域的SAO的類型被處理用色彩成分Y或者兩色度成分U&V的決定。本發明之技術並不限用於YUV色彩成分也可以用於RGB色彩成分或任何其他色彩成分。In the initial step 1702, the "sao_type_idx_X" syntax element is read and decoded. The codeword representing this syntax element can use a fixed-length code or can use any arithmetic coding method. This syntax element sao_type_idx_X completes the determination of the color component Y or the two-chrominance component U&V of the type of SAO applied to the frame area. The technology of the present invention is not limited to YUV color components but can also be used for RGB color components or any other color components.

在相同步驟1702中,執行測試,用以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”,表示對於Y,如果X被設定等於Y,此畫框區域(CTU)沒有SAO及表示對於U及V如果X被設定等於U及V,此畫框區域沒有SAO。SAO參數的決定完成並且程序進行至步驟1708。否則,如果“sao_type_idx”為嚴格正,則表示在位元流中存在有用於此CTU的SAO參數。In the same step 1702, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that for Y, if X is set equal to Y, there is no SAO in this frame area (CTU) and that for U and V if X is set equal to U and V, there is no SAO in this frame area . The decision of the SAO parameters is completed and the procedure proceeds to step 1708. Otherwise, if "sao_type_idx" is strictly positive, it means that there is a SAO parameter for this CTU in the bitstream.

然後,程序進行至步驟1706,其中環路執行四次疊代。四次疊代被執行於步驟1707,其中偏移j的絕對值係由位元流讀取並解碼。這四個偏移對應於SAO邊緣偏移的四個邊緣索引的偏移(O1、O2、O3、O4)的四個絕對值(圖27A或27B)或對應於有關於SAO帶偏移的四個範圍的偏移的四個絕對值(見圖8)。Then, the procedure proceeds to step 1706, where the loop performs four iterations. Four iterations are performed in step 1707, where the absolute value of offset j is read and decoded by the bit stream. These four offsets correspond to the four absolute values of the four edge index offsets (O1, O2, O3, O4) of the SAO edge offset (Figure 27A or 27B) or correspond to the four related SAO band offsets. Four absolute values of the range of offsets (see Figure 8).

在步驟1707後,程序進行至步驟1703,其中執行一測試,以決定是否SAO的型等應於帶偏移型(sao_type_idx_X==1)。After step 1707, the process proceeds to step 1703, where a test is performed to determine whether the SAO type should be equal to the offset type (sao_type_idx_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟1709及1710中被解碼,除了具有零值的各個偏移外,在後續步驟1704被執行之前,以在位元流中讀取並解碼SAO帶的位置“sao_band_position_X”如於圖8所示。If the result is positive, the symbol used for the offset with offset mode is decoded in steps 1709 and 1710, except for each offset with a value of zero, before the subsequent step 1704 is performed, in the bit stream The position “sao_band_position_X” of the SAO band is read and decoded as shown in FIG. 8.

如果在步驟1703中之結果為負 (“sao_type_idx_X”被設定等於2),則表示使用了邊緣偏移型。依據本實施例,在此例中之解碼器在步驟1711中從位元流1701中讀取eo_sign_method_X。如果X等於Y,則讀取語法元件為“eo_sign_method_luma”及如果X被設定等於U及V,則讀取語法元件為“eo_sign_method_chroma”。If the result in step 1703 is negative ("Sao_type_idx_X" is set equal to 2), indicating that the edge offset type is used. According to this embodiment, the decoder in this example reads eo_sign_method_X from the bitstream 1701 in step 1711. If X is equal to Y, the read syntax element is "eo_sign_method_luma" and if X is set equal to U and V, the read syntax element is "eo_sign_method_chroma".

可以注意,在此例子中,因為一些其他參數在兩色度成分間共享,所以,eo_sign_method_X為用於兩色度成分(U及V)。但如果輸入視訊信號類型為RGB,則個別eo_sign_method語法元件可能也可被特殊考量。It can be noted that in this example, because some other parameters are shared between the two chroma components, eo_sign_method_X is used for the two chroma components (U and V). However, if the input video signal type is RGB, individual eo_sign_method syntax elements may also be specially considered.

eo_sign_method語法元件可以以表示參數N的可能值的數目的固定長度碼加以編碼。已經決定,用於N的四個可能值可以在編碼複雜度與編碼效率之間提供有趣的妥協。因此,此語法元件可以以2位元編碼。The eo_sign_method syntax element may be encoded with a fixed-length code representing the number of possible values of parameter N. It has been decided that the four possible values for N can provide an interesting compromise between coding complexity and coding efficiency. Therefore, this syntax element can be encoded in 2 bits.

再者,邊緣偏移類(對應於方向0、45、90及135度)係在步驟1705中由位元流1701抽出。如果X等於Y,則讀取語法元件為“sao_eo_class_luma”及如果X被設定等於U及V,則讀取語法元件為“sao_eo_class_chroma”。Furthermore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream 1701 in step 1705. If X is equal to Y, the syntax element is read as "sao_eo_class_luma" and if X is set equal to U and V, the syntax element is read as "sao_eo_class_chroma".

當四個偏移被解碼時,SAO參數的讀取完成及程序進行至步驟1708。When the four offsets are decoded, the reading of the SAO parameters is completed and the process proceeds to step 1708.

以CTU位準發信邊緣符號法的優點為依據畫框/切片內容及量化誤差的有效適應,這相較於先前技藝產生編碼效率的改良。The advantage of the CTU level signal edge symbol method is based on the effective adaptation of the frame/slice content and quantization error, which results in an improvement in coding efficiency compared to previous techniques.

依據可能實施法,預定符號方法被CABAC編碼,即,旗標eo_sign_method_X可以以傳統CABAC算術編碼。此實施法的優點可以是雖然在現行切片/畫框內的畫框/切片內容及量化誤差為相對同質,但編碼效率仍能增加。結果,一種邊緣偏移符號法可以選擇用於很多CTU。According to a possible implementation method, the predetermined sign method is CABAC coded, that is, the flag eo_sign_method_X may be coded in traditional CABAC arithmetic. The advantage of this implementation method may be that although the frame/slice content and quantization error in the current slice/picture frame are relatively homogeneous, the coding efficiency can still be increased. As a result, an edge offset sign method can be selected for many CTUs.

圖18例示依據第二實施例在解碼器側解析位元流1801中之SAO參數的程序步驟。FIG. 18 illustrates a procedure of parsing the SAO parameters in the bit stream 1801 on the decoder side according to the second embodiment.

依據第二實施例,預定符號法被預測。更明確地說,邊緣偏移符號法語法元件eo_sign_method_X可以由另一符號法語法元件預測。According to the second embodiment, the predetermined symbol method is predicted. More specifically, the edge offset symbol method syntax element eo_sign_method_X can be predicted by another symbol method syntax element.

相較於圖17所示之程序,本程序包含兩如下所述之額外模組1812及1813。Compared with the procedure shown in FIG. 17, this procedure includes two additional modules 1812 and 1813 as described below.

在初始步驟1802中,“sao_type_idx_X”語法元件被讀取與解碼。代表此語法元件的碼字元可以使用固定長度碼或者可以使用算術編碼的任何方法。語法元件sao_type_idx_X完成被施加至予以處理用色彩成分Y或兩色度成分U&V的畫框區域的SAO型的決定。本發明之技術並不限於與YUV色彩成分一起使用,也可以與RGB色彩成分或任何其他色彩成分一起使用。In the initial step 1802, the "sao_type_idx_X" syntax element is read and decoded. The codeword representing this syntax element may use a fixed-length code or may use any method of arithmetic coding. The syntax element sao_type_idx_X completes the SAO type determination applied to the frame area of the color component Y or the two-chrominance component U&V to be processed. The technique of the present invention is not limited to use with YUV color components, but can also be used with RGB color components or any other color components.

在相同步驟1802中,執行一測試,以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”表示對於Y如果X被設定等於Y,沒有SAO用於此畫框區域(CTU),以及表示對於U及V,如果X被設定等於U及V,沒有SAO用於此畫框區域。SAO參數的決定完成及程序進行至步驟1808。否則,如果“sao_type_idx”為嚴格正,則表示SAO參數存在於位元流之此CTU。In the same step 1802, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that for Y if X is set equal to Y, there is no SAO for this frame area (CTU), and for U and V, if X is set equal to U and V, there is no SAO for This picture frame area. The decision of the SAO parameter is completed and the procedure proceeds to step 1808. Otherwise, if "sao_type_idx" is strictly positive, it means that the SAO parameter exists in this CTU of the bitstream.

然後,程序進行至步驟1806,其中環路執行四次疊代。四次疊代被執行於步驟1807中,其中偏移j的絕對值被由位元流讀取與解碼。這四個偏移對應於SAO邊緣偏移的四個邊緣索引的偏移(O1、O2、O3、O4)的四個絕對值(見圖27A或27B)或對應於SAO帶偏移的四個範圍有關的偏移的四個絕對值(見圖8)。Then, the procedure proceeds to step 1806, where the loop performs four iterations. Four iterations are performed in step 1807, where the absolute value of offset j is read and decoded by the bit stream. These four offsets correspond to the four absolute values of the four edge index offsets (O1, O2, O3, O4) of the SAO edge offset (see Figure 27A or 27B) or the four corresponding to the SAO band offset The four absolute values of the range-dependent offset (see Figure 8).

在步驟1807後,程序進行至步驟1803,其中執行一測試,以決定SAO的類型對應於帶偏移型 (sao_type_idx_X==1)。After step 1807, the process proceeds to step 1803, where a test is performed to determine that the type of SAO corresponds to the band offset type (sao_type_idx_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟1809及1810中被解碼,除了具有零值的各個偏移之外,在後續步驟1804執行之前,以讀取於位元流及解碼SAO帶的位置“sao_band_position_X”如圖8所示。If the result is positive, the symbol for the offset with offset mode is decoded in steps 1809 and 1810, except for each offset with a value of zero, before the subsequent step 1804 is executed to read the bit The position "sao_band_position_X" of the stream and decoded SAO band is shown in Fig. 8.

如果在步驟1803中結果為負 (“sao_type_idx_X”被設定等於2),則表示邊緣偏移型被使用。在此例中之解碼器在步驟1811中從位元流1801讀取eo_sign_method_X。如果X等於Y,則讀取語法元件為“eo_sign_method_luma”及如果X被設定等於U及V,則讀取語法元件為“eo_sign_method_chroma”。If the result is negative in step 1803 ("Sao_type_idx_X" is set equal to 2), indicating that the edge offset type is used. The decoder in this example reads eo_sign_method_X from the bitstream 1801 in step 1811. If X is equal to Y, the read syntax element is "eo_sign_method_luma" and if X is set equal to U and V, the read syntax element is "eo_sign_method_chroma".

然後,依據此第二實施例,用於色彩成分X的預測子符號法1812係在步驟1813被加至解碼語法元件eo_sign_method_X,以取得用於現行CTB的邊緣偏移符號法。Then, according to this second embodiment, the predictor symbol method 1812 for the color component X is added to the decoding syntax element eo_sign_method_X in step 1813 to obtain the edge offset symbol method for the current CTB.

因此,在編碼器側, Predictor_sign_method_X已經被減eo_sign_method_X。Therefore, on the encoder side, Predictor_sign_method_X has been subtracted from eo_sign_method_X.

在此第二實施例中,語法元件 eo_sign_method_X被以可變長度碼編碼,以取得以編碼效率表示之優點。此可變長度碼可以為一元碼或Golomb碼及或另一方法。此Predictor_sign_method_X可以被使用作為用於CABAC編碼的上下文值。In this second embodiment, the syntax element eo_sign_method_X is coded with variable-length codes to obtain the advantages expressed in coding efficiency. The variable-length code may be a unary code or a Golomb code or another method. This Predictor_sign_method_X can be used as the context value for CABAC encoding.

依據替代實施例,旗標可以表示是否現行eo_sign_method_X嚴格等於Predictor_sign_method_X與否。如果否,則eo_sign_method_X可以被解碼。否則, eo_sign_method_X等於Predictor_sign_method_X。因此,eo_sign_method_X可以為固定長度碼。According to an alternative embodiment, the flag may indicate whether the current eo_sign_method_X is strictly equal to Predictor_sign_method_X or not. If not, eo_sign_method_X can be decoded. otherwise, eo_sign_method_X is equal to Predictor_sign_method_X. Therefore, eo_sign_method_X can be a fixed-length code.

在一子實施例中,如果左CTU存在(例如,如果左CTU作為SAO參數及如果SAO型為邊緣偏移型),則eo_sign_method_X可以為左CTU的eo_sign_method_X所預測。In a sub-embodiment, if the left CTU exists (for example, if the left CTU is used as the SAO parameter and if the SAO type is an edge offset type), then eo_sign_method_X may be predicted by the eo_sign_method_X of the left CTU.

在一子實施例中,如果上CTU存在,則eo_sign_method_X可以為上CTU的eo_sign_method_X所預測。In a sub-embodiment, if the upper CTU exists, eo_sign_method_X may be predicted by eo_sign_method_X of the upper CTU.

這兩子實施例具有與SAO合併推導一致的優點,其現行為左及上CTU的SAO參數。These two sub-embodiments have the same advantages as the SAO merge derivation, and their current SAO parameters for the left and upper CTUs.

在一子實施例中,如果有的話, eo_sign_method_X可以為先前解碼的最新 eo_sign_method_X所預測。In a sub-embodiment, if any, eo_sign_method_X can be the latest decoded previously Predicted by eo_sign_method_X.

在一子實施例中,如果有的話, eo_sign_metod_X可以為先前解碼的幾個 eo_sign_method_X的平均所預測。In a sub-embodiment, if any, eo_sign_metod_X can be a few previously decoded The average predicted by eo_sign_method_X.

在步驟1813後,邊緣偏移類(對應於方向0、45、90及135度)在步驟1805中由位元流1801抽出。如果X等於Y,則讀取語法元件為“sao_eo_class_luma”及如果X設定為等於U及V,則讀取語法元件為“sao_eo_class_chroma”。After step 1813, the edge offset classes (corresponding to directions 0, 45, 90 and 135 degrees) are extracted from the bit stream 1801 in step 1805. If X is equal to Y, the read syntax element is "sao_eo_class_luma" and if X is set equal to U and V, the read syntax element is "sao_eo_class_chroma".

當四個偏移已經被解碼時,SAO參數的讀取完成及程序進行至步驟1808。When the four offsets have been decoded, the reading of the SAO parameters is completed and the process proceeds to step 1808.

第二實施例及其所有子實施例的優點為由於利用信號內容的空間相關性及在現行切片/畫框的CTU間的類似量化誤差,所以編碼效率增加。這是因為當現行切片的信號係逐CTU類似,及當量化誤差也類似時,則在編碼器側的最佳選擇eo_sign_method_X也經常是類似。The advantage of the second embodiment and all its sub-embodiments is that the coding efficiency is increased due to the use of the spatial correlation of the signal content and the similar quantization error between the CTUs of the current slice/picture frame. This is because when the signal of the current slice is similar by CTU, and when the quantization error is also similar, the best choice eo_sign_method_X on the encoder side is often similar.

圖19例示依據第三實施例在解碼器側解析在位元流1901的SAO參數的程序步驟。FIG. 19 illustrates a procedure of parsing the SAO parameters in the bit stream 1901 on the decoder side according to the third embodiment.

依據此第三實施例,邊緣偏移符號法被以較CTU位準高的位準發信。換句話說,預定符號法係被以畫框、切片或序列位準發信於位元流中。According to this third embodiment, the edge offset symbol method is transmitted at a higher level than the CTU level. In other words, the predetermined symbology is signaled in the bitstream with frame, slice or sequence levels.

更明確地說,其以切片/畫框發信並利用在切片/畫框內所用的邊緣偏移符號法間之可能相關性。More specifically, it sends messages in slices/picture frames and utilizes the possible correlation between the edge-offset symbol methods used in slices/picture frames.

在步驟1902,slice_sao_luma_flag被由位元流1901抽出。如果該旗標的值被設定為真(=1),則在步驟1903,eo_sign_method_luma被由位元流1901抽出並將被用於現行切片/畫框的所有亮度CTB的邊緣偏移分類符號法。然後,程序將進行至下一切片檔頭語法元件(步驟1906)。At step 1902, slice_sao_luma_flag is extracted from the bitstream 1901. If the value of the flag is set to true (=1), in step 1903, eo_sign_method_luma is extracted from the bitstream 1901 and will be used for the edge offset classification notation of all luminance CTBs of the current slice/picture frame. Then, the program will proceed to the next slice header syntax element (step 1906).

如果旗標slice_sao_luma_flag的值被設定為假,則在步驟1904,slice_sao_chroma_flag將由位元流1901抽出。如果此旗標的值被設定為真(=1),則在步驟1905從位元流1901抽出eo_sign_method_chroma並將被使用用於現行切片/畫框的所有色度CTB的邊緣偏移分類符號法。然後,程序進行至下一切片檔頭語法元件(步驟1906)。如果該旗標的值被設定為假(=0),則程序將直接進行至下一切片檔頭語法元件(步驟1906)。If the value of the flag slice_sao_luma_flag is set to false, then in step 1904, slice_sao_chroma_flag will be extracted from the bitstream 1901. If the value of this flag is set to true (=1), eo_sign_method_chroma is extracted from the bitstream 1901 at step 1905 and will be used for the edge offset classification notation for all chroma CTBs of the current slice/picture frame. Then, the program proceeds to the next slice header syntax element (step 1906). If the value of the flag is set to false (=0), the program will directly proceed to the next slice header syntax element (step 1906).

此實施例的優點可以為當畫框/切片內容及量化誤差在現行切片/畫框內相對同質時,編碼效率被改良。在切片檔頭發信的主要優點為用於eo_sign_method_X的可能值數目可能高於參考圖17及18所述之CTU位準發信法。這是因為切片檔頭的碼率可能較CTU位準的語法元件具有更低的衝擊。因此,eo_sign_method_X可以以3位元(8個可能值)或4位元(16個可能值)加以編碼。The advantage of this embodiment may be that when the frame/slice content and quantization error are relatively homogeneous within the current slice/picture frame, the coding efficiency is improved. The main advantage of sending messages in a slice file is that the number of possible values for eo_sign_method_X may be higher than the CTU level signaling method described with reference to FIGS. 17 and 18. This is because the code rate of the slice header may have a lower impact than the syntax elements of the CTU level. Therefore, eo_sign_method_X can be encoded in 3 bits (8 possible values) or 4 bits (16 possible values).

依據替代實施例,eo_sign_method_X可以以序列位準發信。在此情況中,量化誤差及信號內容應逐畫框與逐CTU類似。According to an alternative embodiment, eo_sign_method_X can be sent at a sequence level. In this case, the quantization error and signal content should be similar to frame-by-frame and CTU-by-frame.

依據一實施例,預定符號法係於編碼器側加以選擇,以最小化碼率-失真成本。因此,用於各個 eo_sign_method_X的不同可能值係被以傳統RD準則加以評估及最小化RD(碼率-失真)成本的值係被選擇及插入位元流中。According to an embodiment, the predetermined symbol method is selected on the encoder side to minimize the rate-distortion cost. Therefore, for each The different possible values of eo_sign_method_X are evaluated using traditional RD criteria and the value that minimizes the RD (rate-distortion) cost is selected and inserted into the bitstream.

此實施例的優點可以是其應到達切片/畫框位準發信的最大編碼效率。The advantage of this embodiment may be that it should reach the maximum coding efficiency of the slice/picture frame level signaling.

圖20例示以編碼器的eo_sign_method_X的選擇之例子。其代表根據以切片位準的深度(只編碼器參數)及量化參數的畫框階層。如此圖所示,當量化參數增加時,eo_sign_method_X值增加。FIG. 20 illustrates an example of selection of eo_sign_method_X by the encoder. It represents the picture frame hierarchy based on the depth at slice level (encoder parameters only) and quantization parameters. As shown in this figure, as the quantization parameter increases, the eo_sign_method_X value increases.

依據此實施例,預定符號法係在編碼器側依據現行切片或畫框的參數加以選擇。換句話說,編碼器可以依據現行切片/畫框的一或更多參數選擇 eo_sign_method_X。這些參數可以為如圖所示之在畫框階層中之深度或量化參數。According to this embodiment, the predetermined symbol method is selected on the encoder side according to the parameters of the current slice or picture frame. In other words, the encoder can choose according to one or more parameters of the current slice/picture frame eo_sign_method_X. These parameters can be depth or quantization parameters in the picture frame hierarchy as shown.

依據替代實施例,任何eo_sign_method_X,例如,在序列的開始處立即傳送。在此情況中,eo_sign_method_X係以序列位準方式加以選擇或預選擇以定義編解碼器,以針對所有序列的各個成分或亮度成分及兩色度成分最佳化。According to an alternative embodiment, any eo_sign_method_X, for example, is transmitted immediately at the beginning of the sequence. In this case, eo_sign_method_X is selected or pre-selected in a sequence level manner to define a codec to be optimized for the individual components or luminance components and dichromatic components of all sequences.

圖21為流程圖,例示SAO濾波如何依據本發明第一態樣的第四實施例,執行於影像部上。FIG. 21 is a flowchart illustrating how SAO filtering is performed on the image portion according to the fourth embodiment of the first aspect of the present invention.

例如,此程序2100係在圖6的步驟67期間執行。也被執行於編碼器的解碼環路(圖4的步驟415)中,以產生用於後續畫框的動作評估與補償的參考畫框。此程序係相關於用於一色彩成分的SAO濾波(此在語法元件中之下標“_X”已經如下被省略)。For example, this procedure 2100 is executed during step 67 of FIG. 6. It is also executed in the decoding loop of the encoder (step 415 of FIG. 4) to generate a reference picture frame for motion evaluation and compensation of subsequent picture frames. This procedure is related to SAO filtering for a color component (this subscript "_X" in the syntax element has been omitted as follows).

在此第四實施例中,所取得 eo_sign_method_X並不直接對應於使用作為在signN函數中的參數的值N。該表組係被使用以將指標值 eo_sign_method_X轉換為此值N。例如,根據不是連續的及/或可能不包含0作為可能值的多數限定值N,在編碼器側,選擇預定符號法。In this fourth embodiment, the obtained eo_sign_method_X does not directly correspond to the value N used as a parameter in the signN function. The table system is used to convert the index value eo_sign_method_X is converted to this value N. For example, according to a majority limit value N that is not continuous and/or may not contain 0 as a possible value, on the encoder side, a predetermined sign method is selected.

相較於如圖16所示之程序,本程序包含如下所述的兩額外模組2119及2120。Compared with the procedure shown in FIG. 16, the procedure includes two additional modules 2119 and 2120 as described below.

初始步驟2101包含依據圖9及10所繪之程序決定SAO濾波參數。SAO濾波參數係由編碼器所決定及所編碼SAO參數被包含在位元流中。因此,在步驟2101的解碼器側上,解碼器讀取及解碼來自位元流的參數。步驟2101取得sao_type_idx及如果其等於1,則也取得 sao_band_position 2102,如果其等於2,其也(依據所處理的色彩成分)取得sao_eo_class_luma或 sao_eo_class_chroma。如果元件sao_type_idx等於0,則未應用SAO濾波。The initial step 2101 includes determining the SAO filter parameters according to the procedures depicted in FIGS. 9 and 10. The SAO filtering parameters are determined by the encoder and the encoded SAO parameters are included in the bitstream. Therefore, on the decoder side of step 2101, the decoder reads and decodes the parameters from the bitstream. Step 2101 obtain sao_type_idx and if it is equal to 1, then also obtain sao_band_position 2102, if it is equal to 2, it also obtains sao_eo_class_luma (depending on the color component being processed) or sao_eo_class_chroma. If the element sao_type_idx is equal to 0, no SAO filtering is applied.

在步驟2101,解碼器也檢查是否SAO型為邊緣偏移(EO)。對於以CTU位準的各個SAO邊緣偏移,一旗標被插入在位元流內側。為此目的,其定義代表值N的索引eo_sign_method,其將會被用以作為現行CTB取樣的邊緣分類的signN函數的第二參數。再者,eo_sign_method係在eo_sign_method_Luma與eo_sign_method_Chroma間被指明(步驟2118)。至於,其他邊緣偏移參數, eo_sign_method_Luma可能與eo_sign_method_Chroma無關。步驟2101也取得4偏移的偏移表2103。In step 2101, the decoder also checks whether the SAO type is edge offset (EO). For each SAO edge offset at the CTU level, a flag is inserted inside the bit stream. For this purpose, it defines an index eo_sign_method representing the value N, which will be used as the second parameter of the signN function of the edge classification of the current CTB sampling. Furthermore, eo_sign_method is specified between eo_sign_method_Luma and eo_sign_method_Chroma (step 2118). As for the other edge offset parameters, eo_sign_method_Luma may not be related to eo_sign_method_Chroma. Step 2101 also obtains an offset table 2103 of 4 offsets.

再者,依據本實施例,新語法元件M係根據語法元件eo_sign_method_luma或 o_edge_sign_method_chroma與轉換表“Set”在步驟2119界定。表組係被用以將索引值eo_sign_method_X轉換為值M。此一轉換表的例子係提供如下。此值M將被用於函數“signN(x,M)”2120中,用於現行CTB的取樣的邊緣偏移分類。Furthermore, according to this embodiment, the new syntax element M is based on the syntax element eo_sign_method_luma or o_edge_sign_method_chroma and the conversion table "Set" are defined in step 2119. The table set is used to convert the index value eo_sign_method_X to the value M. An example of this conversion table is provided below. This value M will be used in the function "signN(x,M)" 2120 for the edge offset classification of the current CTB samples.

用以連續考量現行方塊或畫框區域(CTU)的每一像素Pi的變數i在步驟2104中設定為0。另外,“畫框區域”及“影像區域”係在本說明書中交換使用。在此例子中之畫框區域為CTU。在步驟2106中,像素Pi係由畫框區域2105抽出,畫框區域包含N個像素。在步驟2107中,像素Pi係依據參考圖27A與27B所述的邊緣偏移分類或者參考圖8所述之帶偏移分類加以分類。決定模組2108測試Pi是否在予以使用傳統SAO濾波加以濾波的一類中。The variable i used to continuously consider each pixel Pi of the current block or frame area (CTU) is set to 0 in step 2104. In addition, "frame area" and "video area" are used interchangeably in this manual. The frame area in this example is CTU. In step 2106, the pixel Pi is extracted from the frame area 2105, and the frame area includes N pixels. In step 2107, the pixels Pi are classified according to the edge offset classification described with reference to FIGS. 27A and 27B or the band offset classification described with reference to FIG. It is decided that the module 2108 tests whether Pi is in a category to be filtered using traditional SAO filtering.

如果Pi在濾波類中,則相關類數j被指明及相關偏移值Offsetj係在步驟2110由偏移表2103抽出。在傳統SAO濾波中,此Offsetj然後在步驟2111中被加至像素值Pi中,以產生濾波像素值Pi’ 2112。此濾波像素Pi’在步驟2113中被插入濾波畫框區域2116。If Pi is in the filtering class, the relevant class number j is specified and the relevant offset value Offsetj is extracted from the offset table 2103 at step 2110. In conventional SAO filtering, this Offsetj is then added to the pixel value Pi in step 2111 to produce a filtered pixel value Pi' 2112. This filtered pixel Pi' is inserted into the filtered frame area 2116 in step 2113.

如果Pi不是在予以SAO濾波的一類中,則Pi(2109)在步驟2113中被插入濾波畫框區域2116,而沒有濾波。If Pi is not in a category that is subject to SAO filtering, Pi (2109) is inserted into the filtered frame area 2116 in step 2113 without filtering.

在步驟2113後,變數i在步驟2114中被增量,以濾波現行畫框區域2105的後續像素(如果有-測試2115)。在所有像素都在步驟2115被處理後(i>=N),濾波畫框區域2116被重建並可以被加入至SAO重建畫框(見圖6的畫框68或圖4的416)。After step 2113, the variable i is incremented in step 2114 to filter the subsequent pixels of the current frame area 2105 (if any-test 2115). After all pixels are processed in step 2115 (i>=N), the filtered frame area 2116 is reconstructed and can be added to the SAO reconstruction frame (see frame 68 in FIG. 6 or 416 in FIG. 4).

為了容易起見,以下例子包含在該組可能N中的四個值。該組可能N為表組的值。然而,本發明並不限於此。For ease, the following example contains the four values in the set of possible N. The group may have N as the value of the table group. However, the present invention is not limited to this.

例如,值N=0可以被排除,及所用的該組N值可以為{1,2,3,4}。這可以提供較佳RD妥協。For example, the value N=0 can be excluded, and the set of N values used can be {1,2,3,4}. This can provide better RD compromise.

或者,該組可能N的值可以對準值Val的移位值。例如,該組可以是{0,2,4,8}。其對應於使用分類符號法及輸入值val的右移M(以M={0,1,2,3})。Alternatively, the set of possible values of N can be aligned with the shift value of the value Val. For example, the group may be {0, 2, 4, 8}. It corresponds to the right shift M (using M={0,1,2,3}) using the classification symbol method and the input value val.

例如,邊緣索引可以由以下公式取得:

Figure 02_image022
For example, the edge index can be obtained by the following formula:
Figure 02_image022

應注意,此公式並不是一直提供準確相同結果,如同當在該組{0,2,4,8}間之N與以下signN函數一起使用時:

Figure 02_image024
It should be noted that this formula does not always provide the exact same result, as when N between the groups {0, 2, 4, 8} is used with the following signN function:
Figure 02_image024

這是由於在負值上的右移運算子。但兩方法的編碼效率類似。This is due to the right shift operator on negative values. But the coding efficiency of the two methods is similar.

在一實施例中,該組可能N值可以為{1,2,4,8}。在此情況中,邊緣索引可以以下公式取得:

Figure 02_image026
其中eo_sign_method_X可以採4個值0,1,2,3。此組使得其更容易由eo_sign_method_X推導出值N。In an embodiment, the set of possible N values may be {1, 2, 4, 8}. In this case, the edge index can be obtained by the following formula:
Figure 02_image026
Among them, eo_sign_method_X can take 4 values 0, 1, 2, 3. This group makes it easier to derive the value N from eo_sign_method_X.

在其他實施例中,該組可能N被適用以匹配信號內容的統計為{0,2,4,6}或者另一例子為{0,1,3,6}。In other embodiments, the group N may be adapted to match the statistics of the signal content as {0, 2, 4, 6} or another example as {0, 1, 3, 6}.

在這些例子中,該組可能值N被建立,使得最大值並不很大及該組的第一值與該組的最後值間之值間之差相比較為小的。In these examples, the set of possible values N is established so that the maximum value is not very large and the difference between the first value of the set and the last value of the set is relatively small.

當發信在CTU位準或更低時,所有這些實施例可能很有趣,因為連續值並不對應於自然內容與相關量化誤差的統計。一個優點為編碼效率的改良。When the transmission is at the CTU level or lower, all these embodiments may be interesting because continuous values do not correspond to statistics of natural content and related quantization errors. One advantage is the improvement of coding efficiency.

依據另一實施例,預定符號法係在編碼器側依據取決於切片型的多數限定值N加以選擇,即該組N值可能取決於切片類型。因為量化誤差內容取決於切片類型,所以即使主觀測量給出相同品質測量,也可能有趣。在此實施例中,包含在P切片間的該組中的值係高於用於B切片間的該組值。According to another embodiment, the predetermined symbol method is selected on the encoder side according to a majority limit value N that depends on the slice type, that is, the set of N values may depend on the slice type. Because the content of the quantization error depends on the slice type, it may be interesting even if the subjective measurements give the same quality measurement. In this embodiment, the value contained in the group between P slices is higher than the value used for the group between B slices.

在替代實施例中,用於P切片間的該組可能N值中的至少一值係高於用於B切片間的該組可能N值內的對應值。N值可能只相關於亮度(Luma)。In an alternative embodiment, at least one of the set of possible N values used between P slices is higher than the corresponding value within the set of possible N values used between B slices. The N value may only be related to luminance (Luma).

此替代例可以藉由修改如圖21所示之程序,例如,藉由在模組2119中使用此公式加以實施:

Figure 02_image028
其中Slice_type為內、P間或B間。This alternative example can be implemented by modifying the procedure shown in FIG. 21, for example, by using this formula in module 2119:
Figure 02_image028
Where Slice_type is inner, P or B.

例如,表組可以如下:

Figure 02_image030
For example, the table group can be as follows:
Figure 02_image030

依據另一實施例,預定符號法係在編碼器側依據多數限定值N加以選擇,限定值取決於色彩成分,即該組N值取決於色彩成分。在此實施例中,用於亮度成分的該組可能值N可能與用於兩色度成分的該組可能值N不同。此實施例的優點可能是由於用於各個色彩成分類型的適應組N值造成的編碼效率改良。According to another embodiment, the predetermined symbol method is selected on the encoder side according to a majority limit value N. The limit value depends on the color component, that is, the set of N values depends on the color component. In this embodiment, the set of possible values N for the luminance component may be different from the set of possible values N for the two-chroma component. The advantage of this embodiment may be the improvement in coding efficiency due to the adaptation group N value for each color component type.

在一額外實施例中,用於亮度成分的該組N值包含較用於色度成分的該組N值高的值。此實施例的優點可以為由於用於各個色彩成分型的適應組N值的編碼效率改良。這是因為對於色度成分,在相鄰取樣間之差係低於亮度成分者,因此,較佳降低用於色度的值N而不是亮度者。In an additional embodiment, the set of N values for luma components contains higher values than the set of N values for chroma components. The advantage of this embodiment may be the improvement in coding efficiency due to the adaptation group N value for each color component type. This is because for the chrominance component, the difference between adjacent samples is lower than the luminance component, so it is preferable to lower the value N for chrominance rather than the luminance component.

在一額外實施例或替代實施例中,在用於色度的該組中之可能N值的數目係低於用於亮度的該組中之可能N值的數目。此實施例的優點可以是因為有關於邊緣偏移符號法的發信的碼率被降低至更佳數目的方法,所以,編碼效率增加。In an additional or alternative embodiment, the number of possible N values in the group for chroma is lower than the number of possible N values in the group for brightness. The advantage of this embodiment may be because there is a method of reducing the code rate of the signal transmission with the edge offset symbol method to a better number, so the coding efficiency is increased.

在一實施例中,當輸入信號為YUV時,兩組N值被使用,及當輸入信號為RGB時,一組N值被使用。In one embodiment, when the input signal is YUV, two sets of N values are used, and when the input signal is RGB, one set of N values is used.

這些實施例可以藉由修改在圖21中之程序,例如,藉由在模組2119中使用此公式加以實施:

Figure 02_image032
其中X等於亮度或色度,及Slice_type為內、P間或B間。These embodiments can be implemented by modifying the procedure in FIG. 21, for example, by using this formula in module 2119:
Figure 02_image032
Where X is equal to brightness or chroma, and Slice_type is inner, P or B.

例如,表組可以如下:

Figure 02_image034
For example, the table group can be as follows:
Figure 02_image034

圖22為流程圖,例示SAO濾波係如何依據本發明第一態樣的第五實施例執行於影像部上。FIG. 22 is a flowchart illustrating how the SAO filtering system is performed on the image portion according to the fifth embodiment of the first aspect of the present invention.

依據此第五實施例,預定符號法係在編碼器側依據只取決於亮度成分的多數限定值N加以選擇,即,N值只有關於亮度成分。在實際上,用於色度成分的該組可能N值因此被設定為0。此實施例的優點可以是藉由移除eo_sign_method_chroma的編碼效率改良。此實施例可以藉由自前述圖式中移除eo_sign_method_chroma加以實施。According to this fifth embodiment, the predetermined sign method is selected on the encoder side based on the majority limit value N that only depends on the luminance component, that is, the N value is only related to the luminance component. In practice, the set of possible N values for chroma components is therefore set to zero. The advantage of this embodiment can be improved coding efficiency by removing eo_sign_method_chroma. This embodiment can be implemented by removing eo_sign_method_chroma from the aforementioned diagram.

相較於圖17所示之程序,本程序包含額外模組2212,其將描述如下。Compared with the procedure shown in FIG. 17, this procedure includes an additional module 2212, which will be described as follows.

在初始步驟2202中,“sao_type_idx_X”語法元件被讀取與解碼。代表此語法元件的碼字元可以使用固定長度碼或者可以使用任何算術編碼方法。語法元件sao_type_idx_X致使應用於畫框區域的SAO的類型的決定被處理用色彩成分Y或用兩者色度成分U&V。本發明之技術並不限於與YUV色彩成分一起使用並且也可以與RGB色彩成分或任何其他色彩成分一起使用。In the initial step 2202, the "sao_type_idx_X" syntax element is read and decoded. The codeword representing this syntax element may use a fixed-length code or may use any arithmetic coding method. The syntax element sao_type_idx_X causes the determination of the type of SAO applied to the picture frame area to be processed with the color component Y or with both chrominance components U&V. The technique of the present invention is not limited to use with YUV color components and can also be used with RGB color components or any other color components.

在相同步驟2202中,執行測試,以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”表示如果X被設定等於Y,對於Y,並沒有SAO用於此畫框區域(CTU),以及,如果X被設定等於U及V,則對於U及V,沒有SAO用於此畫框區域。SAO參數的決定完成及程序進行至步驟2208。否則,如果“sao_type_idx”為嚴格正,則表示在位元流中此CTU存在有SAO參數。In the same step 2202, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that if X is set equal to Y, there is no SAO for this frame area (CTU) for Y, and, if X is set equal to U and V, then for U and V, there is no SAO is used for this picture frame area. The decision of the SAO parameter is completed and the process proceeds to step 2208. Otherwise, if "sao_type_idx" is strictly positive, it means that there is a SAO parameter for this CTU in the bitstream.

然後,該程序進行至步驟2206,其中環路執行四次疊代。四次疊代被執行於步驟2207中,其中偏移j的絕對值被由位元流讀取與解碼。這四個偏移對應於SAO邊緣偏移的四個邊緣索引(見圖27A或27B)的偏移(O1、O2、O3、O4)的四個絕對值或者有關於SAO帶偏移的四個範圍(見圖8)有關的偏移的四個絕對值。Then, the procedure proceeds to step 2206, where the loop performs four iterations. Four iterations are performed in step 2207, where the absolute value of the offset j is read and decoded by the bit stream. These four offsets correspond to the four absolute values of the offsets (O1, O2, O3, O4) of the four edge indexes of the SAO edge offset (see FIG. 27A or 27B) or four with the SAO band offset Four absolute values of offset related to range (see Figure 8).

在步驟2207後,程序進行至步驟2203,其中執行測試,以決定是否SAO的類型對應於帶偏移型(sao_type_idx_X==1)。After step 2207, the process proceeds to step 2203, where a test is performed to determine whether the type of SAO corresponds to the offset type (sao_type_idx_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟2209及2210中被解碼,除了具有零值的各個偏移位外,在以下步驟2204被執行之前,以讀取在位元流中並解碼如圖8所示之SAO帶的位置“sao_band_position_X”。If the result is positive, the symbol for the offset with offset mode is decoded in steps 2209 and 2210, except for each offset bit with a value of zero, to read the in-position before the following step 2204 is executed In the meta-stream, the position "sao_band_position_X" of the SAO band shown in FIG. 8 is decoded.

如果在步驟2203中的結果為負 (“sao_type_idx_X被設定為2),則表示邊緣偏移型被使用。依據本實施例,在步驟2212,解碼器檢查是否考量成分為亮度成分,如果是,則在步驟2211中讀取來自位元流2201的eo_sign_method_Luma。否則,程序直接進行至步驟2205。If the result in step 2203 is negative ("Sao_type_idx_X is set to 2), it means that the edge offset type is used. According to this embodiment, in step 2212, the decoder checks whether the component is considered to be a luminance component, and if so, reads the bit from bit in step 2211 Eo_sign_method_Luma of stream 2201. Otherwise, the procedure directly proceeds to step 2205.

再者,邊緣偏移類(對應於方向0、45、90及135度)在步驟2205中由位元流2201抽出。如果X等於Y,則讀取語法元件為“sao_eo_class_luma”及如果X被設定等於U及V,則讀取語法元件為“sao_eo_class_chroma”。Furthermore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream 2201 in step 2205. If X is equal to Y, the syntax element is read as "sao_eo_class_luma" and if X is set equal to U and V, the syntax element is read as "sao_eo_class_chroma".

當四個偏移被解碼時,SAO參數的讀取完成及程序進行至步驟2208。When the four offsets are decoded, the reading of the SAO parameters is completed and the process proceeds to step 2208.

圖23例示依據第六實施例之在解碼器側解析在位元流2301中之SAO參數的程序步驟。FIG. 23 illustrates a procedure of parsing the SAO parameters in the bit stream 2301 on the decoder side according to the sixth embodiment.

依據此實施例,預定符號法係在編碼器側根據在切片檔頭中發信的多數限定值N加以選擇,即,只有一組N值被傳送在用於亮度成分的切片檔頭中以及只有一組被傳送在用於色度成分。此實施例的一優點可以為藉由在編碼器側設定用於每一切片的有用組而增加編碼效率。According to this embodiment, the predetermined symbol method is selected on the encoder side based on the majority limit value N transmitted in the slice header, that is, only one set of N values is transmitted in the slice header for luminance components and only One set is transmitted for chroma components. An advantage of this embodiment can be to increase coding efficiency by setting a useful set for each slice on the encoder side.

在步驟2302,slice_sao_luma_flag係由位元流2301抽出。如果旗標的值被設定為真(=1),則 Max_eo_sign_method_luma係在步驟2303中由位元流2301中抽出。此值代表在該組中之元件的數目。然後,該組的每一元件值(2305)係由位元流(2301)抽出(2307)並將被使用於現行切片/畫框的所有亮度CTB的邊緣偏移分類符號法。該程序然後進行至下一切片檔頭語法元件(步驟2306)。In step 2302, slice_sao_luma_flag is extracted from the bit stream 2301. If the value of the flag is set to true (=1), then Max_eo_sign_method_luma is extracted from the bit stream 2301 in step 2303. This value represents the number of components in the group. Then, each element value (2305) of the group is extracted (2307) from the bit stream (2301) and will be used for the edge offset classification notation of all brightness CTBs of the current slice/picture frame. The process then proceeds to the next slice header syntax element (step 2306).

如果旗標slice_sao_luma_flag的值被設定為假,則slice_sao_chroma_flag係在步驟2304被由位元流2301抽出。如果旗標的值被設定為真(=1),則 Max_eo_sign_method_chroma在步驟2308被由位元流2301抽出。此值代表在該組中之元件的數目。然後,該組中之每一元件值(2309)係由位元流(2301)抽出(2310)並將被使用於現行切片/畫框的所有亮度CTB的邊緣偏移分類符號法。程序然後進行至下一切片檔頭語法元件(步驟2306)。如果旗標的值被設定為假(=0),則程序直接進行至下一切片檔頭語法元件(步驟2306)。If the value of the flag slice_sao_luma_flag is set to false, slice_sao_chroma_flag is extracted by the bit stream 2301 at step 2304. If the value of the flag is set to true (=1), then Max_eo_sign_method_chroma is extracted by the bit stream 2301 at step 2308. This value represents the number of components in the group. Then, each element value (2309) in the group is extracted (2310) from the bit stream (2301) and will be used for the edge offset classification notation of all brightness CTBs of the current slice/picture frame. The process then proceeds to the next slice header syntax element (step 2306). If the value of the flag is set to false (=0), the program directly proceeds to the next slice header syntax element (step 2306).

圖24為一流程圖,例示當依據本發明實施例之SAO濾波情況中,可以在編碼器側應用至邊緣偏移型濾波器的統計計算例的步驟240。FIG. 24 is a flowchart illustrating step 240 of a statistical calculation example that can be applied to an edge offset filter on the encoder side in the case of SAO filtering according to an embodiment of the present invention.

在此實施例中,在編碼器的不同N值間有一競爭。在這些實施例中,用eo_sign_method的各個可能值的RD成本係被計算,以在編碼器側選擇最佳 eo_sign_method。In this embodiment, there is a competition between different N values of the encoder. In these embodiments, the RD cost of each possible value of eo_sign_method is calculated to select the best on the encoder side eo_sign_method.

此圖例示用以推導出各個類的各個最佳碼率失真偏移所需的包含所有資訊的變數CTUStats的設定。再者,其例示用於現行CTU的最佳SAO參數組的選擇。This figure illustrates the setting of the variable CTUStats that contains all the information needed to derive the best bit rate distortion offset for each class. Furthermore, it illustrates the selection of the best SAO parameter set for the current CTU.

對於各個色彩成分Y、U、B(或RGB) (2411),各個SAO型被評估。對於各個SAO型(2412)及各個eo_sign_method_X(2416),在初始步驟2401中,變數Sumj SumNbPixj 被設定為零。現行畫框區域2403包含N像素。j是現行範圍數目,用以決定有關於圖7B所示之用於邊緣偏移類型的四個邊緣索引,或有關於圖8所示之用於帶偏移類型的像素值的32個範圍)。Sumj 為在該範圍j中之像素與其原始像素間之差的總和。SumNbPixj 為在該畫框區域中之像素數目,及其像素值屬於範圍j。For each color component Y, U, B (or RGB) (2411), each SAO type is evaluated. For each SAO type (2412) and each eo_sign_method_X (2416), in the initial step 2401, the variables Sum j and SumNbPix j are set to zero. The current picture frame area 2403 includes N pixels. j is the current range number, used to determine the four edge indexes for the edge offset type shown in FIG. 7B, or the 32 ranges for the pixel values with offset type shown in FIG. 8) . Sum j is the sum of the differences between pixels in the range j and their original pixels. SumNbPix j is the number of pixels in the frame area, and its pixel value belongs to the range j.

在步驟2402中,用以連續考量現行畫框區域的各個像素Pi的變數i被設定為零。然後,畫框區域2403的第一像素Pi 在步驟2404中被抽出。在步驟2405中,現行像素的類係藉由檢查在圖27A及27B中界定的狀態加以決定。然後,在步驟2405執行測試。在步驟2405期間,執行檢查,以決定是否像素值Pi 的類對應於圖27A及27B之值“以上皆非”。In step 2402, the variable i used to continuously consider each pixel Pi of the current frame area is set to zero. Then, the first pixel P i of the picture frame area 2403 is extracted in step 2404. In step 2405, the type of the current pixel is determined by checking the state defined in FIGS. 27A and 27B. Then, in step 2405, a test is performed. During step 2405, a check is performed to determine whether the pixel P i value corresponds to the value of class "None of the above" of FIGS. 27A and 27B.

如果結果為正,則在步驟2408中值“i”增量,以考量畫框區域2403的下一像素。If the result is positive, the value "i" is incremented in step 2408 to consider the next pixel of the frame area 2403.

否則,如果在步驟2406中,結果為負,則下一步驟為2407,其中相關SumNbPixj (即,在步驟2405中決定的用於該類的像素數目的總和)被增量及在Pi 與其原始值

Figure 02_image036
間之差被加至Sumj 。在下一步驟2408中,變數i被增量,以考量畫框區域2403的下一像素。Otherwise, if in step 2406, the result is negative, then the next step 2407, where the relevant SumNbPix j (i.e., the sum of the number of pixels for the class determined at step 2405) P i is incremented and in its Original value
Figure 02_image036
The difference between them is added to Sum j . In the next step 2408, the variable i is incremented to consider the next pixel of the frame area 2403.

然後,測試2409被執行,以決定是否所有像素已經被考量及分類。如果結果為負,則程序回到上述步驟2404。否則,結果為正,則程序進行至步驟2410,其中用於現行色彩成分X的變數CTUStats、SAO型SAO _type、eo_sign_method_X及現行類j被設定等於用於第一值的Sumj 及用於第二值的SumNbPixj Then, test 2409 is executed to determine whether all pixels have been considered and classified. If the result is negative, the procedure returns to step 2404 above. Otherwise, the result is positive, the routine proceeds to step 2410, where a variable current CTUStats color component X, the SAO type SAO - _type, eo_sign_method_X and existing class j is set equal to a first value for the first and the Sum j SumNbPix j with two values.

程序然後對於各個eo_sign_method_X作環路進行(2417),直到最後一個為止(2418)及用於SAO型(2413),直到最後一個(2414)為止。當到達最後一個時,程序處理下一成分(2415)。The program then loops (2417) for each eo_sign_method_X until the last one (2418) and for the SAO type (2413) until the last one (2414). When the last one is reached, the program processes the next component (2415).

參考圖13所述,這些變數可以被使用以計算例如用於每一類j的最佳偏移參數Offsetj 。該偏移Offsetj 可以為該類j的像素與其原始值間之差的平均。因此,Offsetj 由以下公式所給定:

Figure 02_image038
As described with reference to FIG. 13, these variables can be used to calculate, for example, the optimal offset parameter Offset j for each category j . The offset Offset j may be the average of the difference between the pixels of this type j and its original value. Therefore, Offset j is given by the following formula:
Figure 02_image038

注意,偏移Offsetj 為整數值。因此,在此公式中界定的碼率可以被捨去,到最接近值或者使用天花板或地板函數。Note that Offset j is an integer value. Therefore, the code rate defined in this formula can be rounded down to the nearest value or use the ceiling or floor function.

各個偏移Offsetj 以失真表示時為最佳偏移Ooptj。Each offset Offset j is the optimal offset Ooptj when represented by distortion.

因此,在圖24中,由於在邊緣偏移符號法上的新環路係被加入(2416、2417、2418),以取得用於各個邊緣偏移符號法統計CTUStats(2410),所以,表CTUStats具有額外尺寸,以相較於圖13設定用於邊緣偏移符號法的統計。Therefore, in FIG. 24, since the new loop system on the edge offset symbol method is added (2416, 2417, 2418) to obtain the statistical CTUStats (2410) for each edge offset symbol method, the table CTUStats It has additional dimensions to set the statistics for the edge offset sign method compared to FIG. 13.

為評估SAO參數的合併的RD成本,編碼器使用在表CTUCStats中的統計集。依據用於SAO左併的以下例子及藉由考量用於Luma Left_Type_Y的類型及四個相關偏移O_Left_O、O_Left_1、O_Left_2、O_Left_3,失真可以藉由以下公式取得。

Figure 02_image040
To evaluate the combined RD cost of SAO parameters, the encoder uses the statistical set in the table CTUCStats. According to the following example for SAO left union and by considering the type used for Luma Left_Type_Y and the four related offsets O_Left_O, O_Left_1, O_Left_2, O_Left_3, the distortion can be obtained by the following formula.
Figure 02_image040

變數Shift被設計用於失真調整。失真應為負,因為SAO為正濾波。The variable Shift is designed for distortion adjustment. Distortion should be negative because SAO is positive filtering.

相同計算可以應用至色度成分。碼率失真成本的λ對於此三個成分為固定的。對於被合併有左CTU的SAO參數,碼率只是1旗標,其被CABAC編碼。The same calculation can be applied to the chroma component. The rate distortion cost λ is fixed for these three components. For SAO parameters that are merged with the left CTU, the code rate is only 1 flag, which is CABAC encoded.

圖25為流程圖,例示執行編碼器的步驟,以決定用於一群(畫框或切片)CTU的SAO參數。FIG. 25 is a flowchart illustrating the steps of performing an encoder to determine SAO parameters for a group (frame or slice) of CTUs.

在此實施例中,預定符號法係在編碼器側依據取決於色彩成分的多數限定值N加以選擇。因此,由圖24的程序所取得的統計可以被使用以決定用於亮度及分別用於兩色度成分的最佳邊緣類及最佳eo_sign_method。In this embodiment, the predetermined symbol method is selected on the encoder side according to the majority limit value N depending on the color component. Therefore, the statistics obtained by the procedure of FIG. 24 can be used to determine the best edge class and the best eo_sign_method for the luminance and the two chroma components, respectively.

程序以現行CTU開始(2501)。首先,用於所有可能SAO型及類的統計係被累積在變數CTUStats(2502)中。步驟2502的程序係參考圖24加以描述。The procedure starts with the current CTU (2501). First, the statistical systems used for all possible SAO types and classes are accumulated in the variable CTUStats (2502). The procedure of step 2502 is described with reference to FIG. 24.

依據在變數CTUStats中的值組,用於SAO左併的RD成本被評估,是否左CTU是在現行切片(2503)中作為SAO上併的RD成本(2504)。由於在CTUStats中之統計(2502),新SAO參數係被評估,針對亮度(2505)、兩色度成分(2509)、及各個eo_sign_method_chroma(2518)。Based on the value set in the variable CTUStats, the RD cost for SAO left merge is evaluated, whether the left CTU is used as the RD cost for SAO merge (2504) in the current slice (2503). Due to the statistics in CTUStats (2502), the new SAO parameters are evaluated for brightness (2505), dichromatic components (2509), and each eo_sign_method_chroma (2518).

對於各個SAO型(2506)及各個 eo_sign_method_luma(2517),用於帶偏移分類的最佳RD偏移及其他參數係被取得(2507)。由於其個別SAO參數及亮度符號法(2508),所有RD成本被計算。以相同方式針對兩色度成分,最佳RD偏移及參數係被選擇(2511)。由於其個別SAO參數與色度符號法(2512),所有RD成本係被計算。所有此RD成本然後被比較,以選擇最佳SAO參數組(2515)。這些RD成本也相比較,以獨立去能用於亮度及色度成分(2513、2514)的SAO。使用新SAO參數組(2515)係與由左及上CTU“合併”或共享(2516)的SAO參數組相比較。For each SAO type (2506) and each eo_sign_method_luma (2517), the best RD offset for offset classification and other parameters are obtained (2507). Due to its individual SAO parameters and luminance sign method (2508), all RD costs are calculated. For the two chroma components in the same way, the optimal RD offset and parameter system are selected (2511). Due to its individual SAO parameters and chromatic sign method (2512), all RD costs are calculated. All this RD costs are then compared to select the best SAO parameter set (2515). These RD costs are also compared, with SAOs that can be used independently for the luminance and chrominance components (2513, 2514). The use of the new SAO parameter set (2515) is compared to the SAO parameter set "merged" or shared (2516) by the left and upper CTUs.

第二群實施例(第二態樣)Second group of embodiments (second aspect)

依據本發明第二態樣,提供一種執行取樣自適應偏移(SAO)濾波取得邊緣偏移的方法,其中當“符號”參數N為嚴格正時,該偏移該至少部份的符號係被顯式地發信。According to the second aspect of the present invention, a method of performing sample adaptive offset (SAO) filtering to obtain an edge offset is provided, wherein when the "symbol" parameter N is strictly positive, the at least part of the offset symbol is Send the letter explicitly.

換句話說,第二態樣提供對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中該方法更包含在該位元流中發信該多數邊緣偏移的至少一邊緣偏移的符號。In other words, the second aspect provides a method of performing sample adaptive offset (SAO) filtering on an image including a majority of image parts. The method includes: Obtain most edge offsets to perform SAO filtering; The method further includes signaling at least one edge offset symbol of the majority edge offset in the bit stream.

依據第二態樣的第一實施例,該邊緣偏移的符號係被發信於該多數邊緣偏移的所有邊緣偏移,其中,決定邊緣偏移的索引的符號函數中所用的符號參數N為正。According to the first embodiment of the second aspect, the sign of the edge offset is sent to all edge offsets of the majority of edge offsets, where the sign parameter N used in the sign function that determines the index of the edge offset Is positive.

依據其他實施例,當以下條件的至少之一滿足時,邊緣偏移的符號被發信: -分類使用新邊緣符號法用於此邊緣偏移; -符號函數的輸入值被修改用於邊緣偏移分類; -用以決定邊緣偏移的索引的符號函數中所用的參數N為嚴格正。According to other embodiments, when at least one of the following conditions is met, the edge shifted symbol is sent: -Classification uses the new edge symbol method for this edge offset; -The input value of the sign function is modified for edge offset classification; -The parameter N used in the sign function used to determine the index of the edge offset is strictly positive.

這些實施例的優點為相較於當符號法的值N不是零時,用於邊緣偏移的偏移的隱式符號發信的編碼效率增加。這是意想不到的結果,因為已知邊緣偏移分類的偏移的隱式符號信號以傳統符號法造成編碼效率的降低。The advantage of these embodiments is that the coding efficiency of the implicit symbol signaling for the offset of the edge offset is increased when the value N of the symbol method is not zero. This is an unexpected result, because the offset implicit symbol signal of the edge offset classification is known to cause a reduction in coding efficiency with the traditional symbol method.

圖26為流程圖,例示依據第二態樣的第二實施例之解碼SAO參數的程序步驟。FIG. 26 is a flowchart illustrating a procedure of decoding SAO parameters according to the second embodiment of the second aspect.

依據此第二實施例,如果決定邊緣偏移的索引的符號函數中所用之所有符號參數N係高於預定臨限的話,則邊緣偏移的符被發信用於多數邊緣偏移的所有邊緣偏移。According to this second embodiment, if all the sign parameters N used in the sign function that determines the index of the edge offset are higher than the predetermined threshold, the sign of the edge offset is sent for all edge offsets of the majority of edge offsets shift.

因此,只有當符號參數N對於所有偏移為高,即當用於決定這些邊緣偏移的索引的符號函數中所用之所有符號參數N高於預定臨限時,符號才被發信。Therefore, the symbol is sent only when the symbol parameter N is high for all offsets, that is, when all the symbol parameters N used in the symbol function used to determine the index of these edge offsets are higher than a predetermined threshold.

相較於圖10所示之程序,本程序執行額外環路,其包含如下所述之額外模組2611、2612、2613及2614。Compared with the procedure shown in FIG. 10, this procedure performs an additional loop, which includes additional modules 2611, 2612, 2613, and 2614 as described below.

在初始步驟2602中,“sao_type_idx_X”語法元件被讀取與解碼。代表此語法元件的碼字元可以使用固定長度碼或可以使用任何算術編碼的方法。語法元件sao_type_idx_X使得用於畫框區域的SAO的類型為以色彩成分Y或兩色度成分U&V處理的決定。In the initial step 2602, the "sao_type_idx_X" syntax element is read and decoded. The code character representing this syntax element can use a fixed-length code or can use any arithmetic coding method. The syntax element sao_type_idx_X makes the type of SAO used in the picture frame area a decision to process with the color component Y or the two-chroma component U&V.

另外,雖YUV色彩成分被使用於HEVC(有時稱Y、Cr及Cb成分),但將了解的是,其他視訊編碼方案其他色彩成分可以被使用,例如,RGB色彩成分。本發明之技術並不限於與YUV色彩成分一起使用,並且也可以與RGB色彩成分或任何其他色彩成分一起使用。In addition, although YUV color components are used in HEVC (sometimes called Y, Cr, and Cb components), it will be understood that other color components of other video coding schemes may be used, for example, RGB color components. The technique of the present invention is not limited to use with YUV color components, and can also be used with RGB color components or any other color components.

在相同步驟2602中,執行一測試,以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”表示如果X被設定等於Y,則對於Y,此畫框區域(CTU)沒有SAO,及表示如果X被設定等於U及V,則用於U及V,沒有SAO用於此畫框區域。SAO參數的決定完成及程序進行至步驟2608。否則,如果“sao_type_idx”為嚴格正,則表示在此位元流中,此CTU存在有SAO參數。In the same step 2602, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that if X is set equal to Y, then for Y, this frame area (CTU) has no SAO, and if X is set equal to U and V, it is used for U and V, and there is no SAO Used for this picture frame area. The determination of the SAO parameters is completed and the process proceeds to step 2608. Otherwise, if "sao_type_idx" is strictly positive, it means that there is a SAO parameter for this CTU in this bit stream.

然後,程序進行至步驟2606,其中環路被執行四次疊代。四次疊代係被執行於步驟2607中,其中偏移j的絕對值被從位元流中讀取及解碼。這四個偏移對應於SAO邊緣偏移(見圖27A或27B)的四個邊緣索引的偏移(O1、O2、O3、O4)的四個絕對值或者對應於有關於SAO帶偏移(見圖8)的四個範圍的偏移的絕對值。Then, the process proceeds to step 2606, where the loop is executed four iterations. The four iterations are performed in step 2607, where the absolute value of offset j is read and decoded from the bit stream. These four offsets correspond to the four absolute values of the four edge index offsets (O1, O2, O3, O4) of the SAO edge offset (see FIGS. 27A or 27B) or correspond to the SAO band offset ( See Figure 8) for the absolute values of the four ranges of offset.

在步驟2607後,程序進行至步驟2603,其中執行測試,以決定SAO的類型是否對應於帶偏移型(sao_type_ide_X==1)。After step 2607, the process proceeds to step 2603, where a test is performed to determine whether the type of SAO corresponds to the band offset type (sao_type_ide_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟2609及2610中被解碼,除了具有零值的各個偏移之外,在執行以下步驟2604之前,以讀取於位元流中及解碼SAO帶的位置“sao_band_position_X”如於圖8所例示。If the result is positive, the symbol for the offset with offset mode is decoded in steps 2609 and 2610, except for each offset with a value of zero, before performing the following step 2604 to read the bit The position "sao_band_position_X" in the stream and the decoded SAO band is illustrated in FIG. 8.

如果在步驟2603中的結果為負 (“sao_tye_idx_X”被設定等於2),這表示邊緣偏移型被使用。如果X等於Y,則讀取語法元件為“sao_eo_class_luma”及如果X設定等於U及V,則讀取語法元件為 “sao_eo_class_chroma”。因此,邊緣偏移類(對應於方向0、45、90及135度)係於步驟2605中被從位元流抽出。If the result in step 2603 is negative ("Sao_tye_idx_X" is set equal to 2), which means that the edge offset type is used. If X equals Y, the read syntax element is "sao_eo_class_luma" and if X is set equal to U and V, the read syntax element is "Sao_eo_class_chroma". Therefore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream in step 2605.

當四個偏移被抽出時,程序進行至步驟2611,其中,其測試是否邊緣偏移符號法 eo_sign_method_X(2614),即對應於在現行色彩成分的組表中的N值的索引係大於臨限Th(2611)。如果是,則四個符號(2612)被由位元流抽出(2613)。然後,SAO參數的讀取完成及程序進行至步驟2608。When four offsets are extracted, the process proceeds to step 2611, where it tests whether the edge offset sign method eo_sign_method_X (2614), that is, the index system corresponding to the N value in the group table of the current color component is greater than the threshold Th (2611). If yes, then four symbols (2612) are extracted from the bit stream (2613). Then, the reading of the SAO parameters is completed and the procedure proceeds to step 2608.

此實施例的優點可以是相較於當用於符號法中之值N為高時,用於邊緣偏移分類的偏移的隱式符號發信,編碼效率的增加。The advantage of this embodiment may be that the encoding efficiency is increased compared to when the value N used in the symbol method is high, the implicit symbol used for edge offset classification is sent.

也可以注意到在此實施例中,邊緣偏移符號法可以是用於該序列的所有CTU都相同或者逐切片地選擇。當邊緣偏移符號法一直具有相同值時,模組2611可以不被使用。It can also be noted that in this embodiment, the edge offset symbol method may be that all CTUs used for the sequence are the same or selected slice by slice. When the edge offset sign method always has the same value, the module 2611 may not be used.

用於第二態樣的這些實施例的邊緣偏移的說明現將參考圖27A及27B加以提供。A description of the edge offset for these embodiments of the second aspect will now be provided with reference to FIGS. 27A and 27B.

邊緣偏移型涉及藉由比較其像素值與兩相鄰像素的值,來決定用於各個像素的邊緣索引。再者,這兩相鄰像素取決於一參數,其指明這兩相鄰像素相對於現行像素的方向。這些方向如於圖7A所示為0度(水平方向)、45度(對角方向)、90度(垂直方向)及135度(第二對角方向)。The edge offset type involves determining the edge index for each pixel by comparing its pixel value with the values of two adjacent pixels. Furthermore, the two adjacent pixels depend on a parameter that indicates the direction of the two adjacent pixels relative to the current pixel. These directions are 0 degrees (horizontal direction), 45 degrees (diagonal direction), 90 degrees (vertical direction), and 135 degrees (second diagonal direction) as shown in FIG. 7A.

圖27A顯示予以應用至解碼器側的特定像素的像素值的偏移值的表,當值N係大於臨限Th。FIG. 27A shows a table of offset values to be applied to pixel values of specific pixels on the decoder side, when the value N is greater than the threshold Th.

當C的值低於相鄰像素Cn1及Cn2的兩值時,予以加至像素C的像素值的偏移為“O1”(O1可以為正或負或等於0)。當C的像素值低於相鄰像素(Cn1或Cn2)的一像素值及C等於相鄰像素的一值時,予以加至此像素取樣值的偏移為“O2”(O2可以為正或負或等於0)。When the value of C is lower than the two values of the adjacent pixels Cn1 and Cn2, the offset of the pixel value added to the pixel C is "O1" (O1 may be positive or negative or equal to 0). When the pixel value of C is lower than a pixel value of the adjacent pixel (Cn1 or Cn2) and C is equal to a value of the adjacent pixel, the offset added to the sample value of this pixel is "O2" (O2 can be positive or negative Or equal to 0).

當c的像素值低於相鄰像素(Cn1或Cn2)的像素值之一及C的像素值等於相鄰像素的一值時,予以應用至此像素取樣的偏移為“O3”(O3可以為正或負或等於0)。當C的值大於Cn1或Cn2的兩值時,予以應用至此像素取樣的偏移為“O4”(O4可以為正或負或等於0)。When the pixel value of c is lower than one of the pixel values of the neighboring pixels (Cn1 or Cn2) and the pixel value of C is equal to a value of the neighboring pixels, the offset applied to this pixel sampling is "O3" (O3 can be Positive or negative or equal to 0). When the value of C is greater than the two values of Cn1 or Cn2, the offset applied to this pixel sample is "O4" (O4 can be positive or negative or equal to 0).

當以上狀況均不符合現行取樣及其相鄰像素時,則沒有偏移值被加入至現行像素C,如表中之邊緣索引值“2”所描述。When none of the above conditions match the current sampling and its neighboring pixels, no offset value is added to the current pixel C, as described by the edge index value "2" in the table.

重要的是注意到,在邊緣偏移型的特定狀況中,各個偏移(O1、O2、O3、O4)的絕對值在位元流中被編碼。該符號也被編碼。It is important to note that in the specific case of the edge offset type, the absolute value of each offset (O1, O2, O3, O4) is encoded in the bitstream. The symbol is also encoded.

在此圖27A中,取樣C、Cn1及Cn2對應於圖7A中所繪者。In this FIG. 27A, the samples C, Cn1, and Cn2 correspond to those depicted in FIG. 7A.

圖27B顯示一表,其給出當值N低於或等於臨限Th時,在解碼器側的予以應用至特定像素的像素值的偏移值。FIG. 27B shows a table that gives the offset value applied to the pixel value of a specific pixel on the decoder side when the value N is lower than or equal to the threshold Th.

當C的值低於相鄰像素Cn1及Cn2的兩值時,予以加至像素C的像素值的偏移為“O1”(O1可以為正或負或等於0)。當C的像素值為低於相鄰像素(Cn1或Cn2)的一像素值及C等於其相鄰像素的一值時,予以加至此像素取樣值的偏移為“+O2”(此偏移為正或等於0)。When the value of C is lower than the two values of the adjacent pixels Cn1 and Cn2, the offset of the pixel value added to the pixel C is "O1" (O1 may be positive or negative or equal to 0). When the pixel value of C is lower than a pixel value of the neighboring pixel (Cn1 or Cn2) and C is equal to a value of its neighboring pixel, the offset added to the sampled value of this pixel is "+O2" (this offset Is positive or equal to 0).

當c的像素值低於其相鄰像素的像素值之一及C的像素值等於其相鄰像素的一值時,予以應用至像素取樣的偏移為“-O3”(此偏移為負或等於0)。當C的值大於Cn1或Cn2的兩值時,予以應用至此像素取樣的偏移為“O4”(O4可以為正或負或等於0)。When the pixel value of c is lower than one of the pixel values of its neighboring pixels and the pixel value of C is equal to a value of its neighboring pixels, the offset applied to pixel sampling is "-O3" (this offset is negative Or equal to 0). When the value of C is greater than the two values of Cn1 or Cn2, the offset applied to this pixel sample is "O4" (O4 can be positive or negative or equal to 0).

當以上狀況均不符合現行取樣及其相鄰像素時,則偏移值未被加入至現行像素C,如表之邊緣索引值“2”所繪。When none of the above conditions match the current sampling and its neighboring pixels, the offset value is not added to the current pixel C, as plotted by the edge index value "2" in the table.

重要的是注意,對於邊緣偏移型的特定情況,各個偏移(O1、O2、O3、O4)的絕對值被編碼於位元流中。予以應用至各個移的符號係取決於現行像素所屬的邊緣索引(或者在HEVC規格中之邊緣索引)。依據圖27B中所示之表,對於邊緣索引1(O2),應用了正偏移。對於邊緣索引3(O3),應用負偏移至現行像素。對應於邊緣索引1及邊緣索引4,符號被編碼/解碼。It is important to note that for the specific case of the edge offset type, the absolute value of each offset (O1, O2, O3, O4) is encoded in the bitstream. The symbol to be applied to each shift depends on the edge index to which the current pixel belongs (or the edge index in the HEVC specification). According to the table shown in FIG. 27B, for edge index 1 (O2), a positive offset is applied. For edge index 3 (O3), apply a negative offset to the current pixel. Corresponding to edge index 1 and edge index 4, symbols are encoded/decoded.

在此圖27B中,取樣C、Cn1、Cn2對應於如圖7A中所繪者。In this FIG. 27B, the samples C, Cn1, and Cn2 correspond to those depicted in FIG. 7A.

在額外實施例中,符號被CABAC編碼。另外,不需上下文。此額外實施例的優點為因為符號經常等於隱式符號,所以編碼效率增加。In additional embodiments, the symbols are CABAC encoded. In addition, no context is required. The advantage of this additional embodiment is that since the symbol is often equal to the implicit symbol, the coding efficiency is increased.

圖28為流程圖,例示依據第二態樣的第三實施例之用以解碼SAO參數的程序步驟。FIG. 28 is a flowchart illustrating a procedure for decoding SAO parameters according to the third embodiment of the second aspect.

依據此第三實施例,對於其符號被發信的至少一邊緣偏移屬於峰及谷架構。更明確地說,只要一預定符號法被使用以決定邊緣偏移的索引,則至少一邊緣偏移的符號被發信。According to this third embodiment, at least one edge offset for which the symbol is signaled belongs to the peak and valley structure. More specifically, as long as a predetermined symbol method is used to determine the edge offset index, at least one edge offset symbol is sent.

在本例子中,只要符號法被用以知道邊緣偏移的符號,則邊緣偏移的符號對於峰及谷類為顯式及對於其他兩類為隱式。這表示對於如圖27B中示之偏移O1及O4,符號被傳送於位元流中。In this example, as long as the sign method is used to know the sign of the edge shift, the sign of the edge shift is explicit for peaks and valleys and implicit for the other two classes. This means that for the offsets O1 and O4 as shown in FIG. 27B, the symbols are transferred in the bit stream.

在初始步驟2802中,“sao_type_idx_X”語法元件被讀取及解碼。代表此語法元件的碼字元可以使用固定長度碼或可以使用任何算術編碼的方法。此語法元件sao_type_idx_X致使決定應用於該畫框區域的SAO型以色彩成分Y或兩色度成分U&V加以處理。In the initial step 2802, the "sao_type_idx_X" syntax element is read and decoded. The code character representing this syntax element can use a fixed-length code or can use any arithmetic coding method. The syntax element sao_type_idx_X causes the SAO type determined to be applied to the frame area to be processed with the color component Y or the two-chrominance component U&V.

另外,雖然YUV色彩成分被用於HEVC中(有時稱Y、Cr及Cb成分),但應了解的是,也可以使用其他視訊編碼方案,其他色彩成分,例如RGB色彩成分。本發明之技術並不限於用於與YUV色彩成分一起使用,也可以與RGB色彩成分或任何其他色彩成分一起使用。In addition, although YUV color components are used in HEVC (sometimes called Y, Cr, and Cb components), it should be understood that other video encoding schemes, other color components, such as RGB color components, can also be used. The technique of the present invention is not limited to use with YUV color components, but can also be used with RGB color components or any other color components.

在相同步驟2802中,執行測試以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”表示對於如果X被設定等於Y,對於Y沒有SAO用於此畫框區域(CTU),以及,如果X被設定等於U及V,則對於U及V,此畫框區域沒有SAO。SAO參數的決定完成及程序進行至步驟2808。否則,如果“sao_type_idx”為嚴格正,則表示SAO參數存在於位元流中的CTU。In the same step 2802, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" equals "0", it means that if X is set equal to Y, there is no SAO for Y for this frame area (CTU), and if X is set equal to U and V, for U and V, this There is no SAO in the box area. The decision of the SAO parameter is completed and the procedure proceeds to step 2808. Otherwise, if "sao_type_idx" is strictly positive, it means that the SAO parameter exists in the CTU in the bitstream.

然後,程序進行至步驟2806,其中執行環路作四次疊代。該四次疊代被執行於步驟2807中,其中偏移j的絕對值被由位元流讀取及解碼。這四偏移對應於SAO邊緣偏移(見圖27A或27B)的四邊緣索引的偏移(O1、O2、O3、O4)的四個絕對值或者對應於SAO帶偏移(見圖8)的四個範圍相關的偏移的四個絕對值。Then, the process proceeds to step 2806, where the loop is executed four iterations. The four iterations are performed in step 2807, where the absolute value of the offset j is read and decoded by the bit stream. These four offsets correspond to the four absolute values of the four edge index offsets (O1, O2, O3, O4) of the SAO edge offset (see Figure 27A or 27B) or to the SAO band offset (see Figure 8) Four absolute values of the offset associated with the four ranges.

在步驟2807後,程序進行至步驟2803,其中執行一測試以決定是否SAO的類型對應於帶偏移型(sao_type_idx_X==1)。After step 2807, the process proceeds to step 2803, where a test is performed to determine whether the type of SAO corresponds to the offset type (sao_type_idx_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟2809及2810中被解碼,除了具有零值的各個偏移以外,在以下步驟2804被執行之前,以讀取位元流及解碼SAO帶的位置“sao_band_position_X”如於圖8所示。If the result is positive, the symbol for the offset with offset mode is decoded in steps 2809 and 2810, except for each offset with a value of zero, to read the bit stream before the following step 2804 is executed The position of the decoded SAO band "sao_band_position_X" is shown in FIG. 8.

如果在步驟2803中之結果為負 (“sao_type_idx_X”被設定等於2),則表示邊緣偏移型被使用。如果X等於Y,則讀取語法元件為“sao_eo_class_luma” ,及如果X被設定等於U及V,則讀取語法元件為 “sao_eo_class_chroma"。因此,邊緣偏移類(對應於方向0、45、90及135度)係在步驟2805中由位元流抽出。If the result in step 2803 is negative ("Sao_type_idx_X" is set equal to 2), indicating that the edge offset type is used. If X equals Y, read the syntax element as "sao_eo_class_luma" , And if X is set equal to U and V, the read syntax element is "Sao_eo_class_chroma". Therefore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream in step 2805.

對於各個偏移(2812),決定是否偏移為峰(j==1)或者谷(j==4)偏移,即O1或O4(2815)。如果是,則偏移的符號被由位元流抽出(2813)。否則,符號為隱式並設定為如圖27B所示。然後,SAO參數的讀取完成及程序進行至步驟2808。For each offset (2812), determine whether the offset is a peak (j==1) or valley (j==4) offset, that is, O1 or O4 (2815). If so, the offset sign is extracted from the bit stream (2813). Otherwise, the symbol is implicit and set as shown in FIG. 27B. Then, the reading of the SAO parameters is completed and the procedure proceeds to step 2808.

此實施例優點可以是相較於用於邊緣偏移分類的偏移的隱式符號發信,編碼效率增加,以及,相較於用於邊緣偏移分類的顯式符號發信的編碼效率增加。The advantage of this embodiment may be that the coding efficiency of the implicit symbol signaling compared to the offset used for edge offset classification is increased, and the coding efficiency of the signaling transmission increased compared to the explicit symbol used for edge offset classification .

在另一實施例中,符號被CABAC編碼。此額外實施例之優點為編碼效率增加,因為符號經常等於隱式符號。In another embodiment, the symbols are CABAC encoded. The advantage of this additional embodiment is increased coding efficiency because the symbol is often equal to the implicit symbol.

圖29為流程圖,例示依據第二態樣的第四實施例之解碼SAO參數的程序步驟。FIG. 29 is a flowchart illustrating a procedure of decoding SAO parameters according to the fourth embodiment of the second aspect.

依據此第四實施例,邊緣偏移之符號只用於邊緣偏移才發信,其中用以決定這些邊緣偏移的索引的符號參數N係高於預定臨限。According to this fourth embodiment, the symbols of edge offsets are only used for edge offsets, and the symbol parameter N used to determine the indexes of these edge offsets is higher than a predetermined threshold.

換句話說,邊緣偏移的符號對於峰及谷類為顯式(即其被發信於位元流中)及對於其他另兩個類為隱式的。因此,當N為大於或等於臨限時,符號被傳送用於偏移O1及O4,如於圖27B所示。In other words, the sign of the edge offset is explicit for peaks and valleys (ie it is signaled in the bitstream) and implicit for the other two classes. Therefore, when N is greater than or equal to the threshold, the symbol is transmitted for offsets O1 and O4, as shown in FIG. 27B.

相較於示於圖28的程序,本程序包含如下所述的額外模組2914及2911。Compared to the procedure shown in FIG. 28, this procedure includes additional modules 2914 and 2911 as described below.

在初始步驟2902中,“sao_type_idx_X”語法元件被讀取及解碼。代表此語法元件的碼字元可以使用固定長度碼或可以使用算術編碼的任意方法。語法元件sao_type_idx_X完成應用至畫框區域的SAO的類型被處理為作色彩成分Y或兩色度成分U&V的決定。In the initial step 2902, the "sao_type_idx_X" syntax element is read and decoded. The codeword representing this syntax element can use a fixed-length code or any method that can use arithmetic coding. The syntax element sao_type_idx_X completes the application of the type of SAO applied to the frame area to be determined as the color component Y or the two-chrominance component U&V.

另外,雖然YUV色彩成分被用於HEVC(有時稱Y、Cr及Cb成分)中,但應了解其他視訊編碼方案,其他色彩成分也可以使用,例如RGB色彩成分。本發明之技術並不限於與YUV色彩成分一起使用,也可以與RGB色彩成分或任何其他色彩成分一起使用。In addition, although YUV color components are used in HEVC (sometimes called Y, Cr, and Cb components), it should be understood that other video encoding schemes, other color components can also be used, such as RGB color components. The technique of the present invention is not limited to use with YUV color components, but can also be used with RGB color components or any other color components.

在相同步驟2902中,執行測試,以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”表示如果X被設定等於Y,對於Y,此畫框區域(CTU)沒有SAO,及如果X被設定等於U及V,則對於U及V的此畫框區域沒有SAO。SAO參數的決定完成及程序進行至步驟2908。否則,如果“sao_type_idx”為嚴格正,則表示在位元流中的此CTU存在有SAO參數。In the same step 2902, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that if X is set equal to Y, there is no SAO for this frame area (CTU) for Y, and if X is set equal to U and V, there is no frame area for U and V SAO. The decision of the SAO parameter is completed and the procedure proceeds to step 2908. Otherwise, if "sao_type_idx" is strictly positive, it means that there is a SAO parameter for this CTU in the bit stream.

然後,程序進行至步驟2906,其中環路執行四次疊代。四次疊代可以執行於步驟2907,其中偏移j的絕對值係由位元流讀取與解碼。這四個偏移對應於SAO邊緣偏移(見圖27A或27B)的四個邊緣索引的偏移(O1、O2、O3、O4)的四個絕對值或者對應於SAO帶偏移(見圖8)的四個範圍有關的偏移的四個絕對值。Then, the procedure proceeds to step 2906, where the loop performs four iterations. Four iterations can be performed in step 2907, where the absolute value of the offset j is read and decoded by the bit stream. These four offsets correspond to the four absolute values of the four edge index offsets (O1, O2, O3, O4) of the SAO edge offset (see Figure 27A or 27B) or to the SAO band offset (see Figure 8) Four absolute values of offsets related to the four ranges.

在步驟2907,程序進行至步驟2903,其中執行測試以決定是否SAO的類型對應於帶偏移型 (sao_type_idx_X==1)。In step 2907, the process proceeds to step 2903, where a test is performed to determine whether the type of SAO corresponds to the band offset type (sao_type_idx_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟2909及2910被解碼,除了具有零值的各個偏移外,在以下步驟2904執行之前,以讀取位元流並解碼SAO帶的“sao_band_position_X”,如於圖8所示。If the result is positive, the symbol for the offset with offset mode is decoded in steps 2909 and 2910, except for each offset with a value of zero, to read and decode the bit stream before the following step 2904 is executed The "sao_band_position_X" of the SAO band is shown in Figure 8.

如果在步驟2903的結果為負 (“sao_type_idx_X”被設定等於2),則表示邊緣偏移型被使用。如果X等於Y,則讀取語法元件為“sao_eo_class_luma” ,以及如果X被設定等於U及V,則讀取語法元件為“sao_eo_class_chroma”。因此,邊緣偏移類(對應於方向0、45、90及135度)在步驟2905被由位元流抽出。If the result in step 2903 is negative ("Sao_type_idx_X" is set equal to 2), indicating that the edge offset type is used. If X equals Y, read the syntax element as "sao_eo_class_luma" , And if X is set equal to U and V, the read syntax element is "sao_eo_class_chroma". Therefore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream in step 2905.

當已抽出四個偏移時,程序進行至步驟2911,其中測試是否邊緣偏移符號法 eo_sign_method_X(2914),即對應於用於現行色彩成分的N值(在轉換表“組”中)的索引係大於臨限Th(2911)。When four offsets have been extracted, the process proceeds to step 2911, where it is tested whether the edge offset sign method eo_sign_method_X (2914), that is, the index system corresponding to the N value (in the conversion table "group") for the current color component is greater than the threshold Th (2911).

如果是,則對於四偏移各者(2912),決定是否偏移為峰(j==1)或谷(j==4)偏移,即O1或O4(2815)。如果是,則偏移的符號被由位元流抽出(2913)。否則,符號為隱式並被設定為如圖27B所描繪。然後,SAO參數的讀取完成及程序進行至步驟2908。If so, for each of the four offsets (2912), decide whether the offset is a peak (j==1) or valley (j==4) offset, ie O1 or O4 (2815). If so, the offset sign is extracted from the bit stream (2913). Otherwise, the symbol is implicit and set as depicted in Figure 27B. Then, the reading of the SAO parameters is completed and the procedure proceeds to step 2908.

此實施例之優點可以是相較於邊緣偏移分類之隱式符號發信的編碼效率增加以及相較於邊緣偏移分類之偏移的顯式符號發信的編碼效率增加。相較於第三實施例,編碼效率也增加。The advantage of this embodiment may be increased coding efficiency of implicit symbol signaling compared to edge offset classification and increased coding efficiency of explicit symbol signaling compared to edge offset classification. Compared with the third embodiment, the coding efficiency is also increased.

依據實施例,邊緣偏移的符號只發信於邊緣偏移,其中用於決定這些邊緣偏移的索引的符號參數N不是零。According to an embodiment, the symbols of the edge offset are only sent to the edge offset, where the symbol parameter N used to determine the index of these edge offsets is not zero.

依據這些實施例,臨限值等於0,以使當符號法為傳統符號法(N=0)時,符號值對於邊緣偏移分類的所有偏移為隱式的,及當符號法具有N>0時,用於峰及谷類的偏移的符號為顯式的(即送於位元流中)。這可以提供很有趣的編碼效率改良。According to these embodiments, the threshold value is equal to 0, so that when the sign method is the traditional sign method (N=0), the sign value is implicit for all offsets of the edge offset classification, and when the sign method has N> At 0, the sign used for the peak and valley offsets is explicit (that is, sent in the bit stream). This can provide very interesting coding efficiency improvements.

圖30為流程圖,例示依據第二態樣的第五實施例之解碼SAO參數的程序步驟。FIG. 30 is a flowchart illustrating a procedure of decoding SAO parameters according to the fifth embodiment of the second aspect.

依據第五實施例,邊緣偏移的符號只被發信用於亮度成分,即用於邊緣偏移分類的偏移的符號對於圖27A的亮度成分為顯式,及對於圖7B之色度成分為隱式的。According to the fifth embodiment, the symbol of the edge offset is only sent for the luminance component, that is, the offset symbol for the edge offset classification is explicit for the luminance component of FIG. 27A, and for the chrominance component of FIG. 7B is Implicitly.

這可以相對於用於所有色彩成分為顯式發信,提供編碼效率改良。This can provide coding efficiency improvements over explicit signaling for all color components.

在初始步驟3002中,“sao_type_idx_X”語法元件被讀取與解碼。代表此語法元件的碼字元可以使用固定長度碼或可以使用任何算術編碼方法。語法元件sao_type_idx_X完成應用於畫框區域的SAO型被處理作色彩成分Y或兩色度成分U&V的決定。In the initial step 3002, the "sao_type_idx_X" syntax element is read and decoded. The codeword representing this syntax element may use a fixed-length code or may use any arithmetic coding method. The syntax element sao_type_idx_X completes the decision that the SAO type applied to the frame area is processed as the color component Y or the two-chrominance component U&V.

另外,雖然YUV色彩成分被用於HEVC中(有時稱Y、Cr或Cb成分),但將了解其他視訊編碼方案其他色彩成分也可以使用,例如,RGB色彩成分。本發明之技術並不限於與YUV色彩成分一起使用,也可以與RGB色彩成分或任何其他色彩成分一起使用。In addition, although YUV color components are used in HEVC (sometimes called Y, Cr, or Cb components), it will be understood that other color coding schemes can use other color components, such as RGB color components. The technique of the present invention is not limited to use with YUV color components, but can also be used with RGB color components or any other color components.

在相同步驟3002中,執行測試以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”,表示如果X被設定等於Y,則對於Y,沒有SAO被用於此畫框區域(CTU),以及,如果X被設定等於U&V,則對於U及V沒有SAO被用於此畫框區域。SAO參數的決定被完成,及程序進行至步驟3008。否則,如果“sao_type_idx ”為嚴格正,則表示SAO參數存在於位元流之此CTU中。In the same step 3002, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that if X is set equal to Y, then no SAO is used for this frame area (CTU) for Y, and if X is set equal to U&V, there is no SAO for U and V Used in this frame area. The decision of the SAO parameter is completed, and the process proceeds to step 3008. Otherwise, if "sao_type_idx "Is strictly positive, it means that the SAO parameter exists in this CTU of the bit stream.

然後,程序進行至步驟3006,其中環路執行四次疊代。此四次疊代被執行於步驟3007中,其中偏移j被由位元流讀取與解碼。這四個偏移對應於SAO邊緣偏移(見圖27A與27B)的四個邊緣索引的偏移(O1、O2、O3、O4)的四個絕對值或者對應於SAO帶偏移(見圖8)的四個範圍有關的偏移的四個絕對值。Then, the procedure proceeds to step 3006, where the loop performs four iterations. The four iterations are performed in step 3007, where the offset j is read and decoded by the bit stream. These four offsets correspond to the four absolute values of the four edge index offsets (O1, O2, O3, O4) of the SAO edge offset (see Figures 27A and 27B) or to the SAO band offset (see Figure 8) Four absolute values of offsets related to the four ranges.

在步驟3007後,程序進行至步驟3003,其中執行測試以決定是否SAO的類型對應於帶偏移型(sao_type_idx_X==1)。After step 3007, the process proceeds to step 3003, where a test is performed to determine whether the type of SAO corresponds to the offset type (sao_type_idx_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟3009及3010中被解碼,除了具有零值的各個偏移外,在以下步驟3004被執行之前,以讀取位元流並解碼SAO帶位置“sao_band_position_X”如於圖8所示。If the result is positive, the symbol for the offset with offset mode is decoded in steps 3009 and 3010, except for each offset with a value of zero, to read the bit stream before the following step 3004 is performed And decode the SAO band position "sao_band_position_X" as shown in FIG. 8.

如果在步驟3003中,結果為負 (“sao_type_idx_X”被設定等於2),則表示邊緣偏移型被使用。如果X等於Y,則讀取語法元件為“sao_eo_class_luma” ,及如果X被設定等於U及V,則讀取符號元件為 “sao_eo_class_chroma”。因此,邊緣偏移類(對應於方向0、45、90及135度)係在步驟3005中由位元流抽出。If in step 3003, the result is negative ("Sao_type_idx_X" is set equal to 2), indicating that the edge offset type is used. If X equals Y, read the syntax element as "sao_eo_class_luma" , And if X is set equal to U and V, the read symbol element is "Sao_eo_class_chroma". Therefore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream in step 3005.

當四偏移被抽出時,程序進行至步驟3016,其測試是否現行色彩成分X對應於亮度成分。如果是,則四個符號(3012)被由位元流抽出(3013)。然後,SAO參數的讀取完成及程序進行至步驟3008。When the four offsets are extracted, the process proceeds to step 3016, which tests whether the current color component X corresponds to the luminance component. If yes, then four symbols (3012) are extracted from the bit stream (3013). Then, the reading of the SAO parameters is completed and the procedure proceeds to step 3008.

如果現行色彩成分為色度成分,則程序直接進行至步驟3008。If the current color component is a chroma component, the process directly proceeds to step 3008.

此實施例的優點可以是相較於所有色彩成分的符號的發信之編碼效率改良。這是因為對於色度成分,隱式發信可能較符號的顯式發信更有效率。The advantage of this embodiment may be improved coding efficiency compared to the transmission of symbols of all color components. This is because for chroma components, implicit signaling may be more efficient than explicit signaling of symbols.

在其他實施例中,符號可以對於所有色彩成分發信,這簡化了硬體實施法。In other embodiments, the symbol can signal all color components, which simplifies the hardware implementation.

圖31為流程圖,例示依據第二態樣的第六實施例之解碼SAO參數的程序步驟。FIG. 31 is a flowchart illustrating a procedure of decoding SAO parameters according to the sixth embodiment of the second aspect.

依據此第六實施例,當SAO符號法時,即在“組”表中之對應於N值的索引高於臨限Th時,符號被針對亮度作顯式發信。According to this sixth embodiment, when the SAO symbol method is used, that is, when the index corresponding to the N value in the "group" table is higher than the threshold Th, the symbol is explicitly signaled for brightness.

相較於圖30所示之程序,本程序包含如下所述之額外模組3111及3114。Compared with the procedure shown in FIG. 30, this procedure includes additional modules 3111 and 3114 as described below.

在初始步驟3102中,“sao_type_idx_X”語法元件被讀取與解碼。代表此語法元件的碼字元可以使用固定長度碼或可以使用任何算術編碼的方法。語法元件sao_type_idx_X完成應用於畫框區域的SAO的類型被處理作色彩成分Y或兩者色度成分U&V的決定。In the initial step 3102, the "sao_type_idx_X" syntax element is read and decoded. The code character representing this syntax element can use a fixed-length code or can use any arithmetic coding method. The syntax element sao_type_idx_X completes the decision that the type of SAO applied to the frame area is processed as the color component Y or both chrominance components U&V.

另外,雖然YUV色彩成分被用於HEVC(有時稱Y、Cr及Cb成分)中,但應了解也可以使用其他視訊編碼方案其他色彩成分,例如RGB色彩成分。本發明之技術並不限於與YUV色彩成分一起使用,也可以與RGB色彩成分或任何其他色彩成分一起使用。In addition, although YUV color components are used in HEVC (sometimes called Y, Cr, and Cb components), it should be understood that other color components of other video encoding schemes, such as RGB color components, can also be used. The technique of the present invention is not limited to use with YUV color components, but can also be used with RGB color components or any other color components.

在相同步驟3102中,執行測試以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”表示如果X被設定等於Y,則對於Y用於此畫框區域(CTU)沒有SAO,以及,如果X被設定等於U和V,則對於U和V,沒有SAO用於此畫框區域。SAO參數的決定完成及程序進行至步驟3108。否則,如果“sao_type_idx”為嚴格正,則表示在位元流中之CTU存在有SAO參數。In the same step 3102, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that if X is set equal to Y, then there is no SAO for Y used for this frame area (CTU), and if X is set equal to U and V, there is no SAO for U and V Used for this picture frame area. The decision of the SAO parameters is completed and the process proceeds to step 3108. Otherwise, if "sao_type_idx" is strictly positive, it means that there is a SAO parameter in the CTU in the bit stream.

然後,程序進行至步驟3106,其中環路執行四次疊代。四次疊代被執行於步驟3107,其中偏移j的絕對值被由位元流讀取與解碼。這四個偏移對應於SAO邊緣偏移的四個邊緣索引(見圖27A或27B)的偏移(O1、O2、O3、O4)的四個絕對值或者對應於SAO帶偏移的四個範圍(見圖8)有關的偏移的四個絕對值。Then, the process proceeds to step 3106, where the loop performs four iterations. Four iterations are performed in step 3107, where the absolute value of offset j is read and decoded by the bit stream. These four offsets correspond to the four absolute values of the offsets (O1, O2, O3, O4) of the four edge indexes of the SAO edge offset (see Figure 27A or 27B) or the four corresponding to the SAO band offset Four absolute values of offset related to range (see Figure 8).

在步驟3107後,程序進行至步驟3103,其中測試被執行,以決定是否SAO的類型對應於帶偏移類型(sao_type_idx_X==1)。After step 3107, the process proceeds to step 3103, where a test is performed to determine whether the type of SAO corresponds to the band offset type (sao_type_idx_X==1).

如果結果為正,則用於帶偏移模式的偏移的符號在步驟3109及3110處被解碼,除了具有零值的各個偏移之外,在以下步驟3104執行之前,以讀取位元流及解碼SAO帶的位置“sao_band_position_X”,如圖8所示。If the result is positive, the symbol for the offset with offset mode is decoded at steps 3109 and 3110, except for each offset with a value of zero, to read the bit stream before the following step 3104 is performed And the position "sao_band_position_X" of the decoded SAO band, as shown in FIG. 8.

如果在步驟3103中結果為負 (“sao_type_idx_X”被設定等於2),則表示邊緣偏移型被使用。如果X等於Y,則讀取語法元件為“sao_eo_class_luma”及如果X被設定等於U及V,則讀取語法元件為“sao_eo_class_chroma”。因此,邊緣偏移類(對應於方向0、45、90及135度)係在步驟3105由位元流抽出。If the result is negative in step 3103 ("Sao_type_idx_X" is set equal to 2), indicating that the edge offset type is used. If X is equal to Y, the syntax element is read as "sao_eo_class_luma" and if X is set equal to U and V, the syntax element is read as "sao_eo_class_chroma". Therefore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream in step 3105.

當四個偏移已經抽出時,程序進行至步驟3116,其中測試是否現行色彩成分X對應於亮度成分。如果是,則測試是否邊緣偏移符號法eo_sign_method_X (3114),即對應於現行色彩成分(亮度)的N值(在轉換表“組”中)的索引是大於臨限Th(3111)。臨限可以為0或更高。如果是,則四個符號(3112)係由位元流抽出(3113)。然後,SAO參數的讀取完成並且程序進行至步驟3108。When the four offsets have been extracted, the process proceeds to step 3116, where it is tested whether the current color component X corresponds to the luminance component. If yes, test whether the edge offset sign method eo_sign_method_X (3114), that is, the index of the N value (in the conversion table "group") corresponding to the current color component (luminance) is greater than the threshold Th (3111). The threshold can be 0 or higher. If yes, the four symbols (3112) are extracted from the bit stream (3113). Then, the reading of the SAO parameters is completed and the procedure proceeds to step 3108.

否則(邊緣偏移符號法,即,對應於N值索引的索引低於臨限),符號為隱式並設定如於圖27B所示。然後,SAO參數的讀取完成及程序進行至步驟3108。Otherwise (edge offset sign method, ie, the index corresponding to the N value index is lower than the threshold), the sign is implicit and set as shown in FIG. 27B. Then, the reading of the SAO parameters is completed and the process proceeds to step 3108.

如果現行色彩成分為色度成分,則程序直接進行至步驟3108。If the current color component is a chroma component, the process directly proceeds to step 3108.

此實施例相較於先前實施例,提供編碼效率增加。這是因為對於色度成分,隱式發信經常較符號的顯式發信更有效率。This embodiment provides increased coding efficiency compared to the previous embodiment. This is because for chroma components, implicit signaling is often more efficient than explicit signaling of symbols.

圖32為流程圖,例示程序步驟,用以依據第二態樣的第七實施例解碼SAO參數。FIG. 32 is a flowchart illustrating program steps for decoding SAO parameters according to the seventh embodiment of the second aspect.

依據此第七實施例,邊緣偏移的符號對於峰及谷類為顯式(發信),及當色彩成分為亮度時,對於另兩群為隱式。在此時,符號被傳送用於偏移O1及O4,如於圖27B所示。According to this seventh embodiment, the sign of the edge shift is explicit (signaling) for peaks and valleys, and implicit for the other two groups when the color component is brightness. At this time, the symbol is transmitted for offsets O1 and O4, as shown in FIG. 27B.

在初始步驟3202中,“sao_type_idx_X”語法元件被讀取與解碼。代表此語法元件的碼字元可以使用固定長度碼或者可以使用任何算術編碼的方法。語法元件sao_type_idx_X完成用於予以用於色彩成分Y或兩色度成分U&V處理的圖框區域的SAO的類型的決定。In the initial step 3202, the "sao_type_idx_X" syntax element is read and decoded. The codeword representing this syntax element can use a fixed-length code or can use any arithmetic coding method. The syntax element sao_type_idx_X completes the determination of the type of SAO to be applied to the frame area for U and V processing of the color component Y or the two-chroma component.

另外,雖然YUV色彩成分被用於HEVC(有時稱Y、Cr及Cb成分),但應了解也可以使用其他視訊編碼方案,其他色彩成分,例如RGB色彩成分。本發明之技術並不限於與YUV色彩成分一起使用,也可以與RGB色彩成分或任何其他色彩成分一起使用。In addition, although YUV color components are used for HEVC (sometimes called Y, Cr, and Cb components), it should be understood that other video encoding schemes, other color components, such as RGB color components, can also be used. The technique of the present invention is not limited to use with YUV color components, but can also be used with RGB color components or any other color components.

在相同步驟3202中,執行測試以決定是否“sao_type_idx_X”為嚴格正。如果“sao_type_idx_X”等於“0”,表示如果X設定等於Y,則對於Y的此畫框區域(CTU)沒有SAO,及如果X被設定等於U及V,則對於U及V的此畫框區域並沒有SAO。SAO參數的決定完成及程序進行至步驟3208。否則,如果“sao_type_idx”為嚴格正,則表示在位元流中的此CTU存在有SAO參數。In the same step 3202, a test is performed to determine whether "sao_type_idx_X" is strictly positive. If "sao_type_idx_X" is equal to "0", it means that if X is set equal to Y, then there is no SAO for this frame area (CTU) of Y, and if X is set equal to U and V, then this frame area for U and V There is no SAO. The decision of the SAO parameter is completed and the process proceeds to step 3208. Otherwise, if "sao_type_idx" is strictly positive, it means that there is a SAO parameter for this CTU in the bit stream.

然後,程序進行至步驟3206,其中環路執行四次疊代。四次疊代可以執行於步驟3207中,其中偏移j的絕對值被由位元流讀取及解碼。這四次疊代對應於SAO邊緣偏移的四個索引的偏移(O1、O2、O3、O4)的四個絕對值(見圖27A及27B)或者對應至有關於SAO帶偏移的四個範圍的偏移的四個絕對值(見圖8)。Then, the process proceeds to step 3206, where the loop performs four iterations. Four iterations can be performed in step 3207, where the absolute value of offset j is read and decoded by the bitstream. These four iterations correspond to the four absolute values of the four index offsets (O1, O2, O3, O4) of the SAO edge offset (see Figures 27A and 27B) or correspond to the four related to the SAO band offset Four absolute values of the range of offsets (see Figure 8).

在步驟3207後,程序進行至步驟3203,其中執行測試以決定是否SAO的類型對應於帶偏移型(sao_type_idx_X==1)。After step 3207, the process proceeds to step 3203, where a test is performed to determine whether the type of SAO corresponds to the band offset type (sao_type_idx_X==1).

如果結果為正,則在以下步驟3204執行前,用於帶偏移模式的偏移的符號在步驟3209及3210中被解碼,除了具有零值的各個偏移外,以讀取該位元流並且解碼SAO帶的位置“sao_band_position_X”如於圖8所示。If the result is positive, the symbol for the offset with offset mode is decoded in steps 3209 and 3210 before the following step 3204 is executed, except for each offset with a value of zero, to read the bit stream And the position "sao_band_position_X" of the decoded SAO band is as shown in FIG. 8.

如果在步驟3203中之結果為負 (“sao_type_idx_X”被設定等於2),則表示邊緣偏移型被使用。如果X等於Y,則讀取語法元件為“sao_eo_class_luma” ,及如果X被設定等於U及V,則讀取語法元件為“sao_eo_class_chroma”。因此,邊緣偏移類(對應於方向0、45、90及135度)係在步驟3205中由位元流中抽出。If the result in step 3203 is negative ("Sao_type_idx_X" is set equal to 2), indicating that the edge offset type is used. If X equals Y, read the syntax element as "sao_eo_class_luma" , And if X is set equal to U and V, the read syntax element is "sao_eo_class_chroma". Therefore, the edge offset class (corresponding to directions 0, 45, 90, and 135 degrees) is extracted from the bit stream in step 3205.

當四個偏移已經被抽出時,程序進行至步驟3216,其中測試是否現行色彩成分X對應於亮度色分。如果是,則對於四個偏移的各個(3212),決定是否偏移為峰(j==1)或谷(j==4)偏移,即O1或O4(3215)。如果是,偏移的符號被由位元流抽出(3213)。否則,符號為隱式並設定如於圖27B所示。然後,SAO參數的讀取完成及程序進行至步驟3208。如果現行色彩成分為色度成分,則程序直接進行至步驟3208。When the four offsets have been extracted, the process proceeds to step 3216, where it is tested whether the current color component X corresponds to the luminance color score. If so, for each of the four offsets (3212), decide whether the offset is a peak (j==1) or valley (j==4) offset, ie O1 or O4 (3215). If so, the offset sign is extracted from the bit stream (3213). Otherwise, the symbol is implicit and set as shown in Figure 27B. Then, the reading of the SAO parameters is completed and the process proceeds to step 3208. If the current color component is a chroma component, the process directly proceeds to step 3208.

此實施例的優點為其可以針對編碼效率看來較佳,因為色度成分的隱式發信經常較符號的顯式發信有效率。The advantage of this embodiment is that it can be considered better for coding efficiency, because implicit signaling of chroma components is often more efficient than explicit signaling of symbols.

在變化例中,額外測試可以執行以測試是否邊緣符號法,即(在轉換表“組”中之)對應於N值的索引大於臨限Th。In a variation, an additional test can be performed to test whether the edge sign method, ie (in the "group" of the conversion table) the index corresponding to the N value is greater than the threshold Th.

在另一實施例中,所有色彩成分的發信可以允許硬體實施法的簡化。In another embodiment, the signaling of all color components may allow simplification of hardware implementation.

第三群實施例(第三態樣)Third group of embodiments (third aspect)

依據本發明之第三態樣,其中提供一種取得邊緣偏移的方法,用以執行取樣自適應偏移(SAO)濾波,其中當SAO偏移的符號在位元流中顯式發信時,其值被預測。According to a third aspect of the present invention, a method for obtaining an edge offset is provided for performing sample adaptive offset (SAO) filtering, wherein when the symbol of the SAO offset is explicitly signaled in the bitstream, Its value is predicted.

換句話說,第三態樣提供在影像上執行取樣自適應偏移(SAO)濾波的方法,該影像包含多數影像部,該方法包含: 取得多數邊緣偏移以執行SAO濾波; 其中該多數邊緣偏移的至少一邊緣偏移的符號被發信於位元流中;及 其中取得多數邊緣偏移包含預測至少一邊緣偏移,其符號係被發信於該位元流中者。 實際上,依據第三態樣的實施例,偏移值或更準確地說絕對偏移值可以以可變長度碼或算術編碼的固定碼加以編碼。In other words, the third aspect provides a method of performing sample adaptive offset (SAO) filtering on an image. The image includes a plurality of image parts. The method includes: Get most edge offsets to perform SAO filtering; Where at least one edge-offset symbol of the majority of edge offsets is sent in the bitstream; and Obtaining the majority of edge offsets includes predicting at least one edge offset whose symbol is sent to the bitstream. In fact, according to the embodiment of the third aspect, the offset value or more precisely the absolute offset value may be encoded with a variable length code or an arithmetically-encoded fixed code.

圖33例示預測程序步驟,其可以在(SAO)濾波實施例中在解碼器側依據第三態樣的第一實施例加以執行。這些步驟可以在圖11所示之程序期間執行。例如,此預測可以應用於圖11的步驟701中。這些步驟可以在圖29至圖32所示之程序期間,在個別步驟2908至3208之前執行。FIG. 33 illustrates the prediction procedure steps, which can be performed on the decoder side in the first embodiment of the third aspect in the (SAO) filtering embodiment. These steps can be performed during the procedure shown in FIG. For example, this prediction can be applied in step 701 of FIG. 11. These steps can be performed during the procedures shown in FIGS. 29 to 32, before the individual steps 2908 to 3208.

依據此第一實施例,至少一邊緣偏移被由預設值預測。在此例子中,邊緣偏移根據包含預設值的預測子表加以預測。此實施例的優點可以是編碼效率增加。According to this first embodiment, at least one edge offset is predicted from a preset value. In this example, the edge offset is predicted based on the prediction sub-table that contains preset values. The advantage of this embodiment may be increased coding efficiency.

在程序的開始,取得解碼偏移表(3301)。此表包含具有其個別符號的偏移值。四個偏移的值(3302)然後被預測(3303)。這是藉由使用預測子表(3304)將成分X(YUV)的變數Offset_X_j加至預測子Predictor_X_j加以完成。預測子表3304可以包含適用至各個類型的偏移(峰、谷等的)不同預測子。因此,在編碼器側,預測子 Predictor_X_j減去Offset_X_j值。程序然後進行至步驟3305。At the beginning of the program, a decoding offset table is obtained (3301). This table contains offset values with their individual symbols. The four offset values (3302) are then predicted (3303). This is done by adding the variable Offset_X_j of the component X (YUV) to the predictor Predictor_X_j using the predictor table (3304). The predictor table 3304 may contain different predictors applicable to various types of offsets (peaks, valleys, etc.). Therefore, on the encoder side, the predictor Predictor_X_j minus Offset_X_j value. The program then proceeds to step 3305.

依據實施例,預設值被預定至少一序列,例如所有序列,即,預測子表的值可以對於整個切片/畫框相同或對於該序列或所有序列的所有畫框相同。According to an embodiment, the preset value is predetermined for at least one sequence, for example, all sequences, that is, the value of the prediction sub-table may be the same for the entire slice/picture frame or for all the frames of the sequence or all sequences.

依據實施例,預設值的表被傳送於位元流中。例如,這些預設預測子值被傳送在切片檔頭中。在一變化例中,這些預設預測子值被傳送在序列參數中。According to an embodiment, a table of preset values is transmitted in the bit stream. For example, these preset predictor values are transmitted in the slice header. In a variation, these predetermined predictor values are transmitted in sequence parameters.

由於較佳彈性,這些實施例提供較佳編碼效率。Due to better flexibility, these embodiments provide better coding efficiency.

依據一實施例,這些預設預測子值針對所有序列加以預定。According to an embodiment, these predetermined predictor values are predetermined for all sequences.

依據一實施例,用以預測邊緣偏移的預設值符號被設定,即其被固定。例如,用於偏移O1及O2的預測子值為正,及用於偏移O1及O3的預測子值為負。According to an embodiment, the default value symbol used to predict the edge offset is set, ie it is fixed. For example, the predictor values for offsets O1 and O2 are positive, and the predictor values for offsets O1 and O3 are negative.

依據實施例,有關於第一與最後類型O1及O4的邊緣偏移的絕對預測子值係高於有關於其他類型O2及O3的邊緣偏移的絕對預測子值。According to an embodiment, the absolute predictor values for the edge offsets of the first and last types O1 and O4 are higher than the absolute predictor values for the edge offsets of other types O2 and O3.

此實施例可以相當有利,因為偏移O1及O4的絕對平均值經常大於偏移O2及O3的絕對平均值。因此,此實施例可以提供較佳編碼效率。This embodiment can be quite advantageous because the absolute average of offsets O1 and O4 is often greater than the absolute average of offsets O2 and O3. Therefore, this embodiment can provide better coding efficiency.

依據實施例,有關於第一及最後類型(O1及O4)的邊緣偏移的絕對預測子值為相同,及有關於其他類型(O2及O3)的邊緣偏移(O2及O3)的絕對預測子值為相同。According to an embodiment, the absolute prediction sub-values for the first and last types (O1 and O4) of the edge offset are the same, and there are absolute predictions for the other types (O2 and O3) of the edge offset (O2 and O3) The sub-values are the same.

較佳地,程序被簡化並與偏移值的統計選擇相符。Preferably, the procedure is simplified and consistent with the statistical selection of offset values.

圖34例示預測程序,其可以在SAO濾波實施例期間在解碼器側依據第三態樣的第二實施例執行。如前述,這些步驟可以在圖10或11所示之程序中執行。FIG. 34 illustrates a prediction procedure which can be executed on the decoder side according to the second embodiment of the third aspect during the SAO filtering embodiment. As mentioned above, these steps can be performed in the procedure shown in FIG. 10 or 11.

依據第二實施例,預設值取決於符號參數N,用於在符號函數中,以決定邊緣偏移的索引。According to the second embodiment, the preset value depends on the sign parameter N and is used in the sign function to determine the index of the edge offset.

在程序的開始,取得解碼偏移表(3401)。此表包含具有其個別符號的偏移值。該四個偏移的值(3402)然後被預測(3403)。這是根據使用預測子表(3404)及公式組[eo_sign_method_X]的預測子Predictor_X加以完成,該公式組是根據eo_sign_method_X組表(3406)。預測子表3404可以包含不同預測子,其適用至各個類型偏移(峰、谷等),同時,表組(3406)被用以取得現行Offset_X_j的正確預測子。在此例子中,預測子表具有用於其第一維度的值N。但如果表組相同不管序列,則不需要依據表組將eo_sign_method_X轉換至值N。另外,如果 eo_sign_method_X並不是直接N值,則表“組”可以被用以轉換eo_sign_method至正確N值。At the beginning of the program, a decoding offset table is obtained (3401). This table contains offset values with their individual symbols. The four offset values (3402) are then predicted (3403). This is done based on the predictor Predictor_X using the prediction sub-table (3404) and the formula group [eo_sign_method_X], which is based on the eo_sign_method_X group table (3406). The predictor table 3404 may contain different predictors, which are applicable to various types of offsets (peaks, valleys, etc.). At the same time, the table group (3406) is used to obtain the correct predictor for the current Offset_X_j. In this example, the prediction sub-table has a value N for its first dimension. But if the table group is the same regardless of the sequence, there is no need to convert eo_sign_method_X to the value N according to the table group. In addition, if eo_sign_method_X is not a direct N value, then the table "group" can be used to convert eo_sign_method to the correct N value.

相應地,在編碼器側,正確預測子 Predictor_X_j被減去Offset_X_j值。程序然後進行至步驟3405。Correspondingly, on the encoder side, the correct predictor Predictor_X_j is subtracted from the Offset_X_j value. The program then proceeds to step 3405.

此實施例的優點可以是相較於所有邊緣偏移符號法的固定值,編碼效率的增加。這是因為當符號法的N值增加時,絕對偏移值增加。The advantage of this embodiment may be an increase in coding efficiency compared to a fixed value for all edge offset sign methods. This is because when the N value of the symbol method increases, the absolute offset value increases.

依據實施例,該多數邊緣偏移的至少一些邊緣偏移其符號被發信於位元流中者並未被預測,即只有一些偏移可以被預測及未預測偏移可能將其符號以顯式發信。圖35、36、37及38顯示此等實施例的四個例子。在這些例子中,這些步驟係類似於圖33及/或圖34所示之程序,但它們只針對部份偏移執行。According to an embodiment, at least some edge offsets of the majority of edge offsets whose symbols are signaled in the bitstream are not predicted, that is, only some offsets can be predicted and unpredicted offsets may have their signs displayed. Letter. Figures 35, 36, 37 and 38 show four examples of these embodiments. In these examples, these steps are similar to the procedures shown in Figure 33 and/or Figure 34, but they are only performed for partial offsets.

圖35例示預測程序的步驟,其可以在解碼器側依據第三態樣的第三實施例的(SAO)濾波實施例期間加以執行。如前所述,這些步驟可以在圖10或11所示之程序期間執行。FIG. 35 illustrates the steps of the prediction procedure, which can be performed during the (SAO) filtering embodiment of the third embodiment according to the third aspect on the decoder side. As mentioned earlier, these steps can be performed during the procedure shown in FIG. 10 or 11.

依據此第三實施例,至少一邊緣偏移被由符號參數N加以預測,以用於用以決定邊緣偏移的索引的符號函數。另外,只有這些偏移的部分被預測。According to this third embodiment, at least one edge offset is predicted by the symbol parameter N for the sign function used to determine the index of the edge offset. In addition, only these offsets are predicted.

例如,偏移O1和O4被預測子所預測,其絕對值等於符號法的值N。For example, the offsets O1 and O4 are predicted by the predictor, and their absolute values are equal to the symbolic value N.

在程序的開始,取得解碼偏移表(3501)。此表包含具有其個別符號的偏移值。對於各個偏移(3502),其決定該偏移為峰或谷偏移,即O1或O4(3507)。如果是,則偏移為公式組[eo_sign_method_X]根據 eo_sign_method_X組表(3506)所取得的值(3503)所預測。依據圖7B所示之表,此值N只是預測子的絕對值,並且,如果其為偏移O1,則符號為正,及如果其為偏移O4,則符號為負。程序然後進行至步驟3505。At the beginning of the program, a decoding offset table is obtained (3501). This table contains offset values with their individual symbols. For each offset (3502), it determines that the offset is a peak or valley offset, namely O1 or O4 (3507). If yes, the offset is the formula group [eo_sign_method_X] according to Predicted by the value (3503) obtained from the eo_sign_method_X group table (3506). According to the table shown in FIG. 7B, this value N is only the absolute value of the predictor, and if it is offset O1, the sign is positive, and if it is offset O4, the sign is negative. The process then proceeds to step 3505.

此實施例的優點可以增加編碼效率。The advantages of this embodiment can increase coding efficiency.

依據其他實施例,用於預測子的絕對值的其他可能值也可以被考量為N-1或N-2或N+1或N+2,特別是如果邊緣偏移符號法對於整個畫框或序列為相同(如果在邊緣偏移符號法間沒有競爭)。According to other embodiments, other possible values for the absolute value of the predictor can also be considered as N-1 or N-2 or N+1 or N+2, especially if the edge offset sign method is used for the entire frame or The sequence is the same (if there is no contention between the edge offset sign methods).

圖36例示預測程序,其可以依據第三態樣的第四實施例在解碼器側的(SAO)濾波實施例期間執行。FIG. 36 illustrates a prediction procedure which can be executed during the (SAO) filtering embodiment on the decoder side according to the fourth embodiment of the third aspect.

在此第四實施例中,只有峰及谷偏移(O1及O4)可以被預測。因此,此程序類似於圖33所示之程序,但只有針對部份的偏移執行。In this fourth embodiment, only the peak and valley shifts (O1 and O4) can be predicted. Therefore, this procedure is similar to the procedure shown in Figure 33, but only for partial offsets.

在程序的開始,取得解碼偏移表(3601)。此表包含具有其個別符號的偏移值。對於各個偏移(3602),決定是否偏移為峰或谷偏移,即O1或O4(3607)。如果是,則成分X(YUV)的變數Offset_X_j被使用預測子表(3604)加入至預測子Predictor_X_j(3603)。程序然後進行至步驟3605。At the beginning of the program, a decoding offset table is obtained (3601). This table contains offset values with their individual symbols. For each offset (3602), decide whether the offset is a peak or valley offset, ie O1 or O4 (3607). If it is, the variable Offset_X_j of the component X (YUV) is added to the predictor Predictor_X_j (3603) using the predictor table (3604). The program then proceeds to step 3605.

此實施例的優點可以是增加編碼效率。這是因為偏移O1及O4的絕對平均值在平均上大於偏移O2及O3者。另外,用於O2及O3的絕對值經常小於1。因此,可能不必要預測它們並發出符號。The advantage of this embodiment may be increased coding efficiency. This is because the absolute average values of the offsets O1 and O4 are larger on average than those of the offsets O2 and O3. In addition, the absolute values used for O2 and O3 are often less than 1. Therefore, it may not be necessary to predict them and issue symbols.

圖37例示預測程序,其可以依據第三態樣的第五實施例在解碼器側的(SAO)濾波實施例期間執行。FIG. 37 illustrates a prediction procedure that can be executed during the (SAO) filtering embodiment on the decoder side according to the fifth embodiment of the third aspect.

在此實施例中,用於亮度成分的偏移只是預測。In this embodiment, the offset used for the luminance component is only prediction.

在程序開始,取得解碼偏移表(3701)。此表包含具有其個別符號的偏移值。對於各個偏移(3702),決定是否現行色彩成分為亮度(3708)。如果是,則偏移使用預測子表(3704)將成分X(YUV)的變數Offset_X_j加入至預測子Predictor_X_j(3703)加以預測。程序然後進行至步驟3705。At the beginning of the program, the decoding offset table is obtained (3701). This table contains offset values with their individual symbols. For each offset (3702), it is determined whether the current color component is brightness (3708). If yes, the offset is predicted by adding the variable Offset_X_j of component X (YUV) to the predictor Predictor_X_j (3703) using the predictor table (3704). The program then proceeds to step 3705.

此實施例的優點可以是增加的編碼效率。這是因為絕對偏移值通常對於亮度成分為較高,色度成分則較低。亮度成分的預測可以足夠高。此實施例可以因此當色度偏移的預測免除時提供簡化。The advantage of this embodiment may be increased coding efficiency. This is because the absolute offset value is usually higher for the luminance component and lower for the chrominance component. The prediction of the luminance component can be sufficiently high. This embodiment can therefore provide simplification when the prediction of chroma shift is dispensed with.

圖38例示預測程序步驟,其可以依據第三態樣的第六實施例在解碼器側的(SAO)濾波實施例期間執行。FIG. 38 illustrates a prediction procedure step, which can be executed during the (SAO) filtering embodiment on the decoder side according to the sixth embodiment of the third aspect.

在此第六實施例中,只有用於亮度成分的偏移及偏移O1及O4被預測。In this sixth embodiment, only the offset for the luminance component and the offsets O1 and O4 are predicted.

在程序開始,取得解碼偏移表(3801)。此表包含具有其個別符號的偏移值。對於各個偏移(3802),其決定是否現行色彩成分為亮度(3808)。如果是,則決定該偏移是為峰或谷偏移,即O1或O4(3807)。如果是,偏移藉由使用預測子表(3804)將成分X(YUV)的變數offset_X_j加至預測子Predictor_X_j(3803)加以預測。程序然後進行至步驟3805。At the beginning of the program, a decoding offset table is obtained (3801). This table contains offset values with their individual symbols. For each offset (3802), it determines whether the current color component is brightness (3808). If it is, it is determined that the shift is a peak or valley shift, namely O1 or O4 (3807). If so, the offset is predicted by adding the variable offset_X_j of the component X (YUV) to the predictor Predictor_X_j (3803) using the predictor table (3804). The program then proceeds to step 3805.

依據其他實施例,至少一邊緣偏移被由相鄰邊緣偏移值預測,只有該相鄰邊緣偏移的符號被使用相同符號法加以決定。換句話說,如果先前偏移的符號使用相同邊緣偏移符號法加以決定,則至少一部份的現行邊緣偏移值可以根據先前編碼CTU參數之一者的邊緣偏移值加以預測。According to other embodiments, at least one edge offset is predicted from the adjacent edge offset value, and only the sign of the adjacent edge offset is determined using the same sign method. In other words, if the previously offset symbol is determined using the same edge offset symbol method, at least a portion of the current edge offset value can be predicted based on the edge offset value of one of the previously encoded CTU parameters.

第四群實施例(第四態樣)Fourth group of embodiments (fourth aspect)

依據本發明第四態樣,其中提供一種用以取得邊緣偏移的方法,以執行取樣自適應偏移(SAO)濾波,其中該至少一邊緣偏移的符號為隱式及該邊緣偏移的最小值係被設定為不是零的預設值。According to a fourth aspect of the present invention, there is provided a method for obtaining an edge offset to perform sampling adaptive offset (SAO) filtering, wherein the sign of the at least one edge offset is implicit and the edge offset The minimum value is set to a preset value that is not zero.

換句話說,第四態樣提供對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中取得多數邊緣偏移包含預測至少一邊緣偏移;及 其中該至少一邊緣偏移的符號為隱式及該邊緣偏移的最小值被設定為不是零的預設值。In other words, the fourth aspect provides a method of performing sample adaptive offset (SAO) filtering on an image including most image parts. The method includes: Obtain most edge offsets to perform SAO filtering; Wherein obtaining the majority of edge offsets includes predicting at least one edge offset; and The sign of the at least one edge offset is implicit and the minimum value of the edge offset is set to a preset value that is not zero.

依據第四態樣的一實施例,用於邊緣偏移分類的偏移具有最小限定絕對值。在此實施例中,對於具有大於0的最小限定絕對值的偏移而言,偏移的符號並未發信於位元流中。According to an embodiment of the fourth aspect, the offset used for edge offset classification has a minimum defined absolute value. In this embodiment, for an offset with a minimum defined absolute value greater than 0, the sign of the offset is not signaled in the bitstream.

可以注意,在SAO的現行實施法中,邊緣偏移被定界如下: O1>=0 O2>=0 O3<=0 O4<=0It can be noted that in the current implementation of SAO, the edge offset is delimited as follows: O1>=0 O2>=0 O3<=0 O4<=0

依據所提實施例,偏移O1、O2、O3、O4分別具有最小限定絕對值MAO1、MAO2、MAO3、MAO4。例如,偏移值O1、O2、O3、O4被定界如下: O1>=MAO1 O2>=MAO2 O3<=-MAO3 O4<=-MAO4According to the proposed embodiment, the offsets O1, O2, O3, and O4 have minimum absolute values MAO1, MAO2, MAO3, and MAO4, respectively. For example, the offset values O1, O2, O3, O4 are delimited as follows: O1>=MAO1 O2>=MAO2 O3<=-MAO3 O4<=-MAO4

此定界目標在於限定有關於偏移的碼率。如同於現行SAO實施法中,示於圖10的絕對偏移值Offset_X_j(607)可以一直由0編碼至最大值。因此,在編碼器側,絕對值Offset_X_j可以分別由MAO1_X、 MAO2_X、-MAO3_X、-MAO4_X所預測。The goal of this delimitation is to define the code rate for the offset. As in the current SAO implementation method, the absolute offset value Offset_X_j (607) shown in FIG. 10 can always be encoded from 0 to the maximum value. Therefore, on the encoder side, the absolute value Offset_X_j can be determined by MAO1_X, Predicted by MAO2_X, -MAO3_X, -MAO4_X.

在解碼器側,相同於圖33所示之程序係被應用至可以被設定如下的預測子Predictor_X_j: Predictor_X_1=MAO1 Predictor_X_2=MAO2 Predictor_X_3=-MAO3 Predictor_X_4=-MAO4On the decoder side, the same procedure as shown in FIG. 33 is applied to the predictor Predictor_X_j which can be set as follows: Predictor_X_1=MAO1 Predictor_X_2=MAO2 Predictor_X_3=-MAO3 Predictor_X_4=-MAO4

此實施例的優點可以是相較於先前技術的編碼效率增加。因為它並不需要將偏移的符號相加作為語法元件,所以,相於符號被傳送的實施例,此實施例可以被認為是簡化。The advantage of this embodiment may be an increase in coding efficiency compared to the prior art. Since it does not need to add the offset symbols as a syntax element, this embodiment can be regarded as a simplification relative to the embodiment where the symbols are transmitted.

圖39顯示系統191及195,依據本發明實施例,包含編碼器150或解碼器100的至少之一及通訊網路199。依據實施例,系統195係用以處理及提供內容(例如,用以顯示/輸出的視訊及音訊內容或串流視訊/音訊內容)給使用者,該使用者例如已透過包含解碼器100的使用者終端或能與解碼器100通訊的使用者終端的使用者界面,接取解碼器100。此使用者終端可以是電腦、行動電話、平版電腦或任何類型的裝置,其能提供/顯示(所提/串流)內容給使用者。系統195經由通訊網路199取得/接收位元流101(以連續串流或信號的形式,例如,當早先視訊/音訊係被顯示/輸出的同時)。依據實施例,系統191係用以處理內容並儲存處理過的內容,例如,已處理視訊及音訊內容,供隨後顯示/輸出/串流。系統191取得/接收包含影像151的原始序列的內容,其係為編碼器150所接收與處理(包含以依據本發明之解塊濾波器濾波),及編碼器150產生位元流101,其係被經由通訊網路191傳送至解碼器100。位元流101然後以若干方式傳送至解碼器100,例如,其可以事先為編碼器150所產生並儲存在通訊網路199(例如,伺服器或雲端儲存)中之儲存設備作為資料,直到使用者要求來自該儲存設備的該內容(即,位元流資料)為止,在儲存設備點上,資料被由儲存設備傳送/串流至解碼器100。系統191也可以包含內容提供設備,用以將儲存在儲存設備中的內容的內容資訊(例如,內容名稱及其他原/儲存位置資料,以供識別、選擇及要求該內容)提供/串流給使用者(例如,傳送給使用者介面資料將被顯示在使用者終端),及用於接收及處理內容的使用者要求,以使得所要求內容可以被由儲存設備傳送/串流至使用者終端。或者,編碼器150產生位元流101並當使用者要求該內容時,將其直接傳送/串流至解碼器100。解碼器100然後接收位元流101(或信號)並以依據本發明之解塊濾波器執行濾波,以取得/產生視訊信號109及/或音訊信號,其然後為使用者終端所使用以提供所要求內容給使用者。FIG. 39 shows systems 191 and 195, which include at least one of encoder 150 or decoder 100 and communication network 199 according to an embodiment of the present invention. According to an embodiment, the system 195 is used to process and provide content (for example, video and audio content for display/output or streaming video/audio content) to a user who has used the decoder 100 for example The user interface of a user terminal or a user terminal that can communicate with the decoder 100 accesses the decoder 100. The user terminal may be a computer, a mobile phone, a tablet computer, or any type of device, which can provide/display (promote/stream) content to the user. The system 195 acquires/receives the bit stream 101 via the communication network 199 (in the form of a continuous stream or signal, for example, while the previous video/audio system is being displayed/output). According to an embodiment, the system 191 is used to process content and store processed content, such as processed video and audio content, for subsequent display/output/streaming. The system 191 obtains/receives the content including the original sequence of the image 151, which is received and processed by the encoder 150 (including filtering with the deblocking filter according to the present invention), and the encoder 150 generates the bit stream 101, which is It is transmitted to the decoder 100 via the communication network 191. The bit stream 101 is then sent to the decoder 100 in several ways. For example, it can be generated in advance by the encoder 150 and stored in the storage device of the communication network 199 (for example, server or cloud storage) as data until the user Until the content from the storage device (ie, bit stream data) is requested, the data is transmitted/streamed from the storage device to the decoder 100 at the storage device point. The system 191 may also include a content providing device for providing/streaming content information of the content stored in the storage device (eg, content name and other original/storage location data for identification, selection, and requesting the content) Users (for example, data sent to the user interface will be displayed on the user terminal), and user requests for receiving and processing content, so that the requested content can be transmitted/streamed from the storage device to the user terminal . Alternatively, the encoder 150 generates a bit stream 101 and directly transmits/streams the content to the decoder 100 when the user requests the content. The decoder 100 then receives the bit stream 101 (or signal) and performs filtering with the deblocking filter according to the present invention to obtain/generate the video signal 109 and/or audio signal, which is then used by the user terminal to provide all Request content to users.

在先前實施例中,所述功能可以實施於硬體、軟體、韌體或其組合中。如果實施於軟體,則功能可以作為一或更多指令或碼被儲存或傳送於電腦可讀取媒體上並為硬體為主處理單元所執行。In the previous embodiment, the functions can be implemented in hardware, software, firmware, or a combination thereof. If implemented in software, the functions can be stored or transmitted as one or more instructions or codes on a computer-readable medium and executed by the hardware as the main processing unit.

電腦可讀取媒體可以包含電腦可讀取儲存媒體,其對應於有形媒體,例如資料儲存媒體或包含任何可以促成電腦程式例如依據通訊協定由一地轉移至另一地的媒體的通訊媒體。以此方式,電腦可讀取媒體通常對應於(1)有形電腦可讀取儲存媒體,其為非暫時性的,或(2)通訊媒體,例如信號或載波。資料儲存媒體可以為任何可用媒體,其可以為一或更多電腦或一或更多處理器所存取,以取得指令、碼及/或資料結構,以供在本案中所述的技術實施。電腦程式產品可以包含電腦可讀取媒體。The computer-readable medium may include a computer-readable storage medium, which corresponds to a tangible medium, such as a data storage medium, or a communication medium including any medium that can cause a computer program to be transferred from one place to another according to a communication protocol, for example. In this way, computer-readable media generally corresponds to (1) tangible computer-readable storage media, which is non-transitory, or (2) communication media, such as signals or carrier waves. The data storage medium may be any available medium, which may be accessed by one or more computers or one or more processors to obtain instructions, codes, and/or data structures for the implementation of the technology described in this case. The computer program product may include computer readable media.

例如但並不限於,此電腦可讀取儲存媒體可以包含RAM、ROM、EEPROM、CD-ROM或其他光碟儲存、磁碟儲存、或其他磁性儲存裝置、快閃記憶體、或任何其他媒體,其可以用以以指令或資料結構的形式儲存想要程式碼並可以為電腦所存取者。另外,任何連接較佳稱為電腦可讀取媒體。例如,如果指令被由網站、伺服器或其他使用同軸電纜、光纜、對絞線、數位用戶線(DSL)的遠端來源或者例如紅外線、無線電、及微波之無線技術傳送,則同軸電纜、光纜、對絞線、DSL、或例如紅外線、無線電及微波的無線技術係被包含在媒體的定義中。然而,應了解的是,電腦可讀取儲存媒體與資料儲存媒體並不包含連接、載波、信號或其他暫態媒體,而是有關於非暫態、有形儲存媒體。在此所用的碟片包含光碟(CD)、雷射光碟、光碟、數位多功能光碟(DVD)、軟碟及藍光碟,其中碟片通常磁性地播放資料,而以雷射作光學地播放資料。以上這些的結合也應包含在電腦可讀取媒體的範圍內。For example, but not limited to, the computer-readable storage medium may include RAM, ROM, EEPROM, CD-ROM or other optical disk storage, magnetic disk storage, or other magnetic storage devices, flash memory, or any other media, which It can be used to store the desired code in the form of commands or data structures and can be accessed by the computer. In addition, any connection is preferably called a computer-readable medium. For example, if the command is transmitted by a website, server, or other remote source using coaxial cable, optical cable, twisted pair, digital subscriber line (DSL), or wireless technology such as infrared, radio, and microwave, then the coaxial cable, optical cable , Twisted pair, DSL, or wireless technologies such as infrared, radio, and microwave are included in the definition of media. However, it should be understood that computer-readable storage media and data storage media do not include connections, carrier waves, signals, or other transient media, but non-transient, tangible storage media. The discs used here include compact discs (CDs), laser discs, optical discs, digital versatile discs (DVDs), floppy discs, and Blu-ray discs, where discs usually play data magnetically, while lasers play data optically . The combination of these should also be included in the scope of computer-readable media.

指令可以為例如一或更多數位信號處理器(DSP)、通用微處理器、特定應用積體電路(ASIC)、場可程式邏輯陣列(FPGA)、或其他等效整合或分立邏輯電路的一或更多處理器所執行。因此,於此所用之用語“處理器”可以表示任何前述結構或任何其他適用以執行於此所述之技術的結構。另外,在一些態樣中,於此所述之功能可以設在專用硬體及/或軟體模組中,其係被組態用以編碼或解碼或併入組合編解碼器中。另外,技術可以完全地實施在一或更多電腦或邏輯單元中。The instructions may be, for example, one or more multi-bit signal processors (DSPs), general-purpose microprocessors, application specific integrated circuits (ASICs), field programmable logic arrays (FPGAs), or other equivalent integrated or discrete logic circuits. Or more processors. Therefore, the term "processor" as used herein may refer to any of the foregoing structure or any other structure suitable for implementation of the techniques described herein. In addition, in some aspects, the functions described herein may be provided in dedicated hardware and/or software modules, which are configured to encode or decode or incorporate into a combined codec. In addition, the technology may be fully implemented in one or more computers or logic units.

本案的技術可以實施於各種裝置或設備中,包含無線手機、積體電路(IC)或IC組(例如,晶片組)。在本案中所述之各種元件、模組或單元係用以強調裝置的功能態樣,其被組態用以執行本案技術,但並不必然需要藉由不同硬體單元來實現。相反地,如上所述,各種單元可以組合成編解碼硬體單元或由包含一或更多如上所述之處理器配合適當軟體及/或韌體的互動硬體單元的集合所提供。The technology in this case can be implemented in various devices or equipment, including wireless handsets, integrated circuits (ICs), or IC groups (eg, chipsets). The various components, modules or units described in this case are used to emphasize the functional aspects of the device, which are configured to perform the technology of this case, but do not necessarily need to be implemented by different hardware units. Conversely, as described above, various units can be combined into a codec hardware unit or provided by a collection of interactive hardware units that include one or more processors as described above with appropriate software and/or firmware.

雖然本發明已經在圖式及前述說明中加以詳細顯示與描述,此等例示與描述被認為是例示或範例並不限定用,本發明並不限於所揭露的實施例。對所揭露實施例的其他變化仍可以為熟習於本技藝者透過對附圖、本案與隨附申請專利範圍的研讀加以了解與作動,以實體化(即,執行)所主張發明。Although the present invention has been shown and described in detail in the drawings and the foregoing description, these illustrations and descriptions are considered to be examples or examples and are not limiting, and the invention is not limited to the disclosed embodiments. Other changes to the disclosed embodiments can still be understood and acted upon by those skilled in the art by studying the drawings, the case, and the scope of the accompanying patent applications to substantiate (ie, execute) the claimed invention.

第一、第二、第三及第四態樣的部份實施例可以結合。Some embodiments of the first, second, third and fourth aspects can be combined.

例如,偏移O1及O4(峰及谷)的符號可以被傳送於位元流中作亮度與色度成分。例如,偏移O1及O4(峰及谷)的符號可以被傳送於位元流中作亮度與色度成分。另外,絕對預測子值可以被設定等於用於偏移O1及O4(峰及谷)的符號法的值N。For example, symbols with offsets O1 and O4 (peaks and valleys) can be transmitted in the bitstream as luminance and chrominance components. For example, symbols with offsets O1 and O4 (peaks and valleys) can be transmitted in the bitstream as luminance and chrominance components. In addition, the absolute predictor value may be set equal to the value N of the sign method for offsetting O1 and O4 (peak and valley).

在另一實施例中,符號法也可以被傳送有一對應於以下組N值:{0,2,4,8}的表組。In another embodiment, the symbology can also be transmitted with a table set corresponding to the following set of N values: {0, 2, 4, 8}.

在申請專利範圍中,用於“包含”並不排除其他元件或步驟,及不定冠詞“a”或“an”並不排除多數。單一處理器或其他單元可能實現在申請專利範圍中所述之幾個元件的功能。這表示不同特性在彼此不同附屬項中加以描述者並不表示這些特性的組合並不能有利地使用。在申請專利範圍中之元件符號並不應被建構為限定本發明的範圍。In the scope of the patent application, the use of "including" does not exclude other elements or steps, and the indefinite article "a" or "an" does not exclude the majority. A single processor or other unit may implement the functions of several elements described in the scope of the patent application. This means that different characteristics are described in different sub-items with each other. This does not mean that the combination of these characteristics cannot be used advantageously. The component symbols in the patent application scope should not be constructed to limit the scope of the present invention.

1‧‧‧視訊序列 2‧‧‧影像 3‧‧‧切片 4‧‧‧編碼樹方塊 5‧‧‧編碼單元 6‧‧‧預測單元 7‧‧‧轉換單元 200‧‧‧資料通訊網路 201‧‧‧伺服器 202‧‧‧客戶 204‧‧‧資料流 300‧‧‧處理裝置 302‧‧‧通訊介面 303‧‧‧通訊網路 304‧‧‧資料儲存手段 305‧‧‧磁碟機 306‧‧‧碟片 307‧‧‧唯讀記憶體 308‧‧‧麥克風 309‧‧‧螢幕 310‧‧‧鍵盤 311‧‧‧中央處理單元 312‧‧‧隨機存取記憶體 313‧‧‧通訊匯流排 320‧‧‧數位相機 400‧‧‧編碼器 401‧‧‧原始序列影像 402‧‧‧切割模組 403‧‧‧內預測模組 404‧‧‧動作估計模組 405‧‧‧動作補償模組 406‧‧‧選擇模組 407‧‧‧轉換模組 408‧‧‧量化模組 409‧‧‧熵編碼 410‧‧‧位元流 411‧‧‧去量化模組 412‧‧‧逆轉換模組 413‧‧‧內預測模組 414‧‧‧動作補償模組 415‧‧‧後濾波模組 416‧‧‧參考影像/圖片 417‧‧‧動作向量預測及編碼模組 418‧‧‧動作向量欄 50‧‧‧環路濾波程序 51‧‧‧初始步驟 52‧‧‧解塊濾波器 53‧‧‧重建 54‧‧‧取樣自適應偏移 55‧‧‧所得畫框 56‧‧‧適應環路濾波器 57‧‧‧重建畫框 58‧‧‧分類 60‧‧‧解碼器 61‧‧‧位元流 62‧‧‧熵解碼 63‧‧‧去量化 64‧‧‧逆轉換 65‧‧‧內預測 66‧‧‧動作補償 67‧‧‧後濾波 68‧‧‧參考影像/圖片 69‧‧‧解碼視訊信號 70‧‧‧動作向量解碼模組 71‧‧‧動作向量欄資料 40‧‧‧群 41‧‧‧帶 42‧‧‧帶 43‧‧‧帶 44‧‧‧帶1‧‧‧Video sequence 2‧‧‧Image 3‧‧‧Slice 4‧‧‧ coding tree box 5‧‧‧Coding unit 6‧‧‧Prediction Unit 7‧‧‧ Conversion unit 200‧‧‧Data communication network 201‧‧‧Server 202‧‧‧Customer 204‧‧‧Data flow 300‧‧‧Processing device 302‧‧‧Communication interface 303‧‧‧Communication network 304‧‧‧Data storage method 305‧‧‧Drive 306‧‧‧disc 307‧‧‧Read-only memory 308‧‧‧Microphone 309‧‧‧ screen 310‧‧‧ keyboard 311‧‧‧Central Processing Unit 312‧‧‧random access memory 313‧‧‧Communication bus 320‧‧‧ digital camera 400‧‧‧Encoder 401‧‧‧ Original sequence image 402‧‧‧Cutting module 403‧‧‧Internal prediction module 404‧‧‧Motion estimation module 405‧‧‧Motion compensation module 406‧‧‧Select module 407‧‧‧ Conversion module 408‧‧‧Quantization module 409‧‧‧Entropy coding 410‧‧‧ bit stream 411‧‧‧ Dequantization module 412‧‧‧Inverse Conversion Module 413‧‧‧Internal prediction module 414‧‧‧Motion compensation module 415‧‧‧Post filter module 416‧‧‧Reference image/picture 417‧‧‧Motion vector prediction and coding module 418‧‧‧Action Vector Bar 50‧‧‧Loop filter program 51‧‧‧Initial steps 52‧‧‧deblocking filter 53‧‧‧Reconstruction 54‧‧‧Sample adaptive offset 55‧‧‧ frame 56‧‧‧Adaptive loop filter 57‧‧‧ Reconstruction 58‧‧‧Classification 60‧‧‧decoder 61‧‧‧ bit stream 62‧‧‧Entropy decoding 63‧‧‧ Dequantization 64‧‧‧Inverse conversion 65‧‧‧ forecast 66‧‧‧Motion compensation 67‧‧‧Post filtering 68‧‧‧Reference image/picture 69‧‧‧decode video signal 70‧‧‧Motion vector decoding module 71‧‧‧Action vector column data 40‧‧‧ group 41‧‧‧ belt 42‧‧‧belt 43‧‧‧ belt 44‧‧‧band

現將僅以例示並參考以下附圖的方式加以描述本發明實施例。The embodiments of the present invention will now be described by way of illustration only and with reference to the following drawings.

圖1為用於解釋HEVC中所使用的編碼結構的示意圖;FIG. 1 is a schematic diagram for explaining the coding structure used in HEVC;

圖2為例示出資料通訊系統的方塊圖,其中可以實施本發明之一或更多實施例;FIG. 2 is a block diagram illustrating a data communication system in which one or more embodiments of the present invention can be implemented;

圖3為例示出處理裝置的元件的方塊圖,其中可以實施本發明之一或更多實施例;FIG. 3 is a block diagram illustrating elements of a processing device, in which one or more embodiments of the present invention may be implemented;

圖4為例示依據本發明實施例之編碼方法步驟的流程圖;4 is a flowchart illustrating steps of an encoding method according to an embodiment of the invention;

圖5為依據本發明之一或更多實施例之環路濾波程序的步驟流程圖;FIG. 5 is a flowchart of the steps of the loop filtering process according to one or more embodiments of the present invention;

圖6為依據本發明實施例之解碼方法的步驟流程圖;6 is a flowchart of steps of a decoding method according to an embodiment of the invention;

圖7A及7B為用於解釋在HEVC中的邊緣型SAO濾波的圖表;7A and 7B are diagrams for explaining edge-type SAO filtering in HEVC;

圖8為用於解釋在HEVC中的帶型SAO濾波的圖表;8 is a diagram for explaining band-type SAO filtering in HEVC;

圖9為例示出依據HEVC規格以解碼SAO參數的程序步驟的流程圖;FIG. 9 is a flowchart illustrating the procedure steps of decoding SAO parameters according to the HEVC specification;

圖10為例示出圖9的程序的步驟的更詳細的一步驟的流程圖;10 is a flowchart illustrating a more detailed one step of the procedure of FIG. 9;

圖11為例示出SAO濾波如何依據HEVC規格執行於影像部上的流程圖;FIG. 11 is a flowchart illustrating how SAO filtering is performed on the video part according to the HEVC specification;

圖12為用以執行編碼器以決定用於一群(畫框或切片)的CTU的SAO參數的步驟流程圖;FIG. 12 is a flowchart of steps used to execute an encoder to determine SAO parameters for a group of CTUs (frames or slices);

圖13為流程圖,用以例示可以應用於邊緣偏移型濾波器的在編碼器側計算的統計的例子的步驟;13 is a flowchart for illustrating the steps of an example of statistics calculated on the encoder side that can be applied to an edge offset filter;

圖14顯示第一編碼程序的步驟;Figure 14 shows the steps of the first encoding procedure;

圖15顯示第二編碼程序的步驟;Figure 15 shows the steps of the second encoding procedure;

圖16為一流程圖,用以例示SAO濾波如何依據本發明第一態樣的第一實施例而執行於影像部上;16 is a flowchart illustrating how SAO filtering is performed on the image portion according to the first embodiment of the first aspect of the present invention;

圖17例示依據圖16所示之第一實施例,在解碼器側解析在位元流中的SAO參數的程序步驟;FIG. 17 illustrates the procedure of parsing the SAO parameters in the bit stream on the decoder side according to the first embodiment shown in FIG. 16;

圖18例示依據第二實施例在解碼器側解析在位元流中的SAO參數的程序步驟;18 illustrates a procedure of parsing SAO parameters in a bit stream on the decoder side according to the second embodiment;

圖19例示依據第三實施例在解碼器側解析在位元流中的SAO參數的程序步驟;FIG. 19 illustrates a procedure of parsing SAO parameters in a bit stream on the decoder side according to the third embodiment;

圖20例示以編碼器作eo_sign_method_X選擇的例子;Fig. 20 illustrates an example of using an encoder to select eo_sign_method_X;

圖21為流程圖,例示SAO濾波係如何依據本發明第一態樣的第四實施例而執行於影像部上;21 is a flowchart illustrating how the SAO filtering system is executed on the image portion according to the fourth embodiment of the first aspect of the present invention;

圖22為流程圖,例示SAO濾波係如何依據本發明第一態樣的第五實施例而執行於影像部上;22 is a flowchart illustrating how the SAO filtering system is executed on the image portion according to the fifth embodiment of the first aspect of the present invention;

圖23例示依據第六實施例在解碼器側解析在位元流中的SAO參數的程序步驟;FIG. 23 illustrates a procedure of parsing the SAO parameters in the bit stream on the decoder side according to the sixth embodiment;

圖24為流程圖,例示在編碼器側計算的統計應用至邊緣偏移型濾波器的例子的步驟;FIG. 24 is a flowchart illustrating the steps of an example in which statistics calculated on the encoder side are applied to an edge offset type filter;

圖25為流程圖,例示被執行以決定用於一群(畫框或切片)的CTU的SAO參數的編碼器的步驟;FIG. 25 is a flowchart illustrating the steps of an encoder executed to determine the SAO parameters for a group of CTUs (frames or slices);

圖26為流程圖,例示依據第二態樣的第二實施例,以解碼SAO參數的程序步驟;FIG. 26 is a flowchart illustrating a procedure of decoding SAO parameters according to the second embodiment of the second aspect;

圖27A及27B為用於解釋依據實施例的邊緣型SAO濾波的圖表;27A and 27B are diagrams for explaining edge-type SAO filtering according to the embodiment;

圖28為依據第二態樣的第三實施例的解碼SAO參數的程序步驟的流程圖;28 is a flowchart of the procedure steps of decoding SAO parameters according to the third embodiment of the second aspect;

圖29為依據第二態樣的第四實施例的解碼SAO參數的程序步驟的流程圖;FIG. 29 is a flowchart of procedure steps of decoding SAO parameters according to the fourth embodiment of the second aspect;

圖30為依據第二態樣的第五實施例的解碼SAO參數的程序步驟的流程圖;30 is a flowchart of the procedure steps of decoding SAO parameters according to the fifth embodiment of the second aspect;

圖31為依據第二態樣的第六實施例的解碼SAO參數的程序步驟的流程圖;FIG. 31 is a flowchart of procedure steps of decoding SAO parameters according to the sixth embodiment of the second aspect;

圖32為依據第二態樣的第七實施例的解碼SAO參數的程序步驟的流程圖;32 is a flowchart of the procedure steps of decoding SAO parameters according to the seventh embodiment of the second aspect;

圖33例示可以在依據第三態樣的第一實施例在解碼器側的SAO濾波實施例期間執行的預測程序步驟;FIG. 33 illustrates steps of a prediction procedure that can be performed during the SAO filtering embodiment on the decoder side according to the first embodiment of the third aspect;

圖34例示可以在依據第三態樣的第二實施例在解碼器側的SAO濾波實施例期間執行的預測程序步驟;FIG. 34 illustrates steps of a prediction procedure that can be performed during the SAO filtering embodiment on the decoder side according to the second embodiment of the third aspect;

圖35例示可以在依據第三態樣的第三實施例在解碼器側的SAO濾波實施例期間執行的預測程序步驟;FIG. 35 illustrates steps of a prediction procedure that can be performed during the SAO filtering embodiment on the decoder side according to the third embodiment of the third aspect;

圖36例示可以在依據第三態樣的第四實施例在解碼器側的SAO濾波實施例期間執行的預測程序步驟;FIG. 36 illustrates steps of a prediction procedure that can be performed during the SAO filtering embodiment on the decoder side according to the fourth embodiment of the third aspect;

圖37例示可以在依據第三態樣的第五實施例在解碼器側的SAO濾波實施例期間執行的預測程序步驟;FIG. 37 illustrates steps of a prediction procedure that can be performed during the SAO filtering embodiment on the decoder side according to the fifth embodiment of the third aspect;

圖38例示可以在依據第三態樣的第六實施例在解碼器側的SAO濾波實施例期間執行的預測程序步驟;FIG. 38 illustrates steps of a prediction procedure that can be performed during the SAO filtering embodiment on the decoder side according to the sixth embodiment of the third aspect;

圖39為依據本發明實施例的包含編碼器或解碼器與通訊網路的系統的示意圖。39 is a schematic diagram of a system including an encoder or decoder and a communication network according to an embodiment of the invention.

Claims (52)

一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得邊緣偏移,以執行SAO濾波; 使用用以決定該邊緣偏移的索引的預定符號法,將邊緣偏移分類施加至該影像的至少一像素; 其中該預定符號法被發信於該位元流中。A method for performing sample adaptive offset (SAO) filtering on an image including most image parts, the method includes: Get the edge offset to perform SAO filtering; Applying a predetermined symbol method to determine the index of the edge offset, applying the edge offset classification to at least one pixel of the image; The predetermined symbol method is sent in the bit stream. 如申請專利範圍第1項之方法,其中該預定符號法以CTU、畫框、切片或序列位準被發信於該位元流中。For example, in the method of claim 1, the predetermined symbol method is sent to the bit stream in CTU, frame, slice or sequence level. 如申請專利範圍第1或2項之方法,其中該預定符號法被預測。For example, the method of claim 1 or 2, wherein the predetermined symbol method is predicted. 如前述申請專利範圍之任一項之方法,其中該預定符號法考量對應於限定值的數目N界定符號函數。A method as claimed in any one of the aforementioned patent applications, wherein the predetermined symbolic method consideration corresponds to the number N of defined values to define a symbolic function. 如申請專利範圍第4項之方法,其中該預定符號法係在該編碼器側根據不連續的多數限定值N加以選擇。For example, in the method of claim 4, the predetermined symbol method is selected on the encoder side according to the discontinuous majority limit value N. 如申請專利範圍第4項之方法,其中該預定符號法係在該編碼器側根據取決於該切片型的多數限定值N加以選擇。For example, the method of claim 4 of the patent application, wherein the predetermined symbol method is selected on the encoder side according to the majority limit value N depending on the slice type. 如申請專利範圍第4項之方法,其中該預定符號法係在該編碼器側根據取決於色彩成分的多數限定值N加以選擇。For example, the method of claim 4 of the patent application, wherein the predetermined symbol method is selected on the encoder side according to the majority limit value N depending on the color component. 如申請專利範圍第4項之方法,其中該預定符號法係在該編碼器側根據只取決於亮度成分的多數限定值N加以選擇。For example, the method of claim 4 of the patent application, wherein the predetermined symbol method is selected on the encoder side according to the majority limit value N that depends only on the luminance component. 如申請專利範圍第4項之方法,其中該預定符號法係在該編碼器側根據發信在切片檔頭中的多數限定值N加以選擇。For example, the method of claim 4 of the patent application, wherein the predetermined symbol method is selected on the encoder side according to the majority limit value N in the slice header transmitted. 如申請專利範圍第4項之方法,其中該預定符號法係在該編碼器側根據多數限定值N加以選擇。For example, in the method of claim 4, the predetermined symbol method is selected on the encoder side according to the majority limit value N. 一種提供邊緣偏移以對影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 計算邊緣偏移,以執行該SAO濾波; 在多數可能符號法中選擇一符號法,以用以決定該邊緣偏移的索引;及 在該位元流中發信該所選擇的符號法,藉以允許該邊緣偏移分類予以依據該所選擇的符號法執行。A method for providing edge offset to perform sample adaptive offset (SAO) filtering on an image, the method includes: Calculate the edge offset to perform the SAO filtering; Choose one of the most possible symbologies to use to determine the index of the edge offset; and The selected symbol method is signaled in the bitstream, thereby allowing the edge offset classification to be performed according to the selected symbol method. 如申請專利範圍第11項之方法,其中該符號法係以CTU、畫框、切片或序列位準被發信在該位元流中。For example, the method of claim 11 of the patent scope, wherein the symbol method is sent in the bit stream in CTU, frame, slice or sequence level. 如申請專利範圍第11或12項之方法,其中該符號法被預測。For example, the method of claim 11 or 12, wherein the symbol method is predicted. 如申請專利範圍第11至13項中任一項之方法,其中該符號法係依據現行切片或畫框的參數加以選擇。For example, the method of any one of the items 11 to 13 of the patent application scope, wherein the symbol method is selected according to the parameters of the current slice or frame. 如申請專利範圍第11至14項中任一項之方法,其中該符號法考量對應於限定值的數目N來界定一符號函數。The method as in any one of the items 11 to 14 of the patent application scope, wherein the symbolic method considers the number N corresponding to the limit value to define a symbolic function. 一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中該多數邊緣偏移的至少一邊緣偏移的符號係被發信於該位元流中。A method for performing sample adaptive offset (SAO) filtering on an image including most image parts, the method includes: Obtain most edge offsets to perform SAO filtering; At least one edge-shifted symbol of the majority of edge shifts is sent in the bit stream. 如申請專利範圍第16項之方法,其中該邊緣偏移的該符號係被發信於該多數邊緣偏移的所有邊緣偏移,其中用以決定該邊緣偏移的索引的符號函數中所用的符號參數N為正。As in the method of claim 16, the symbol of the edge offset is sent to all edge offsets of the majority of edge offsets, where the symbol function used to determine the index of the edge offset is used in The sign parameter N is positive. 如申請專利範圍第16項之方法,其中該邊緣偏移的該符號係被發信於該多數邊緣偏移的所有邊緣偏移,如果用以決定該邊緣偏移的索引的符號函數中所用的所有該符號參數N高於預定臨限的話。For example, the method of claim 16 of the patent application, in which the symbol of the edge offset is sent to all edge offsets of the majority of edge offsets, if used in the symbol function used to determine the index of the edge offset If all the symbol parameters N are higher than the predetermined threshold. 如申請專利範圍第16項之方法,其中該至少一邊緣偏移中,其符號被發信者屬於該峰與谷架構。For example, in the method of claim 16, wherein in the at least one edge offset, the symbol whose signal is sent belongs to the peak and valley structure. 如申請專利範圍第16項之方法,其中不論被使用以決定該邊緣偏移的索引之預定符號法為何,該至少一邊緣偏移的該符號都被發信。For example, in the method of claim 16 of the patent application range, regardless of the predetermined symbol method used to determine the index of the edge offset, the symbol of the at least one edge offset is sent. 如申請專利範圍第16項之方法,其中該邊緣偏移的該符號只被發信於該邊緣偏移,其中用以決定這些邊緣偏移的索引的該符號參數N高於預定臨限。For example, in the method of claim 16, the symbol of the edge offset is only sent to the edge offset, and the symbol parameter N used to determine the index of the edge offset is higher than a predetermined threshold. 如申請專利範圍第16項之方法,其中該邊緣偏移的該符號只被發信於該邊緣偏移,其中用以決定這些邊緣偏移的索引的該符號參數N不是零。For example, in the method of claim 16, the symbol of the edge offset is only sent to the edge offset, and the symbol parameter N used to determine the indexes of the edge offsets is not zero. 如申請專利範圍第16至22項中任一項之方法,其中該邊緣偏移的該符號只針對該亮度成分發信。A method as in any one of claims 16 to 22, wherein the symbol with the edge shifted is sent only for the luminance component. 一種提供邊緣偏移以對影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行該SAO濾波; 藉由針對各個邊緣偏移,施加符號法至符號參數N,計算該邊緣偏移的索引;及 將該多數邊緣偏移的至少一邊緣偏移的符號發信於該位元流中。A method for providing edge offset to perform sample adaptive offset (SAO) filtering on an image, the method includes: Obtain the majority of edge offsets to perform the SAO filtering; Calculate the index of the edge offset by applying the sign method to the symbol parameter N for each edge offset; and At least one edge-offset symbol of the majority of edge offsets is signaled in the bit stream. 一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中該多數邊緣偏移的至少一邊緣偏移的符號被發信於該位元流中;及 其中取得多數邊緣偏移包含預測至少一邊緣偏移,其符號係被發信於該位元流中者。A method for performing sample adaptive offset (SAO) filtering on an image including most image parts, the method includes: Obtain most edge offsets to perform SAO filtering; Where at least one edge-shifted symbol of the majority of edge shifts is signaled in the bitstream; and Obtaining the majority of edge offsets includes predicting at least one edge offset whose symbol is sent to the bitstream. 如申請專利範圍第25項之方法,其中該至少一邊緣偏移係由預設值預測。As in the method of claim 25, wherein the at least one edge offset is predicted from a preset value. 如申請專利範圍第26項之方法,其中該預設值係被傳送於該位元流中。For example, the method of claim 26, wherein the preset value is transmitted in the bit stream. 如申請專利範圍第26項之方法,其中該預設值係針對至少一序列加以預定。For example, the method of claim 26, wherein the preset value is predetermined for at least one sequence. 如申請專利範圍第26項之方法,更包含設定該預設值的該符號。For example, the method of applying for item 26 of the patent scope further includes setting the symbol of the preset value. 如申請專利範圍第26項之方法,其中該預設值取決於符號參數N,其被用在用以決定該邊緣偏移的索引的符號函數中。For example, the method of claim 26, wherein the preset value depends on the symbol parameter N, which is used in the symbol function used to determine the index of the edge offset. 如申請專利範圍第25項之方法,更包含: 對該影像的像素施加邊緣偏移分類,以將該像素分類為四個類型,各個類型相關於一給定邊緣偏移,及 其中有關於對應於該峰及谷的第一與最後類型的該邊緣偏移的絕對預測子值係高於有關於其他類型的該邊緣偏移的絕對預測子值。For example, the method of applying for item 25 of the patent scope further includes: Applying edge offset classification to pixels of the image to classify the pixel into four types, each type being associated with a given edge offset, and Among them, the absolute predictor values for the first and last types of edge shifts corresponding to the peaks and valleys are higher than those for other types of edge shifts. 如申請專利範圍第25項之方法,更包含: 對該影像的像素施加邊緣偏移分類,以將該像素分類為四個類型,各個類型有關於一給定邊緣偏移,及 其中有關於對應於該峰與谷的第一與最後類型的該邊緣偏移的絕對預測子值相同。For example, the method of applying for item 25 of the patent scope further includes: Applying edge offset classification to pixels of the image to classify the pixel into four types, each type having a given edge offset, and There is the same absolute predictor value for the edge shifts of the first and last types corresponding to the peaks and valleys. 如申請專利範圍第32項之方法,其中有關於其他類型的該邊緣偏移的絕對預測子值相同。For example, in the method of claim 32, there are other types of edge predictors with the same absolute predictor value. 如申請專利範圍第31或32項之方法,其中該邊緣偏移分類考量該多數邊緣偏移的至少一邊緣偏移的被發信於該位元流中的該符號。For example, the method of claim 31 or 32, wherein the edge offset classification considers at least one edge offset of the majority of edge offsets to be transmitted to the symbol in the bitstream. 如申請專利範圍第25項之方法,其中該至少一邊緣偏移係由符號參數N預測,該符號參數N被用於用以決定該邊緣偏移的索引的符號函數中。For example, the method of claim 25, wherein the at least one edge offset is predicted by a symbol parameter N, and the symbol parameter N is used in the symbol function used to determine the index of the edge offset. 如申請專利範圍第25項之方法,其中該多數邊緣偏移中,其符號被發信於該位元流中的至少一些邊緣偏移未被預測。For example, the method of claim 25, wherein in the majority of edge offsets, at least some edge offsets whose symbols are signaled in the bitstream are not predicted. 如申請專利範圍第25項之方法,更包含: 施加邊緣偏移分類至該影像的像素,以將該像素分類為四個類型,各個類型係有關於一給定邊緣偏移,及 其中只有有關於對應於該峰與谷的第一及最後類型的該邊緣偏移被預測。For example, the method of applying for item 25 of the patent scope further includes: Apply an edge offset to the pixels of the image to classify the pixel into four types, each type is related to a given edge offset, and Only the first and last types of edge shifts corresponding to the peaks and valleys are predicted. 如申請專利範圍第25項之方法,其中該邊緣偏移只針對亮度成分預測。As in the method of claim 25, where the edge shift is only predicted for the luminance component. 如申請專利範圍第25項之方法,更包含: 施加邊緣偏移分類至該影像的像素,以將該像素分類為四個類型,各個類型係有關於一給定邊緣偏移,及 其中只有有關於對應於該峰及谷的第一與最後類型的該邊緣偏移及針對該亮度成分的該邊緣偏移被預測。For example, the method of applying for item 25 of the patent scope further includes: Apply an edge offset to the pixels of the image to classify the pixel into four types, each type is related to a given edge offset, and Among them, only the first and last types of the edge shift corresponding to the peaks and valleys and the edge shift for the luminance component are predicted. 如申請專利範圍第25項之方法,其中該至少一邊緣偏移係由相鄰邊緣偏移值加以預測。For example, the method of claim 25, wherein the at least one edge offset is predicted from the adjacent edge offset value. 如申請專利範圍第25項之方法,其中只有當相鄰邊緣偏移使用相同符號法加以決定時,該至少一邊緣偏移才由該相鄰邊緣偏移值預測。For example, in the method of claim 25, wherein only when the adjacent edge offset is determined using the same sign method, the at least one edge offset is predicted from the adjacent edge offset value. 一種提供邊緣偏移以對影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行該SAO濾波; 針對各個邊緣偏移,取得該邊緣偏移的符號; 其中該方法更包含將該多數邊緣偏移的至少一邊緣偏移的該符號發信於該位元流中;及 其中取得多數邊緣偏移包含預測至少一邊緣偏移,其符號被發信於該位元流中者。A method for providing edge offset to perform sample adaptive offset (SAO) filtering on an image, the method includes: Obtain the majority of edge offsets to perform the SAO filtering; For each edge offset, obtain the sign of the edge offset; The method further includes signaling the symbol of at least one edge offset of the majority of edge offsets in the bitstream; and Obtaining the majority of edge offsets includes predicting at least one edge offset whose symbol is sent to the bitstream. 一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 取得多數邊緣偏移,以執行SAO濾波; 其中取得多數邊緣偏移包含預測至少一邊緣偏移;及 其中該至少一邊緣偏移的符號為隱式及該邊緣偏移的最小值被設定為不是零的預設值。A method for performing sample adaptive offset (SAO) filtering on an image including most image parts, the method includes: Obtain most edge offsets to perform SAO filtering; Wherein obtaining the majority of edge offsets includes predicting at least one edge offset; and The sign of the at least one edge offset is implicit and the minimum value of the edge offset is set to a preset value that is not zero. 一種提供邊緣偏移以對影像執行取樣自適應偏移(SAO)濾波的方法,該方法包含: 計算多數邊緣偏移,以執行該SAO濾波; 其中計算多數邊緣偏移包含預測至少一邊緣偏移,及 其中該至少一邊緣偏移的符號為隱式及該邊緣偏移的最小值被設定為不是零的預設值。A method for providing edge offset to perform sample adaptive offset (SAO) filtering on an image, the method includes: Calculate the majority of edge offsets to perform the SAO filtering; Where calculating most edge offsets includes predicting at least one edge offset, and The sign of the at least one edge offset is implicit and the minimum value of the edge offset is set to a preset value that is not zero. 一種編碼影像的方法,包含使用申請專利範圍第11、24、42或44項中任一項之方法,執行取樣自適應偏移(SAO)濾波。A method for encoding an image, including using any one of the patent application items 11, 24, 42 or 44 to perform sample adaptive offset (SAO) filtering. 一種解碼影像的方法,包含使用申請專利範圍第1、16、25或43項中任一項之方法,執行取樣自適應偏移(SAO)濾波。A method of decoding an image, including using the method of any one of patent application items 1, 16, 25, or 43, to perform sample adaptive offset (SAO) filtering. 一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的裝置,該裝置包含微處理器,被架構以執行如申請專利範圍第11、24、42或44項中任一項之方法的步驟。An apparatus for performing sample adaptive offset (SAO) filtering on an image including a majority of image parts. The apparatus includes a microprocessor and is structured to perform any one of items 11, 24, 42, or 44 of the patent application. Method steps. 一種對包含多數影像部的影像執行取樣自適應偏移(SAO)濾波的裝置,該裝置包含微處理器,被架構以執行如申請專利範圍第1、16、25或43項中任一項之方法的步驟。An apparatus for performing sample adaptive offset (SAO) filtering on an image including a majority of image parts. The apparatus includes a microprocessor and is structured to perform any one of items 1, 16, 25, or 43 of the patent application. Method steps. 一種編碼器,包含如申請專利範圍第46項之裝置。An encoder including the device as claimed in item 46 of the patent scope. 一種解碼器,包含如申請專利範圍第47項之裝置。A decoder including a device as claimed in item 47 of the patent scope. 一種程式,當為電腦或處理器所執行時,使得該電腦或該處理器執行如申請專利範圍第1、11、16、24、25、42、43、44項中任一項之方法。A program, when executed by a computer or a processor, causes the computer or the processor to execute the method of any one of items 1, 11, 16, 24, 25, 42, 43, and 44 of the patent application. 一種系統,包含如申請專利範圍第49項之編碼器及如申請專利範圍第50項之解碼器,被架構以透過通訊網路通訊。A system including an encoder as claimed in item 49 and a decoder as claimed in item 50 is constructed to communicate through a communication network.
TW108116392A 2018-06-29 2019-05-13 Methods and devices for performing sample adaptive offset (SAO) filtering TW202002656A (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
GB1810787.0 2018-06-29
GB1810787.0A GB2575119B (en) 2018-06-29 2018-06-29 Methods and devices for performing sample adaptive offset (SAO) filtering

Publications (1)

Publication Number Publication Date
TW202002656A true TW202002656A (en) 2020-01-01

Family

ID=63143568

Family Applications (1)

Application Number Title Priority Date Filing Date
TW108116392A TW202002656A (en) 2018-06-29 2019-05-13 Methods and devices for performing sample adaptive offset (SAO) filtering

Country Status (3)

Country Link
GB (1) GB2575119B (en)
TW (1) TW202002656A (en)
WO (1) WO2020002117A2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021247883A1 (en) * 2020-06-03 2021-12-09 Beijing Dajia Internet Information Technology Co., Ltd. Chroma coding enhancement in cross-component correlation
CN111866507B (en) * 2020-06-07 2024-09-27 咪咕文化科技有限公司 Image filtering method, device, equipment and storage medium
CN114760481B (en) * 2022-04-29 2023-05-30 北京淳中科技股份有限公司 Video coding method, device, equipment and storage medium

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013070148A1 (en) * 2011-11-07 2013-05-16 Telefonaktiebolaget L M Ericsson (Publ) Improved sample adaptive offset compensation of video data
KR20130084053A (en) * 2012-01-16 2013-07-24 주식회사 케이티 Sample adaptive offset(sao) edge offset prediction simplification
KR20130084054A (en) * 2012-01-16 2013-07-24 주식회사 케이티 Sample adaptive offset (sao) edge offset
RU2686008C2 (en) * 2012-01-17 2019-04-23 Инфобридж Пте. Лтд. Method of using edge shift
KR101962984B1 (en) * 2012-06-27 2019-03-27 선 페이턴트 트러스트 Image encoding method, image decoding method, image encoding device, image decoding device and image encoding/decoding device
GB2512827B (en) * 2013-04-05 2015-09-16 Canon Kk Method and device for classifying samples of an image
JP6328759B2 (en) * 2013-07-15 2018-05-23 寰發股▲ふん▼有限公司HFI Innovation Inc. Method of sample adaptive offset processing for video coding

Also Published As

Publication number Publication date
WO2020002117A3 (en) 2020-02-06
GB2575119A (en) 2020-01-01
GB201810787D0 (en) 2018-08-15
GB2575119B (en) 2021-11-24
WO2020002117A2 (en) 2020-01-02

Similar Documents

Publication Publication Date Title
US11601687B2 (en) Method and device for providing compensation offsets for a set of reconstructed samples of an image
RU2720975C2 (en) Method of encoding and decoding images, an encoding and decoding device and corresponding computer programs
US10298937B2 (en) Method, device, computer program, and information storage means for encoding or decoding a video sequence
US20150341638A1 (en) Method and device for processing prediction information for encoding or decoding an image
JP7494218B2 (en) Clipping index coding for adaptive loop filters in video encoding
US20220337814A1 (en) Image encoding/decoding method and device using reference sample filtering, and method for transmitting bitstream
TW202002656A (en) Methods and devices for performing sample adaptive offset (SAO) filtering
TW202005398A (en) Video coding and decoding
TW202013963A (en) Video coding and decoding
US11638024B2 (en) Image encoding/decoding method and apparatus for signaling residual coding method used for encoding block to which BDPCM is applied, and method for transmitting bitstream
GB2509706A (en) Encoding or decoding a scalable video sequence using inferred SAO parameters
TW202005370A (en) Video coding and decoding
TW202005371A (en) Video coding and decoding