技术领域Technical field
本发明涉及一种用于对图像进行编码/解码的方法和设备。具体地讲,本发明涉及一种用于使用帧内预测对图像进行编码/解码的方法和设备以及存储通过本发明的图像编码方法/设备产生的比特流的记录介质。The present invention relates to a method and device for encoding/decoding images. In particular, the present invention relates to a method and apparatus for encoding/decoding an image using intra prediction and a recording medium storing a bit stream generated by the image encoding method/apparatus of the present invention.
背景技术Background technique
近来,对诸如高清(HD)图像和超高清(UHD)图像的高分辨率和高质量图像的需求在各个应用领域已获得增长。然而,与传统的图像数据相比,更高分辨率和质量的图像数据的数据量有所增加。因此,当通过使用诸如传统的有线宽带网络和无线宽带网络的介质发送图像数据时,或者当通过使用传统的存储介质存储图像数据时,发送和存储的成本增加。为了解决这些随着图像数据的分辨率和质量的提高而出现的问题,对于更高分辨率和更高质量的图像,需要高效图像编码/解码技术。Recently, demand for high-resolution and high-quality images such as high-definition (HD) images and ultra-high-definition (UHD) images has increased in various application fields. However, the data volume of image data with higher resolution and quality has increased compared with traditional image data. Therefore, when image data is transmitted by using a medium such as a conventional wired broadband network and a wireless broadband network, or when image data is stored by using a conventional storage medium, transmission and storage costs increase. In order to solve these problems that arise as the resolution and quality of image data increase, efficient image encoding/decoding technology is required for higher resolution and higher quality images.
图像压缩技术包括各种技术,包括:从当前画面的先前画面或后续画面预测包括在当前画面中的像素值的帧间预测技术;通过使用当前画面中的像素信息来预测包括在当前画面中的像素值的帧内预测技术;用于压缩残差信号的能量的变换和量化技术;向高出现频率的值分配短码并且向低出现频率的值分配长码的熵编码技术;等等。通过使用这样的图像压缩技术,图像数据可被有效压缩,并且可被发送或存储。Image compression technology includes various technologies, including: inter prediction technology that predicts pixel values included in the current picture from a previous picture or a subsequent picture of the current picture; predicting pixel values included in the current picture by using pixel information in the current picture Intra-frame prediction techniques for pixel values; transformation and quantization techniques for compressing the energy of residual signals; entropy coding techniques that assign short codes to values with high frequency of occurrence and long codes to values with low frequency of occurrence; etc. By using such image compression technology, image data can be efficiently compressed, and can be sent or stored.
发明内容Contents of the invention
技术问题technical problem
本发明的目的在于提供一种用于对图像进行编码和解码以提高压缩效率的方法和设备以及存储通过本发明的图像编码方法/设备产生的比特流的记录介质。An object of the present invention is to provide a method and device for encoding and decoding images to improve compression efficiency and a recording medium that stores a bit stream generated by the image encoding method/device of the present invention.
本发明的另一目的在于提供一种用于使用帧内预测对图像进行编码和解码以提高压缩效率的方法和设备以及存储通过本发明的图像编码方法/设备产生的比特流的记录介质。Another object of the present invention is to provide a method and device for encoding and decoding images using intra prediction to improve compression efficiency and a recording medium that stores a bit stream generated by the image encoding method/device of the present invention.
本发明的另一目的在于提供一种用于通过使用残差信号预测执行帧内预测对图像进行编码和解码的方法和设备以及存储通过本发明的图像编码方法/设备产生的比特流的记录介质。Another object of the present invention is to provide a method and apparatus for encoding and decoding an image by performing intra prediction using residual signal prediction and a recording medium storing a bit stream generated by the image encoding method/apparatus of the present invention .
解决方案solution
根据本发明的一种用于针对当前块执行帧内预测的图像解码方法可包括:对第一信息进行解码,其中,第一信息指示用于对当前块的残差块进行预测的残差信号预测是否被执行;如果第一信息指示第一值,则执行所述残差信号预测。An image decoding method for performing intra prediction for a current block according to the present invention may include decoding first information, wherein the first information indicates a residual signal used for predicting a residual block of the current block. Whether prediction is performed; if the first information indicates the first value, the residual signal prediction is performed.
在本发明的图像解码方法中,可基于先前解码的重建块来执行所述残差信号预测。In the image decoding method of the present invention, the residual signal prediction may be performed based on a previously decoded reconstruction block.
本发明的图像解码方法还可包括:对帧内位移矢量(IDV)进行解码,其中,所述先前解码的重建块可由解码的IDV指定。The image decoding method of the present invention may further include decoding an intra-frame displacement vector (IDV), wherein the previously decoded reconstruction block may be specified by the decoded IDV.
本发明的图像解码方法还可包括:对用于所述残差信号预测的帧内预测模式进行解码;并基于解码的帧内预测模式产生所述重建块的预测块。The image decoding method of the present invention may further include: decoding an intra prediction mode used for prediction of the residual signal; and generating a prediction block of the reconstruction block based on the decoded intra prediction mode.
本发明的图像解码方法还可包括:基于所述重建块以及所述重建块的预测块产生所述重建块的残差块,其中,所述重建块的残差块可以是当前块的残差块的预测块。The image decoding method of the present invention may further include: generating a residual block of the reconstruction block based on the reconstruction block and a prediction block of the reconstruction block, wherein the residual block of the reconstruction block may be a residual block of the current block. Block prediction block.
本发明的图像解码方法还可包括:对当前块的二阶残差块进行解码;并基于当前块的残差块的预测块以及所述二阶残差块来产生当前块的残差块。The image decoding method of the present invention may further include: decoding a second-order residual block of the current block; and generating a residual block of the current block based on a prediction block of the residual block of the current block and the second-order residual block.
在本发明的图像解码方法中,如果关于IDV的信息未被包括在比特流中,则可通过使用预定搜索方法选择在预定搜索范围中包括的多个IDV之一来执行对IDV的解码。In the image decoding method of the present invention, if the information on the IDV is not included in the bit stream, decoding of the IDV may be performed by selecting one of a plurality of IDVs included in the predetermined search range using a predetermined search method.
在本发明的图像解码方法中,所述预定搜索方法可以是与在图像编码方法中使用的搜索方法相同的方法。In the image decoding method of the present invention, the predetermined search method may be the same search method used in the image encoding method.
根据本发明的一种包括用于针对当前块执行帧内预测的帧内预测器的图像解码设备可包括:帧内预测器,被配置用于:对第一信息进行解码,其中,第一信息指示用于对当前块的残差块进行预测的残差信号预测是否被执行;如果第一信息指示第一值,则执行所述残差信号预测。An image decoding device including an intra predictor for performing intra prediction for a current block according to the present invention may include: an intra predictor configured to: decode first information, wherein the first information Indicates whether residual signal prediction for predicting the residual block of the current block is performed; if the first information indicates the first value, the residual signal prediction is performed.
根据本发明的一种用于针对当前块执行帧内预测的图像编码方法可包括:执行用于对当前块的残差块进行预测的残差信号预测;并对指示所述残差信号预测是否被执行的第一信息进行编码。An image encoding method for performing intra prediction for a current block according to the present invention may include: performing residual signal prediction for predicting a residual block of the current block; and indicating whether the residual signal prediction The first message that is executed is encoded.
在本发明的图像编码方法中,可基于先前解码的重建块执行所述残差信号预测。In the image encoding method of the present invention, the residual signal prediction may be performed based on a previously decoded reconstruction block.
本发明的图像编码方法还可包括:对指定所述先前解码的重建块的帧内位移矢量(IDV)进行编码。The image encoding method of the present invention may further include encoding an intra-frame displacement vector (IDV) specifying the previously decoded reconstruction block.
本发明的图像编码方法还可包括:确定用于所述残差信号预测的帧内预测模式;基于确定的帧内预测模式来产生所述重建块的预测块;并对确定的帧内预测模式进行编码。The image encoding method of the present invention may further include: determining an intra prediction mode for the residual signal prediction; generating a prediction block of the reconstruction block based on the determined intra prediction mode; and applying the determined intra prediction mode to Encode.
在本发明的图像编码方法中,所述预定搜索方法可包括:将当前块的残差块的代价函数值与当前块的二阶残差块的代价函数值进行比较。In the image encoding method of the present invention, the predetermined search method may include: comparing a cost function value of a residual block of the current block with a cost function value of a second-order residual block of the current block.
根据本发明的一种包括用于针对当前块执行帧内预测的帧内预测器的图像编码设备可包括:帧内预测器,被配置为:执行用于对当前块的残差块进行预测的残差信号预测,并且对指示所述残差信号预测是否被执行的第一信息进行编码。An image encoding device including an intra predictor for performing intra prediction for a current block according to the present invention may include: an intra predictor configured to: perform prediction for a residual block of the current block. Residual signal prediction is performed, and first information indicating whether the residual signal prediction is performed is encoded.
根据本发明的一种存储由用于针对当前块执行帧内预测的图像编码方法产生的比特流的记录介质可存储由图像编码方法产生的比特流,其中,所述图像编码方法包括:执行用于对当前块的残差块进行预测的残差信号预测;并对指示所述残差信号预测是否被执行的第一信息进行编码。A recording medium that stores a bit stream generated by an image encoding method for performing intra prediction for a current block according to the present invention may store a bit stream generated by the image encoding method, wherein the image encoding method includes: executing residual signal prediction for predicting a residual block of the current block; and encoding first information indicating whether the residual signal prediction is performed.
有益效果beneficial effects
根据本发明,可提供一种提高压缩效率的图像编码/解码方法和设备以及一种存储通过本发明的图像编码方法/设备产生的比特流的记录介质。According to the present invention, it is possible to provide an image encoding/decoding method and device that improves compression efficiency and a recording medium that stores a bit stream generated by the image encoding method/device of the present invention.
并且,根据本发明,可提供一种提高压缩效率的使用帧内预测的图像编码/解码方法和设备以及一种存储通过本发明的图像编码方法/设备产生的比特流的记录介质。Furthermore, according to the present invention, it is possible to provide an image encoding/decoding method and device using intra prediction that improves compression efficiency and a recording medium that stores a bit stream generated by the image encoding method/device of the present invention.
并且,根据本发明,可提供一种使用残差信号预测执行帧内预测的图像编码/解码方法和设备以及一种存储通过本发明的图像编码方法/设备产生的比特流的记录介质。Also, according to the present invention, an image encoding/decoding method and apparatus that performs intra prediction using residual signal prediction and a recording medium that stores a bit stream generated by the image encoding method/apparatus of the present invention can be provided.
附图说明Description of the drawings
图1是示出根据本发明的实施例的编码设备的配置的框图。1 is a block diagram showing the configuration of an encoding device according to an embodiment of the present invention.
图2是示出根据本发明的实施例的解码设备的配置的框图。2 is a block diagram showing the configuration of a decoding device according to an embodiment of the present invention.
图3是示意性地示出当对图像进行编码和解码时的图像的分区结构的示图。FIG. 3 is a diagram schematically showing a partition structure of an image when encoding and decoding the image.
图4是示出可被包括在编码单元(CU)中的预测单元(PU)的形式的示图。4 is a diagram illustrating a form of a prediction unit (PU) that may be included in a coding unit (CU).
图5是示出可被包括在编码单元(CU)中的变换单元(TU)的形式的示图。FIG. 5 is a diagram illustrating a form of a transformation unit (TU) that may be included in a coding unit (CU).
图6是用于解释帧内预测的处理的实施例的示图。FIG. 6 is a diagram for explaining an embodiment of processing of intra prediction.
图7是用于解释帧间预测的处理的实施例的示图。FIG. 7 is a diagram for explaining an embodiment of a process of inter prediction.
图8是用于解释根据帧内预测模式的变换集的示图。FIG. 8 is a diagram for explaining a transform set according to an intra prediction mode.
图9是用于解释变换的处理的示图。FIG. 9 is a diagram for explaining the process of transformation.
图10是用于解释对量化的变换系数进行扫描的示图。FIG. 10 is a diagram for explaining scanning of quantized transform coefficients.
图11是用于解释块分区的示图。FIG. 11 is a diagram for explaining block partitioning.
图12是描绘根据本发明的实施例的用于对当前块执行帧内预测的方法的示图。FIG. 12 is a diagram depicting a method for performing intra prediction on a current block according to an embodiment of the present invention.
图13是描述用于从邻近块推导当前块的帧内预测模式的方法的示图。FIG. 13 is a diagram describing a method for deriving an intra prediction mode of a current block from neighboring blocks.
图14是描绘当前块、上层块、和邻近块的示例性示图。FIG. 14 is an exemplary diagram depicting a current block, an upper block, and a neighboring block.
图15是示出颜色分量的组成比为4:2:0的亮度块和色度块的示例性示图。FIG. 15 is an exemplary diagram showing a luminance block and a chrominance block in which the composition ratio of color components is 4:2:0.
图16是描绘推导当前块被划分成的一个或更多个子块中的每个子块的帧内预测模式的实施例的示图。16 is a diagram depicting an embodiment of deriving an intra prediction mode for each of one or more sub-blocks into which a current block is divided.
图17是描绘将当前块划分为子块的实施例的示图。Figure 17 is a diagram depicting an embodiment of dividing a current block into sub-blocks.
图18是描绘将当前块划分为子块的另一实施例的示图。Figure 18 is a diagram depicting another embodiment of dividing a current block into sub-blocks.
图19是描绘将当前块划分为子块的另一实施例的示图。Figure 19 is a diagram depicting another embodiment of dividing a current block into sub-blocks.
图20是描绘将当前块划分为子块的另一实施例的示图。Figure 20 is a diagram depicting another embodiment of dividing a current block into sub-blocks.
图21是描绘使用种子点帧内预测模式推导当前块的帧内预测模式的实施例的示图。21 is a diagram depicting an embodiment of deriving an intra prediction mode for a current block using a seed point intra prediction mode.
图22是描绘制作包括两个SPIPM的SPIPM列表的实施例的示图。Figure 22 is a diagram depicting an embodiment of making a SPIPM list including two SPIPMs.
图23是示出制作包括三个SPIPM的SPIPM列表的实施例的示例性示图。FIG. 23 is an exemplary diagram illustrating an embodiment of making a SPIPM list including three SPIPMs.
图24是示出制作包括四个SPIPM的SPIPM列表的实施例的示例性示图。FIG. 24 is an exemplary diagram illustrating an embodiment of making a SPIPM list including four SPIPMs.
图25是示出在当前块的大小是16×16的情况下的子块大小的示例性示图。FIG. 25 is an exemplary diagram showing the sub-block size in the case where the size of the current block is 16×16.
图26是描绘使用确定的IPDF分配帧内预测模式的实施例的示图。Figure 26 is a diagram depicting an embodiment of allocating intra prediction modes using determined IPDFs.
图27是示出与当前块邻近的重建块的示例性示图。FIG. 27 is an exemplary diagram showing reconstructed blocks adjacent to the current block.
图28是描绘使用邻近重建块推导帧内预测模式的实施例的示图。Figure 28 is a diagram depicting an embodiment of deriving intra prediction modes using neighboring reconstructed blocks.
图29是描绘基于子块推导帧内预测模式的实施例的示图。Figure 29 is a diagram depicting an embodiment of deriving intra prediction modes based on sub-blocks.
图30是描绘基于子块推导帧内预测模式的另一实施例的示图。Figure 30 is a diagram depicting another embodiment of deriving intra prediction modes based on sub-blocks.
图31是示出包括帧内预测模式信息的语法结构的示例性示图。FIG. 31 is an exemplary diagram showing a syntax structure including intra prediction mode information.
图32是描绘可用于对当前块进行帧内预测的邻近重建样点线的示例性示图。32 is an exemplary diagram depicting adjacent reconstruction sample lines that may be used for intra prediction of the current block.
图33是描绘针对当前块中包括的子块构建参考样点的实施例的示图。33 is a diagram depicting an embodiment of constructing reference samples for sub-blocks included in the current block.
图34是描绘用于使用可用重建样点替换不可用重建样点的方法的示图。Figure 34 is a diagram depicting a method for replacing unavailable reconstruction samples with available reconstruction samples.
图35是示出针对块大小的用于确定是否应用滤波的示例性阈值的示图。35 is a diagram illustrating exemplary thresholds for block size for determining whether to apply filtering.
图36是示出是否根据块大小和/或帧内预测模式执行滤波的示例性示图。FIG. 36 is an exemplary diagram showing whether filtering is performed according to block size and/or intra prediction mode.
图37是示出根据当前块的形状的帧内预测的示例性示图。FIG. 37 is an exemplary diagram illustrating intra prediction according to the shape of the current block.
图38是描绘针对DC-模式帧内预测的滤波的示图。Figure 38 is a diagram depicting filtering for DC-mode intra prediction.
图39是描绘平面(Planar)模式帧内预测的示图。FIG. 39 is a diagram depicting Planar mode intra prediction.
图40是描绘从Pref产生1D参考样点阵列p1,ref的实施例的示图。Figure 40 is a diagram depicting an embodiment of generating a ID reference sample array p1,ref fromPref .
图41是描绘根据预测块中的样点的位置使用不同角度处的参考样点的实施例的示图。Figure 41 is a diagram depicting an embodiment of using reference samples at different angles depending on the location of the sample in a prediction block.
图42是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从右上方的边到左下方的边的方向执行预测的实施例的示图。FIG. 42 is a diagram illustrating the steps from the upper right side to the lower left by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图43是示出作为应用图42的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 43 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 42 .
图44是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从左上方的边到右下方的边的方向(类型-1)执行预测的实施例的示图。44 is a diagram illustrating the steps from the upper left side to the lower right side by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment where prediction is performed for edge direction (Type-1).
图45是示出作为应用图44的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 45 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 44 .
图46是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从左下方的边到右上方的边的方向执行预测的实施例的示图。46 is a diagram illustrating the steps from the lower left side to the upper right side by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图47是示出作为应用图46的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 47 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 46 .
图48是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从左上方的边到右下方的边的方向(类型-2)执行预测的实施例的示图。FIG. 48 is a diagram illustrating the steps from the upper left side to the lower right side by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment where prediction is performed for edge direction (Type-2).
图49是示出作为应用图48的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 49 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 48 .
图50是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从上方的边到左下方的边的方向执行预测的实施例的示图。FIG. 50 is a diagram illustrating the steps from the upper side to the lower left side by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment of performing prediction in the direction of .
图51是示出作为应用图50的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 51 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 50 .
图52是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从上方的边到右下方的边的方向执行预测的实施例的示图。FIG. 52 is a diagram illustrating the steps from the upper side to the lower right side by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment of performing prediction in the direction of .
图53是示出作为应用图52的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 53 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 52 .
图54是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从左侧的边到右上方的边的方向执行预测的实施例的示图。54 is a diagram illustrating the steps from the left side to the upper right by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图55是示出作为应用图54的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 55 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 54 .
图56是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从左侧的边到右下方的边的方向执行预测的实施例的示图。FIG. 56 is a diagram illustrating the steps from the left side to the lower right by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图57是示出作为应用图56的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 57 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 56 .
图58是用于解释在目标块中以样点为单位使用不同方向模式的另一实施例的示图。FIG. 58 is a diagram for explaining another embodiment of using different direction patterns on a sample unit basis in a target block.
图59是描绘对残差信号进行预测的实施例的示图。Figure 59 is a diagram depicting an embodiment of predicting a residual signal.
图60是描绘使用二阶残差信号块对残差信号进行预测的示图。Figure 60 is a diagram depicting prediction of a residual signal using a second-order residual signal block.
图61是描绘残差信号预测的实施例的示图。Figure 61 is a diagram depicting an embodiment of residual signal prediction.
图62a和图62b是描绘在编码器中执行残差信号预测的实施例的示图。Figures 62a and 62b are diagrams depicting embodiments of performing residual signal prediction in an encoder.
图63是描绘在解码器中执行残差信号预测的实施例的示图。Figure 63 is a diagram depicting an embodiment of performing residual signal prediction in a decoder.
具体实施方式Detailed ways
可对本发明做出多种修改,并且存在本发明的多种实施例,其中,现在将参照附图提供所述实施例的示例并且将详细描述所述实施例的示例。然而,本发明不限于此,尽管示例性实施例可被解释为包括本发明的技术构思和技术范围内的所有修改、等同形式或替换形式。相似的参考标号指在各方面相同或相似的功能。在附图中,为了清楚起见,元件的形状和大小可被夸大。在本发明的以下详细描述中,对通过图示的方式示出可对本发明进行实施的具体实施例的附图进行参照。这些实施例被足够详细地描述以使本领域技术人员能够实施本公开。应该理解,本公开的各种实施例尽管不同,但不必是相互排他的。例如,在不脱离本公开的精神和范围的情况下,这里描述的与一个实施例关联的特定特征、结构和特性可在其它实施例中被实施。此外,应该理解,在不脱离本公开的精神和范围的情况下,每个公开的实施例内的各个元件的位置或布置可被修改。因此,以下详细描述并不用以限制的含义,本公开的范围经由所附权利要求(在合适的解释的情况下,还连同权利要求所要求保护的等同物的全部范围)来限定。Various modifications are possible to the invention and there are various embodiments of the invention, examples of which will now be provided with reference to the accompanying drawings and which will be described in detail. However, the present invention is not limited thereto, although the exemplary embodiments may be interpreted to include all modifications, equivalents, or substitutions within the technical concept and technical scope of the present invention. Similar reference numbers refer to identical or similar functions in all respects. In the drawings, the shapes and sizes of elements may be exaggerated for clarity. In the following detailed description of the invention, reference is made to the accompanying drawings, which illustrate by way of illustration specific embodiments in which the invention may be practiced. These embodiments are described in sufficient detail to enable those skilled in the art to practice the disclosure. It should be understood that the various embodiments of the present disclosure, while different, are not necessarily mutually exclusive. For example, the specific features, structures, and characteristics described herein in connection with one embodiment may be implemented in other embodiments without departing from the spirit and scope of the disclosure. Furthermore, it is to be understood that the position or arrangement of various elements within each disclosed embodiment may be modified without departing from the spirit and scope of the disclosure. The following detailed description is, therefore, not to be taken in a limiting sense, with the scope of the disclosure being defined by the appended claims (along with the full scope of equivalents to which such claims are entitled, when properly interpreted).
在说明书中使用的术语“第一”、“第二”等可被用于描述各种组件,但这些组件并不被解释为限制于所述术语。所述术语仅被用于将一个组件与另一组件区分开。例如,在不脱离本发明的范围的情况下,“第一”组件可被称为“第二”组件,并且“第二”组件也可被类似地称为“第一”组件。术语“和/或”包括多个项的组合或者是多个项中的任意一项。The terms "first", "second", etc. used in the specification may be used to describe various components, but these components are not to be construed as being limited to the terms. The terms are only used to distinguish one component from another component. For example, a "first" component could be termed a "second" component, and the "second" component could similarly be termed a "first" component, without departing from the scope of the invention. The term "and/or" includes a combination of a plurality of items or any one of a plurality of items.
将理解的是,在本说明书中,当元件被简单称为“连接到”或“结合到”另一元件而不是“直接连接到”或“直接结合到”另一元件时,它可以“直接连接到”或“直接结合到”另一元件,或者是在其间插入其它元件的情况下连接到或结合到另一元件。相反,应该理解,当元件被称为“直接结合”或“直接连接”到另一元件时,不存在中间元件。It will be understood that, in this specification, when an element is referred to as being simply "connected to" or "coupled to" another element rather than as "directly connected to" or "directly coupled to" the other element, it may be "directly coupled to" or "directly coupled to" the other element. "Connected to" or "coupled directly to" another element, or connected or coupled to another element with other elements intervening therebetween. In contrast, it will be understood that when an element is referred to as being "directly coupled" or "directly connected" to another element, there are no intervening elements present.
此外,在本发明的实施例中示出的组成部件被独立示出,以便呈现彼此不同的特性功能。因此,这并不意味着每个组成部件以单独的硬件或软件的组成单元被组成。换句话说,为了方便,每个组成部件包括枚举的组成部件中的每一个。因此,每个组成部件中的至少两个组成部件可被组合形成一个组成部件,或者一个组成部件可被划分为多个组成部件以执行每个功能。在没有脱离本发明的本质的情况下,每个组成部件被组合的实施例以及一个组成部件被划分的实施例也被包括在本发明的范围中。Furthermore, the constituent parts shown in the embodiments of the present invention are shown independently so as to present different characteristic functions from each other. Therefore, it does not mean that each component is constituted as a separate component unit of hardware or software. In other words, for convenience, each component includes each of the enumerated components. Therefore, at least two of each component may be combined to form one component, or one component may be divided into a plurality of components to perform each function. Embodiments in which each component is combined and embodiments in which one component is divided are also included in the scope of the present invention without departing from the essence of the invention.
在本说明书中使用的术语仅用于描述具体实施例,而不旨在限制本发明。以单数使用的表达包括复数表达,除非它在上下文中具有明显不同的含义。在本说明书中,将理解,诸如“包括...的”、“具有...的”等的术语旨在指明说明书中所公开的特征、数量、步骤、行为、元件、部件、或其组合的存在,而并不旨在排除一个或更多个其它特征、数量、步骤、行为、元件、部件、或其组合可能存在或者可能被添加的可能性。换句话说,当特定元件被称为“被包括”时,除相应元件以外的元件并不被排除,而是,另外的元件可被包括在本发明的实施例中或者是本发明的范围中。The terminology used in this specification is used only to describe specific embodiments and is not intended to limit the invention. An expression used in the singular includes the plural unless it has an obviously different meaning in the context. In this specification, it will be understood that terms such as "comprising", "having", etc. are intended to indicate the features, quantities, steps, acts, elements, components, or combinations thereof disclosed in the specification The presence of , is not intended to exclude the possibility that one or more other features, quantities, steps, acts, elements, parts, or combinations thereof may be present or may be added. In other words, when a particular element is referred to as being "comprising," elements other than the corresponding element are not excluded, but rather, additional elements may be included in embodiments of the invention or within the scope of the invention .
此外,一些组成元件可能不是执行本发明的必要功能的不可缺的组成元件,而是仅提升其性能的可选组成元件。可通过仅包括用于实施本发明的实质的不可缺的组成部件而排除在提升性能时使用的组成部件来实施本发明。仅包括所述不可缺的组成部件而排除在仅提升性能时使用的可选组成部件的结构也被包括在本发明的范围中。Furthermore, some constituent elements may not be indispensable for performing the necessary functions of the present invention, but may be optional constituent elements that merely enhance its performance. The present invention can be implemented by including only components indispensable for implementing the essence of the present invention and excluding components used in improving performance. A structure including only the indispensable components and excluding optional components used only to improve performance is also included in the scope of the present invention.
在下文中,将参照附图详细描述本发明的实施例。在描述本发明的示例性实施例时,将不详细描述公知功能或结构,这是因为它们会不必要地模糊对本发明的理解。附图中的相同的组成元件通过相同的参考标号来表示,并且对相同元件的重复描述将被省略。Hereinafter, embodiments of the present invention will be described in detail with reference to the accompanying drawings. In describing exemplary embodiments of the invention, well-known functions or constructions will not be described in detail since they would unnecessarily obscure the understanding of the invention. The same constituent elements in the drawings are denoted by the same reference numerals, and repeated description of the same elements will be omitted.
此外,在下文中,图像可意为构成视频的画面,或者可意为视频本身。例如,“对图像进行编码或解码或者进行两者”可意为“对视频进行编码或解码或者进行两者”,并且可意为“对视频的多个图像之中的一个图像进行编码或解码或者进行两者”。这里,画面和图像可具有相同的含义。Furthermore, in the following, an image may mean a picture constituting a video, or may mean the video itself. For example, "encode or decode an image or both" may mean "encode or decode a video or both" and may mean "encode or decode one of a plurality of images of a video Or do both”. Here, picture and image may have the same meaning.
术语描述Terminology description
编码器:可意为执行编码的设备。Encoder: Can mean a device that performs encoding.
解码器:可意为执行解码的设备。Decoder: Can mean a device that performs decoding.
解析:可意为通过执行熵解码来确定语法元素的值,或者可意为熵解码本身。Parsing: May mean determining the value of a syntax element by performing entropy decoding, or may mean entropy decoding itself.
块:可意为M×N矩阵的样点。这里,M和N是正整数,并且块可意为二维形式的样点矩阵。Block: can mean the sample points of the M×N matrix. Here, M and N are positive integers, and the block may mean a matrix of samples in two-dimensional form.
样点:是块的基本单元,并且可指示依据比特深度(Bd)而范围为0至2Bd–1的值。样点在本发明中可意为像素。Sample: is the basic unit of a block and may indicate a value ranging from 0 to 2Bd–1 in terms of bit depth (Bd). Sample points in the present invention may mean pixels.
单元:可意为对图像进行编码和解码的单元。在对图像进行编码和解码时,单元可以是通过对一个图像进行分区而产生的区域。此外,单元可意为在编码或解码期间当一个图像被分区为多个子划分单元时的子划分单元。在对图像进行编码和解码时,可执行针对每个单元的预定处理。一个单元可被分区为大小比该单元的大小更小的子单元。依据功能,单元可意为块、宏块、编码树单元、编码树块、编码单元、编码块、预测单元、预测块、变换单元、变换块等。此外,为了将单元与块区分开,单元可包括亮度分量块、亮度分量块的色度分量块、以及每个颜色分量块的语法元素。单元可具有各种大小和形状,具体而言,单元的形状可以是二维几何图形,诸如矩形、正方形、梯形、三角形、五边形等。此外,单元信息可包括单元类型(指示编码单元、预测单元、变换单元等)、单元大小、单元深度、对单元进行编码和解码的顺序等中的至少一个。Unit: can mean the unit that encodes and decodes images. When encoding and decoding images, units may be regions produced by partitioning an image. Furthermore, a unit may mean a sub-division unit when one image is partitioned into a plurality of sub-division units during encoding or decoding. When encoding and decoding images, predetermined processing for each unit may be performed. A cell can be partitioned into subcells that are smaller in size than the size of the cell. Depending on the function, a unit may mean a block, a macroblock, a coding tree unit, a coding tree block, a coding unit, a coding block, a prediction unit, a prediction block, a transform unit, a transform block, etc. Furthermore, to distinguish a unit from a block, a unit may include a luma component block, a chroma component block of the luma component block, and a syntax element for each color component block. The unit may have various sizes and shapes. Specifically, the shape of the unit may be a two-dimensional geometric figure, such as a rectangle, a square, a trapezoid, a triangle, a pentagon, etc. Furthermore, the unit information may include at least one of a unit type (indicating a coding unit, a prediction unit, a transformation unit, etc.), a unit size, a unit depth, an order of encoding and decoding the unit, and the like.
重建邻近单元:可意为在空间上/时间上被在先编码或解码的重建单元,并且重建单元与编码/解码目标单元相邻。这里,重建邻近单元可意为重建邻近块。Reconstruction neighboring unit: may mean a reconstruction unit that has been previously encoded or decoded in space/time, and the reconstruction unit is adjacent to the encoding/decoding target unit. Here, reconstructing neighboring units may mean reconstructing neighboring blocks.
邻近块:可意为与编码/解码目标块相邻的块。与编码/解码目标块相邻的块可意为具有与编码/解码目标块接触的边界的块。邻近块可意为位于编码/解码目标块的相邻顶点的块。邻近块可意为重建邻近块。Neighboring blocks: may mean blocks adjacent to the encoding/decoding target block. A block adjacent to the encoding/decoding target block may mean a block having a boundary that contacts the encoding/decoding target block. Neighboring blocks may mean blocks located at adjacent vertices of the encoding/decoding target block. Neighboring blocks may mean reconstructed neighboring blocks.
单元深度:可意为单元的被分区程度。在树结构中,根节点可以是最高节点,叶节点可以是最低节点。Unit depth: can mean the degree to which the unit is partitioned. In a tree structure, the root node can be the highest node and the leaf node can be the lowest node.
符号:可意为编码/解码目标单元的语法元素、编码参数、变换系数的值等。Symbols: can mean syntax elements of encoding/decoding target units, encoding parameters, values of transform coefficients, etc.
参数集:可意为比特流的结构中的头信息。参数集可包括视频参数集、序列参数集、画面参数集或自适应参数集中的至少一个参数集。此外,参数集可意为条带头信息和并行块(tile)头信息等。Parameter set: It can mean the header information in the structure of the bit stream. The parameter set may include at least one parameter set from a video parameter set, a sequence parameter set, a picture parameter set, or an adaptive parameter set. In addition, the parameter set may mean slice header information, tile header information, and the like.
比特流:可意为包括编码图像信息的比特串。Bitstream: Can mean a string of bits that includes encoded image information.
预测单元:可意为当执行帧间预测或帧内预测以及针对预测的补偿时的基本单元。一个预测单元可被分区为多个分区。在这种情况下,多个分区中的每个分区可以是在执行预测和补偿时的基本单元,并且从预测单元分区获得的每个分区可以是预测单元。此外,一个预测单元可以被分区为多个小预测单元。预测单元可具有各种大小和形状,并且具体来说,预测单元的形状可以是二维几何图形,诸如矩形、正方形、梯形、三角形和五边形等。Prediction unit: May mean a basic unit when performing inter prediction or intra prediction and compensation for prediction. A prediction unit can be partitioned into multiple partitions. In this case, each of the plurality of partitions may be a basic unit when prediction and compensation are performed, and each partition obtained from the prediction unit partition may be a prediction unit. In addition, a prediction unit can be partitioned into multiple small prediction units. The prediction unit may have various sizes and shapes, and specifically, the shape of the prediction unit may be a two-dimensional geometric figure such as a rectangle, a square, a trapezoid, a triangle, a pentagon, and the like.
预测单元分区:可意为分区出的预测单元的形状。Prediction unit partition: It can mean the shape of the partitioned prediction unit.
参考画面列表:可意为包括至少一个参考画面的列表,其中,所述至少一个参考画面被用于帧间预测或运动补偿。参考画面列表的类型可以是List Combined(LC)、List 0(L0)、List 1(L1)、List 2(L2)、List 3(L3)等。至少一个参考画面列表可被用于帧间预测。Reference picture list: may mean a list including at least one reference picture, wherein the at least one reference picture is used for inter prediction or motion compensation. The type of reference picture list may be List Combined (LC), List 0 (L0), List 1 (L1), List 2 (L2), List 3 (L3), etc. At least one reference picture list may be used for inter prediction.
帧间预测指示符:可意为以下之一:帧间预测情况下的编码/解码目标块的帧间预测方向(单向预测、双向预测等)、用于通过所述编码/解码目标块产生预测块的参考画面的数量、以及用于通过所述编码/解码目标块执行帧间预测或运动补偿的参考块的数量。Inter prediction indicator: can mean one of the following: inter prediction direction (unidirectional prediction, bidirectional prediction, etc.) of the encoding/decoding target block in the case of inter prediction, for generation by said encoding/decoding target block The number of reference pictures of the prediction block, and the number of reference blocks used to perform inter prediction or motion compensation through the encoding/decoding target block.
参考画面索引:可意为参考画面列表中的特定参考画面的索引。Reference picture index: may mean the index of a specific reference picture in the reference picture list.
参考画面:可意为特定单元为了帧间预测或运动补偿所参考的画面。参考图像可被称为参考画面。Reference picture: may mean a picture that a specific unit refers to for inter-frame prediction or motion compensation. The reference image may be called a reference picture.
运动矢量:是用于帧间预测或运动补偿的二维矢量,并且可意为编码/解码目标画面与参考画面之间的偏移。例如,(mvX,mvY)可指示运动矢量,mvX可指示水平分量,mvY可指示垂直分量。Motion vector: is a two-dimensional vector used for inter-frame prediction or motion compensation, and can mean the offset between the encoding/decoding target picture and the reference picture. For example, (mvX, mvY) may indicate a motion vector, mvX may indicate a horizontal component, and mvY may indicate a vertical component.
运动矢量候选:可意为当预测运动矢量时成为预测候选的单元,或者可意为该单元的运动矢量。Motion vector candidate: may mean a unit that becomes a prediction candidate when a motion vector is predicted, or may mean a motion vector of the unit.
运动矢量候选列表:可意为通过使用运动矢量候选而配置的列表。Motion vector candidate list: May mean a list configured by using motion vector candidates.
运动矢量候选索引:可意为指示运动矢量候选列表中的运动矢量候选的指示符。运动矢量候选索引可被称为运动矢量预测因子的索引。Motion vector candidate index: may mean an indicator indicating a motion vector candidate in the motion vector candidate list. The motion vector candidate index may be referred to as the index of the motion vector predictor.
运动信息:可意为运动矢量、参考画面索引和帧间预测指示符,以及包括参考画面列表信息、参考画面、运动矢量候选、运动矢量候选索引等中的至少一个的信息。Motion information: may mean a motion vector, a reference picture index, and an inter prediction indicator, as well as information including at least one of reference picture list information, a reference picture, a motion vector candidate, a motion vector candidate index, and the like.
合并候选列表:可意为通过使用合并候选而配置的列表。Merge candidate list: May mean a list configured by using merge candidates.
合并候选:可包括空间合并候选、时间合并候选、组合合并候选、组合双向预测合并候选、零合并候选等。合并候选可包括诸如预测类型信息的运动信息、用于每个列表的参考画面索引、运动矢量等。Merge candidates: can include spatial merging candidates, temporal merging candidates, combined merging candidates, combined bidirectional prediction merging candidates, zero merging candidates, etc. The merge candidates may include motion information such as prediction type information, reference picture index for each list, motion vector, etc.
合并索引:可意为指示合并候选列表中的合并候选的信息。此外,合并索引可指示与当前块在空间/时间上相邻的重建块之中的推导合并候选的块。此外,合并索引可指示合并候选的多条运动信息中的至少一条。Merge index: may mean information indicating merge candidates in the merge candidate list. Furthermore, the merge index may indicate a block from which a merge candidate is derived among reconstructed blocks spatially/temporally adjacent to the current block. Furthermore, the merging index may indicate at least one piece of the plurality of pieces of motion information of the merging candidate.
变换单元:可意为当对残差信号执行与变换、逆变换、量化、反量化以及变换系数编码/解码类似的编码/解码时的基本单元。一个变换单元可被分区为多个小变换单元。变换单元可具有各种大小和形状。具体而言,变换单元的形状可以是二维几何图形,诸如矩形、正方形、梯形、三角形、五边形等。Transform unit: may mean a basic unit when encoding/decoding similar to transform, inverse transform, quantization, inverse quantization, and transform coefficient encoding/decoding is performed on the residual signal. A transformation unit can be partitioned into multiple small transformation units. Transform units can be of various sizes and shapes. Specifically, the shape of the transformation unit may be a two-dimensional geometric figure, such as a rectangle, a square, a trapezoid, a triangle, a pentagon, etc.
缩放:可意为将一因子与变换系数等级相乘的处理,其结果是,变换系数可被产生。缩放还可被称为反量化。Scaling: may mean the process of multiplying a factor by a transform coefficient level, as a result of which transform coefficients may be generated. Scaling may also be called inverse quantization.
量化参数:可意为在量化和反量化期间在对变换系数等级进行缩放时使用的值。这里,量化参数可以是被映射到量化的步长大小的值。Quantization parameter: may mean the value used in scaling the transform coefficient levels during quantization and inverse quantization. Here, the quantization parameter may be a value mapped to the step size of quantization.
变量增量(Delta)量化参数:可意为编码/解码目标单元的量化参数与预测出的量化参数之间的差值。Variable delta quantization parameter: can mean the difference between the quantization parameter of the encoding/decoding target unit and the predicted quantization parameter.
扫描:可意为对块或矩阵内的系数顺序进行排序的方法。例如,将二维矩阵排序为一维矩阵的操作可被称为扫描,并且将一维矩阵排序为二维矩阵的操作可被称为扫描或逆扫描。Scan: Can mean a method of sorting the order of coefficients within a block or matrix. For example, an operation of sorting a two-dimensional matrix into a one-dimensional matrix may be called a scan, and an operation of sorting a one-dimensional matrix into a two-dimensional matrix may be called a scan or inverse scan.
变换系数:可意为在执行变换之后产生的系数值。在本发明中,量化的变换系数等级(即被应用了量化的变换系数)可被称为变换系数。Transform coefficients: May mean the coefficient values produced after performing a transformation. In the present invention, quantized transform coefficient levels (ie, transform coefficients to which quantization is applied) may be referred to as transform coefficients.
非零变换系数:可意为值不为0的变换系数,或者可意为值不为0的变换系数等级。Non-zero transform coefficient: may mean a transform coefficient with a value other than 0, or may mean a transform coefficient level with a value other than 0.
量化矩阵:可意为在量化和反量化中使用以便提高图像的主体质量(subjectquality)或对象质量(object quality)的矩阵。量化矩阵可被称为缩放列表。Quantization matrix: It can mean a matrix used in quantization and inverse quantization to improve the subject quality or object quality of the image. The quantization matrix can be called a scaling list.
量化矩阵系数:可意为量化矩阵的每个元素。量化矩阵系数可被称为矩阵系数。Quantization matrix coefficient: can mean each element of the quantization matrix. The quantized matrix coefficients may be called matrix coefficients.
默认矩阵:可意为在编码器和解码器中被预先定义的预定量化矩阵。Default matrix: May mean a predetermined quantization matrix that is predefined in the encoder and decoder.
非默认矩阵:可意为在编码器和解码器中未被预先定义的情况下由用户发送/接收的量化矩阵。Non-default matrix: Can mean the quantization matrix sent/received by the user without being predefined in the encoder and decoder.
编码树单元:可由一个亮度分量(Y)编码树单元以及相关的两个色度分量(Cb,Cr)编码树单元构成。每个编码树单元可通过使用至少一种分区方法(诸如四叉树、二叉树等)被分区,以构成诸如编码单元、预测单元、变换单元等的子单元。编码树单元可被用作用于指示像素块(即在图像的解码/编码处理中的处理单元,如输入图像的分区)的术语。Coding tree unit: It can be composed of a luminance component (Y) coding tree unit and two related chroma component (Cb, Cr) coding tree units. Each coding tree unit may be partitioned using at least one partitioning method (such as a quadtree, a binary tree, etc.) to constitute sub-units such as a coding unit, a prediction unit, a transformation unit, etc. Coding tree unit may be used as a term for indicating a pixel block (ie, a processing unit in the decoding/encoding process of an image, such as a partition of an input image).
编码树块:可用作用于指示Y编码树单元、Cb编码树单元和Cr编码树单元之一的术语。Coding tree block: may be used as a term to indicate one of Y coding tree unit, Cb coding tree unit and Cr coding tree unit.
图1是示出根据本发明的实施例的编码设备的配置的框图。1 is a block diagram showing the configuration of an encoding device according to an embodiment of the present invention.
编码设备100可以是视频编码设备或图像编码设备。视频可包括一个或更多个图像。编码设备100可按照时间顺序对视频的一个或更多个图像进行编码。The encoding device 100 may be a video encoding device or an image encoding device. A video can include one or more images. The encoding device 100 may encode one or more images of the video in time sequence.
参照图1,编码设备100可包括运动预测单元111、运动补偿单元112、帧内预测单元120、切换器115、减法器125、变换单元130、量化单元140、熵编码单元150、反量化单元160、逆变换单元170、加法器175、滤波器单元180以及参考画面缓冲器190。Referring to FIG. 1 , the encoding device 100 may include a motion prediction unit 111, a motion compensation unit 112, an intra prediction unit 120, a switch 115, a subtractor 125, a transform unit 130, a quantization unit 140, an entropy encoding unit 150, and an inverse quantization unit 160. , inverse transform unit 170, adder 175, filter unit 180 and reference picture buffer 190.
编码设备100可按照帧内模式或帧间模式或者是帧内模式和帧间模式两者来对输入画面进行编码。此外,编码设备100可通过对输入画面进行编码来产生比特流,并可输出产生的比特流。当帧内模式被用作预测模式时,切换器115可切换到帧内。当帧间模式被用作预测模式时,切换器115可切换到帧间。这里,帧内模式可被称为帧内预测模式,帧间模式可被称为帧间预测模式。编码设备100可产生输入画面的输入块的预测块。此外,在产生预测块之后,编码设备100可对输入块和预测块之间的残差进行编码。输入画面可被称为作为当前编码的目标的当前图像。输入块可被称为当前块或者可被称为作为当前编码的目标的编码目标块。The encoding device 100 may encode the input picture in an intra mode or an inter mode, or both an intra mode and an inter mode. Furthermore, the encoding device 100 may generate a bit stream by encoding the input picture, and may output the generated bit stream. When the intra mode is used as the prediction mode, the switch 115 may switch to intra. When the inter mode is used as the prediction mode, the switch 115 may switch to inter. Here, the intra mode may be called an intra prediction mode, and the inter mode may be called an inter prediction mode. The encoding device 100 may generate a prediction block of an input block of an input picture. Furthermore, after generating the prediction block, the encoding device 100 may encode the residual between the input block and the prediction block. The input picture may be referred to as the current image that is the target of current encoding. The input block may be called a current block or may be called an encoding target block that is a target of current encoding.
当预测模式是帧内模式时,帧内预测单元120可使用与当前块相邻的先前编码块的像素值作为参考像素。帧内预测单元120可通过使用参考像素来执行空间预测,并可通过使用空间预测来产生输入块的预测样点。这里,帧内预测可意为帧内帧预测。When the prediction mode is the intra mode, the intra prediction unit 120 may use pixel values of previously encoded blocks adjacent to the current block as reference pixels. Intra prediction unit 120 may perform spatial prediction by using reference pixels and may generate prediction samples of the input block by using spatial prediction. Here, intra prediction may mean intra frame prediction.
当预测模式是帧间模式时,运动预测单元111可在运动预测处理中从参考画面搜索与输入块最优匹配的区域,并可通过使用搜索到的区域推导运动矢量。参考画面可被存储在参考画面缓冲器190中。When the prediction mode is the inter mode, the motion prediction unit 111 may search for a region optimally matching the input block from the reference picture in the motion prediction process, and may derive a motion vector by using the searched region. Reference pictures may be stored in reference picture buffer 190.
运动补偿单元112可通过使用运动矢量执行运动补偿来产生预测块。这里,运动矢量可以是用于帧间预测的二维矢量。此外,运动矢量可指示当前画面和参考画面之间的偏移。这里,帧间预测可意为帧间帧预测。Motion compensation unit 112 may generate prediction blocks by performing motion compensation using motion vectors. Here, the motion vector may be a two-dimensional vector used for inter prediction. Additionally, the motion vector may indicate an offset between the current picture and the reference picture. Here, inter prediction may mean inter frame prediction.
当运动矢量的值不为整数时,运动预测单元111和运动补偿单元112可通过对参考画面中的部分区域应用插值滤波器来产生预测块。为了基于编码单元执行帧间预测或运动补偿,可在跳过模式、合并模式、AMVP模式和当前画面参考模式之中确定编码单元中的预测单元的运动预测和补偿方法使用哪种方法。可根据每种模式执行帧间预测或运动补偿。这里,当前画面参考模式可意为使用具有编码目标块的当前画面的预先重建的区域的预测模式。为了指明所述预先重建的区域,可定义针对当前画面参考模式的运动矢量。是否按照当前画面参考模式对编码目标块进行编码可通过使用编码目标块的参考画面索引而被编码。When the value of the motion vector is not an integer, the motion prediction unit 111 and the motion compensation unit 112 may generate a prediction block by applying an interpolation filter to a partial area in the reference picture. In order to perform inter prediction or motion compensation based on a coding unit, which method is used for motion prediction and compensation of a prediction unit in the coding unit may be determined among skip mode, merge mode, AMVP mode, and current picture reference mode. Inter prediction or motion compensation can be performed according to each mode. Here, the current picture reference mode may mean a prediction mode using a previously reconstructed area of the current picture with the encoding target block. In order to specify the pre-reconstructed area, a motion vector for the current picture reference mode may be defined. Whether the encoding target block is encoded according to the current picture reference mode may be encoded by using the reference picture index of the encoding target block.
减法器125可通过使用输入块和预测块之间的残差来产生残差块。残差块可被称为残差信号。Subtractor 125 may generate a residual block by using the residual between the input block and the prediction block. The residual block may be called a residual signal.
变换单元130可通过对残差块进行变换来产生变换系数,并可输出变换系数。这里,变换系数可以是通过对残差块进行变换而产生的系数值。在变换跳过模式中,变换单元130可跳过对残差块的变换。The transform unit 130 may generate transform coefficients by transforming the residual block, and may output the transform coefficients. Here, the transform coefficient may be a coefficient value generated by transforming the residual block. In transform skip mode, transform unit 130 may skip transforming the residual block.
可通过对变换系数应用量化来产生量化的变换系数等级。在下文中,在本发明的实施例中,量化的变换系数等级可被称为变换系数。Quantized transform coefficient levels may be generated by applying quantization to the transform coefficients. Hereinafter, in embodiments of the present invention, quantized transform coefficient levels may be referred to as transform coefficients.
量化单元140可通过依据量化参数对变换系数进行量化来产生量化的变换系数等级,并可输出量化的变换系数等级。这里,量化单元140可通过使用量化矩阵来对变换系数进行量化。Quantization unit 140 may generate quantized transform coefficient levels by quantizing the transform coefficients according to the quantization parameters, and may output the quantized transform coefficient levels. Here, the quantization unit 140 may quantize the transform coefficient by using a quantization matrix.
熵编码单元150可通过根据概率分布对由量化单元140计算出的值或对在编码处理中计算出的编码参数值等执行熵编码来产生比特流,并可输出产生的比特流。熵编码单元150可对用于对图像进行解码的信息执行熵编码,并对图像的像素的信息执行熵编码。例如,用于对图像进行解码的信息可包括语法元素等。The entropy encoding unit 150 may generate a bit stream by performing entropy encoding on the value calculated by the quantization unit 140 or on the encoding parameter value calculated in the encoding process or the like according to the probability distribution, and may output the generated bit stream. The entropy encoding unit 150 may perform entropy encoding on information used to decode an image, and perform entropy encoding on information of pixels of the image. For example, information used to decode an image may include syntax elements and the like.
当熵编码被应用时,通过对具有高出现概率的符号分配少量比特并对具有低出现概率的符号分配大量比特来表示符号,从而减少对目标符号进行编码的比特流的大小。因此,通过熵编码,图像编码的压缩性能可提高。对于熵编码,熵编码单元150可使用诸如指数哥伦布、上下文自适应变长编码(CAVLC)以及上下文自适应二进制算术编码(CABAC)的编码方法。例如,熵编码单元150可通过使用变长编码/码(VLC)表来执行熵编码。此外,熵编码单元150可推导目标符号的二值化方法以及目标符号/二进制位的概率模型,并且随后可通过使用推导出的二值化方法或推导出的概率模型来执行算术编码。When entropy coding is applied, symbols are represented by allocating a small number of bits to symbols with a high probability of occurrence and a large number of bits to symbols with a low probability of occurrence, thereby reducing the size of the bitstream encoding the target symbol. Therefore, through entropy coding, the compression performance of image coding can be improved. For entropy encoding, the entropy encoding unit 150 may use encoding methods such as Exponential Golomb, Context Adaptive Variable Length Coding (CAVLC), and Context Adaptive Binary Arithmetic Coding (CABAC). For example, the entropy encoding unit 150 may perform entropy encoding by using a variable length coding/coding (VLC) table. In addition, the entropy encoding unit 150 may derive a binarization method of the target symbol and a probability model of the target symbol/bin, and then may perform arithmetic coding by using the derived binarization method or the derived probability model.
为了对变换系数等级进行编码,熵编码单元150可通过使用变换系数扫描方法将二维块形式的系数改变为一维矢量形式。例如,通过用右上扫描来扫描块的系数,二维形式的系数可被改变为一维矢量形式。根据变换单元的大小以及帧内预测模式,可使用用于沿列方向扫描二维块形式的系数的垂直方向扫描以及用于沿行方向扫描二维块形式的系数的水平方向扫描,而不是使用右上扫描。也就是说,依据变换单元的大小以及帧内预测模式,可确定右上扫描、垂直方向扫描和水平方向扫描之中的哪种扫描方法将被使用。In order to encode the transform coefficient level, the entropy encoding unit 150 may change the coefficients in a two-dimensional block form into a one-dimensional vector form by using a transform coefficient scanning method. For example, by scanning the coefficients of a block with an upper right scan, the coefficients in two-dimensional form can be changed into a one-dimensional vector form. Depending on the size of the transform unit and the intra prediction mode, a vertical scan for scanning the coefficients in the column direction in the form of a two-dimensional block and a horizontal scan for scanning the coefficients in the row direction in the form of a two-dimensional block can be used instead of using Scan to the upper right. That is, depending on the size of the transformation unit and the intra prediction mode, it can be determined which scanning method among upper right scanning, vertical direction scanning, and horizontal direction scanning will be used.
编码参数可包括由编码器编码并被发送到解码器的诸如语法元素的信息,并可包括可在编码或解码处理中推导的信息。编码参数可意为对图像进行编码或解码所必要的信息。例如,编码参数可包括以下项中的至少一个值或组合形式:块大小、块深度、块分区信息、单元大小、单元深度、单元分区信息、四叉树形式的分区标志、二叉树形式的分区标志、二叉树形式的分区方向、帧内预测模式、帧内预测方向、参考样点滤波方法、预测块边界滤波方法、滤波器抽头、滤波器系数、帧间预测模式、运动信息、运动矢量、参考画面索引、帧间预测方向、帧间预测指示符、参考画面列表、运动矢量预测因子、运动矢量候选列表、关于运动合并模式是否被使用的信息、运动合并候选、运动合并候选列表、关于跳过模式是否被使用的信息、插值滤波器类型、运动矢量大小、运动矢量表示的精确度、变换类型、变换大小、关于附加(二次)变换是否被使用的信息、关于残差信号是否存在的信息、编码块样式、编码块标志、量化参数、量化矩阵、环路内的滤波器信息、关于滤波器是否在环路内被应用的信息、环路内的滤波器系数、二值化/反二值化方法、上下文模型、上下文二进制位、旁通二进制位、变换系数、变换系数等级、变换系数等级扫描方法、图像显示/输出顺序、条带识别信息、条带类型、条带分区信息、并行块识别信息、并行块类型、并行块分区信息、画面类型、比特深度、以及亮度信号或色度信号的信息。Encoding parameters may include information such as syntax elements that are encoded by the encoder and sent to the decoder, and may include information that may be derived in the encoding or decoding process. Encoding parameters may mean information necessary to encode or decode an image. For example, the encoding parameters may include at least one value or combination of the following: block size, block depth, block partition information, unit size, unit depth, unit partition information, partition flag in the form of a quadtree, partition flag in the form of a binary tree , partition direction in the form of binary tree, intra prediction mode, intra prediction direction, reference sample filtering method, prediction block boundary filtering method, filter tap, filter coefficient, inter prediction mode, motion information, motion vector, reference picture Index, inter prediction direction, inter prediction indicator, reference picture list, motion vector predictor, motion vector candidate list, information on whether motion merge mode is used, motion merge candidate, motion merge candidate list, about skip mode Information about whether it is used, interpolation filter type, motion vector size, accuracy of motion vector representation, transform type, transform size, information about whether additional (secondary) transform is used, information about whether residual signal is present, Coding block pattern, coding block flag, quantization parameters, quantization matrix, filter information within the loop, information on whether the filter is applied within the loop, filter coefficients within the loop, binarization/inverse binary ization method, context model, context bin, bypass bin, transform coefficient, transform coefficient level, transform coefficient level scanning method, image display/output sequence, stripe identification information, stripe type, stripe partition information, parallel block Identification information, tile type, tile partition information, picture type, bit depth, and luminance signal or chrominance signal information.
残差信号可意为原始信号与预测信号之间的差。可选择地,残差信号可以是通过对原始信号和预测信号之间的差进行变换而产生的信号。可选择地,残差信号可以是通过对原始信号和预测信号之间的差进行变换和量化而产生的信号。残差块可以是块单元的残差信号。The residual signal may mean the difference between the original signal and the predicted signal. Alternatively, the residual signal may be a signal generated by transforming the difference between the original signal and the predicted signal. Alternatively, the residual signal may be a signal generated by transforming and quantizing the difference between the original signal and the predicted signal. The residual block may be a block-unit residual signal.
当编码设备100通过使用帧间预测执行编码时。编码的当前画面可被用作针对将被随后处理的另一图像的参考画面。因此,编码设备100可对编码的当前画面进行解码,并可将解码的图像存储为参考画面。为了执行解码,可对编码的当前画面执行反量化和逆变换。When the encoding device 100 performs encoding by using inter prediction. The encoded current picture may be used as a reference picture for another picture to be subsequently processed. Therefore, the encoding device 100 can decode the encoded current picture and store the decoded image as the reference picture. To perform decoding, inverse quantization and inverse transformation may be performed on the encoded current picture.
量化的系数可通过反量化单元160被反量化,并可通过逆变换单元170被逆变换。可由加法器175将经过反量化和逆变换的系数与预测块相加,由此可产生重建块。The quantized coefficients may be inversely quantized by the inverse quantization unit 160 and may be inversely transformed by the inverse transform unit 170 . The inverse-quantized and inverse-transformed coefficients may be added to the prediction block by an adder 175, whereby a reconstruction block may be generated.
重建块可通过滤波器单元180。滤波器单元180可向重建块或重建画面应用去块滤波器、样点自适应偏移(SAO)以及自适应环路滤波器(ALF)中的至少一个。滤波器单元180可被称为环路滤波器。The reconstructed block may pass filter unit 180. The filter unit 180 may apply at least one of a deblocking filter, a sample adaptive offset (SAO), and an adaptive loop filter (ALF) to the reconstructed block or reconstructed picture. Filter unit 180 may be referred to as a loop filter.
去块滤波器可去除在块之间的边界处出现的块失真。为了确定去块滤波器是否被运行,可基于包括在块中的若干行或列中的像素来确定去块滤波器是否被应用于当前块。当去块滤波器被应用于块时,可依据所需的去块滤波器强度来应用强滤波器或弱滤波器。此外,在应用去块滤波器时,可并行处理水平方向滤波和垂直方向滤波。Deblocking filters remove blocking artifacts that occur at the boundaries between blocks. To determine whether a deblocking filter is run, whether a deblocking filter is applied to a current block may be determined based on pixels included in several rows or columns of the block. When a deblocking filter is applied to a block, a strong or weak filter may be applied depending on the desired deblocking filter strength. In addition, when applying a deblocking filter, horizontal filtering and vertical filtering can be processed in parallel.
样点自适应偏移可将最优偏移值添加到像素值以便对编码误差进行补偿。样点自适应偏移可针对每个像素对经过去块滤波的图像和原始画面之间的偏移进行校正。为了对特定画面执行偏移校正,可使用考虑每个像素的边缘信息来应用偏移的方法,或使用以下方法:将图像的像素分区为预定数量的区域,确定将被执行偏移校正的区域,并对所确定区域应用偏移校正。Sample Adaptive Offset adds optimal offset values to pixel values to compensate for encoding errors. Sample adaptive offset corrects the offset between the deblocking filtered image and the original picture on a per-pixel basis. In order to perform offset correction on a specific frame, you can use a method that considers the edge information of each pixel to apply the offset, or use the following method: divide the pixels of the image into a predetermined number of areas, and determine the area where the offset correction will be performed. , and apply offset correction to the determined area.
自适应环路滤波器可基于通过将重建画面与原始画面进行比较而获得的值来执行滤波。图像的像素可被分区为预定组,被应用于每个组的一个滤波器被确定,并且不同的滤波可在每个组被执行。关于自适应环路滤波器是否被应用于亮度信号的信息可针对每个编码单元(CU)被发送。被应用于每个块的自适应环路滤波器的形状和滤波器系数可变化。此外,具有相同形式(固定形式)的自适应环路滤波器可在不考虑目标块的特性的情况下被应用。The adaptive loop filter may perform filtering based on values obtained by comparing the reconstructed picture with the original picture. The pixels of the image can be partitioned into predetermined groups, a filter to be applied to each group is determined, and different filtering can be performed on each group. Information on whether an adaptive loop filter is applied to the luminance signal may be sent for each coding unit (CU). The shape and filter coefficients of the adaptive loop filter applied to each block can vary. Furthermore, the adaptive loop filter with the same form (fixed form) can be applied without considering the characteristics of the target block.
经过滤波器单元180的重建块可被存储在参考画面缓冲器190中。The reconstructed blocks that have passed through the filter unit 180 may be stored in the reference picture buffer 190 .
图2是示出根据本发明的实施例的解码设备的配置的框图。2 is a block diagram showing the configuration of a decoding device according to an embodiment of the present invention.
解码设备200可以是视频解码设备或图像解码设备。The decoding device 200 may be a video decoding device or an image decoding device.
参照图2,解码设备200可包括熵解码单元210、反量化单元220、逆变换单元230、帧内预测单元240、运动补偿单元250、加法器255、滤波器单元260以及参考画面缓冲器270。Referring to FIG. 2 , the decoding device 200 may include an entropy decoding unit 210, an inverse quantization unit 220, an inverse transform unit 230, an intra prediction unit 240, a motion compensation unit 250, an adder 255, a filter unit 260, and a reference picture buffer 270.
解码设备200可接收从编码设备100输出的比特流。解码设备200可按照帧内模式或帧间模式对比特流进行解码。此外,解码设备100可通过执行解码来产生重建画面,并可输出重建画面。The decoding device 200 may receive the bit stream output from the encoding device 100. The decoding device 200 may decode the bit stream in an intra mode or an inter mode. Furthermore, the decoding device 100 may generate a reconstructed picture by performing decoding, and may output the reconstructed picture.
当在解码中使用的预测模式是帧内模式时,切换器可被切换到帧内。当在解码中使用的预测模式是帧间模式时,切换器可被切换到帧间。When the prediction mode used in decoding is intra mode, the switcher may be switched to intra. When the prediction mode used in decoding is inter mode, the switcher may be switched to inter.
解码设备200可从输入的比特流获得重建残差块,并可产生预测块。当重建残差块和预测块被获得时,解码设备200可通过将重建残差块与预测块相加来产生作为解码目标块的重建块。解码目标块可被称为当前块。The decoding device 200 may obtain a reconstruction residual block from the input bit stream, and may generate a prediction block. When the reconstruction residual block and the prediction block are obtained, the decoding device 200 may generate the reconstruction block as the decoding target block by adding the reconstruction residual block and the prediction block. The decoding target block may be called the current block.
熵解码单元210可通过根据概率分布对比特流执行熵解码来产生符号。产生的符号可包括具有量化的变换系数等级的符号。这里,熵解码的方法可与上述熵编码的方法类似。例如,熵解码的方法可以是上述熵编码的方法的逆处理。The entropy decoding unit 210 may generate symbols by performing entropy decoding on the bitstream according to a probability distribution. The generated symbols may include symbols with quantized transform coefficient levels. Here, the method of entropy decoding may be similar to the method of entropy encoding described above. For example, the entropy decoding method may be the inverse of the entropy encoding method described above.
为了对变换系数等级进行解码,熵解码单元210可执行变换系数扫描,由此,一维矢量形式的系数可被改变为二维块形式。例如,通过用右上扫描来扫描块的系数,一维矢量形式的系数可被改变为二维块形式。根据变换单元的大小以及帧内预测模式,可使用垂直方向扫描以及水平方向扫描,而不是使用右上扫描。也就是说,依据变换单元的大小以及帧内预测模式,可确定在右上扫描、垂直方向扫描和水平方向扫描之中的哪种扫描方法被使用。To decode transform coefficient levels, entropy decoding unit 210 may perform transform coefficient scanning, whereby coefficients in one-dimensional vector form may be changed into two-dimensional block form. For example, coefficients in one-dimensional vector form can be changed into two-dimensional block form by scanning the coefficients of the block with an upper right scan. Depending on the size of the transform unit and the intra prediction mode, vertical scanning as well as horizontal scanning may be used instead of upper right scanning. That is, depending on the size of the transformation unit and the intra prediction mode, it can be determined which scanning method is used among upper right scanning, vertical direction scanning, and horizontal direction scanning.
量化的变换系数等级可通过反量化单元220被反量化,并可通过逆变换单元230被逆变换。量化的变换系数等级被反量化并被逆变换以便产生重建残差块。这里,反量化单元220可对量化的变换系数等级应用量化矩阵。The quantized transform coefficient levels may be inversely quantized by inverse quantization unit 220 and may be inversely transformed by inverse transform unit 230 . The quantized transform coefficient levels are inversely quantized and inversely transformed to produce a reconstructed residual block. Here, the inverse quantization unit 220 may apply a quantization matrix to the quantized transform coefficient levels.
当帧内模式被使用时,帧内预测单元240可通过执行空间预测来产生预测块,其中,空间预测使用与解码目标块相邻的先前解码块的像素值。When the intra mode is used, the intra prediction unit 240 may generate a prediction block by performing spatial prediction using pixel values of previously decoded blocks adjacent to the decoding target block.
当帧间模式被使用时,运动补偿单元250可通过执行运动补偿来产生预测块,其中,运动补偿使用存储在参考画面缓冲器270中的参考画面以及运动矢量两者。当运动矢量的值不是整数时,运动补偿单元250可通过对参考画面中的部分区域应用插值滤波器来产生预测块。为了执行运动补偿,基于编码单元,可在跳过模式、合并模式、AMVP模式和当前画面参考模式之中确定编码单元中的预测单元的运动补偿方法使用哪种方法。此外,可依据所述模式执行运动补偿。这里,当前画面参考模式可意为使用具有解码目标块的当前画面内的先前重建区域的预测模式。先前重建区域可不与解码目标块相邻。为了指明先前重建区域,可针对当前画面参考模式使用固定矢量。此外,指示解码目标块是否是按照当前画面参考模式被解码的块的标志或索引可被用信号发送,并可通过使用解码目标块的参考画面索引而被推导出。针对当前画面参考模式的当前画面可存在于针对解码目标块的参考画面列表内的固定位置(例如,参考画面索引为0的位置或最后的位置)。此外,当前画面可以可变地位于参考画面列表内,为此,可用信号发送指示当前画面的位置的参考画面索引。这里,用信号传送标志或索引可表示编码器对相应标志或索引进行熵编码并包括在比特流中,并表示解码器从比特流对所述相应标志或索引进行熵解码。When inter mode is used, motion compensation unit 250 may generate prediction blocks by performing motion compensation using both reference pictures and motion vectors stored in reference picture buffer 270 . When the value of the motion vector is not an integer, the motion compensation unit 250 may generate a prediction block by applying an interpolation filter to a partial area in the reference picture. In order to perform motion compensation, based on the coding unit, which method to use for the motion compensation method of the prediction unit in the coding unit may be determined among skip mode, merge mode, AMVP mode, and current picture reference mode. Furthermore, motion compensation can be performed depending on the mode. Here, the current picture reference mode may mean a prediction mode using a previously reconstructed region within the current picture with the decoding target block. The previously reconstructed region may not be adjacent to the decoding target block. To indicate previously reconstructed areas, fixed vectors can be used for the current picture reference mode. Furthermore, a flag or index indicating whether the decoding target block is a block decoded according to the current picture reference mode may be signaled and may be derived by using the reference picture index of the decoding target block. The current picture for the current picture reference mode may exist at a fixed position within the reference picture list for the decoding target block (eg, the position with reference picture index 0 or the last position). Furthermore, the current picture may be variably located within the reference picture list, for which a reference picture index indicating the position of the current picture may be signaled. Here, signaling a flag or index may mean that the encoder entropy-encodes the corresponding flag or index and includes it in the bitstream, and means that the decoder entropy-decodes the corresponding flag or index from the bitstream.
可通过加法器255将重建残差块与预测块相加。通过将重建残差块和预测块相加而产生的块可经过滤波器单元260。滤波器单元260可对重建块或重建画面应用去块滤波器、样点自适应偏移和自适应环路滤波器中的至少一个。滤波器单元260可输出重建画面。重建画面可被存储在参考画面缓冲器270中,并可被用于帧间预测。The reconstructed residual block and the prediction block may be added by adder 255. Blocks generated by adding the reconstruction residual block and the prediction block may be passed through filter unit 260. The filter unit 260 may apply at least one of a deblocking filter, a sample adaptive offset, and an adaptive loop filter to the reconstructed block or reconstructed picture. Filter unit 260 may output a reconstructed picture. The reconstructed pictures may be stored in the reference picture buffer 270 and used for inter prediction.
图3是示意性地示出当对图像进行编码和解码时的图像的分区结构的示图。图3示意性地示出将一个单元分区为多个子单元的实施例。FIG. 3 is a diagram schematically showing a partition structure of an image when encoding and decoding the image. Figure 3 schematically illustrates an embodiment of partitioning one unit into multiple sub-units.
为了对图像进行有效分区,编码单元(CU)可在编码和解码中被使用。这里,编码单元可意为进行编码的单元,单元可以是1)语法元素和2)包括图像样点的块的组合。例如,“单元的分区”可意为“与单元相关的块的分区”。块分区信息可包括关于单元深度的信息。深度信息可指示单元被分区的次数或单元被分区的程度或两者。In order to efficiently partition images, coding units (CUs) may be used in encoding and decoding. Here, a coding unit may mean a unit for encoding, and a unit may be a combination of 1) a syntax element and 2) a block including image samples. For example, "partition of a unit" may mean "partition of a block associated with the unit." Block partition information may include information about unit depth. Depth information may indicate the number of times the unit is partitioned or the extent to which the unit is partitioned, or both.
参照图3,图像300针对每个最大编码单元(LCU)被顺序分区,并且分区结构针对每个LCU被确定。这里,LCU和编码树单元(CTU)具有相同的含义。一个单元可具有基于树结构的深度信息,并可被分层分区。每个分区出的子单元可具有深度信息。深度信息指示单元被分区的次数或单元被分区的程度或两者,因此,深度信息可包括关于子单元的大小的信息。Referring to FIG. 3 , an image 300 is sequentially partitioned for each largest coding unit (LCU), and the partition structure is determined for each LCU. Here, LCU and Coding Tree Unit (CTU) have the same meaning. A cell can have depth information based on a tree structure and can be partitioned hierarchically. Each partitioned subunit may have depth information. Depth information indicates the number of times a unit is partitioned or the extent to which the unit is partitioned, or both, and therefore, the depth information may include information about the size of a subunit.
分区结构可意为LCU 310中的编码单元(CU)的分布。CU可以是用于对图像进行有效编码/解码的单元。所述分布可基于一个CU是否将被多次(等于或大于2的正整数,包括2、4、8、16等)分区而被确定。分区出的CU的宽度大小和高度大小可分别为原始CU的一半宽度大小和一半高度大小。可选择地,根据分区的次数,分区出的CU的宽度大小和高度大小可分别小于原始CU的宽度大小和高度大小。分区出的CU可被递归地分区为多个进一步分区出的CU,其中,按照相同的分区方法,所述进一步分区出的CU具有比所述分区出的CU的宽度大小和高度大小更小的宽度大小和高度大小。The partition structure may mean the distribution of coding units (CUs) in the LCU 310. A CU may be a unit for efficient encoding/decoding of images. The distribution may be determined based on whether a CU will be partitioned multiple times (a positive integer equal to or greater than 2, including 2, 4, 8, 16, etc.). The width and height of the partitioned CU can be half the width and half the height of the original CU respectively. Optionally, according to the number of partitions, the width and height of the partitioned CU may be respectively smaller than the width and height of the original CU. The partitioned CU may be recursively partitioned into a plurality of further partitioned CUs, wherein the further partitioned CUs have a smaller width size and height size than the partitioned CU according to the same partitioning method. width size and height size.
这里,CU的分区可被递归地执行直到预定深度。深度信息可以是指示CU的大小的信息,并且可被存储在每个CU中。例如,LCU的深度可以是0,并且最小编码单元(SCU)的深度可以是预定最大深度。这里,LCU可以是具有上述最大大小的编码单元,并且SCU可以是具有最小大小的编码单元。Here, the partitioning of the CU may be performed recursively up to a predetermined depth. The depth information may be information indicating the size of the CU and may be stored in each CU. For example, the depth of the LCU may be 0, and the depth of the minimum coding unit (SCU) may be a predetermined maximum depth. Here, the LCU may be a coding unit having the above-mentioned maximum size, and the SCU may be a coding unit having the minimum size.
每当LCU 310开始被分区,并且CU的宽度大小和高度大小通过分区操作而减小时,CU的深度增加1。在不能被分区的CU的情况下,CU针对每个深度可具有2N×2N大小。在能够被分区的CU的情况下,具有2N×2N大小的CU可被分区为多个N×N大小的CU。每当深度增加1时,N的大小减半。Whenever the LCU 310 starts to be partitioned, and the width size and height size of the CU are reduced by the partitioning operation, the depth of the CU is increased by one. In the case of a CU that cannot be partitioned, the CU may have a 2N×2N size for each depth. In the case of a CU that can be partitioned, a CU with a size of 2N×2N may be partitioned into multiple N×N sized CUs. Whenever the depth increases by 1, the size of N is halved.
例如,当一个编码单元被分区为四个子编码单元时,所述四个子编码单元之一的宽度大小和高度大小可分别为原始编码单元的一半宽度大小和一半高度大小。例如,当32×32大小的编码单元被分区为四个子编码单元时,所述四个子编码单元中的每一个可具有16×16大小。当一个编码单元被分区为四个子编码单元时,编码单元可按照四叉树形式被分区。For example, when one coding unit is partitioned into four sub-coding units, the width size and height size of one of the four sub-coding units may be half the width size and half the height size of the original coding unit, respectively. For example, when a coding unit of 32×32 size is partitioned into four sub-coding units, each of the four sub-coding units may have a size of 16×16. When one coding unit is partitioned into four sub-coding units, the coding unit may be partitioned in a quadtree form.
例如,当一个编码单元被分区为两个子编码单元时,所述两个子编码单元之一的宽度大小或高度大小可分别为原始编码单元的一半宽度大小或一半高度大小。例如,当32×32大小的编码单元被垂直分区为两个子编码单元时,所述两个子编码单元中的每一个可具有16×32大小。例如,当32×32大小的编码单元被水平分区为两个子编码单元时,所述两个子编码单元中的每一个可具有32×16大小。当一个编码单元被分区为两个子编码单元时,编码单元可按照二叉树形式被分区。For example, when one coding unit is partitioned into two sub-coding units, the width size or height size of one of the two sub-coding units may be half the width size or half the height size of the original coding unit, respectively. For example, when a coding unit of 32×32 size is vertically partitioned into two sub-coding units, each of the two sub-coding units may have a size of 16×32. For example, when a coding unit of 32×32 size is horizontally partitioned into two sub-coding units, each of the two sub-coding units may have a size of 32×16. When a coding unit is partitioned into two sub-coding units, the coding unit may be partitioned in a binary tree form.
参照图3,具有最小深度0的LCU的大小可以是64×64像素,并且具有最大深度3的SCU的大小可以是8×8像素。这里,可由深度0来表示具有64×64像素的CU(即,LCU),可由深度1来表示具有32×32像素的CU,可由深度2来表示具有16×16像素的CU,并且可由深度3来表示具有8×8像素的CU(即,SCU)。Referring to FIG. 3 , the size of the LCU with the minimum depth 0 may be 64×64 pixels, and the size of the SCU with the maximum depth 3 may be 8×8 pixels. Here, a CU (ie, LCU) having 64×64 pixels may be represented by depth 0, a CU having 32×32 pixels may be represented by depth 1, a CU having 16×16 pixels may be represented by depth 2, and a CU having 16×16 pixels may be represented by depth 3 to represent a CU with 8×8 pixels (i.e., SCU).
此外,可通过CU的分区信息来表示关于CU是否将被分区的信息。分区信息可以是1比特信息。分区信息可被包括在除SCU以外的所有CU中。例如,当分区信息的值为0时,CU可不被分区,当分区信息的值为1时,CU可被分区。In addition, information on whether the CU will be partitioned may be expressed by partition information of the CU. Partition information may be 1-bit information. Partition information can be included in all CUs except SCU. For example, when the value of the partition information is 0, the CU may not be partitioned, and when the value of the partition information is 1, the CU may be partitioned.
图4是示出可被包括在编码单元(CU)中的预测单元(PU)的形式的示图。4 is a diagram illustrating a form of a prediction unit (PU) that may be included in a coding unit (CU).
从LCU分区出的多个CU之中的不再被分区的CU可被分区为至少一个预测单元(PU)。该处理也可被称为分区。Among the plurality of CUs partitioned from the LCU, the CUs that are no longer partitioned may be partitioned into at least one prediction unit (PU). This process may also be called partitioning.
PU可以是用于预测的基本单元。PU可按照跳过模式、帧间模式和帧内模式中的任一模式而被编码和解码。PU可依据所述模式按照各种形式被分区。PU can be the basic unit used for prediction. A PU may be encoded and decoded in any of skip mode, inter mode, and intra mode. PUs may be partitioned in various forms depending on the mode.
此外,编码单元可不被分区为多个预测单元,并且编码单元和预测单元可具有相同的大小。Furthermore, the coding unit may not be partitioned into multiple prediction units, and the coding unit and the prediction unit may have the same size.
如图4所示,在跳过模式中,CU可不被分区。在跳过模式中,可支持与不经分区的CU具有相同大小的2N×2N模式410。As shown in Figure 4, in skip mode, the CU may not be partitioned. In skip mode, a 2Nx2N mode 410 with the same size as a non-partitioned CU may be supported.
在帧间模式中,在CU中可支持8个分区模式。例如,在帧间模式中,可支持2N×2N模式410、2N×N模式415、N×2N模式420、N×N模式425、2N×nU模式430、2N×nD模式435、nL×2N模式440以及nR×2N模式445。在帧内模式中,可支持2N×2N模式410和N×N模式425。In inter mode, 8 partition modes can be supported in the CU. For example, in inter mode, 2N×2N mode 410, 2N×N mode 415, N×2N mode 420, N×N mode 425, 2N×nU mode 430, 2N×nD mode 435, nL×2N mode can be supported 440 and nR×2N mode 445. In intra mode, 2N×2N mode 410 and N×N mode 425 may be supported.
一个编码单元可被分区为一个或更多个预测单元。一个预测单元可被分区为一个或更多个子预测单元。A coding unit can be partitioned into one or more prediction units. A prediction unit can be partitioned into one or more sub-prediction units.
例如,当一个预测单元被分区为四个子预测单元时,所述四个子预测单元之一的宽度大小和高度大小可为原始预测单元的一半宽度大小和一半高度大小。例如,当32×32大小的预测单元被分区为四个子预测单元时,所述四个子预测单元中的每一个可具有16×16大小。当一个预测单元被分区为四个子预测单元时,预测单元可按照四叉树形式被分区。For example, when one prediction unit is partitioned into four sub-prediction units, the width size and height size of one of the four sub-prediction units may be half the width size and half the height size of the original prediction unit. For example, when a prediction unit of 32×32 size is partitioned into four sub-prediction units, each of the four sub-prediction units may have a size of 16×16. When one prediction unit is partitioned into four sub-prediction units, the prediction unit may be partitioned in a quadtree form.
例如,当一个预测单元被分区为两个子预测单元时,所述两个子预测单元之一的宽度大小或高度大小可为原始预测单元的一半宽度大小或一半高度大小。例如,当32×32大小的预测单元被垂直分区为两个子预测单元时,所述两个子预测单元中的每一个可具有16×32大小。例如,当32×32大小的预测单元被水平分区为两个子预测单元时,所述两个子预测单元中的每一个可具有32×16大小。当一个预测单元被分区为两个子预测单元时,预测单元可按照二叉树形式被分区。For example, when one prediction unit is partitioned into two sub-prediction units, the width size or height size of one of the two sub-prediction units may be half the width size or half the height size of the original prediction unit. For example, when a prediction unit of 32×32 size is vertically partitioned into two sub-prediction units, each of the two sub-prediction units may have a size of 16×32. For example, when a prediction unit of 32×32 size is horizontally partitioned into two sub-prediction units, each of the two sub-prediction units may have a size of 32×16. When one prediction unit is partitioned into two sub-prediction units, the prediction unit may be partitioned in a binary tree form.
图5是示出可被包括在编码单元(CU)中的变换单元(TU)的形式的示图。FIG. 5 is a diagram illustrating a form of a transformation unit (TU) that may be included in a coding unit (CU).
变换单元(TU)可以是CU内的用于变换、量化、逆变换和反量化的基本单元。TU可具有正方形状或矩形形状等。TU可按照CU的大小或CU的形式或两者而被独立确定。A Transform Unit (TU) may be a basic unit within a CU for transform, quantization, inverse transform, and inverse quantization. The TU may have a square shape, a rectangular shape, etc. TUs may be determined independently by the size of the CU or the form of the CU, or both.
从LCU分区出的CU之中的不再被分区的CU可被分区为至少一个TU。这里,TU的分区结构可以是四叉树结构。例如,如图5所示,一个CU 510可依据四叉树结构而被分区一次或更多次。一个CU被分区至少一次的情况可被称为递归分区。通过进行分区,一个CU 510可由具有不同大小的TU形成。可选择地,CU可依据对CU进行分区的垂直线的数量或对CU进行分区的水平线的数量或两者而被分区为至少一个TU。CU可被分区为彼此对称的TU,或者可被分区为彼此不对称的TU。为了将CU分区为彼此对称的TU,TU的大小/形状的信息可被用信号传送,并可从CU的大小/形状的信息推导出。Among the CUs partitioned from the LCU, the CUs that are no longer partitioned may be partitioned into at least one TU. Here, the partition structure of the TU may be a quadtree structure. For example, as shown in Figure 5, a CU 510 may be partitioned one or more times according to a quadtree structure. The situation where a CU is partitioned at least once may be called recursive partitioning. By partitioning, one CU 510 can be formed from TUs of different sizes. Alternatively, a CU may be partitioned into at least one TU based on the number of vertical lines by which the CU is partitioned or the number of horizontal lines by which the CU is partitioned, or both. CUs may be partitioned into TUs that are symmetrical to each other, or may be partitioned into TUs that are asymmetrical to each other. In order to partition a CU into TUs that are symmetrical to each other, information on the size/shape of the TU can be signaled and can be derived from the information on the size/shape of the CU.
此外,编码单元可不被分区为变换单元,并且编码单元和变换单元可具有相同的大小。Furthermore, coding units may not be partitioned into transformation units, and coding units and transformation units may have the same size.
一个编码单元可被分区为至少一个变换单元,并且一个变换单元可被分区为至少一个子变换单元。One coding unit may be partitioned into at least one transformation unit, and one transformation unit may be partitioned into at least one sub-transformation unit.
例如,当一个变换单元被分区为四个子变换单元时,所述四个子变换单元之一的宽度大小和高度大小可分别为原始变换单元的一半宽度大小和一半高度大小。例如,当32×32大小的变换单元被分区为四个子变换单元时,所述四个子变换单元中的每一个可具有16×16大小。当一个变换单元被分区为四个子变换单元时,变换单元可按照四叉树形式被分区。For example, when one transformation unit is partitioned into four sub-transformation units, the width size and height size of one of the four sub-transformation units may be half the width size and half the height size of the original transformation unit, respectively. For example, when a 32×32-sized transformation unit is partitioned into four sub-transformation units, each of the four sub-transformation units may have a size of 16×16. When one transformation unit is partitioned into four sub-transformation units, the transformation unit may be partitioned in a quadtree form.
例如,当一个变换单元被分区为两个子变换单元时,所述两个子变换单元之一的宽度大小或高度大小可分别为原始变换单元的一半宽度大小或一半高度大小。例如,当32×32大小的变换单元被垂直分区为两个子变换单元时,所述两个子变换单元中的每一个可具有16×32大小。例如,当32×32大小的变换单元被水平分区为两个子变换单元时,所述两个子变换单元中的每一个可具有32×16大小。当一个变换单元被分区为两个子变换单元时,变换单元可按照二叉树形式被分区。For example, when one transformation unit is partitioned into two sub-transformation units, the width size or height size of one of the two sub-transformation units may be half the width size or half the height size of the original transformation unit, respectively. For example, when a transformation unit of 32×32 size is vertically partitioned into two sub-transformation units, each of the two sub-transformation units may have a size of 16×32. For example, when a transformation unit of 32×32 size is horizontally partitioned into two sub-transformation units, each of the two sub-transformation units may have a size of 32×16. When one transformation unit is partitioned into two sub-transformation units, the transformation unit may be partitioned in a binary tree form.
当执行变换时,可通过使用预定变换方法中的至少一种变换方法对残差块进行变换。例如,所述预定变换方法可包括离散余弦变换(DCT)、离散正弦变换(DST)、KLT等。可通过使用以下项中的至少一个来确定哪种变换方法被应用于对残差块进行变换:预测单元的帧间预测模式信息、预测单元的帧内预测模式信息以及变换块的大小/形状。指示变换方法的信息可被用信号传送。When performing transformation, the residual block may be transformed by using at least one transformation method among predetermined transformation methods. For example, the predetermined transformation method may include discrete cosine transform (DCT), discrete sine transform (DST), KLT, etc. Which transform method is applied to transform the residual block may be determined by using at least one of: inter prediction mode information of the prediction unit, intra prediction mode information of the prediction unit, and the size/shape of the transform block. Information indicating the transformation method may be signaled.
图6是用于解释帧内预测的处理的实施例的示图。FIG. 6 is a diagram for explaining an embodiment of processing of intra prediction.
帧内预测模式可以是非方向模式或方向模式。非方向模式可以是DC模式或平面模式。方向模式可以是具有特定方向或角度的预测模式,并且方向模式的数量可以是等于或大于1的M。方向模式可被指示为模式编号、模式值和模式角度中的至少一个。Intra prediction mode can be non-directional mode or directional mode. Non-directional mode can be DC mode or planar mode. The direction mode may be a prediction mode with a specific direction or angle, and the number of direction modes may be M equal to or greater than 1. The direction mode may be indicated as at least one of a mode number, a mode value, and a mode angle.
帧内预测模式的数量可以是等于或大于1的N,包括非方向模式和方向模式。The number of intra prediction modes may be N equal to or greater than 1, including non-directional modes and directional modes.
帧内预测模式的数量可依据块的大小而变化。例如,当块的大小为4×4或8×8时,帧内预测模式的数量可以是67,当块的大小是16×16时,帧内预测模式的数量可以是35,当块的大小是32×32时,帧内预测模式的数量可以是19,当块的大小是64×64时,帧内预测模式的数量可以是7。The number of intra prediction modes may vary depending on the block size. For example, when the block size is 4×4 or 8×8, the number of intra prediction modes may be 67, when the block size is 16×16, the number of intra prediction modes may be 35, and when the block size is 16×16, the number of intra prediction modes may be 35. When the block size is 32×32, the number of intra prediction modes may be 19, and when the block size is 64×64, the number of intra prediction modes may be 7.
帧内预测模式的数量可被固定为N,而不管块的大小如何。例如,帧内预测模式的数量可被固定为35或67中的至少一个,而不管块的大小如何。The number of intra prediction modes can be fixed to N regardless of the block size. For example, the number of intra prediction modes may be fixed to at least one of 35 or 67 regardless of the block size.
帧内预测模式的数量可依据颜色分量的类型而变化。例如,预测模式的数量可依据颜色分量是亮度信号还是色度信号而变化。The number of intra prediction modes may vary depending on the type of color component. For example, the number of prediction modes may vary depending on whether the color component is a luminance signal or a chrominance signal.
可通过使用重建邻近块中所包括的样点值或编码参数来执行帧内编码和/或解码。Intra-coding and/or decoding may be performed using sample values or coding parameters included in reconstructed adjacent blocks.
为了按照帧内预测对当前块进行编码/解码,可识别包括在重建邻近块中的样点是否可用作编码/解码目标块的参考样点。当存在不能用作编码/解码目标块的参考样点的样点时,通过使用包括在重建邻近块中的样点中的至少一个样点,样点值被复制和/或插值到不能用作参考样点的样点,由此,不能用作参考样点的样点可被用作编码/解码目标块的参考样点。In order to encode/decode the current block according to intra prediction, it may be identified whether samples included in the reconstructed neighboring blocks can be used as reference samples for the encoding/decoding target block. When there are samples that cannot be used as reference samples for the encoding/decoding target block, the sample values are copied and/or interpolated to the point that cannot be used as reference samples by using at least one of the samples included in the reconstructed adjacent block. Samples of reference samples, whereby samples that cannot be used as reference samples can be used as reference samples for encoding/decoding target blocks.
在帧内预测中,基于帧内预测模式以及编码/解码目标块的大小中的至少一个,滤波器可被应用于参考样点或预测样点中的至少一个。这里,编码/解码目标块可意为当前块,并且可意为编码块、预测块和变换块中的至少一个。被应用于参考样点或预测样点的滤波器的类型可依据帧内预测模式或当前块的大小/形状中的至少一个而变化。滤波器的类型可依据滤波器抽头的数量、滤波器系数值或滤波器强度中的至少一个而变化。In intra prediction, a filter may be applied to at least one of a reference sample or a prediction sample based on at least one of an intra prediction mode and a size of an encoding/decoding target block. Here, the encoding/decoding target block may mean a current block, and may mean at least one of a coding block, a prediction block, and a transformation block. The type of filter applied to the reference samples or prediction samples may vary depending on at least one of the intra prediction mode or the size/shape of the current block. The type of filter may vary depending on at least one of the number of filter taps, filter coefficient values, or filter strength.
在帧内预测模式之中的非方向平面模式中,当产生编码/解码目标块的预测块时,可根据样点位置通过使用当前样点的上参考样点、当前样点的左参考样点、当前块的右上参考样点、以及当前块的左下参考样点的加权和来产生预测块中的样点值。In the non-directional plane mode among the intra prediction modes, when generating the prediction block of the encoding/decoding target block, the upper reference sample of the current sample and the left reference sample of the current sample can be used according to the sample position. , the upper right reference sample point of the current block, and the weighted sum of the lower left reference sample point of the current block to generate the sample value in the prediction block.
在帧内预测模式之中的非方向DC模式中,当产生编码/解码目标块的预测块时,可通过当前块的上参考样点和当前块的左参考样点的均值来产生预测块。此外,可通过使用参考样点值对编码/解码块中与参考样点相邻的一个或更多个上方行以及一个或更多个左侧列执行滤波。In the non-directional DC mode among the intra prediction modes, when generating a prediction block of an encoding/decoding target block, the prediction block may be generated by an average of the upper reference sample of the current block and the left reference sample of the current block. Furthermore, filtering may be performed on one or more upper rows and one or more left columns in the encoding/decoding block adjacent to the reference samples by using the reference sample values.
在帧内预测模式之中的多个方向模式(角度模式)的情况下,可通过使用右上参考样点和/或左下参考样点来产生预测块,并且所述多个方向模式可具有不同的方向。为了产生预测样点值,可执行实数单元的插值。In the case of a plurality of direction modes (angle modes) among intra prediction modes, the prediction block may be generated by using the upper right reference sample and/or the lower left reference sample, and the plurality of direction modes may have different direction. To generate predicted sample values, interpolation of real units may be performed.
为了执行帧内预测方法,可从与当前预测块相邻的邻近预测块的帧内预测模式预测当前预测块的帧内预测模式。在通过使用从邻近帧内预测模式预测出的模式信息来预测当前预测块的帧内预测模式的情况下,在当前预测块和邻近预测块具有相同的帧内预测模式时,当前预测块和邻近预测块具有相同的帧内预测模式的信息可通过使用预定标志信息被发送。在当前预测块的帧内预测模式不同于邻近预测块的帧内预测模式时,可通过执行熵编码来对编码/解码目标块的帧内预测模式信息进行编码。In order to perform the intra prediction method, the intra prediction mode of the current prediction block may be predicted from the intra prediction modes of neighboring prediction blocks adjacent to the current prediction block. In the case where the intra prediction mode of the current prediction block is predicted by using the mode information predicted from the neighboring intra prediction mode, when the current prediction block and the neighboring prediction block have the same intra prediction mode, the current prediction block and the neighboring prediction block Information that prediction blocks have the same intra prediction mode may be transmitted using predetermined flag information. When the intra prediction mode of the current prediction block is different from the intra prediction mode of the neighboring prediction block, the intra prediction mode information of the encoding/decoding target block may be encoded by performing entropy encoding.
图7是用于解释帧间预测的处理的实施例的示图。FIG. 7 is a diagram for explaining an embodiment of a process of inter prediction.
图7中示出的四角形可指示图像(或画面)。此外,图7的箭头可指示预测方向。也就是说,图像可根据预测方向被编码或解码或者被编码和解码。根据编码类型,每个图像可被分类为I画面(帧内画面)、P画面(单向预测画面)、B画面(双向预测画面)等。每个画面可依据每个画面的编码类型而被编码和解码。The square shape shown in Figure 7 may indicate an image (or picture). In addition, the arrows of FIG. 7 may indicate the prediction direction. That is, the image may be encoded or decoded or encoded and decoded according to the prediction direction. Depending on the encoding type, each image can be classified into an I picture (intra picture), a P picture (unidirectionally predicted picture), a B picture (bidirectionally predicted picture), etc. Each picture can be encoded and decoded according to the encoding type of each picture.
当作为编码目标的图像是I画面时,画面本身可在无需帧间预测的情况下被帧内编码。当作为编码目标的图像是P画面时,可通过使用仅在前向的参考画面进行帧间预测或运动补偿来对图像进行编码。当作为编码目标的图像是B画面时,可通过使用在前向和逆向两者的参考画面进行帧间预测或运动补偿来对图像进行编码。可选择地,可通过使用在前向和逆向之一的参考画面进行帧间预测或运动补偿来对图像进行编码。这里,当帧间预测模式被使用时,编码器可执行帧间预测或运动补偿,并且解码器可响应于编码器执行运动补偿。通过使用参考画面被编码或解码或者被编码和解码的P画面和B画面的图像可被视为用于帧间预测的图像。When the image targeted for encoding is an I picture, the picture itself can be intra-encoded without inter prediction. When the image targeted for encoding is a P picture, the image can be encoded by performing inter prediction or motion compensation using a reference picture only in the forward direction. When the image as the encoding target is a B picture, the image can be encoded by performing inter prediction or motion compensation using reference pictures in both forward and reverse directions. Alternatively, the image may be encoded by inter prediction or motion compensation using a reference picture in one of the forward and reverse directions. Here, when the inter prediction mode is used, the encoder may perform inter prediction or motion compensation, and the decoder may perform motion compensation in response to the encoder. Images of P pictures and B pictures that are encoded or decoded or encoded and decoded by using reference pictures may be regarded as images for inter prediction.
在下文中,将详细描述根据实施例的帧间预测。Hereinafter, inter prediction according to embodiments will be described in detail.
可通过使用参考画面和运动信息两者来执行帧间预测或运动补偿。此外,帧间预测可使用上述跳过模式。Inter prediction or motion compensation can be performed by using both reference pictures and motion information. Additionally, inter prediction may use the skip mode described above.
参考画面可以是当前画面的先前画面和后续画面中的至少一个。这里,帧间预测可依据参考画面来预测当前画面的块。这里,参考画面可意为在对块进行预测时使用的图像。这里,参考画面内的区域可通过使用指示参考画面的参考画面索引(refIdx)、运动矢量等来指明。The reference picture may be at least one of a previous picture and a subsequent picture of the current picture. Here, inter prediction can predict the blocks of the current picture based on the reference picture. Here, the reference picture may mean an image used when predicting a block. Here, the area within the reference picture may be specified by using a reference picture index (refIdx) indicating the reference picture, a motion vector, or the like.
帧间预测可选择参考画面和参考画面内与当前块相关的参考块。可通过使用选择的参考块来产生当前块的预测块。当前块可以是当前画面的块之中的作为当前编码目标或当前解码目标的块。Inter prediction can select a reference picture and a reference block within the reference picture that is related to the current block. A prediction block for the current block may be generated by using the selected reference block. The current block may be a block that is a current encoding target or a current decoding target among the blocks of the current picture.
可由编码设备100和解码设备200从帧间预测的处理推导运动信息。此外,推导出的运动信息可在执行帧间预测时被使用。这里,编码设备100和解码设备200可通过使用重建邻近块的运动信息或同位块(col块)的运动信息或两者的运动信息来提高编码效率或解码效率或两者。col块可以是先前被重建的同位画面(col画面)内的与编码/解码目标块的空间位置相关的块。重建邻近块可以是当前画面内的块、以及通过编码或解码或者编码和解码两者先前被重建的块。此外,重建块可以是与编码/解码目标块相邻的块,或者是位于编码/解码目标块的外部拐角处的块,或者是两者。这里,位于编码/解码目标块的外部拐角处的块可以是与水平相邻于编码/解码目标块的邻近块垂直相邻的块。可选择地,位于编码/解码目标块的外部拐角处的块可以是与垂直相邻于编码/解码目标块的邻近块水平相邻的块。The motion information can be derived by the encoding device 100 and the decoding device 200 from the process of inter prediction. Furthermore, the derived motion information can be used when performing inter prediction. Here, the encoding device 100 and the decoding device 200 may improve encoding efficiency or decoding efficiency or both by using motion information of reconstructed neighboring blocks or motion information of co-located blocks (col blocks) or both. The col block may be a block related to the spatial position of the encoding/decoding target block within a previously reconstructed co-located picture (col picture). Reconstructed neighboring blocks may be blocks within the current picture, as well as blocks that were previously reconstructed by encoding or decoding, or both. Furthermore, the reconstructed block may be a block adjacent to the encoding/decoding target block, or a block located at an outer corner of the encoding/decoding target block, or both. Here, the block located at an outer corner of the encoding/decoding target block may be a block vertically adjacent to an adjacent block horizontally adjacent to the encoding/decoding target block. Alternatively, the block located at an outer corner of the encoding/decoding target block may be a block horizontally adjacent to an adjacent block vertically adjacent to the encoding/decoding target block.
编码设备100和解码设备200可分别确定存在于col画面内的与编码/解码目标块空间相关的位置处的块,并可基于确定的块来确定预定义的相对位置。所述预定义的相对位置可以是存在于与编码/解码目标块空间相关的位置处的块的内部位置或外部位置或者是内部位置和外部位置两者。此外,编码设备100和解码设备200可基于所确定的所述预定义的相对位置来分别推导col块。这里,col画面可以是在参考画面列表中包括的至少一个参考画面中的一个画面。The encoding device 100 and the decoding device 200 may each determine a block existing at a position spatially related to the encoding/decoding target block within the col picture, and may determine a predefined relative position based on the determined block. The predefined relative position may be an internal position or an external position or both an internal position and an external position of the block existing at a position spatially related to the encoding/decoding target block. Furthermore, the encoding device 100 and the decoding device 200 may respectively derive the col block based on the determined predefined relative position. Here, the col picture may be one picture among at least one reference picture included in the reference picture list.
推导运动信息的方法可根据编码/解码目标块的预测模式而变化。例如,被应用于帧间预测的预测模式可包括高级运动矢量预测(AMVP)、合并模式等。这里,合并模式可被称为运动合并模式。The method of deriving motion information may vary depending on the prediction mode of the encoding/decoding target block. For example, prediction modes applied to inter prediction may include advanced motion vector prediction (AMVP), merge mode, and the like. Here, the merging mode may be called a motion merging mode.
例如,当AMVP作为预测模式被应用时,编码设备100和解码设备200可分别通过使用重建邻近块的运动矢量或col块的运动矢量或两者来产生运动矢量候选列表。重建邻近块的运动矢量或col块的运动矢量或者两者可被用作运动矢量候选。这里,col块的运动矢量可被称为时间运动矢量候选,重建邻近块的运动矢量可被称为空间运动矢量候选。For example, when AMVP is applied as the prediction mode, the encoding device 100 and the decoding device 200 may generate a motion vector candidate list by using the motion vector of the reconstructed neighboring block or the motion vector of the col block, or both, respectively. The motion vector of the reconstructed neighboring block or the motion vector of the col block or both may be used as motion vector candidates. Here, the motion vector of the col block may be called a temporal motion vector candidate, and the motion vector of the reconstructed neighboring block may be called a spatial motion vector candidate.
编码设备100可产生比特流,比特流可包括运动矢量候选索引。也就是说,编码设备100可通过对运动矢量候选索引进行熵编码来产生比特流。运动矢量候选索引可指示从包括在运动矢量候选列表中的运动矢量候选中选择出的最优运动矢量候选。运动矢量候选索引可通过比特流从编码设备100被发送到解码设备200。The encoding device 100 may generate a bitstream, and the bitstream may include the motion vector candidate index. That is, the encoding device 100 may generate a bitstream by entropy encoding the motion vector candidate index. The motion vector candidate index may indicate an optimal motion vector candidate selected from the motion vector candidates included in the motion vector candidate list. The motion vector candidate index may be transmitted from the encoding device 100 to the decoding device 200 through a bit stream.
解码设备200可从比特流对运动矢量候选索引进行熵解码,并可通过使用经过熵解码的运动矢量候选索引在运动矢量候选列表中所包括的运动矢量候选之中选择解码目标块的运动矢量候选。The decoding device 200 may entropy-decode the motion vector candidate index from the bit stream, and may select the motion vector candidate of the decoding target block among the motion vector candidates included in the motion vector candidate list by using the entropy-decoded motion vector candidate index. .
编码设备100可计算解码目标块的运动矢量和运动矢量候选之间的运动矢量差(MVD),并对MVD进行熵编码。比特流可包括经过熵编码的MVD。MVD可通过比特流从编码设备100被发送到解码设备200。这里,解码设备200可对从比特流接收到的MVD进行熵解码。解码设备200可通过解码的MVD与运动矢量候选之和来推导解码目标块的运动矢量。The encoding device 100 may calculate a motion vector difference (MVD) between the motion vector of the decoding target block and the motion vector candidate, and entropy encode the MVD. The bitstream may include entropy-encoded MVD. The MVD may be transmitted from the encoding device 100 to the decoding device 200 through a bit stream. Here, the decoding device 200 may entropy decode the MVD received from the bitstream. The decoding device 200 may derive the motion vector of the decoding target block through the sum of the decoded MVD and the motion vector candidate.
比特流可包括指示参考画面的参考画面索引等,并且参考画面索引可被熵编码并通过比特流从编码设备100被发送到解码设备200。解码设备200可通过使用邻近块的运动信息来预测解码目标块的运动矢量,并可通过使用预测出的运动矢量以及运动矢量差来推导解码目标块的运动矢量。解码设备200可基于推导出的运动矢量和参考画面索引信息来产生解码目标块的预测块。The bitstream may include a reference picture index indicating the reference picture or the like, and the reference picture index may be entropy-encoded and transmitted from the encoding device 100 to the decoding device 200 through the bitstream. The decoding device 200 may predict the motion vector of the decoding target block by using motion information of neighboring blocks, and may derive the motion vector of the decoding target block by using the predicted motion vector and the motion vector difference. The decoding device 200 may generate a prediction block of the decoding target block based on the derived motion vector and the reference picture index information.
作为推导运动信息的另一方法,合并模式被使用。合并模式可意为多个块的运动的合并。合并模式可意为一个块的运动信息被应用于另一个块。当合并模式被应用时,编码设备100和解码设备200可分别通过使用重建邻近块的运动信息或col块的运动信息或两者来产生合并候选列表。运动信息可包括以下至少一个:1)运动矢量、2)参考画面索引、以及3)帧间预测指示符。预测指示符可指示单向(L0预测、L1预测)或双向。As another way to derive motion information, the merge mode is used. Merge mode may mean the merging of motions of multiple blocks. Merging mode may mean that the motion information of one block is applied to another block. When the merge mode is applied, the encoding device 100 and the decoding device 200 may generate the merge candidate list by using the motion information of the reconstructed neighboring block or the motion information of the col block, or both, respectively. The motion information may include at least one of: 1) motion vector, 2) reference picture index, and 3) inter prediction indicator. The prediction indicator may indicate unidirectional (L0 prediction, L1 prediction) or bidirectional.
这里,合并模式可被应用于每个CU或每个PU。当合并模式在每个CU或每个PU被执行时,编码设备100可通过对预定义的信息进行熵解码来产生比特流,并可将比特流发送到解码设备200。比特流可包括所述预定义的信息。所述预定义的信息可包括:1)作为指示合并模式是否针对每个块分区被执行的信息的合并标志、2)作为指示与编码目标块相邻的邻近块之中的哪个块被合并的信息的合并索引。例如,与编码目标块相邻的邻近块可包括编码目标块的左邻近块、编码目标块的上邻近块、编码目标块的时间邻近块等。Here, the merge mode can be applied to each CU or each PU. When the merge mode is performed on each CU or each PU, the encoding device 100 may generate a bit stream by entropy decoding predefined information, and may transmit the bit stream to the decoding device 200 . The bitstream may include the predefined information. The predefined information may include: 1) a merge flag as information indicating whether the merge mode is performed for each block partition, 2) as an indication which block among neighboring blocks adjacent to the encoding target block is merged A merged index of information. For example, the neighboring blocks adjacent to the encoding target block may include a left neighboring block of the encoding target block, an upper neighboring block of the encoding target block, a temporal neighboring block of the encoding target block, and the like.
合并候选列表可指示存储运动信息的列表。此外,合并候选列表可在执行合并模式之前被产生。存储在合并候选列表中的运动信息可以是以下运动信息中的至少一个:与编码/解码目标块相邻的邻近块的运动信息、参考画面中与编码/解码目标块相关的同位块的运动信息、通过对合并运动候选列表中存在的运动信息的预先组合而新产生的运动信息、以及零合并候选。这里,与编码/解码目标块相邻的邻近块的运动信息可被称为空间合并候选。参考画面中与编码/解码目标块相关的同位块的运动信息可被称为时间合并候选。The merge candidate list may indicate a list storing motion information. Additionally, a merge candidate list may be generated before executing the merge mode. The motion information stored in the merge candidate list may be at least one of the following motion information: motion information of neighboring blocks adjacent to the encoding/decoding target block, motion information of co-located blocks related to the encoding/decoding target block in the reference picture , motion information newly generated by pre-combination of motion information existing in the merge motion candidate list, and zero merge candidates. Here, motion information of neighboring blocks adjacent to the encoding/decoding target block may be referred to as spatial merging candidates. The motion information of co-located blocks related to the encoding/decoding target block in the reference picture may be called temporal merging candidates.
跳过模式可以是将邻近块本身的模式信息应用于编码/解码目标块的模式。跳过模式可以是用于帧间预测的模式之一。当跳过模式被使用时,编码设备100可对关于哪个块的运动信息被用作编码目标块的运动信息的信息进行熵编码,并可通过比特流将该信息发送到解码设备200。编码设备100可不将其它信息(例如,语法元素信息)发送到解码设备200。语法元素信息可包括运动矢量差信息、编码块标志以及变换系数等级中的至少一个。The skip mode may be a mode in which mode information of the adjacent block itself is applied to the encoding/decoding target block. Skip mode may be one of the modes used for inter prediction. When the skip mode is used, the encoding device 100 may entropy encode information about which block's motion information is used as the motion information of the encoding target block, and may transmit the information to the decoding device 200 through a bit stream. The encoding device 100 may not send other information (eg, syntax element information) to the decoding device 200 . The syntax element information may include at least one of motion vector difference information, coding block flags, and transform coefficient levels.
在帧内预测或帧间预测之后产生的残差信号可通过作为量化处理的一部分的变换处理被变换到频域。这里,首次变换可使用DCT类型2(DCT-II)以及各种DCT、DST内核。这些变换内核可对残差信号执行用于沿水平和/或垂直方向执行1D变换的可分离变换,或者可对残差信号执行2D不可分离变换。The residual signal generated after intra prediction or inter prediction can be transformed into the frequency domain through a transformation process as part of the quantization process. Here, the first transformation can use DCT type 2 (DCT-II) and various DCT and DST kernels. These transformation kernels may perform a separable transformation on the residual signal for performing ID transformations in the horizontal and/or vertical directions, or may perform a 2D non-separable transformation on the residual signal.
例如,在1D变换的情况下,在变换中使用的DCT和DST类型可使用如下表中所示的DCT-II、DCT-V、DCT-VIII、DST-I以及DST-VII。例如,如表1和表2中所示,可推导出通过合成变换集而在变换中使用的DCT或DST类型。For example, in the case of 1D transformation, the DCT and DST types used in the transformation may use DCT-II, DCT-V, DCT-VIII, DST-I, and DST-VII as shown in the following table. For example, as shown in Table 1 and Table 2, the DCT or DST type used in the transform can be derived by synthesizing the transform set.
[表1][Table 1]
[表2][Table 2]
例如,如图8所示,根据帧内预测模式,不同的变换集针对水平方向和垂直方向被定义。接下来,编码器/解码器可通过使用当前编码/解码目标块的帧内预测模式和相关变换集的变换来执行变换和/或逆变换。在这种情况下,不对变换集执行熵编码/解码,并且编码器/解码器可根据相同的规则来定义变换集。在这种情况下,指示变换集的变换之中的哪种变换被使用的熵编码/解码可被执行。例如,当块的大小等于或小于64×64时,根据帧内预测模式,如表2中所示三个变换集被合成,并且三个变换被用于每个水平方向变换和垂直方向变换以组合并执行总共九个多变换方法。接下来,通过使用最优变换方法来对残差信号进行编码/解码,由此,编码效率可被提高。这里,为了对关于一个变换集中的三个变换之中哪个变换方法被使用的信息执行熵编码/解码,可使用截断一元二值化。这里,为了进行垂直变换和水平变换中的至少一个,可对指示变换集的变换中的哪个变换被使用的信息执行熵编码/解码。For example, as shown in Figure 8, different transformation sets are defined for the horizontal and vertical directions according to the intra prediction mode. Next, the encoder/decoder may perform a transform and/or an inverse transform by using the intra prediction mode of the current encoding/decoding target block and the transform of the associated transform set. In this case, no entropy encoding/decoding is performed on the transform set, and the encoder/decoder can define the transform set according to the same rules. In this case, entropy encoding/decoding indicating which transform among the transforms of the transform set is used may be performed. For example, when the block size is equal to or smaller than 64×64, according to the intra prediction mode, three transform sets are synthesized as shown in Table 2, and three transforms are used for each horizontal direction transform and vertical direction transform to A total of nine multi-transform methods are combined and executed. Next, the residual signal is encoded/decoded by using the optimal transformation method, whereby the encoding efficiency can be improved. Here, in order to perform entropy encoding/decoding on information about which transform method is used among three transforms in one transform set, truncated unary binarization may be used. Here, in order to perform at least one of vertical transformation and horizontal transformation, entropy encoding/decoding may be performed on information indicating which transform among the transforms of the transform set is used.
在完成上述首次变换之后,如图9中所示,编码器可针对变换系数执行二次变换以提高能量集中度。二次变换可执行用于沿水平和/或垂直方向执行1D变换的可分离变换,或者可执行2D不可分离变换。所使用的变换信息可被发送,或者可被编码器/解码器根据当前编码信息和邻近编码信息而推导出。例如,如1D变换,用于二次变换的变换集可被定义。不对该变换集执行熵编码/解码,并且编码器/解码器可根据相同的规则定义变换集。在这种情况下,指示变换集的变换之中的哪个变换被使用的信息可被发送,并且该信息可通过帧内预测或帧间预测被应用于至少一个残差信号。After completing the above-mentioned first transformation, as shown in Figure 9, the encoder can perform a secondary transformation on the transformation coefficients to improve energy concentration. The secondary transformation may perform a separable transformation for performing ID transformation in the horizontal and/or vertical directions, or may perform a 2D non-separable transformation. The transformation information used may be sent, or may be derived by the encoder/decoder from the current encoding information and neighboring encoding information. For example, a transformation set for a quadratic transformation can be defined, such as a 1D transformation. No entropy encoding/decoding is performed on this transform set, and the encoder/decoder can define the transform set according to the same rules. In this case, information indicating which transform among the transforms of the transform set is used may be transmitted, and the information may be applied to at least one residual signal through intra prediction or inter prediction.
变换候选的数量或类型中的至少一个针对每个变换集而不同。变换候选的数量或类型中的至少一个可基于以下至少一个而被不同地确定:块(CU、PU、TU等)的位置、大小、分区形式、以及预测模式(帧内/帧间模式)或帧内预测模式的方向/非方向。At least one of the number or types of transformation candidates differs for each transformation set. At least one of the number or types of transform candidates may be variously determined based on at least one of: location, size, partition form, and prediction mode (intra/inter mode) of the block (CU, PU, TU, etc.) or Direction/non-direction of intra prediction mode.
解码器可依据二次逆变换是否被执行来执行二次逆变换,并可从二次逆变换的结果依据首次逆变换是否被执行来执行首次逆变换。The decoder may perform the second inverse transform according to whether the second inverse transform is performed, and may perform the first inverse transform from the result of the second inverse transform according to whether the first inverse transform is performed.
上述首次变换和二次变换可被应用于亮度/色度分量中的至少一个信号分量,或者可根据任意编码块的大小/形状被应用。可对指示首次变换/二次变换是否被使用以及任意编码块中的所使用的首次变换/二次变换两者的索引执行熵编码/解码。可选择地,所述索引可由编码器/解码器根据至少一条当前/邻近编码信息而默认推导。The above-described primary transformation and secondary transformation may be applied to at least one signal component among the luminance/chrominance components, or may be applied according to the size/shape of an arbitrary coding block. Entropy encoding/decoding may be performed on an index indicating whether the first transform/secondary transform is used and both the first transform/secondary transform used in any coding block. Alternatively, the index may be derived by default by the encoder/decoder based on at least one piece of current/nearby encoding information.
在帧内预测或帧间预测之后产生的残差信号在经过首次变换和/或二次变换之后经过量化处理,并且量化的变换系数经过熵编码处理。这里,如图10中所示,量化的变换系数可基于帧内预测模式或最小块的大小/形状中的至少一个,按照对角方向、垂直方向和水平方向被扫描。The residual signal generated after intra prediction or inter prediction is subjected to quantization processing after the first transformation and/or the second transformation, and the quantized transform coefficients are subjected to entropy coding processing. Here, as shown in FIG. 10 , the quantized transform coefficients may be scanned in a diagonal direction, a vertical direction, and a horizontal direction based on at least one of an intra prediction mode or a size/shape of a minimum block.
此外,执行了熵解码的量化的变换系数可通过被逆扫描而按照块形式被布置,并且可对相关块执行反量化或逆变换中的至少一个。这里,作为逆扫描的方法,对角方向扫描、水平方向扫描和垂直方向扫描中的至少一个可被执行。Furthermore, the quantized transform coefficients on which entropy decoding is performed may be arranged in a block form by being inversely scanned, and at least one of inverse quantization or inverse transformation may be performed on the relevant block. Here, as a method of reverse scanning, at least one of diagonal direction scanning, horizontal direction scanning, and vertical direction scanning may be performed.
例如,在当前编码块的大小为8×8时,可对针对8×8的块的残差信号执行首次变换、二次变换以及量化,接下来,可根据图10中示出的三种扫描顺序方法中的至少一种针对四个4×4的子块中的每一个对量化的变换系数执行扫描和熵编码。此外,可通过执行熵解码来对量化的变换系数执行逆扫描。执行了逆扫描的量化的变换系数在经过反量化之后成为变换系数,并且二次逆变换或首次逆变换中的至少一个被执行,由此,重建残差信号可被产生。For example, when the size of the current coding block is 8×8, the first transformation, the second transformation, and the quantization can be performed on the residual signal for the 8×8 block. Next, the residual signal can be scanned according to the three scans shown in FIG. 10 At least one of the sequential methods performs scan and entropy coding on the quantized transform coefficients for each of the four 4x4 sub-blocks. Furthermore, inverse scanning may be performed on the quantized transform coefficients by performing entropy decoding. The quantized transform coefficients on which inverse scanning has been performed become transform coefficients after being inversely quantized, and at least one of the second inverse transform or the first inverse transform is performed, whereby a reconstructed residual signal can be generated.
在视频编码处理中,一个块可如图11所示被分区,并且与分区信息相应的指示符可被用信号传送。这里,分区信息可以是以下至少一个:分区标志(split_flag)、四叉/二叉树标志(QB_flag)、四叉树分区标志(quadtree_flag)、二叉树分区标志(binarytree_flag)以及二叉树分区类型标志(Btype_flag)。这里,split_flag是指示块是否被分区的标志,QB_flag是指示块是按照四叉树形式还是按照二叉树形式被分区的标志,quadtree_flag是指示块是否按照四叉树形式被分区的标志,binarytree_flag是指示块是否按照二叉树形式被分区的标志,Btype_flag是指示在二叉树形式的分区的情况下块是被垂直分区还是被水平分区的标志。In the video encoding process, one block may be partitioned as shown in FIG. 11, and an indicator corresponding to the partition information may be signaled. Here, the partition information may be at least one of the following: partition flag (split_flag), quad/binary tree flag (QB_flag), quadtree partition flag (quadtree_flag), binary tree partition flag (binarytree_flag), and binary tree partition type flag (Btype_flag). Here, split_flag is a flag indicating whether the block is partitioned, QB_flag is a flag indicating whether the block is partitioned in the form of a quadtree or a binary tree, quadtree_flag is a flag indicating whether the block is partitioned in the form of a quadtree, and binarytree_flag is an indicator block A flag indicating whether the block is partitioned in the binary tree format. Btype_flag is a flag indicating whether the block is partitioned vertically or horizontally in the case of partitioning in the binary tree format.
当分区标志为1时,它可指示分区被执行,当分区标志为0时,它可指示分区不被执行。在四叉/二叉树标志的情况下,0可指示四叉树分区,并且1可指示二叉树分区。可选择地,0可指示二叉树分区,1可指示四叉树分区。在二叉树分区类型标志的情况下,0可指示水平方向分区,1可指示垂直方向分区。可选择地,0可指示垂直方向分区,1可指示水平方向分区。When the partition flag is 1, it may indicate that the partition is executed, and when the partition flag is 0, it may indicate that the partition is not executed. In the case of the quad/binary tree flag, 0 may indicate quadtree partitioning, and 1 may indicate binary tree partitioning. Alternatively, 0 may indicate binary tree partitioning and 1 may indicate quadtree partitioning. In the case of the binary tree partition type flag, 0 may indicate horizontal partitioning and 1 may indicate vertical partitioning. Alternatively, 0 may indicate vertical partitioning and 1 may indicate horizontal partitioning.
例如,可通过将如表3中示出的quadtree_flag、binarytree_flag和Btype_flag中的至少一个用信号传送来推导图11的分区信息。For example, the partition information of Figure 11 may be derived by signaling at least one of quadtree_flag, binarytree_flag, and Btype_flag as shown in Table 3.
[表3][table 3]
例如,可通过将如表4中示出的split_flag、QB_flag和Btype_flag中的至少一个用信号传送来推导图11的分区信息。For example, the partition information of FIG. 11 may be derived by signaling at least one of split_flag, QB_flag, and Btype_flag as shown in Table 4.
[表4][Table 4]
可根据块的大小/形状仅按照四叉树形式或仅按照二叉树形式来执行分区方法。在这种情况下,split_flag可意为指示是按照四叉树形式还是按照二叉树形式执行分区的标志。块的大小/形状可根据块的深度信息来推导,并且深度信息可被用信号传送。The partitioning method can be performed only in quadtree form or only in binary tree form depending on the size/shape of the block. In this case, split_flag may mean a flag indicating whether partitioning is performed in a quadtree form or a binary tree form. The size/shape of the block can be derived from the depth information of the block, and the depth information can be signaled.
当块的大小在预定范围中时,可仅按照四叉树形式执行分区。这里,所述预定范围可被定义为仅能够按照四叉树形式被分区的最大块的大小或最小块的大小中的至少一个。可通过比特流用信号传送指示允许四叉树形式的分区的最大块/最小块的大小的信息,并且可以以序列、画面参数或条带(分段)中的至少一个为单位用信号传送该信息。可选择地,最大块/最小块的大小可以是在编码器/解码器中预设的固定大小。例如,当块的大小的范围是256x256至64x64时,可仅按照四叉树形式执行分区。在这种情况下,split_flag可以是指示是否按照四叉树形式执行分区的标志。When the block size is within a predetermined range, partitioning can be performed only in the quadtree form. Here, the predetermined range may be defined as at least one of a maximum block size or a minimum block size that can be partitioned only in a quadtree form. Information indicating a maximum/minimum block size allowing partitioning in a quad-tree form may be signaled through a bit stream, and may be signaled in units of at least one of a sequence, a picture parameter, or a slice (segment) . Alternatively, the maximum block/minimum block size may be a fixed size preset in the encoder/decoder. For example, when the block size ranges from 256x256 to 64x64, partitioning may be performed only in the quadtree form. In this case, split_flag may be a flag indicating whether to perform partitioning in the form of a quadtree.
当块的大小在预定范围中时,可仅按照二叉树形式执行分区。这里,所述预定范围可被定义为仅能够按照二叉树形式被分区的最大块的大小或最小块的大小中的至少一个。可通过比特流用信号传送指示允许二叉树形式的分区的最大块/最小块的大小的信息,并且可以以序列、画面参数或条带(分段)中的至少一个为单位而用信号传送该信息。可选择地,最大块/最小块的大小可以是在编码器/解码器中预设的固定大小。例如,当块的大小的范围是16x16至8x8时,可仅按照二叉树形式执行分区。在这种情况下,split_flag可以是指示是否按照二叉树形式执行分区的标志。When the size of the block is within a predetermined range, partitioning can be performed only in the form of a binary tree. Here, the predetermined range may be defined as at least one of a maximum block size or a minimum block size that can be partitioned only in a binary tree form. Information indicating a maximum/minimum block size allowing partitioning in the form of a binary tree may be signaled through a bit stream, and may be signaled in units of at least one of a sequence, a picture parameter, or a slice (segment). Alternatively, the maximum block/minimum block size may be a fixed size preset in the encoder/decoder. For example, when the block size ranges from 16x16 to 8x8, partitioning may be performed only in a binary tree form. In this case, split_flag may be a flag indicating whether to perform partitioning in the form of a binary tree.
在按照二叉树形式对一个块进行分区之后,当分区出的块被进一步分区时,可仅按照二叉树形式执行分区。After a block is partitioned in the binary tree form, when the partitioned block is further partitioned, the partitioning can be performed only in the binary tree form.
当分区出的块的宽度大小或长度大小不能被进一步分区时,至少一个指示符可不被用信号传送。At least one indicator may not be signaled when the width size or length size of the partitioned block cannot be further partitioned.
除了基于四叉树的二叉树分区以外,基于四叉树的分区可在二叉树分区以后被执行。In addition to quadtree-based binary tree partitioning, quadtree-based partitioning may be performed after binary tree partitioning.
图12是描绘根据本发明的实施例的用于对当前块执行帧内预测的方法的示图。FIG. 12 is a diagram depicting a method for performing intra prediction on a current block according to an embodiment of the present invention.
如图12中所示,帧内预测可包括:推导帧内预测模式(S1210),构建参考样点(S1220),和/或执行帧内预测(S1230)。As shown in FIG. 12, intra prediction may include deriving an intra prediction mode (S1210), constructing reference samples (S1220), and/or performing intra prediction (S1230).
在推导帧内预测模式的步骤(S1210)中,可使用邻近块的帧内预测模式,可从比特流解码(例如,熵解码)当前块的帧内预测模式,可使用利用变换模型的帧内预测模式来推导当前块的颜色分量的帧内预测模式和/或当前块的帧内预测模式。或者,在推导帧内预测模式的步骤(S1210)中,可使用邻近块的帧内预测模式、邻近块的一个或更多个帧内预测模式的组合、和/或通过MPM推导出的帧内预测模式来推导当前块的帧内预测模式。In the step of deriving the intra prediction mode (S1210), the intra prediction mode of the neighboring block may be used, the intra prediction mode of the current block may be decoded (eg, entropy decoded) from the bit stream, the intra prediction mode using the transform model may be used prediction mode to derive the intra prediction mode of the color component of the current block and/or the intra prediction mode of the current block. Alternatively, in the step of deriving the intra prediction mode (S1210), the intra prediction mode of the neighboring block, a combination of one or more intra prediction modes of the neighboring block, and/or the intra prediction mode derived by MPM may be used. prediction mode to derive the intra prediction mode of the current block.
在构建参考样点的步骤(S1220)中,可通过执行参考样点选择和/或参考样点滤波来构建参考样点。In the step of constructing reference samples (S1220), the reference samples may be constructed by performing reference sample selection and/or reference sample filtering.
在执行帧内预测的步骤(S1230)中,可使用非方向预测、方向预测、基于位置信息的预测、颜色分量之间的预测和/或残差信号预测来针对当前块执行帧内预测。在执行帧内预测的步骤(S1230)中,可对预测样点另外地执行滤波。如果执行方向预测,则可根据一个或更多个样点单元执行不同方向预测。例如,所述一个或更多个样点单元可以是单个样点、样点组、线和/或子块。In the step of performing intra prediction (S1230), intra prediction may be performed for the current block using non-directional prediction, directional prediction, prediction based on position information, prediction between color components, and/or residual signal prediction. In the step of performing intra prediction (S1230), filtering may be additionally performed on the prediction samples. If directional prediction is performed, different directional predictions may be performed based on one or more sample units. For example, the one or more sample units may be single samples, groups of samples, lines, and/or sub-blocks.
在下文中,将更加详细地描述推导帧内预测模式的步骤(S1210)。Hereinafter, the step of deriving the intra prediction mode (S1210) will be described in more detail.
如上所述,为了推导当前块的帧内预测模式,可使用以下方法中的至少一种方法:用于使用一个或更多个邻近块的帧内预测模式的方法、用于从比特流解码当前块的帧内预测模式的方法、用于使用邻近块的编码参数的方法、以及用于使用颜色分量之间的帧内预测模式的方法。邻近块可以是在当前块的编码/解码之前被重建的一个或更多个块。As described above, in order to derive the intra prediction mode of the current block, at least one of the following methods may be used: a method for using the intra prediction mode of one or more neighboring blocks, a method for decoding the current block from the bitstream Methods for intra prediction modes of blocks, methods for using coding parameters of neighboring blocks, and methods for using intra prediction modes between color components. Neighboring blocks may be one or more blocks that were reconstructed before encoding/decoding of the current block.
如果邻近块位于至少一个预定单元(诸如画面、条带、并行块和编码树单元(CTU)的边界外部,或者PCM模式或帧间预测已被应用于该邻近块,则可确定该邻近块不可用。可利用DC模式、平面模式或预定帧内预测模式来替换与不可用的邻近块相应的帧内预测模式。If the neighboring block is located outside the boundary of at least one predetermined unit such as a picture, a slice, a tile, and a coding tree unit (CTU), or a PCM mode or inter prediction has been applied to the neighboring block, it may be determined that the neighboring block is not Use. The intra prediction mode corresponding to the unavailable neighboring block may be replaced with a DC mode, a planar mode, or a predetermined intra prediction mode.
当前块的大小可以是W×H,其中,W和H是正整数并且可以相等或不同。W和/或H可以是例如2、4、8、16、32、64、128、256和512中的至少一个。The size of the current block may be W×H, where W and H are positive integers and may be equal or different. W and/or H may be at least one of 2, 4, 8, 16, 32, 64, 128, 256 and 512, for example.
图13是描绘用于从邻近块推导当前块的帧内预测模式的方法的示图。Figure 13 is a diagram depicting a method for deriving an intra prediction mode of a current block from neighboring blocks.
在图13中,在邻近块上标记的a至k可表示邻近块的帧内预测模式或者帧内预测模式的编号。用于推导当前块的帧内预测模式的邻近块的位置可以是预定义的固定位置。或者,可通过编码/解码来推导关于邻近块的位置的信息。在本公开中,编码/解码可包括熵编码和熵解码。In FIG. 13 , a to k marked on neighboring blocks may represent intra prediction modes or numbers of intra prediction modes of the neighboring blocks. The positions of neighboring blocks used to derive the intra prediction mode of the current block may be predefined fixed positions. Alternatively, information about the positions of neighboring blocks may be derived through encoding/decoding. In the present disclosure, encoding/decoding may include entropy encoding and entropy decoding.
在邻近块的帧内预测模式被使用的情况下,邻近块的特定模式可被推导作为当前块的帧内预测模式。例如,与当前块的样点(0,0)相邻的左侧样点(-1,0)所属于的邻近块的帧内预测模式i可被推导作为当前块的帧内预测模式。或者,与当前块的样点(0,0)相邻的上方样点(0,-1)所属于的邻近块的帧内预测模式f可被推导作为当前块的帧内预测模式。或者,与当前块的样点(0,0)相邻的左上方样点(-1,-1)所属于的邻近块的帧内预测模式b可被推导作为当前块的帧内预测模式。或者,与当前块的样点(W-1,0)相邻的上方样点(W-1,-1)所属于的邻近块的帧内预测模式g可被推导作为当前块的帧内预测模式。或者,与当前块的样点(W-1,0)相邻的右上方样点(W,-1)所属于的邻近块的帧内预测模式k可被推导作为当前块的帧内预测模式。或者,与当前块的样点(0,H-1)相邻的左侧样点(1,H-1)所属于的邻近块的帧内预测模式j可被推导作为当前块的帧内预测模式。或者,与当前块的样点(0,H-1)相邻的左下方样点(-1,H)所属于的邻近块的帧内预测模式l可被推导作为当前块的帧内预测模式。或者,邻近块之中的位于预定位置处的邻近块的帧内预测模式可被推导作为当前块的帧内预测模式。例如,所述预定位置可被编码/从比特流解码,或者可基于编码参数被推导出。例如,所述预定位置可以是具有帧内预测模式e的块。In the case where the intra prediction mode of the neighboring block is used, the specific mode of the neighboring block may be derived as the intra prediction mode of the current block. For example, the intra prediction mode i of the neighboring block to which the left sample point (-1,0) adjacent to the sample point (0,0) of the current block belongs, may be derived as the intra prediction mode of the current block. Alternatively, the intra prediction mode f of the neighboring block to which the upper sample point (0,-1) adjacent to the sample point (0,0) of the current block belongs can be derived as the intra prediction mode of the current block. Alternatively, the intra prediction mode b of the neighboring block to which the upper left sample point (-1, -1) adjacent to the sample point (0,0) of the current block belongs, may be derived as the intra prediction mode of the current block. Alternatively, the intra prediction mode g of the neighboring block to which the upper sample point (W-1,-1) adjacent to the sample point (W-1,0) of the current block belongs can be derived as the intra prediction of the current block model. Alternatively, the intra prediction mode k of the neighboring block to which the upper right sample point (W, -1) adjacent to the sample point (W-1,0) of the current block belongs can be derived as the intra prediction mode of the current block . Alternatively, the intra prediction mode j of the neighboring block to which the left sample (1, H-1) adjacent to the sample (0, H-1) of the current block belongs can be derived as the intra prediction of the current block model. Alternatively, the intra prediction mode l of the neighboring block to which the lower left sample point (-1, H) adjacent to the sample point (0, H-1) of the current block belongs can be derived as the intra prediction mode of the current block . Alternatively, the intra prediction mode of a neighboring block located at a predetermined position among neighboring blocks may be derived as the intra prediction mode of the current block. For example, the predetermined position may be encoded/decoded from the bitstream, or may be derived based on encoding parameters. For example, the predetermined position may be a block with intra prediction mode e.
或者,可选择当前块的邻近块中的一个或更多个。可基于通过比特流显式地用信号传送的信息来进行所述选择。或者,可根据编码器和解码器之间预设的准则来进行所述选择。可从所选择的一个或更多个邻近块的帧内预测模式推导当前块的帧内预测模式。例如,可使用所选择的邻近块的帧内预测模式的统计值来推导当前块的帧内预测模式。例如,所述统计值可包括最小值、最大值、平均值、加权平均值、最频繁值和/或中值。Alternatively, one or more of the neighboring blocks of the current block may be selected. The selection may be made based on information explicitly signaled through the bitstream. Alternatively, the selection may be made based on preset criteria between the encoder and decoder. The intra prediction mode of the current block may be derived from the intra prediction modes of the selected one or more neighboring blocks. For example, the intra prediction mode of the current block may be derived using statistical values of the selected intra prediction modes of neighboring blocks. For example, the statistical value may include a minimum value, a maximum value, an average value, a weighted average value, a most frequent value, and/or a median value.
例如,可将在与当前块的样点(0,0)相邻的左侧样点和上方样点所属于的邻近块的帧内预测模式i和f之中具有较小模式编号或者较大模式编号的模式推导作为当前块的帧内预测模式。例如,如果所选择的邻近块的帧内预测模式是b、f、g、i和j,则可将具有帧内预测模式的模式编号中的最小值的模式推导作为当前块的帧内预测模式。例如,如果所选择的邻近块的帧内预测模式是i、b和f,则可将具有帧内预测模式的模式编号的中值的模式推导作为当前块的帧内预测模式。例如,可将与当前块相邻的邻近块的帧内预测模式中的最频繁的一个推导作为当前块的帧内预测模式。For example, among the intra prediction modes i and f of the adjacent blocks to which the left sample adjacent to the sample (0,0) of the current block and the upper sample belong, the smaller mode number or the larger The mode of the mode number is derived as the intra prediction mode of the current block. For example, if the selected intra prediction modes of neighboring blocks are b, f, g, i, and j, the mode with the smallest value among the mode numbers of the intra prediction modes may be derived as the intra prediction mode of the current block . For example, if the selected intra prediction modes of neighboring blocks are i, b, and f, the mode with the median value of the mode numbers of the intra prediction modes may be derived as the intra prediction mode of the current block. For example, the most frequent one of the intra prediction modes of neighboring blocks adjacent to the current block may be derived as the intra prediction mode of the current block.
或者,通过对一个或更多个邻近块的帧内预测模式进行组合来推导当前块的帧内预测模式。帧内预测模式可被表示为模式编号、模式值和模式角度中的至少一个。例如,邻近块的一个或更多个帧内预测模式的平均值可被推导作为当前块的帧内预测模式。两个帧内预测模式的平均值可表示在两个模式编号之间的中位数、两个模式值的中值、以及在两个模式角度之间的中间角度中的至少一个。Alternatively, the intra prediction mode of the current block is derived by combining the intra prediction modes of one or more neighboring blocks. The intra prediction mode may be expressed as at least one of a mode number, a mode value, and a mode angle. For example, the average of one or more intra prediction modes of neighboring blocks may be derived as the intra prediction mode of the current block. The average of two intra prediction modes may represent at least one of a median between two mode numbers, a median of two mode values, and an intermediate angle between two mode angles.
例如,可将与和当前块的样点(0,0)相邻的左侧样点和上方样点所属于的邻近块的帧内预测模式i和f的模式值的平均值相应的模式推导作为当前块的帧内预测模式。例如,可通过在[等式1]中描述的方法(1)、方法(2)和方法(3)中的至少一个来推导当前块的帧内预测模式Pred_mode。For example, a mode corresponding to the average of the mode values of the intra prediction modes i and f of the neighboring blocks to which the left sample and the upper sample belong adjacent to sample (0,0) of the current block can be derived. As the intra prediction mode of the current block. For example, the intra prediction mode Pred_mode of the current block may be derived by at least one of method (1), method (2), and method (3) described in [Equation 1].
[等式1][Equation 1]
Pred_mode=(i+f)>>1(1)Pred_mode=(i+f)>>1(1)
Pred_mode=(i+f+1)>>1(2)Pred_mode=(i+f+1)>>1(2)
Pred_mode=(i+f)/2(3)Pred_mode=(i+f)/2(3)
或者,如果邻近块的帧内预测模式i是非方向模式,则当前块的帧内预测模式可被推导为帧内预测模式i。或者,如果邻近块的帧内预测模式f是方向模式,则当前块的帧内预测模式可被推导为帧内预测模式f。Alternatively, if the intra prediction mode i of a neighboring block is a non-directional mode, the intra prediction mode of the current block may be derived as intra prediction mode i. Alternatively, if the intra prediction mode f of the neighboring block is the direction mode, the intra prediction mode of the current block may be derived as the intra prediction mode f.
或者,当前块的帧内预测模式可被推导为与邻近块的帧内预测模式b、f、g、i和j的模式值中的至少一个的平均值相应的模式。例如,可通过在[等式2]中描述的方法(1)、方法(2)、方法(3)和方法(4)中的至少一个来推导当前块的帧内预测模式Pred_mode。Alternatively, the intra prediction mode of the current block may be derived as a mode corresponding to an average of at least one of mode values of intra prediction modes b, f, g, i, and j of neighboring blocks. For example, the intra prediction mode Pred_mode of the current block may be derived by at least one of method (1), method (2), method (3), and method (4) described in [Equation 2].
[等式2][Equation 2]
Pred_mode=(f+g+i+j+2)>>2(1)Pred_mode=(f+g+i+j+2)>>2(1)
Pred_mode=(b+f+g+i+j)/5(2)Pred_mode=(b+f+g+i+j)/5(2)
Pred_mode=(i+f+k+l+2)>>2(3)Pred_mode=(i+f+k+l+2)>>2(3)
Pred_mode=(b+f+k+i+l)/5(4)Pred_mode=(b+f+k+i+l)/5(4)
或者,与附近的邻近块的可用帧内预测模式的平均值相应的模式可被推导作为当前块的帧内预测模式。例如,如果当前块的左侧邻近块位于画面、并行块、条带和/或CTU的边界外部,或者,当前块的左侧邻近块与PCM模式或帧间预测模式中的至少一个相应并因此不可用,则可将与上方邻近块的帧内预测模式(例如,f和g)的统计值相应的模式推导作为当前块的帧内预测模式。Alternatively, a mode corresponding to the average of available intra prediction modes of nearby neighboring blocks may be derived as the intra prediction mode of the current block. For example, if the left neighboring block of the current block is located outside the boundary of the picture, tile, slice and/or CTU, or the left neighboring block of the current block corresponds to at least one of the PCM mode or the inter prediction mode and therefore is not available, then the mode corresponding to the statistical value of the intra prediction mode (eg, f and g) of the upper neighboring block may be derived as the intra prediction mode of the current block.
例如,加权平均值或加权和可被用作邻近块的帧内预测模式的统计值。这里,可基于邻近块的帧内预测模式的方向性来分配权重。例如,可预定义或用信号传送被分配了相对大的权重的模式。例如,被分配了相对大的权重的模式可以是垂直方向模式、水平方向模式和非方向模式中的至少一个模式。可对这些模式分配相同权重或不同权重。例如,帧内预测模式i和f的加权和可通过下面的[等式3]被推导作为当前块的帧内预测模式Pred_mode。在下面的[等式3]中,模式f可以是被分配了相对大的权重的模式(例如,垂直方向模式)。For example, a weighted average or a weighted sum may be used as the statistical value of the intra prediction mode of neighboring blocks. Here, weights may be assigned based on the directionality of intra prediction modes of neighboring blocks. For example, patterns that are assigned relatively large weights may be predefined or signaled. For example, the mode to which a relatively large weight is assigned may be at least one of a vertical direction mode, a horizontal direction mode, and a non-directional mode. These modes can be assigned the same weight or different weights. For example, the weighted sum of intra prediction modes i and f can be derived as the intra prediction mode Pred_mode of the current block by [Equation 3] below. In [Equation 3] below, the mode f may be a mode to which a relatively large weight is assigned (for example, a vertical direction mode).
[等式3][Equation 3]
Pred_mode=(i+3*f+2)>>2Pred_mode=(i+3*f+2)>>2
或者,可基于邻近块的大小来确定将被用于加权和的权重。例如,如果与当前块相邻的上方块的大小大于与当前块相邻的左侧块的大小,则可将较大的权重分配给上方相邻块的帧内预测模式。或者,可将较大的权重分配给较小的邻近块的帧内预测模式。Alternatively, the weights to be used for the weighted sum may be determined based on the size of neighboring blocks. For example, if the size of the upper block adjacent to the current block is larger than the size of the left block adjacent to the current block, a larger weight may be assigned to the intra prediction mode of the upper adjacent block. Alternatively, larger weights may be assigned to intra prediction modes of smaller neighboring blocks.
或者,如果邻近块的一个或更多个帧内预测模式是非方向模式,则该非方向模式可被推导作为当前块的帧内预测模式。或者,可使用除了非方向模式之外的邻近块的帧内预测模式来推导当前块的帧内预测模式。如果邻近块的帧内预测模式全部都是非方向模式,则当前块的帧内预测模式可被推导为DC模式或平面模式中的至少一个。Alternatively, if one or more intra prediction modes of neighboring blocks are non-directional modes, the non-directional mode may be derived as the intra prediction mode of the current block. Alternatively, the intra prediction mode of the current block may be derived using the intra prediction modes of neighboring blocks in addition to the non-directional mode. If the intra prediction modes of neighboring blocks are all non-directional modes, the intra prediction mode of the current block may be derived as at least one of DC mode or planar mode.
或者,可使用基于邻近块的帧内预测模式的最可能模式(MPM)来推导当前块的帧内预测模式。如果MPM被使用,则关于当前块的帧内预测模式的一条或更多条信息可被编码/解码。Alternatively, the intra prediction mode of the current block may be derived using a most probable mode (MPM) based on the intra prediction modes of neighboring blocks. If MPM is used, one or more pieces of information about the intra prediction mode of the current block may be encoded/decoded.
如果MPM被使用,则MPM列表可被构造。MPM列表可包括基于邻近块的帧内预测模式推导出的帧内预测模式。MPM列表可包括N个候选模式。N是正整数,并且可依据当前块的大小和/或形状而变化。或者,可通过比特流用信号传送关于N的信息。If MPM is used, an MPM list can be constructed. The MPM list may include intra prediction modes derived based on intra prediction modes of neighboring blocks. The MPM list may include N candidate patterns. N is a positive integer and may vary depending on the size and/or shape of the current block. Alternatively, information about N may be signaled via a bitstream.
例如,使用邻近块的一个或更多个帧内预测模式推导出的当前块的帧内预测模式可以是MPM列表中包括的候选模式。For example, the intra prediction mode of the current block derived using one or more intra prediction modes of neighboring blocks may be a candidate mode included in the MPM list.
在图13中示出的示例中,可使用与当前块相邻的(-1,H-1)、(W-1,-1)、(W,-1)、(-1,H)和(-1,-1)相同位置处的邻近块的帧内预测模式,例如,可按照j、g、平面、DC、l、k和b的顺序来制作MPM列表。或者,可按照i、f、平面、DC、l、k和b的顺序来制作MPM列表。重复模式在MPM列表中可被包括一次。如果MPM列表由于存在重复模式而未被填满,则可基于列表中包括的模式将另外的候选模式包括在列表中。例如,可将与列表中包括的模式的+N或-N(N是正整数,例如,1)相应的模式添加到列表中。或者,可将水平模式、垂直模式、45度模式、135度模式和225度模式之中的在列表中未包括的模式中的至少一个模式添加到列表中。或者,可使用邻近块的多于1个的帧内预测模式的组合和/或统计值来构建MPM列表。In the example shown in Figure 13, (-1,H-1), (W-1,-1), (W,-1), (-1,H) and (-1,-1) Intra prediction modes of adjacent blocks at the same position, for example, the MPM list can be made in the order of j, g, plane, DC, l, k and b. Alternatively, the MPM list can be made in the order of i, f, plane, DC, l, k, and b. Repeating patterns may be included once in the MPM list. If the MPM list is not filled due to the presence of duplicate patterns, additional candidate patterns may be included in the list based on the patterns included in the list. For example, a pattern corresponding to +N or -N (N is a positive integer, eg, 1) of the patterns included in the list may be added to the list. Alternatively, at least one mode not included in the list among the horizontal mode, the vertical mode, the 45-degree mode, the 135-degree mode, and the 225-degree mode may be added to the list. Alternatively, the MPM list may be constructed using a combination of more than 1 intra prediction modes of neighboring blocks and/or statistical values.
可存在多个MPM列表,并且用于构建每个MPM列表的方法可彼此不同。例如,可构建3个MPM列表(MPM列表1、MPM列表2和MPM列表3)。在这种情况下,在每个MPM列表中包括的帧内预测模式可以不重复。Multiple MPM lists may exist, and the methods used to construct each MPM list may differ from each other. For example, 3 MPM lists (MPM list 1, MPM list 2, and MPM list 3) can be constructed. In this case, the intra prediction modes included in each MPM list may not be repeated.
指示在推导出的MPM列表中是否存在与当前块的帧内预测模式相同的模式的指示符(例如,prev_intra_luma_pred_flag)可被编码在比特流中或者可从比特流解码。An indicator (eg, prev_intra_luma_pred_flag) indicating whether the same mode as the intra prediction mode of the current block exists in the derived MPM list may be encoded in the bitstream or may be decoded from the bitstream.
如果所述指示符指示在MPM列表中存在与当前块的帧内预测模式相同的模式,则指示该模式是MPM列表中包括的模式之中的哪个模式的索引信息(例如,mpm_idx)可被编码在比特流中或者从比特流解码。可基于解码出的索引信息来推导当前块的帧内预测模式。If the indicator indicates that the same mode as the intra prediction mode of the current block exists in the MPM list, index information (eg, mpm_idx) indicating which mode among the modes included in the MPM list the mode is may be encoded Decode in or from the bitstream. The intra prediction mode of the current block may be derived based on the decoded index information.
如果所述指示符指示在MPM列表中不存在与当前块的帧内预测模式相同的模式,则关于当前块的帧内预测模式的信息可被编码在比特流中或从比特流解码。可基于解码出的关于当前块的帧内预测模式的信息来推导当前块的帧内预测模式。这里,在MPM列表中未包括的帧内预测模式可按照升序或降序中的至少一个被排列。或者,在MPM列表中未包括的帧内预测模式中的一个或更多个可被分成一个或更多个组。例如,与MPM列表中包括的帧内预测模式的+N或-N(N是正整数,例如,1、2或3)相应的模式可被分组成一个组。这里,该组可包括预定数量(例如,8或16)个帧内预测模式,并且在该组中包括的模式可不被包括在MPM列表中。If the indicator indicates that the same mode as the intra prediction mode of the current block does not exist in the MPM list, information about the intra prediction mode of the current block may be encoded in or decoded from the bitstream. The intra prediction mode of the current block may be derived based on the decoded information about the intra prediction mode of the current block. Here, intra prediction modes not included in the MPM list may be arranged in at least one of ascending order or descending order. Alternatively, one or more intra prediction modes not included in the MPM list may be divided into one or more groups. For example, modes corresponding to +N or -N (N is a positive integer, such as 1, 2, or 3) of intra prediction modes included in the MPM list may be grouped into a group. Here, the group may include a predetermined number (eg, 8 or 16) of intra prediction modes, and the modes included in the group may not be included in the MPM list.
或者,如上所述,当存在多个MPM列表时,所述指示符(例如,prev_intra_luma_pred_flag)可指示在MPM列表1中是否存在与当前块的帧内预测模式相同的模式。在所述指示符指示在MPM列表1中不存在与当前块的帧内预测模式相同的模式的情况下,可确定在MPM列表2中是否存在与当前块的帧内预测模式相同的模式。在MPM列表2中存在与当前块的帧内预测模式相同的模式的情况下,相应模式可被推导作为当前块的帧内预测模式。在MPM列表2中不存在与当前块的帧内预测模式相同的模式的情况下,可执行针对MPM列表3的确定。利用与以上方法相同的方法,可按顺序执行针对多个MPM列表的确定。Alternatively, as described above, when there are multiple MPM lists, the indicator (eg, prev_intra_luma_pred_flag) may indicate whether the same mode as the intra prediction mode of the current block exists in MPM list 1. In the case where the indicator indicates that the same mode as the intra prediction mode of the current block does not exist in the MPM list 1, it may be determined whether the same mode as the intra prediction mode of the current block exists in the MPM list 2. In the case where the same mode as the intra prediction mode of the current block exists in the MPM list 2, the corresponding mode may be derived as the intra prediction mode of the current block. In the case where the same mode as the intra prediction mode of the current block does not exist in MPM list 2, determination for MPM list 3 may be performed. Determination for multiple MPM lists can be performed sequentially using the same method as above.
或者,可发送指示多个MPM列表之一的单独信息。在这种情况下,可通过使用由所述单独信息指示的MPM列表以及所述指示符(例如prev_intra_luma_pred_flag)来推导当前块的帧内预测模式。Alternatively, a separate message indicating one of multiple MPM lists may be sent. In this case, the intra prediction mode of the current block can be derived by using the MPM list indicated by the separate information and the indicator (eg, prev_intra_luma_pred_flag).
或者,在推导出的MPM列表中的预定候选可被推导作为当前块的帧内预测模式。例如,与列表0相应的模式(即,MPM列表中的第一模式)可被推导作为当前块的帧内预测模式。或者,与列表中的预定模式相应的索引可被编码/解码,并且相应模式可被推导作为当前块的帧内预测模式。Alternatively, a predetermined candidate in the derived MPM list may be derived as the intra prediction mode of the current block. For example, the mode corresponding to list 0 (ie, the first mode in the MPM list) may be derived as the intra prediction mode of the current block. Alternatively, an index corresponding to a predetermined mode in the list may be encoded/decoded, and the corresponding mode may be derived as the intra prediction mode of the current block.
关于MPM列表的构造,可针对预定大小的块制作一个MPM列表。如果所述预定大小的块被划分为多个子块,则所述多个子块中的每个子块可使用该MPM列表。Regarding the construction of the MPM list, one MPM list can be made for blocks of a predetermined size. If the predetermined size block is divided into a plurality of sub-blocks, each of the plurality of sub-blocks may use the MPM list.
例如,如果当前块与所述预定大小的块相应,则可针对当前块制作MPM列表。如果当前块被划分为一个或更多个子块,则可使用该MPM列表针对每个子块推导帧内预测模式。例如,如果当前块的大小为8×8并且被划分为四个4×4的子块,则可针对当前块制作MPM列表,并且可将该MPM列表用于每个子块。For example, if the current block corresponds to the predetermined size block, an MPM list may be made for the current block. If the current block is divided into one or more sub-blocks, the MPM list can be used to derive the intra prediction mode for each sub-block. For example, if the size of the current block is 8×8 and is divided into four 4×4 sub-blocks, an MPM list can be made for the current block and the MPM list can be used for each sub-block.
关于MPM列表的构造,可针对预定大小的块被划分成的多个子块中的每个子块制作MPM列表。Regarding the construction of the MPM list, the MPM list may be made for each of a plurality of sub-blocks into which a block of a predetermined size is divided.
例如,如果当前块与所述预定大小的块相应,则可使用当前块的邻近块的帧内预测模式针对当前块的每个子块制作MPM列表。例如,如果当前块的大小是8×8并且存在四个4×4的子块,则可使用当前块的邻近块的帧内预测模式针对四个子块中的每个子块制作MPM列表。因此,可同时针对四个子块制作MPM列表。For example, if the current block corresponds to the predetermined size block, an MPM list may be made for each sub-block of the current block using intra prediction modes of neighboring blocks of the current block. For example, if the size of the current block is 8×8 and there are four 4×4 sub-blocks, an MPM list may be made for each of the four sub-blocks using the intra prediction modes of neighboring blocks of the current block. Therefore, MPM lists can be made for four sub-blocks at the same time.
或者,可使用通过MPM推导出的当前块的帧内预测模式以及邻近块的帧内预测模式中的至少一个来推导当前块的帧内预测模式。Alternatively, the intra prediction mode of the current block may be derived using at least one of the intra prediction mode of the current block derived through the MPM and the intra prediction modes of neighboring blocks.
例如,如果通过MPM推导出的当前块的帧内预测模式是Pred_mpm,则可通过使用邻近块的一个或更多个帧内预测模式,将Pred_mpm改变为特定模式来推导当前块的帧内预测模式。For example, if the intra prediction mode of the current block derived by MPM is Pred_mpm, the intra prediction mode of the current block can be derived by changing Pred_mpm to a specific mode using one or more intra prediction modes of neighboring blocks. .
例如,通过对Pred_mpm与邻近块的帧内预测模式比较大小,可将Pred_mpm增大N或减小N。这里,N可以是预定整数,诸如+1、+2、+3、0、-1、-2或-3。例如,如果Pred_mpm小于邻近块的帧内预测模式和/或一个或更多个邻近块的帧内预测模式的统计值,则Pred_mpm可被增大。或者,如果Pred_mpm大于邻近块的帧内预测模式,则Pred_mpm可被减小。或者,可基于Pred_mpm和/或与Pred_mpm比较的值来推导当前块的帧内预测模式。For example, Pred_mpm can be increased by N or decreased by N by comparing the size of Pred_mpm with the intra prediction mode of a neighboring block. Here, N may be a predetermined integer such as +1, +2, +3, 0, -1, -2, or -3. For example, Pred_mpm may be increased if Pred_mpm is less than the intra prediction mode of the neighboring block and/or the statistical value of the intra prediction mode of one or more neighboring blocks. Alternatively, Pred_mpm may be reduced if it is larger than the intra prediction mode of the neighboring block. Alternatively, the intra prediction mode of the current block may be derived based on Pred_mpm and/or a value compared with Pred_mpm.
在图13中示出的示例中,如果Pred_mpm小于模式值f,则Pred_mpm+1可被推导作为当前块的帧内预测模式。或者,如果Pred_mpm小于模式值g,则Pred_mpm+1可被推导作为当前块的帧内预测模式。或者,如果Pred_mpm小于模式值f,则Pred_mpm+2可被推导作为当前块的帧内预测模式。或者,如果Pred_mpm大于模式值f,则Pred_mpm-1可被推导作为当前块的帧内预测模式。或者,如果Pred_mpm小于模式值i,则Pred_mpm+1可被推导作为当前块的帧内预测模式。或者,如果Pred_mpm小于模式值f和i的平均值,则Pred_mpm+1可被推导作为当前块的帧内预测模式。或者,如果Pred_mpm小于模式值f和i的平均值,则可增加Pred_mpm和所述平均值之间的差值的1/2。例如,Pred_mpm+{((f+i+1)>>1-Pred_mpm+1)>>1}可被推导作为当前块的帧内预测模式。In the example shown in FIG. 13, if Pred_mpm is smaller than the mode value f, Pred_mpm+1 may be derived as the intra prediction mode of the current block. Alternatively, if Pred_mpm is smaller than the mode value g, Pred_mpm+1 may be derived as the intra prediction mode of the current block. Alternatively, if Pred_mpm is smaller than the mode value f, Pred_mpm+2 may be derived as the intra prediction mode of the current block. Alternatively, if Pred_mpm is greater than the mode value f, Pred_mpm-1 may be derived as the intra prediction mode of the current block. Alternatively, if Pred_mpm is less than the mode value i, Pred_mpm+1 may be derived as the intra prediction mode of the current block. Alternatively, if Pred_mpm is smaller than the average value of mode values f and i, Pred_mpm+1 may be derived as the intra prediction mode of the current block. Alternatively, if Pred_mpm is less than the average of mode values f and i, 1/2 of the difference between Pred_mpm and the average may be increased. For example, Pred_mpm+{((f+i+1)>>1-Pred_mpm+1)>>1} can be derived as the intra prediction mode of the current block.
或者,如果Pred_mpm和邻近块的模式中的一个是非方向模式并且另一个是方向模式,则所述非方向模式可被推导作为当前块的帧内预测模式,或者所述方向模式可被推导作为当前块的帧内预测模式。Alternatively, if one of the modes of Pred_mpm and neighboring blocks is a non-directional mode and the other is a directional mode, the non-directional mode may be derived as the intra prediction mode of the current block, or the directional mode may be derived as the current The intra prediction mode of the block.
在使用最可能模式(MPM)列表推导当前块的帧内预测模式的情况下,可使用例如以下MPM列表中的至少一个。或者,当前块的帧内预测模式可被熵编码/解码。In the case where the most probable mode (MPM) list is used to derive the intra prediction mode of the current block, for example, at least one of the following MPM lists may be used. Alternatively, the intra prediction mode of the current block may be entropy encoded/decoded.
–用于当前块的MPM列表。– List of MPMs to use for the current block.
–用于当前块的上层块的MPM列表中的至少一个。– At least one of the MPM lists for the upper block of the current block.
–用于当前块的邻近块的MPM列表中的至少一个。– At least one of the MPM lists for neighboring blocks of the current block.
可在视频参数集(VPS)、序列参数集(SPS)、画面参数集(PPS)、自适应参数集(APS)、条带、头、并行块、CTU、CU、PU和TU中的至少一个中熵编码/解码制作MPM列表所需的信息,诸如当前块的MPM列表是否被使用、当前块的上层块的MPM列表中的至少一个是否被使用、以及当前块的邻近块的MPM列表中的至少一个是否被使用。Can be in at least one of video parameter set (VPS), sequence parameter set (SPS), picture parameter set (PPS), adaptive parameter set (APS), slice, header, tile, CTU, CU, PU and TU Medium entropy encoding/decoding information required to make the MPM list, such as whether the MPM list of the current block is used, whether at least one of the MPM lists of the upper-level blocks of the current block is used, and the MPM lists of the neighboring blocks of the current block Whether at least one is used.
上层块可以是具有比当前块的深度值小的深度值的块。另外,上层块可表示在具有更小深度值的块之中的包括当前块的块中的至少一个块。这里,深度值可表示块每次被划分时增加1的值。例如,未被划分的CTU的深度值可以是0。The upper layer block may be a block with a smaller depth value than that of the current block. In addition, the upper layer block may represent at least one block including the current block among blocks having a smaller depth value. Here, the depth value may represent a value that increases by 1 each time the block is divided. For example, the depth value of an undivided CTU may be 0.
此外,上层块可意为以下实施例或者以下多个实施例之中的至少一个实施例的组合。如果第一块是上层块并且第二块是当前块,则第一块可包括第二块。这里,第一块可以是深度比第二块浅的块。这里,深度较浅的块可表示具有较小深度值的块。或者,第一块可表示大小比第二块大的块。这里,较大的块可表示深度较浅的块。Furthermore, the upper block may mean the following embodiment or a combination of at least one embodiment among the following embodiments. If the first block is the upper block and the second block is the current block, the first block may include the second block. Here, the first block can be a block with a shallower depth than the second block. Here, a block with a shallower depth may represent a block with a smaller depth value. Alternatively, the first block may represent a block that is larger in size than the second block. Here, larger blocks may represent blocks with shallower depth.
指示第一块的大小或深度中的至少一个的信息可被编码器用信号传送。可按照VPS、SPS、画面、条带、并行块和块中的至少一个的级别来用信号传送所述信息。Information indicating at least one of a size or a depth of the first block may be signaled by the encoder. The information may be signaled at the level of at least one of VPS, SPS, picture, slice, tile, and block.
可基于第二块的大小或深度中的至少一个来推导第一块的大小或深度中的至少一个。例如,可基于通过将预定常数与第二块(当前块)的大小(或深度)相加或者从第二块(当前块)的大小(或深度)减去所述预定常数所获得的值来推导第一块的大小或深度中的至少一个。或者,第一块的大小或深度中的至少一个可具有在编码器/解码器中预设的固定值。At least one of the size or depth of the first block may be derived based on at least one of the size or depth of the second block. For example, it may be based on a value obtained by adding a predetermined constant to the size (or depth) of the second block (current block) or subtracting the predetermined constant from the size (or depth) of the second block (current block). Derive at least one of the size or depth of the first block. Alternatively, at least one of the size or depth of the first block may have a fixed value preset in the encoder/decoder.
邻近块可以是与当前块在空间上和/或时间上相邻的块中的至少一个。邻近块可以已被编码/解码。另外,邻近块可具有与当前块的深度(或大小)相等或不同的深度(或大小)。邻近块可表示位于关于当前块的预定位置处的块。这里,所述预定位置可以是关于当前块的左上方位置、上方位置、右上方位置、左侧位置和左下方位置中的至少一个。The neighboring block may be at least one of the blocks that is spatially and/or temporally adjacent to the current block. Neighboring blocks may already be encoded/decoded. Additionally, neighboring blocks may have a depth (or size) that is equal to or different from the depth (or size) of the current block. Neighboring blocks may represent blocks located at predetermined positions with respect to the current block. Here, the predetermined position may be at least one of an upper left position, an upper position, an upper right position, a left position, and a lower left position with respect to the current block.
或者,所述预定位置可以是在与当前块所属于的画面不同的画面内的位置。在所述预定位置处的块可表示当前块的在不同画面中的同位块和/或与所述同位块相邻的块中的至少一个。或者,在所述预定位置处的块可以是在不同画面的特定区域中的与当前块相应的具有与当前块的预测模式相同的预测模式的块。Alternatively, the predetermined position may be a position within a different picture than the picture to which the current block belongs. The block at the predetermined position may represent at least one of a co-located block of the current block in a different picture and/or a block adjacent to the co-located block. Alternatively, the block at the predetermined position may be a block corresponding to the current block in a specific area of a different picture and having the same prediction mode as that of the current block.
此外,邻近块可意为以下实施例或者以下多个实施例中的至少一个的组合。如果第一块是邻近块并且第二块是当前块,则第一块是与第二块邻近的已编码/解码的块。第一块可以是具有与第二块的深度相等的深度的块。第一块可以是具有与第二块的大小相等的大小的块。Furthermore, the adjacent block may mean the following embodiment or a combination of at least one of the following embodiments. If the first block is an adjacent block and the second block is the current block, then the first block is an encoded/decoded block adjacent to the second block. The first block may be a block having a depth equal to the depth of the second block. The first block may be a block having a size equal to the size of the second block.
第一块和第二块可属于相同的编码块(CTU、CU等)或者不同的编码块。第一块的深度和/或大小可以不同于第二块的深度和/或大小。The first block and the second block may belong to the same coding block (CTU, CU, etc.) or different coding blocks. The depth and/or size of the first block may be different from the depth and/or size of the second block.
上层块或邻近块的MPM列表可表示基于上层块或邻近块制作的MPM列表。与上层块或邻近块邻近的已编码/解码的块的帧内预测模式可被添加到上层块或邻近块的MPM列表。The MPM list of the upper block or the neighboring block may represent an MPM list made based on the upper block or the neighboring block. The intra prediction mode of the encoded/decoded block adjacent to the upper layer block or the adjacent block may be added to the MPM list of the upper layer block or the adjacent block.
图14是描绘当前块、上层块和邻近块的示例性示图。FIG. 14 is an exemplary diagram depicting a current block, an upper block, and a neighboring block.
例如,在图14中,块U(用粗实线标记的块)可以是块F、块G、块H、块I和块J的上层块。块F、块G、块H、块I和块J中的至少一个可以是当前块。For example, in FIG. 14 , block U (block marked with a thick solid line) may be an upper block of block F, block G, block H, block I, and block J. At least one of block F, block G, block H, block I, and block J may be the current block.
例如,在图14中,块V(用粗虚线标记的块)可以是块G、块H、块I和块J的上层块。块G、块H、块I和块J中的至少一个可以是当前块。For example, in FIG. 14 , block V (the block marked with a thick dotted line) may be an upper block of block G, block H, block I, and block J. At least one of Block G, Block H, Block I and Block J may be the current block.
例如,在图14中,块W(用点状图案标记的块)可以是块G、块H和块I的上层块。块G、块H和块I中的至少一个可以是当前块。For example, in FIG. 14 , block W (a block marked with a dotted pattern) may be an upper block of block G, block H, and block I. At least one of block G, block H, and block I may be the current block.
例如,在图14中,块X(用菱形图案标记的块)可以是块H和块I的上层块。块H和块I中的至少一个可以是当前块。For example, in FIG. 14 , block X (the block marked with a diamond pattern) may be an upper block of block H and block I. At least one of block H and block I may be the current block.
例如,在图14中,当前块D的邻近块可以是块B、块C和块K中的至少一个。For example, in FIG. 14 , the neighboring blocks of the current block D may be at least one of block B, block C, and block K.
例如,在图14中,当前块L的邻近块可以是块C、块D、块E、块H和块K中的至少一个。For example, in FIG. 14 , the neighboring blocks of the current block L may be at least one of block C, block D, block E, block H, and block K.
例如,在图14中,当前块P的邻近块可以是块E、块H、块I、块J、块L、块N和块O中的至少一个。For example, in FIG. 14 , the neighboring blocks of the current block P may be at least one of block E, block H, block I, block J, block L, block N, and block O.
例如,在图14中,当前块S的邻近块可以是块I、块J、块P、块Q和块R中的至少一个。For example, in FIG. 14 , the neighboring blocks of the current block S may be at least one of block I, block J, block P, block Q, and block R.
可使用N个MPM列表来推导或熵编码/解码当前块的帧内预测模式。这里,N可以是0或正整数。也就是说,可使用多个MPM列表来推导或熵编码/解码当前块的帧内预测模式。另外,多个MPM列表可表示多个MPM列表或多个列表。用于当前块的N个MPM列表可包括当前块的MPM列表、上层块的MPM列表和邻近块的MPM列表中的至少一个。The N MPM lists may be used to derive or entropy encode/decode the intra prediction mode of the current block. Here, N can be 0 or a positive integer. That is, multiple MPM lists may be used to derive or entropy encode/decode the intra prediction mode of the current block. Additionally, multiple MPM lists may represent multiple MPM lists or multiple lists. The N MPM lists for the current block may include at least one of the MPM list of the current block, the MPM list of the upper layer block, and the MPM list of the neighboring block.
此外,可使用用于当前块的编码参数中的至少一个来产生所述N个MPM列表。Furthermore, the N MPM lists may be generated using at least one of the encoding parameters for the current block.
此外,预定块的多个子块中的至少一个子块可以是当前块。在这种情况下,所述多个子块的上层块可以是所述预定块。这里,所述多个子块可被包括在所述预定块中。此外,所述多个子块可以是从所述预定块划分出的块。此外,从所述预定块划分出的所述多个子块之中的不与当前块相应的子块中的至少一个可以是当前块的邻近块。这里,子块可意为在含义上与上层块相对的下层块。Furthermore, at least one sub-block among the plurality of sub-blocks of the predetermined block may be the current block. In this case, an upper block of the plurality of sub-blocks may be the predetermined block. Here, the plurality of sub-blocks may be included in the predetermined block. Furthermore, the plurality of sub-blocks may be blocks divided from the predetermined block. Furthermore, at least one of the plurality of sub-blocks divided from the predetermined block that does not correspond to the current block may be a neighboring block of the current block. Here, the sub-block may mean a lower-level block that is opposite in meaning to the upper-level block.
例如,如果当前块是图14中的块H,则可按照以下方法中的至少一种方法来制作用于当前块的多个MPM列表。所述多个MPM列表可包括基于当前块制作的MPM列表以及基于当前块的上层块制作的MPM列表中的至少一个。For example, if the current block is block H in FIG. 14, multiple MPM lists for the current block may be made according to at least one of the following methods. The plurality of MPM lists may include at least one of an MPM list made based on the current block and an MPM list made based on an upper layer block of the current block.
例如,在图14中,基于上层块X制作的MPM列表可被用于当前块H。For example, in Figure 14, the MPM list made based on the upper layer block X can be used for the current block H.
例如,在图14中,基于上层块W制作的MPM列表可被用于当前块H。For example, in Figure 14, the MPM list made based on the upper layer block W can be used for the current block H.
例如,在图14中,基于上层块V制作的MPM列表可被用于当前块H。For example, in Figure 14, the MPM list made based on the upper layer block V can be used for the current block H.
例如,在图14中,基于上层块U制作的MPM列表可被用于当前块H。For example, in Figure 14, the MPM list made based on the upper layer block U can be used for the current block H.
例如,在图14中,基于上层块X、上层块W、上层块V和上层块U中的至少一个制作的MPM列表中的至少一个可被用于推导当前块H的帧内预测模式。For example, in FIG. 14 , at least one of the MPM lists made based on at least one of the upper layer block X, the upper layer block W, the upper layer block V, and the upper layer block U may be used to derive the intra prediction mode of the current block H.
例如,如果当前块是图14中的块H,则可按照以下方法中的至少一种方法来制作用于当前块的多个MPM列表。所述多个MPM列表可包括基于当前块制作的MPM列表以及基于当前块的邻近块制作的MPM列表中的至少一个。For example, if the current block is block H in FIG. 14, multiple MPM lists for the current block may be made according to at least one of the following methods. The plurality of MPM lists may include at least one of an MPM list made based on the current block and an MPM list made based on neighboring blocks of the current block.
例如,在图14中,基于邻近块E制作的MPM列表可被用于当前块H。For example, in Figure 14, the MPM list made based on the neighboring block E can be used for the current block H.
例如,在图14中,基于邻近块G制作的MPM列表可被用于当前块H。For example, in FIG. 14, the MPM list made based on the neighboring block G can be used for the current block H.
例如,在图14中,基于邻近块E和邻近块G中的至少一个制作的MPM列表中的至少一个可被用于当前块H。For example, in FIG. 14 , at least one of the MPM lists made based on at least one of the neighboring block E and the neighboring block G may be used for the current block H.
可使用制作的MPM列表来推导当前块的帧内预测模式,或者,可对当前块的帧内预测模式进行熵编码/解码。The made MPM list can be used to derive the intra prediction mode of the current block, or the intra prediction mode of the current block can be entropy encoded/decoded.
将上层块的MPM列表或者邻近块的MPM列表用于当前块可意味着将上层块的MPM列表或邻近块的MPM列表用在推导当前块的帧内预测模式或者对当前块的帧内预测模式进行编码/解码的操作中。Using the MPM list of the upper layer block or the MPM list of the neighboring block for the current block may mean using the MPM list of the upper layer block or the MPM list of the neighboring block in deriving the intra prediction mode of the current block or the intra prediction mode of the current block. Encoding/decoding is in progress.
用于当前块的多个MPM列表可包括用于N个上层块的MPM列表。这里,N是0或正整数。The plurality of MPM lists for the current block may include MPM lists for N upper-layer blocks. Here, N is 0 or a positive integer.
在制作用于上层块的MPM列表时可能需要诸如上层块的数量、深度和/或深度范围和/或当前块的深度与上层块的深度之间的差的信息。可在VPS、SPS、PPS、APS、条带头、并行块头、CTU、CU、PU和TU中的至少一个中熵编码/解码制作上层块的MPM列表所需的该信息。Information such as the number, depth and/or depth range of upper blocks and/or the difference between the depth of the current block and the depth of the upper block may be required when making the MPM list for the upper block. The information required to make the MPM list of the upper layer block may be entropy encoded/decoded in at least one of VPS, SPS, PPS, APS, slice header, parallel block header, CTU, CU, PU, and TU.
例如,如果当前块的深度值为D,则可按照以下方法中的至少一种方法来制作上层块的MPM列表。如上所述,制作出的上层块的MPM列表可在推导当前块的帧内预测模式或者对当前块的帧内预测模式进行编码/解码的操作中被使用。这里,D是0或正整数。For example, if the depth value of the current block is D, the MPM list of the upper block can be made according to at least one of the following methods. As described above, the prepared MPM list of the upper layer block can be used in the operation of deriving the intra prediction mode of the current block or encoding/decoding the intra prediction mode of the current block. Here, D is 0 or a positive integer.
例如,深度值为D-1的上层块的MPM列表可被用于当前块。For example, the MPM list of the upper block with a depth value of D-1 may be used for the current block.
例如,深度值为D-2的上层块的MPM列表可被用于当前块。For example, the MPM list of the upper block with a depth value of D-2 may be used for the current block.
例如,深度值为D-K的上层块的MPM列表可被用于当前块。这里,K是等于或小于D的正整数。For example, the MPM list of upper-layer blocks with depth values D-K may be used for the current block. Here, K is a positive integer equal to or less than D.
例如,具有范围从D-1到D-2的深度值的上层块的MPM列表可被用于当前块。For example, an MPM list of upper-level blocks with depth values ranging from D-1 to D-2 may be used for the current block.
例如,具有范围从D-1到D-3的深度值的上层块的MPM列表可被用于当前块。For example, an MPM list of upper-level blocks with depth values ranging from D-1 to D-3 may be used for the current block.
例如,具有范围从D-1到D-K的深度值的上层块的MPM列表可被用于当前块。这里,K是等于或小于D的正整数。For example, an MPM list of upper-level blocks with depth values ranging from D-1 to D-K may be used for the current block. Here, K is a positive integer equal to or less than D.
例如,具有范围从D-K到D-l的深度值的上层块的MPM列表可被用于当前块。这里,K和l可以是等于或小于D的正整数。另外,K可以小于l。For example, an MPM list of upper-level blocks with depth values ranging from D-K to D-1 may be used for the current block. Here, K and l may be positive integers equal to or smaller than D. In addition, K can be smaller than l.
例如,如果一个上层块被使用,则深度值为D-1或0的上层块的MPM列表可被用于当前块。For example, if an upper-level block is used, the MPM list of the upper-level block with a depth value of D-1 or 0 may be used for the current block.
例如,如果两个上层块被使用,则深度值分别为0、1、D-1或D-2的上层块中的至少两个上层块的MPM列表可被用于当前块。For example, if two upper-layer blocks are used, MPM lists of at least two upper-layer blocks whose depth values are 0, 1, D-1, or D-2 respectively may be used for the current block.
例如,如果K个上层块被使用,则至少在具有范围从D-l到D-K的深度值的上层块以及具有范围从0到K-1的深度值的上层块之中的上层块的MPM列表可被用于当前块。K可以是小于或等于D的正整数。For example, if K upper-layer blocks are used, the MPM list of upper-layer blocks at least among upper-layer blocks having depth values ranging from D-1 to D-K and upper-layer blocks having depth values ranging from 0 to K-1 can be for the current block. K can be a positive integer less than or equal to D.
例如,如果K个上层块被使用,则关于当前块的K个上层块的MPM列表可被用于当前块。K可以是小于或等于D的正整数。For example, if K upper-layer blocks are used, the MPM list of the K upper-layer blocks with respect to the current block may be used for the current block. K can be a positive integer less than or equal to D.
如果用于当前块的多个MPM列表包括上层块的MPM列表,则可使用关于当前块的大小和/或深度的信息来推导使用的上层块的数量和/或深度值。If the multiple MPM lists for the current block include MPM lists of upper-layer blocks, information about the size and/or depth of the current block may be used to derive the number of upper-layer blocks used and/or the depth value.
例如,如果当前块是深度值为D的W×H块,则当前块的大小可被表示为像素的数量W×H。如果当前块中的像素的数量等于或大于预定阈值,则具有范围从D-1至D-K的深度值的上层块中的一个或更多个上层块的MPM列表可被用于当前块。这里,K可以是小于D的正整数。For example, if the current block is a W×H block with a depth value D, the size of the current block may be expressed as the number of pixels W×H. If the number of pixels in the current block is equal to or greater than the predetermined threshold, an MPM list of one or more upper-layer blocks having depth values ranging from D-1 to D-K may be used for the current block. Here, K can be a positive integer smaller than D.
此外,例如,如果当前块中的像素的数量小于所述预定阈值,则具有范围从D-1到D-L的深度值的上层块中的一个或更多个上层块的MPM列表可被用于当前块。这里,L可以是大于K的正整数。Furthermore, for example, if the number of pixels in the current block is less than the predetermined threshold, an MPM list of one or more upper-layer blocks having depth values ranging from D-1 to D-L may be used for the current block. piece. Here, L can be a positive integer greater than K.
例如,如果当前块的深度值是D并且D小于或等于预定深度值T,则具有范围从D-1到D-K的深度值的上层块中的一个或更多个上层块的MPM列表可被用于当前块。K可以是小于D的正整数。For example, if the depth value of the current block is D and D is less than or equal to the predetermined depth value T, an MPM list of one or more upper-layer blocks having depth values ranging from D-1 to D-K may be used in the current block. K can be a positive integer less than D.
例如,如果当前块的深度值D大于T,则具有范围从D-1到D-L的深度值的上层块中的一个或更多个上层块的MPM列表可被用于当前块。L可以是大于K的正整数。For example, if the depth value D of the current block is greater than T, an MPM list of one or more upper-layer blocks having depth values ranging from D-1 to D-L may be used for the current block. L can be a positive integer greater than K.
用于当前块的多个MPM列表可包括用于N个邻近块的MPM列表。所述N个邻近块可包括预定位置处的邻近块。N可以是0或者正整数。The multiple MPM lists for the current block may include MPM lists for N neighboring blocks. The N neighboring blocks may include neighboring blocks at predetermined positions. N can be 0 or a positive integer.
可能需要诸如所包括的邻近块的数量N、深度值、大小和/或位置的信息来制作邻近块的MPM列表。可在VPS、SPS、PPS、APS、条带头、并行块头、CTU、CU、PU和TU中的至少一个中熵编码/解码制作邻近块的MPM列表所需的信息。可根据当前块的大小、形状和/或位置来可变地确定邻近块的数量和/或位置。如果邻近块的深度值是预定值或落入预定范围内,则可制作邻近块的MPM列表。可通过最小值或最大值中的至少一个来定义所述预定范围。可在前述的预定单元中熵编码/解码关于最小值或最大值中的至少一个的信息。Information such as the number N, depth value, size and/or location of neighboring blocks included may be needed to make the MPM list of neighboring blocks. The information required to make the MPM list of neighboring blocks may be entropy encoded/decoded in at least one of VPS, SPS, PPS, APS, slice header, parallel block header, CTU, CU, PU, and TU. The number and/or location of neighboring blocks may be variably determined based on the size, shape, and/or location of the current block. If the depth value of the neighboring block is a predetermined value or falls within a predetermined range, an MPM list of the neighboring block may be made. The predetermined range may be defined by at least one of a minimum value or a maximum value. Information on at least one of the minimum value or the maximum value may be entropy encoded/decoded in the aforementioned predetermined unit.
例如,在图14中,如果当前块是块P并且具有深度值D,则可按照以下方法中的至少一种方法来制作用于当前块的多个MPM列表。这里,所述多个MPM列表可包括基于当前块制作的MPM列表和基于当前块的邻近块制作的MPM列表中的至少一个。For example, in FIG. 14, if the current block is block P and has a depth value D, multiple MPM lists for the current block may be made according to at least one of the following methods. Here, the plurality of MPM lists may include at least one of an MPM list made based on the current block and an MPM list made based on neighboring blocks of the current block.
例如,基于当前块P的左侧邻近块L或N制作的MPM列表可被用于当前块P。For example, an MPM list made based on the left neighboring blocks L or N of the current block P may be used for the current block P.
例如,基于当前块P的左上方邻近块E制作的MPM列表可被用于当前块P。For example, an MPM list made based on the upper left neighboring block E of the current block P may be used for the current block P.
例如,基于当前块P的左下方邻近块O制作的MPM列表可被用于当前块P。For example, an MPM list made based on the lower left neighboring block O of the current block P may be used for the current block P.
例如,基于当前块P的上方邻近块H或I制作的MPM列表可被用于当前块P。For example, an MPM list made based on the upper neighboring blocks H or I of the current block P may be used for the current block P.
例如,基于当前块P的右上方邻近块J制作的MPM列表可被用于当前块P。For example, an MPM list made based on the upper right neighboring block J of the current block P can be used for the current block P.
例如,当前块P的左上方邻近块、上方邻近块、右上方邻近块、左侧邻近块和左下方邻近块中的至少两个邻近块的MPM列表可被用于当前块P。For example, MPM lists of at least two neighboring blocks among the upper left neighboring block, the upper neighboring block, the upper right neighboring block, the left neighboring block, and the lower left neighboring block of the current block P may be used for the current block P.
例如,当前块P的左上方邻近块、上方邻近块、右上方邻近块、左侧邻近块和左下方邻近块中的至少三个邻近块的MPM列表可被用于当前块P。For example, MPM lists of at least three neighboring blocks among the upper left neighboring block, the upper neighboring block, the upper right neighboring block, the left neighboring block, and the lower left neighboring block of the current block P may be used for the current block P.
例如,当前块P的左上方邻近块、上方邻近块、右上方邻近块、左侧邻近块和左下方邻近块中的至少四个邻近块的MPM列表可被用于当前块P。For example, MPM lists of at least four neighboring blocks among the upper left neighboring block, the upper neighboring block, the upper right neighboring block, the left neighboring block, and the lower left neighboring block of the current block P may be used for the current block P.
例如,当前块P的左上方邻近块、上方邻近块、右上方邻近块、左侧邻近块和左下方邻近块中的至少五个邻近块的MPM列表可被用于当前块P。For example, MPM lists of at least five neighboring blocks among the upper left neighboring block, the upper neighboring block, the upper right neighboring block, the left neighboring block, and the lower left neighboring block of the current block P may be used for the current block P.
基于当前块、上层块和邻近块中的至少一个被推导出的帧内预测模式可被包括在用于当前块的一个MPM列表中。也就是说,如果不是多个MPM列表被用于当前块而是单个MPM列表被用于当前块,则MPM列表可由基于多个帧内预测模式中的至少一个被推导出的帧内预测模式中的至少一个组成,其中,所述多个帧内预测模式基于当前块、上层块和邻近块中的至少一个。The intra prediction mode derived based on at least one of the current block, the upper layer block, and the neighboring block may be included in one MPM list for the current block. That is, if instead of multiple MPM lists being used for the current block but a single MPM list is being used for the current block, the MPM list may be derived from the intra prediction mode derived based on at least one of the plurality of intra prediction modes. At least one composition, wherein the plurality of intra prediction modes are based on at least one of a current block, an upper layer block, and a neighboring block.
如果用于当前块的N个MPM列表包括用于上层块和邻近块中的至少一个的MPM列表,则可确定制作N个MPM列表的顺序。这里,N可以是0或者正整数。If the N MPM lists for the current block include an MPM list for at least one of the upper layer block and the neighboring block, the order in which the N MPM lists are made may be determined. Here, N can be 0 or a positive integer.
可在编码器和解码器中预先设置制作MPM列表的顺序。或者,可基于每个相应块的编码参数来确定制作MPM列表的顺序。或者,可基于当前块的编码参数来确定制作MPM列表的顺序。或者,关于制作MPM列表的顺序的信息可被熵编码/解码。The order in which MPM lists are made can be preset in the encoder and decoder. Alternatively, the order in which the MPM list is made may be determined based on the encoding parameters of each corresponding block. Alternatively, the order in which the MPM list is made may be determined based on the encoding parameters of the current block. Alternatively, information about the order in which the MPM list was made can be entropy encoded/decoded.
例如,在图14中,当前块可以是块H,并且用于当前块的MPM列表可被称为MPM_LIST_CUR。For example, in Figure 14, the current block may be block H, and the MPM list for the current block may be called MPM_LIST_CUR.
基于当前块的上层块制作的用于块X、W、V和U的MPM列表可分别被称为MPM_LIST_X、MPM_LIST_W、MPM_LIST_V和MPM_LIST_U。The MPM lists for blocks X, W, V, and U made based on the upper blocks of the current block may be called MPM_LIST_X, MPM_LIST_W, MPM_LIST_V, and MPM_LIST_U, respectively.
另外,基于当前块的邻近块制作的用于块L、E和G的MPM列表可分别被称为MPM_LIST_L、MPM_LIST_E和MPM_LIST_G。In addition, MPM lists for blocks L, E, and G made based on neighboring blocks of the current block may be referred to as MPM_LIST_L, MPM_LIST_E, and MPM_LIST_G, respectively.
可按照随后描述的方法中的至少一种方法来确定制作用于当前块的N个MPM列表的顺序。在随后描述的方法中使用的上层块和/或邻近块的数量仅是示例,并因此也可以使用不同数量的上层块和/或邻近块。The order in which the N MPM lists for the current block are made may be determined according to at least one of the methods described later. The numbers of upper-layer blocks and/or neighboring blocks used in the method described subsequently are only examples, and therefore different numbers of upper-layer blocks and/or neighboring blocks may also be used.
例如,可按照MPM_LIST_CUR->MPM_LIST_X->MPM_LIST_W->MPM_LIST_V->MPM_LIST_U的顺序针对当前块H制作多个MPM列表。For example, multiple MPM lists may be made for the current block H in the order of MPM_LIST_CUR->MPM_LIST_X->MPM_LIST_W->MPM_LIST_V->MPM_LIST_U.
例如,可按照MPM_LIST_U->MPM_LIST_V->MPM_LIST_W->MPM_LIST_X->MPM_LIST_CUR的顺序针对当前块H制作多个MPM列表。For example, multiple MPM lists may be made for the current block H in the order of MPM_LIST_U->MPM_LIST_V->MPM_LIST_W->MPM_LIST_X->MPM_LIST_CUR.
例如,当MPM_LIST_CUR被用作第一MPM列表时,可使用用于按照深度值的升序或降序排列的至少K个上层块的MPM列表,针对当前块H制作多个MPM列表。这里,K可以是0或者正整数。For example, when MPM_LIST_CUR is used as the first MPM list, multiple MPM lists may be made for the current block H using MPM lists for at least K upper-level blocks arranged in ascending or descending order of depth values. Here, K can be 0 or a positive integer.
例如,可按照MPM_LIST_CUR->MPM_LIST_L->MPM_LIST_G->MPM_LIST_E的顺序针对当前块H制作多个MPM列表。For example, multiple MPM lists may be made for the current block H in the order of MPM_LIST_CUR->MPM_LIST_L->MPM_LIST_G->MPM_LIST_E.
例如,可按照MPM_LIST_L->MPM_LIST_G->MPM_LIST_E->MPM_LIST_CUR的顺序针对当前块H制作多个MPM列表。For example, multiple MPM lists may be made for the current block H in the order of MPM_LIST_L->MPM_LIST_G->MPM_LIST_E->MPM_LIST_CUR.
例如,当MPM_LIST_CUR被用作第一MPM列表时,可按照预定顺序使用用于左上方邻近块、左侧邻近块、左下方邻近块、上方邻近块和右上方邻近块中的至少一个的MPM列表来针对当前块H制作多个MPM列表。For example, when MPM_LIST_CUR is used as the first MPM list, the MPM list for at least one of the upper left neighboring block, the left neighboring block, the lower left neighboring block, the upper neighboring block, and the upper right neighboring block may be used in a predetermined order to make multiple MPM lists for the current block H.
例如,可按照MPM_LIST_CUR->MPM_LIST_X->MPM_LIST_L的顺序针对当前块H制作多个MPM列表。For example, multiple MPM lists may be made for the current block H in the order of MPM_LIST_CUR->MPM_LIST_X->MPM_LIST_L.
例如,可按照MPM_LIST_CUR->MPM_LIST_L->MPM_LIST_X的顺序针对当前块H制作多个MPM列表。For example, multiple MPM lists can be made for the current block H in the order of MPM_LIST_CUR->MPM_LIST_L->MPM_LIST_X.
例如,可按照以下顺序针对当前块H制作多个MPM列表:MPM_LIST_CUR->针对按照预定顺序的K个上层块的MPM列表->针对按照预定顺序的L个邻近块的MPM列表。这里,K和L中的每一个可以是0或者正整数。For example, multiple MPM lists may be made for the current block H in the following order: MPM_LIST_CUR -> MPM list for K upper-level blocks in a predetermined order -> MPM list for L neighboring blocks in a predetermined order. Here, each of K and L can be 0 or a positive integer.
例如,可按照以下顺序针对当前块H制作多个MPM列表:MPM_LIST_CUR->针对按照预定顺序的L个邻近块的MPM列表->针对按照预定顺序的K个上层块的MPM列表。这里,K和L中的每一个可以是0或者正整数。For example, multiple MPM lists may be made for the current block H in the following order: MPM_LIST_CUR -> MPM list for L neighboring blocks in a predetermined order -> MPM list for K upper-layer blocks in a predetermined order. Here, each of K and L can be 0 or a positive integer.
例如,可按照以下顺序针对当前块H制作多个MPM列表:MPM_LIST_CUR->针对按照预定顺序的上层块或邻近块中的至少K个块的MPM列表。这里,K可以是正整数。For example, multiple MPM lists may be made for the current block H in the following order: MPM_LIST_CUR->MPM lists for at least K blocks in upper-level blocks or neighboring blocks in a predetermined order. Here, K can be a positive integer.
例如,可使用MPM_LIST_CUR和针对按照预定顺序的上层块或邻近块中的至少K个块的MPM列表,针对当前块H制作多个MPM列表。这里,K可以是正整数。For example, a plurality of MPM lists may be made for the current block H using MPM_LIST_CUR and MPM lists for at least K blocks in upper-layer blocks or neighboring blocks in a predetermined order. Here, K can be a positive integer.
在后的MPM列表可不包括在前的MPM列表中的帧内预测模式。The later MPM list may not include the intra prediction mode in the previous MPM list.
另外,用于所述在前的MPM列表的指示符的可变长码可短于用于所述在后的MPM列表的指示符的可变长码。In addition, the variable length code for the indicator of the previous MPM list may be shorter than the variable length code for the indicator of the later MPM list.
所述在前的MPM列表可包括比所述在后的MPM列表更少数量的候选。The earlier MPM list may include a smaller number of candidates than the later MPM list.
指示符可按照制作MPM列表的顺序被分配给MPM列表。Indicators may be assigned to the MPM list in the order in which the MPM list is made.
用于当前块的N个MPM列表可包括根据制作MPM列表的多个顺序中的至少一个顺序的用于上层块和邻近块中的至少一个的MPM列表。这里,多个MPM列表可被制作为不冗余地包括相同的帧内预测模式。这里,N可以是0或正整数。The N MPM lists for the current block may include MPM lists for at least one of the upper-layer block and the neighboring block according to at least one order among a plurality of orders in which the MPM lists are made. Here, multiple MPM lists may be made to include the same intra prediction mode without redundancy. Here, N can be 0 or a positive integer.
可用MPM_LIST_1、MPM_LIST_2、…MPM_LIST_N来表示用于当前块的N个MPM列表。MPM_LIST_CUR、MPM_LIST_X、MPM_LIST_W、MPM_LIST_V、MPM_LIST_U、MPM_LIST_L、MPM_LIST_E和MPM_LIST_G中的至少一个可对应于MPM_LIST_1、MPM_LIST_2、…MPM_LIST_N中的至少一个。MPM_LIST_1, MPM_LIST_2, ...MPM_LIST_N can be used to represent N MPM lists for the current block. At least one of MPM_LIST_CUR, MPM_LIST_X, MPM_LIST_W, MPM_LIST_V, MPM_LIST_U, MPM_LIST_L, MPM_LIST_E, and MPM_LIST_G may correspond to at least one of MPM_LIST_1, MPM_LIST_2, ...MPM_LIST_N.
可用C1、C2、...CN来表示各个MPM列表中可包括的帧内预测模式的数量。N、C1、C2、...CN中的每一个可以是0或正整数。C1至CN中的一部分或全部可相等或不同。另外,可在编码器和解码器中预先确定C1、C2、…CN中的至少一个。另外,可基于每个相应块的编码参数来确定C1、C2、…CN中的至少一个。另外,C1、C2、…CN中至少一个可被熵编码/解码。C1, C2, ...CN can be used to represent the number of intra prediction modes that can be included in each MPM list. Each of N, C1, C2,...CN can be 0 or a positive integer. Some or all of C1 to CN may be equal or different. In addition, at least one of C1, C2, . . . CN may be predetermined in the encoder and decoder. In addition, at least one of C1, C2, . . . CN may be determined based on the encoding parameters of each corresponding block. In addition, at least one of C1, C2, ...CN may be entropy encoded/decoded.
例如,可用MPM_LIST_1_MODE_1、MPM_LIST_1_MODE_2、...,MPM_LIST_1_MODE_C1来表示MPM_LIST_1中包括的帧内预测模式。For example, the intra prediction modes included in MPM_LIST_1 may be represented by MPM_LIST_1_MODE_1, MPM_LIST_1_MODE_2, ..., MPM_LIST_1_MODE_C1.
为了防止在MPM列表中冗余地包括相同的帧内预测模式,可使用在后的MPM列表中的帧内预测模式来检查包括在在前的MPM列表中的帧内预测模式的冗余。当在冗余检查之后存在冗余的帧内预测模式时,可从MPM列表中去除该帧内预测模式。在冗余模式被去除之后,可将预定帧内预测模式添加到MPM列表。In order to prevent the same intra prediction mode from being redundantly included in the MPM list, the intra prediction mode in the later MPM list may be used to check the redundancy of the intra prediction mode included in the previous MPM list. When a redundant intra prediction mode exists after redundancy checking, the intra prediction mode may be removed from the MPM list. After redundant modes are removed, predetermined intra prediction modes may be added to the MPM list.
可在制作多个MPM列表的步骤中执行对MPM列表中包括的模式的冗余检查。或者,可在多个MPM列表全部被制作之后执行冗余检查。或者,可在每次将帧内预测模式包括在MPM列表中时执行冗余检查。Redundancy checking of patterns included in the MPM lists may be performed in the step of making multiple MPM lists. Alternatively, the redundancy check can be performed after multiple MPM lists have all been made. Alternatively, the redundancy check can be performed every time an intra prediction mode is included in the MPM list.
例如,如果用于当前块的MPM_LIST_1包括C1个帧内预测模式,则MPM_LIST_1中的帧内预测模式可以是不冗余的MPM_LIST_1_MODE_1、MPM_LIST_1_MODE_2、...、MPM_LIST_1_MODE_C1。For example, if MPM_LIST_1 for the current block includes C1 intra prediction modes, the intra prediction modes in MPM_LIST_1 may be non-redundant MPM_LIST_1_MODE_1, MPM_LIST_1_MODE_2, ..., MPM_LIST_1_MODE_C1.
例如,如果MPM_LIST_2包括C2个非冗余帧内预测模式,则可检查MPM_LIST_2中的每个帧内预测模式是否与MPM_LIST_1中的帧内预测模式中的至少一个相同。For example, if MPM_LIST_2 includes C2 non-redundant intra prediction modes, it may be checked whether each intra prediction mode in MPM_LIST_2 is the same as at least one of the intra prediction modes in MPM_LIST_1.
如果MPM_LIST_2中包括的帧内预测模式MPM_LIST_2_MODE_X与MPM_LIST_1中包括的模式相同,则可从MPM_LIST_2去除冗余的帧内预测模式MPM_LIST_2_MODE_X。这里,MPM_LIST_2_MODE_X可以是MPM_LIST_2_MODE_1、MPM_LIST_2_MODE_2、…、MPM_LIST_2_MODE_C2中的至少一个。If the intra prediction mode MPM_LIST_2_MODE_X included in MPM_LIST_2 is the same as the mode included in MPM_LIST_1, the redundant intra prediction mode MPM_LIST_2_MODE_X may be removed from MPM_LIST_2. Here, MPM_LIST_2_MODE_X may be at least one of MPM_LIST_2_MODE_1, MPM_LIST_2_MODE_2, ..., MPM_LIST_2_MODE_C2.
例如,如果从MPM_LIST_2去除了至少一个帧内预测模式,则预定帧内预测模式中的至少一个帧内预测模式可被包括在MPM_LIST_2中。所述预定帧内预测模式中的被包括在MPM_LIST_2中的所述至少一个帧内预测模式可不与MPM_LIST_1中包括的帧内预测模式中的至少一个冗余。或者,所述预定帧内预测模式中的被包括在MPM_LIST_2中的所述至少一个帧内预测模式可不与MPM_LIST_1中包括的帧内预测模式中的任何一个冗余。For example, if at least one intra prediction mode is removed from MPM_LIST_2, at least one intra prediction mode among predetermined intra prediction modes may be included in MPM_LIST_2. The at least one intra prediction mode included in MPM_LIST_2 among the predetermined intra prediction modes may not be redundant with at least one intra prediction mode included in MPM_LIST_1. Alternatively, the at least one intra prediction mode included in MPM_LIST_2 among the predetermined intra prediction modes may not be redundant with any one of the intra prediction modes included in MPM_LIST_1.
被添加用于替代冗余的预测模式的所述预定帧内预测模式可包括包含例如以下项的帧内预测模式中的至少一个:INTRA_PLANAR、INTRA_DC、水平模式、垂直模式、45度模式、135度模式、225度模式、MPM_LIST_2_MODE_X±delta、INTRA_DM和INTRA_LM。INTRA_DM可表示这样的帧内预测模式:在该帧内预测模式中,帧内色度预测模式被确定为与帧内亮度预测模式相同。另外,INTRA_LM可表示这样的帧内预测模式:在该帧内预测模式中,可基于亮度预测块/亮度残差块/亮度重建块中的至少一个来产生色度预测块/色度残差块/色度重建块中的至少一个。另外,delta(增量)可以是正整数。The predetermined intra prediction mode added to replace the redundant prediction mode may include at least one of the intra prediction modes including, for example: INTRA_PLANAR, INTRA_DC, horizontal mode, vertical mode, 45 degree mode, 135 degree mode, 225 degree mode, MPM_LIST_2_MODE_X±delta, INTRA_DM and INTRA_LM. INTRA_DM may represent an intra prediction mode in which the intra chroma prediction mode is determined to be the same as the intra luma prediction mode. In addition, INTRA_LM may represent an intra prediction mode in which a chroma prediction block/chroma residual block may be generated based on at least one of a luma prediction block/luma residual block/luma reconstruction block /At least one of the chroma reconstruction blocks. In addition, delta (increment) can be a positive integer.
当delta连续地从1每次增加1直到MPM_LIST_2中包括的帧内预测模式的数量为C2为止时,预定帧内预测模式(MPM_LIST_2_MODE_X±增量)可被包括在MPM_LIST_2中。或者,预定帧内预测模式可按照预定顺序排列,并且预定帧内预测模式中的至少一个可按照所述顺序被包括在MPM_LIST_2中,直到MPM_LIST_2中包括的帧内预测模式的数量是C2为止。When delta continuously increases from 1 by 1 each time until the number of intra prediction modes included in MPM_LIST_2 is C2, a predetermined intra prediction mode (MPM_LIST_2_MODE_X±increment) may be included in MPM_LIST_2. Alternatively, the predetermined intra prediction modes may be arranged in a predetermined order, and at least one of the predetermined intra prediction modes may be included in MPM_LIST_2 in the order until the number of intra prediction modes included in MPM_LIST_2 is C2.
例如,如果用于当前块的MPM_LIST_3包括C3个非冗余帧内预测模式,则可检查MPM_LIST_3中包括的每个帧内预测模式是否等于MPM_LIST_1和MPM_LIST_2中包括的帧内预测模式中的至少一个。For example, if MPM_LIST_3 for the current block includes C3 non-redundant intra prediction modes, it may be checked whether each intra prediction mode included in MPM_LIST_3 is equal to at least one of the intra prediction modes included in MPM_LIST_1 and MPM_LIST_2.
如果MPM_LIST_3中包括的帧内预测模式MPM_LIST_3_MODE_X与MPM_LIST_1或MPM_LIST_2中包括的模式相同,则可从MPM_LIST_3中去除MPM_LIST_3_MODE_X。这里,MPM_LIST_3_MODE_X可以是MPM_LIST_3_MODE_1、MPM_LIST_3_MODE_2、...,MPM_LIST_3_MODE_C3中的至少一个。If the intra prediction mode MPM_LIST_3_MODE_X included in MPM_LIST_3 is the same as the mode included in MPM_LIST_1 or MPM_LIST_2, MPM_LIST_3_MODE_X may be removed from MPM_LIST_3. Here, MPM_LIST_3_MODE_X may be at least one of MPM_LIST_3_MODE_1, MPM_LIST_3_MODE_2, ..., MPM_LIST_3_MODE_C3.
例如,如果从MPM_LIST_3中去除了至少一个帧内预测模式,则预定帧内预测模式中的至少一个帧内预测模式可被包括在MPM_LIST_3中。所述预定帧内预测模式中的被包括在MPM_LIST_3中的所述至少一个帧内预测模式可不与MPM_LIST_1和MPM_LIST_2中包括的帧内预测模式中的至少一个冗余。或者,所述预定帧内预测模式中的被包括在MPM_LIST_3中的所述至少一个帧内预测模式可不与MPM_LIST_1和MPM_LIST_2中包括的帧内预测模式中的任何一个冗余。For example, if at least one intra prediction mode is removed from MPM_LIST_3, at least one intra prediction mode among predetermined intra prediction modes may be included in MPM_LIST_3. The at least one intra prediction mode included in MPM_LIST_3 among the predetermined intra prediction modes may not be redundant with at least one of the intra prediction modes included in MPM_LIST_1 and MPM_LIST_2. Alternatively, the at least one intra prediction mode included in MPM_LIST_3 among the predetermined intra prediction modes may not be redundant with any one of the intra prediction modes included in MPM_LIST_1 and MPM_LIST_2.
例如,当delta连续地从1每次增加1直到MPM_LIST_3中包括的帧内预测模式的数量为C3为止时,预定帧内预测模式(MPM_LIST_3_MODE_X±delta)可被包括在MPM_LIST_3中。或者,预定帧内预测模式可按照预定顺序排列,并且预定帧内预测模式中的至少一个可按照所述顺序被包括在MPM_LIST_3中,直到MPM_LIST_3中包括的帧内预测模式的数量是C3为止。For example, when delta continuously increases from 1 by 1 each time until the number of intra prediction modes included in MPM_LIST_3 is C3, the predetermined intra prediction mode (MPM_LIST_3_MODE_X±delta) may be included in MPM_LIST_3. Alternatively, the predetermined intra prediction modes may be arranged in a predetermined order, and at least one of the predetermined intra prediction modes may be included in MPM_LIST_3 in the order until the number of intra prediction modes included in MPM_LIST_3 is C3.
例如,如果用于当前块的MPM_LIST_K包括CK个非冗余帧内预测模式,则可检查MPM_LIST_K中包括的每个帧内预测模式是否与MPM_LIST_1、MPM_LIST_2、…MPM_LIST_(K-1)中包括的帧内预测模式中的至少一个相同。K可以是等于或小于可用于当前块的MPM列表的最大数量N的正整数。For example, if MPM_LIST_K for the current block includes CK non-redundant intra prediction modes, it may be checked whether each intra prediction mode included in MPM_LIST_K is consistent with the frames included in MPM_LIST_1, MPM_LIST_2,...MPM_LIST_(K-1) At least one of the intra-prediction modes is the same. K may be a positive integer equal to or less than the maximum number N of MPM lists available for the current block.
如果MPM_LIST_K中包括的帧内预测模式MPM_LIST_K_MODE_X与MPM_LIST_1、MPM_LIST_2、…MPM_LIST_(K-1)中包括的模式相同,则可从MPM_LIST_K中去除冗余的帧内预测模式MPM_LIST_K_MODE_X。这里,MPM_LIST_K_MODE_X可以是MPM_LIST_K_MODE_1、MPM_LIST_K_MODE_2、…、MPM_LIST_K_MODE_CK中的至少一个。If the intra prediction mode MPM_LIST_K_MODE_X included in MPM_LIST_K is the same as the modes included in MPM_LIST_1, MPM_LIST_2, ...MPM_LIST_(K-1), the redundant intra prediction mode MPM_LIST_K_MODE_X may be removed from MPM_LIST_K. Here, MPM_LIST_K_MODE_X may be at least one of MPM_LIST_K_MODE_1, MPM_LIST_K_MODE_2, ..., MPM_LIST_K_MODE_CK.
例如,如果从MPM_LIST_K去除了至少一个帧内预测模式,则可将预定帧内预测模式中的至少一个包括在MPM_LIST_K中。所述预定帧内预测模式中的被包括在MPM_LIST_K中的所述至少一个帧内预测模式可不与MPM_LIST_1、MPM_LIST_2、…、以及MPM_LIST_(K-1)中包括的帧内预测模式中的至少一个冗余。或者,所述预定帧内预测模式中的被包括在MPM_LIST_K中的所述至少一个帧内预测模式可不与MPM_LIST_1、MPM_LIST_2、…、以及MPM_LIST_(K-1)中包括的帧内预测模式中的任何一个冗余。For example, if at least one intra prediction mode is removed from MPM_LIST_K, at least one of the predetermined intra prediction modes may be included in MPM_LIST_K. The at least one intra prediction mode included in MPM_LIST_K among the predetermined intra prediction modes may not be redundant with at least one of the intra prediction modes included in MPM_LIST_1, MPM_LIST_2, ..., and MPM_LIST_(K-1). Remain. Alternatively, the at least one intra prediction mode included in MPM_LIST_K among the predetermined intra prediction modes may be different from any of the intra prediction modes included in MPM_LIST_1, MPM_LIST_2, ..., and MPM_LIST_(K-1) A redundancy.
例如,为了代替从MPM_LIST_K中去除的帧内预测模式,在预定帧内预测模式之中存在不与MPM_LIST_1、MPM_LIST_2、…、以及MPM_LIST_(K-1)中包括的帧内预测模式中的至少一个或任何一个冗余的特定帧内预测模式时,可将所述特定帧内预测模式添加到MPM_LIST_K中。For example, in order to replace the intra prediction mode removed from MPM_LIST_K, there is at least one of the intra prediction modes that is not included in MPM_LIST_1, MPM_LIST_2, ..., and MPM_LIST_(K-1) or When any specific intra prediction mode is redundant, the specific intra prediction mode can be added to MPM_LIST_K.
例如,当delta连续地从1每次增加1直到MPM_LIST_K中包括的帧内预测模式的数量为CK为止时,预定帧内预测模式(MPM_LIST_K_MODE_X±delta)可被包括在MPM_LIST_K中。或者,预定帧内预测模式可按照预定顺序排列,并且预定帧内预测模式中的至少一个可按照所述顺序被包括在MPM_LIST_K中,直到MPM_LIST_K中包括的帧内预测模式的数量是CK为止。For example, when delta continuously increases from 1 by 1 each time until the number of intra prediction modes included in MPM_LIST_K is CK, a predetermined intra prediction mode (MPM_LIST_K_MODE_X±delta) may be included in MPM_LIST_K. Alternatively, the predetermined intra prediction modes may be arranged in a predetermined order, and at least one of the predetermined intra prediction modes may be included in MPM_LIST_K in the order until the number of intra prediction modes included in MPM_LIST_K is CK.
如果使用N个MPM列表来推导当前块的帧内预测模式或者当前块的帧内预测模式被熵编码/解码,则针对N个MPM列表中的每一个,可对指示当前块的帧内预测模式是否被包括在N个MPM列表中的每一个中的帧内预测模式之中的指示符(MPM标志)进行熵编码/解码。If N MPM lists are used to derive the intra prediction mode of the current block or the intra prediction mode of the current block is entropy encoded/decoded, then for each of the N MPM lists, an indicator indicating the intra prediction mode of the current block may be An indicator (MPM flag) included among the intra prediction modes in each of the N MPM lists is entropy encoding/decoding.
例如,如果N个MPM列表被使用,则最多N个指示符可被编码/解码,其中,每个指示符用于一个MPM列表,诸如,MPM_FLAG_1、MPM_FLAG_2、...、MPM_FLAG_N。或者,最多(N-1)个指示符可被编码/解码,在这种情况下,可基于(N-1)个指示符中的一部分或者全部来推导用于另一个MPM列表的未被编码/解码的指示符。例如,可针对N个MPM列表中的任意一个MPM列表(例如,按照预定顺序计数的最后的MPM列表)不对指示符编码/解码。在特定MPM列表的帧内预测模式之中存在当前块的帧内预测模式时,对于所述特定MPM列表,指示符可具有第一值。在当前块的帧内预测模式不存在时,所述指示符可具有第二值。这里,第一值可以是1,第二值可以是0。也就是说,指示符可以是标志信息。For example, if N MPM lists are used, up to N indicators may be encoded/decoded, where each indicator is for one MPM list, such as MPM_FLAG_1, MPM_FLAG_2, ..., MPM_FLAG_N. Alternatively, up to (N-1) indicators may be encoded/decoded, in which case the unencoded value for another MPM list may be derived based on some or all of the (N-1) indicators. /decoding indicator. For example, the indicator may not be encoded/decoded for any one of the N MPM lists (eg, the last MPM list counted in a predetermined order). When the intra prediction mode of the current block exists among the intra prediction modes of a specific MPM list, the indicator may have a first value for the specific MPM list. The indicator may have a second value when the intra prediction mode of the current block does not exist. Here, the first value may be 1 and the second value may be 0. That is, the indicator may be flag information.
另外,如果在N个指示符中,用于特定MPM列表的指示符具有第一值,则除了用于所述特定MPM列表的指示符之外的用于其它MPM列表的指示符可具有第二值。In addition, if an indicator for a specific MPM list among N indicators has a first value, indicators for other MPM lists other than the indicator for the specific MPM list may have a second value. value.
另外,如果在N个指示符之中的用于第K MPM列表的指示符具有第一值,则用于第(K+1)MPM列表至第N MPM列表的指示符可不被熵编码/解码。这里,K可以是等于或大于1并且等于或小于N的正整数。In addition, if the indicator for the K-th MPM list among the N indicators has the first value, the indicators for the (K+1)-th MPM list to the N-th MPM list may not be entropy encoded/decoded . Here, K may be a positive integer equal to or greater than 1 and equal to or less than N.
在N个MPM列表中的特定MPM列表中包括的帧内预测模式之中存在与当前块的帧内预测模式相同的帧内预测模式时,指示所述特定MPM列表中的与当前块的帧内预测模式相同的帧内预测模式的位置或编号的索引信息(MPM索引)可被熵编码。另外,可通过对所述索引信息进行熵解码来识别在所述特定MPM列表中包括的帧内预测模式之中的与当前块的帧内预测模式相同的帧内预测模式。所述索引信息可被熵编码为固定长度码或者可变长度码。另外,可使用所述索引信息来推导当前块的帧内预测模式。When there is an intra prediction mode that is the same as the intra prediction mode of the current block among the intra prediction modes included in a specific MPM list among the N MPM lists, indicating that the intra prediction mode of the specific MPM list is the same as the intra prediction mode of the current block. Index information (MPM index) of positions or numbers of intra prediction modes with the same prediction mode may be entropy encoded. In addition, an intra prediction mode that is the same as an intra prediction mode of a current block among intra prediction modes included in the specific MPM list may be identified by entropy decoding the index information. The index information may be entropy encoded as a fixed length code or a variable length code. Additionally, the index information may be used to derive an intra prediction mode for the current block.
在N个MPM列表中包括的帧内预测模式之中不存在与当前块的帧内预测模式相同的帧内预测模式时,可在编码器中对当前块的剩余帧内预测模式进行熵编码。所述剩余帧内预测模式可被用于识别未被包括在MPM列表中的至少一个MPM列表中的当前块的帧内预测模式。或者,所述剩余帧内预测模式可被用于识别未被包括在MPM列表中的任何一个MPM列表中的当前块的帧内预测模式。When the same intra prediction mode as the intra prediction mode of the current block does not exist among the intra prediction modes included in the N MPM lists, the remaining intra prediction modes of the current block may be entropy encoded in the encoder. The remaining intra prediction modes may be used to identify intra prediction modes of the current block that are not included in at least one of the MPM lists. Alternatively, the remaining intra prediction modes may be used to identify the intra prediction mode of the current block that is not included in any one of the MPM lists.
如果帧内预测模式的总数是Y,并且包括在用于当前块的N个MPM列表中的帧内预测模式的数量的总和是X,则指示在(Y-X)个帧内预测模式之中的与当前块的帧内预测模式相同的帧内预测模式的剩余帧内预测模式可被熵编码。这里,可基于帧内预测模式的大小、角度、顺序和标识号中的至少一个来排列在N个MPM列表中包括的全部X个帧内预测模式。可按照升序或降序来进行所述排列。可将排列后的X个帧内预测模式与当前块的帧内预测模式进行比较。如果所述比较表明当前块的帧内预测模式大于排列后的X个帧内预测模式,则可从当前块的帧内预测模式减去预定值。所述预定值可以是1。If the total number of intra prediction modes is Y, and the sum of the number of intra prediction modes included in the N MPM lists for the current block is X, indicates the AND among (Y-X) intra prediction modes Remaining intra prediction modes of the same intra prediction mode as the intra prediction mode of the current block may be entropy encoded. Here, all X intra prediction modes included in the N MPM lists may be arranged based on at least one of size, angle, order and identification number of the intra prediction modes. The arrangement can be done in ascending or descending order. The arranged X intra prediction modes may be compared with the intra prediction mode of the current block. If the comparison indicates that the intra prediction mode of the current block is greater than the arranged X intra prediction modes, a predetermined value may be subtracted from the intra prediction mode of the current block. The predetermined value may be 1.
或者,例如,可将当前块的帧内预测模式与在排列后的X个帧内预测模式之中的具有最大参考值(例如,就大小、角度、顺序和标识号中的至少一个而言)的模式进行比较。如果该比较表明当前块的帧内预测模式大于所述具有最大参考值的模式,则可从当前块的帧内预测模式减去所述预定值。Or, for example, the intra prediction mode of the current block may be compared with the one with the largest reference value (for example, in terms of at least one of size, angle, order and identification number) among the arranged X intra prediction modes. modes to compare. If the comparison indicates that the intra prediction mode of the current block is greater than the mode with the largest reference value, the predetermined value may be subtracted from the intra prediction mode of the current block.
另外,例如,可将当前块的相减后的帧内预测模式与在排列后的X个帧内预测模式之中的具有第二大参考值的模式进行比较。如果该比较表明相减后的帧内预测模式大于所述具有第二大参考值的模式,则可从当前块的相减后的帧内预测模式进一步减去所述预定值。In addition, for example, the subtracted intra prediction mode of the current block may be compared with a mode having the second largest reference value among the arranged X intra prediction modes. If the comparison indicates that the subtracted intra prediction mode is greater than the mode with the second largest reference value, the predetermined value may be further subtracted from the subtracted intra prediction mode of the current block.
基于比较的减法操作可被重复直到在排列后的X个帧内预测模式之中具有最小参考值的模式为止。当前块的最终的相减后的帧内预测模式可被熵编码为所述剩余帧内预测模式。The comparison-based subtraction operation may be repeated until the mode has the smallest reference value among the arranged X intra prediction modes. The final subtracted intra prediction mode of the current block may be entropy encoded as the remaining intra prediction mode.
当前块的所述剩余帧内预测模式可被熵解码并被用于识别在未被包括在N个MPM列表中的帧内预测模式之中的与当前块的帧内预测模式相同的帧内预测模式。如果帧内预测模式的总数是Y并且在用于当前块的N个MPM列表中包括的帧内预测模式的数量的总和是X,则可对指示在(Y-X)个帧内预测模式之中的与当前块的帧内预测模式相同的帧内预测模式的所述剩余帧内预测模式进行熵解码。The remaining intra prediction modes of the current block may be entropy decoded and used to identify intra predictions that are the same as the intra prediction mode of the current block among intra prediction modes that are not included in the N MPM lists model. If the total number of intra prediction modes is Y and the total number of intra prediction modes included in the N MPM lists for the current block is The remaining intra prediction modes of the same intra prediction mode as the intra prediction mode of the current block are entropy decoded.
在所述剩余帧内预测模式被熵解码之后,可基于帧内预测模式的大小、角度、顺序和标识号中的至少一个来排列所述X个帧内预测模式。可按照升序或降序来进行所述排列。可将被熵解码的所述剩余帧内预测模式与所述X个帧内预测模式的值进行比较。如果所述比较表明被熵解码的所述剩余帧内预测模式等于或大于所述X个帧内预测模式的值,则可将被熵解码的所述剩余帧内预测模式的值增加预定值。所述预定值可以是1。After the remaining intra prediction modes are entropy decoded, the X intra prediction modes may be arranged based on at least one of size, angle, order and identification number of the intra prediction modes. The arrangement can be done in ascending or descending order. The entropy-decoded remaining intra-prediction modes may be compared with values of the X intra-prediction modes. If the comparison indicates that the entropy-decoded remaining intra-prediction modes are equal to or greater than the values of the X intra-prediction modes, the values of the entropy-decoded remaining intra-prediction modes may be increased by a predetermined value. The predetermined value may be 1.
或者,例如,可将在排列后的X个帧内预测模式之中具有最小参考值(例如,就帧内预测模式的大小、角度、顺序和标识号中的至少一个而言)的模式与被熵解码的所述剩余帧内预测模式进行比较。如果该比较表明被熵解码的所述剩余帧内预测模式等于或大于所述具有最小参考值的模式的值,则可将所述预定值与被熵解码的所述剩余帧内预测模式的值相加。Alternatively, for example, a mode with the smallest reference value (for example, in terms of at least one of the size, angle, order and identification number of the intra prediction mode) among the arranged X intra prediction modes may be compared with the one being The entropy decoded remaining intra prediction modes are compared. If the comparison indicates that the entropy-decoded remaining intra-prediction mode is equal to or greater than the value of the mode with the smallest reference value, the predetermined value may be compared with the value of the entropy-decoded remaining intra-prediction mode. Add up.
另外,可将在排列后的X个帧内预测模式之中具有第二小参考值的模式与被熵解码的所述剩余帧内预测模式的相加后的值进行比较。如果该比较表明被熵解码的所述剩余帧内预测模式的相加后的值等于或大于所述具有第二小参考值的模式的值,则可进一步将所述预定值与被熵解码的所述剩余帧内预测模式的相加后的值相加。In addition, the mode having the second smallest reference value among the arranged X intra prediction modes may be compared with the added value of the entropy-decoded remaining intra prediction modes. If the comparison indicates that the added value of the entropy-decoded remaining intra prediction modes is equal to or greater than the value of the mode with the second smallest reference value, the predetermined value may be further compared with the entropy-decoded The added values of the remaining intra prediction modes are added.
基于比较的加法操作可被重复直到在排列后的X个帧内预测模式之中具有最大参考值的模式为止。最终的相加后的剩余帧内预测模式可被熵解码为当前块的帧内预测模式。The comparison-based addition operation may be repeated until the mode has the largest reference value among the arranged X intra prediction modes. The final added remaining intra prediction mode may be entropy decoded into the intra prediction mode of the current block.
可按照以下实施例的方式对N个MPM列表被用于的当前块的帧内预测模式进行熵编码/解码。The intra prediction mode of the current block for which N MPM lists are used may be entropy encoded/decoded in the manner of the following embodiments.
下面将描述对于一个MPM列表被用于当前块的情况的实施例。An embodiment will be described below for the case where one MPM list is used for the current block.
在MPM_LIST_1中包括的帧内预测模式之中存在与当前块的帧内预测模式相同的帧内预测模式时,编码器可将指示在MPM_LIST_1中是否存在与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1熵编码为第一值。如果MPM_FLAG_1是第一值,则关于MPM_LIST_1的索引信息MPM_IDX_1可被进一步熵编码。When the same intra prediction mode as the intra prediction mode of the current block exists among the intra prediction modes included in MPM_LIST_1, the encoder may indicate whether the same intra prediction mode as the intra prediction mode of the current block exists in MPM_LIST_1 The indicator MPM_FLAG_1 of the prediction mode is entropy coded to a first value. If MPM_FLAG_1 is the first value, the index information MPM_IDX_1 regarding MPM_LIST_1 may be further entropy encoded.
在MPM_LIST_1中包括的帧内预测模式之中不存在与当前块的帧内预测模式相同的帧内预测模式时,编码器可将指示在MPM_LIST_1中是否存在与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1熵编码为第二值。如果MPM_FLAG_1是第二值,则所述剩余帧内预测模式REM_MODE可被进一步熵编码。When the same intra prediction mode as the intra prediction mode of the current block does not exist among the intra prediction modes included in MPM_LIST_1, the encoder may indicate whether there is a frame in MPM_LIST_1 that is the same as the intra prediction mode of the current block. The indicator MPM_FLAG_1 of the intra prediction mode is entropy coded to a second value. If MPM_FLAG_1 is the second value, the remaining intra prediction mode REM_MODE may be further entropy encoded.
解码器可对指示在MPM_LIST_1中是否存在与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1进行熵解码。如果MPM_FLAG_1是第一值,则解码器可通过进一步对关于MPM_LIST_1的索引信息MPM_IDX_1进行熵解码来推导当前块的帧内预测模式。The decoder may entropy decode the indicator MPM_FLAG_1 indicating whether the same intra prediction mode as the intra prediction mode of the current block exists in the MPM_LIST_1. If MPM_FLAG_1 is the first value, the decoder may derive the intra prediction mode of the current block by further entropy decoding the index information MPM_IDX_1 regarding MPM_LIST_1.
如果MPM_FLAG_1是第二值,则解码器可通过进一步对所述剩余帧内预测模式REM_MODE进行熵解码来推导当前块的帧内预测模式。If MPM_FLAG_1 is the second value, the decoder may derive the intra prediction mode of the current block by further entropy decoding the remaining intra prediction mode REM_MODE.
下面将描述对于两个MPM列表被用于当前块的情况的实施例。An embodiment will be described below for the case where two MPM lists are used for the current block.
在MPM_LIST_1和MPM_LIST_2中包括的帧内预测模式之中存在与当前块的帧内预测模式相同的帧内预测模式时,编码器可对指示MPM_LIST_1和MPM_LIST_2之中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1和MPM_FLAG_2进行熵编码。如果在MPM_LIST_1中存在当前块的帧内预测模式,则MPM_FLAG_1可以是第一值,并且MPM_FLAG_2可以是第二值。在这种情况下,关于MPM_LIST_1的索引信息MPM_IDX_1可被进一步熵编码。或者,如果在MPM_LIST_2中存在当前块的帧内预测模式,则MPM_FLAG_1可以是第二值,并且MPM_FLAG_2可以是第一值。在这种情况下,关于MPM_LIST_2的索引信息MPM_IDX_2可被进一步熵编码。When the same intra prediction mode as the intra prediction mode of the current block exists among the intra prediction modes included in MPM_LIST_1 and MPM_LIST_2, the encoder may indicate which list among MPM_LIST_1 and MPM_LIST_2 includes the intra prediction mode with the current block. Indicators MPM_FLAG_1 and MPM_FLAG_2 of intra prediction modes with the same prediction mode are entropy encoded. If the intra prediction mode of the current block exists in MPM_LIST_1, MPM_FLAG_1 may be a first value, and MPM_FLAG_2 may be a second value. In this case, the index information MPM_IDX_1 regarding MPM_LIST_1 may be further entropy encoded. Alternatively, if the intra prediction mode of the current block exists in MPM_LIST_2, MPM_FLAG_1 may be the second value, and MPM_FLAG_2 may be the first value. In this case, the index information MPM_IDX_2 on MPM_LIST_2 may be further entropy encoded.
在MPM_LIST_1和MPM_LIST_2中包括的帧内预测模式之中不存在与当前块的帧内预测模式相同的帧内预测模式时,编码器可将指示MPM_LIST_1和MPMS_LIST_2中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1和MPM_FLAG_2熵编码为第二值。如果MPM_FLAG_1和MPM_FLAG_2是第二值,则所述剩余帧内预测模式REM_MODE可被进一步熵编码。When the same intra prediction mode as the intra prediction mode of the current block does not exist among the intra prediction modes included in MPM_LIST_1 and MPM_LIST_2, the encoder may indicate which list in MPM_LIST_1 and MPMS_LIST_2 includes the intra prediction mode with the current block. Indicators MPM_FLAG_1 and MPM_FLAG_2 of intra prediction modes with the same prediction mode are entropy encoded to a second value. If MPM_FLAG_1 and MPM_FLAG_2 are the second value, the remaining intra prediction mode REM_MODE may be further entropy encoded.
解码器可对指示MPM_LIST_1和MPM_LIST_2中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1和MPM_FLAG_2进行熵解码。如果MPM_FLAG_1是第一值并且MPM_FLAG_2是第二值,则在MPM_LIST_1中存在当前块的帧内预测模式,并且解码器可通过进一步对关于MPM_LIST_1的索引信息MPM_IDX_1进行熵解码来推导当前块的帧内预测模式。或者,如果MPM_FLAG_1是第二值并且MPM_FLAG_2是第一值,则在MPM_LIST_2中存在当前块的帧内预测模式,并且解码器可通过进一步对关于MPM_LIST_2的索引信息MPM_IDX_2进行熵解码来推导当前块的帧内预测模式。或者,如果MPM_FLAG_1和MPM_FLAG_2是第二值,则解码器可通过对所述剩余帧内预测模式REM_MODE进行熵解码来推导当前块的帧内预测模式。这里,MPM_FLAG_1和MPM_FLAG_2两者都是第一值的情况不会发生。The decoder may entropy decode indicators MPM_FLAG_1 and MPM_FLAG_2 indicating which list among MPM_LIST_1 and MPM_LIST_2 includes the same intra prediction mode as that of the current block. If MPM_FLAG_1 is the first value and MPM_FLAG_2 is the second value, the intra prediction mode of the current block exists in MPM_LIST_1, and the decoder can derive the intra prediction of the current block by further entropy decoding the index information MPM_IDX_1 about MPM_LIST_1 model. Alternatively, if MPM_FLAG_1 is the second value and MPM_FLAG_2 is the first value, the intra prediction mode of the current block exists in MPM_LIST_2, and the decoder can derive the frame of the current block by further entropy decoding the index information MPM_IDX_2 on MPM_LIST_2 Intra prediction mode. Alternatively, if MPM_FLAG_1 and MPM_FLAG_2 are the second value, the decoder may derive the intra prediction mode of the current block by entropy decoding the remaining intra prediction mode REM_MODE. Here, the situation where both MPM_FLAG_1 and MPM_FLAG_2 are the first values does not occur.
在下文中,将描述针对两个MPM列表被用于当前块的情况的另一实施例。In the following, another embodiment will be described for the case where two MPM lists are used for the current block.
[表5][table 5]
如在[表5]的示例中,编码器可通过根据制作多个MPM列表的多个顺序中的至少一个顺序依次检查在MPM_LIST_1和MPM_LIST_2中的每一个中包括的帧内预测模式之中是否存在与当前块的帧内预测模式相同的帧内预测模式,来对当前块的帧内预测模式进行熵编码。As in the example of [Table 5], the encoder may sequentially check whether there is an intra prediction mode included in each of MPM_LIST_1 and MPM_LIST_2 by sequentially checking at least one of a plurality of orders in which a plurality of MPM lists are made. Entropy encoding is performed on the intra prediction mode of the current block using the same intra prediction mode as the intra prediction mode of the current block.
例如,如果在MPM_LIST_1中存在与当前块的帧内预测模式相同的帧内预测模式,则MPM_FLAG_1可被熵编码为第一值。这里,关于MPM_LIST_1的索引信息MPM_IDX_1可被进一步熵编码。For example, if the same intra prediction mode as the intra prediction mode of the current block exists in MPM_LIST_1, MPM_FLAG_1 may be entropy encoded to the first value. Here, the index information MPM_IDX_1 regarding MPM_LIST_1 may be further entropy encoded.
例如,在MPM_LIST_1中不存在与当前块的帧内预测模式相同的帧内预测模式时,MPM_FLAG_1可被熵编码为第二值。这里,在MPM_LIST_2中存在与当前块的帧内预测模式相同的帧内预测模式时(在MPM_FLAG_1是第二值的情况下),MPM_FLAG_2可被熵编码为第一值。这里,关于MPM_LIST_2的索引信息MPM_IDX_2可被进一步熵编码。For example, when the same intra prediction mode as the intra prediction mode of the current block does not exist in MPM_LIST_1, MPM_FLAG_1 may be entropy encoded to the second value. Here, when the same intra prediction mode as that of the current block exists in MPM_LIST_2 (in the case where MPM_FLAG_1 is the second value), MPM_FLAG_2 may be entropy encoded to the first value. Here, the index information MPM_IDX_2 regarding MPM_LIST_2 may be further entropy encoded.
例如,在MPM_LIST_1和MPM_LIST_2中不存在与当前块的帧内预测模式相同的帧内预测模式时,MPM_FLAG_1和MPM_FLAG_2可被熵编码为第二值。这里(如果MPM_FLAG_1和MPM_FLAG_2是第二值),剩余帧内预测模式REM_MODE可被进一步熵编码。For example, when the same intra prediction mode as the intra prediction mode of the current block does not exist in MPM_LIST_1 and MPM_LIST_2, MPM_FLAG_1 and MPM_FLAG_2 may be entropy encoded to the second value. Here (if MPM_FLAG_1 and MPM_FLAG_2 are the second value), the remaining intra prediction mode REM_MODE may be further entropy encoded.
如在[表5]的示例中,解码器可按照制作多个MPM列表的多个顺序中的至少一个顺序依次地对指示在MPM_LIST_1和MPM_LIST_2中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1和/或MPM_FLAG_2进行熵解码。As in the example of [Table 5], the decoder may sequentially indicate which list in MPM_LIST_1 and MPM_LIST_2 includes the same intra prediction mode as the current block in at least one of a plurality of orders in which the plurality of MPM lists are made. The indicator MPM_FLAG_1 and/or MPM_FLAG_2 of the intra prediction mode is entropy decoded.
例如,如果MPM_FLAG_1被熵解码为第一值,则在MPM_LIST_1中存在当前块的帧内预测模式,并且可通过进一步对关于MPM_LIST_1的索引信息MPM_IDX_1进行熵解码来推导当前块的帧内预测模式。For example, if MPM_FLAG_1 is entropy decoded to a first value, the intra prediction mode of the current block exists in MPM_LIST_1, and the intra prediction mode of the current block can be derived by further entropy decoding the index information MPM_IDX_1 on MPM_LIST_1.
例如,如果MPM_FLAG_1被熵解码为第二值,则可对MPM_FLAG_2进行熵解码。如果解码的MPM_FLAG_2是第一值,则在MPM_LIST_2中存在当前块的帧内预测模式,并且可通过进一步对关于MPM_LIST_2的索引信息MPM_IDX_2进行熵解码来推导当前块的帧内预测模式。For example, if MPM_FLAG_1 is entropy decoded to a second value, MPM_FLAG_2 may be entropy decoded. If the decoded MPM_FLAG_2 is the first value, the intra prediction mode of the current block exists in MPM_LIST_2 and can be derived by further entropy decoding the index information MPM_IDX_2 on MPM_LIST_2.
例如,如果MPM_FLAG_1和MPM_FLAG_2被熵解码为第二值,则可通过进一步对剩余帧内预测模式REM_MODE进行熵解码来推导当前块的帧内预测模式。这里,可依次地执行确定MPM_FLAG_1和MPM_FLAG_2是第一值还是第二值的步骤。For example, if MPM_FLAG_1 and MPM_FLAG_2 are entropy decoded to the second value, the intra prediction mode of the current block may be derived by further entropy decoding the remaining intra prediction mode REM_MODE. Here, the steps of determining whether MPM_FLAG_1 and MPM_FLAG_2 are the first value or the second value may be performed sequentially.
现在,将描述针对N个MPM列表被用于当前块的情况的实施例。Now, an embodiment will be described for the case where N MPM lists are used for the current block.
在MPM_LIST_1、MPM_LIST_2、…、和MPM_LIST_N中包括的帧内预测模式中存在与当前块的帧内预测模式相同的帧内预测模式时,编码器可对指示MPM_LIST_1、MPM_LIST_2、…、和MPM_LIST_N中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1、MPM_FLAG_2、…、和MPM_FLAG_N进行熵编码。如果在MPM_LIST_1中存在当前块的帧内预测模式,则MPM_FLAG_1可以是第一值,并且除了MPM_FLAG_1之外的MPM_FLAG_2、…、和MPM_FLAG_N可以是第二值。在这种情况下,可进一步对关于MPM_LIST_1的索引信息MPM_IDX_1进行熵编码。When the same intra prediction mode as the intra prediction mode of the current block exists among the intra prediction modes included in MPM_LIST_1, MPM_LIST_2, ..., and MPM_LIST_N, the encoder may indicate which of the MPM_LIST_1, MPM_LIST_2, ..., and MPM_LIST_N The list includes indicators MPM_FLAG_1, MPM_FLAG_2, . . . , and MPM_FLAG_N for intra prediction modes that are the same as the intra prediction mode of the current block for entropy encoding. If the intra prediction mode of the current block exists in MPM_LIST_1, MPM_FLAG_1 may be the first value, and MPM_FLAG_2, . . . , and MPM_FLAG_N except MPM_FLAG_1 may be the second value. In this case, the index information MPM_IDX_1 regarding MPM_LIST_1 may be further entropy-encoded.
或者,如果在MPM_LIST_2中存在当前块的帧内预测模式,则MPM_FLAG_2可以是第一值,并且除了MPM_FLAG_2之外的MPM_FLAG_1、…、和MPM_FLAG_N可以是第二值。在这种情况下,可进一步对关于MPM_LIST_2的索引信息MPM_IDX_2进行熵编码。Alternatively, if the intra prediction mode of the current block exists in MPM_LIST_2, MPM_FLAG_2 may be the first value, and MPM_FLAG_1, . . . , and MPM_FLAG_N except MPM_FLAG_2 may be the second value. In this case, the index information MPM_IDX_2 regarding MPM_LIST_2 may be further entropy-encoded.
或者,如果在MPM_LIST_N中存在当前块的帧内预测模式,则MPM_FLAG_N可以是第一值,并且除了MPM_FLAG_N之外的MPM_FLAG_1、…、和MPM_FLAG_(N-1)可以是第二值。在这种情况下,可进一步对关于MPM_LIST_N的索引信息MPM_IDX_N进行熵编码。Alternatively, if the intra prediction mode of the current block exists in MPM_LIST_N, MPM_FLAG_N may be the first value, and MPM_FLAG_1, . . . , and MPM_FLAG_(N-1) other than MPM_FLAG_N may be the second value. In this case, the index information MPM_IDX_N regarding MPM_LIST_N may be further entropy-encoded.
在MPM_LIST_1、MPM_LIST_2、…、和MPM_LIST_N中包括的帧内预测模式之中不存在与当前块的帧内预测模式相同的帧内预测模式时,编码器可将指示MPM_LIST_1、MPM_LIST_2、…、和MPM_LIST_N中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的MPM_FLAG_1、MPM_FLAG_2、…、和MPM_FLAG_N熵编码为第二值。如果MPM_FLAG_1、MPM_FLAG_2、…、和MPM_FLAG_N是第二值,则可进一步对剩余帧内预测模式REM_MODE进行熵编码。When the same intra prediction mode as the intra prediction mode of the current block does not exist among the intra prediction modes included in MPM_LIST_1, MPM_LIST_2, ..., and MPM_LIST_N, the encoder may indicate MPM_LIST_1, MPM_LIST_2, ..., and MPM_LIST_N Which list of MPM_FLAG_1, MPM_FLAG_2, ..., and MPM_FLAG_N of the same intra prediction mode as the intra prediction mode of the current block is entropy encoded as the second value. If MPM_FLAG_1, MPM_FLAG_2, . . . , and MPM_FLAG_N are the second values, the remaining intra prediction mode REM_MODE may be further entropy encoded.
解码器可对指示MPM_LIST_1、MPM_LIST_2、…、和MPM_LIST_N中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1、MPM_FLAG_2、…、和MPM_FLAG_N进行熵解码。如果MPM_FLAG_1是第一值并且除了MPM_FLAG_1之外的MPM_FLAG_2、…、和MPM_FLAG_N是第二值,则在MPM_LIST_1中可存在当前块的帧内预测模式。在这种情况下,可通过进一步对关于MPM_LIST_1的索引信息MPM_IDX_1进行熵解码来推导当前块的帧内预测模式。The decoder may entropy decode indicators MPM_FLAG_1, MPM_FLAG_2, . . . , and MPM_FLAG_N indicating which list among MPM_LIST_1, MPM_LIST_2, . If MPM_FLAG_1 is the first value and MPM_FLAG_2, . . . , and MPM_FLAG_N except MPM_FLAG_1 are the second value, the intra prediction mode of the current block may be present in MPM_LIST_1. In this case, the intra prediction mode of the current block can be derived by further entropy decoding the index information MPM_IDX_1 on MPM_LIST_1.
或者,如果MPM_FLAG_2是第一值并且除了MPM_FLAG_2之外的MPM_FLAG_1、…、和MPM_FLAG_N是第二值,则在MPM_LIST_2中可存在当前块的帧内预测模式。在这种情况下,可通过进一步对关于MPM_LIST_2的索引信息MPM_IDX_2进行熵解码来推导当前块的帧内预测模式。Alternatively, if MPM_FLAG_2 is the first value and MPM_FLAG_1, . . . , and MPM_FLAG_N except MPM_FLAG_2 are the second value, the intra prediction mode of the current block may be present in MPM_LIST_2. In this case, the intra prediction mode of the current block can be derived by further entropy decoding the index information MPM_IDX_2 on MPM_LIST_2.
或者,如果MPM_FLAG_N是第一值并且除了MPM_FLAG_N之外的MPM_FLAG_1、…、和MPM_FLAG_(N-1)是第二值,则在MPM_LIST_N中可存在当前块的帧内预测模式。在这种情况下,可通过进一步对关于MPM_LIST_N的索引信息MPM_IDX_N进行熵解码来推导当前块的帧内预测模式。Alternatively, if MPM_FLAG_N is the first value and MPM_FLAG_1, . . . , and MPM_FLAG_(N-1) except MPM_FLAG_N are the second value, the intra prediction mode of the current block may be present in MPM_LIST_N. In this case, the intra prediction mode of the current block can be derived by further entropy decoding the index information MPM_IDX_N on MPM_LIST_N.
或者,如果MPM_FLAG_1、MPM_FLAG_2、…、和MPM_FLAG_N是第二值,则可通过进一步对剩余帧内预测模式REM_MODE进行熵解码来推导当前块的帧内预测模式。这里,MPM_FLAG_1、MPM_FLAG_2、…、和MPM_FLAG_N全部是第一值的情况不会发生。Alternatively, if MPM_FLAG_1, MPM_FLAG_2, . . . , and MPM_FLAG_N are the second values, the intra prediction mode of the current block may be derived by further entropy decoding the remaining intra prediction mode REM_MODE. Here, the situation where MPM_FLAG_1, MPM_FLAG_2, ..., and MPM_FLAG_N are all first values does not occur.
现在,将描述针对N个MPM列表被用于当前块的情况的另一实施例。Now, another embodiment will be described for the case where N MPM lists are used for the current block.
[表6][Table 6]
如在[表6]的示例中,编码器可通过根据制作多个MPM列表的多个顺序中的至少一个顺序依次检查在MPM_LIST_1、MPM_LIST_2、…、MPM_LIST_N中的每一个中包括的帧内预测模式之中是否存在与当前块的帧内预测模式相同的帧内预测模式,来对当前块的帧内预测模式进行熵编码。As in the example of [Table 6], the encoder may sequentially check the intra prediction modes included in each of MPM_LIST_1, MPM_LIST_2, . Whether there is an intra prediction mode that is the same as the intra prediction mode of the current block, to entropy encode the intra prediction mode of the current block.
例如,如果在MPM_LIST_1中存在与当前块的帧内预测模式相同的帧内预测模式,则MPM_FLAG_1可被熵编码为第一值。这里,可进一步对关于MPM_LIST_1的索引信息MPM_IDX_1进行熵编码。For example, if the same intra prediction mode as the intra prediction mode of the current block exists in MPM_LIST_1, MPM_FLAG_1 may be entropy encoded to the first value. Here, the index information MPM_IDX_1 regarding MPM_LIST_1 may be further entropy-encoded.
例如,在MPM_LIST_1中不存在与当前块的帧内预测模式相同的帧内预测模式时,MPM_FLAG_1可被熵编码为第二值。这里,在MPM_LIST_2中存在与当前块的帧内预测模式相同的帧内预测模式时(在MPM_FLAG_1是第二值的情况下),MPM_FLAG_2可被熵编码为第一值。这里,可进一步对关于MPM_LIST_2的索引信息MPM_IDX_2进行熵编码。For example, when the same intra prediction mode as the intra prediction mode of the current block does not exist in MPM_LIST_1, MPM_FLAG_1 may be entropy encoded to the second value. Here, when the same intra prediction mode as that of the current block exists in MPM_LIST_2 (in the case where MPM_FLAG_1 is the second value), MPM_FLAG_2 may be entropy encoded to the first value. Here, the index information MPM_IDX_2 regarding MPM_LIST_2 may be further entropy-encoded.
例如,在MPM_LIST_1、MPM_LIST_2、…、MPM_LIST_(N-1)中不存在与当前块的帧内预测模式相同的帧内预测模式时,MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_(N-1)可被熵编码为第二值。这里,如果在MPM_LIST_N中存在与当前块的帧内预测模式相同的帧内预测模式(如果MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_(N-1)是第二值),则可进一步对关于MPM_LIST_N的索引信息MPM_IDX_N进行熵编码。For example, when the same intra prediction mode as the intra prediction mode of the current block does not exist in MPM_LIST_1, MPM_LIST_2, ..., MPM_LIST_(N-1), MPM_FLAG_1, MPM_FLAG_2, ..., MPM_FLAG_(N-1) may be entropy encoded is the second value. Here, if the same intra prediction mode as the intra prediction mode of the current block exists in MPM_LIST_N (if MPM_FLAG_1, MPM_FLAG_2, ..., MPM_FLAG_(N-1) is the second value), then the index information about MPM_LIST_N may be further MPM_IDX_N performs entropy encoding.
例如,在MPM_LIST_1、MPM_LIST_2、…、MPM_LIST_N中不存在与当前块的帧内预测模式相同的帧内预测模式时,MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_N可被熵编码为第二值。这里,可进一步对剩余帧内预测模式REM_MODE进行熵编码。For example, when the same intra prediction mode as the intra prediction mode of the current block does not exist in MPM_LIST_1, MPM_LIST_2, ..., MPM_LIST_N, MPM_FLAG_1, MPM_FLAG_2, ..., MPM_FLAG_N may be entropy encoded to the second value. Here, the remaining intra prediction mode REM_MODE may be further entropy encoded.
如在[表6]的示例中,解码器可按照制作多个MPM列表的多个顺序中的至少一个顺序依次地对指示在MPM_LIST_1、MPM_LIST_2、…、MPM_LIST_N中的哪个列表包括与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_N中的至少一个进行熵解码。As in the example of [Table 6], the decoder may sequentially indicate which list among MPM_LIST_1, MPM_LIST_2, . At least one of the intra prediction mode indicators MPM_FLAG_1, MPM_FLAG_2, ..., MPM_FLAG_N with the same intra prediction mode is entropy decoded.
例如,如果MPM_FLAG_1被熵解码为第一值,则在MPM_LIST_1中存在当前块的帧内预测模式,并且可通过进一步对关于MPM_LIST_1的索引信息MPM_IDX_1进行熵解码来推导当前块的帧内预测模式。For example, if MPM_FLAG_1 is entropy decoded to a first value, the intra prediction mode of the current block exists in MPM_LIST_1, and the intra prediction mode of the current block can be derived by further entropy decoding the index information MPM_IDX_1 on MPM_LIST_1.
例如,如果MPM_FLAG_1被熵解码为第二值,则可对MPM_FLAG_2进行熵解码。如果解码的MPM_FLAG_2是第一值,则在MPM_LIST_2中存在当前块的帧内预测模式,并且可通过进一步对关于MPM_LIST_2的索引信息MPM_IDX_2进行熵解码来推导当前块的帧内预测模式。For example, if MPM_FLAG_1 is entropy decoded to a second value, MPM_FLAG_2 may be entropy decoded. If the decoded MPM_FLAG_2 is the first value, the intra prediction mode of the current block exists in MPM_LIST_2 and can be derived by further entropy decoding the index information MPM_IDX_2 on MPM_LIST_2.
例如,如果MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_(N-1)被熵解码为第二值,则可对MPM_FLAG_N进行熵解码。如果解码的MPM_FLAG_N是第一值,则在MPM_LIST_N中存在当前块的帧内预测模式,并且可通过进一步对关于MPM_LIST_N的索引信息MPM_IDX_N进行熵解码来推导当前块的帧内预测模式。For example, if MPM_FLAG_1, MPM_FLAG_2, . . . , MPM_FLAG_(N-1) are entropy decoded to the second value, MPM_FLAG_N may be entropy decoded. If the decoded MPM_FLAG_N is the first value, the intra prediction mode of the current block exists in MPM_LIST_N and can be derived by further entropy decoding the index information MPM_IDX_N about the MPM_LIST_N.
例如,如果MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_N被熵解码为第二值,则可通过进一步对剩余帧内预测模式REM_MODE进行熵解码来推导当前块的帧内预测模式。这里,可依次地执行确定MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_N是第一值还是第二值的步骤。For example, if MPM_FLAG_1, MPM_FLAG_2, . . . , MPM_FLAG_N are entropy decoded to the second value, the intra prediction mode of the current block may be derived by further entropy decoding the remaining intra prediction mode REM_MODE. Here, the steps of determining whether MPM_FLAG_1, MPM_FLAG_2, ..., MPM_FLAG_N are the first value or the second value may be performed sequentially.
可对指定MPM列表的标志(诸如MPM_FLAG_N)或者指示多个MPM列表之一的索引进行编码/解码。可对指示基于MPM的帧内预测推导方法是否将被用于当前块(或者当前条带、当前画面、当前序列等)的信息进行编码/解码。如果该信息指示基于MPM的帧内预测推导方法被使用,则可对所述索引进行编码/解码。可在编码器/解码器中固定地预先定义多个MPM列表的数量或类型中的至少一个,或者,可基于与当前块/邻近块的大小、深度、形状、位置等相关的参数来可变地确定多个MPM列表的数量或类型中的至少一个。例如,在编码器/解码器中预先定义的MPM列表的数量可以是1、2、3或更大。在每个MPM列表中包括的帧内预测模式的最大数量可被强制为相等。可在编码器/解码器中固定地预先设置所述最大数量,或者可按预定单元(例如,序列、画面、条带、块等)用信号传送所述最大数量。如果在特定MPM列表中包括的帧内预测模式的数量小于所述最大数量,则可将预定模式添加到所述特定MPM列表中。添加的模式可以是预设的默认模式、或者是在另一MPM列表中包括的帧内预测模式。值得注意的是,可添加与所述特定MPM列表中包括的帧内预测模式不同的模式。在MPM列表之间的冗余检查可被省略。MPM列表之一可与另一MPM列表共享至少一个相同的帧内预测模式。A flag specifying an MPM list, such as MPM_FLAG_N, or an index indicating one of multiple MPM lists may be encoded/decoded. Information indicating whether an MPM-based intra prediction derivation method will be used for the current block (or current slice, current picture, current sequence, etc.) may be encoded/decoded. If the information indicates that the MPM-based intra prediction derivation method is used, the index may be encoded/decoded. At least one of the number or types of multiple MPM lists may be fixedly predefined in the encoder/decoder, or may be variable based on parameters related to the size, depth, shape, position, etc. of the current block/neighboring blocks. Determine at least one of the number or types of the plurality of MPM lists. For example, the number of MPM lists predefined in the encoder/decoder can be 1, 2, 3 or larger. The maximum number of intra prediction modes included in each MPM list may be forced to be equal. The maximum number may be fixedly preset in the encoder/decoder or may be signaled in predetermined units (eg, sequences, pictures, slices, blocks, etc.). If the number of intra prediction modes included in the specific MPM list is less than the maximum number, a predetermined mode may be added to the specific MPM list. The added mode may be a preset default mode, or an intra prediction mode included in another MPM list. Notably, modes different from the intra prediction modes included in the specific MPM list may be added. Redundancy checks between MPM lists can be omitted. One of the MPM lists may share at least one same intra prediction mode with another MPM list.
现在,将描述针对N个MPM列表被用于当前块的情况的另一实施例。Now, another embodiment will be described for the case where N MPM lists are used for the current block.
编码器可按照制作多个MPM列表的多个顺序中的至少一个顺序来制作范围从MPM_LIST_1到MPM_LIST_N的多个MPM列表。在N个MPM列表中的候选帧内预测模式的总数量可以是K。N和K可以是正整数。The encoder may make a plurality of MPM lists ranging from MPM_LIST_1 to MPM_LIST_N in at least one order of making a plurality of MPM lists. The total number of candidate intra prediction modes in the N MPM lists may be K. N and K can be positive integers.
例如,MPM_LIST_combined可以由N个MPM列表的候选帧内预测模式之中的K个或更少的候选帧内预测模式组成。For example, MPM_LIST_combined may be composed of K or less candidate intra prediction modes among N candidate intra prediction modes of the MPM list.
例如,如果在MPM_LIST_combined中存在与当前块的帧内预测模式相同的帧内预测模式,则指示在MPM_LIST_combined中是否存在与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_combined可被熵编码为第一值。这里,可另外地对关于MPM_LIST_combined的索引信息MPM_IDX_combined进行熵编码。For example, if the same intra prediction mode as the intra prediction mode of the current block exists in MPM_LIST_combined, the indicator MPM_FLAG_combined indicating whether the same intra prediction mode as the intra prediction mode of the current block exists in MPM_LIST_combined may be entropy Encoded as the first value. Here, the index information MPM_IDX_combined regarding MPM_LIST_combined may be additionally entropy-encoded.
在MPM_LIST_combined中不存在与当前块的帧内预测模式相同的帧内预测模式时,MPM_FLAG_combined可被熵编码为第二值。如果MPM_FLAG_combined是第二值,则可另外地对剩余帧内预测模式REM_MODE进行熵编码。When the same intra prediction mode as the intra prediction mode of the current block does not exist in MPM_LIST_combined, MPM_FLAG_combined may be entropy encoded to the second value. If MPM_FLAG_combined is the second value, the remaining intra prediction mode REM_MODE may be additionally entropy encoded.
解码器可对指示在MPM_LIST_combined中是否存在与当前块的帧内预测模式相同的帧内预测模式的指示符MPM_FLAG_combined进行熵解码。如果MPM_FLAG_combined是第一值,则可通过进一步对索引信息MPM_IDX_combined进行熵解码来推导当前块的帧内预测模式。如果MPM_FLAG_combined是第二值,则可通过另外地对剩余帧内预测模式REM_MODE进行熵解码来推导当前块的帧内预测模式。The decoder may entropy decode the indicator MPM_FLAG_combined indicating whether the same intra prediction mode as the intra prediction mode of the current block exists in MPM_LIST_combined. If MPM_FLAG_combined is the first value, the intra prediction mode of the current block may be derived by further entropy decoding the index information MPM_IDX_combined. If MPM_FLAG_combined is the second value, the intra prediction mode of the current block may be derived by additionally entropy decoding the remaining intra prediction mode REM_MODE.
根据本发明,可通过进行编码/解码来推导当前块的帧内预测模式。这里,可在不使用邻近块的帧内预测模式的情况下对当前块的帧内预测模式进行熵编码/解码。According to the present invention, the intra prediction mode of the current block can be derived by performing encoding/decoding. Here, the intra prediction mode of the current block may be entropy encoded/decoded without using the intra prediction mode of the neighboring block.
根据本发明,不同颜色分量的帧内预测模式可被用于推导当前块的帧内预测模式。例如,如果当前块是色度块,则与目标色度块相应的一个或更多个相应亮度块的帧内预测模式可被用于推导当前块的帧内预测模式。可基于色度块的大小、形状或编码参数中的至少一个来确定所述相应亮度块。或者,可基于亮度块的大小、形状或编码参数中的至少一个来确定所述相应亮度块。According to the present invention, intra prediction modes of different color components can be used to derive the intra prediction mode of the current block. For example, if the current block is a chroma block, the intra prediction modes of one or more corresponding luma blocks corresponding to the target chroma block may be used to derive the intra prediction mode of the current block. The respective luma blocks may be determined based on at least one of a size, shape, or encoding parameter of the chroma block. Alternatively, the corresponding luma block may be determined based on at least one of a size, shape, or encoding parameter of the luma block.
图15是示出颜色分量的组成比为4:2:0的亮度块和色度块的示例性示图。FIG. 15 is an exemplary diagram showing a luminance block and a chrominance block in which the composition ratio of color components is 4:2:0.
在图15中示出的示例中,与色度块相应的相应亮度块可以是块A、块B、块C和块D中的至少一个。In the example shown in FIG. 15 , the corresponding luma block corresponding to the chroma block may be at least one of block A, block B, block C, and block D.
例如,与色度块的样点位置(0,0)相应的亮度块A的帧内预测模式可被推导作为色度块的帧内预测模式。For example, the intra prediction mode of luma block A corresponding to the sample position (0,0) of the chroma block can be derived as the intra prediction mode of the chroma block.
例如,与色度块的中心处的样点位置(nS/2,nS/2)相应的亮度块D的帧间预测模式可被推导作为色度块的帧内预测模式。For example, the inter prediction mode of the luma block D corresponding to the sample position (nS/2, nS/2) at the center of the chroma block can be derived as the intra prediction mode of the chroma block.
例如,可使用与色度块的大小相应的亮度块内的多个块中的一个或更多个块的帧内预测模式的组合来推导色度块的帧内预测模式。例如,和与样点位置(0,0)相应的亮度块A的帧内预测模式和与样点位置(nS/2,nS/2)相应的亮度块D的帧内预测模式的平均值所对应的模式可被推导作为色度块的帧内预测模式。或者,和与色度块的大小相应的亮度块内的块A、块B、块C和块D的帧内预测模式的平均值相应的模式可被推导作为色度块的帧内预测模式。可使用包括最大值、最小值、最频繁值、中值和加权平均值的各种统计值中的一个或更多个来代替平均值。For example, the intra prediction mode of the chroma block may be derived using a combination of the intra prediction modes of one or more blocks of a plurality of blocks within the luma block corresponding to the size of the chroma block. For example, the average value of the intra prediction mode of the luma block A corresponding to the sample position (0,0) and the intra prediction mode of the luma block D corresponding to the sample position (nS/2, nS/2) The corresponding mode can be derived as the intra prediction mode of the chroma block. Alternatively, a mode corresponding to the average value of the intra prediction modes of block A, block B, block C, and block D within the luma block corresponding to the size of the chroma block may be derived as the intra prediction mode of the chroma block. One or more of various statistical values including maximum, minimum, most frequent, median, and weighted average may be used in place of the average.
例如,可基于亮度块的大小、形状或深度中的至少一个来推导色度块的帧内预测模式。例如,可将与色度块的样点位置(0,0)相应的亮度块A的大小和与色度块的样点位置(nS/2,nS/2)相应的亮度块D的大小进行比较,并将具有相对较大大小的亮度块D的帧内预测模式推导作为色度块的帧内预测模式。或者,如果与色度块的预定位置相应的亮度块的大小等于或大于色度块的大小,则可使用亮度块的帧内预测模式来推导色度块的帧内预测模式。For example, the intra prediction mode for the chroma block may be derived based on at least one of the size, shape, or depth of the luma block. For example, the size of the luma block A corresponding to the sample position (0,0) of the chroma block can be compared with the size of the luma block D corresponding to the sample position (nS/2, nS/2) of the chroma block. Compare and derive the intra prediction mode of the luma block D with a relatively large size as the intra prediction mode of the chroma block. Alternatively, if the size of the luma block corresponding to the predetermined position of the chroma block is equal to or larger than the size of the chroma block, the intra prediction mode of the luma block may be used to derive the intra prediction mode of the chroma block.
例如,可基于色度块的大小、形状或深度中的至少一个来推导色度块的帧内预测模式。例如,如果色度块的大小落在预定范围内,则与色度块的样点位置(0,0)相应的亮度块的帧内预测模式可被推导作为色度块的帧内预测模式。或者,如果色度块的大小落在预定范围内,则可将与色度块的样点位置(0,0)相应的亮度块的大小和与色度块的样点位置(nS/2,nS/2)相应的亮度块的大小进行比较,并将具有较大大小的亮度块的帧内预测模式推导作为色度块的帧内预测模式。或者,如果色度块被成形为矩形,则与色度块的中心位置相应的亮度块的帧内预测模式可被推导作为色度块的帧内预测模式。For example, the intra prediction mode of the chroma block may be derived based on at least one of the size, shape, or depth of the chroma block. For example, if the size of the chroma block falls within a predetermined range, the intra prediction mode of the luma block corresponding to the sample position (0,0) of the chroma block may be derived as the intra prediction mode of the chroma block. Alternatively, if the size of the chroma block falls within a predetermined range, the sum of the size of the luma block corresponding to the sample position (0,0) of the chroma block can be compared with the sample position (nS/2, nS/2) The sizes of the corresponding luma blocks are compared, and the intra prediction mode of the luma block with the larger size is derived as the intra prediction mode of the chroma block. Alternatively, if the chroma block is shaped into a rectangle, the intra prediction mode of the luma block corresponding to the center position of the chroma block may be derived as the intra prediction mode of the chroma block.
例如,如果当前块被划分为下层块或子块,则可使用用于推导当前块的帧内预测模式的上述多种方法中的至少一种方法来推导每个子块的帧内预测模式。For example, if the current block is divided into lower layer blocks or sub-blocks, the intra prediction mode of each sub-block may be derived using at least one of the above-described multiple methods for deriving the intra prediction mode of the current block.
当前块的大小和子块的大小可以是M×N。M和N可以是相同的正整数或者不同的正整数。例如,当前块或子块的大小可以是CTU、CU、SU(信令单元)、QTMax、QTMin、BTMax、BTMin、4×4、8×8、16×16、32×32、64×64、128×128、256×256、4×8、8×16、16×8、32×64、32×8和4×32中的至少一个。这里,QTMax和QTMin可分别表示允许划分为四叉树的最大大小和最小大小,BTMax和BTMin可分别表示允许划分为二叉树的最大大小和最小大小。在下文中,子块的大小可表示子块的划分结构。The size of the current block and the size of the sub-block can be M×N. M and N can be the same positive integer or different positive integers. For example, the size of the current block or sub-block can be CTU, CU, SU (signaling unit), QTMax, QTMin, BTMax, BTMin, 4×4, 8×8, 16×16, 32×32, 64×64, At least one of 128×128, 256×256, 4×8, 8×16, 16×8, 32×64, 32×8 and 4×32. Here, QTMax and QTMin can respectively represent the maximum size and the minimum size that are allowed to be divided into quadtrees, and BTMax and BTMin can respectively represent the maximum size and the minimum size that are allowed to be divided into binary trees. In the following, the size of the sub-block may represent the division structure of the sub-block.
子块大小可根据当前块的大小变化。例如,当前块的垂直大小和水平大小的1/N可以是子块大小。N可以是正整数,并且可以是2、4、8、16、32和64中的至少一个。例如,如果当前块的大小是32×32并且当前块的水平大小和垂直大小的1/N中的N是4,则子块大小可以是8×8。The sub-block size can vary based on the size of the current block. For example, 1/N of the vertical size and horizontal size of the current block can be the sub-block size. N may be a positive integer and may be at least one of 2, 4, 8, 16, 32, and 64. For example, if the size of the current block is 32×32 and N in 1/N of the horizontal and vertical sizes of the current block is 4, the sub-block size may be 8×8.
或者,子块大小可以是预定的固定大小,而不管当前块的大小如何。例如,子块大小可以是最小大小,而不管当前块的大小如何,并且子块大小可以是例如4×4。Alternatively, the sub-block size can be a predetermined fixed size regardless of the current block size. For example, the sub-block size may be the minimum size regardless of the size of the current block, and the sub-block size may be, for example, 4×4.
或者,可基于当前块的邻近块的划分结构来确定子块大小。例如,如果附近的邻近块被划分,则可通过对当前块进行划分来确定子块大小。Alternatively, the sub-block size may be determined based on the partition structure of neighboring blocks of the current block. For example, if a nearby neighboring block is divided, the sub-block size can be determined by dividing the current block.
可基于当前块的邻近块的帧内预测模式来确定子块大小。例如,可通过基于以下边界将块划分为子块来确定子块大小,其中,邻近块的帧内预测模式根据所述边界而变得不同。The sub-block size may be determined based on intra prediction modes of neighboring blocks of the current block. For example, the sub-block size may be determined by dividing the block into sub-blocks based on the boundaries in which intra prediction modes of adjacent blocks become different.
可基于邻近块的编码参数来确定子块大小。例如,可通过基于邻近块是帧内编码块还是帧间编码块将块划分为子块来确定子块大小。The sub-block size may be determined based on coding parameters of neighboring blocks. For example, the sub-block size may be determined by dividing the block into sub-blocks based on whether the adjacent block is an intra-coded block or an inter-coded block.
可将当前块大小、子块大小、以及当前块被N等分所依据的N中的至少一个固定为预定值。At least one of the current block size, the sub-block size, and N by which the current block is divided into N equal parts may be fixed to a predetermined value.
例如,在用于当前块的预定的固定大小是16×16的情况下,如果当前块的大小是16×16,则当前块可被划分为子块,并且用于每个子块的帧内预测模式可被推导。For example, in the case where the predetermined fixed size for the current block is 16×16, if the size of the current block is 16×16, the current block may be divided into sub-blocks, and intra prediction for each sub-block Patterns can be derived.
例如,在用于当前块的预定的固定大小是CTU并且N是4的情况下,如果当前块的大小是CTU,则可基于子块来推导帧内预测模式,其中,每个子块是通过将CTU的高度和宽度除以4而产生的。For example, in the case where the predetermined fixed size for the current block is CTU and N is 4, if the size of the current block is CTU, the intra prediction mode can be derived based on sub-blocks, where each sub-block is determined by The height and width of the CTU are divided by 4.
可将一个或更多个子块进一步划分为更小的块。例如,如果当前块的大小是32×32并且子块大小是16×16,则可将一个或更多个子块中的每一个划分为大小分别为8×8、4×4、16×8、4×16等的更小块。One or more sub-blocks can be further divided into smaller blocks. For example, if the current block size is 32×32 and the sub-block size is 16×16, each of the one or more sub-blocks can be divided into sizes of 8×8, 4×4, 16×8, Smaller blocks such as 4×16 etc.
当前块大小、子块大小、以及当前块被N等分所依据的N中的至少一个可被编码/解码。At least one of the current block size, the sub-block size, and N by which the current block is divided into N equal parts may be encoded/decoded.
用于当前块的子块的划分结构可被编码/解码。当前块被划分成的子块的大小和/或形状方面可以变化。此外,可针对每个子块推导帧内预测模式。The partition structure for the sub-blocks of the current block may be encoded/decoded. The sub-blocks into which the current block is divided may vary in size and/or shape. Furthermore, intra prediction modes can be derived for each sub-block.
可对指示使用邻近块的帧内预测模式来推导当前块的帧内预测模式的指示符(例如,标志)进行编码/解码。例如,所述指示符可以是NDIP_flag(邻近模式非独立帧内预测)。可针对当前块或每个子块中的至少一个对所述指示符进行编码/解码。可仅在当前块大小或子块大小与预定大小或预定大小范围相应时对所述指示符进行编码/解码。所述预定大小可以是例如64×64或BTMax。如上所述,当前块可被划分为多个子块。子块的划分结构可被预先定义或者被编码/解码。An indicator (eg, a flag) indicating that the intra prediction mode of a neighboring block is used to derive the intra prediction mode of the current block may be encoded/decoded. For example, the indicator may be NDIP_flag (neighbor mode non-independent intra prediction). The indicator may be encoded/decoded for at least one of the current block or each sub-block. The indicator may be encoded/decoded only when the current block size or sub-block size corresponds to a predetermined size or a predetermined size range. The predetermined size may be, for example, 64×64 or BTMax. As mentioned above, the current block may be divided into multiple sub-blocks. The division structure of sub-blocks can be predefined or encoded/decoded.
如果对于当前块,NDIP_flag是1,则可使用邻近块的帧内预测模式来推导当前块的帧内预测模式或当前块的每个子块的帧内预测模式。在这种情况下,可不对用于当前块和/或子块的prev_intra_luma_pred_flag、mpm_idx、rem_intra_luma_pred_mode、intra_chroma_pred_mode、split_flag、QB_flag、quadtree_flag、binarytree_flag和Btype_flag中的至少一个进行编码/解码。If NDIP_flag is 1 for the current block, the intra prediction mode of the neighboring block may be used to derive the intra prediction mode of the current block or the intra prediction mode of each sub-block of the current block. In this case, at least one of prev_intra_luma_pred_flag, mpm_idx, rem_intra_luma_pred_mode, intra_chroma_pred_mode, split_flag, QB_flag, quadtree_flag, binarytree_flag and Btype_flag for the current block and/or sub-block may not be encoded/decoded.
例如,如果对于当前块,NDIP_flag是1,则可对当前块的帧内预测模式进行解码,随后可使用解码的帧内预测模式以及邻近块的帧内预测模式来推导每个子块的帧内预测模式。在这种情况下,可不对用于子块的prev_intra_luma_pred_flag、mpm_idx、rem_intra_luma_pred_mode、intra_chroma_pred_mode、split_flag、QB_flag、quadtree_flag、binarytree_flag和Btype_flag中的至少一个进行编码/解码。For example, if NDIP_flag is 1 for the current block, the intra prediction mode of the current block can be decoded, and the decoded intra prediction mode and the intra prediction mode of the neighboring block can then be used to derive the intra prediction for each sub-block. model. In this case, at least one of prev_intra_luma_pred_flag, mpm_idx, rem_intra_luma_pred_mode, intra_chroma_pred_mode, split_flag, QB_flag, quadtree_flag, binarytree_flag and Btype_flag for the sub-block may not be encoded/decoded.
如果对于当前块,NDIP_flag是0,则可对与当前块或子块的帧内预测模式或子块的划分信息中的至少一个相关的信息进行编码/解码。If NDIP_flag is 0 for the current block, information related to at least one of the intra prediction mode of the current block or sub-block or the partition information of the sub-block may be encoded/decoded.
在当前块的多个子块之中,第一子块的帧内预测模式可按照与其它子块不同的方式被推导。第一子块可以是当前块中的多个子块之一。例如,第一子块可以是按Z字形扫描顺序的第一个子块。Among the plurality of sub-blocks of the current block, the intra prediction mode of the first sub-block may be derived in a different manner from other sub-blocks. The first sub-block may be one of multiple sub-blocks in the current block. For example, the first sub-block may be the first sub-block in the zigzag scanning order.
第一子块的帧内预测模式可以指初始模式。例如,如果每个子块的帧内预测模式被推导为在所述每个子块左侧和上方的块的帧内预测模式的平均值,则可按照不同方法来推导所述初始模式。用于推导所述初始模式的所述不同方法可以是根据本发明的用于推导帧内预测模式的多种方法中的至少一种方法。The intra prediction mode of the first sub-block may refer to the initial mode. For example, if the intra prediction mode of each sub-block is derived as the average of the intra prediction modes of blocks to the left and above each sub-block, the initial mode may be derived according to a different method. The different methods for deriving the initial mode may be at least one of a plurality of methods for deriving intra prediction modes according to the present invention.
例如,MPM列表中列出的第N(例如,第一)模式可被推导作为所述初始模式。或者,当前块的一个或更多个邻近块的帧内预测模式中的最频繁的一个可被推导作为所述初始模式。或者,针对当前块编码/解码的帧内预测模式可被推导作为所述初始模式。或者,针对第一子块编码/解码的帧内预测模式可被推导作为所述初始模式。For example, the Nth (eg, first) mode listed in the MPM list may be derived as the initial mode. Alternatively, the most frequent one of the intra prediction modes of one or more neighboring blocks of the current block may be derived as the initial mode. Alternatively, the intra prediction mode encoded/decoded for the current block may be derived as the initial mode. Alternatively, the intra prediction mode encoded/decoded for the first sub-block may be derived as the initial mode.
关于对用于当前块中的子块的帧内预测模式的推导,可按照任意顺序来推导一个或更多个子块的帧内预测模式。所述任意顺序可以是扫描顺序,并且所述扫描可与光栅扫描、右上扫描、垂直扫描、水平扫描、对角扫描和zigzag扫描中的至少一个相应。按照所述扫描顺序被推导帧内预测模式的子块的数量可以是1或更大。可根据邻近块的帧内预测模式来自适应地确定所述任意顺序。Regarding derivation of intra prediction modes for sub-blocks in the current block, intra prediction modes for one or more sub-blocks may be derived in any order. The arbitrary sequence may be a scanning sequence, and the scanning may correspond to at least one of a raster scan, an upper right scan, a vertical scan, a horizontal scan, a diagonal scan, and a zigzag scan. The number of sub-blocks from which intra prediction modes are derived in the scanning order may be 1 or greater. The arbitrary order may be adaptively determined based on the intra prediction modes of neighboring blocks.
图16是描绘推导当前块被划分成的一个或更多个子块中的每个子块的帧内预测模式的实施例的示图。16 is a diagram depicting an embodiment of deriving an intra prediction mode for each of one or more sub-blocks into which a current block is divided.
首先,可确定当前块的大小是否与预定大小相应(S1610)。可根据当前块的水平长度或垂直长度来确定所述预定大小。例如,在步骤S1610可依赖于当前块的水平长度或垂直长度是否是用于划分为子块的可划分长度来进行确定操作。First, it may be determined whether the size of the current block corresponds to a predetermined size (S1610). The predetermined size may be determined according to the horizontal length or vertical length of the current block. For example, the determination operation may be performed in step S1610 depending on whether the horizontal length or vertical length of the current block is a divisible length for dividing into sub-blocks.
例如,在当前块是水平长度和垂直长度相同的正方形的情况下,如果通过将水平长度和垂直长度中的每一个除以N而获得的长度等于或大于任意长度,则当前块的大小可与所述预定大小相应。例如,在N是4并且所述任意长度是4的情况下,如果当前块的大小是256×256、128×128、64×64、32×32和16×16之一,则当前块的大小可与所述预定大小相应。For example, in the case where the current block is a square with the same horizontal and vertical lengths, if the length obtained by dividing each of the horizontal and vertical lengths by N is equal to or greater than an arbitrary length, the size of the current block can be equal to The predetermined size corresponds. For example, in the case where N is 4 and the arbitrary length is 4, if the size of the current block is one of 256×256, 128×128, 64×64, 32×32, and 16×16, then the size of the current block Can correspond to the predetermined size.
例如,在当前块是水平长度和垂直长度不同的矩形的情况下,如果在通过将水平长度和垂直长度之中的较大者除以M而获得的长度与通过将水平长度和垂直长度之中的较小者除以N而获得的长度之中的较小者等于或大于任意长度,则当前块的大小可与所述预定大小相应。例如,在M是4,N是2,并且所述任意长度是4的情况下,如果当前块的大小是128×64、64×128、128×32、32×128、128×16、16×128、128×8、8×128、64×32、32×64、64×16、16×64、64×8、8×64、32×16、16×32、32×8、8×32、16×8和8×16中的一个,则当前块的大小可与所述预定大小相应。For example, in the case where the current block is a rectangle whose horizontal length and vertical length are different, if the length obtained by dividing the larger of the horizontal length and the vertical length by M is different from the length obtained by dividing the horizontal length and the vertical length If the smaller of the lengths obtained by dividing by N is equal to or greater than any length, the size of the current block may correspond to the predetermined size. For example, in the case where M is 4, N is 2, and the arbitrary length is 4, if the size of the current block is 128×64, 64×128, 128×32, 32×128, 128×16, 16× 128, 128×8, 8×128, 64×32, 32×64, 64×16, 16×64, 64×8, 8×64, 32×16, 16×32, 32×8, 8×32, One of 16×8 and 8×16, then the size of the current block may correspond to the predetermined size.
例如,如果当前块没有被进一步划分,则当前块的大小可与所述预定大小相应。例如,如果关于当前块的划分信息、四叉树划分信息和/或二叉树划分信息是0(表示当前块没有被划分),并且当前块的水平长度或垂直长度大于最小长度,则当前块的大小可与所述预定大小相应。这里,所述最小长度可以是4。For example, if the current block is not further divided, the size of the current block may correspond to the predetermined size. For example, if the division information, quadtree division information and/or binary tree division information about the current block is 0 (indicating that the current block is not divided), and the horizontal length or vertical length of the current block is greater than the minimum length, then the size of the current block Can correspond to the predetermined size. Here, the minimum length may be 4.
如果当前块的大小不与所述预定大小相应(在S1610中为否),则可对当前块的划分信息、当前块的帧内预测模式或子块的帧内预测模式中的至少一个进行解码(S1660)。如果当前块未被划分,则可对当前块的帧内预测模式进行解码。如果当前块被划分为子块,则可对每个子块的帧内预测模式进行解码。If the size of the current block does not correspond to the predetermined size (No in S1610), at least one of the division information of the current block, the intra prediction mode of the current block, or the intra prediction mode of the sub-block may be decoded (S1660). If the current block is not partitioned, the intra prediction mode of the current block may be decoded. If the current block is divided into sub-blocks, the intra prediction mode of each sub-block may be decoded.
如果当前块的大小与所述预定大小相应(在S1610中为是),则可对NDIP_flag进行解码(S1620)。在下一步骤中,可检查解码的NDIP_flag的值(S1630)。If the size of the current block corresponds to the predetermined size (Yes in S1610), the NDIP_flag may be decoded (S1620). In the next step, the value of the decoded NDIP_flag may be checked (S1630).
如果NDIP_flag是0(在S1630中为否),则可对关于当前块的划分信息、当前块的帧内预测模式、以及子块的帧内预测模式中的至少一个进行解码(S1660)。If NDIP_flag is 0 (NO in S1630), at least one of the division information on the current block, the intra prediction mode of the current block, and the intra prediction mode of the sub-block may be decoded (S1660).
如果NDIP_flag是1(在S1630中为是),则可将当前块划分为子块(S1640)。这里,可执行划分使得每个子块具有预定大小和/或形状。或者,可基于解码出的划分信息来执行划分。If NDIP_flag is 1 (Yes in S1630), the current block may be divided into sub-blocks (S1640). Here, the partitioning may be performed such that each sub-block has a predetermined size and/or shape. Alternatively, partitioning may be performed based on the decoded partitioning information.
在下一步骤中,可推导通过划分当前块而产生的子块的帧内预测模式(S1650)。可基于邻近块的帧内预测模式来推导块的帧内预测模式。或者,当前块的帧内预测模式可被解码并使用。In the next step, the intra prediction mode of the sub-block generated by dividing the current block may be derived (S1650). The intra prediction mode of a block may be derived based on the intra prediction modes of neighboring blocks. Alternatively, the intra prediction mode of the current block may be decoded and used.
可使用针对当前块或子块推导的帧内预测模式来执行帧内预测(S1670)。Intra prediction may be performed using the intra prediction mode derived for the current block or sub-block (S1670).
图17是描绘将当前块划分为子块的实施例的示图。Figure 17 is a diagram depicting an embodiment of dividing a current block into sub-blocks.
推导当前块中的多个子块的帧内预测模式的顺序可以是基于当前块的光栅扫描顺序。或者,推导当前块中的多个子块的帧内预测模式的顺序可以是基于预定块大小的光栅扫描顺序。例如,可按照C1、C2、C3、…、C16的顺序来推导子块的帧内预测模式。或者,可按照C1、C2、C5、C6、C3、C4、…、C12、C15、C16的顺序来推导子块的帧内预测模式。或者,可并行地推导每个子块的帧内预测模式。可按照用于推导当前块的帧内预测模式的多种方法中的至少一种方法来推导每个子块的帧内预测模式。The order of deriving the intra prediction modes of the plurality of sub-blocks in the current block may be based on the raster scanning order of the current block. Alternatively, the order in which intra prediction modes are derived for multiple sub-blocks in the current block may be a raster scanning order based on a predetermined block size. For example, the intra prediction mode of the sub-block may be derived in the order of C1, C2, C3, ..., C16. Alternatively, the intra prediction mode of the sub-block may be derived in the order of C1, C2, C5, C6, C3, C4, ..., C12, C15, C16. Alternatively, the intra prediction mode for each sub-block can be derived in parallel. The intra prediction mode of each sub-block may be derived according to at least one of a variety of methods for deriving the intra prediction mode of the current block.
例如,如果当前块被划分为子块并且用于每个子块的帧内预测模式被推导,则可使用邻近块的帧内预测模式。For example, if the current block is divided into sub-blocks and an intra-prediction mode for each sub-block is derived, the intra-prediction modes of neighboring blocks may be used.
例如,在每个子块的位置(0,0)处的样点左侧和上方的块的帧内预测模式的统计值可被推导作为所述每个子块的帧内预测模式。例如,如果所述统计值是平均值,则可通过下面的[等式4]来推导图17中示出的每个子块的帧内预测模式。For example, the statistical values of the intra prediction modes of blocks to the left and above the sample point at position (0,0) of each sub-block may be derived as the intra prediction modes of each sub-block. For example, if the statistical value is an average value, the intra prediction mode of each sub-block shown in FIG. 17 can be derived by [Equation 4] below.
[等式4][Equation 4]
C1=(j+d+1)>>1,C1=(j+d+1)>>1,
C2=(C1+e+1)>>1,C2=(C1+e+1)>>1,
C3=(C2+g+1)>>1,C3=(C2+g+1)>>1,
C4=(C3+g+1)>>1,C4=(C3+g+1)>>1,
C5=(j+C1+1)>>1,C5=(j+C1+1)>>1,
C6=(C5+C2+1)>>1,C6=(C5+C2+1)>>1,
C7=(C6+C3+1)>>1,C7=(C6+C3+1)>>1,
C8=(C7+C4+1)>>1,C8=(C7+C4+1)>>1,
C9=(k+C5+1)>>1,C9=(k+C5+1)>>1,
C10=(C9+C6+1)>>1,C10=(C9+C6+1)>>1,
C11=(C10+C7+1)>>1,C11=(C10+C7+1)>>1,
C12=(C11+C8+1)>>1,C12=(C11+C8+1)>>1,
C13=(l+C9+1)>>1,C13=(l+C9+1)>>1,
C14=(C13+C10+1)>>1,C14=(C13+C10+1)>>1,
C15=(C14+C11+1)>>1,C15=(C14+C11+1)>>1,
C16=(C15+C12+1)>>1。C16=(C15+C12+1)>>1.
或者,可将在每个子块的位置(0,0)处的样点左侧和上方的块的大小彼此进行比较,并且可将具有较大大小的块的帧内预测模式推导作为所述每个子块的帧内预测模式。如果两个块具有相同大小,则左侧和上方的块的帧内预测模式的平均值可被推导作为所述每个子块的帧内预测模式。Alternatively, the sizes of blocks to the left and above the sample at position (0,0) of each sub-block may be compared to each other, and the intra prediction mode of the block with the larger size may be derived as Intra prediction mode of sub-block. If two blocks have the same size, the average of the intra prediction modes of the left and upper blocks can be derived as the intra prediction mode of each sub-block.
或者,可将在每个子块的位置(0,0)处的样点的左侧和上方的块的帧内预测模式的大小彼此进行比较,并且可将具有较小值的帧内预测模式推导作为所述每个子块的帧内预测模式。如果两个模式的值相等,则两个模式之一可被推导作为所述每个子块的帧内预测模式。Alternatively, the sizes of the intra prediction modes of blocks to the left and above the sample at position (0,0) of each sub-block may be compared to each other, and the intra prediction mode with the smaller value may be derived As the intra prediction mode of each sub-block. If the values of the two modes are equal, one of the two modes may be derived as the intra prediction mode for each sub-block.
或者,可使用当前块的邻近块的帧内预测模式来推导每个子块的帧内预测模式。这里,可使用当前块的在每个子块的样点位置(0,0)左侧和/或上方的一个或更多个邻近块的帧内预测模式。例如,可通过下面的[等式5]来推导图17中示出的每个子块的帧内预测模式。Alternatively, the intra prediction mode of each sub-block may be derived using the intra prediction modes of neighboring blocks of the current block. Here, the intra prediction modes of one or more neighboring blocks to the left and/or above the sample position (0,0) of each sub-block of the current block may be used. For example, the intra prediction mode of each sub-block shown in FIG. 17 can be derived by [Equation 5] below.
[等式5][Equation 5]
C1=(j+d+1)>>1,C1=(j+d+1)>>1,
C2=e,C2=e,
C3=g,C3=g,
C4=g,C4=g,
C5=j,C5=j,
C6=(j+e+1)>>1,C6=(j+e+1)>>1,
C7=g,C7=g,
C8=g,C8=g,
C9=k,C9=k,
C10=k,C10=k,
C11=(k+g+1)>>1,C11=(k+g+1)>>1,
C12=g,C12=g,
C13=l,C13=l,
C14=l,C14=l,
C15=l,C15=l,
C16=(l+g+1)>>1。C16=(l+g+1)>>1.
或者,如果当前块的邻近块的帧内预测模式全部是非方向模式,则子块的帧内预测模式可被推导为所述非方向模式(例如,DC模式和平面模式)中的至少一个。Alternatively, if the intra prediction modes of neighboring blocks of the current block are all non-directional modes, the intra prediction mode of the sub-block may be derived as at least one of the non-directional modes (eg, DC mode and planar mode).
图18是描绘将当前块划分为子块的另一实施例的示图。Figure 18 is a diagram depicting another embodiment of dividing a current block into sub-blocks.
如图18中所示,当前块中的子块的大小和/或形状可变化。可通过编码/解码来确定当前块和/或子块的划分结构和/或大小。可按照用于推导当前块或子块的帧内预测模式的上述多种方法中的至少一种方法来推导每个子块的帧内预测模式。As shown in Figure 18, the size and/or shape of the sub-blocks in the current block may vary. The partition structure and/or size of the current block and/or sub-block may be determined through encoding/decoding. The intra-prediction mode of each sub-block may be derived according to at least one of the above-described multiple methods for deriving the intra-prediction mode of the current block or sub-block.
例如,在每个子块的位置(0,0)处的样点左侧和上方的块的帧内预测模式的统计值可被推导作为所述每个子块的帧内预测模式。例如,如果所述统计值是平均值,则可通过下面的[等式6]来推导图18中示出的子块的帧内预测模式。For example, the statistical values of the intra prediction modes of blocks to the left and above the sample point at position (0,0) of each sub-block may be derived as the intra prediction modes of each sub-block. For example, if the statistical value is an average value, the intra prediction mode of the sub-block shown in FIG. 18 can be derived by [Equation 6] below.
[等式6][Equation 6]
C1=(j+d+1)>>1,C1=(j+d+1)>>1,
C2=(C1+e+1)>>1,C2=(C1+e+1)>>1,
C3=(C2+g+1)>>1,C3=(C2+g+1)>>1,
C4=(k+C1+1)>>1,C4=(k+C1+1)>>1,
C5=(C4+C2+1)>>1,C5=(C4+C2+1)>>1,
C6=(l+C4+1)>>1,C6=(l+C4+1)>>1,
C7=(C6+C5+1)>>1,C7=(C6+C5+1)>>1,
C8=(C5+C3+1)>>1,C8=(C5+C3+1)>>1,
C9=(C8+C3+1)>>1,C9=(C8+C3+1)>>1,
C10=(C7+C8+1)>>1。C10=(C7+C8+1)>>1.
或者,与每个子块相邻的一个或更多个邻近块的帧内预测模式的统计值可被推导作为所述每个子块的帧内预测模式。例如,如果所述统计值是平均值,则可通过下面的等式[7]来推导图18中示出的每个子块的帧内预测模式。Alternatively, statistical values of intra prediction modes of one or more neighboring blocks adjacent to each sub-block may be derived as the intra prediction mode of each sub-block. For example, if the statistical value is an average value, the intra prediction mode of each sub-block shown in FIG. 18 can be derived by the following equation [7].
[等式7][Equation 7]
C1=(b+j+d)/3,C1=(b+j+d)/3,
C2=(C1+d+e)/3,C2=(C1+d+e)/3,
C3=(C2+e+g)/3,C3=(C2+e+g)/3,
C4=(k+j+C1)/3,C4=(k+j+C1)/3,
C5=(C4+C2+C1)/3,C5=(C4+C2+C1)/3,
C6=(l+C4+k)/3,C6=(l+C4+k)/3,
C7=(C6+C5+C4)/3,C7=(C6+C5+C4)/3,
C8=(C5+C3+C2)/3,C8=(C5+C3+C2)/3,
C9=(C8+C3)/2,C9=(C8+C3)/2,
C10=(C5+C8+C9+C7)/4。C10=(C5+C8+C9+C7)/4.
或者,如果当前块的邻近块的帧内预测模式全部是非方向模式,则子块的帧内预测模式可被推导为所述非方向模式(例如,DC模式和平面模式)中的至少一个。Alternatively, if the intra prediction modes of neighboring blocks of the current block are all non-directional modes, the intra prediction mode of the sub-block may be derived as at least one of the non-directional modes (eg, DC mode and planar mode).
在当前块被划分为子块并且用于每个子块的帧内预测模式被推导的情况下,可通过MPM来推导当前块的帧内预测模式,然后可使用推导出的当前块的帧内预测模式以及邻近块的帧内预测模式来推导每个子块的帧内预测模式。这里,可使用通过MPM推导出的当前块的帧内预测模式以及邻近块的帧内预测模式中的至少一个,按照用于推导当前块的帧内预测模式的多种方法中的至少一种方法来推导子块的帧内预测模式。如果通过MPM推导出的当前块的帧内预测模式是Pred_mpm,则可按照以下方式来推导子块的帧内预测模式。In a case where a current block is divided into sub-blocks and an intra prediction mode for each sub-block is derived, the intra prediction mode of the current block may be derived by MPM, and then the derived intra prediction of the current block may be used mode and the intra prediction modes of neighboring blocks to derive the intra prediction mode of each sub-block. Here, at least one of the intra prediction mode of the current block and the intra prediction mode of the neighboring block derived through the MPM may be used, according to at least one of a plurality of methods for deriving the intra prediction mode of the current block. to derive the intra prediction mode of the sub-block. If the intra prediction mode of the current block derived by MPM is Pred_mpm, the intra prediction mode of the sub-block can be derived as follows.
例如,可将在每个子块的位置(0,0)处的样点左侧和上方的块的帧内预测模式的平均值与Pred_mpm进行比较。如果所述平均值大于Pred_mpm,则可将Pred_mpm+1推导作为所述每个子块的帧内预测模式,如果所述平均值小于Pred_mpm,则可将Pred_mpm-1推导作为所述每个子块的帧内预测模式。或者,在每个子块的位置(0,0)处的样点左侧和上方的块的帧内预测模式的平均值、以及Pred_mpm可被推导作为所述每个子块的帧内预测模式。或者,可通过将在每个子块的位置(0,0)处的样点左侧和上方的块的帧内预测模式与Pred_mpm进行比较,并调整Pred_mpm来推导子块的帧内预测模式。这里,可使用以上描述的统计值中的至少一种统计值来代替平均值。For example, the average of the intra prediction modes of the blocks to the left and above the sample at position (0,0) of each sub-block may be compared to Pred_mpm. If the average value is greater than Pred_mpm, Pred_mpm+1 may be derived as the intra prediction mode of each sub-block, and if the average value is less than Pred_mpm, Pred_mpm-1 may be derived as the frame of each sub-block. Intra prediction mode. Alternatively, the average of the intra prediction modes of blocks to the left and above the sample point at position (0,0) of each sub-block, and Pred_mpm may be derived as the intra prediction mode of each sub-block. Alternatively, the intra prediction mode of a sub-block may be derived by comparing the intra prediction modes of blocks to the left and above the sample at position (0,0) of each sub-block with Pred_mpm and adjusting Pred_mpm. Here, at least one of the above-described statistical values may be used instead of the average value.
图19是描绘将当前块划分为子块的另一实施例的示图。Figure 19 is a diagram depicting another embodiment of dividing a current block into sub-blocks.
在图19中,在每个块上标记的编号表示块的帧内预测模式的编号。另外,Cx表示当前块的第x子块(x是1、…、16)。另外,箭头表示块的帧内预测模式的方向或角度。In FIG. 19 , the number marked on each block represents the number of the intra prediction mode of the block. In addition, Cx represents the x-th sub-block of the current block (x is 1,...,16). In addition, the arrow indicates the direction or angle of the intra prediction mode of the block.
例如,在每个子块的位置(0,0)处的样点左侧和上方的块的帧内预测模式的统计值可被推导作为所述每个子块的帧内预测模式。所述统计值可以是例如平均值。或者,如果邻近块的帧内预测模式中的至少一个是非方向模式,则子块的帧内预测模式可被推导为邻近块的帧内预测模式之中的方向模式。非方向模式可包括例如平面模式(模式编号0)和DC模式(模式编号1)。例如,可通过下面的等式[8]来推导图19中示出的每个子块的帧内预测模式。For example, the statistical values of the intra prediction modes of blocks to the left and above the sample point at position (0,0) of each sub-block may be derived as the intra prediction modes of each sub-block. The statistical value may be, for example, an average value. Alternatively, if at least one of the intra prediction modes of the neighboring blocks is a non-directional mode, the intra prediction mode of the sub-block may be derived as the directional mode among the intra prediction modes of the neighboring blocks. Non-directional modes may include, for example, planar mode (mode number 0) and DC mode (mode number 1). For example, the intra prediction mode of each sub-block shown in FIG. 19 can be derived by the following equation [8].
[等式8][Equation 8]
C1=(30+50+1)>>1=40C1=(30+50+1)>>1=40
C2=(40+50+1)>>1=45C2=(40+50+1)>>1=45
C3=45C3=45
C4=(45+58+1)>>1=52C4=(45+58+1)>>1=52
C5=(18+40+1)>>1=29C5=(18+40+1)>>1=29
C6=(29+45+1)>>1=37C6=(29+45+1)>>1=37
C7=(37+45+1)>>1=41C7=(37+45+1)>>1=41
C8=(41+52+1)>>1=47C8=(41+52+1)>>1=47
C9=(16+29+1)>>1=23C9=(16+29+1)>>1=23
C10=(23+37+1)>>1=30C10=(23+37+1)>>1=30
C11=(30+41+1)>>1=36C11=(30+41+1)>>1=36
C12=(36+47+1)>>1=42C12=(36+47+1)>>1=42
C13=23C13=23
C14=(23+30+1)>>1=27C14=(23+30+1)>>1=27
C15=(27+36+1)>>1=32C15=(27+36+1)>>1=32
C16=(32+42+1)>>1=37C16=(32+42+1)>>1=37
图20是描绘将当前块划分为子块的另一实施例的示图。Figure 20 is a diagram depicting another embodiment of dividing a current block into sub-blocks.
在图20中,在每个子块上标记的编号表示块的帧内预测模式的编号。另外,Cx表示当前块的第x子块(x是1、…、14)。另外,箭头表示用于块的帧内预测的方向或角度。In FIG. 20 , the number marked on each sub-block represents the number of the intra prediction mode of the block. In addition, Cx represents the x-th sub-block of the current block (x is 1,...,14). In addition, arrows indicate directions or angles for intra prediction of blocks.
在参照图20所描述的实施例中,可通过解码来推导当前块的帧内预测模式和子块的划分信息中的至少一个。可使用推导出的当前块的帧内预测模式、以及在每个子块的位置(0,0)处的样点左侧和上方的块的帧内预测模式的平均值来推导当前块中的每个子块的帧内预测模式。例如,如果推导出的当前块的帧内预测模式大于所述平均值,则可从推导出的当前块的帧内预测模式减去平均值的1/2。如果推导出的当前块的帧内预测模式等于或小于所述平均值,则可将推导出的当前块的帧内预测模式与所述平均值的1/2相加。这里,可使用以上描述的统计值中的至少一种统计值来代替所述平均值。In the embodiment described with reference to FIG. 20 , at least one of the intra prediction mode of the current block and the partition information of the sub-blocks may be derived through decoding. Each sub-block in the current block may be derived using the derived intra prediction mode of the current block, and the average of the intra prediction modes of blocks to the left and above the sample point at position (0,0) of each sub-block. Intra prediction mode of sub-block. For example, if the derived intra prediction mode of the current block is greater than the average value, 1/2 of the average value may be subtracted from the derived intra prediction mode of the current block. If the derived intra prediction mode of the current block is equal to or less than the average value, the derived intra prediction mode of the current block may be added to 1/2 of the average value. Here, at least one of the above-described statistical values may be used instead of the average value.
或者,如果邻近块的帧内预测模式中的至少一个是非方向模式,则子块的帧内预测模式可被推导为邻近块的帧内预测模式之中的方向模式。非方向模式可包括例如平面模式(模式编号0)和DC模式(模式编号1)。例如,如果推导出的当前块的帧内预测模式是52,则可通过下面的[等式9]来推导图20中示出的每个子块的帧内预测模式。Alternatively, if at least one of the intra prediction modes of the neighboring blocks is a non-directional mode, the intra prediction mode of the sub-block may be derived as the directional mode among the intra prediction modes of the neighboring blocks. Non-directional modes may include, for example, planar mode (mode number 0) and DC mode (mode number 1). For example, if the derived intra prediction mode of the current block is 52, the intra prediction mode of each sub-block shown in FIG. 20 can be derived by [Equation 9] below.
[等式9][Equation 9]
C1:abs(52-((30+50+1)>>1)+1)>>1=6,C1=52-6=46C1:abs(52-((30+50+1)>>1)+1)>>1=6,C1=52-6=46
C2:abs(52-((46+50+1)>>1)+1)>>1=2,C2=52-2=50C2:abs(52-((46+50+1)>>1)+1)>>1=2,C2=52-2=50
C3:abs(52-((50+64+1)>>1)+1)>>1=3,C3=52+3=55C3: abs(52-((50+64+1)>>1)+1)>>1=3, C3=52+3=55
C4:abs(52-((18+46+1)>>1)+1)>>1=10,C4=52-10=42C4:abs(52-((18+46+1)>>1)+1)>>1=10,C4=52-10=42
C5:abs(52-((42+50+1)>>1)+1)>>1=3,C5=52-3=49C5:abs(52-((42+50+1)>>1)+1)>>1=3,C5=52-3=49
C6:abs(52-((42+49+1)>>1)+1)>>1=3,C6=52-3=49C6:abs(52-((42+49+1)>>1)+1)>>1=3,C6=52-3=49
C7:abs(52-((49+55+1)>>1)+1)>>1=0,C7=52-0=52C7:abs(52-((49+55+1)>>1)+1)>>1=0,C7=52-0=52
C8:abs(52-((52+55+1)>>1)+1)>>1=1,C8=52+1=53C8:abs(52-((52+55+1)>>1)+1)>>1=1,C8=52+1=53
C9:abs(52-((16+42+1)>>1)+1)>>1=12,C9=52-12=40C9: abs(52-((16+42+1)>>1)+1)>>1=12, C9=52-12=40
C10:abs(52-((16+40+1)>>1)+1)>>1=12,C10=52-12=40C10:abs(52-((16+40+1)>>1)+1)>>1=12,C10=52-12=40
C11:abs(52-40+1)>>1=6,C11=52-6=46C11:abs(52-40+1)>>1=6,C11=52-6=46
C12:abs(52-((40+49+1)>>1)+1)>>1=4,C12=52-4=48C12:abs(52-((40+49+1)>>1)+1)>>1=4,C12=52-4=48
C13:abs(52-((48+49+1)>>1)+1)>>1=2,C13=52-2=50C13:abs(52-((48+49+1)>>1)+1)>>1=2,C13=52-2=50
C14:abs(52-((50+52+1)>>1)+1)>>1=1,C14=52-1=51C14:abs(52-((50+52+1)>>1)+1)>>1=1,C14=52-1=51
在推导帧内预测模式时,可将当前块划分为比当前块小的多个子块,然后可推导每个子块的帧内预测模式。这里,帧内预测模式可表示帧内预测方向。帧内预测模式可被包括在编码器和解码器中预先定义的帧内预测模式集合中。When deriving the intra prediction mode, the current block may be divided into multiple sub-blocks smaller than the current block, and then the intra prediction mode of each sub-block may be derived. Here, the intra prediction mode may represent an intra prediction direction. Intra prediction modes may be included in a predefined set of intra prediction modes in the encoder and decoder.
例如,可使用与当前块邻近的重建块之中的通过使用帧内预测被编码/解码的块的帧内预测模式中的至少一个、以及当前块的帧内预测模式来产生用于当前块的帧内预测方向场(IPDF)。可在产生IPDF的过程中使用预定变换模型。在IPDF被产生之后,可使用IPDF来确定当前块的每个子块的帧内预测模式。For example, at least one of the intra prediction modes of a block that is encoded/decoded by using intra prediction among reconstructed blocks adjacent to the current block and the intra prediction mode of the current block may be generated for the current block. Intra prediction direction field (IPDF). Predetermined transformation models can be used in the process of generating the IPDF. After the IPDF is generated, the IPDF can be used to determine the intra prediction mode for each sub-block of the current block.
另外,与以上的示例类似,如果当前块是从比当前块更大或比当前块深度更小的块划分出的,则当前块可以是所述比当前块更大或比当前块深度更小的块的子块。在这种情况下,可使用在与所述比当前块更大或比当前块深度更小的块邻近的重建块之中的通过帧内预测被编码/解码的块的帧内预测模式中的至少一个来推导当前块的帧内预测模式。可通过产生IPDF来推导当前块的帧内预测模式。In addition, similar to the above example, if the current block is divided from a block larger than the current block or smaller than the current block depth, the current block may be larger than the current block or smaller than the current block depth. A sub-block of a block. In this case, the intra prediction mode of the block encoded/decoded by intra prediction among the reconstructed blocks adjacent to the block larger than the current block or smaller than the current block depth may be used. At least one to derive the intra prediction mode of the current block. The intra prediction mode of the current block can be derived by generating an IPDF.
可将刚性变换、相似变换、仿射变换、单应性变换、3D变换和其它变换中的至少一种变换用作所述预定变换模型。单应性变换可以是透视变换。At least one of rigid transformation, similarity transformation, affine transformation, homography transformation, 3D transformation and other transformations may be used as the predetermined transformation model. The homography transformation can be a perspective transformation.
由于可使用与当前块邻近的重建块之中的通过使用帧内预测被编码/解码的块的帧内预测模式中的至少一个、以及当前块的帧内预测模式来推导从当前块划分出的每个子块的帧内预测模式,因此可减少对每个子块的帧内预测模式进行熵编码/解码所需的比特数。Since the split from the current block can be derived using at least one of the intra prediction modes of the block encoded/decoded by using intra prediction among the reconstructed blocks adjacent to the current block, and the intra prediction mode of the current block. Intra prediction mode for each sub-block, thus reducing the number of bits required to entropy encode/decode the intra prediction mode for each sub-block.
子块的大小可以小于或等于当前块的大小。例如,如果当前块的大小是M×N(M和N是正整数),则子块的大小可以是M/K×N/L。K和M可以是正整数,L可以是N的正因子。另外,M/K或N/L可以是正整数。The size of the sub-block can be less than or equal to the size of the current block. For example, if the size of the current block is M×N (M and N are positive integers), the size of the sub-block may be M/K×N/L. K and M can be positive integers, and L can be a positive factor of N. Additionally, M/K or N/L may be a positive integer.
另外,在当前块中可存在P个子块。P可以是0或者正整数。例如,在当前块中可存在1、2、4或16个子块。Additionally, there may be P sub-blocks in the current block. P can be 0 or a positive integer. For example, there may be 1, 2, 4 or 16 sub-blocks in the current block.
另外,当当前块被划分为子块时,可不单独对指示当前块是否已被划分为子块的信息进行熵编码/解码。可基于指示当前块的帧内预测模式是否已基于子块被推导的信息来确定当前块是否被划分为子块。In addition, when the current block is divided into sub-blocks, the information indicating whether the current block has been divided into sub-blocks may not be entropy encoded/decoded separately. Whether the current block is divided into sub-blocks may be determined based on information indicating whether the intra prediction mode of the current block has been derived based on the sub-blocks.
另外,由于使用与当前块邻近的重建块之中的通过使用帧内预测而被编码/解码的块的帧内预测模式中的至少一个、以及当前块的帧内预测模式来推导子块的帧内预测模式,因此可不对子块的帧内预测模式进行熵编码/解码。然而,可对当前块的帧内预测模式进行熵编码/解码。特别地,如果当前块由一个子块构成,则可不对当前块的帧内预测模式进行熵编码/解码,并且可使用与当前块邻近的重建块之中的通过帧内预测而被编码/解码的块的帧内预测模式中的至少一个来推导当前块的帧内预测模式。In addition, since the frame of the sub-block is derived using at least one of the intra prediction modes of the block encoded/decoded by using intra prediction among the reconstructed blocks adjacent to the current block and the intra prediction mode of the current block Intra prediction mode, so the intra prediction mode of the sub-block may not be entropy encoded/decoded. However, the intra prediction mode of the current block may be entropy encoded/decoded. In particular, if the current block is composed of one sub-block, the intra prediction mode of the current block may not be entropy encoded/decoded, and the intra prediction mode among the reconstructed blocks adjacent to the current block may be used to be encoded/decoded by intra prediction The intra prediction mode of the current block is derived from at least one of the intra prediction modes of the block.
用于IPDF产生的在与当前块邻近的重建块之中的通过使用帧内预测而被编码/解码的块可被称为种子块。种子块的位置可被称为种子点。包括种子点的种子块所具有的帧内预测模式可被称为种子点帧内预测模式(SPIPM)。A block encoded/decoded by using intra prediction among reconstructed blocks adjacent to the current block for IPDF generation may be called a seed block. The location of the seed block may be called a seed point. The intra prediction mode of the seed block including the seed points may be called a seed point intra prediction mode (SPIPM).
图21是描绘使用SPIPM推导当前块的帧内预测模式的实施例的示图。21 is a diagram depicting an embodiment of deriving an intra prediction mode for a current block using SPIPM.
在图21中所示的示例中,当前块的大小可以是16×16,并且每个子块的大小可以是(16/4)×(16/4)。这里,种子块可以是通过帧内预测已被编码/解码的多个邻近块中的至少一个。种子块或种子点可以位于相对于当前块的固定位置。或者,上方、左侧、左上方、右下方和右上方的块或位置中的至少一个可被确定为种子块或种子点。In the example shown in FIG. 21, the size of the current block may be 16×16, and the size of each sub-block may be (16/4)×(16/4). Here, the seed block may be at least one of a plurality of neighboring blocks that have been encoded/decoded through intra prediction. Seed blocks or seed points can be located at fixed positions relative to the current block. Alternatively, at least one of blocks or locations above, left, upper left, lower right, and upper right may be determined as a seed block or seed point.
例如,当前块的上方邻近块c、d、e、f和g中的至少一个的帧内预测模式可被用作SPIPM。For example, the intra prediction mode of at least one of the upper neighboring blocks c, d, e, f, and g of the current block may be used as SPIPM.
或者,与当前块邻近的右上方块h的帧内预测模式可被用作SPIPM。Alternatively, the intra prediction mode of the upper right block h adjacent to the current block may be used as SPIPM.
或者,与当前块邻近的左上方块a和b中的至少一个的帧内预测模式可被用作SPIPM。Alternatively, the intra prediction mode of at least one of the upper left blocks a and b adjacent to the current block may be used as SPIPM.
或者,与当前块邻近的左侧块i、j、k和l中的至少一个的帧内预测模式可被用作SPIPM。Alternatively, the intra prediction mode of at least one of the left blocks i, j, k, and l adjacent to the current block may be used as SPIPM.
或者,与当前块邻近的左下方块m的帧内预测模式可被用作SPIPM。Alternatively, the intra prediction mode of the lower left block m adjacent to the current block may be used as SPIPM.
例如,当前块的帧内预测模式也可被用作SPIPM。For example, the intra prediction mode of the current block can also be used as SPIPM.
可使用一个或更多个种子点的SPIPM来产生IPDF。IPDF can be generated using SPIPM of one or more seed points.
例如,如果用于确定预定变换模型的参数的多个种子点的坐标是(x_sp,y_sp)(sp=1,2,3,…),并且包括种子点的种子块的SPIPM是mode_sp(sp=1,2,3,…),则变换后的种子点的坐标(x_sp',y_sp')可被确定为(x_sp',y_sp')=(x_sp+dx,y_sp+dy)。这里,dx可表示x轴方向上的位移,dy可表示y轴方向上的位移。另外,可确定dx=D_sub*cosΘ和dy=D_sub*sinΘ。For example, if the coordinates of the plurality of seed points used to determine the parameters of the predetermined transformation model are (x_sp, y_sp) (sp=1,2,3,...), and the SPIPM of the seed block including the seed points is mode_sp (sp= 1,2,3,...), then the transformed coordinates of the seed point (x_sp', y_sp') can be determined as (x_sp', y_sp')=(x_sp+dx, y_sp+dy). Here, dx can represent the displacement in the x-axis direction, and dy can represent the displacement in the y-axis direction. In addition, dx=D_sub*cosΘ and dy=D_sub*sinΘ can be determined.
这里,可根据SPIPM来确定Θ。例如,如果帧内预测模式是如图6中所示的方向模式,则每个SPIPM可具有唯一的方向性,并且关于x轴的正角度可被确定为Θ。Here, Θ can be determined based on SPIPM. For example, if the intra prediction mode is the directional mode as shown in Figure 6, each SPIPM may have unique directivity, and the positive angle with respect to the x-axis may be determined as Θ.
例如,对于垂直帧内预测模式,Θ=270°。For example, for vertical intra prediction mode, Θ=270°.
例如,对于水平帧内预测模式,Θ=0°。For example, for horizontal intra prediction mode, Θ=0°.
例如,对于左下对角帧内预测模式,Θ=225°。For example, for the lower left diagonal intra prediction mode, Θ=225°.
例如,对于右上对角帧内预测模式,Θ=45°。For example, for the upper right diagonal intra prediction mode, Θ=45°.
例如,对于右下对角帧内预测模式,Θ=135°。For example, for the lower right diagonal intra prediction mode, Θ=135°.
这里,对于具有非方向性的帧内预测模式(诸如DC模式或平面模式),Θ可被确定为特定值。所述特定值可以是例如0、90、180或270度。Here, Θ may be determined as a specific value for an intra prediction mode with non-directionality, such as DC mode or planar mode. The specific value may be, for example, 0, 90, 180 or 270 degrees.
SPIPM可表示始自种子点的方向性,并且D_sub可表示具有该方向性的矢量的大小。可根据种子点所属的种子块的大小和/或形状来确定D_Sub的大小。另外,对于每个帧内预测模式,D_sub可具有固定值P。这里,P可以是0或者整数。例如,如果当前块的大小是M×N(M和N是正整数),并且D_cur=S(S是正整数),则K×L的种子块(K和L是正整数)的D_sub(sub=1,2,3,…)可被确定为D_sub=S*(K×L)/(M×N)。例如,如果在图21中当前块的大小是16×16,则D_cur=S并且可按照以下方法中的至少一种方法来确定种子块的D_sub。SPIPM can represent the directionality from the seed point, and D_sub can represent the magnitude of the vector with that directionality. The size of D_Sub may be determined based on the size and/or shape of the seed block to which the seed point belongs. In addition, D_sub may have a fixed value P for each intra prediction mode. Here, P can be 0 or an integer. For example, if the size of the current block is M×N (M and N are positive integers), and D_cur=S (S is a positive integer), then the K×L seed block (K and L are positive integers) has D_sub (sub=1, 2,3,...) can be determined as D_sub=S*(K×L)/(M×N). For example, if the size of the current block is 16×16 in FIG. 21, D_cur=S and D_sub of the seed block may be determined according to at least one of the following methods.
例如,对于种子块d或e,可确定D_sub=S*(4×8)/(16×16)=S/8。For example, for seed block d or e, it can be determined that D_sub=S*(4×8)/(16×16)=S/8.
例如,对于种子块g或j,可确定D_sub=S*(8×8)/(16×16)=S/4。For example, for seed block g or j, it can be determined that D_sub=S*(8×8)/(16×16)=S/4.
例如,对于种子块k或l,可确定D_sub=S*(8×4)/(16×16)=S/8。For example, for seed block k or l, it can be determined that D_sub=S*(8×4)/(16×16)=S/8.
例如,对于种子块m或h,可确定D_sub=S*(16×16)/(16×16)=S。For example, for seed block m or h, it can be determined that D_sub=S*(16×16)/(16×16)=S.
例如,对于每个种子块,D_sub可被确定为S。For example, D_sub may be determined as S for each seed block.
可通过制作SPIPM列表来配置候选以产生当前块的IPDF。可使用当前块的邻近块中的至少一个的帧内预测模式来产生SPIPM列表。例如,SPIPM可以是当前块的左上方(SPIPM_TL)、右上方(SPIPM_TR)、左下方(SPIPM_BL)和右下方(SPIPM_BR)的SPIPM中的一个或更多个的集合。对于W×H的当前块,SPIPM_TL可将关于当前块的位置(0,0)的上方邻近块、左上方邻近块和左侧邻近块的帧内预测模式中的至少一个用作候选。SPIPM_TR可将关于当前块的位置(W-1,0)的上方邻近块和右上方邻近块的帧内预测模式中的至少一个用作候选。SPIPM_BL可将关于当前块的位置(0,H-1)的左侧邻近块和左下方邻近块的帧内预测模式中的至少一个用作候选。SPIPM_BR可表示当前块的邻近块的帧内预测模式。或者,SPIPM_BR可被用于表示当前块的帧内预测模式。Candidates can be configured to produce the IPDF of the current block by making a SPIPM list. The SPIPM list may be generated using the intra prediction mode of at least one of the neighboring blocks of the current block. For example, the SPIPM may be a set of one or more of the SPIPMs of the upper left (SPIPM_TL), upper right (SPIPM_TR), lower left (SPIPM_BL), and lower right (SPIPM_BR) of the current block. For the current block of W×H, SPIPM_TL may use at least one of the intra prediction modes of the upper neighboring block, the upper left neighboring block, and the left neighboring block with respect to the position (0,0) of the current block as a candidate. SPIPM_TR may use at least one of the intra prediction modes of the upper neighboring block and the upper right neighboring block with respect to the position (W-1,0) of the current block as a candidate. SPIPM_BL may use at least one of the intra prediction modes of the left neighboring block and the lower left neighboring block with respect to the position (0, H-1) of the current block as candidates. SPIPM_BR may represent the intra prediction mode of neighboring blocks of the current block. Alternatively, SPIPM_BR may be used to represent the intra prediction mode of the current block.
在图21中所示的示例中,SPIPM_TL可具有邻近块d、b和j的帧内预测模式中的至少一个。另外,SPIPM_TR可具有邻近块g和h的帧内预测模式中的至少一个。另外,SPIPM_BL可具有邻近块i和m的帧内预测模式中的至少一个。另外,SPIPM_BR可具有当前块的帧内预测模式中的至少一个。In the example shown in FIG. 21, SPIPM_TL may have at least one of the intra prediction modes of neighboring blocks d, b, and j. In addition, SPIPM_TR may have at least one of intra prediction modes of adjacent blocks g and h. In addition, SPIPM_BL may have at least one of intra prediction modes of neighboring blocks i and m. In addition, SPIPM_BR may have at least one of the intra prediction modes of the current block.
另外,可按照预定顺序搜索种子块或种子点。例如,通过按照左、上、左下、右上和上的顺序搜索种子块或种子点,可由相应种子块或种子点处的帧内预测模式构成SPIPM列表。Additionally, seed blocks or seed points can be searched in a predetermined order. For example, by searching for seed blocks or seed points in the order of left, top, bottom left, top right, and top, a SPIPM list can be constructed from the intra prediction modes at the corresponding seed blocks or seed points.
为了制作SPIPM列表,可针对用于SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的每一个的多个候选中的至少一个候选,执行基于帧内预测模式之间的相似度去除具有与其它模式的方向不同的方向的帧内预测模式的处理。这里,帧内预测模式差(IPMD)可被用作用于测量相似度的准则。在制作SPIPM列表时可去除非方向模式(例如,DC_MODE和PLANAR_MODE)。In order to make the SPIPM list, removal of a plurality of candidates having a direction different from other modes based on similarity between intra prediction modes may be performed for at least one candidate among a plurality of candidates for each of SPIPM_TL, SPIPM_TR, SPIPM_BL, and SPIPM_BR. Directional intra prediction mode processing. Here, intra prediction mode difference (IPMD) may be used as a criterion for measuring similarity. Non-directional modes (for example, DC_MODE and PLANAR_MODE) can be removed when making SPIPM lists.
例如,如果在SPIPM_TL的三个候选模式SPIPM_TL_mode中的每一个与SPIPM_neighbor(neighbor=TR或BL或BR)的候选模式之间的比较中,IPMD=abs(SPIPM_TL_mode-SPIPM_neighbor)>Th1(Th1是正整数),则可从用于SPIPM_TL的候选集中去除相应模式。For example, if in the comparison between each of the three candidate modes of SPIPM_TL_mode and the candidate mode of SPIPM_neighbor (neighbor=TR or BL or BR), IPMD=abs(SPIPM_TL_mode-SPIPM_neighbor)>Th1 (Th1 is a positive integer) , then the corresponding pattern can be removed from the candidate set for SPIPM_TL.
例如,如果在SPIPM_TR的两个候选模式SPIPM_TR_mode中的每一个与SPIPM_neighbor(neighbor=TL或BL或BR)的候选模式之间的比较中,IPMD=abs(SPIPM_TR_mode-SPIPM_neighbor)>Th2(Th2是正整数),则可从用于SPIPM_TR的候选集中去除相应模式。For example, if in a comparison between each of the two candidate modes of SPIPM_TR_SPIPM_TR_mode and the candidate mode of SPIPM_neighbor (neighbor=TL or BL or BR), IPMD=abs(SPIPM_TR_mode-SPIPM_neighbor)>Th2 (Th2 is a positive integer) , then the corresponding pattern can be removed from the candidate set for SPIPM_TR.
例如,如果在SPIPM_BL的两个候选模式SPIPM_BL_mode中的每一个与SPIPM_neighbor(neighbor=TL或TR或BR)的候选模式之间的比较中,IPMD=abs(SPIPM_BL_mode-SPIPM_neighbor)>Th3(Th3是正整数),则可从用于SPIPM_BL的候选集中去除相应模式。For example, if in the comparison between each of the two candidate modes of SPIPM_BL_mode SPIPM_BL_mode and the candidate mode of SPIPM_neighbor (neighbor=TL or TR or BR), IPMD=abs(SPIPM_BL_mode-SPIPM_neighbor)>Th3 (Th3 is a positive integer) , then the corresponding pattern can be removed from the candidate set for SPIPM_BL.
例如,如果在SPIPM_BR的候选模式SPIPM_BR_mode中的每一个与SPIPM_neighbor(neighbor=TL或TR或BL)的候选模式之间的比较中,IPMD=abs(SPIPM_BR_mode-SPIPM_neighbor)>Th4(Th4是正整数),则可从用于SPIPM_BR的候选集中去除相应模式。For example, if in the comparison between each of the candidate modes of SPIPM_BR_mode and the candidate mode of SPIPM_neighbor (neighbor=TL or TR or BL), IPMD=abs(SPIPM_BR_mode-SPIPM_neighbor)>Th4 (Th4 is a positive integer), then The corresponding pattern may be removed from the candidate set for SPIPM_BR.
例如,如果用于SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的每一个的多个候选中的至少一个候选是非方向帧内预测模式(诸如DC模式或平面模式),则可从候选集中去除相应模式。For example, if at least one candidate among the plurality of candidates for each of SPIPM_TL, SPIPM_TR, SPIPM_BL, and SPIPM_BR is a non-directional intra prediction mode (such as DC mode or planar mode), the corresponding mode may be removed from the candidate set.
在用于制作SPIPM列表的多个候选之中的具有最小相似度的候选被去除之后,可根据使用的特定2D变换模型来确定用于IPDF产生所需的SPIPM的数量。例如,2D变换模型可包括刚性变换、相似变换、仿射变换和单应变换。另外,SPIPM的数量可根据2D变换模型被确定为变量值1、2、3、4、或N(N是正整数)。After the candidate with the smallest similarity among the multiple candidates used to make the SPIPM list is eliminated, the number of SPIPM required for IPDF generation can be determined based on the specific 2D transformation model used. For example, the 2D transformation model may include rigid transformation, similarity transformation, affine transformation, and homography transformation. In addition, the number of SPIPM can be determined as a variable value of 1, 2, 3, 4, or N (N is a positive integer) according to the 2D transformation model.
例如,如果用于IPDF产生的变换模型是刚性变换,则可需要至少两个SPIPM。For example, if the transformation model used for IPDF generation is a rigid transformation, at least two SPIPM may be required.
如[等式10]中所述,刚性变换可具有自由度3(3-DoF)。这里,(x,y)可以是种子点的预变换(pre-transform)坐标,并且(x’,y’)可以是种子点的后变换(post-transform)坐标。Θ、tx和ty是待确定的模型参数,其中,Θ、tx和ty可以分别是旋转角度、x轴位移和y轴位移。As stated in [Equation 10], the rigid transformation can have 3 degrees of freedom (3-DoF). Here, (x, y) may be the pre-transform coordinates of the seed point, and (x', y') may be the post-transform coordinates of the seed point. Θ, tx and ty are the model parameters to be determined, where Θ, tx and ty can be the rotation angle, x-axis displacement and y-axis displacement respectively.
[等式10][Equation 10]
可使用从一个SPIPM确定的Θ来获取(x,y)-(x’,y’)对,并且可通过将(x,y)-(x’,y’)对代入[等式10]来确定与Θ、tx和ty相关的两个等式。另外,可从两个SPIPM确定与Θ、tx和ty相关的四个等式,并且可使用所述四个等式中的三个等式来确定刚性变换模型。The (x,y)-(x',y') pair can be obtained using Θ determined from a SPIPM and can be obtained by substituting the (x,y)-(x',y') pair into [Eq. 10] Determine the two equations related to Θ, tx, and ty. Additionally, four equations related to Θ, tx, and ty can be determined from the two SPIPMs, and three of the four equations can be used to determine the rigid transformation model.
可通过选择SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的至少两个来确定所述两个SPIPM。所选择的SPIPM可被添加到SPIPM列表。The two SPIPMs may be determined by selecting at least two of SPIPM_TL, SPIPM_TR, SPIPM_BL and SPIPM_BR. The selected SPIPM can be added to the SPIPM list.
图22是描绘制作包括两个SPIPM的SPIPM列表的实施例的示图。Figure 22 is a diagram depicting an embodiment of making a SPIPM list including two SPIPMs.
如图22中所示,可按照两个SPIPM候选模式的IPMD总和的升序填充SPIPM列表。As shown in Figure 22, the SPIPM list may be populated in ascending order of the IPMD sum of the two SPIPM candidate modes.
例如,用于SPIPM_TL的候选模式之一和用于SPIPM_TR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TL and one of the candidate modes for SPIPM_TR may be used as two SPIPMs.
例如,用于SPIPM_TL的候选模式之一和用于SPIPM_BL的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TL and one of the candidate modes for SPIPM_BL may be used as two SPIPMs.
例如,用于SPIPM_TL的候选模式之一和用于SPIPM_BR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TL and one of the candidate modes for SPIPM_BR may be used as two SPIPMs.
例如,用于SPIPM_TR的候选模式之一和用于SPIPM_BL的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TR and one of the candidate modes for SPIPM_BL may be used as two SPIPMs.
例如,用于SPIPM_TR的候选模式之一和用于SPIPM_BR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TR and one of the candidate modes for SPIPM_BR may be used as two SPIPMs.
例如,用于SPIPM_BL的候选模式之一和用于SPIPM_BR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_BL and one of the candidate modes for SPIPM_BR may be used as two SPIPMs.
如果两个SPIPM未被填充,则可利用可用的SPIPM来填充SPIPM列表。例如,可使用SPIPM±delta来填充SPIPM列表。这里,delta可以是任意正整数,例如,1、2、3…。If two SPIPMs are not populated, the SPIPM list can be populated with available SPIPMs. For example, SPIPM±delta can be used to populate the SPIPM list. Here, delta can be any positive integer, for example, 1, 2, 3….
一旦两个SPIPM(SPIPM1、SPIPM2)被确定,则可通过[等式10]产生与Θ、tx和ty相关的四个等式。可使用四个等式中的三个等式来确定用于刚性变换模型的参数。确定的模型可被用于IPDF产生。Once the two SPIPMs (SPIPM1, SPIPM2) are determined, four equations related to Θ, tx and ty can be generated by [Equation 10]. Three of the four equations can be used to determine the parameters for the rigid transformation model. The determined model can be used for IPDF generation.
例如,可使用通过SPIM1计算出的两个等式和通过SPIM2计算出的两个等式中的至少一个等式来确定刚性变换。For example, the rigid transformation may be determined using at least one of the two equations calculated by SPIM1 and the two equations calculated by SPIM2.
例如,可使用通过SPIM1计算出的两个等式中的至少一个和通过SPIM2计算出的两个等式来确定刚性变换。For example, the rigid transformation may be determined using at least one of the two equations calculated by SPIM1 and the two equations calculated by SPIM2.
例如,如果相似变换被用作用于IPDF产生的变换模型,则可能需要至少两个SPIPM。For example, if similarity transformation is used as the transformation model for IPDF generation, at least two SPIPM may be required.
相似变换可具有如[等式11]中所述的4-DoF。这里,(x,y)可以是种子点的预变换坐标,(x’,y’)可以是种子点的后变换坐标。a、b、c和d可以是将被确定的模型参数。Similar transformations may have 4-DoF as described in [Equation 11]. Here, (x, y) can be the pre-transformed coordinates of the seed point, and (x’, y’) can be the post-transformed coordinates of the seed point. a, b, c and d may be model parameters to be determined.
[等式11][Equation 11]
可使用从一个SPIPM确定的Θ来获取(x,y)-(x’,y’)对,并且可通过将(x,y)-(x’,y’)对代入[等式11]来确定与a、b、c和d相关的两个等式。另外,可从两个SPIPM确定与a、b、c和d相关的四个等式,并且可使用该四个等式来获得相似变换模型。The (x,y)-(x',y') pair can be obtained using Θ determined from a SPIPM and can be obtained by substituting the (x,y)-(x',y') pair into [Eq. 11] Identify the two equations related to a, b, c, and d. In addition, four equations related to a, b, c, and d can be determined from the two SPIPMs, and the similarity transformation model can be obtained using the four equations.
可通过选择SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的至少两个来确定两个SPIPM。所选择的SPIPM可被添加到SPIPM列表。这里,如等式22中所示,可按照两个SPIPM候选模式的IPMD值的总和的升序来填充SPIPM列表。The two SPIPMs may be determined by selecting at least two of SPIPM_TL, SPIPM_TR, SPIPM_BL and SPIPM_BR. The selected SPIPM can be added to the SPIPM list. Here, as shown in Equation 22, the SPIPM list may be populated in ascending order of the sum of IPMD values of the two SPIPM candidate modes.
例如,用于SPIPM_TL的候选模式之一和用于SPIPM_TR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TL and one of the candidate modes for SPIPM_TR may be used as two SPIPMs.
例如,用于SPIPM_TL的候选模式之一和用于SPIPM_BL的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TL and one of the candidate modes for SPIPM_BL may be used as two SPIPMs.
例如,用于SPIPM_TL的候选模式之一和用于SPIPM_BR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TL and one of the candidate modes for SPIPM_BR may be used as two SPIPMs.
例如,用于SPIPM_TR的候选模式之一和用于SPIPM_BL的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TR and one of the candidate modes for SPIPM_BL may be used as two SPIPMs.
例如,用于SPIPM_TR的候选模式之一和用于SPIPM_BR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_TR and one of the candidate modes for SPIPM_BR may be used as two SPIPMs.
例如,用于SPIPM_BL的候选模式之一和用于SPIPM_BR的候选模式之一可被用作两个SPIPM。For example, one of the candidate modes for SPIPM_BL and one of the candidate modes for SPIPM_BR may be used as two SPIPMs.
如果两个SPIPM未被填充,则可利用可用的SPIPM来填充SPIPM列表。例如,可使用SPIPM±delta来填充SPIPM列表。这里,delta可以是任意正整数,例如,1、2、3…。If two SPIPMs are not populated, the SPIPM list can be populated with available SPIPMs. For example, SPIPM±delta can be used to populate the SPIPM list. Here, delta can be any positive integer, for example, 1, 2, 3….
一旦两个SPIPM(SPIPM1、SPIPM2)被确定,则可通过[等式11]产生与Θ、tx和ty相关的四个等式来确定用于相似变换模型的参数。确定的模型可被用于IPDF产生。Once the two SPIPMs (SPIPM1, SPIPM2) are determined, the parameters for the similarity transformation model can be determined by [Equation 11] generating four equations related to Θ, tx, and ty. The determined model can be used for IPDF generation.
例如,如果仿射变换被用作用于IPDF产生的变换模型,则可能需要至少三个SPIPM。For example, if affine transformations are used as the transformation model for IPDF generation, at least three SPIPMs may be required.
仿射变换可具有如[等式12]中所述的6-DoF。这里,(x,y)可以是种子点的预变换坐标,(x’,y’)可以是种子点的后变换坐标。a、b、c、d、e和f可以是将被确定的模型参数。The affine transformation can have 6-DoF as described in [Equation 12]. Here, (x, y) can be the pre-transformed coordinates of the seed point, and (x’, y’) can be the post-transformed coordinates of the seed point. a, b, c, d, e and f may be model parameters to be determined.
[等式12][Equation 12]
可使用从一个SPIPM确定的Θ来获取(x,y)-(x’,y’)对,并且可通过将(x,y)-(x’,y’)对代入[等式12]来确定与a、b、c、d、e和f相关的两个等式。另外,可从三个SPIPM确定与a、b、c、d、e和f相关的六个等式,并且可使用该六个等式来获得仿射变换模型。The (x,y)-(x',y') pair can be obtained using Θ determined from a SPIPM and can be obtained by substituting the (x,y)-(x',y') pair into [Eq. 12] Identify the two equations related to a, b, c, d, e, and f. In addition, six equations related to a, b, c, d, e, and f can be determined from the three SPIPMs, and the affine transformation model can be obtained using the six equations.
可通过选择SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的至少三个来确定三个SPIPM。所选择的SPIPM可被添加到SPIPM列表。Three SPIPMs may be determined by selecting at least three of SPIPM_TL, SPIPM_TR, SPIPM_BL and SPIPM_BR. The selected SPIPM can be added to the SPIPM list.
图23是示出制作包括三个SPIPM的SPIPM列表的实施例的示例性示图。FIG. 23 is an exemplary diagram illustrating an embodiment of making a SPIPM list including three SPIPMs.
如图23中所示,可按照三个SPIPM候选模式的IPMD值的总和的升序来用SPIPM填充SPIPM列表。As shown in Figure 23, the SPIPM list may be populated with SPIPM in ascending order of the sum of the IPMD values of the three SPIPM candidate patterns.
例如,用于SPIPM_TL的候选模式之一、用于SPIPM_TR的候选模式之一和用于SPIPM_BL的候选模式之一可被用作三个SPIPM。For example, one of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_TR, and one of the candidate modes for SPIPM_BL may be used as three SPIPMs.
例如,用于SPIPM_TL的候选模式之一、用于SPIPM_TR的候选模式之一和用于SPIPM_BR的候选模式之一可被用作三个SPIPM。For example, one of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_TR, and one of the candidate modes for SPIPM_BR may be used as three SPIPMs.
例如,用于SPIPM_TL的候选模式之一、用于SPIPM_BL的候选模式之一和用于SPIPM_BR的候选模式之一可被用作三个SPIPM。For example, one of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_BL, and one of the candidate modes for SPIPM_BR may be used as three SPIPMs.
例如,用于SPIPM_TR的候选模式之一、用于SPIPM_BL的候选模式之一和用于SPIPM_BR的候选模式之一可被用作三个SPIPM。For example, one of the candidate modes for SPIPM_TR, one of the candidate modes for SPIPM_BL, and one of the candidate modes for SPIPM_BR may be used as three SPIPMs.
如果三个SPIPM未被填充,则可利用可用的SPIPM来填充SPIPM列表。例如,可使用SPIPM±delta来填充SPIPM列表。这里,delta可以是任意正整数,例如,1、2、3…。If three SPIPMs are not populated, the SPIPM list can be populated with available SPIPMs. For example, SPIPM±delta can be used to populate the SPIPM list. Here, delta can be any positive integer, for example, 1, 2, 3….
一旦三个SPIPM(SPIPM1、SPIPM2、SPIPM3)被确定,则可通过[等式12]产生与a、b、c、d、e和f相关的六个等式来确定用于仿射变换模型的参数。确定的模型可被用于IPDF产生。Once the three SPIPMs (SPIPM1, SPIPM2, SPIPM3) are determined, the six equations related to a, b, c, d, e and f can be generated by [Equation 12] to determine the affine transformation model. parameter. The determined model can be used for IPDF generation.
例如,如果单应变换(或透视变换)被用作用于IPDF产生的变换模型,则可能需要至少四个SPIPM。For example, if a homography transformation (or perspective transformation) is used as the transformation model for IPDF generation, at least four SPIPM may be required.
仿射变换可具有如[等式13]中描述的8-DoF。这里,(x,y)可以是种子点的预变换坐标,(x’,y’)可以是种子点的后变换坐标。h1、h2、h3、h4、h5、h6、h7和h8可以是将被确定的模型参数。The affine transformation can have 8-DoF as described in [Equation 13]. Here, (x, y) can be the pre-transformed coordinates of the seed point, and (x’, y’) can be the post-transformed coordinates of the seed point. h1, h2, h3, h4, h5, h6, h7 and h8 may be model parameters to be determined.
[等式13][Equation 13]
可使用从一个SPIPM确定的Θ来获取(x,y)-(x’,y’)对,并且可通过将(x,y)-(x’,y’)对代入[等式13]来确定与h1、h2、h3、h4、h5、h6、h7和h8相关的两个等式。另外,可从四个SPIPM确定与h1、h2、h3、h4、h5、h6、h7和h8相关的八个等式,并且可使用该八个等式来获得单应变换模型。The (x,y)-(x',y') pair can be obtained using Θ determined from a SPIPM and can be obtained by substituting the (x,y)-(x',y') pair into [Eq. 13] Identify the two equations related to h1, h2, h3, h4, h5, h6, h7, and h8. In addition, eight equations related to h1, h2, h3, h4, h5, h6, h7, and h8 can be determined from the four SPIPMs, and the eight equations can be used to obtain the homography transformation model.
可通过选择SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的至少四个来确定四个SPIPM。所选择的SPIPM可被添加到SPIPM列表。The four SPIPMs may be determined by selecting at least four of SPIPM_TL, SPIPM_TR, SPIPM_BL and SPIPM_BR. The selected SPIPM can be added to the SPIPM list.
图24是示出制作包括四个SPIPM的SPIPM列表的实施例的示例性示图。FIG. 24 is an exemplary diagram illustrating an embodiment of making a SPIPM list including four SPIPMs.
如图24中所示,可按照四个SPIPM候选模式的IMPD值的总和的升序利用SPIPM来顺序地填充SPIPM列表。As shown in Figure 24, the SPIPM list may be sequentially populated with SPIPM in ascending order of the sum of the IMPD values of the four SPIPM candidate patterns.
例如,用于SPIPM_TL的候选模式中的两个候选模式以及用于SPIPM_TR的候选模式中的两个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TL and two of the candidate modes for SPIPM_TR may be used as four SPIPMs.
例如,用于SPIPM_TL的候选模式中的两个候选模式以及用于SPIPM_BL的候选模式中的两个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TL and two of the candidate modes for SPIPM_BL may be used as four SPIPMs.
例如,用于SPIPM_TL的候选模式中的两个候选模式以及用于SPIPM_BR的候选模式中的两个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TL and two of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_BL的候选模式中的两个候选模式以及用于SPIPM_BR的候选模式中的两个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BL and two of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_BL的候选模式中的两个候选模式以及用于SPIPM_BR的候选模式中的两个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BL and two of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_TL的候选模式中的两个候选模式、用于SPIPM_TR的候选模式中的一个候选模式、以及用于SPIPM_BL的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_TR, and one of the candidate modes for SPIPM_BL may be used as four SPIPMs.
例如,用于SPIPM_TL的候选模式中的两个候选模式、用于SPIPM_TR的候选模式中的一个候选模式、以及用于SPIPM_BR的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_TR, and one of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_TL的候选模式中的两个候选模式、用于SPIPM_BL的候选模式中的一个候选模式、以及用于SPIPM_BR的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_BL, and one of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_TR的候选模式中的两个候选模式、用于SPIPM_TL的候选模式中的一个候选模式、以及用于SPIPM_BL的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TR, one of the candidate modes for SPIPM_TL, and one of the candidate modes for SPIPM_BL may be used as four SPIPMs.
例如,用于SPIPM_TR的候选模式中的两个候选模式、用于SPIPM_TL的候选模式中的一个候选模式、以及用于SPIPM_BR的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TR, one of the candidate modes for SPIPM_TL, and one of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_TR的候选模式中的两个候选模式、用于SPIPM_TL的候选模式中的一个候选模式、以及用于SPIPM_BL的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_TR, one of the candidate modes for SPIPM_TL, and one of the candidate modes for SPIPM_BL may be used as four SPIPMs.
例如,用于SPIPM_BL的候选模式中的两个候选模式、用于SPIPM_TL的候选模式中的一个候选模式、以及用于SPIPM_TR的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BL, one of the candidate modes for SPIPM_TL, and one of the candidate modes for SPIPM_TR may be used as four SPIPMs.
例如,用于SPIPM_BL的候选模式中的两个候选模式、用于SPIPM_TL的候选模式中的一个候选模式、以及用于SPIPM_BR的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BL, one of the candidate modes for SPIPM_TL, and one of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_BL的候选模式中的两个候选模式、用于SPIPM_TR的候选模式中的一个候选模式、以及用于SPIPM_BR的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BL, one of the candidate modes for SPIPM_TR, and one of the candidate modes for SPIPM_BR may be used as four SPIPMs.
例如,用于SPIPM_BR的候选模式中的两个候选模式、用于SPIPM_TL的候选模式中的一个候选模式、以及用于SPIPM_TR的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BR, one of the candidate modes for SPIPM_TL, and one of the candidate modes for SPIPM_TR may be used as four SPIPMs.
例如,用于SPIPM_BR的候选模式中的两个候选模式、用于SPIPM_TL的候选模式中的一个候选模式、以及用于SPIPM_BL的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BR, one of the candidate modes for SPIPM_TL, and one of the candidate modes for SPIPM_BL may be used as four SPIPMs.
例如,用于SPIPM_BR的候选模式中的两个候选模式、用于SPIPM_TR的候选模式中的一个候选模式、以及用于SPIPM_BL的候选模式中的一个候选模式可被用作四个SPIPM。For example, two of the candidate modes for SPIPM_BR, one of the candidate modes for SPIPM_TR, and one of the candidate modes for SPIPM_BL may be used as four SPIPMs.
例如,用于SPIPM_BR的候选模式中的一个候选模式、用于SPIPM_TR的候选模式中的一个候选模式、用于SPIPM_BL的候选模式中的一个候选模式、以及用于SPIPM_BR的候选模式中的一个候选模式可被用作四个SPIPM。For example, one of the candidate modes for SPIPM_BR, one of the candidate modes for SPIPM_TR, one of the candidate modes for SPIPM_BL, and one of the candidate modes for SPIPM_BR Can be used as four SPIPM.
如果四个SPIPM未被填充,则可利用可用的SPIPM来填充SPIPM列表。例如,可使用SPIPM±delta来填充SPIPM列表。这里,delta可以是任意正整数,例如,1、2、3…。If the four SPIPMs are not populated, the SPIPM list can be populated with the available SPIPMs. For example, SPIPM±delta can be used to populate the SPIPM list. Here, delta can be any positive integer, for example, 1, 2, 3….
一旦四个SPIPM(SPIPM1、SPIPM2、SPIPM3、SPIPM4)被确定,则可通过[等式13]产生与h1、h2、h3、h4、h5、h6、h7和h8相关的八个等式来确定用于单应变换模型的参数。确定的模型可被用于IPDF产生。Once the four SPIPMs (SPIPM1, SPIPM2, SPIPM3, SPIPM4) are determined, the eight equations related to h1, h2, h3, h4, h5, h6, h7, and h8 can be determined by [Equation 13]. Parameters for the homography transformation model. The determined model can be used for IPDF generation.
在使用预定变换模型产生IPDF之后,可使用产生的IPDF将帧内预测模式分配给W×H的当前块内的K×L子块。这里,每个子块的大小K×L(K是等于或小于M的正整数,L是等于或小于H的正整数)可以是等于或小于当前块的大小的固定大小。或者,可使用当前块的大小和/或IPMD来自适应地确定子块大小。或者,子块大小可等于当前块的大小。After generating an IPDF using a predetermined transform model, the generated IPDF may be used to assign an intra prediction mode to a K×L sub-block within a current block of W×H. Here, the size K×L of each sub-block (K is a positive integer equal to or smaller than M, and L is a positive integer equal to or smaller than H) may be a fixed size equal to or smaller than the size of the current block. Alternatively, the sub-block size may be adaptively determined using the current block size and/or IPMD. Alternatively, the sub-block size may be equal to the size of the current block.
图25是示出在当前块的大小是16×16的情况下的子块大小的示例性示图。FIG. 25 is an exemplary diagram showing the sub-block size in the case where the size of the current block is 16×16.
如图25的(a)中所示,子块的大小可被固定为8×8。或者,如图25的(b)中所示,子块的大小可被固定为4×4。或者,如图25的(c)中所示,子块的大小可被固定为2×2。或者,如图25的(d)中所示,子块的大小可被固定为1×1。固定大小1×1可以是样点单元的大小。As shown in (a) of FIG. 25, the size of the sub-block may be fixed to 8×8. Alternatively, as shown in (b) of FIG. 25 , the size of the sub-block may be fixed to 4×4. Alternatively, as shown in (c) of FIG. 25 , the size of the sub-block may be fixed to 2×2. Alternatively, as shown in (d) of FIG. 25, the size of the sub-block may be fixed to 1×1. The fixed size 1×1 can be the size of the sample unit.
例如,可基于当前块的大小来确定子块的大小。For example, the size of the sub-block may be determined based on the size of the current block.
例如,可基于当前块的SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的IPMD中的至少一个来确定子块的大小。For example, the size of the sub-block may be determined based on at least one of the IPMD of SPIPM_TL, SPIPM_TR, SPIPM_BL, and SPIPM_BR of the current block.
例如,可基于当前块的SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的IPMD中的至少一个以及当前块的大小来确定子块的大小。For example, the size of the sub-block may be determined based on at least one of the IPMDs of SPIPM_TL, SPIPM_TR, SPIPM_BL, and SPIPM_BR of the current block and the size of the current block.
可在比特流中熵编码/解码关于子块的大小的信息。这里,可在VPS、SPS、PPS、APS、条带头、并行块头、CTU、CU、PU、TU、块和子块中的至少一个中熵编码/解码该信息。Information about the size of the sub-blocks can be entropy encoded/decoded in the bitstream. Here, the information may be entropy encoded/decoded in at least one of VPS, SPS, PPS, APS, slice header, parallel block header, CTU, CU, PU, TU, block and sub-block.
可根据当前块的大小和/或IPMD自适应地推导关于子块大小的信息,而不发送该信息。Information about the sub-block size may be adaptively derived based on the size of the current block and/or the IPMD without sending this information.
另外,可基于当前块的编码参数和当前块的邻近块的编码参数中的至少一个来确定子块大小。In addition, the sub-block size may be determined based on at least one of a coding parameter of the current block and a coding parameter of a neighboring block of the current block.
可使用确定的IPDF来分配子块的帧内预测模式。可通过将每个子块中的特定位置的坐标代入确定的IPDF模型来将所述特定位置处的帧内预测模式实现为矢量。所述特定位置可被确定为子块中的像素的位置或者与子块的边界相邻的位置。例如,可将子块的左上位置、右上位置、左下位置、右下位置和中间位置中的至少一个确定为所述特定位置。如果子块中的所述特定位置的坐标是(x,y)并且通过IPDF计算出的位置的变换坐标是(x’,y’),则可通过θSB=atan[(y’-y)/(x’-x)]来确定所述矢量的方向θSB。The determined IPDF may be used to assign the intra prediction mode of the sub-block. The intra prediction mode at a specific position in each sub-block can be implemented as a vector by substituting the coordinates of the specific position into the determined IPDF model. The specific position may be determined as a position of a pixel in the sub-block or a position adjacent to a boundary of the sub-block. For example, at least one of the upper left position, the upper right position, the lower left position, the lower right position and the middle position of the sub-block may be determined as the specific position. If the coordinates of the specific position in the sub-block are (x, y) and the transformed coordinates of the position calculated by IPDF are (x', y'), then θSB =atan[(y'-y) /(x'-x)] to determine the direction of the vector θSB .
图26是描绘使用确定的IPDF分配帧内预测模式的实施例的示图。Figure 26 is a diagram depicting an embodiment of allocating intra prediction modes using determined IPDFs.
如图26中所示,θSB可被映射到多个方向模式之中的指向最相似方向的帧内预测模式。可使用查找表(LUT)来执行θSB到帧内预测模式映射的操作。As shown in FIG. 26 , θSB may be mapped to an intra prediction mode pointing in the most similar direction among a plurality of direction modes. ThetaSB to intra prediction mode mapping may be performed using a lookup table (LUT).
另外,当使用IPDF分配子块的帧内预测模式时,可基于最邻近方法将IDF分配为子块的帧内预测模式。In addition, when the IPDF is used to allocate the intra prediction mode of the sub-block, the IDF may be allocated as the intra prediction mode of the sub-block based on the nearest neighbor method.
此外,当使用IPDF将帧内预测模式分配给子块时,可通过将IPDF量化为整数来将帧内预测模式分配给子块。Furthermore, when an intra prediction mode is assigned to a sub-block using IPDF, the intra prediction mode may be assigned to the sub-block by quantizing the IPDF into an integer.
此外,当使用IPDF将帧内预测模式分配给子块时,可通过将IPDF四舍五入到最接近的整数来将帧内预测模式分配给子块。Furthermore, when an intra prediction mode is assigned to a sub-block using IPDF, the intra prediction mode may be assigned to the sub-block by rounding the IPDF to the nearest integer.
对于基于变换模型的逐子块帧内预测,将在比特流中被额外地熵编码/解码的信息可包括以下内容中的至少一个。For transform model-based sub-block intra prediction, information to be additionally entropy encoded/decoded in the bitstream may include at least one of the following.
指示基于变换模型的逐子块帧内预测是否已针对当前块被执行的信息:TBIP_flagInformation indicating whether transform model-based sub-block intra prediction has been performed for the current block: TBIP_flag
TBIP_flag可以是这样的信息:该信息指示是否使用在与当前块邻近的重建块之中的通过使用帧内预测而被编码/解码的块的帧内预测模式中的至少一个以及当前块的帧内预测模式来推导每个子块的帧内预测模式。TBIP_flag may be information indicating whether to use at least one of the intra prediction modes of the block encoded/decoded by using intra prediction among the reconstructed blocks adjacent to the current block and the intra prediction mode of the current block. prediction mode to derive the intra prediction mode for each sub-block.
指示所使用的SPIPM集的索引:SPIPM_idxIndex indicating the SPIPM set used: SPIPM_idx
现在,将描述使用变换模型基于子块推导帧内预测模式的另一实施例。例如,在邻近重建块之中存在通过基于变换模型的逐子块帧内预测而被编码/解码的块时,可使用邻近块的IPDF模型针对每个子块推导帧内预测模式,而不是直接产生当前块的IPDF。Now, another embodiment of deriving intra prediction modes based on sub-blocks using a transform model will be described. For example, when there is a block encoded/decoded by transform model-based sub-block intra prediction among neighboring reconstructed blocks, the intra prediction mode can be derived for each sub-block using the IPDF model of the neighboring block instead of directly generating The IPDF of the current block.
为了确定在当前块的邻近重建块之中是否存在通过基于变换模型的逐子块帧内预测而被编码/解码的任何块,可使用预定义的扫描顺序。所述扫描顺序可以是以下顺序中的至少一个。In order to determine whether there are any blocks encoded/decoded by transform model-based sub-block intra prediction among neighboring reconstructed blocks of the current block, a predefined scanning order may be used. The scanning order may be at least one of the following orders.
图27是示出与当前块邻近的重建块的示例性示图。FIG. 27 is an exemplary diagram showing reconstructed blocks adjacent to the current block.
例如,在图27中,可按照A->B->C->D->E的顺序执行扫描。或者,可按照A->B->D->C->E的顺序执行扫描。或者,可按照B->A->D->C->E的顺序执行扫描。或者,可按照E->A->B->C->D的顺序执行扫描。或者,可按照任意其它顺序执行扫描。For example, in Figure 27, scanning may be performed in the order A->B->C->D->E. Alternatively, scans can be performed in the order A->B->D->C->E. Alternatively, scans can be performed in the order B->A->D->C->E. Alternatively, scans can be performed in the order E->A->B->C->D. Alternatively, the scans can be performed in any other order.
或者,在扫描时可以排除块A、B、C、D和C中的一部分。或者,可扫描除了A、B、C、D和C之外的块。可基于如这里所描述的邻近重建块和当前块中的至少一个的大小、形状和编码参数中的至少一个来确定将被扫描的邻近重建块。Alternatively, some of the blocks A, B, C, D and C can be excluded from scanning. Alternatively, blocks other than A, B, C, D, and C can be scanned. The neighboring reconstruction blocks to be scanned may be determined based on at least one of the size, shape, and encoding parameters of at least one of the neighboring reconstruction blocks and the current block as described herein.
图28是描绘使用邻近重建块推导帧内预测模式的实施例的示图。Figure 28 is a diagram depicting an embodiment of deriving intra prediction modes using neighboring reconstructed blocks.
在图28中所示出的示例中,在作为当前块的邻近块的块A使用变换模型通过子块单元的帧内预测被编码/解码的情况下,可使用SPIPM_A_TL、SPIPM_A_TR、SPIPM_A_BL和SPIPM_A_BR中的至少一个来产生块A的IPDF。In the example shown in FIG. 28 , in the case where block A, which is a neighboring block of the current block, is encoded/decoded by intra prediction in sub-block units using a transform model, SPIPM_A_TL, SPIPM_A_TR, SPIPM_A_BL, and SPIPM_A_BR may be used. of at least one to generate the IPDF of block A.
可使用块A的IPDF来推导当前块的SPIPM_Cur_TL、SPIPM_Cur_TR、SPIPM_Cur_BL和SPIPM_Cur_BR中的至少一个,并且可使用推导出的SPIPM_Cur_TL、SPIPM_Cur_TR、SPIPM_Cur_BL和SPIPM_Cur_BR中的至少一个来产生当前块的IPDF,从而执行逐子块帧内预测。The IPDF of block A may be used to derive at least one of SPIPM_Cur_TL, SPIPM_Cur_TR, SPIPM_Cur_BL, and SPIPM_Cur_BR of the current block, and at least one of the derived SPIPM_Cur_TL, SPIPM_Cur_TR, SPIPM_Cur_BL, and SPIPM_Cur_BR may be used to generate the IPDF of the current block, thereby performing step-by-step Sub-block intra prediction.
如果当前块的邻近重建块中的至少一个是使用IPDF而被编码/解码的块,则可使用相应邻近重建块的IPDF来推导当前块的IPDF。此外,可对TBIP_flag的信息进行熵编码/解码。If at least one of the neighboring reconstruction blocks of the current block is a block that was encoded/decoded using IPDF, the IPDF of the corresponding neighboring reconstruction block may be used to derive the IPDF of the current block. In addition, the information of TBIP_flag can be entropy encoded/decoded.
将描述使用等空间模型基于子块推导帧内预测模式的另一实施例。Another embodiment of deriving intra prediction modes based on sub-blocks using an iso-spatial model will be described.
图29是描绘基于子块推导帧内预测模式的实施例的示图。Figure 29 is a diagram depicting an embodiment of deriving intra prediction modes based on sub-blocks.
在等空间模型被使用的情况下,可能需要至少两个SPIPM。例如,如图29的(a)中所示,可选择用于SPIPM_TL的候选模式之一、用于SPIPM_TR的候选模式之一、用于SPIPM_BL的候选模式之一和用于SPIPM_BR的候选模式之一,即总共四个候选模式。如图24中所示,可按照IPMD值的总和的升序将所选择的四个SPIPM候选模式填充在SPIPM列表中。In cases where equal spatial models are used, at least two SPIPM may be required. For example, as shown in (a) of FIG. 29 , one of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_TR, one of the candidate modes for SPIPM_BL, and one of the candidate modes for SPIPM_BR may be selected. , that is, a total of four candidate patterns. As shown in Figure 24, the selected four SPIPM candidate modes may be populated in the SPIPM list in ascending order of the sum of IPMD values.
可使用SPIPM_TL、SPIPM_TR、SPIPM_BL和/或SPIPM_BR来首先确定当前块的最外层子块的帧内预测模式。等空间地确定帧内预测模式可意味着使用至少两个帧内预测模式以相等的间隔划分帧内预测模式的值并将划分的帧内预测模式值分配给子块。SPIPM_TL, SPIPM_TR, SPIPM_BL and/or SPIPM_BR may be used to first determine the intra prediction mode of the outermost sub-block of the current block. Determining the intra prediction modes equally spatially may mean dividing the values of the intra prediction modes at equal intervals using at least two intra prediction modes and assigning the divided intra prediction mode values to the subblocks.
例如,在图29的(a)中所示的示例中,如果SPIPM_TL是24并且SPIPM_TR是21,则可使用SPIPM_TL和SPIPM_TR的值等空间地确定子块A、B、C和D的帧内预测模式。例如,如图29的(b)中所示,可确定A=24,B=23,C=22并且D=21。For example, in the example shown in (a) of FIG. 29 , if SPIPM_TL is 24 and SPIPM_TR is 21, the intra predictions of sub-blocks A, B, C, and D can be spatially determined using the values of SPIPM_TL and SPIPM_TR, etc. model. For example, as shown in (b) of FIG. 29 , A=24, B=23, C=22, and D=21 can be determined.
例如,在图29的(a)中所示的示例中,如果SPIPM_TL是25并且SPIPM_BL是38,则可使用SPIPM_TL和SPIPM_BL的值等空间地确定子块A、E、I和M的帧内预测模式。例如,如图29的(b)中所示,可确定A=24,E=29,I=34并且M=38。For example, in the example shown in (a) of FIG. 29 , if SPIPM_TL is 25 and SPIPM_BL is 38, the intra predictions of sub-blocks A, E, I, and M can be spatially determined using the values of SPIPM_TL and SPIPM_BL, etc. model. For example, as shown in (b) of FIG. 29 , it can be determined that A=24, E=29, I=34, and M=38.
例如,在图29的(a)中所示的示例中,如果SPIPM_BL是38并且SPIPM_BR是35,则可使用SPIPM_BL和SPIPM_BR的值等空间地确定子块M、N、O和P的帧内预测模式。例如,如图29的(b)中所示,可确定M=38,N=37,O=36并且P=35。For example, in the example shown in (a) of FIG. 29 , if SPIPM_BL is 38 and SPIPM_BR is 35, intra prediction of sub-blocks M, N, O, and P may be spatially determined using the values of SPIPM_BL and SPIPM_BR, etc. model. For example, as shown in (b) of FIG. 29 , it can be determined that M=38, N=37, O=36, and P=35.
例如,在图29的(a)中所示的示例中,如果SPIPM_TR是21并且SPIPM_BR是35,则可使用SPIPM_TR和SPIPM_BR的值等空间地确定子块D、H、I和P的帧内预测模式。例如,如图29的(b)中所示,可确定D=21、H=26、I=31并且P=35。For example, in the example shown in (a) of FIG. 29 , if SPIPM_TR is 21 and SPIPM_BR is 35, intra prediction of sub-blocks D, H, I, and P may be spatially determined using the values of SPIPM_TR and SPIPM_BR, etc. model. For example, as shown in (b) of FIG. 29 , D=21, H=26, I=31, and P=35 can be determined.
在当前块的最外层子块的帧内预测模式全部被确定之后,可确定第二最外层子块的帧内预测模式。在图29中所示的示例中,第二最外层子块可以是子块F、G、J和K。这里,可将SPIPM_TL重置为在第二最外层子块之中的左上方子块(图29的(a)中的子块F)的左上位置处的模式(图29的(a)中的子块A的模式)的值。另外,可将SPIPM_TR重置为在第二最外层子块之中的右上方子块(图29的(a)中的子块G)的右上位置处的模式(图29的(a)中的子块D的模式)的值。另外,可将SPIPM_BL重置为在第二最外层子块之中的左下方子块(图29的(a)中的子块J)的左下位置处的模式(图29的(a)中的子块M的模式)的值。另外,可将SPIPM_BR重置为在第二最外层子块之中的右下方子块(图29的(a)中的子块K)的右下位置处的模式(图29的(a)中的子块P的模式)的值。可递归地重复该操作直到当前块中的所有子块的模式被确定为止。After the intra prediction modes of the outermost sub-block of the current block are all determined, the intra prediction mode of the second outermost sub-block may be determined. In the example shown in FIG. 29, the second outermost sub-block may be sub-blocks F, G, J, and K. Here, SPIPM_TL may be reset to the mode (in (a) of FIG. 29 ) at the upper left position of the upper left subblock (subblock F in (a) of FIG. 29 ) among the second outermost subblocks. The value of sub-block A's mode). In addition, SPIPM_TR may be reset to the mode (in (a) of FIG. 29 ) at the upper right position of the upper right subblock (subblock G in (a) of FIG. 29 ) among the second outermost subblocks. mode of sub-block D). In addition, SPIPM_BL may be reset to the mode (in (a) of FIG. 29 ) at the lower left position of the lower left subblock (subblock J in (a) of FIG. 29 ) among the second outermost subblocks. mode of sub-block M). In addition, SPIPM_BR may be reset to the mode ((a) of FIG. 29 ) at the lower right position of the lower right subblock (subblock K in (a) of FIG. 29 ) among the second outermost subblocks. The value of the pattern of sub-block P in . This operation may be repeated recursively until the patterns of all sub-blocks in the current block are determined.
例如,在图29的(b)中所示的示例中,如果SPIPM_TL是24并且SPIPM_TR是21,则可使用SPIPM_TL和SPIPM_TR的值等空间地确定子块F和G的帧内预测模式。例如,如图29的(c)中所示,可确定F=24并且G=21。For example, in the example shown in (b) of FIG. 29 , if SPIPM_TL is 24 and SPIPM_TR is 21, the intra prediction modes of sub-blocks F and G may be spatially determined using the values of SPIPM_TL and SPIPM_TR, etc. For example, as shown in (c) of FIG. 29 , it can be determined that F=24 and G=21.
例如,在图29的(b)中所示的示例中,如果SPIPM_BL是38并且SPIPM_BR是35,则可使用SPIPM_TL和SPIPM_TR的值等空间地确定子块J和K的帧内预测模式。例如,如图29的(c)中所示,可确定J=38并且K=35。For example, in the example shown in (b) of FIG. 29 , if SPIPM_BL is 38 and SPIPM_BR is 35, the intra prediction modes of sub-blocks J and K may be spatially determined using the values of SPIPM_TL and SPIPM_TR, etc. For example, as shown in (c) of FIG. 29 , it can be determined that J=38 and K=35.
针对基于等空间模型的逐子块帧内预测将被额外熵编码/解码的信息可以是以下项中的至少一项。Information to be additionally entropy encoded/decoded for sub-block-wise intra prediction based on the equal spatial model may be at least one of the following items.
指示是否已针对当前块执行了基于等空间模型的逐子块帧内预测的信息:ES_flagInformation indicating whether equal space model-based sub-block intra prediction has been performed for the current block: ES_flag
指示所使用的SPIPM集的索引:SPIPM_idxIndex indicating the SPIPM set used: SPIPM_idx
现在,将描述使用双线性滤波器模型基于子块推导帧内预测模式的另一实施例。Now, another embodiment of deriving an intra prediction mode on a sub-block basis using a bilinear filter model will be described.
图30是描绘基于子块推导帧内预测模式的另一实施例的示图。Figure 30 is a diagram depicting another embodiment of deriving intra prediction modes based on sub-blocks.
为了使用双线性滤波器模型基于子块确定帧内预测模式,可能需要至少两个SPIPM。例如,如图30的(a)中所示,可通过选择用于SPIPM_TL的候选模式之一、用于SPIPM_TR的候选模式之一、用于SPIPM_BL的候选模式之一、以及用于SPIPM_BR的候选模式之一来选择总共四个候选模式。如图24中所示,可按照IPMD值的总和的升序将所选择的四个SPIPM候选模式顺序地填充在SPIPM列表中。In order to determine the intra prediction mode on a sub-block basis using a bilinear filter model, at least two SPIPM may be required. For example, as shown in (a) of FIG. 30 , the method can be configured by selecting one of the candidate modes for SPIPM_TL, one of the candidate modes for SPIPM_TR, one of the candidate modes for SPIPM_BL, and the candidate mode for SPIPM_BR. one to select a total of four candidate patterns. As shown in FIG. 24, the selected four SPIPM candidate modes may be sequentially populated in the SPIPM list in ascending order of the sum of IPMD values.
可将当前块中的左上方子块(图30的(a)中的子块A)的模式确定为SPIPM_TL。另外,可将当前块中的右上方子块(图30的(a)中的子块D)的模式确定为SPIPM_TR。另外,可将当前块中的左下方子块(图30的(a)中的子块M)的模式确定为SPIPM_BL。另外,可将当前块中的右下方子块(图30的(a)中的子块P)的模式确定为SPIPM_BR。如图30的(b)中所示,可将当前块中的左上方子块、右上方子块、左下方子块和右下方子块的帧内预测模式分别确定为SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR。然而,当前块中的左上方子块、右上方子块、左下方子块和右下方子块的帧内预测模式不限于SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR,并且当前块中的左上方子块、右上方子块、左下方子块和右下方子块的帧内预测模式中的至少一个可被确定为SPIPM_TL、SPIPM_TR、SPIPM_BL和SPIPM_BR中的至少一个。The mode of the upper left sub-block (sub-block A in (a) of FIG. 30 ) in the current block may be determined as SPIPM_TL. In addition, the mode of the upper right sub-block (sub-block D in (a) of FIG. 30 ) in the current block may be determined as SPIPM_TR. In addition, the mode of the lower left sub-block (sub-block M in (a) of FIG. 30 ) in the current block may be determined as SPIPM_BL. In addition, the mode of the lower right sub-block (sub-block P in (a) of FIG. 30 ) in the current block may be determined as SPIPM_BR. As shown in (b) of FIG. 30 , the intra prediction modes of the upper left sub-block, upper right sub-block, lower left sub-block and lower right sub-block in the current block may be determined as SPIPM_TL, SPIPM_TR, SPIPM_BL and SPIPM_BR. However, the intra prediction modes of the upper left sub-block, upper right sub-block, lower left sub-block and lower right sub-block in the current block are not limited to SPIPM_TL, SPIPM_TR, SPIPM_BL and SPIPM_BR, and the upper left sub-block, At least one of the intra prediction modes of the upper right subblock, the lower left subblock, and the lower right subblock may be determined as at least one of SPIPM_TL, SPIPM_TR, SPIPM_BL, and SPIPM_BR.
可使用双线性滤波器方案来确定其它子块的帧内预测模式。例如,可使用下面的[等式14]。在[等式14]中,function()可以是floor()或ceil()或round()中的至少一个。在图30中所示的示例中,function()可以是round()。另外,在[等式14]中,#of SubBlk inwdt可表示当前块中水平方向上的子块的数量。类似地,#of SubBlk in hgt可表示当前块中垂直方向上的子块的数量。A bilinear filter scheme may be used to determine intra prediction modes for other sub-blocks. For example, the following [Equation 14] can be used. In [Equation 14], function() may be at least one of floor() or ceil() or round(). In the example shown in Figure 30, function() may be round(). In addition, in [Equation 14], #of SubBlk inwdt may represent the number of sub-blocks in the current block in the horizontal direction. Similarly, #of SubBlk in hgt can represent the number of sub-blocks in the current block in the vertical direction.
[等式14][Equation 14]
例如,如图30的(c)中所示,可使用[等式14]确定其余子块的帧内预测模式。For example, as shown in (c) of FIG. 30 , the intra prediction modes of the remaining sub-blocks may be determined using [Equation 14].
针对基于双线性滤波器模型的逐子块帧内预测将被额外熵编码/解码的信息可以是以下项中的至少一项。The information to be additionally entropy encoded/decoded for sub-block-wise intra prediction based on the bilinear filter model may be at least one of the following items.
指示是否针对当前块执行了基于双线性滤波器模型的逐子块帧内预测的信息:BF_flagInformation indicating whether bilinear filter model-based sub-block intra prediction is performed for the current block: BF_flag
指示所使用的SPIPM集的索引:SPIPM_idxIndex indicating the SPIPM set used: SPIPM_idx
可使用在与当前块邻近的重建块之中的通过帧内预测被编码/解码的块的帧内预测模式中的至少一个以及当前块的帧内预测模式,基于子块推导帧内预测模式,并且可使用推导出的帧内预测模式来基于子块执行帧内预测。这里,在基于子块被先前编码/解码的子块中包括的样点可被用作用于后续逐子块帧内预测的参考样点。The intra prediction mode may be derived based on the sub-block using at least one of the intra prediction modes of the block encoded/decoded by intra prediction among the reconstructed blocks adjacent to the current block and the intra prediction mode of the current block, And the derived intra prediction mode can be used to perform intra prediction on a sub-block basis. Here, samples included in sub-blocks previously encoded/decoded on a sub-block basis may be used as reference samples for subsequent sub-block-wise intra prediction.
编码器可通过针对逐子块帧内预测之后所产生的残差块执行首次变换、二次变换以及量化中的至少一个来产生变换系数。产生的变换系数可被熵编码。可针对当前块执行首次变换、二次变换和量化,或者可基于子块执行首次变换、二次变换和量化。例如,可针对整个当前块执行首次变换、二次变换和量化中的至少一个,或者可针对每个子块执行首次变换、二次变换和量化中的至少一个。这里,可不对当前块或子块执行首次变换、二次变换和量化中的任何一个。The encoder may generate the transform coefficient by performing at least one of a first transform, a second transform, and quantization on a residual block generated after sub-block-wise intra prediction. The resulting transform coefficients can be entropy coded. The first transform, the second transform, and the quantization may be performed for the current block, or the first transform, the second transform, and the quantization may be performed on a sub-block basis. For example, at least one of the first transform, the second transform, and the quantization may be performed for the entire current block, or at least one of the first transform, the second transform, and the quantization may be performed for each subblock. Here, any one of the first transform, the second transform, and the quantization may not be performed on the current block or sub-block.
变换系数可在解码器中被熵解码。可通过针对熵解码的变换系数执行反量化、首次逆变换和二次逆变换中的至少一个来产生重建残差块。可针对当前块执行首次变换、二次变换和量化,并且可基于子块执行首次变换、二次变换和量化。例如,可针对整个当前块执行首次变换、二次变换和量化中的至少一个,并且可针对每个子块执行首次变换、二次变换和量化中的至少一个。这里,可不对当前块或子块执行首次变换、二次变换和量化中的任何一个。The transform coefficients can be entropy decoded in the decoder. The reconstructed residual block may be generated by performing at least one of inverse quantization, first inverse transform, and second inverse transform on the entropy-decoded transform coefficients. The first transform, the second transform, and the quantization may be performed for the current block, and the first transform, the second transform, and the quantization may be performed on a sub-block basis. For example, at least one of the first transform, the second transform, and the quantization may be performed for the entire current block, and at least one of the first transform, the second transform, and the quantization may be performed for each subblock. Here, any one of the first transform, the second transform, and the quantization may not be performed on the current block or sub-block.
帧内预测信息可被熵编码/从比特流熵解码。图31是示出包括帧内预测模式信息的语法结构的示例性示图。如图31中所示,帧内预测信息可包括以下多条信息中的至少一条。这里,可在VPS、SPS、PPS、APS、条带头和并行块头中的至少一个中用信号传送帧内预测信息。Intra prediction information can be entropy encoded/entropy decoded from the bitstream. FIG. 31 is an exemplary diagram showing a syntax structure including intra prediction mode information. As shown in FIG. 31, intra prediction information may include at least one of the following pieces of information. Here, the intra prediction information may be signaled in at least one of VPS, SPS, PPS, APS, slice header, and tile header.
指示MPM是否匹配的标志:例如,prev_intra_luma_pred_flagFlag indicating whether the MPM matches: e.g. prev_intra_luma_pred_flag
指示MPM列表中的位置的索引:例如,mpm_idxIndex indicating position in the MPM list: for example, mpm_idx
帧内亮度预测模式信息:例如,rem_intra_luma_pred_modeIntra-frame luma prediction mode information: for example, rem_intra_luma_pred_mode
帧内色度预测模式信息:例如,intra_chroma_pred_modeIntra chroma prediction mode information: for example, intra_chroma_pred_mode
弯曲帧内预测模式的曲率参数:例如,cuvCurvature parameters for curved intra prediction modes: e.g. cuv
用于弯曲帧内预测模式的权重参数:例如,cw1、cw2、…、cwNs-1Weight parameters for curved intra prediction modes: e.g., cw1, cw2, …, cwNs-1
用于弯曲帧内预测的LUTLUT for curved intra prediction
指示使用邻近块的帧内预测模式推导当前块和子块的帧内预测模式的标志:例如,NDIP_flagFlag indicating that the intra prediction modes of neighboring blocks are used to derive the intra prediction mode of the current block and sub-block: for example, NDIP_flag
指示残差信号预测是否将被执行的标志:例如,SRP_flagFlag indicating whether residual signal prediction will be performed: e.g., SRP_flag
指示符(MPM标志):例如,MPM_FLAG_1、MPM_FLAG_2、…、MPM_FLAG_N,其中,所述指示符用于指示当当前块的帧内预测模式使用N个MPM列表被推导或者被熵编码/解码时,针对N个MPM列表中的每一个,与当前块的帧内预测模式相同的帧内预测模式是否被包括在MPM列表的帧内预测模式中Indicator (MPM flag): for example, MPM_FLAG_1, MPM_FLAG_2, ..., MPM_FLAG_N, where the indicator is used to indicate that when the intra prediction mode of the current block is derived using N MPM lists or is entropy encoded/decoded, for For each of the N MPM lists, whether the intra prediction mode that is the same as the intra prediction mode of the current block is included in the intra prediction mode of the MPM list
索引信息:例如,MPM_IDX_1、MPM_IDX_2、…、MPM_IDX_N,其中,所述索引信息用于指示当与当前块的帧内预测模式相同的帧内预测模式被包括在N个MPM列表中的特定一个MPM列表的帧内预测模式中时,该帧内预测模式在MPM列表中的位置或顺序。Index information: for example, MPM_IDX_1, MPM_IDX_2, ..., MPM_IDX_N, where the index information is used to indicate a specific one of the N MPM lists when the intra prediction mode that is the same as the intra prediction mode of the current block is included in the N MPM lists. When in the intra prediction mode, the position or order of the intra prediction mode in the MPM list.
指示是否针对当前块执行了基于变换模型的逐子块帧内预测的信息、以及指示所使用的SPIPM集的索引:例如,TBIP_flag和SPIPM_idxInformation indicating whether transform model-based sub-block intra prediction was performed for the current block, and an index indicating the SPIPM set used: e.g., TBIP_flag and SPIPM_idx
指示是否针对当前块使用等空间模型基于子块推导帧内预测模式的信息、以及指示所使用的SPIPM集的索引:ES_flag和SPIPM_idxInformation indicating whether to use an equal spatial model to derive the intra prediction mode based on sub-blocks for the current block, and an index indicating the SPIPM set used: ES_flag and SPIPM_idx
指示是否针对当前块使用双线性滤波器模型基于子块推导帧内预测模式的信息、以及指示所使用的SPIPM集的索引:BF_flag和SPIPM_idxInformation indicating whether to use a bilinear filter model for the current block to derive the intra prediction mode based on sub-blocks, and an index indicating the SPIPM set used: BF_flag and SPIPM_idx
当MPM(最可能模式)标志是1时,可通过使用MPM索引mpm_idx,从包括已被编码/解码的邻近单元的帧内模式的候选模式推导亮度分量的帧内预测模式。When the MPM (Most Likely Mode) flag is 1, the intra prediction mode of the luma component can be derived from the candidate modes including the intra modes of the neighboring units that have been encoded/decoded by using the MPM index mpm_idx.
当MPM(最可能模式)标志是0时,可通过使用关于亮度分量的帧内预测模式信息rem_intra_luma_pred_mode来对亮度分量的帧内预测模式进行编码/解码。When the MPM (Most Likely Mode) flag is 0, the intra prediction mode of the luma component may be encoded/decoded by using the intra prediction mode information rem_intra_luma_pred_mode on the luma component.
可通过使用关于色度分量的帧内预测模式信息intra_chroma_pred_mode和/或色度分量块的相应帧内预测模式来对色度分量的帧内预测模式进行编码/解码。The intra prediction mode of the chroma component may be encoded/decoded by using the intra prediction mode information intra_chroma_pred_mode on the chroma component and/or the corresponding intra prediction mode of the chroma component block.
在弯曲帧内预测模式的情况下,可根据预测块内部的样点的位置(x,y)使用不同角度的参考样点来推导预测样点值。在预测块内部的样点可被分组为多个组,第一组可使用具有与第二组的角度不同的角度的方向帧内预测模式。每个组可包括一个或更多个样点。每个组可以是三角形形状、矩形形状或其它几何形状。In the case of curved intra prediction mode, reference samples at different angles can be used to derive prediction sample values based on the position (x, y) of the sample inside the prediction block. Samples within a prediction block may be grouped into multiple groups, a first group may use a directional intra prediction mode with a different angle than the angle of the second group. Each group can include one or more samples. Each group can be triangular, rectangular, or other geometric shape.
弯曲帧内预测模式的曲率参数cuv可表示被应用于弯曲帧内预测模式的曲率。可通过使用至少一个cuv对当前块执行弯曲帧内预测。可从邻近块的曲率参数之中的至少一个曲率参数推导曲率参数。The curvature parameter cuv of the curved intra prediction mode may represent the curvature applied to the curved intra prediction mode. Curved intra prediction can be performed on the current block by using at least one cuv. The curvature parameter may be derived from at least one curvature parameter among the curvature parameters of neighboring blocks.
弯曲帧内预测模式的单个或多个权重参数cw可被应用于当前块。当多个权重参数cw被应用于当前块时,不同的权重参数可被应用于当前块的预定单元,诸如像素、行、列或子块等。可从邻近块的权重参数之中的至少一个权重参数推导权重参数。Single or multiple weight parameters cw of the curved intra prediction mode may be applied to the current block. When multiple weight parameters cw are applied to the current block, different weight parameters may be applied to predetermined units of the current block, such as pixels, rows, columns, or sub-blocks. The weight parameter may be derived from at least one of the weight parameters of neighboring blocks.
用于推导曲率参数和/或权重参数的邻近块可以是在上侧、左侧和/或右侧与当前块相邻的已被编码/解码的块。Neighboring blocks used to derive curvature parameters and/or weight parameters may be coded/decoded blocks adjacent to the current block on the upper, left and/or right sides.
可通过使用cuv和cw中的至少一个来执行各种形式的弯曲帧内预测。Various forms of curved intra prediction may be performed by using at least one of cuv and cw.
当N个cuv和M个cw被使用时,可通过产生至少(N×M)×4个预测块来执行当前块的帧内预测。When N cuvs and M cws are used, intra prediction of the current block can be performed by generating at least (N×M)×4 prediction blocks.
例如,当单个cuv和单个cw被使用时,可通过产生至少四个预测块来执行当前块的帧内预测。For example, when a single cuv and a single cw are used, intra prediction of the current block can be performed by generating at least four prediction blocks.
例如,当两个cuv和单个cw被使用时,可通过产生至少八个预测块来执行当前块的帧内预测。For example, when two cuv and a single cw are used, intra prediction of the current block can be performed by generating at least eight prediction blocks.
例如,当单个cuv和两个cw被使用时,可通过产生至少八个预测块来执行当前块的帧内预测。For example, when a single cuv and two cw are used, intra prediction of the current block can be performed by generating at least eight prediction blocks.
例如,当两个cuv和两个cw被使用时,可通过产生至少十六个预测块来执行当前块的帧内预测。For example, when two cuv and two cw are used, intra prediction of the current block can be performed by generating at least sixteen prediction blocks.
可通过使用默认值和delta值来对关于至少两个cuv和/或cw的信息进行编码/解码。这里,默认值可表示单个cuw值和/或单个cw值,delta值可表示恒定值。Information about at least two cuv and/or cw can be encoded/decoded by using default and delta values. Here, the default value may represent a single cuw value and/or a single cw value, and the delta value may represent a constant value.
例如,当在当前块中使用2个cuv时,两个曲率参数可以是default_cuv和default_cuv+delta_cuv。For example, when using 2 cuvs in the current block, the two curvature parameters can be default_cuv and default_cuv+delta_cuv.
例如,当在当前块中使用N个cuv时,N个曲率参数可以是default_cuv、default_cuv+delta_cuv、default_cuv+2*delta_cuv、…、以及default_cuv+(N-1)*delta_cuv。(这里,N是大于2的正整数)。For example, when N cuvs are used in the current block, the N curvature parameters may be default_cuv, default_cuv+delta_cuv, default_cuv+2*delta_cuv, ..., and default_cuv+(N-1)*delta_cuv. (Here, N is a positive integer greater than 2).
例如,当在当前块中使用2N+1个cuv时,2N+1个曲率参数可以是default_cuv、default_cuv+delta_cuv、default_cuv-delta_cuv、default_cuv+2*delta_cuv、default_cuv-2*delta_cuv、…、default_cuv+N*delta_cuv以及default_cuv-N*delta_cuv。(这里,N是大于1的正整数)。For example, when using 2N+1 cuvs in the current block, the 2N+1 curvature parameters can be default_cuv, default_cuv+delta_cuv, default_cuv-delta_cuv, default_cuv+2*delta_cuv, default_cuv-2*delta_cuv, ..., default_cuv+N *delta_cuv and default_cuv-N*delta_cuv. (Here, N is a positive integer greater than 1).
例如,当在当前块中使用两个cw时,两个权重参数可以是default_cw和default_cw+delta_cw。(这里,default_cw+delta_cw是矢量的元素单位的总和)。For example, when using two cws in the current block, the two weight parameters can be default_cw and default_cw+delta_cw. (Here, default_cw+delta_cw is the sum of the element units of the vector).
例如,当在当前块中使用M个cw时,M个权重参数可以是default_cw、default_cw+delta_cw、default_cw+2*delta_cw、…、以及default_cw+(M-1)*delta_cw。(这里,default_cw+delta_cw是矢量的元素单位的总和,M是大于2的正整数)。For example, when M cws are used in the current block, the M weight parameters may be default_cw, default_cw+delta_cw, default_cw+2*delta_cw, ..., and default_cw+(M-1)*delta_cw. (Here, default_cw+delta_cw is the sum of the element units of the vector, and M is a positive integer greater than 2).
例如,当在当前块中使用2M+1个cw时,2M+1个曲率参数可以是default_cw、default_cw+delta_cw、default_cw-delta_cw、default_cw+2*delta_cw、default_cw-2*delta_cw、…、default_cw+M*delta_cw、以及default_cw-M*delta_cw。(这里,M是大于1的正整数)。For example, when using 2M+1 cws in the current block, the 2M+1 curvature parameters can be default_cw, default_cw+delta_cw, default_cw-delta_cw, default_cw+2*delta_cw, default_cw-2*delta_cw, ..., default_cw+M *delta_cw, and default_cw-M*delta_cw. (Here, M is a positive integer greater than 1).
以上描述的关于cuv和/或cw的信息可被编码为比特流,或者可从比特流被解码。可选地,编码器或解码器可以以例如查找表的格式共享和存储关于cuv和/或cw的数量或者cuv和/或cw的值的信息。The information about cuv and/or cw described above may be encoded into a bitstream, or may be decoded from the bitstream. Optionally, the encoder or decoder may share and store information about the number of cuv and/or cw or the values of cuv and/or cw in a lookup table format, for example.
当SRP_flag等于1时,可使用针对当前块或子块确定的帧内预测模式来执行残差信号预测。When SRP_flag is equal to 1, residual signal prediction may be performed using the intra prediction mode determined for the current block or sub-block.
帧内预测信息可基于编码参数中的至少一个被熵编码/从比特流解码。例如,可基于块划分信息来编码/解码NDIP_flag。The intra prediction information may be entropy encoded/decoded from the bitstream based on at least one of the encoding parameters. For example, NDIP_flag may be encoded/decoded based on block partition information.
例如,如果split_flag、quadtree_flag和binarytree_flag中的至少一个是“0”并且因此块不被进一步划分,则NDIP_flag可被编码/解码。For example, if at least one of split_flag, quadtree_flag, and binarytree_flag is "0" and therefore the block is not further divided, NDIP_flag may be encoded/decoded.
例如,如果binarytree_flag是1,则NDIP_flag可不被编码/解码。For example, if binarytree_flag is 1, NDIP_flag may not be encoded/decoded.
基于块的大小和形状中的至少一个,可不用信号传送以上描述的多条帧内预测信息中的至少一条。Based on at least one of the size and shape of the block, at least one of the plurality of pieces of intra prediction information described above may not be signaled.
例如,如果当前块的大小是预定大小,则可不用信号传送至少一条关于当前块的帧内预测信息,并且可使用至少一条关于与先前编码/解码的上层块的大小相应的帧内预测的信息。For example, if the size of the current block is a predetermined size, at least one piece of intra prediction information about the current block may not be signaled, and at least one piece of information about intra prediction corresponding to the size of the previously encoded/decoded upper layer block may be used .
例如,如果当前块被成形为矩形,则可不用信号传送至少一条关于当前块的帧内预测信息,并且可使用至少一条关于与先前编码/解码的上层块的大小相应的帧内预测的信息。For example, if the current block is shaped into a rectangle, at least one piece of intra prediction information about the current block may not be signaled, and at least one piece of information about intra prediction corresponding to the size of a previously encoded/decoded upper layer block may be used.
如果SRP_flag是1,则可使用针对当前块或子块确定的帧内预测模式来预测残差信号。If SRP_flag is 1, the residual signal may be predicted using the intra prediction mode determined for the current block or sub-block.
当多条帧内预测信息中的至少一条被熵编码/解码时,可使用以下二值化方法中的至少一种二值化方法。When at least one piece of the plurality of pieces of intra prediction information is entropy encoded/decoded, at least one of the following binarization methods may be used.
—截断莱斯二值化方法—Truncated Rician binarization method
—K阶指数哥伦布二值化方法—K-order exponential Columbus binarization method
—有限K阶指数哥伦布二值化方法—Finite K-order exponential Columbus binarization method
—固定长度二值化方法—Fixed length binarization method
—一元二值化方法—One-yuan binarization method
—截断一元二值化方法—Truncated unary binarization method
现在,将详细描述参考样点构建步骤S1220。Now, the reference sample point construction step S1220 will be described in detail.
在基于推导出的帧内预测模式对当前块或具有比当前块小的大小和/或形状的子块的帧内预测中,参考样点可被构建用于该预测。在当前块的上下文中给出以下描述,并且当前块可意为子块。可使用与当前块邻近的一个或更多个重建样点或样点组合来构建参考样点。另外,可在构建参考样点时应用滤波。这里,可按照原样使用多个重建样点线上的每个重建样点来构建参考样点。或者,可在同一重建样点线上的样点之间进行滤波之后构建参考样点。或者,可在不同重建样点线上的样点之间进行滤波之后构建参考样点。可用ref[m,n]来表示构建的参考样点,可用rec[m,n]来表示重建邻近样点或通过对重建邻近样点进行滤波而获得的样点。这里,m或n可以是预定的整数值。在当前块的大小为W(水平)×H(垂直)的情况下,如果当前块的最左上方样点位置是(0,0),则与该样点位置最接近的最左上方参考样点的相对位置可被设置为(-1,-1)。In intra prediction of a current block or a sub-block having a smaller size and/or shape than the current block based on the derived intra prediction mode, reference samples may be constructed for the prediction. The following description is given in the context of the current block, and the current block may be meant as a sub-block. The reference sample can be constructed using one or more reconstructed samples or combinations of samples adjacent to the current block. Additionally, filtering can be applied when constructing reference samples. Here, each reconstructed sample point on the multiple reconstructed sample point lines can be used as is to construct the reference sample point. Alternatively, the reference samples can be constructed after filtering between samples on the same reconstructed sample line. Alternatively, the reference samples can be constructed after filtering between samples on different reconstructed sample lines. Ref[m,n] can be used to represent the constructed reference sample points, and rec[m,n] can be used to represent the reconstructed adjacent sample points or the sample points obtained by filtering the reconstructed adjacent sample points. Here, m or n may be a predetermined integer value. When the size of the current block is W (horizontal) × H (vertical), if the upper left sample point position of the current block is (0,0), then the upper left reference sample closest to the sample position is The relative position of the point can be set to (-1,-1).
图32是描绘可用于对当前块进行帧内预测的邻近重建样点线的示例性示图。32 is an exemplary diagram depicting adjacent reconstruction sample lines that may be used for intra prediction of the current block.
如图32中所示,可使用与当前块相邻的一个或更多个重建样点线来构建参考样点。As shown in Figure 32, one or more reconstructed sample lines adjacent to the current block may be used to construct the reference samples.
例如,可选择图32中示出的多个重建样点线之一,并且可使用所选择的重建样点线来构建参考样点。可将所述多个重建样点线中的预定一个重建样点线固定地选为所选择的重建样点线。或者,可将所述多个重建样点线中的特定一个重建样点线自适应地选为所选择的重建样点线。在这种情况下,可用信号传送用于所选择的重建样点线的指示符。For example, one of the plurality of reconstruction splines shown in Figure 32 may be selected, and the selected reconstruction spline may be used to construct a reference sample. A predetermined one of the plurality of reconstruction spline lines may be fixedly selected as the selected reconstruction spline line. Alternatively, a specific one of the plurality of reconstruction spline lines may be adaptively selected as the selected reconstruction spline line. In this case, an indicator for the selected reconstructed sample line may be signaled.
例如,可组合使用图32中示出的多个重建样点线中的一个或更多个来构建参考样点。例如,参考样点可被构建为一个或更多个重建样点的加权和(或加权平均)。可基于距当前块的距离来分配用于加权平均的权重。这里,可以对距当前块的较短距离分配较大的权重。例如,可使用以下[等式15]。For example, one or more of the multiple reconstructed sample lines shown in Figure 32 may be used in combination to construct the reference sample. For example, a reference sample may be constructed as a weighted sum (or weighted average) of one or more reconstructed samples. The weights used for the weighted average may be assigned based on distance from the current block. Here, shorter distances from the current block can be assigned larger weights. For example, the following [Equation 15] can be used.
[等式15][Equation 15]
ref[-1,-1]=(rec[-2,-1]+2*rec[-1,-1]+rec[-1,-2]+2)>>2ref[-1,-1]=(rec[-2,-1]+2*rec[-1,-1]+rec[-1,-2]+2)>>2
ref[x,-1]=(rec[x,-2]+3*rec[x,-1]+2)>>2,(x=0~W+H-1)ref[x,-1]=(rec[x,-2]+3*rec[x,-1]+2)>>2,(x=0~W+H-1)
ref[-1,y]=(rec[-2,y]+3*rec[-1,y]+2)>>2,(y=0~W+H-1)ref[-1,y]=(rec[-2,y]+3*rec[-1,y]+2)>>2,(y=0~W+H-1)
或者,可基于距当前块的距离或帧内预测模式中的至少一个,使用多个重建样点的平均值、最大值、最小值、中值和最频繁值中的至少一个来构建参考样点。Alternatively, the reference sample may be constructed using at least one of the average, maximum, minimum, median and most frequent values of a plurality of reconstructed samples based on at least one of distance from the current block or intra prediction mode .
或者,可基于多个连续重建样点的值的变化(改变)来构建参考样点。例如,可基于两个连续重建样点的值之间的差是否等于或大于阈值、两个连续重建样点的值是连续变化还是非连续变化、等等中的至少一个来构建参考样点。例如,如果rec[-1,-1]与rec[-2,-1]之间的差等于或大于阈值,则ref[-1,-1]可被确定为rec[-1,-1]、或者通过应用利用被分配给rec[-1,-1]的预定权重的加权平均而获得的值。例如,如果随着多个连续重建样点越接近当前块,所述多个连续重建样点的值每次被改变n,则参考样点ref[-1,-1]可被确定为rec[-1,-1]-n。Alternatively, the reference sample points may be constructed based on changes (changes) in the values of a plurality of consecutive reconstructed sample points. For example, the reference sample point may be constructed based on at least one of whether the difference between the values of two consecutive reconstructed sample points is equal to or greater than a threshold, whether the values of two consecutive reconstructed sample points change continuously or discontinuously, and the like. For example, if the difference between rec[-1,-1] and rec[-2,-1] is equal to or greater than the threshold, ref[-1,-1] may be determined as rec[-1,-1] , or a value obtained by applying a weighted average using predetermined weights assigned to rec[-1,-1]. For example, if the values of a plurality of consecutive reconstructed sample points are changed by n each time as the plurality of consecutive reconstructed sample points get closer to the current block, then the reference sample point ref[-1,-1] can be determined as rec[ -1,-1]-n.
可根据当前块的上方边界或左侧边界是否与画面、条带、并行块和编码树块(CTB)中的至少一个的边界相应来不同地确定重建样点线的数量和位置之中的至少一个以及用于构建参考样点的构建方法。At least one of the number and the position of the reconstructed sample lines may be determined differently depending on whether the upper boundary or the left boundary of the current block corresponds to the boundary of at least one of a picture, a slice, a tile, and a coding tree block (CTB). One and the construction method used to construct the reference sample points.
例如,在使用重建样点线1和2来构建参考样点时,当当前块的上方边界与CTB边界相应时,重建样点线1可用于上方的边,并且重建样点线1和2可用于左侧的边。For example, when using reconstruction spline 1 and 2 to construct a reference sample, when the upper boundary of the current block corresponds to the CTB boundary, reconstruction spline 1 is available for the upper edge, and reconstruction spline 1 and 2 are available on the left side.
例如,在使用重建样点线1至4来构建参考样点时,当当前块的上方边界与CTB边界相应时,重建样点线1和2可用于上方的边,并且重建样点线1至4可用于左侧的边。For example, when constructing reference samples using reconstructed sample lines 1 to 4, when the upper boundary of the current block corresponds to the CTB boundary, reconstructed sample lines 1 and 2 can be used for the upper edge, and reconstructed sample lines 1 to 4 is available for the left side.
例如,在使用重建样点线2来构建参考样点时,当当前块的上方边界与CTB边界相应时,重建样点线1可用于上方的边,重建样点线2可用于左侧的边。For example, when using reconstructed sample line 2 to construct reference samples, when the upper boundary of the current block corresponds to the CTB boundary, reconstructed sample line 1 can be used for the upper edge, and reconstructed sample line 2 can be used for the left edge. .
可通过以上处理来构建一个或更多个参考样点线。One or more reference sample lines can be constructed through the above processing.
当前块的上方的边的参考样点构建方法可不同于当前块的左侧的边的参考样点构建方法。The reference sample construction method for the upper edge of the current block may be different from the reference sample construction method for the left side of the current block.
可对指示参考样点已使用以上方法中的至少一个方法被构建的信息进行编码/解码。例如,可对指示多个重建样点线是否被使用的信息进行编码/解码。Information indicating that the reference sample has been constructed using at least one of the above methods may be encoded/decoded. For example, information indicating whether multiple reconstructed sample lines are used may be encoded/decoded.
如果当前块被划分成多个子块,并且每个子块具有独立的帧内预测模式,则可针对每个子块构建参考样点。If the current block is divided into multiple sub-blocks, and each sub-block has an independent intra prediction mode, a reference sample can be constructed for each sub-block.
图33是描绘针对当前块中包括的子块构建参考样点的实施例的示图。33 is a diagram depicting an embodiment of constructing reference samples for sub-blocks included in the current block.
如图33中所示,如果当前块的大小是16×16并且16个4×4的子块具有独立的帧内预测模式,则可根据用于对子块进行预测的扫描方案按照以下方法中的至少一种方法来构建用于每个子块的参考样点。As shown in Figure 33, if the size of the current block is 16×16 and 16 4×4 sub-blocks have independent intra prediction modes, the following method can be used according to the scanning scheme used to predict the sub-blocks. At least one method to construct reference samples for each sub-block.
例如,可使用与当前块邻近的N个重建参考样点线针对每个子块构建参考样点。在图33中示出的示例中,N是1。For example, the reference samples may be constructed for each sub-block using N reconstructed reference sample lines adjacent to the current block. In the example shown in Figure 33, N is 1.
例如,在按照1->2->3->…15->16的光栅扫描顺序预测多个子块的情况下,可使用已经编码/解码的左侧子块、上方子块、右上方子块和左下方子块中的至少一个的样点来构建用于第K子块的参考样点。For example, when predicting multiple sub-blocks in the raster scanning order of 1->2->3->...15->16, the already encoded/decoded left sub-block, upper sub-block, and upper right sub-block can be used and at least one sample point in the lower left sub-block to construct a reference sample point for the K-th sub-block.
例如,在按照1->2->5->6->3->4->7->…12->15->16的Z字形扫描顺序预测多个子块的情况下,可使用已经编码/解码的左侧子块、上方子块、右上方子块和左下方子块中的至少一个的样点来构建用于第K子块的参考样点。For example, in the case of predicting multiple sub-blocks according to the zigzag scanning order of 1->2->5->6->3->4->7->…12->15->16, the already encoded / Decoded samples of at least one of the left sub-block, upper sub-block, upper right sub-block and lower left sub-block to construct a reference sample for the Kth sub-block.
例如,在按照1->2->5->9->6->3->4->…12->15->16的zig-zag扫描顺序预测多个子块的情况下,可使用已经编码/解码的左侧子块、上方子块、右上方子块和左下方子块中的至少一个的样点来构建用于第K子块的参考样点。For example, in the case of predicting multiple sub-blocks in the zig-zag scanning order of 1->2->5->9->6->3->4->…12->15->16, you can use A sample point of at least one of the encoded/decoded left sub-block, upper sub-block, upper right sub-block and lower left sub-block is used to construct a reference sample for the K-th sub-block.
例如,在按照1->5->9->13->2->6->…8->12->16的垂直扫描顺序预测多个子块的情况下,可使用已经编码/解码的左侧子块、上方子块、右上方子块和左下方子块中的至少一个的样点来构建用于第K子块的参考样点。For example, in the case of predicting multiple sub-blocks in the vertical scanning order of 1->5->9->13->2->6->...8->12->16, the already encoded/decoded left A sample point of at least one of the side sub-block, the upper sub-block, the upper right sub-block and the lower left sub-block is used to construct a reference sample point for the K-th sub-block.
在按照以上扫描顺序之外的扫描顺序预测多个子块的情况下,可使用已经编码/解码的左侧子块、上方子块、右上方子块和左下方子块中的至少一个的样点来构建用于第K子块的参考样点。In the case where multiple sub-blocks are predicted according to a scanning order other than the above scanning order, samples of at least one of the already encoded/decoded left sub-block, upper sub-block, upper right sub-block and lower left sub-block may be used to construct the reference sample points for the Kth sub-block.
在选择参考样点时,可执行关于包括参考样点的块的可用性的决定和/或填充。例如,如果包括参考样点的块可用,则可使用该参考样点。同时,如果包括参考样点的块不可用,则可通过填充来用一个或更多个可用的邻近参考样点替换该不可用参考样点。When selecting a reference sample, a decision and/or filling may be performed regarding the availability of blocks that include the reference sample. For example, if a block containing a reference sample is available, the reference sample can be used. At the same time, if a block including a reference sample is unavailable, the unavailable reference sample can be replaced with one or more available neighboring reference samples through padding.
如果参考样点存在于画面边界、并行块边界、条带边界、CTB边界和预定边界中的至少一个的外部,则可确定该参考样点不可用。If a reference sample point exists outside at least one of a picture boundary, a tile boundary, a slice boundary, a CTB boundary, and a predetermined boundary, it may be determined that the reference sample point is not available.
在当前块通过CIP(受约束的帧内预测)被编码的情况下,如果包括参考样点的块按照帧间预测模式被编码/解码,则可确定该参考样点不可用。In the case where the current block is encoded by CIP (Constrained Intra-Prediction), if the block including the reference sample is encoded/decoded in the inter-prediction mode, it may be determined that the reference sample is not available.
图34是描绘用于使用可用重建样点替换不可用重建样点的方法的示图。Figure 34 is a diagram depicting a method for replacing unavailable reconstruction samples with available reconstruction samples.
如果确定邻近重建样点不可用,则可使用可用邻近重建样点来替换该不可用样点。例如,如图34中所示,在存在可用样点和不可用样点的情况下,可使用一个或更多个可用样点来替换不可用样点。If a neighboring reconstructed sample is determined to be unavailable, the unavailable sample can be replaced with an available neighboring reconstructed sample. For example, as shown in Figure 34, where there are available and unavailable samples, one or more available samples may be used to replace the unavailable samples.
可按照预定顺序利用可用样点的样点值替换不可用样点的样点值。与不可用样点相邻的可用样点可被用于替换该不可用样点。在不存在相邻的可用样点的情况下,可使用第一个出现的可用样点或最近的可用样点。不可用样点的替换顺序可以是最左下方到最右上方的顺序。或者,不可用样点的替换顺序可以是最右上方到最左下方的顺序。或者,不可用样点的替换顺序可以是最左上方到最右上方和/或最左下方的顺序。或者,不可用样点的替换顺序可以是最右上方和/或最左下方到最左上方的顺序。Sample values of unavailable sample points may be replaced with sample values of available sample points in a predetermined sequence. Available sample points adjacent to an unavailable sample point can be used to replace the unavailable sample point. In the absence of adjacent available samples, the first available sample to occur or the nearest available sample may be used. The replacement order of unavailable sample points can be from the bottom left to the top right. Alternatively, the replacement order of unavailable sample points may be from upper rightmost to lower leftmost order. Alternatively, the replacement order of unavailable samples may be from top left to top right and/or bottom left. Alternatively, the replacement order for unavailable samples may be upper-right and/or lower-left to upper-left order.
如图34中所示,可按照从最左下方样点位置0到最右上方样点的顺序来替换不可用样点。在这种情况下,可用第一个出现的或最接近的可用样点a的值来替换前四个不可用样点的值。可用最后的可用样点b的值来替换接下来的13个不可用样点的值。As shown in Figure 34, unavailable sample points can be replaced in order from the bottom left sample point position 0 to the upper right sample point. In this case, the values of the first four unavailable samples can be replaced by the value of the first occurring or closest available sample a. The values of the next 13 unavailable samples can be replaced with the value of the last available sample point b.
或者,可使用可用样点的组合来替换不可用样点。例如,可使用与不可用样点的两端相邻的可用样点的平均值来替换不可用样点。例如,在图34中,可利用可用样点a的值来替换前四个不可用样点,并且可利用可用样点b和可用样点c的平均值来替换接下来的13个不可用样点。或者,可利用可用样点b的值和可用样点c的值之间的任意值来填充所述13个不可用样点。在这种情况下,可利用不同值来替换不可用样点。例如,由于不可用样点更接近可用样点a,因此可利用与可用样点a的值接近的值来替换不可用样点的值。类似地,由于不可用样点更接近可用样点b,因此可利用与可用样点b的值接近的值来替换不可用样点的值。也就是说,可基于从不可用样点到可用样点a和/或b的距离来确定不可用样点的值。Alternatively, a combination of available sample points can be used to replace unavailable sample points. For example, the unavailable sample points can be replaced with the average of the available sample points adjacent to both ends of the unavailable sample point. For example, in Figure 34, the first four unusable samples can be replaced with the value of available sample a, and the next 13 unusable samples can be replaced with the average of available sample b and available sample c. point. Alternatively, the 13 unavailable sample points can be filled with any value between the value of the available sample point b and the value of the available sample point c. In this case, the unavailable sample points can be replaced with different values. For example, since the unavailable sample point is closer to the available sample point a, the value of the unavailable sample point can be replaced with a value that is close to the value of the available sample point a. Similarly, since the unavailable sample point is closer to the available sample point b, the value of the unavailable sample point can be replaced with a value that is close to the value of the available sample point b. That is, the value of the unavailable sample point may be determined based on the distance from the unavailable sample point to the available sample points a and/or b.
为了替换不可用样点,可选择性地应用包括以上方法的多种方法中的一种或更多种方法。可通过包括在比特流中的信息来用信号传送用于替换不可用样点的方法,或者,可使用由编码器和解码器预先确定的方法。或者,可通过预定方案来推导用于替换不可用样点的方法。例如,可基于可用样点a和b的值之间的差和/或不可用样点的数量来选择用于替换不可用样点的方法。例如,可基于两个可用样点的值之间的差与阈值之间的比较和/或不可用样点的数量与阈值之间的比较来选择用于替换不可用样点的方法。例如,如果两个可用样点的值之间的差大于阈值和/或如果不可用样点的数量大于阈值,则可用不同的值来替换不可用样点的值。To replace unavailable sample points, one or more methods among a variety of methods including the above methods may be selectively applied. The method for replacing unavailable samples may be signaled by information included in the bitstream, or a method predetermined by the encoder and decoder may be used. Alternatively, a method for replacing unusable samples can be derived through a predetermined scheme. For example, the method for replacing unusable samples may be selected based on the difference between the values of available samples a and b and/or the number of unusable samples. For example, the method for replacing unusable samples may be selected based on a comparison between the difference between the values of two available samples and a threshold and/or a comparison of the number of unusable samples and a threshold. For example, if the difference between the values of two available samples is greater than a threshold and/or if the number of unavailable samples is greater than a threshold, the values of the unavailable samples may be replaced with different values.
对于构建的一个或更多个参考样点,可根据当前块的帧内预测模式、大小和形状中的至少一个确定是否应用滤波。如果应用滤波,则可根据当前块的帧内预测模式、大小和形状中的至少一个来使用不同滤波器类型。For the constructed one or more reference samples, whether to apply filtering may be determined based on at least one of an intra prediction mode, a size, and a shape of the current block. If filtering is applied, different filter types may be used depending on at least one of intra prediction mode, size and shape of the current block.
例如,对于多个参考样点线中的每一个,可不同地确定是否应用滤波和/或滤波器类型。例如,可向第一邻近线应用滤波,然而可不对第二邻近线应用滤波。For example, whether to apply filtering and/or the filter type may be determined differently for each of a plurality of reference sample lines. For example, filtering may be applied to a first adjacent line, whereas filtering may not be applied to a second adjacent line.
例如,可针对参考样点使用经过滤波的值和未经滤波的值两者。For example, both filtered and unfiltered values may be used for the reference sample.
例如,如果目标解码块的帧内预测模式intraPredMode是方向预测模式,则该方向预测模式和垂直方向模式(给定33个方向模式,其中,索引为26的模式)之间的差以及该方向预测模式与水平方向模式(给定33个方向模式,其中,索引为10的模式)之间的差中的较小者[minDistVerHor=Min(Abs(intraPredMode-26),abs(intraPredMode-10))]可被计算。For example, if the intra prediction mode intraPredMode of the target decoding block is a direction prediction mode, then the difference between that direction prediction mode and the vertical direction mode (given 33 direction modes, where the mode with index 26) and the direction prediction The smaller of the difference between the mode and the horizontal direction mode (given 33 direction modes, of which the mode with index 10) [minDistVerHor=Min(Abs(intraPredMode-26),abs(intraPredMode-10))] can be calculated.
图35是示出针对块大小的用于确定是否应用滤波的示例性阈值的示图。35 is a diagram illustrating exemplary thresholds for block size for determining whether to apply filtering.
例如,对于4×4的块,阈值可以是10,对于8×8的块,阈值可以是7,对于16×16的块,阈值可以是1,对于32×32的块,阈值可以是0,并且,对于64×64的块,阈值可以是10。For example, for a 4×4 block, the threshold can be 10, for an 8×8 block, the threshold can be 7, for a 16×16 block, the threshold can be 1, and for a 32×32 block, the threshold can be 0, And, for a 64×64 block, the threshold may be 10.
如果minDistVerHor大于分配给相应块大小的阈值(minDistVerHor>intraHorVerDistThresh),则可执行滤波,如果minDistVerHor等于或小于该阈值,则可不执行滤波。If minDistVerHor is greater than the threshold assigned to the corresponding block size (minDistVerHor>intraHorVerDistThresh), filtering may be performed, if minDistVerHor is equal to or less than the threshold, filtering may not be performed.
图36是示出是否根据块大小和/或帧间预测模式执行滤波的示例性示图。在图36中,X可表示不进行滤波,O可表示进行滤波。FIG. 36 is an exemplary diagram showing whether filtering is performed according to block size and/or inter prediction mode. In Figure 36, X may represent no filtering, and O may represent filtering.
例如,如图36中所示,可根据块大小和/或方向预测模式确定是否将滤波应用于具有8<=NS<=32的目标编码/解码块。For example, as shown in FIG. 36, whether to apply filtering to a target encoding/decoding block with 8<=NS <=32 may be determined according to the block size and/or the directional prediction mode.
在应用滤波的另一实施例中,可对具有大大小的目标编码/解码块执行双线性插值滤波。例如,可针对块大小为NS的目标编码/解码块,在垂直方向和水平方向上计算二阶微分值。如果所述二阶微分值小于预定阈值(例如,|pref(-1,-1)-2×pref(NS/2,-1)+pref(NS,-1)|<2Bd-C和/或|pref(-1,-1)-2×pref(-1,NS/2)+pref(-1,NS)|<2Bd-C(Bd是作为满足1<=C<=Bd的正整数的比特深度)),则对于y=0、…、NS-1,可推导出参考像素pref(-1,y)=(Ns-1-y)/NS×pref(-1,-1)+(y+1)/NS×pref(-1,NS-1),或者对于x=0,…,NS-1,可推导出pref(x,-1)=(Ns-1-x)/NS×pref(-1,-1)+(x+1)/NS×pref(NS-1,-1)。In another embodiment where filtering is applied, bilinear interpolation filtering may be performed on target encoding/decoding blocks with large sizes. For example, second-order differential values may be calculated in the vertical and horizontal directions for a target encoding/decoding block of block sizeNS . If the second-order differential value is less than a predetermined threshold (for example, |pref (-1,-1)-2×pref (NS /2,-1)+pref (NS ,-1)|<2Bd-C and/or |pref (-1,-1)-2×pref (-1,NS /2)+pref (-1,NS )|<2Bd-C (Bd is As the bit depth of a positive integer satisfying 1<=C<=Bd )), then for y=0,..., NS -1, it can be deduced that the reference pixel pref (-1, y)=(Ns - 1-y)/NS ×pref (-1,-1)+(y+1)/NS ×pref (-1,NS -1), or for x=0,…,NS - 1. It can be deduced that pref (x,-1)=(Ns -1-x)/NS ×pref (-1,-1)+(x+1)/NS ×pref (NS -1,-1).
例如,可根据当前块的帧内预测模式、大小和形状中的至少一个选择并应用3抽头滤波器、5抽头滤波器、7抽头滤波器和N抽头滤波器(N是正整数)中的至少一个不同的滤波器。For example, at least one of a 3-tap filter, a 5-tap filter, a 7-tap filter, and an N-tap filter (N is a positive integer) may be selected and applied according to at least one of the intra prediction mode, size, and shape of the current block. different filters.
在下文中,将详细描述执行帧内预测的步骤(S1230)。Hereinafter, the step of performing intra prediction (S1230) will be described in detail.
可基于推导出的帧内预测模式和参考样点,针对当前块或子块执行帧内预测。在以下描述中,当前块可意为子块。Intra prediction may be performed for the current block or sub-block based on the derived intra prediction mode and reference samples. In the following description, the current block may be meant as a sub-block.
例如,可执行非方向帧内预测。非方向帧内预测模式可以是DC模式和平面模式中的至少一个。For example, non-directional intra prediction may be performed. The non-directional intra prediction mode may be at least one of DC mode and planar mode.
可使用构建的参考样点中的一个或更多个的平均值来执行DC模式下的帧内预测。可将滤波应用于在当前块的边界上的一个或更多个预测样点。可根据当前块的大小和形状中的至少一个自适应地执行DC模式帧内预测。Intra prediction in DC mode may be performed using an average of one or more of the constructed reference samples. Filtering may be applied to one or more prediction samples on the boundaries of the current block. DC mode intra prediction may be adaptively performed according to at least one of the size and shape of the current block.
图37是示出根据当前块的形状的帧内预测的示例性示图。FIG. 37 is an exemplary diagram illustrating intra prediction according to the shape of the current block.
例如,如图37的(a)中所示,如果当前块成形为正方形,则可使用在当前块的上方和左侧的参考样点的平均值来预测当前块。For example, as shown in (a) of FIG. 37, if the current block is shaped into a square, the current block may be predicted using the average value of the reference samples above and to the left of the current block.
例如,如图37的(b)中所示,如果当前块成形为矩形,则可使用与当前块的宽度和长度之中的较长者邻近的参考样点的平均值来预测当前块。For example, as shown in (b) of FIG. 37 , if the current block is shaped into a rectangle, the current block may be predicted using an average value of reference samples adjacent to the longer of the width and length of the current block.
例如,如果当前块的大小落在预定范围内,则从当前块的上方参考样点或左侧参考样点之中选择预定样点,并且可使用所选择的样点的平均值来执行预测。For example, if the size of the current block falls within a predetermined range, a predetermined sample is selected from among upper reference samples or left reference samples of the current block, and prediction may be performed using an average value of the selected samples.
例如,可使用构建的参考样点中的一个或更多个的平均值来执行DC模式帧内预测。例如,可使用下面的[等式16]。For example, DC mode intra prediction may be performed using an average of one or more of the constructed reference samples. For example, the following [Equation 16] can be used.
[等式16][Equation 16]
可将滤波应用于位于当前块的边界上的一个或更多个预测样点。例如,可针对当前块的左侧和/或上方的N个列和/或行执行滤波。N可以是大于1的正整数。Filtering can be applied to one or more prediction samples located on the boundaries of the current block. For example, filtering may be performed for N columns and/or rows to the left and/or above the current block. N can be a positive integer greater than 1.
图38是描绘针对DC-模式帧内预测的滤波的示图。Figure 38 is a diagram depicting filtering for DC-mode intra prediction.
例如,如果N=1,则可针对目标块的一个上方行和/或一个左侧列执行滤波,如图38中所示。可通过下面的[等式17]来执行滤波。For example, if N=1, filtering may be performed on an upper row and/or a left column of the target block, as shown in Figure 38. Filtering can be performed by [Equation 17] below.
[等式17][Equation 17]
可根据当前块的目标帧内预测样点的位置考虑距一个或更多个构建的参考样点的距离,通过计算加权和来执行平面模式帧内预测。Planar mode intra prediction may be performed by calculating a weighted sum taking into account the distance from one or more constructed reference samples based on the position of the target intra prediction sample of the current block.
例如,依据目标预测样点的位置(x,y),预测块可被计算为N个参考样点的加权和。N可以是正整数,例如,4。For example, based on the position (x, y) of the target prediction sample, the prediction block can be calculated as a weighted sum of N reference samples. N can be a positive integer, for example, 4.
图39是描绘平面模式帧内预测的示图。FIG. 39 is a diagram depicting planar mode intra prediction.
例如,如图39中所示,如果目标编码/解码块的宽度和长度中的每一个是4(NS=4),则在每个像素位置(x,y)处的预测像素值可被推导为上方参考像素c、左侧参考像素b、目标编码/解码块的右上角像素d、以及目标编码/解码块的左下角像素a的加权和。例如,可通过[等式18]推导所述加权和。For example, as shown in FIG. 39, if each of the width and length of the target encoding/decoding block is 4 (NS = 4), the predicted pixel value at each pixel position (x, y) may be It is derived as the weighted sum of the upper reference pixel c, the left reference pixel b, the upper right pixel d of the target encoding/decoding block, and the lower left pixel a of the target encoding/decoding block. For example, the weighted sum can be derived by [Equation 18].
[等式18][Equation 18]
例如,可执行方向帧内预测。方向预测模式可以是水平模式、垂直模式和具有预定角度的模式中的至少一个。For example, directional intra prediction may be performed. The direction prediction mode may be at least one of a horizontal mode, a vertical mode, and a mode with a predetermined angle.
可使用在目标帧内预测样点的位置处的水平/垂直线上的一个或更多个参考样点来执行水平/垂直模式帧内预测。Horizontal/vertical mode intra prediction may be performed using one or more reference samples on a horizontal/vertical line at the location of the target intra prediction sample.
可使用在相对于目标帧内预测样点的位置的预定角度的线上的一个或更多个参考样点执行具有预定角度的模式下的帧内预测。这里,可使用N个参考样点。N可以是正整数,诸如2、3、4、5、或6。此外,例如,可通过应用N抽头滤波器(诸如2抽头、3抽头、4抽头、5抽头、或6抽头滤波器)来执行预测。Intra prediction in a mode with a predetermined angle may be performed using one or more reference samples on a line at a predetermined angle relative to the location of the target intra prediction sample. Here, N reference sample points can be used. N may be a positive integer such as 2, 3, 4, 5, or 6. Furthermore, prediction may be performed by applying an N-tap filter such as a 2-tap, 3-tap, 4-tap, 5-tap, or 6-tap filter, for example.
例如,可基于位置信息来执行帧内预测。位置信息可被编码/解码,并且在该位置处的重建样点块可被推导为用于当前块的帧内预测块。或者,由解码器检测到的与当前块类似的块可被推导为用于当前块的帧内预测块。For example, intra prediction may be performed based on location information. The location information can be encoded/decoded, and the reconstructed sample block at that location can be derived as an intra prediction block for the current block. Alternatively, blocks detected by the decoder that are similar to the current block may be derived as intra prediction blocks for the current block.
例如,帧内颜色分量预测可被执行。例如,可使用当前块的重建亮度分量针对色度分量执行帧内预测。或者,可使用当前块的一个重建色度分量Cb针对另一个色度分量Cr执行帧内预测。For example, intra color component prediction may be performed. For example, intra prediction may be performed for the chrominance component using the reconstructed luma component of the current block. Alternatively, intra prediction may be performed for another chroma component Cr using one reconstructed chroma component Cb of the current block.
可通过组合使用上述各种帧内预测方法中的一个或更多个来执行帧内预测。例如,可通过使用预定非方向帧内预测模式而预测的块以及使用预定方向帧内预测模式而预测的块的加权和,针对当前块构建帧内预测块。这里,可根据当前块的帧内预测模式、块大小、形状和/或样点位置中的至少一个来应用不同的权重。Intra prediction may be performed by using one or more of the various intra prediction methods described above in combination. For example, an intra prediction block may be constructed for a current block by a weighted sum of blocks predicted using a predetermined non-directional intra prediction mode and blocks predicted using a predetermined directional intra prediction mode. Here, different weights may be applied according to at least one of intra prediction mode, block size, shape and/or sample position of the current block.
或者,关于一个或更多个帧内预测模式的组合使用,可利用通过使用当前块的帧内预测模式而预测出的值以及通过使用MPM列表中包括的预定模式而预测出的值的加权和来构建预测块。Alternatively, regarding the combined use of one or more intra prediction modes, a weighted sum of values predicted by using the intra prediction mode of the current block and values predicted by using a predetermined mode included in the MPM list may be utilized to build the prediction block.
或者,可使用一个或更多个参考样点集来执行帧内预测。例如,可利用以下块的加权和来针对当前块执行帧内预测:使用未通过将滤波应用于构建的参考样点而获得的参考样点被帧内预测出的块、以及使用通过将滤波应用于构建的参考样点而获得的参考样点被帧内预测出的块。Alternatively, intra prediction may be performed using one or more sets of reference samples. For example, intra prediction for the current block may be performed using a weighted sum of blocks that were intra predicted using reference samples obtained without applying filtering to the constructed reference samples, and using A block is intra-predicted from reference samples obtained from constructed reference samples.
在帧内预测时,可使用邻近重建样点来执行滤波操作。这里,根据当前块的帧内预测模式、块大小、形状和/或样点位置中的至少一个,可执行或可不执行滤波操作。滤波操作可被包括在帧内预测处理中并因此作为一个步骤被执行。在执行滤波时,可基于当前块的帧内预测模式、块大小和形状之中的至少一个自适应地确定滤波器抽头、系数、将被应用的线的数量以及将被应用的样点的数量中的至少一个。In intra prediction, neighboring reconstructed samples can be used to perform filtering operations. Here, the filtering operation may or may not be performed according to at least one of the intra prediction mode, block size, shape, and/or sample position of the current block. The filtering operation may be included in the intra prediction process and thus performed as a step. When performing filtering, filter taps, coefficients, the number of lines to be applied, and the number of samples to be applied may be adaptively determined based on at least one of an intra prediction mode, a block size, and a shape of the current block. at least one of them.
在通过将当前块划分为子块并使用邻近块的帧内预测模式推导每个子块的帧内预测模式执行帧内预测时,可将滤波应用于当前块的每个子块。例如,可将低通滤波器应用于整个当前块。或者,可将滤波器应用于位于每个子块的边界上的样点。或者,可将滤波器应用于每个子块的预测块或重建块,并且,滤波器被应用到的子块的一个或更多个样点可在后续子块的帧内预测中被使用。When performing intra prediction by dividing the current block into sub-blocks and deriving the intra prediction mode of each sub-block using the intra prediction modes of neighboring blocks, filtering may be applied to each sub-block of the current block. For example, a low-pass filter can be applied to the entire current block. Alternatively, the filter can be applied to samples located on the boundaries of each sub-block. Alternatively, a filter may be applied to the prediction block or reconstructed block of each sub-block, and one or more samples of the sub-block to which the filter is applied may be used in intra prediction of subsequent sub-blocks.
在将当前块划分为子块并且针对每个子块执行帧内预测时,每个子块可以是指编码/解码块、预测块和变换块中的至少一个。例如,如果当前块的大小是64×64并且子块的大小是16×16,则可推导作为每个子块的预测块的帧内预测模式,和/或可针对预测块执行帧内预测。如果一个或更多个子块中的每一个子块被进一步划分为8×8或4×4的块,则8×8或4×4的块中的每一个可以是变换块,并且可使用16×16的块的帧内预测模式针对通过进一步划分而获得的块执行帧内预测。When the current block is divided into sub-blocks and intra prediction is performed for each sub-block, each sub-block may refer to at least one of an encoding/decoding block, a prediction block, and a transformation block. For example, if the size of the current block is 64×64 and the size of the sub-block is 16×16, an intra prediction mode as a prediction block for each sub-block may be derived, and/or intra prediction may be performed for the prediction block. If each of the one or more sub-blocks is further divided into 8×8 or 4×4 blocks, then each of the 8×8 or 4×4 blocks may be a transform block, and 16 The intra prediction mode of ×16 blocks performs intra prediction on blocks obtained by further dividing.
在方向帧内预测中,可使用N个方向模式中的至少一个方向模式对当前块进行编码/解码。这里,N可以是正整数,诸如33或65。在这种情况下,每个方向帧内预测模式可具有预定角度值。In directional intra prediction, the current block may be encoded/decoded using at least one direction mode among N direction modes. Here, N may be a positive integer such as 33 or 65. In this case, each direction intra prediction mode may have a predetermined angle value.
在方向帧内预测中,可以利用以M个样点为单位的方向模式对当前块进行编码/解码。M可以是正整数。在这种情况下,以样点为单位的方向模式可意为使用一个或更多个方向帧内预测模式对当前块中的一个或更多个预测目标样点单元进行预测的模式。In directional intra prediction, the current block can be encoded/decoded using a directional pattern in units of M samples. M can be a positive integer. In this case, the directional mode in sample units may mean a mode in which one or more prediction target sample units in the current block are predicted using one or more directional intra prediction modes.
在方向帧内预测中,可根据方向预测模式重建构建的参考样点。例如,如果方向预测模式是所有的左侧参考样点和上方参考样点被使用的模式,则可利用左侧参考样点或上方参考样点来构建单方向阵列。In directional intra prediction, the constructed reference samples can be reconstructed according to the directional prediction mode. For example, if the direction prediction mode is a mode in which all left reference samples and upper reference samples are used, then the left reference sample or the upper reference sample can be used to construct a unidirectional array.
图40是描绘从Pref产生1D参考样点阵列p1,ref的实施例的示图。Figure 40 is a diagram depicting an embodiment of generating a ID reference sample array p1,ref fromPref .
例如,如图40中所示,可使用一个或更多个左侧参考样点来构建上方参考样点的1D阵列。可根据方向模式使用左侧样点中的不同样点来构建上方参考样点。可通过移动左侧参考样点来构建上方参考样点,或者,可通过使用一个或更多个左侧参考样点的加权和来构建上方参考样点。For example, as shown in Figure 40, one or more left reference samples may be used to construct a ID array of upper reference samples. The upper reference sample can be constructed using different samples from the left sample depending on the direction mode. The upper reference sample can be constructed by moving the left reference sample, or the upper reference sample can be constructed by using a weighted sum of one or more left reference samples.
在方向帧内预测中,可执行基于实数的插值预测。例如,如下所述,可基于与每个方向预测模式相应的角度参数(intraPredAngle),根据当前块中的样点的位置确定用于预测样点插值的偏移(iIdx)和/或权重(iFact)。In directional intra prediction, real number-based interpolation prediction can be performed. For example, as described below, the offset (iIdx) and/or weight (iFact ).
例如,假设以1/32pel为单位进行插值,可通过下面的[等式19]确定用于具有垂直方向的方向模式的偏移和权重。For example, assuming interpolation in units of 1/32 pel, the offset and weight for the directional pattern with vertical orientation can be determined by [Equation 19] below.
[等式19][Equation 19]
iIdx=((y+1)*intraPredAngle)>>5iIdx=((y+1)*intraPredAngle)>>5
iFact=((y+1)*intraPredAngle)&31iFact=((y+1)*intraPredAngle)&31
可根据[等式19]中的iFact的值来确定不同的预测样点值。例如,如果iFact不为0,则参考样点P1,ref的预测位置不是基于整数的位置(整样点位置),而是基于实数的位置。因此,可通过下面的[等式20]使用与实数位置相邻的多个参考样点(例如,两个左侧和右侧的相邻参考样点)来产生在目标样点位置(x,y)处的预测样点值。这里,相邻的多个参考样点可以是4或6个左侧和右侧的相邻参考样点。Different predicted sample values can be determined based on the value of iFact in [Equation 19]. For example, if iFact is not 0, the predicted position of the reference sample point P1,ref is not based on the position of an integer (the position of the integer sample point), but based on the position of a real number. Therefore, the target sample position (x, The predicted sample value at y). Here, the adjacent multiple reference sample points may be 4 or 6 adjacent reference sample points on the left and right sides.
[等式20][Equation 20]
predSamples[x][y]=((32-iFact)*pl,ref[x+iIdx+11+iFact*p1,ref[x+iIdx+2]+16)>>5predSamples[x][y]=((32-iFact)*pl, ref [x+iIdx+11+iFact*p1, ref [x+iIdx+2]+16)>>5
例如,如果iFact是0,则可通过下面的[等式21]来产生预测样点值。或者,可使用参考样点P1,ref以及左侧和右侧参考样点来应用3抽头[1/4:2/4:1/4]滤波器。For example, if iFact is 0, the predicted sample values can be generated by [Equation 21] below. Alternatively, a 3-tap [1/4:2/4:1/4] filter can be applied using the reference sample P1,ref and the left and right reference samples.
[等式21][Equation 21]
predSamples[x][y]=P1,ref[x+iIdx+1]predSamples[x][y]=P1,ref [x+iIdx+1]
在方向预测模式中的水平模式和/或垂直模式中的至少一个的情况下,可不针对参考样点执行滤波。另外,该参考样点可能不需要插值预测。此外,由于仅能够利用上方或左侧参考样点进行预测,因此可能不需要针对该参考样点构建1D阵列的处理。In the case of at least one of the horizontal mode and/or the vertical mode among the directional prediction modes, filtering may not be performed for the reference samples. Additionally, the reference sample may not require interpolation prediction. Furthermore, since prediction can only be made using the upper or left reference sample points, the process of constructing a 1D array for this reference sample point may not be required.
图41是描绘根据预测块中的样点的位置使用不同角度处的参考样点的实施例的示图。Figure 41 is a diagram depicting an embodiment of using reference samples at different angles depending on the location of the sample in a prediction block.
如图41中所示,在方向帧内预测中,可改变方向模式被应用于的单元。也就是说,可基于目标块中的样点单元、样点组单元和线单元中的至少一个,使用一个或更多个方向模式执行预测。As shown in FIG. 41, in directional intra prediction, the unit to which the directional mode is applied can be changed. That is, prediction may be performed using one or more direction modes based on at least one of sample units, sample group units, and line units in the target block.
例如,可基于当前块使用方向模式来执行预测。或者,可针对在当前块中用于进行预测的每个目标样点线使用方向模式来执行预测。也就是说,可针对当前块的水平线或垂直线中的至少一条线中的每一个,使用不同的方向模式来执行预测。或者,可针对在当前块中用于进行预测的每个预定目标样点组使用方向模式执行预测。也就是说,可针对当前块中的包括N个样点的每个组使用不同方向模式来执行预测。例如,可针对当前块中用于进行预测的每个目标样点使用方向模式执行预测。也就是说,可针对当前块中用于进行预测的每个目标样点使用不同方向模式来执行预测。For example, prediction may be performed using direction mode based on the current block. Alternatively, prediction can be performed using direction mode for each target sample line used for prediction in the current block. That is, prediction may be performed using a different direction mode for each of at least one of the horizontal or vertical lines of the current block. Alternatively, prediction may be performed using directional mode for each predetermined target sample group used for prediction in the current block. That is, prediction may be performed using a different direction mode for each group of N samples in the current block. For example, prediction can be performed using directional mode for each target sample in the current block used for prediction. That is, prediction can be performed using a different direction mode for each target sample in the current block used for prediction.
当以当前块为单位执行一个方向预测时,如果编码目标块包括具有多个图像特征的曲线,则编码效率会降低。为了提高编码效率,可以以目标块内部的样点、样点组和线中的至少一个为单位,使用一个或更多个方向模式执行预测。When one direction prediction is performed in units of the current block, if the encoding target block includes curves with multiple image features, the encoding efficiency will be reduced. In order to improve coding efficiency, prediction may be performed using one or more direction patterns in units of at least one of samples, sample groups, and lines inside the target block.
图41的(a)示出不同方向模式被用于目标块中的每个样点的示例性情况。在图41的(a)中示出的示例中,可使用位于每个方向模式的角度上的参考样点,针对每个样点产生预测值。(a) of FIG. 41 shows an exemplary case in which different direction patterns are used for each sample point in the target block. In the example shown in (a) of FIG. 41 , a prediction value may be generated for each sample using reference samples located at the angle of each direction pattern.
图41的(b)示出不同方向模式被用于目标块中的每个水平线的示例性情况。在图41的(b)中示出的示例中,可使用位于每个方向模式的角度上的参考样点,针对每个水平线产生预测值。(b) of FIG. 41 shows an exemplary case in which a different direction pattern is used for each horizontal line in the target block. In the example shown in (b) of FIG. 41 , a predicted value can be generated for each horizontal line using reference samples located at the angle of each direction pattern.
图41的(c)示出不同方向模式被用于目标块中的每个垂直线的示例性情况。在图41的(c)中示出的示例中,可使用位于每个方向模式的角度上的参考样点,针对每个垂直线产生预测值。(c) of FIG. 41 shows an exemplary case where a different direction pattern is used for each vertical line in the target block. In the example shown in (c) of FIG. 41 , a predicted value can be generated for each vertical line using reference samples located at the angle of each direction pattern.
图41的(d)示出不同方向模式被应用于目标块中的对角线方向上的每个样点组的示例性情况。在图41的(d)中示出的示例中,可使用位于每个方向模式的角度上的参考样点,针对对角线方向上的每个对角样点组产生预测值。(d) of FIG. 41 shows an exemplary case in which different direction modes are applied to each sample point group in the diagonal direction in the target block. In the example shown in (d) of FIG. 41 , a prediction value may be generated for each diagonal sample group in the diagonal direction using reference samples located at the angle of each direction pattern.
图41的(e)示出不同方向模式被用于目标块中的每个L形线的示例性情况。在图41的(e)中示出的示例中,可使用位于每个方向模式的角度上的参考样点,针对每条直角线产生预测值。(e) of FIG. 41 shows an exemplary case where different direction patterns are used for each L-shaped line in the target block. In the example shown in (e) of FIG. 41 , a prediction value can be generated for each right-angled line using reference sample points located at the angle of each direction pattern.
除了图41的示例之外,可使用用于对一个或更多个样点进行分组的各种方法。例如,可将不同方向模式应用于通过将高度和/或宽度除以任意数而产生的每个块。In addition to the example of Figure 41, various methods for grouping one or more sample points may be used. For example, a different orientation mode can be applied to each block produced by dividing the height and/or width by any number.
作为以目标块中的样点为单位使用不同方向模式的实施例,可通过使用曲率参数cuv和权重参数cwi(i=0、1、…、NS-1,NS:块大小)来确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。As an example of using different direction patterns in units of sample points in the target block, it can be determined by using the curvature parameter cuv and the weight parameter cwi (i=0, 1, ...,NS -1,NS : block size) The position of the reference pixel used to generate the prediction value for any position (x, y) within the prediction block.
例如,在“从右上方的边到左下方的边”的帧内预测的情况下,如下面的方程式22,可按照行单元确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction "from the upper right edge to the lower left edge", as shown in Equation 22 below, the prediction for generating an arbitrary position (x, y) within the prediction block can be determined in row units The position of the reference pixel for the value.
[方程式22][Equation 22]
第y行→p(pos,-1),其中,pos=x+1/2*(x+y)+cwy*cuv*(x+1),Row y→p(pos,-1), where pos=x+1/2*(x+y)+cwy *cuv*(x+1),
其中,y=0,1,…,Ns-1Among them, y=0,1,…,Ns -1
在使用上面的方程式22进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向右移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向左移动(直到x的位置)。In the case of intra prediction using Equation 22 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can move to the right. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved to the left (up to the position of x).
当目标块是N×M时,cwi可以是包括N个权重的参数,其中,所述参数指块的高度或行的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应行中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i行的预测像素使用的参考像素的位置可向右移动。可选地,cwi值变得越小,则参考像素的位置可向左移动(直到x的位置)。When the target block is N×M,cwi may be a parameter including N weights, where the parameter refers to the height of the block or the number of rows. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding row can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th row may be moved to the right. Alternatively, the position of the reference pixel can be moved to the left (up to the position of x) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重行参数cwi进行组合来执行各种形式的帧内预测。Therefore, various forms of intra prediction can be performed by combining the curvature parameter cuv and/or the weight row parametercwi .
图42是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从右上方的边到左下方的边的方向执行预测的实施例的示图。FIG. 42 is a diagram illustrating the steps from the upper right side to the lower left by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图43是示出作为应用图42的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 43 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 42 .
为了产生预测像素值,可执行所描述的以1/N pel为单位的插值预测。N可以是正整数。To generate predicted pixel values, the described interpolation prediction in units of 1/N pel can be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是正整数单位时,可通过参考像素p(pos,-1)来推导预测目标像素predSamples[x][y]。pos可指参考像素的位置。For example, when the position of the reference pixel of the prediction target pixel is a positive integer unit, the prediction target pixel predSamples[x][y] can be derived through the reference pixel p(pos,-1). pos can refer to the position of the reference pixel.
例如,当预测目标像素的参考像素的位置是实数帧间单位时,predSamples[x][y]可被推导为通过对p(floor(pos),-1)和p(ceil(pos),-1)执行以1/N pel为单位的插值预测而获得的插值预测数。floor(pos)可以是等于或小于pos的整数值,并且可以指最大值。ceil(pos)可以是等于或大于pos的整数,并且可以指最小值。For example, when the position of the reference pixel for predicting the target pixel is a real inter-frame unit, predSamples[x][y] can be derived as by p(floor(pos),-1) and p(ceil(pos),- 1) The number of interpolation predictions obtained by performing interpolation prediction in units of 1/N pel. floor(pos) can be an integer value equal to or less than pos, and can refer to the maximum value. ceil(pos) can be an integer equal to or greater than pos, and can refer to the minimum value.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图42中,超过P(7,-1))时,所有参考像素的计算出的位置可在通过与可用参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 42, exceeds P(7,-1)), the calculated positions of all reference pixels can be determined by matching the maximum range of available reference pixels. are used after being converted to their respective normalized values.
例如,在“从左上方的边到右下方的边(类型-1)”的帧内预测的情况下,如下面的方程式23,可按照行单元确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction “from the upper left edge to the lower right edge (type-1)”, as shown in Equation 23 below, the arbitrary position (x , the position of the reference pixel of the predicted value of y).
[方程式23][Equation 23]
第y行→p(pos,-1),其中,pos=x-1/2*(Ns-1-x+y)-cwy*cuv*(Ns-x),Row y→p(pos,-1), where pos=x-1/2*(Ns -1-x+y)-cwy *cuv*(Ns -x),
其中,y=0,1,…,Ns-1Among them, y=0,1,…,Ns -1
在使用上面的方程23进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向左移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向右移动(直到x的位置)。In the case of intra prediction using Equation 23 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can be moved to the left. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved to the right (up to the position of x).
当目标块是N×M时,cwi可以是包括N个权重的参数,其中,所述参数指块的高度或行的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应行中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i行的预测像素使用的参考像素的位置可向左移动。可选地,cwi值变得越小,则参考像素的位置可向右移动(直到x的位置)。When the target block is N×M,cwi may be a parameter including N weights, where the parameter refers to the height of the block or the number of rows. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding row can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th row may be moved to the left. Alternatively, the position of the reference pixel can be moved to the right (up to the position of x) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重行参数cwi进行组合来执行各种形式的弯曲帧内预测。Therefore, various forms of curved intra prediction can be performed by combining the curvature parameter cuv and/or the weight row parametercwi .
图44是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从左上方的边到右下方的边的方向(类型-1)执行预测的实施例的示图。44 is a diagram illustrating the steps from the upper left side to the lower right side by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment where prediction is performed for edge direction (Type-1).
图45是示出作为应用图44的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 45 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 44 .
为了产生预测像素值,可执行所描述的以1/N pel为单位的插值预测。N可以是正整数。To generate predicted pixel values, the described interpolation prediction in units of 1/N pel can be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是正整数单位时,预测目标像素predSamples[x][y]可被推导为参考像素p(pos,-1)。For example, when the position of the reference pixel of the prediction target pixel is a positive integer unit, the prediction target pixel predSamples[x][y] can be derived as the reference pixel p(pos,-1).
例如,当预测目标像素的参考像素的位置是实数单位时,predSamples[x][y]可被推导为通过对p(floor(pos),-1)和p(ceil(pos),-1)执行以1/N pel为单位的插值预测而获得的插值预测值。For example, when the position of the reference pixel of the predicted target pixel is in real units, predSamples[x][y] can be derived as by p(floor(pos),-1) and p(ceil(pos),-1) Interpolated prediction value obtained by performing interpolation prediction in units of 1/N pel.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图29中,超过P(-7,-1))时,所有参考像素的计算出的位置可在通过与可用参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 29, exceeds P(-7,-1)), the calculated positions of all reference pixels can be matched with the maximum range of available reference pixels by and are used after being converted into their respective normalized values.
例如,在“从左下方的边到右上方的边”的帧内预测的情况下,如下面的方程式24,可按照列单元确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction "from the lower left edge to the upper right edge", as shown in Equation 24 below, the prediction for generating an arbitrary position (x, y) within the prediction block can be determined in column units The position of the reference pixel for the value.
[方程式24][Equation 24]
第x列→p(-1,pos),其中,pos=y+1/2*(x+y)+cwx*cuv*(y+1),Column x→p(-1,pos), where pos=y+1/2*(x+y)+cwx *cuv*(y+1),
其中,x=0,1,…,Ns-1Among them, x=0,1,…,Ns -1
在使用上面的方程式24进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向下移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向上移动(直到y的位置)。In the case of intra prediction using Equation 24 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can be moved downward. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved upward (up to the y position).
当目标块是N×M时,cwi可以是包括M个权重的参数,其中,所述参数指块的宽度或列的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应列中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i列的预测像素使用的参考像素的位置可向下移动。可选地,cwi值变得越小,则参考像素的位置可向上移动(直到y的位置)。When the target block is N×M,cwi may be a parameter including M weights, where the parameter refers to the width of the block or the number of columns. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding column can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th column may be moved downward. Alternatively, the position of the reference pixel can be moved upward (up to the y position) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重列参数cwi进行组合来执行各种形式的帧内预测。Therefore, various forms of intra prediction can be performed by combining the curvature parameter cuv and/or the weight column parametercwi .
图46是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从左下方的边到右上方的边的方向执行预测的实施例的示图。46 is a diagram illustrating the steps from the lower left side to the upper right side by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图47是示出作为应用图46的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 47 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 46 .
为了产生预测像素值,可执行所描述的以1/N pel为单位的插值预测。N可以是正整数。To generate predicted pixel values, the described interpolation prediction in units of 1/N pel can be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是整数单位时,预测目标像素predSamples[x][y]可被推导为参考像素p(-1,pos)。For example, when the position of the reference pixel of the prediction target pixel is an integer unit, the prediction target pixel predSamples[x][y] can be derived as the reference pixel p(-1,pos).
例如,当预测目标像素的参考像素的位置是实数单位时,predSamples[x][y]可被推导为通过对p(-1,floor(pos))和p(-1,ceil(pos))执行以1/N pel为单位的插值预测而获得的插值预测值。For example, when the position of the reference pixel of the predicted target pixel is in real units, predSamples[x][y] can be derived as Interpolated prediction value obtained by performing interpolation prediction in units of 1/N pel.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图46中,超过P(-1,7))时,所有参考像素的计算出的位置可在通过与可用参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 46, exceeds P(-1,7)), the calculated positions of all reference pixels can be determined by matching the maximum range of available reference pixels. are used after being converted to their respective normalized values.
例如,在“从左上方的边到右下方的边(类型-2)”的帧内预测的情况下,如下面的方程式25,可按照列单元确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction “from the upper left edge to the lower right edge (Type-2)”, as shown in Equation 25 below, the arbitrary position (x , the position of the reference pixel of the predicted value of y).
[方程式25][Equation 25]
第x列→p(-1,pos),其中,pos=y-1/2*(Ns-1-y+x)-cwx*cuv*(Ns-y),Column x→p(-1,pos), where pos=y-1/2*(Ns -1-y+x)-cwx *cuv*(Ns -y),
其中,x=0,1,…,Ns-1Among them, x=0,1,…,Ns -1
在使用上面的方程式25进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向上移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向下移动(直到y的位置)。In the case of intra prediction using Equation 25 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can be moved upward. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved downward (up to the y position).
当目标块是N×M时,cwi可以是包括M个权重的参数,其中,所述参数指块的宽度或列的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应列中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i列的预测像素使用的参考像素的位置可向上移动。可选地,cwi值变得越小,则参考像素的位置可向下移动(直到y的位置)。When the target block is N×M,cwi may be a parameter including M weights, where the parameter refers to the width of the block or the number of columns. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding column can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th column may be moved upward. Alternatively, the position of the reference pixel can be moved downward (up to the y position) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重列参数cwi进行组合来执行各种形式的帧内预测。Therefore, various forms of intra prediction can be performed by combining the curvature parameter cuv and/or the weight column parametercwi .
图48是示出通过向大小为4×4的当前块应用cuv=0.1、cw0=1.0、cw1=1.2、cw2=1.4和cw3=1.6,按照从左上方的边到右下方的边的方向(类型-2)执行预测的实施例的示图。FIG. 48 is a diagram illustrating the steps from the upper left side to the lower right side by applying cuv=0.1, cw0 =1.0, cw1 =1.2, cw2 =1.4, and cw3 =1.6 to the current block of size 4×4. Illustration of an embodiment where prediction is performed for edge direction (Type-2).
图49是示出作为应用图48的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 49 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 48 .
为了产生预测像素值,可执行所描述的以1/N pel为单位的插值预测。N可以是正整数。To generate predicted pixel values, the described interpolation prediction in units of 1/N pel can be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是整数单位时,预测目标像素predSamples[x][y]可被推导为参考像素p(-1,pos)。For example, when the position of the reference pixel of the prediction target pixel is an integer unit, the prediction target pixel predSamples[x][y] can be derived as the reference pixel p(-1,pos).
例如,当预测目标像素的参考像素的位置是实数单位时,predSamples[x][y]可被推导为通过对p(-1,floor(pos))和p(-1,ceil(pos))执行以1/N pel为单位的插值预测而获得的插值预测值。For example, when the position of the reference pixel of the predicted target pixel is in real units, predSamples[x][y] can be derived as Interpolated prediction value obtained by performing interpolation prediction in units of 1/N pel.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图48中,超过P(-1,-7))时,所有参考像素的计算出的位置可在通过与可用参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 48, exceeds P(-1,-7)), the calculated positions of all reference pixels can be matched with the maximum range of available reference pixels by and are used after being converted into their respective normalized values.
例如,在“从上方的边到左下方的边”的帧内预测的情况下,如下面的方程式26,可按照行单元确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction "from the upper edge to the lower left edge", as shown in Equation 26 below, the prediction value for generating an arbitrary position (x, y) within the prediction block can be determined in row units the position of the reference pixel.
[方程式26][Equation 26]
第y行→p(pos,-1),其中,pos=x+cwy*cuv*y,其中,y=0,1,…,Ns-1Row y→p(pos,-1), where pos=x+cwy *cuv*y, where y=0,1,…,Ns -1
在使用上面的方程式26进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向右移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向左移动(直到x的位置)。In the case of intra prediction using Equation 26 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can move to the right. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved to the left (up to the position of x).
当目标块是N×M时,cwi可以是包括N个权重的参数,其中,所述参数指块的高度或行的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应行中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i行的预测像素使用的参考像素的位置可向右移动。可选地,cwi值变得越小,则参考像素的位置可向左移动(直到x的位置)。When the target block is N×M,cwi may be a parameter including N weights, where the parameter refers to the height of the block or the number of rows. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding row can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th row may be moved to the right. Alternatively, the position of the reference pixel can be moved to the left (up to the position of x) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重行参数cwi进行组合来执行各种形式的帧内预测。Therefore, various forms of intra prediction can be performed by combining the curvature parameter cuv and/or the weight row parametercwi .
图50是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从上方的边到左下方的边的方向执行预测的实施例的示图。FIG. 50 is a diagram illustrating the steps from the upper side to the lower left side by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment of performing prediction in the direction of .
图51是示出作为应用图50的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 51 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 50 .
为了产生预测像素值,可执行所描述的以1/N pel为单位的插值预测。N可以是正整数。To generate predicted pixel values, the described interpolation prediction in units of 1/N pel can be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是整数单位时,预测目标像素predSamples[x][y]可被推导为参考像素p(pos,-1)。For example, when the position of the reference pixel of the prediction target pixel is an integer unit, the prediction target pixel predSamples[x][y] can be derived as the reference pixel p(pos,-1).
例如,当预测目标像素的参考像素的位置是实数单位时,predSamples[x][y]可被推导为通过对p(floor(pos),-1)和p(ceil(pos),-1)执行以1/N pel为单位的插值预测而获得的插值预测值。For example, when the position of the reference pixel of the predicted target pixel is in real units, predSamples[x][y] can be derived as by p(floor(pos),-1) and p(ceil(pos),-1) Interpolated prediction value obtained by performing interpolation prediction in units of 1/N pel.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图50中,超过P(7,-1))时,所有参考像素的计算出的位置可在通过与可用参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 50, exceeds P(7,-1)), the calculated positions of all reference pixels can be determined by matching the maximum range of available reference pixels. are used after being converted to their respective normalized values.
例如,在“从上方的边到右下方的边”的帧内预测的情况下,如下面的方程式27,可按照行单元确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction "from the upper edge to the lower right edge", as shown in Equation 27 below, the prediction value for generating an arbitrary position (x, y) within the prediction block can be determined in row units the position of the reference pixel.
[方程式27][Equation 27]
第y行→p(pos,-1),其中,pos=x-cwy*cuv*y,其中,y=0,1,…,Ns-1Row y→p(pos,-1), where pos=x-cwy *cuv*y, where y=0,1,…,Ns -1
在使用上面的方程式27进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向左移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向右移动(直到x的位置)。In the case of intra prediction using Equation 27 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can be moved to the left. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved to the right (up to the position of x).
当目标块是N×M时,cwi可以是包括N个权重的参数,其中,所述参数指块的高度或行的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应行中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i行的预测像素使用的参考像素的位置可向左移动。可选地,cwi值变得越小,则参考像素的位置可向右移动(直到x的位置)。When the target block is N×M,cwi may be a parameter including N weights, where the parameter refers to the height of the block or the number of rows. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding row can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th row may be moved to the left. Alternatively, the position of the reference pixel can be moved to the right (up to the position of x) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重行参数cwi进行组合来执行各种形式的帧内预测。Therefore, various forms of intra prediction can be performed by combining the curvature parameter cuv and/or the weight row parametercwi .
图52是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从上方的边到右下方的边的方向执行预测的实施例的示图。FIG. 52 is a diagram illustrating the steps from the upper side to the lower right side by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment of performing prediction in the direction of .
图53是示出作为应用图52的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 53 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 52 .
为了产生预测像素值,可执行所描述的以1/N pel为单位的插值预测。N可以是正整数。To generate predicted pixel values, the described interpolation prediction in units of 1/N pel can be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是整数单位时,预测目标像素predSamples[x][y]可被推导为p(pos,-1)。For example, when the position of the reference pixel of the prediction target pixel is an integer unit, the prediction target pixel predSamples[x][y] can be derived as p(pos,-1).
例如,当预测目标像素的参考像素的位置是实数单位时,predSamples[x][y]可被推导为通过对p(floor(pos),-1)和p(ceil(pos),-1)执行以1/N pel为单位的插值预测而获得的插值预测值。For example, when the position of the reference pixel of the predicted target pixel is in real units, predSamples[x][y] can be derived as by p(floor(pos),-1) and p(ceil(pos),-1) Interpolated prediction value obtained by performing interpolation prediction in units of 1/N pel.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图52中,超过P(-7,-1))时,所有参考像素的计算出的位置可在通过与可用参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 52, exceeds P(-7,-1)), the calculated positions of all reference pixels can be matched with the maximum range of available reference pixels by and are used after being converted into their respective normalized values.
例如,在“从左侧的边到右上方的边”的帧内预测的情况下,如下面的方程式28,可按照列单元确定用于产生预测块内的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction "from the left side to the upper right side", as shown in Equation 28 below, the prediction for generating an arbitrary position (x, y) within the prediction block can be determined in column units The position of the reference pixel for the value.
[方程式28][Equation 28]
第x列→p(pos,-1),其中,pos=y+cwx*cuv*x,其中,x=0,1,…,Ns-1Column x→p(pos,-1), where pos=y+cwx *cuv*x, where x=0,1,…,Ns -1
在使用上面的方程式28进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向下移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向上移动(直到y的位置)。In the case of intra prediction using Equation 28 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can be moved downward. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved upward (up to the y position).
当目标块是N×M时,cwi可以是包括M个权重的参数,其中,所述参数指块的宽度或列的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应列中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i列的预测像素使用的参考像素的位置可向下移动。可选地,cwi值变得越小,则参考像素的位置可向上移动(直到y的位置)。When the target block is N×M,cwi may be a parameter including M weights, where the parameter refers to the width of the block or the number of columns. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding column can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th column may be moved downward. Alternatively, the position of the reference pixel can be moved upward (up to the y position) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重列参数cwi进行组合来执行各种形式的弯曲帧内预测。Therefore, various forms of curved intra prediction can be performed by combining the curvature parameter cuv and/or the weight column parametercwi .
图54是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从左侧的边到右上方的边的方向执行预测的实施例的示图。54 is a diagram illustrating the steps from the left side to the upper right by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图55是示出作为应用图54的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 55 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 54 .
为了产生预测像素值,可执行所描述的以1/N pel为单位的插值预测。N可以是正整数。To generate predicted pixel values, the described interpolation prediction in units of 1/N pel can be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是整数单位时,预测目标像素predSamples[x][y]可被推导为参考像素p(-1,pos)。For example, when the position of the reference pixel of the prediction target pixel is an integer unit, the prediction target pixel predSamples[x][y] can be derived as the reference pixel p(-1, pos).
例如,当预测目标像素的参考像素的位置是实数单位时,predSamples[x][y]可被推导为通过对p(-1,floor(pos))和p(-1,ceil(pos))执行以1/N pel为单位的插值预测而获得的插值预测值。For example, when the position of the reference pixel of the predicted target pixel is in real units, predSamples[x][y] can be derived as Interpolated prediction value obtained by performing interpolation prediction in units of 1/N pel.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图54中,超过P(-1,7))时,所有参考像素的计算出的位置可在通过与可用参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 54, exceeds P(-1,7)), the calculated positions of all reference pixels can be determined by matching the maximum range of available reference pixels. are used after being converted to their respective normalized values.
例如,在“从左侧的边到右下方的边”的帧内预测的情况下,如下面的方程式29,可按照列单元确定用于产生预测块的任意位置(x,y)的预测值的参考像素的位置。For example, in the case of intra prediction "from the left side to the lower right side", as shown in Equation 29 below, the prediction value for generating an arbitrary position (x, y) of the prediction block can be determined in column units the position of the reference pixel.
[方程式29][Equation 29]
第x列→p(pos,-1),其中,pos=y-cwx*cuv*x,其中,x=0,1,…,Ns-1The xth column → p(pos,-1), where pos=y-cwx *cuv*x, where x=0,1,…,Ns -1
在使用上面的方程式29进行帧内预测的情况下,可通过调整cuv来调整曲率的大小。cuv可以是等于或大于零的实数。例如,cuv值变得越大,则曲率变得越大,并且参考像素的位置可向上移动。可选地,cuv值变得越小,则曲率变得越小,并且参考像素的位置可向下移动(直到y的位置)。In the case of intra prediction using Equation 29 above, the size of the curvature can be adjusted by adjusting the cuv. cuv can be a real number equal to or greater than zero. For example, as the cuv value becomes larger, the curvature becomes larger, and the position of the reference pixel can be moved upward. Alternatively, the smaller the cuv value becomes, the smaller the curvature becomes, and the position of the reference pixel can be moved downward (up to the y position).
当目标块是N×M时,cwi可以是包括M个权重的参数,其中,所述参数指块的宽度或列的数量。每个权重可以是等于或大于零的实数。可通过调整cwi来调整被相应列中包括的预测像素所使用的参考像素的位置。例如,cwi值变得越大,则被第i列的预测像素使用的参考像素的位置可向上移动。可选地,cwi值变得越小,则参考像素的位置可向下移动(直到y的位置)。When the target block is N×M,cwi may be a parameter including M weights, where the parameter refers to the width of the block or the number of columns. Each weight can be a real number equal to or greater than zero. The position of the reference pixel used by the predicted pixels included in the corresponding column can be adjusted by adjustingcwi . For example, as thecwi value becomes larger, the position of the reference pixel used by the predicted pixel of the i-th column may be moved upward. Alternatively, the position of the reference pixel can be moved downward (up to the y position) as thecwi value becomes smaller.
因此,可通过对曲率参数cuv和/或权重列参数cwi进行组合来执行各种形式的弯曲帧内预测。Therefore, various forms of curved intra prediction can be performed by combining the curvature parameter cuv and/or the weight column parametercwi .
图56是示出通过向大小为4×4的当前块应用cuv=0.6、cw0=1.0、cw1=1.4、cw2=1.8和cw3=2.2,按照从左侧的边到右下方的边的方向执行预测的实施例的示图。FIG. 56 is a diagram illustrating the steps from the left side to the lower right by applying cuv=0.6, cw0 =1.0, cw1 =1.4, cw2 =1.8, and cw3 =2.2 to the current block of size 4×4. Illustration of an embodiment in which edge direction prediction is performed.
图57是示出作为应用图56的cuv和cwi的结果的、由当前块内的预测像素使用的参考像素的位置的实施例的示图。FIG. 57 is a diagram illustrating an example of the positions of reference pixels used by prediction pixels within the current block as a result of applying cuv andcwi of FIG. 56 .
为了产生预测像素值,可执行所描述的插值预测。N可以是正整数。To generate predicted pixel values, interpolation prediction as described may be performed. N can be a positive integer.
例如,当预测目标像素的参考像素的位置是整数单位时,预测目标像素predSamples[x][y]可被推导为参考像素p(-1,pos)。For example, when the position of the reference pixel of the prediction target pixel is an integer unit, the prediction target pixel predSamples[x][y] can be derived as the reference pixel p(-1,pos).
例如,当预测目标像素的参考像素的位置是实数单位时,predSamples[x][y]可被推导为通过对p(-1,floor(pos))和p(-1,ceil(pos))执行以1/N pel为单位的插值预测而获得的插值预测值。For example, when the position of the reference pixel of the predicted target pixel is in real units, predSamples[x][y] can be derived as Interpolated prediction value obtained by performing interpolation prediction in units of 1/N pel.
如上所述,为了计算方便,可在产生预测样点值之前将pref转换为p1,ref。As mentioned above, for calculation convenience, pref can be converted to p1,ref before generating predicted sample values.
当参考像素的位置pos超过可用参考像素的最大范围(在图56中,超过P(-1,-7))时,所有参考像素的计算出的位置可在通过与参考像素的最大范围匹配而被转换成各自的标准化值之后被使用。When the position pos of the reference pixel exceeds the maximum range of available reference pixels (in Figure 56, exceeds P(-1,-7)), the calculated positions of all reference pixels can be determined by matching the maximum range of the reference pixels. are used after being converted to their respective normalized values.
在参照图42至57描述的实施例中,单个曲率参数cuv被应用于当前块,并且单个权重参数cw被应用于当前块的行或列。然而,不限于此。换句话说,至少一个曲率参数cuvi和/或至少一个权重参数cwi可被应用于当前块。例如,如参照图41所描述的,不同的曲率参数cuvi和不同的权重参数cwi可被应用于当前块的像素单元、水平线单元、垂直线单元、对角线单元、直角线单元、子块单元和/或任意像素组单元。In the embodiment described with reference to Figures 42 to 57, a single curvature parameter cuv is applied to the current block, and a single weight parameter cw is applied to the row or column of the current block. However, it is not limited to this. In other words, at least one curvature parameter cuvi and/or at least one weight parametercwi may be applied to the current block. For example, as described with reference to FIG. 41 , different curvature parameters cuvi and different weight parameterscwi may be applied to pixel units, horizontal line units, vertical line units, diagonal line units, rectangular line units, sub-units of the current block. Block units and/or arbitrary pixel group units.
图58是用于解释在目标块中以样点为单位使用不同方向模式的另一实施例的示图。FIG. 58 is a diagram for explaining another embodiment of using different direction patterns on a sample unit basis in a target block.
如图58中所示,基于以块为单位所选择的帧内预测模式,可执行以样点为单位的帧内预测。在此情况下,可另外地执行以样点为单位的帧内预测。As shown in FIG. 58 , based on the intra prediction mode selected in block units, intra prediction in sample units may be performed. In this case, sample-unit intra prediction may be additionally performed.
例如,当所选择的帧内预测模式是非方向模式(PLANAR_MODE或DC_MODE)时,可不仅仅执行以样点为单位的预测。For example, when the selected intra prediction mode is a non-directional mode (PLANAR_MODE or DC_MODE), not only prediction in sample units may be performed.
在图58的(a)中,当所选择的块的帧内预测模式被包括在范围A中时,可执行从左下方的边→右上方的边的方向以及从左侧的边→右上方的边的方向的以样点为单位的预测之中的至少一个。In (a) of FIG. 58 , when the intra prediction mode of the selected block is included in the range A, the direction from the lower left side → the upper right side and the direction from the left side → the upper right side may be performed. At least one of the predictions in sample points for the direction of the edge.
可选地,在图58的(a)中,当所选择的块的帧内预测模式被包括在范围B中时,可执行从左上方的边→右下方的边的方向(类型2)以及从左侧的边→右下方的边的方向的以样点为单位的预测之中的至少一个。Alternatively, in (a) of FIG. 58 , when the intra prediction mode of the selected block is included in the range B, the direction from the upper left side → the lower right side (Type 2) and from At least one of the predictions in sample points in the direction of the left edge → the lower right edge.
可选地,在图58的(a)中,当所选择的块的帧内预测模式被包括在范围C中时,可执行从左上方的边→右下方的边的方向(类型1)以及从上方的边→右下方的边的方向的以样点为单位的预测之中的至少一个。Alternatively, in (a) of FIG. 58 , when the intra prediction mode of the selected block is included in the range C, the direction from the upper left side → the lower right side (Type 1) and from At least one of the predictions in sample points in the direction of the upper edge → the lower right edge.
可选地,在图58的(a)中,当所选择的块的帧内预测模式被包括在范围D中时,可执行从右上方的边→左下方的边的方向以及从上方的边→左下方的边的方向的以样点为单位的预测之中的至少一个。Alternatively, in (a) of FIG. 58 , when the intra prediction mode of the selected block is included in the range D, the direction from the upper right side → the lower left side and the direction from the upper side → At least one of the predictions in sample points for the direction of the lower left edge.
可选地,在图58的(b)中,当所选择的块的帧内预测模式被包括在范围A中时,可执行从左侧的边→右下方的边的方向以及从左侧的边→右上方的边的方向的以样点为单位的预测之中的至少一个。Alternatively, in (b) of FIG. 58 , when the intra prediction mode of the selected block is included in the range A, the direction from the left side → the lower right side and the direction from the left side may be performed →At least one of the predictions in sample points for the direction of the upper right edge.
可选地,在图58的(b)中,当所选择的块的帧内预测模式被包括在范围B中时,可执行从上方的边→左下方的边的方向以及从上方的边→右下方的边的方向的以样点为单位的预测之中的至少一个。Alternatively, in (b) of FIG. 58 , when the intra prediction mode of the selected block is included in the range B, the direction from the upper side → the lower left side and the direction from the upper side → right may be performed. At least one of the predictions in sample points for the direction of the edge below.
图59是描绘对残差信号进行预测的实施例的示图。Figure 59 is a diagram depicting an embodiment of predicting a residual signal.
可针对从帧内预测构建的残差信号额外执行残差信号预测。Residual signal prediction may additionally be performed on the residual signal constructed from intra prediction.
使用已经编码/解码的邻近块的样点针对当前块执行帧内预测。因此,当当前块的样点离参考样点较远时,残差信号较大,从而降低了编码效率。Intra prediction is performed for the current block using samples from neighboring blocks that have been encoded/decoded. Therefore, when the sample point of the current block is far away from the reference sample point, the residual signal is larger, thereby reducing the coding efficiency.
为了进一步减小残差信号,可针对当前块或每个子块额外地执行残差信号预测。To further reduce the residual signal, residual signal prediction may be additionally performed for the current block or each sub-block.
在当前块之前已被编码/解码的重建邻近块可被设置为搜索范围。可根据当前块的大小、形状、划分深度和/或帧内预测模式来设置不同的搜索范围。Reconstructed neighboring blocks that have been encoded/decoded before the current block may be set as the search range. Different search ranges can be set based on the size, shape, partition depth and/or intra prediction mode of the current block.
例如,在当前块之前重建的所有块可被设置为搜索范围。如果与当前块邻近的左侧块、左上方块、上方块和/或右上方块被包括在搜索范围内,则重建块的部分区域可包括当前块或在当前块之后的尚未开始编码的块。在此情况下,可用重建块的可用样点来填充相应样点值,或者,可从搜索范围去除在当前块之后的尚未开始编码的块。For example, all blocks reconstructed before the current block can be set as the search range. If the left block, the upper left block, the upper block and/or the upper right block adjacent to the current block are included in the search range, the partial area of the reconstructed block may include the current block or blocks after the current block that have not yet started encoding. In this case, the corresponding sample values may be filled with available samples of the reconstructed block, or blocks following the current block that have not yet started encoding may be removed from the search range.
例如,在当前块之前被重建的块之中的N个块可被设置为搜索范围。N可以是等于或大于1的正整数。For example, N blocks among blocks reconstructed before the current block may be set as the search range. N can be a positive integer equal to or greater than 1.
例如,如图59中所示,如果当前块CUR_BLK的宽度和长度分别是W和H,并且当前块的左上方像素的位置被定义为(0,0),则包括位置(-2*W,-2*H)、(-W,-2*H)、(0,-2*H)、(W,-2*H)、(-2*W,-H)、(-W,-H)、(0,-H)、(W,-H)、(-2*W,0)和(-W,0)处的像素的10个重建块可被设置为搜索范围。For example, as shown in Figure 59, if the width and length of the current block CUR_BLK are W and H respectively, and the position of the upper left pixel of the current block is defined as (0,0), then the position (-2*W, -2*H), (-W,-2*H), (0,-2*H), (W,-2*H), (-2*W,-H), (-W,-H 10 reconstruction blocks of pixels at ), (0,-H), (W,-H), (-2*W,0), and (-W,0) can be set as the search range.
例如,如果当前块是宽度W和长度H不相等的非正方形块,则可依据W和/或H来设置搜索范围。例如,如果当前块是W×H的非正方形块,则在重建邻近块的区域中可将搜索范围设置为大小(K*W)×(L*H)。这里,K和L中的每一个可以是等于或大于1的正整数。For example, if the current block is a non-square block with unequal width W and length H, the search range can be set based on W and/or H. For example, if the current block is a non-square block of W×H, the search range may be set to a size of (K*W)×(L*H) in the area where neighboring blocks are reconstructed. Here, each of K and L may be a positive integer equal to or greater than 1.
可使用在上述各种帧内预测模式之中的通过帧内预测确定的当前块的帧内预测模式predModeIntra来构建当前块的预测块。The prediction block of the current block may be constructed using the intra prediction mode predModeIntra of the current block determined by intra prediction among the various intra prediction modes described above.
例如,在图59中,可用PRD_BLK_best来表示使用predModeIntra而构建的预测块。For example, in Figure 59, a prediction block constructed using predModeIntra can be represented by PRD_BLK_best.
除了通过predModeIntra构建的该预测块PRD_BLK_best之外,还可以构建当前块的一个或更多个预测块。In addition to this prediction block PRD_BLK_best constructed through predModeIntra, one or more prediction blocks of the current block can be constructed.
例如,可使用所有的方向/非方向帧内预测模式中的至少一个来构建至少一个额外预测块。For example, at least one additional prediction block may be constructed using at least one of all directional/non-directional intra prediction modes.
例如,可使用与predModeIntra邻近的N个帧内预测模式来构建额外预测块。这里,N可以是等于或大于1的正整数。例如,如图59中所示,如果N=2,则可构建两个额外预测块PRD_BLK_plus_one和PRD_BLK_minus_one。例如,如果predModeIntra是方向模式,则可使用predModeIntra+1来构建额外预测块PRD_BLK_plus_one,并且可使用predModeIntra-1来构建其它的额外预测块。可将等于或大于1的正整数与predModeIntra相加,或者,可从predModeIntra减去等于或大于1的正整数。For example, N intra prediction modes adjacent to predModeIntra may be used to construct additional prediction blocks. Here, N can be a positive integer equal to or greater than 1. For example, as shown in FIG. 59, if N=2, two additional prediction blocks PRD_BLK_plus_one and PRD_BLK_minus_one may be constructed. For example, if predModeIntra is the direction mode, predModeIntra+1 can be used to build the extra prediction block PRD_BLK_plus_one, and predModeIntra-1 can be used to build the other extra prediction blocks. A positive integer equal to or greater than 1 may be added to predModeIntra, or a positive integer equal to or greater than 1 may be subtracted from predModeIntra.
例如,可使用关于到predModeIntra的角度的N个邻近帧内预测模式来构建额外预测块。这里,N可以是等于或大于1的正整数。如果角度是θ,则可使用落在从-θ到θ的角度范围内的帧内预测模式来构建额外预测块。For example, the additional prediction block may be constructed using N neighboring intra prediction modes with respect to the angle to predModeIntra. Here, N can be a positive integer equal to or greater than 1. If the angle is θ, the extra prediction block may be constructed using intra prediction modes falling within the angle range from -θ to θ.
例如,可通过对使用N个帧内预测模式而构建的N个额外预测块进行组合来构建M个额外预测块。这里,M和N可以是正整数。例如,如果predModeIntra是非方向模式PLANAR_MODE,则可使用DC_MODE来构建额外预测块PRD_BLK_plus_one,并且可使用PRD_BLK_best和PRD_BLK_plus_one的加权和来构建另一个额外预测块PRD_BLK_minus_one。或者,如果predModeIntra是非方向模式DC_MODE,则可使用PLANAR_MODE来构建额外预测块PRD_BLK_plus_one,并且可使用PRD_BLK_best和PRD_BLK_plus_one的加权和来构建另一个额外预测块PRD_BLK_minus_one。或者,如果predModeIntra是方向模式ANGULAR_MODE,则可使用ANGULAR_MODE来构建额外预测块PRD_BLK_plus_one,并且可使用PRD_BLK_best和PRD_BLK_plus_one的加权和来构建另一个额外预测块PRD_BLK_minus_one。For example, M additional prediction blocks may be constructed by combining N additional prediction blocks constructed using N intra prediction modes. Here, M and N can be positive integers. For example, if predModeIntra is the non-directional mode PLANAR_MODE, DC_MODE may be used to construct the additional prediction block PRD_BLK_plus_one, and the weighted sum of PRD_BLK_best and PRD_BLK_plus_one may be used to construct another additional prediction block PRD_BLK_minus_one. Alternatively, if predModeIntra is the non-directional mode DC_MODE, PLANAR_MODE may be used to construct the additional prediction block PRD_BLK_plus_one, and the weighted sum of PRD_BLK_best and PRD_BLK_plus_one may be used to construct another additional prediction block PRD_BLK_minus_one. Alternatively, if predModeIntra is the direction mode ANGULAR_MODE, then ANGULAR_MODE may be used to construct the additional prediction block PRD_BLK_plus_one, and the weighted sum of PRD_BLK_best and PRD_BLK_plus_one may be used to construct another additional prediction block PRD_BLK_minus_one.
可通过使用当前块以及多个构建的预测块中的至少一个构建的预测块来获得多个差值块。例如,可构建当前块与使用所有的方向/非方向模式而构建的预测块之间的差值块。例如,可构建当前块与N+1个预测块之间的差值块,其中,所述N+1个预测块是使用predModeIntra和在角度或帧内预测模式方面与predModeIntra邻近的N个帧内预测模式被构建的。这里,N是等于或大于1的正整数。例如,如图59中所示,如果N=2,则如下可构建三个差值块。The plurality of difference blocks may be obtained by using a current block and a prediction block constructed using at least one of a plurality of constructed prediction blocks. For example, a difference block can be constructed between the current block and a prediction block constructed using all directional/non-directional modes. For example, a difference block between the current block and N+1 predicted blocks can be constructed using predModeIntra and N intras adjacent to predModeIntra in terms of angle or intra prediction mode. Predictive models are constructed. Here, N is a positive integer equal to or greater than 1. For example, as shown in Figure 59, if N=2, three difference blocks can be constructed as follows.
例如,可获得当前块与PRD_BLK_best之间的差值块RES_BLK_best。例如,可获得当前块与PRD_BLK_plus_one之间的差值块RES_BLK_plusone。例如,可获得当前块与PRD_BLK_minus_one之间的差值块RES_BLK_minusone。For example, the difference block RES_BLK_best between the current block and PRD_BLK_best can be obtained. For example, the difference block RES_BLK_plusone between the current block and PRD_BLK_plus_one can be obtained. For example, the difference block RES_BLK_minusone between the current block and PRD_BLK_minus_one can be obtained.
例如,可使用N个帧内预测模式来构建N个额外预测块,可通过对构建的N个预测块进行组合来构建M个额外预测块(M和N是正整数),然后可构建三个预测块与当前块之间的差值块。For example, N intra prediction modes may be used to construct N additional prediction blocks, M additional prediction blocks may be constructed by combining the constructed N prediction blocks (M and N are positive integers), and then three prediction blocks may be constructed The difference block between the block and the current block.
可执行针对搜索范围内的每个样点计算最佳帧内位移矢量(IDV)的操作。如图59中所示,IDV可被定义为从当前块的左上方样点位置到搜索范围内的样点位置的矢量(x,y)。An operation can be performed to calculate an optimal intraframe displacement vector (IDV) for each sample within the search range. As shown in Figure 59, the IDV may be defined as the vector (x, y) from the upper left sample position of the current block to the sample position within the search range.
对于每个IDV,可将由IDV所指示的样点位置用作(0,0)来构建具有与当前块相同大小的重建块REC_BLK。For each IDV, the sample position indicated by the IDV can be used as (0,0) to construct a reconstruction block REC_BLK with the same size as the current block.
可使用PRD_BLK_best以及多个额外构建的预测块中的至少一个额外构建的预测块,针对在由IDV所指示的位置处构建的重建块REC_BLK来构建一个或更多个残差信号块RES_BLK_IDV。One or more residual signal blocks RES_BLK_IDV may be constructed for the reconstruction block REC_BLK constructed at the position indicated by IDV using PRD_BLK_best and at least one additional constructed prediction block of a plurality of additional constructed prediction blocks.
例如,如果使用N个额外预测块,则可通过[等式30]针对在由IDV所指示的位置处构建的重建块REC_BLK来构建N+1个残差信号块。For example, if N additional prediction blocks are used, N+1 residual signal blocks may be constructed by [Equation 30] for the reconstruction block REC_BLK constructed at the position indicated by IDV.
[等式30][Equation 30]
RES_BLK_IDV_best=REC_BLK-PRD_BLK_bestRES_BLK_IDV_best=REC_BLK-PRD_BLK_best
RES_BLK_IDV_1=REC_BLK-PRD_BLK_1RES_BLK_IDV_1=REC_BLK-PRD_BLK_1
RES_BLK_IDV_2=REC_BLK-PRD_BLK_2RES_BLK_IDV_2=REC_BLK-PRD_BLK_2
……
RES_BLK_IDV_N=REC_BLK-PRD_BLK_NRES_BLK_IDV_N=REC_BLK-PRD_BLK_N
例如,如果如图59中所示使用两个额外预测块,则可通过[等式31]针对在由IDV所指示的位置处构建的重建块REC_BLK构建三个残差信号块。For example, if two additional prediction blocks are used as shown in FIG. 59, three residual signal blocks can be constructed by [Equation 31] for the reconstruction block REC_BLK constructed at the position indicated by IDV.
[等式31][Equation 31]
RES_BLK_IDV_best=REC_BLK-PRD_BLK_bestRES_BLK_IDV_best=REC_BLK-PRD_BLK_best
RES_BLK_IDV_plusone=REC_BLK-PRD_BLK_plus_oneRES_BLK_IDV_plusone=REC_BLK-PRD_BLK_plus_one
RES_BLK_IDV_minusone=REC_BLK-PRD_BLK_minus_oneRES_BLK_IDV_minusone=REC_BLK-PRD_BLK_minus_one
可构建与被应用于搜索范围内的在由每个IDV所指示的位置处的重建块的预测块的数量一样多的二阶残差块。Second-order residual blocks may be constructed as many as the number of prediction blocks applied to the reconstruction block at the position indicated by each IDV within the search range.
图60是描绘使用二阶残差信号块对残差信号进行预测的示图。Figure 60 is a diagram depicting prediction of a residual signal using a second-order residual signal block.
如图60中所示,可使用RES_BLK_’MODE’与RES_BLK_IDV_’MODE’之间的差值来获得二阶残差信号块RES_BLK_SEC。这里,“MODE”可以是预定帧内预测模式。As shown in Figure 60, the second-order residual signal block RES_BLK_SEC can be obtained using the difference between RES_BLK_’MODE’ and RES_BLK_IDV_’MODE’. Here, "MODE" may be a predetermined intra prediction mode.
例如,如果N个预测块被应用于重建块,则可通过[等式32]针对重建块RES_BLK构建N个二阶残差信号块。For example, if N prediction blocks are applied to the reconstruction block, N second-order residual signal blocks can be constructed for the reconstruction block RES_BLK by [Equation 32].
[等式32][Equation 32]
RES_BLK_SEC_1=RES_BLK_1-RES_BLK_IDV_1RES_BLK_SEC_1=RES_BLK_1-RES_BLK_IDV_1
RES_BLK_SEC_2=RES_BLK_2-RES_BLK_IDV_2RES_BLK_SEC_2=RES_BLK_2-RES_BLK_IDV_2
……
RES_BLK_SEC_N=RES_BLK_N-RES_BLK_IDV_NRES_BLK_SEC_N=RES_BLK_N-RES_BLK_IDV_N
例如,如图60中所示,如果使用通过利用predModeIntra而产生的预测块以及两个额外预测块,则可通过[等式33]针对重建块REC_BLK来构建三个二阶残差信号块。For example, as shown in FIG. 60 , if a prediction block generated by utilizing predModeIntra and two additional prediction blocks are used, three second-order residual signal blocks can be constructed for the reconstruction block REC_BLK by [Equation 33].
[等式33][Equation 33]
RES_BLK_SEC_best=RES_BLK_best-RES_BLK_IDV_bestRES_BLK_SEC_best=RES_BLK_best-RES_BLK_IDV_best
RES_BLK_SEC_plusone=RES_BLK_plusone-RES_BLK_IDV_plusoneRES_BLK_SEC_plusone=RES_BLK_plusone-RES_BLK_IDV_plusone
RES_BLK_SEC_minusone=RES_BLK_minusone-RES_BLK_IDV_minusoneRES_BLK_SEC_minusone=RES_BLK_minusone-RES_BLK_IDV_minusone
可通过将RES_BLK_best的代价函数值与残差信号块的代价函数值进行比较来确定是否针对在搜索范围内的由每个IDV所指示的位置处的重建块执行残差信号预测,其中,所述残差信号块根据率失真优化在多个二阶残差信号块RES_BLK_SEC之中是最小的。可用例如指示符SRP_flag(二阶残差预测)来指示是否执行残差信号预测。例如,如果残差信号预测被执行,则第一值可被分配给SRP_flag,如果残差信号预测不被执行,则第二值可被分配给SRP_flag。第一值可以是1,第二值可以是0。Whether to perform residual signal prediction for the reconstruction block at the position indicated by each IDV within the search range may be determined by comparing the cost function value of RES_BLK_best with the cost function value of the residual signal block, where The residual signal block is the smallest among the plurality of second-order residual signal blocks RES_BLK_SEC according to rate-distortion optimization. Whether to perform residual signal prediction may be indicated using, for example, an indicator SRP_flag (second-order residual prediction). For example, if residual signal prediction is performed, a first value may be assigned to SRP_flag, and if residual signal prediction is not performed, a second value may be assigned to SRP_flag. The first value can be 1 and the second value can be 0.
例如,如果二阶残差信号块的代价函数值之中的最小值小于从RES_BLK_best产生的代价函数值,则第一值可被分配给SRP_flag。此外,SRP_flag、IDV、被用于产生具有最小代价函数值的二阶残差信号块的帧内预测模式、以及RES_BLK_SEC的二阶残差信号中的至少一个可被编码在比特流中或者从比特流解码。For example, if the minimum value among the cost function values of the second-order residual signal block is smaller than the cost function value generated from RES_BLK_best, the first value may be assigned to the SRP_flag. In addition, at least one of SRP_flag, IDV, an intra prediction mode used to generate a second-order residual signal block with a minimum cost function value, and the second-order residual signal of RES_BLK_SEC may be encoded in the bit stream or derived from the bit stream. Stream decoding.
例如,如果二阶残差信号块的代价函数值中的最小值等于或大于从RES_BLK_best产生的代价函数值,则第二值可被分配给SRP_flag。此外,RES_BLK_best的残差信号、SRP_flag以及predModeIntra中的至少一个可被编码在比特流中或者从比特流解码。For example, if the minimum value among the cost function values of the second-order residual signal block is equal to or greater than the cost function value generated from RES_BLK_best, the second value may be assigned to the SRP_flag. Furthermore, at least one of the residual signal of RES_BLK_best, SRP_flag, and predModeIntra may be encoded in or decoded from the bitstream.
由于针对指示搜索范围内的所有样点的所有IDV重复执行以上操作,可确定所有的指示具有比RES_BLK_best的代价函数值小的代价函数值的二阶残差信号块的IDV。可从确定的所有IDV中最终选择具有最小代价函数值的IDV。Since the above operation is repeatedly performed for all IDVs indicating all samples within the search range, all IDVs indicating second-order residual signal blocks having a smaller cost function value than the cost function value of RES_BLK_best can be determined. The IDV with the smallest cost function value can be finally selected from all the determined IDVs.
图61是描绘残差信号预测的实施例的示图。Figure 61 is a diagram depicting an embodiment of residual signal prediction.
CUR_BLK表示进行编码/解码的当前块。RES_BLK可以是一阶残差信号,表示当前块的预测块与CUR_BLK之间的残差信号块。该预测块可以是在编码器/解码器中针对当前块构建的多个预测块之一。CUR_BLK represents the current block being encoded/decoded. RES_BLK may be a first-order residual signal, representing the residual signal block between the prediction block of the current block and CUR_BLK. The prediction block may be one of multiple prediction blocks constructed in the encoder/decoder for the current block.
IDV_REC_BLK表示从IDV构建的重建块。RES_BLK_IDV表示当前块的预测块与IDV_REC_BLK之间的残差信号块。该预测块可以是在编码器/解码器中针对当前块构建的多个预测块之一。IDV_REC_BLK represents the reconstruction block built from IDV. RES_BLK_IDV represents the residual signal block between the prediction block of the current block and IDV_REC_BLK. The prediction block may be one of multiple prediction blocks constructed in the encoder/decoder for the current block.
RES_BLK_SEC表示RES_BLK与RES_BLK_IDV之间的二阶残差信号块。RES_BLK_SEC represents the second-order residual signal block between RES_BLK and RES_BLK_IDV.
在图61中,如果RES_BLK的代价函数值小于RES_BLK_SEC的代价函数值,则第一值可被分配给SRP_flag。此外,SRP_flag、IDV、用于产生具有最小代价函数值的二阶残差信号块的帧内预测模式、以及RES_BLK_SEC的二阶残差信号中的至少一个可被编码在比特流中或从比特流解码。第一值可以是0或1。In FIG. 61, if the cost function value of RES_BLK is smaller than the cost function value of RES_BLK_SEC, the first value may be assigned to SRP_flag. Furthermore, at least one of SRP_flag, IDV, intra prediction mode for generating a second-order residual signal block with a minimum cost function value, and the second-order residual signal of RES_BLK_SEC may be encoded in or from the bitstream decoding. The first value can be 0 or 1.
在图61中,如果RES_BLK的代价函数值等于或大于RES_BLK_SEC的代价函数值,则第二值可被分配给SRP_flag。此外,RES_BLK的一阶残差信号、SRP_flag、以及predModeIntra中的至少一个可被编码在比特流中或从比特流解码。第二值可以是0或1。In FIG. 61, if the cost function value of RES_BLK is equal to or greater than the cost function value of RES_BLK_SEC, the second value may be assigned to SRP_flag. Furthermore, at least one of the first-order residual signal of RES_BLK, SRP_flag, and predModeIntra may be encoded in or decoded from the bitstream. The second value can be 0 or 1.
可使用第一残差信号和第二残差信号中的至少一个来推导当前块的残差信号。邻近块IDV_REC_BLK可以是由上述IDV所指示的块,并且可以与当前块邻近(例如,在当前块之前被重建的块,诸如在当前块左侧的块和上方的块)。IDV可按原样被编码,或者可通过对IDV与当前画面中的另一块的IDV之间的差进行编码而被编码。RES_BLK_IDV可被推导为通过从重建邻近块减去预定的预测块而获得的值。这里,产生该预测块所使用的帧内预测模式可以是邻近块IDV_REC_BLK或当前块的帧内预测模式,或者可以是编码器/解码器中的预设模式。或者,预定的预测块可被设置为与用于当前块的预测块相同。或者,包括当前块的上层块可被定义,并且由属于上层块的块所共享的残差信号可被定义为第二残差信号。可基于预定标志SRP_flag来选择性地执行基于上述第二残差信号的残差预测技术。可通过序列、画面、条带和块中的至少一个用信号传送该标志。或者,如果该标志是常量,则该标志可根据当前块的大小、形状和/或深度被推导为在编码器/解码器中预设的固定值。At least one of the first residual signal and the second residual signal may be used to derive the residual signal of the current block. The adjacent block IDV_REC_BLK may be a block indicated by the above-mentioned IDV, and may be adjacent to the current block (for example, a block reconstructed before the current block, such as a block to the left and a block above the current block). The IDV may be encoded as it is, or may be encoded by encoding the difference between the IDV and the IDV of another block in the current picture. RES_BLK_IDV can be derived as a value obtained by subtracting a predetermined prediction block from a reconstructed neighboring block. Here, the intra prediction mode used to generate the prediction block may be the intra prediction mode of the neighboring block IDV_REC_BLK or the current block, or may be a preset mode in the encoder/decoder. Alternatively, the predetermined prediction block may be set to be the same as the prediction block used for the current block. Alternatively, an upper layer block including the current block may be defined, and a residual signal shared by blocks belonging to the upper layer block may be defined as a second residual signal. The residual prediction technique based on the above-mentioned second residual signal may be selectively performed based on the predetermined flag SRP_flag. The flag may be signaled through at least one of a sequence, a picture, a slice, and a block. Alternatively, if the flag is a constant, the flag may be derived as a fixed value preset in the encoder/decoder based on the size, shape and/or depth of the current block.
指示是否针对当前块执行残差信号预测的指示符(标志)可被编码/解码。例如,该指示符可以是SRP_flag,并且可按照当前块或每个子块中的至少一个被编码/解码。An indicator (flag) indicating whether to perform residual signal prediction for the current block may be encoded/decoded. For example, the indicator may be SRP_flag, and may be encoded/decoded according to at least one of the current block or each sub-block.
IDV、针对当前块的残差信号预测所选择的帧内预测模式(图61中的mode_x)、以及作为残差信号预测所需的信息其它编码参数信息中的至少一个可被编码在比特流中或从比特流解码。At least one of the IDV, the intra prediction mode selected for residual signal prediction of the current block (mode_x in FIG. 61 ), and other coding parameter information as information required for residual signal prediction may be encoded in the bitstream. Or decode from bitstream.
可使用邻近块的IDV对当前块的IDV信息进行预测编码/解码。例如,可对当前块的IDV与邻近块的IDV的最小值、最大值、中值、平均值、最频繁值、或加权和之间的差进行编码/解码。The IDV information of the current block may be predictively encoded/decoded using the IDVs of neighboring blocks. For example, the difference between the IDV of the current block and the minimum value, the maximum value, the median value, the average value, the most frequent value, or the weighted sum of the IDVs of neighboring blocks may be encoded/decoded.
或者,如果邻近块的IDV中的至少一个与当前块的IDV相同,则编码器可按照预定义方法使用邻近块的IDV制作并使用IDV列表。编码器可将指示邻近块的IDV中的至少一个与当前块的IDV相同的信息(例如,标志)、和/或指示IDV列表中的相同IDV的信息(例如,索引)编码为当前块的IDV信息。如果标志信息指示邻近块的IDV中的至少一个与当前块的IDV相同,则解码器可根据预定义方法制作IDV列表。解码器可使用制作的IDV列表和索引信息来推导当前块的IDV。Alternatively, if at least one of the IDVs of neighboring blocks is the same as the IDV of the current block, the encoder may make and use an IDV list using the IDVs of neighboring blocks according to a predefined method. The encoder may encode information (eg, a flag) indicating that at least one of the IDVs of neighboring blocks is the same as the IDV of the current block, and/or information (eg, an index) indicating the same IDV in the IDV list as the IDV of the current block. information. If the flag information indicates that at least one of the IDVs of neighboring blocks is the same as the IDV of the current block, the decoder may make an IDV list according to a predefined method. The decoder can use the crafted IDV list and index information to derive the IDV of the current block.
图62a和图62b是描绘在编码器中执行残差信号预测的实施例的示图。Figures 62a and 62b are diagrams depicting embodiments of performing residual signal prediction in an encoder.
可针对当前块执行帧内预测(S6201),并且可确定最佳帧内预测模式predModeIntra(S6202)。在步骤S6202,可使用最佳帧内预测模式来产生预测块PRD_BLK_best。可获得在使用predModeIntra而产生的预测块PRD_BLK_best与当前块之间的残差块RES_BLK_bset(S6203)。Intra prediction may be performed for the current block (S6201), and the optimal intra prediction mode predModeIntra may be determined (S6202). In step S6202, the best intra prediction mode may be used to generate the prediction block PRD_BLK_best. The residual block RES_BLK_bset between the prediction block PRD_BLK_best generated using predModeIntra and the current block can be obtained (S6203).
可基于在步骤S6202确定的predModeIntra来确定N个额外帧内预测模式(S6204)。在步骤S6205,可从包括predModeIntra和N个额外帧内预测模式的N+1个帧内预测模式产生N+1个预测块PRD_BLK_'mode'。在步骤S6206,可使用当前块和N+1个预测块PRD_BLK_'mode'来获得N+1个残差块RES_BLK_'mode'。N additional intra prediction modes may be determined based on predModeIntra determined at step S6202 (S6204). In step S6205, N+1 prediction blocks PRD_BLK_'mode' may be generated from N+1 intra prediction modes including predModeIntra and N additional intra prediction modes. In step S6206, N+1 residual blocks RES_BLK_'mode' may be obtained using the current block and N+1 prediction blocks PRD_BLK_'mode'.
在步骤S6207,可使用逐像素搜索或预定搜索方法在搜索范围内移动并确定IDV。可在确定的IDV位置处获得重建块REC_BLK_IDV(S6208)。在步骤S6209,可使用REC_BLK_IDV和N+1个预测块PRD_BLK_'mode'来获得N+1个IDV残差块RES_BLK_IDV_'mode'。In step S6207, a pixel-by-pixel search or a predetermined search method may be used to move within the search range and determine the IDV. The reconstruction block REC_BLK_IDV may be obtained at the determined IDV position (S6208). In step S6209, N+1 IDV residual blocks RES_BLK_IDV_'mode' may be obtained using REC_BLK_IDV and N+1 prediction blocks PRD_BLK_'mode'.
在步骤S6210,可使用RES_BLK_'mode'和与RES_BLK_'mode'相应的RES_BLK_IDV_'mode'来获得N+1个二阶残差块RES_BLK_SEC_'mode'。In step S6210, N+1 second-order residual blocks RES_BLK_SEC_'mode' may be obtained using RES_BLK_'mode' and RES_BLK_IDV_'mode' corresponding to RES_BLK_'mode'.
在步骤S6211,可将每个块RES_BLK_SEC_'mode'的RD代价与RES_BLK_best的RD代价进行比较。如果至少一个块RES_BLK_SEC_'mode'的RD代价小于RES_BLK_best的RD代价(在S6211中为是),则该过程可进行到步骤S6212。否则(步骤S6211中为否),该过程可进行到步骤S6213。In step S6211, the RD cost of each block RES_BLK_SEC_'mode' may be compared with the RD cost of RES_BLK_best. If the RD cost of at least one block RES_BLK_SEC_'mode' is less than the RD cost of RES_BLK_best (Yes in S6211), the process may proceed to step S6212. Otherwise (No in step S6211), the process may proceed to step S6213.
在步骤S6212,第一值(例如1)可被分配给SRP_flag,并且最佳代价可被确定为所述至少一个块RES_BLK_SEC_'mode'的RD代价。In step S6212, a first value (eg, 1) may be assigned to SRP_flag, and the optimal cost may be determined as the RD cost of the at least one block RES_BLK_SEC_'mode'.
在步骤S6213,可确定当前IDV是否是搜索范围内的最后IDV。如果当前IDV不是最后IDV(在步骤S6213中为否),则该过程进行到步骤S6207,并且可针对下一个IDV重复以上操作。如果当前IDV是最后IDV(在步骤S6213中为是),则该过程可进行到步骤S6214。In step S6213, it may be determined whether the current IDV is the last IDV within the search range. If the current IDV is not the last IDV (No in step S6213), the process proceeds to step S6207, and the above operation may be repeated for the next IDV. If the current IDV is the last IDV (Yes in step S6213), the process may proceed to step S6214.
在步骤S6214,可确定SRP_flag是否是第一值(例如,1)。如果SRP_flag是第一值(在S6214中为是),则该过程可进行到步骤S6215。如果SRP_flag不是第一值(在S6214中为否),则该过程可进行到步骤S6216。In step S6214, it may be determined whether SRP_flag is a first value (eg, 1). If SRP_flag is the first value (Yes in S6214), the process may proceed to step S6215. If SRP_flag is not the first value (NO in S6214), the process may proceed to step S6216.
SRP_flag、IDV、用于产生具有最小代价函数值的二阶残差信号块的帧内预测模式(在PRED_BLK_'mode'中使用的'mode')和RES_BLK_SEC_'mode'的二阶残差信号中的至少一个可在步骤S6215被确定为编码目标,并在步骤S6217被编码。SRP_flag, IDV, intra prediction mode ('mode' used in PRED_BLK_'mode') used to generate a second-order residual signal block with a minimum cost function value and RES_BLK_SEC_'mode' in the second-order residual signal At least one may be determined as an encoding target in step S6215 and encoded in step S6217.
RES_BLK的一阶残差信号(例如,RES_BLK_best)、SRP_flag、以及predModeIntra中的至少一个可在步骤S6216被确定为编码目标,并在步骤S6217被编码。At least one of the first-order residual signal of RES_BLK (eg, RES_BLK_best), SRP_flag, and predModeIntra may be determined as an encoding target in step S6216 and encoded in step S6217.
如果IDV不被用信号传送,则解码器可通过按照相同的方式执行编码器的搜索过程来推导IDV。If the IDV is not signaled, the decoder can derive the IDV by performing the encoder's search process in the same way.
图63是描绘在解码器中执行残差信号预测的实施例的示图。Figure 63 is a diagram depicting an embodiment of performing residual signal prediction in a decoder.
在步骤S6301,可对比特流中包括的相关信息进行解码。In step S6301, related information included in the bit stream may be decoded.
如果SRP_flag不是第一值(例如,1)(在S6302中为否),则可执行步骤S6303。If SRP_flag is not the first value (eg, 1) (NO in S6302), step S6303 may be performed.
在步骤S6303,可产生与predModeIntra相应的预测块PRD_BLK_best。另外,可对残差块RES_BLK_best进行解码。In step S6303, the prediction block PRD_BLK_best corresponding to predModeIntra may be generated. Additionally, the residual block RES_BLK_best may be decoded.
在步骤S6304,可使用PRD_BLK_best和RES_BLK_best来产生重建块。In step S6304, PRD_BLK_best and RES_BLK_best may be used to generate a reconstruction block.
如果SRP_flag是第一值(例如,1)(在S6302中为是),则可执行步骤S6305、S6306和S6307。If SRP_flag is the first value (eg, 1) (Yes in S6302), steps S6305, S6306, and S6307 may be performed.
在步骤S6305,可对二阶残差块RES_BLK_SEC_'mode'进行解码。In step S6305, the second-order residual block RES_BLK_SEC_'mode' may be decoded.
在步骤S6306,可产生与解码的IDV相应的重建块REC_BLK_IDV。In step S6306, a reconstruction block REC_BLK_IDV corresponding to the decoded IDV may be generated.
在步骤S6307,可产生与解码的'mode'相应的预测块PRD_BLK_'mode'。In step S6307, the prediction block PRD_BLK_'mode' corresponding to the decoded 'mode' may be generated.
在步骤S6308,可使用产生的REC_BLK_IDV和PRD_BLK_'mode'来产生IDV残差块RES_BLK_IDV_'mode'。In step S6308, the IDV residual block RES_BLK_IDV_'mode' may be generated using the generated REC_BLK_IDV and PRD_BLK_'mode'.
在步骤S6309,可使用产生的RES_BLK_SEC_'mode'以及RES_BLK_IDV_'mode'来产生残差块RES_BLK。In step S6309, the residual block RES_BLK may be generated using the generated RES_BLK_SEC_'mode' and RES_BLK_IDV_'mode'.
在步骤S6310,可使用产生的RES_BLK和PRD_BLK_'mode'来产生重建块。In step S6310, the generated RES_BLK and PRD_BLK_'mode' may be used to generate a reconstruction block.
如上所述,如果IDV未被用信号传送,则解码器可通过按照相同的方式执行编码器的搜索操作来推导IDV。As mentioned above, if the IDV is not signaled, the decoder can derive the IDV by performing the encoder's search operation in the same manner.
可针对亮度信号和色度信号中的每一个执行帧内编码/解码处理。例如,在帧内编码/解码处理中,可针对亮度信号和色度信号不同地应用推导帧内预测模式、对块进行划分、构建参考样点以及执行帧内预测的至少一种方法。Intra-frame encoding/decoding processing may be performed for each of the luminance signal and the chrominance signal. For example, in the intra encoding/decoding process, at least one method of deriving an intra prediction mode, partitioning blocks, constructing reference samples, and performing intra prediction may be applied differently for luma signals and chrominance signals.
可针对亮度信号和色度信号同等地执行帧内编码/解码处理。例如,在针对亮度信号应用帧内编码/解码处理时,可对色度信号同等地应用推导帧内预测模式、对块进行划分、构建参考样点以及执行帧内预测中的至少一个。Intra-frame encoding/decoding processing can be performed equally for luminance signals and chrominance signals. For example, when applying intra encoding/decoding processes to luma signals, at least one of deriving intra prediction modes, partitioning blocks, constructing reference samples, and performing intra prediction may be applied equally to chrominance signals.
可按照相同的方式在编码器和解码器中执行所述方法。例如,在帧内编码/解码处理中,可在编码器和解码器中同等地应用推导帧内预测模式、对块进行划分、构建参考样点以及执行帧内预测的至少一种方法。另外,应用方法的顺序可在编码器和解码器中不同。例如,在针对当前块执行帧内编码/解码时,编码器可对通过在构建参考样点之后执行至少一种帧内预测而确定的帧内预测模式进行编码。The method can be performed in the same way in the encoder and decoder. For example, in the intra encoding/decoding process, at least one method of deriving intra prediction modes, partitioning blocks, constructing reference samples, and performing intra prediction may be applied equally in the encoder and decoder. Additionally, the order in which methods are applied can differ between encoders and decoders. For example, when performing intra encoding/decoding for the current block, the encoder may encode an intra prediction mode determined by performing at least one intra prediction after constructing the reference samples.
本发明的实施例可根据编码块、预测块、块和单元中的至少一个的大小而被应用。这里,所述大小可被定义为最小大小和/或最大大小以便应用实施例,并且可被定义为应用了实施例的固定大小。此外,第一实施例可按照第一大小被应用,第二实施例可按照第二大小被应用。也就是说,实施例可根据所述大小而被多次应用。此外,本发明的实施例可仅在大小等于或大于最小大小并且等于或小于最大大小时被应用。也就是说,实施例可仅在块大小在预定范围中时被应用。Embodiments of the present invention may be applied according to the size of at least one of a coding block, a prediction block, a block and a unit. Here, the size may be defined as a minimum size and/or a maximum size in order to apply the embodiment, and may be defined as a fixed size to which the embodiment is applied. Furthermore, the first embodiment can be applied in a first size, and the second embodiment can be applied in a second size. That is, embodiments may be applied multiple times depending on the size. Furthermore, embodiments of the present invention may be applied only when the size is equal to or greater than the minimum size and equal to or less than the maximum size. That is, embodiments may be applied only when the block size is within a predetermined range.
例如,仅当编码/解码目标块的大小等于或大于8×8时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或大于16×16时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或大于32×32时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或大于64×64时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或大于128×128时,实施例才可被应用。例如,仅当编码/解码目标块的大小为4×4时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或小于8×8时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或大于16×16时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或大于8×8且等于或小于16×16时,实施例才可被应用。例如,仅当编码/解码目标块的大小等于或大于16×16且等于或小于64×64时,实施例才可被应用。For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or larger than 8×8. For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or larger than 16×16. For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or larger than 32×32. For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or larger than 64×64. For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or larger than 128×128. For example, the embodiment can be applied only when the size of the encoding/decoding target block is 4×4. For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or smaller than 8×8. For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or larger than 16×16. For example, the embodiment is applicable only when the size of the encoding/decoding target block is equal to or larger than 8×8 and equal to or smaller than 16×16. For example, the embodiment may be applied only when the size of the encoding/decoding target block is equal to or larger than 16×16 and equal to or smaller than 64×64.
本发明的实施例可根据时间层而被应用。用于标识可被应用实施例的时间层的标识符可用信号传送,并且可针对由所述指示符指明的时间层应用实施例。这里,所述标识符可被定义为指示可被应用实施例的最小层和/或最大层,并且可被定义为指示可被应用实施例的特定层。Embodiments of the present invention may be applied according to time strata. An identifier identifying a time layer to which an embodiment may be applied may be signaled, and the embodiment may be applied for the time layer indicated by the indicator. Here, the identifier may be defined to indicate a minimum layer and/or a maximum layer to which the embodiment may be applied, and may be defined to indicate a specific layer to which the embodiment may be applied.
例如,仅在当前画面的时间层为最底层时,实施例才可被应用。例如,仅在当前画面的时间层标识符为0时,实施例才可被应用。例如,仅在当前画面的时间层标识符等于或大于1时,实施例才可被应用。例如,仅在当前画面的时间层为最高层时,实施例才可被应用。For example, the embodiment can be applied only when the temporal layer of the current picture is the lowest layer. For example, the embodiment may be applied only when the temporal layer identifier of the current picture is 0. For example, the embodiment may be applied only when the temporal layer identifier of the current picture is equal to or greater than 1. For example, the embodiment may be applied only when the temporal layer of the current picture is the highest layer.
如在本发明的实施例中所描述的,在参考画面列表构建和参考画面列表修改的处理中使用的参考画面集可使用参考画面列表L0、L1、L2和L3中的至少一个。As described in the embodiments of the present invention, the reference picture set used in the processes of reference picture list construction and reference picture list modification may use at least one of the reference picture lists L0, L1, L2, and L3.
根据本发明的实施例,当去块滤波器计算边界强度时,可使用编码/解码目标块的至少一个至最多N个运动矢量。这里,N指示等于或大于1的正整数,诸如2、3、4等。According to an embodiment of the present invention, when the deblocking filter calculates the boundary strength, at least one and up to N motion vectors of the encoding/decoding target block may be used. Here, N indicates a positive integer equal to or greater than 1, such as 2, 3, 4, etc.
在运动矢量预测中,当运动矢量具有以下单元中的至少一个时,可应用本发明的实施例:16-像素(16-pel)单元、8-像素(8-pel)单元、4-像素(4-pel)单元、整数-像素(整数-pel)单元、1/2-像素(1/2-pel)单元、1/4-像素(1/4-pel)单元、1/8-像素(1/8-pel)单元、1/16-像素(1/16-pel)单元、1/32-像素(1/32-pel)单元以及1/64-像素(1/64-pel)单元。此外,在执行运动矢量预测时,可针对每个像素单元可选地使用运动矢量。In motion vector prediction, embodiments of the present invention may be applied when the motion vector has at least one of the following units: 16-pixel (16-pel) unit, 8-pixel (8-pel) unit, 4-pixel ( 4-pel) unit, integer-pixel (integer-pel) unit, 1/2-pixel (1/2-pel) unit, 1/4-pixel (1/4-pel) unit, 1/8-pixel ( 1/8-pel) unit, 1/16-pixel (1/16-pel) unit, 1/32-pixel (1/32-pel) unit, and 1/64-pixel (1/64-pel) unit. Furthermore, when performing motion vector prediction, motion vectors may optionally be used for each pixel unit.
可定义应用本发明的实施例的条带类型并且可根据条带类型应用本发明的实施例。A strip type to which embodiments of the present invention are applied may be defined and embodiments of the present invention may be applied according to the strip type.
例如,当条带类型是T(三向预测)-条带时,预测块可通过使用至少三个运动矢量来产生,并且可通过计算至少三个预测块的加权和而被用作编码/解码目标块的最终预测块。例如,当条带类型是Q(四向预测)-条带时,预测块可通过使用至少四个运动矢量来产生,并且可通过计算至少四个预测块的加权和而被用作编码/解码目标块的最终预测块。For example, when the slice type is a T (tri-directional prediction)-slice, a prediction block may be generated by using at least three motion vectors, and may be used for encoding/decoding by calculating a weighted sum of at least three prediction blocks The final predicted block of the target block. For example, when the slice type is a Q (Quad prediction)-slice, a prediction block may be generated by using at least four motion vectors, and may be used for encoding/decoding by calculating a weighted sum of at least four prediction blocks The final predicted block of the target block.
本发明的实施例可被应用于使用运动矢量预测的帧间预测和运动补偿方法以及使用跳过模式、合并模式等的帧间预测和运动补偿方法。Embodiments of the present invention can be applied to inter prediction and motion compensation methods using motion vector prediction and inter prediction and motion compensation methods using skip mode, merge mode, and the like.
应用了本发明的实施例的块的形状可具有正方形或非正方形。The shape of the blocks to which embodiments of the present invention are applied may have square or non-square shapes.
在上述实施例中,基于具有一系列步骤或单元的流程图描述了所述方法,但本发明不限于所述步骤的顺序,而是,一些步骤可与其它步骤被同时执行,或者可与其它步骤按照不同顺序被执行。此外,本领域普通技术人员应该理解,流程图中的步骤不彼此相斥,并且在不影响本发明的范围的情况下,其它步骤可被添加到流程图中,或者一些步骤可从流程图被删除。In the above embodiments, the method is described based on a flow chart having a series of steps or units, but the present invention is not limited to the order of the steps, but some steps may be performed simultaneously with other steps, or may be performed with other steps. Steps are performed in different orders. Furthermore, those of ordinary skill in the art will understand that the steps in the flowcharts are not mutually exclusive and that other steps may be added to the flowcharts or some steps may be removed from the flowcharts without affecting the scope of the present invention. delete.
实施例包括示例的各种方面。针对各个方面的所有可能组合可不被描述,但本领域技术人员将能够认识到不同组合。因此,本发明可包括权利要求范围内的所有替换形式、修改形式和改变。The embodiments include various aspects of the examples. Not all possible combinations of the various aspects may be described, but those skilled in the art will be able to recognize the different combinations. Accordingly, the present invention may include all alternatives, modifications, and changes within the scope of the claims.
本发明的实施例可按照程序指令的形式来实施,其中,所述程序指令可由各种计算机组件来执行,并被记录在计算机可读记录介质上。计算机可读记录介质可包括单独的程序指令、数据文件、数据结构等,或者是程序指令、数据文件、数据结构等的组合。记录在计算机可读记录介质中的程序指令可被特别设计和构造用于本发明,或者对于计算机软件技术领域的普通技术人员而言是已知的。计算机可读记录介质的示例包括:磁记录介质(诸如硬盘、软盘和磁带);光学数据存储介质(诸如CD-ROM或DVD-ROM);磁光介质(诸如软光盘);以及被特别构造用于存储和实施程序指令的硬件装置(诸如只读存储器(ROM)、随机存取存储器(RAM)、闪存存储器等)。程序指令的示例不仅包括由编译器形成的机器语言代码,还包括可由计算机使用解释器实施的高级语言代码。硬件装置可被配置为由一个或更多个软件模块操作以进行根据本发明的处理,反之亦可。Embodiments of the present invention may be implemented in the form of program instructions, which may be executed by various computer components and recorded on a computer-readable recording medium. The computer-readable recording medium may include individual program instructions, data files, data structures, etc., or combinations of program instructions, data files, data structures, etc. The program instructions recorded in the computer-readable recording medium may be specially designed and constructed for use in the present invention, or may be known to those of ordinary skill in the field of computer software technology. Examples of computer-readable recording media include: magnetic recording media (such as hard disks, floppy disks, and magnetic tapes); optical data storage media (such as CD-ROM or DVD-ROM); magneto-optical media (such as soft optical disks); Hardware devices (such as read-only memory (ROM), random access memory (RAM), flash memory, etc.) for storing and executing program instructions. Examples of program instructions include not only machine language code formed by a compiler, but also high-level language code that can be implemented by a computer using an interpreter. A hardware device may be configured to be operated by one or more software modules to perform processing according to the invention, and vice versa.
虽然已根据特定术语(诸如详细元件)以及有限实施例和附图描述了本发明,但它们仅被提供用于帮助更通俗地理解本发明,本发明不限于上述实施例。本发明所属领域的技术人员将理解,可从以上描述做出各种修改和改变。Although the present invention has been described in terms of specific terms, such as detailed elements, and limited embodiments and drawings, they are provided only to facilitate a more general understanding of the present invention, and the present invention is not limited to the above-described embodiments. It will be understood by those skilled in the art that various modifications and changes can be made from the above description.
因此,本发明的精神不应受限于上述实施例,所附权利要求及其等同物的全部范围将落入本发明的范围和精神之内。Therefore, the spirit of the present invention should not be limited to the above-described embodiments, but the full scope of the appended claims and their equivalents will fall within the scope and spirit of the present invention.
工业可用性Industrial availability
本发明可在对图像进行编码/解码时被使用。The present invention can be used when encoding/decoding images.
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202311313785.3ACN117201809A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN202311311003.2ACN117201808A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN202311310805.1ACN117201807A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| KR10-2016-0098094 | 2016-08-01 | ||
| KR20160098094 | 2016-08-01 | ||
| KR10-2017-0000206 | 2017-01-02 | ||
| KR20170000206 | 2017-01-02 | ||
| PCT/KR2017/008221WO2018026148A1 (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and device, and recording medium storing bitstream |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202311313785.3ADivisionCN117201809A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN202311310805.1ADivisionCN117201807A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN202311311003.2ADivisionCN117201808A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| Publication Number | Publication Date |
|---|---|
| CN109792515A CN109792515A (en) | 2019-05-21 |
| CN109792515Btrue CN109792515B (en) | 2023-10-24 |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202311313785.3APendingCN117201809A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN201780061056.XAActiveCN109792515B (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN202311310805.1APendingCN117201807A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN202311311003.2APendingCN117201808A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202311313785.3APendingCN117201809A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202311310805.1APendingCN117201807A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| CN202311311003.2APendingCN117201808A (en) | 2016-08-01 | 2017-07-31 | Image encoding/decoding method and apparatus, and recording medium storing bit stream |
| Country | Link |
|---|---|
| KR (1) | KR102435675B1 (en) |
| CN (4) | CN117201809A (en) |
| WO (1) | WO2018026148A1 (en) |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN116866563A (en)* | 2018-03-21 | 2023-10-10 | Lx 半导体科技有限公司 | Image encoding/decoding method, storage medium, and image data transmission method |
| EP3562158A1 (en)* | 2018-04-27 | 2019-10-30 | InterDigital VC Holdings, Inc. | Method and apparatus for combined intra prediction modes |
| JP7137008B2 (en) | 2018-06-29 | 2022-09-13 | 北京字節跳動網絡技術有限公司 | The concept of using one or more lookup tables to sequentially store previously coded motion information and use them for coding subsequent blocks |
| CN114125450B (en) | 2018-06-29 | 2023-11-17 | 北京字节跳动网络技术有限公司 | Method, device and computer-readable medium for processing video data |
| EP4322533A3 (en) | 2018-06-29 | 2024-03-06 | Beijing Bytedance Network Technology Co., Ltd. | Checking order of motion candidates in lut |
| CN110166777B (en)* | 2018-07-04 | 2023-11-17 | 腾讯科技(深圳)有限公司 | Encoding method, apparatus and video data encoding device |
| KR20240017119A (en) | 2018-09-05 | 2024-02-06 | 엘지전자 주식회사 | Method for encoding/decoding video signal, and apparatus therefor |
| BR112021005161A2 (en) | 2018-09-21 | 2021-06-15 | Guangdong Oppo Mobile Telecommunications Corp., Ltd. | video decoding method, and video encoding method |
| CN109561316A (en)* | 2018-10-26 | 2019-04-02 | 西安科锐盛创新科技有限公司 | A kind of VR three dimensional image processing method |
| GB2580036B (en) | 2018-12-19 | 2023-02-01 | British Broadcasting Corp | Bitstream decoding |
| CN113261286B (en)* | 2018-12-28 | 2024-10-22 | 韩国电子通信研究院 | Method and apparatus for deriving intra prediction modes |
| KR102861087B1 (en)* | 2019-01-02 | 2025-09-16 | 광동 오포 모바일 텔레커뮤니케이션즈 코포레이션 리미티드 | Intra-frame prediction method and device, video encoding device, storage medium |
| WO2020143741A1 (en) | 2019-01-10 | 2020-07-16 | Beijing Bytedance Network Technology Co., Ltd. | Invoke of lut updating |
| CN113302937B (en)* | 2019-01-16 | 2024-08-02 | 北京字节跳动网络技术有限公司 | Motion Candidate Derivation |
| CN113615193B (en) | 2019-03-22 | 2024-06-25 | 北京字节跳动网络技术有限公司 | Interaction between Merge list construction and other tools |
| KR102470696B1 (en)* | 2019-04-16 | 2022-11-28 | 엘지전자 주식회사 | Transformation for matrix-based intra prediction in image coding |
| CN118118662A (en)* | 2019-04-16 | 2024-05-31 | Lg电子株式会社 | Image decoding method, image encoding method, transmitting method, and storage medium |
| WO2020244571A1 (en)* | 2019-06-04 | 2020-12-10 | Beijing Bytedance Network Technology Co., Ltd. | Motion candidate list construction using neighboring block information |
| KR20200145763A (en)* | 2019-06-22 | 2020-12-30 | 주식회사 엑스리스 | Method for encoding/decoidng video signal and apparatus therefor |
| EP4542995A3 (en) | 2019-06-24 | 2025-07-09 | LG Electronics Inc. | Image encoding/decoding method and apparatus using maximum transform size setting for chroma block, and method for transmitting bitstream |
| EP3886435A4 (en)* | 2019-06-25 | 2022-01-26 | Guangdong Oppo Mobile Telecommunications Corp., Ltd. | MAPPING PROCESSES, ENCODERS, DECODERS AND COMPUTER STORAGE MEDIUM |
| CN116668698A (en)* | 2019-07-05 | 2023-08-29 | Lg电子株式会社 | Image encoding/decoding method, image data transmitting method, and storage medium |
| CN119835448A (en)* | 2019-08-31 | 2025-04-15 | Lg 电子株式会社 | Video or image compiling method and device |
| CN117596389A (en) | 2019-09-28 | 2024-02-23 | 北京字节跳动网络技术有限公司 | Geometric partitioning modes in video coding and decoding |
| US12022094B2 (en)* | 2019-10-08 | 2024-06-25 | Lg Electronics Inc. | Transform-based image coding method and device for same |
| WO2021162723A1 (en)* | 2020-02-13 | 2021-08-19 | Google Llc | Intra prediction for image and video compression |
| CN115362676A (en) | 2020-03-07 | 2022-11-18 | 抖音视界有限公司 | Processing of transform skip mode in video coding and decoding |
| CN113422966B (en)* | 2021-05-27 | 2024-05-24 | 绍兴市北大信息技术科创中心 | Multi-model CNN loop filtering method |
| CN118511514A (en)* | 2021-11-08 | 2024-08-16 | 北京达佳互联信息技术有限公司 | Cross-component sample adaptive offset |
| EP4580186A1 (en)* | 2022-08-25 | 2025-07-02 | LG Electronics Inc. | Intra prediction mode-based image encoding/decoding method and apparatus using multi reference line (mrl), and recording medium for storing bitstream |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103096066A (en)* | 2011-11-04 | 2013-05-08 | 吴秀美 | Decoding device for video data |
| CN103200401A (en)* | 2012-01-06 | 2013-07-10 | 索尼公司 | Image processing device and image processing method |
| WO2013109066A1 (en)* | 2012-01-20 | 2013-07-25 | 주식회사 팬택 | Intra prediction mode mapping method and device using the method |
| JP2013150164A (en)* | 2012-01-19 | 2013-08-01 | Sony Corp | Encoding apparatus and encoding method, and decoding apparatus and decoding method |
| CN103636203A (en)* | 2011-06-17 | 2014-03-12 | 联发科技股份有限公司 | Method and apparatus for intra prediction mode coding |
| CN103891283A (en)* | 2011-12-05 | 2014-06-25 | Lg电子株式会社 | Method and device for intra prediction |
| CN104041048A (en)* | 2011-11-09 | 2014-09-10 | Sk电信有限公司 | Method And Apparatus Video Encoding And Decoding Using Skip Mode |
| JP2015008341A (en)* | 2011-10-31 | 2015-01-15 | 三菱電機株式会社 | Moving picture encoding apparatus, moving picture decoding apparatus, moving picture encoding method, and moving picture decoding method |
| CN104488270A (en)* | 2012-06-29 | 2015-04-01 | 韩国电子通信研究院 | Method and device for encoding/decoding images |
| CN105338345A (en)* | 2011-10-24 | 2016-02-17 | 英孚布瑞智有限私人贸易公司 | Method and apparatus for image decoding |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP5321439B2 (en)* | 2009-12-15 | 2013-10-23 | 株式会社Jvcケンウッド | Image encoding device, image decoding device, image encoding method, and image decoding method |
| US9762900B2 (en)* | 2011-06-17 | 2017-09-12 | Lg Electronics Inc. | Method and apparatus for encoding/decoding video in intra prediction mode |
| KR101348544B1 (en)* | 2011-08-17 | 2014-01-10 | 주식회사 케이티 | Methods of intra prediction on sdip and apparatuses for using the same |
| KR101827939B1 (en)* | 2011-12-13 | 2018-02-12 | 주식회사 스카이미디어테크 | Method of adaptive intra prediction mode encoding and apparatus for the same, and method of decoding and apparatus for the same |
| RU2510944C2 (en)* | 2012-07-03 | 2014-04-10 | Корпорация "САМСУНГ ЭЛЕКТРОНИКС Ко., Лтд." | Method of encoding/decoding multi-view video sequence based on adaptive local adjustment of brightness of key frames without transmitting additional parameters (versions) |
| GB2509901A (en)* | 2013-01-04 | 2014-07-23 | Canon Kk | Image coding methods based on suitability of base layer (BL) prediction data, and most probable prediction modes (MPMs) |
| US9247255B2 (en)* | 2013-02-28 | 2016-01-26 | Research & Business Foundation Sungkyunkwan University | Method and apparatus for image encoding/decoding |
| US9380305B2 (en)* | 2013-04-05 | 2016-06-28 | Qualcomm Incorporated | Generalized residual prediction in high-level syntax only SHVC and signaling and management thereof |
| US11470339B2 (en)* | 2013-08-27 | 2022-10-11 | Qualcomm Incorporated | Residual prediction for intra block copying |
| US10091511B2 (en)* | 2015-01-05 | 2018-10-02 | Getgo, Inc. | Efficient video block matching |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103636203A (en)* | 2011-06-17 | 2014-03-12 | 联发科技股份有限公司 | Method and apparatus for intra prediction mode coding |
| CN105338345A (en)* | 2011-10-24 | 2016-02-17 | 英孚布瑞智有限私人贸易公司 | Method and apparatus for image decoding |
| JP2015008341A (en)* | 2011-10-31 | 2015-01-15 | 三菱電機株式会社 | Moving picture encoding apparatus, moving picture decoding apparatus, moving picture encoding method, and moving picture decoding method |
| CN103096066A (en)* | 2011-11-04 | 2013-05-08 | 吴秀美 | Decoding device for video data |
| CN104041048A (en)* | 2011-11-09 | 2014-09-10 | Sk电信有限公司 | Method And Apparatus Video Encoding And Decoding Using Skip Mode |
| CN103891283A (en)* | 2011-12-05 | 2014-06-25 | Lg电子株式会社 | Method and device for intra prediction |
| CN103200401A (en)* | 2012-01-06 | 2013-07-10 | 索尼公司 | Image processing device and image processing method |
| JP2013150164A (en)* | 2012-01-19 | 2013-08-01 | Sony Corp | Encoding apparatus and encoding method, and decoding apparatus and decoding method |
| WO2013109066A1 (en)* | 2012-01-20 | 2013-07-25 | 주식회사 팬택 | Intra prediction mode mapping method and device using the method |
| CN104488270A (en)* | 2012-06-29 | 2015-04-01 | 韩国电子通信研究院 | Method and device for encoding/decoding images |
| Publication number | Publication date |
|---|---|
| CN117201808A (en) | 2023-12-08 |
| CN117201809A (en) | 2023-12-08 |
| WO2018026148A1 (en) | 2018-02-08 |
| KR20180014674A (en) | 2018-02-09 |
| CN117201807A (en) | 2023-12-08 |
| KR102435675B1 (en) | 2022-08-24 |
| CN109792515A (en) | 2019-05-21 |
| Publication | Publication Date | Title |
|---|---|---|
| CN109792515B (en) | Image encoding/decoding method and apparatus, and recording medium storing bit stream | |
| CN109417617B (en) | Intra-frame prediction method and device | |
| CN109479129B (en) | Image encoding/decoding method and device, and recording medium for storing bit stream | |
| CN110024386B (en) | Method and apparatus for encoding/decoding image, recording medium for storing bit stream | |
| CN111034196A (en) | Method and apparatus for encoding/decoding video and recording medium for storing bitstream | |
| CN111684801B (en) | Bidirectional intra-frame prediction method and device | |
| CN111919448A (en) | Method and apparatus for image encoding and image decoding using temporal motion information |
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |