Image encoding method, image decoding method and related device

By using the spatial correlation of adjacent coding blocks in the intra prediction mode of chroma component, the problems of inaccurate prediction and low encoding efficiency caused by ignoring spatial correlation in the prior art are solved, and more efficient video compression is achieved.

CN115002485BActive Publication Date: 2025-07-22GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210664095.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2020-06-05
Filing Date
2021-04-29
Publication Date
2025-07-22
Estimated Expiration
2041-04-29

AI Technical Summary

Technical Problem

In the chroma component intra prediction mode, the spatial correlation between the current encoding block and the adjacent encoding block is ignored, resulting in poor prediction accuracy and encoding efficiency.

Method used

By using the spatial correlation between adjacent coded blocks and the current coded block, the prediction sample of chroma component is corrected, including selecting upper or left adjacent pixels as reference pixels for prediction correction, improving prediction accuracy and coding efficiency.

Benefits of technology

It improves the prediction accuracy and encoding efficiency of chroma component, reduces information waste during the encoding process, and improves the video compression ratio.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115002485B_ABST
    Figure CN115002485B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose an image encoding method, an image decoding method, and related devices. The image decoding method includes: partitioning an image, and determining an intra prediction mode of a chrominance component of a current coding block; determining a prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component; and performing prediction correction on the prediction block of the chrominance component of the current coding block to obtain a corrected prediction block of the chrominance component of the current coding block. In the intra prediction mode of the chrominance component, embodiments of the present application utilize the spatial correlation between adjacent coding blocks and the current coding block to correct the prediction samples of the chrominance component of the current coding block, thereby improving the prediction accuracy and the coding efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of electronic devices, and in particular, to an image encoding method, an image decoding method, and related devices. Background Art

[0002] Digital video capabilities can be incorporated into a wide range of devices, including digital televisions, digital live systems, wireless broadcast systems, personal digital assistants (PDAs), laptop or desktop computers, tablet computers, e-book readers, digital cameras, digital recording devices, digital media players, video game devices, video game consoles, cellular or satellite radiotelephones, video conferencing devices, video streaming devices, and so on.

[0003] Digital video devices implement video compression technologies, such as those described in the standards defined by MPEG-2, MPEG-4, ITU-T H.263, ITU-T H.264 / MPEG-4 Part 10 Advanced Video Coding (AVC), ITU-T H.265 High Efficiency Video Coding (HEVC) standards, and the extended parts of these standards, so as to transmit and receive digital video information more efficiently. Video devices can transmit, receive, encode, decode, and / or store digital video information more efficiently by implementing these video coding and decoding technologies.

[0004] With the proliferation of Internet videos, although digital video compression technologies are constantly evolving, there are still higher requirements for the video compression ratio. Summary of the Invention

[0005] Embodiments of this application provide an image encoding method, an image decoding method, and related devices, in order to correct the prediction samples of the chrominance component of the current coding block by using the spatial correlation between adjacent coding blocks and the current coding block, and improve the prediction accuracy and coding efficiency.

[0006] In a first aspect, an embodiment of this application provides an image encoding method, including: dividing an image, and determining an intra prediction mode of the chrominance component of a current coding block; determining a prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component; and performing prediction correction on the prediction block of the chrominance component of the current coding block to obtain a corrected prediction block of the chrominance component of the current coding block.

[0007] Compared with the prior art, in the chrominance component intra prediction mode of the solution of the present application, the spatial correlation between adjacent coding blocks and the current coding block is used to correct the prediction samples of the chrominance component of the current coding block, thereby improving the prediction accuracy and coding efficiency.

[0008] In a second aspect, an embodiment of the present application provides an image decoding method, including: parsing a bitstream to determine the chrominance component intra prediction mode of a current decoding block; determining a prediction block of the chrominance component of the current decoding block according to the chrominance component intra prediction mode; and performing prediction correction on the prediction block of the chrominance component of the current decoding block to obtain a corrected prediction block of the chrominance component of the current decoding block.

[0009] Compared with the prior art, in the chrominance component intra prediction mode of the solution of the present application, the spatial correlation between adjacent coding blocks and the current coding block is used to correct the prediction samples of the chrominance component of the current coding block, thereby improving the prediction accuracy and decoding efficiency.

[0010] In a third aspect, an embodiment of the present application provides an image coding apparatus, including:

[0011] A partitioning unit, configured to partition an image and determine the chrominance component intra prediction mode of a current coding block;

[0012] A determination unit, configured to determine a prediction block of the chrominance component of the current coding block according to the chrominance component intra prediction mode;

[0013] A correction unit, configured to perform prediction correction on the prediction block of the chrominance component of the current coding block to obtain a corrected prediction block of the chrominance component of the current coding block.

[0014] In a fourth aspect, an embodiment of the present application provides an image decoding apparatus, including:

[0015] A parsing unit, configured to parse a bitstream and determine the chrominance component intra prediction mode of a current decoding block;

[0016] A determination unit, configured to determine a prediction block of the chrominance component of the current decoding block according to the chrominance component intra prediction mode;

[0017] A correction unit, configured to perform prediction correction on the prediction block of the chrominance component of the current decoding block to obtain a corrected prediction block of the chrominance component of the current decoding block.

[0018] In a fifth aspect, an embodiment of the present application provides an encoder, including: a processor and a memory coupled to the processor; the processor is configured to execute the method described in the first aspect above.

[0019] Sixth aspect, an embodiment of the present application provides a decoder, including: a processor and a memory coupled to the processor; the processor is configured to execute the method described in the second aspect above.

[0020] Seventh aspect, an embodiment of the present application provides a terminal, the terminal includes: one or more processors, a memory, and a communication interface; the memory and the communication interface are connected to the one or more processors; the terminal communicates with other devices through the communication interface, the memory is used to store computer program code, the computer program code includes instructions, and when the one or more processors execute the instructions, the terminal executes the method described in the first aspect or the second aspect.

[0021] Eighth aspect, an embodiment of the present application provides a computer-readable storage medium, in which instructions are stored, and when the instructions are run on a computer, the computer is caused to execute the method described in the first aspect or the second aspect above.

[0022] Ninth aspect, an embodiment of the present application provides a computer program product containing instructions, and when the instructions are run on a computer, the computer is caused to execute the method described in the first aspect or the second aspect above. Description of the Drawings

[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0024] Figure 1 It is a schematic block diagram of a coding tree unit in an embodiment of the present application;

[0025] Figure 2 It is a schematic block diagram of a color format in an embodiment of the present application;

[0026] Figure 3 It is a schematic block diagram of a CTU and a coding unit CU in an embodiment of the present application;

[0027] Figure 4 It is a schematic block diagram of associated pixels of a coding unit in an embodiment of the present application;

[0028] Figure 5A It is a schematic block diagram of an intra prediction mode of a luminance component in an embodiment of the present application;

[0029] Figure 5BSchematic diagram of the chrominance component intra prediction mode in the embodiments of the present application;

[0030] Figure 6 Schematic block diagram of adjacent pixels for calculating coefficients of a linear model in the embodiments of the present application;

[0031] Figure 7 Schematic block diagram of a downsampling filter in the embodiments of the present application;

[0032] Figure 8 Schematic block diagram of the change from the luminance component reconstruction block to the chrominance component prediction block in the embodiments of the present application;

[0033] Figure 9 Schematic block diagram of a video decoding system in the embodiments of the present application;

[0034] Figure 10 Schematic block diagram of a video encoder in the embodiments of the present application;

[0035] Figure 11 Schematic block diagram of a video decoder in the embodiments of the present application;

[0036] Figure 12A Schematic flow diagram of an image coding method in the embodiments of the present application;

[0037] Figure 12B Schematic diagram of a horizontal downsampling process in the embodiments of the present application;

[0038] Figure 12C Schematic diagram of a vertical downsampling process in the embodiments of the present application;

[0039] Figure 12D Schematic diagram of a bi - directional downsampling process in the embodiments of the present application;

[0040] Figure 13 Schematic flow diagram of an image decoding method in the embodiments of the present application;

[0041] Figure 14 Functional unit block diagram of an image coding device in the embodiments of the present application;

[0042] Figure 15 Another functional unit block diagram of an image coding device in the embodiments of the present application;

[0043] Figure 16 Functional unit block diagram of an image decoding device in the embodiments of the present application;

[0044] Figure 17 Another functional unit block diagram of an image decoding device in the embodiments of the present application. Detailed implementation manners

[0045] In order to make the objectives, technical solutions and advantages of the present invention clearer and more understandable, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0046] It can be understood that the terms "first", "second", etc. used in the present invention can be used in this document to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from another element. For example, without departing from the scope of the present invention, the first client can be called the second client, and similarly, the second client can be called the first client. Both the first client and the second client are clients, but they are not the same client.

[0047] First, the terms and related technologies used in the embodiments of the present application will be introduced.

[0048] For the division of images, in order to represent video content more flexibly, the High Efficiency Video Coding standard (HEVC) defines a coding tree unit (CTU), a coding unit (CU), a prediction unit (PU), and a transform unit (TU). CTU, CU, PU, and TU are all image blocks.

[0049] The coding tree unit CTU, an image is composed of multiple CTUs. A CTU usually corresponds to a square image area and contains the luminance pixels and chrominance pixels in this image area (or it can also only contain luminance pixels, or it can also only contain chrominance pixels); the CTU also contains syntax elements, and these syntax elements indicate how to divide the CTU into at least one coding unit (CU), and the method of decoding each coding unit to obtain the reconstructed image. Such as Figure 1As shown, the image 10 is composed of multiple CTUs (including CTU A, CTU B, CTU C, etc.). The coding information corresponding to a certain CTU includes the luminance values and / or chrominance values of the pixels in the square image region corresponding to the CTU. In addition, the coding information corresponding to a certain CTU may also include syntax elements, which indicate how to divide the CTU into at least one CU and the method of decoding each CU to obtain a reconstructed image. The image region corresponding to a CTU may include 64×64, 128×128, or 256×256 pixels. In one example, a CTU of 64×64 pixels contains a rectangular pixel lattice of 64 columns with 64 pixels in each column, and each pixel contains a luminance component and / or a chrominance component. A CTU may also correspond to a rectangular image region or an image region of other shapes. The image region corresponding to a CTU may also be an image region where the number of pixel points in the horizontal direction is different from the number of pixel points in the vertical direction, such as including 64×128 pixels.

[0050] The coding unit CU, usually corresponding to a rectangular region of A×B in the image, contains A×B luminance pixels or / and its corresponding chrominance pixels. A is the width of the rectangle, B is the height of the rectangle, and A and B may be the same or different. The values of A and B are usually powers of 2, such as 128, 64, 32, 16, 8, 4. Among them, the width involved in the embodiments of the present application refers to Figure 1 the length along the X-axis direction (horizontal direction) in the two-dimensional rectangular coordinate system XoY shown, and the height refers to Figure 1 the length along the Y-axis direction (vertical direction) in the two-dimensional rectangular coordinate system XoY shown. The reconstructed image of a CU can be obtained by adding the predicted image and the residual image. The predicted image is generated by intra-frame prediction or inter-frame prediction and can specifically be composed of one or more prediction blocks (PB). The residual image is generated by performing inverse quantization and inverse transformation on the transform coefficients and can specifically be composed of one or more transform blocks (TB). Specifically, a CU contains coding information, which includes information such as prediction mode and transform coefficients. According to these coding information, corresponding prediction, inverse quantization, inverse transformation, and other decoding processes are performed on the CU to generate the reconstructed image corresponding to this CU.

[0051] The prediction unit PU is the basic unit for intra prediction and inter prediction. The motion information of an image block is defined to include the inter prediction direction, reference frame, motion vector, etc. The image block being encoded is called the current coding block (CCB), and the image block being decoded is called the current decoding block (CDB). For example, when a prediction process is performed on an image block, the current coding block or the current decoding block is the prediction block; when a residual process is performed on an image block, the current coding block or the current decoding block is the transform block. The image where the current coding block or the current decoding block is located is called the current frame. In the current frame, the image blocks located on the left or above the current block may be inside the current frame and have completed the encoding / decoding process, obtaining the reconstructed image, and they are called the reconstructed blocks; information such as the coding mode and reconstructed pixels of the reconstructed blocks is available. The frame that has completed the encoding / decoding process before the current frame is encoded / decoded is called the reconstructed frame. When the current frame is a unidirectional prediction frame (P frame) or a bidirectional prediction frame (B frame), it has one or two reference frame lists respectively, and the two lists are called L0 and L1 respectively. Each list contains at least one reconstructed frame, which is called the reference frame of the current frame. The reference frame provides reference pixels for the inter prediction of the current frame.

[0052] The transform unit TU processes the residual between the original image block and the predicted image block.

[0053] A pixel (also known as a pixel point) refers to the pixel point in an image, such as the pixel points in the coding unit, the pixel points in the pixel block of the luminance component (also known as luminance pixels), the pixel points in the pixel block of the chrominance component (also known as chrominance pixels), etc.

[0054] A sample (also known as a pixel value) refers to the pixel value of a pixel point. In the luminance component domain, this pixel value specifically refers to luminance (i.e., the gray scale value), and in the chrominance component domain, this pixel value specifically refers to the chrominance value (i.e., color and saturation). According to the different processing stages, the sample of a pixel specifically includes the original sample, the predicted sample, and the reconstructed sample.

[0055] Intra prediction generates the predicted image of the current block based on the spatially adjacent pixels of the current block. One intra prediction mode corresponds to a method of generating a predicted image. The division of the intra prediction unit includes the 2N×2N division method and the N×N division method. The 2N×2N division method means not dividing the image block; the N×N division method means dividing the image block into four equal-sized sub-image blocks.

[0056] Typically, digital video compression technology is applied to video sequences with a color encoding method of YCbCr, also known as YUV, and color formats of 4:2:0, 4:2:2, or 4:4:4. Among them, Y represents luminance, which is the grayscale value, Cb represents the blue chrominance component, Cr represents the red chrominance component, and U and V represent chrominance, which are used to describe color and saturation. In terms of color format, 4:2:0 means that for every 4 pixels, there are 4 luminance components and 2 chrominance components (YYYYCbCr), 4:2:2 means that for every 4 pixels, there are 4 luminance components and 4 chrominance components (YYYYCbCrCbCr), and 4:4:4 means full pixel display (YYYYCbCrCbCrCbCrCbCr). Figure 2 Shows the distribution diagrams of each component in different color formats, where the circles are the Y components and the triangles are the UV components.

[0057] During the digital video encoding process, the encoder reads and encodes pixels from the original video sequence in different color formats. Generally, a digital encoder usually includes prediction, transformation and quantization, inverse transformation and inverse quantization, loop filtering, and entropy encoding, etc., which are used to eliminate spatial, temporal, visual, and character redundancies. However, the human eye is more sensitive to changes in the luminance component and does not have a strong reaction to changes in the chrominance component. Therefore, the YUV 4:2:0 color format is generally used for encoding in the original video sequence. At the same time, the digital video encoder adopts different prediction processes for the luminance component and the chrominance component in the intra-frame encoding part. The prediction of the luminance component is more detailed and complex, while the prediction of the chrominance component is usually relatively simple. The Cross Component Prediction (CCP) mode is a technology in existing digital video encoding that acts on the luminance component and the chrominance component to improve the video compression ratio.

[0058] The specific implementation process of the cross component prediction mode acts in the intra-frame encoding. This method includes using the training samples of the luminance block to determine the linear model for predicting the chrominance block, and using the samples of the luminance block and the linear model to determine the samples of the chrominance block. Among them, the luminance block and the chrominance block are pixel blocks of the encoding unit in the luminance component and the chrominance component. The digital video encoder usually reads the original video sequence frame by frame and divides the image into Coding Tree Units (CTUs), and the coding tree unit can be further divided into Coding Units (CUs) of different and the same sizes. The specific encoding process is carried out in the coding units of different components. The relationship between the coding tree unit and the coding unit is as Figure 3 shown.

[0059] Example of Cross-Component Prediction (CCP): In the latest Versatile Video Coding (VVC) standard, a Cross Component Linear Model (CCLM) is used to reduce redundancy between components. The linear model is trained using the original and reconstructed samples of adjacent pixels in the original pixel block of the luminance component of the current coding unit. The sample information of these adjacent pixels includes the original and reconstructed samples of the upper adjacent pixels in the original pixel block of the luminance component of the current coding unit, the original and reconstructed samples of the upper-right adjacent pixels in the original pixel block of the luminance component of the current coding unit, the original and reconstructed samples of the left adjacent pixels in the original pixel block of the luminance component of the current coding unit, and the original and reconstructed samples of the lower-left adjacent pixels in the original pixel block of the luminance component of the current coding unit. Figure 4 Examples of the positional relationships between an 8x8 original pixel block of the luminance component and adjacent pixels, and a 4x4 original predicted pixel block of the chrominance component and adjacent pixels under the color format YUV4:2:0 are respectively shown.

[0060] In the current coding unit, the predicted samples of the pixels in the chrominance component prediction block are obtained by linearly modeling and downsampling the reconstructed samples of the pixels in the original pixel block of the luminance component of the current coding unit. The linear modeling process is expressed as follows:

[0061] Pred C (i, j) = α · Rec L (i, j) + β (1)

[0062] where (i, j) are the coordinates of the pixel. Specifically, i refers to the abscissa of the prediction block of the chrominance component of the current coding unit, with a range of [0, width - 1], a step size of 1, and width being the width of the prediction block of the chrominance component of the current coding unit, which can take values of 4, 8, 16, and 32; j specifically refers to the ordinate of the prediction block of the chrominance component of the current coding unit, with a range of [0, height - 1], a step size of 1, and height being the height of the prediction block of the chrominance component of the current coding unit, which can take values of 4, 8, 16, and 32. Rec L is the reconstructed sample of the pixel in the original pixel block of the luminance component, and Pred c is the predicted sample of the pixel in the prediction block of the chrominance component, and α and β are the coefficients of the linear model.

[0063] In the CCLM technology of VVC, there are LM, LM_L, and LM_A modes. Among them, LM_L only uses the left adjacent samples to calculate the linear model, while LM_A only uses the upper adjacent samples to calculate the linear model.

[0064] In another example of cross-component prediction, the cross-component technology proposal M4612, the Two Step Cross-component Prediction Mode (TSCPM), which was recently adopted by the Audio Video coding Standard (AVS) in China. During the encoding process, as Figure 5A shown, the intra-coded luminance component calculates up to 65 intra prediction modes. DC represents the mean mode, Plane represents the plane mode, Bilinear represents the bilinear mode, and Zone represents the zone. The optimal result is selected according to the Rate Distortion cost, and the intra prediction mode and the corresponding prediction residual are transmitted. In the current coding unit, the intra-coded chrominance component calculates up to 11 intra prediction modes for chrominance components, including the calculation of 5 intra prediction modes for chrominance components that refer to the information of a single chrominance component and the calculation of 6 intra prediction modes for chrominance components that refer to multi-component information. The above intra-chrominance prediction mode that refers to the information of a single chrominance component is the ordinary intra prediction mode for chrominance components.

[0065] When using the ordinary intra prediction mode for chrominance components for the pixels of the prediction block of the chrominance component, the current chrominance coding block calculates the prediction samples of the current chrominance coding block according to the available information of the reconstructed samples of the adjacent prediction blocks of the chrominance component and the corresponding intra prediction mode for chrominance components. The reference pixels of the adjacent prediction blocks selected by different prediction modes are also inconsistent. Some prediction modes can directly calculate the prediction samples using the reconstructed samples of the pixels of the adjacent coding blocks, while some prediction modes need to interpolate the reconstructed samples of the pixels of the adjacent coding blocks and then select the reference pixels to calculate the prediction samples of the current coding block. Figure 5B Separate schematic diagrams of intra prediction modes with a coding block size of 8X8 are shown. In the figure, (1) is the ordinary intra vertical angle prediction mode, which calculates the prediction samples of the current coding block using the reference pixels of the upper adjacent block. (2) is the ordinary intra horizontal angle prediction mode, which calculates the prediction samples of the current coding block using the reference pixels of the left adjacent block. (3) is the ordinary intra non-angle prediction mode, which calculates the prediction samples of the current coding block using the reference pixels of both the upper and left adjacent blocks.

[0066] When performing cross-component technology prediction on the pixels of the prediction block of the chrominance component, the reconstructed samples of the adjacent pixels of the original pixel block of the luminance component of the current coding unit and the reconstructed samples of the adjacent pixels of the original prediction pixel block of the chrominance component of the current coding unit are used for the calculation of the linear model. The adjacent pixels of the original pixel block of the above luminance component include the upper adjacent pixel and the left adjacent pixel of the original pixel block of the luminance component of the current coding unit; the adjacent pixels of the prediction block of the above chrominance component include the upper adjacent pixel and the left adjacent pixel of the prediction block of the chrominance component of the current coding unit.

[0067] When selecting the reconstructed sample as the reference sample for calculating the coefficients of the linear model, in combination with the availability of the reconstructed samples of the adjacent pixels, a combination of the reconstructed samples of two pixels in the upper adjacent pixels and the reconstructed samples of two pixels in the left adjacent pixels can be adopted, or the reconstructed samples of all four pixels in the upper adjacent pixels can be entirely adopted, and the reconstructed samples of all four pixels in the left adjacent pixels can be entirely adopted.

[0068] According to the different selections of the above reference samples, the prediction modes include: if the reconstructed samples of the upper adjacent pixels of the original pixel blocks of the luminance component and the chrominance component corresponding to the current coding unit (collectively referred to as the original pixel blocks for convenience of description at this end) and the reconstructed samples of the left adjacent pixels of the original pixel block of the current coding unit are available, and the reference samples used for the calculation of the coefficients of the linear model come from both the upper and left adjacent pixels at the same time, or if only the reconstructed samples of the upper adjacent pixels of the original pixel block corresponding to the current coding unit are available, and the reference samples used for the calculation of the linear model coefficients only select the reconstructed samples of the upper adjacent pixels, or if only the reconstructed samples of the left adjacent pixels of the original pixel block corresponding to the current coding unit are available, and the reference samples used for the calculation of the coefficients of the linear model only select the reconstructed samples of the left adjacent pixels, all are in the TSCPM mode; if the reconstructed samples of the upper adjacent pixels of the original pixel block corresponding to the current coding unit and the reconstructed samples of the left adjacent pixels of the original pixel block corresponding to the current coding unit are available, and the reference samples used for the calculation of the coefficients of the linear model only select the reconstructed samples of the upper adjacent pixels, it is the TSCPM_T mode; if the reconstructed samples of the upper adjacent pixels of the original pixel block corresponding to the current coding unit and the reconstructed samples of the left adjacent pixels of the original pixel block corresponding to the current coding unit are available, and the reference samples used for the calculation of the coefficients of the linear model only select the reconstructed samples of the upper adjacent pixels, it is the TSCPM_L mode.

[0069] Among the above reference samples used for the calculation of the coefficients of the linear model, such as Figure 6As shown, if the reference samples are from the adjacent pixels on both sides of the original pixel block corresponding to the current coding unit, for the upper reference sample, the reconstructed sample of the leftmost pixel among the upper adjacent pixels and the reconstructed sample of the rightmost pixel on the upper side of the width of the original pixel block corresponding to the current coding unit are selected; for the left reference sample, the reconstructed sample of the uppermost pixel among the left adjacent pixels and the reconstructed sample of the lowermost pixel among the left adjacent pixels of the height of the original pixel block corresponding to the current coding unit are selected; if the reference samples used for the calculation of the coefficients of the linear model only come from the upper side, then with a step size of one-fourth of the width of the original pixel block corresponding to the current coding unit, the reconstructed samples of the pixels with four consecutive steps among the upper adjacent pixels are selected; if the reference samples only come from the left side, then with a step size of one-fourth of the height of the original pixel block corresponding to the current coding unit, the reconstructed samples of the pixels with four consecutive steps among the four left adjacent pixels are selected.

[0070] That is, the adjacent pixels of the four luminance components and the adjacent pixels of the four chrominance components can be selected in three ways.

[0071] Method 1: When two adjacent pixels are selected from the upper adjacent coding block and the left adjacent coding block respectively, the adjacent pixels can be determined by the following formula:

[0072] minStep = min(Width, Height);

[0073] TopIndex = (minStep – 1) * Width / minStep;

[0074] LeftIndex = (minStep – 1) * Height / minStep;

[0075] In the above formulas, min(x, y) returns the smaller value of x and y, Width is the width of the chrominance component of the current coding block, Height is the height of the chrominance component of the current coding block, TopIndex is the index value of the other adjacent pixel except the first adjacent pixel when selecting the adjacent pixel on the upper boundary, and LeftIndex is the index value of the other adjacent pixel except the first adjacent pixel when selecting the adjacent pixel on the left boundary;

[0076] Method 2: When four adjacent pixels are only selected from the upper adjacent coding block, starting from the leftmost first adjacent pixel, with a step size of one-fourth of the width of the chrominance component of the current coding block, four adjacent pixels of the luminance components and four adjacent pixels of the chrominance components are selected;

[0077] Method 3: When selecting four adjacent pixels only from the left adjacent coding block, starting from the topmost first adjacent pixel, with a step size of one-fourth of the height of the chrominance component of the current coding block, select four adjacent pixels of the luminance component and four adjacent pixels of the chrominance component;

[0078] In the above specific example AVS3, the linear model calculation formula of the cross-component technology is the same as the above formula (1), where α and β can be calculated through the following formulas:

[0079]

[0080] β = Y Min -α·X Min (3)

[0081] Among them, Y Max is the average value of the two largest reconstruction samples among the reconstruction samples of multiple adjacent pixel points of the original pixel block of the chrominance component used for the calculation of the coefficients of the linear model, and Y Min is the average value of the two smallest reconstruction samples among the reconstruction samples of multiple adjacent pixel points of the original pixel block of the chrominance component used for the calculation of the coefficients of the linear model. X Max is the average value of the two largest reconstruction samples among the reconstruction samples of multiple adjacent pixel points of the original pixel block of the luminance component used for the calculation of the coefficients of the linear model, and X Min is the average value of the two smallest reconstruction samples among the reconstruction samples of multiple adjacent pixel points of the original pixel block of the luminance component used for the calculation of the coefficients of the linear model.

[0082] Perform cross-component prediction according to the calculated linear model. The reconstructed block of the luminance component of the current CU is used to generate the corresponding chrominance component reference prediction block (Chroma Reference Prediction Pixel Block). Specifically, calculate the reference prediction samples of the chrominance component of each pixel of the current coding unit according to formulas (1) / (2) and (3). The size of this chrominance component reference prediction block is the same as the size of the original pixel block of the luminance component. In a specific example, the input digital video color format is generally the YUV4∶2∶0 format, that is, the size of the chrominance component prediction block is one-fourth of the size of the original pixel block of the luminance component. To obtain the corresponding chrominance component prediction block with the correct size, this chrominance component reference prediction block needs to be downsampled by one-half in both the horizontal and vertical directions. After downsampling, the chrominance component prediction block is one-fourth of the original pixel block of the corresponding luminance component, meeting the size requirements of the color format constraint. Among them, the filter used for downsampling the chrominance component reference prediction block uses a two-tap downsampling filter with the same coefficients in the left boundary pixel area of this chrominance component reference prediction block, and uses a six-tap downsampling filter with two different coefficients in other pixel areas.

[0083] The six-tap downsampling filter with two different coefficients is shown in Equation (4).

[0084]

[0085] where x and y are the coordinates of the pixel, and P’ C is the predicted sample of the luminance component of the current pixel, and P 1 C and P 2 C are the predicted samples of the chrominance components of the current pixel.

[0086] The two-tap downsampling filter with the same coefficient is shown in Equation (5).

[0087]

[0088] where x and y are the coordinates of the pixel, and P’ C is the predicted sample of the luminance component of the current pixel, and P 1 C and P 2 C are the predicted samples of the chrominance components of the current pixel.

[0089] The downsampling filter is as shown in Figure 7 where x1 represents multiplying by 1 and x2 represents multiplying by 2. Figure 8 Figure shows a schematic diagram of the change from the luminance component reconstruction block to the chrominance component prediction block in the cross-component technology. Among them, the size of the luminance component reconstruction block of the coding unit is 8*8, the size of the corresponding chrominance component reference prediction block is 8*8, and the size of the filtered chrominance component prediction block is 4*4.

[0090] AVS3 also adopts a variety of cross-component prediction modes MCPM. The three prediction modes of MCPM are similar to the TSCPM prediction mode. The MCPM mode corresponds to the TSCPM mode, the MCPM_T mode corresponds to the TSCPM_T mode, and the MCPM_L mode corresponds to the TSCPM_L mode. However, the chrominance component prediction process is different. The chrominance U component prediction process of the three MCPM prediction modes is the same as that of the TSCPM mode, while the prediction block of the chrominance V component is obtained by subtracting the reconstruction block of the U component from the temporary chrominance prediction component block. The specific formula is as follows:

[0091] Pred C (x, y) = α′·Rec L (x, y) + β′ (6)

[0092] Pred Cr (x, y) = Pred C(x, y)-Rec Cb (x, y) (7)

[0093] In the above formulas (2) and (3), Pred C (x, y) is the predicted sample at the pixel (x, y) in the predicted block of the chrominance component, and Rec L (x, y) is the reconstructed sample at the pixel (x, y) in the reconstructed block of the luminance component, and Pred C ’(x, y) is the predicted sample at the pixel (x, y) in the predicted block of the chrominance component after downsampling, and Rec cb (x, y) is the reconstructed sample of the U component at the pixel (x, y) in the reconstructed block of the chrominance component, and Pred Cr (x, y) is the predicted sample of the V component at the pixel (x, y) in the predicted block of the chrominance component. α’ and β’ are respectively the sum of the linear parameters of the U component and the V component. The calculation of the linear parameters of the U component and the V component refers to formulas (2) and (3). Currently, in the existing enhanced two-step cross-component prediction technology, when all the reconstructed samples from the upper or left adjacent coding units are used as reference information to calculate the linear model to obtain the reference predicted block of the chrominance component of the current coding unit, if only the reconstructed samples from the upper adjacent pixels are taken, the reference information of the reconstructed samples from the left adjacent pixels is lacking; if only the reconstructed samples from the left adjacent pixels are taken, the reference information of the reconstructed samples from the upper adjacent pixels is lacking.

[0094] When the existing chrominance component intra prediction mode selects pixels as the reference pixels of the prediction mode, it often ignores the correlation between some reference pixels and the current coding block. There is a spatial correlation between the current coding block and all adjacent pixels. If only the upper adjacent pixels are taken, the reference information of the left adjacent pixels is lacking; if only the left adjacent pixels are taken, the reference information of the upper adjacent pixels is lacking.

[0095] The existing ordinary chrominance component intra prediction mode selects the adjacent pixels in the corresponding direction as the reference pixels according to the directionality of the prediction mode. However, there is also a certain correlation between the current coding block and the adjacent pixels not in this direction. The prediction effect of only referring to the adjacent pixels in a single direction is not good, and the available reference information of other adjacent pixels is wasted. The existing cross-component chrominance prediction mode calculates the linear model by simply selecting the upper or left adjacent pixels as the reference pixels according to the prediction mode, and there are also some problems. If the upper adjacent pixels are simply selected as the reference pixels, the spatial correlation between the current coding block and the left coding block is ignored; if the left adjacent pixels are simply selected as the reference pixels, the spatial correlation between the current coding block and the upper coding block is ignored.

[0096] Such prediction wastes a large amount of available reference information and cannot well predict the sample values of the chrominance components of the current coding unit, resulting in a loss of coding efficiency.

[0097] To address the above technical problems, the present application proposes the following design ideas.

[0098] Perform prediction correction on the prediction block calculated through the ordinary intra prediction mode of chrominance components.

[0099] If only the adjacent pixels of the upper chrominance component are selected as reference pixels to calculate the prediction sample of the current coding block, then use the adjacent pixels of the left chrominance component as reference pixels to perform prediction correction on the prediction sample of the chrominance component of the current coding block.

[0100] If only the adjacent pixels of the left chrominance component are selected as reference pixels to calculate the prediction sample of the current coding block, then use the adjacent pixels of the upper chrominance component as reference pixels to perform prediction correction on the prediction sample of the chrominance component of the current coding block.

[0101] If the current coding block adopts the ordinary intra non-angle prediction mode of chrominance components, then use the adjacent pixels of the upper and left chrominance components as reference pixels to perform prediction correction on the prediction sample of the chrominance component of the current coding block.

[0102] Perform prediction correction on the prediction sample calculated through the cross-component prediction mode of chrominance components.

[0103] If only the adjacent pixels of the upper luminance component and the adjacent pixels of the upper chrominance component are selected to calculate the linear model for the current coding block, then use the adjacent pixels of the left chrominance component as reference pixels to perform prediction correction on the prediction sample of the chrominance component of the current coding block.

[0104] If only the adjacent pixels of the left luminance component and the adjacent pixels of the left chrominance component are selected to calculate the linear model for the current coding block, then use the adjacent pixels of the upper chrominance component as reference pixels to perform prediction correction on the prediction sample of the chrominance component of the current coding block.

[0105] The above prediction correction of the prediction sample of the current coding block includes using the distance between the current pixel and the reference adjacent pixels as the filter coefficient index value, using the size of the current coding block as the filter coefficient group index value, looking up the intra prediction filter coefficient group of chrominance components according to the filter coefficient group index value, and finding the intra prediction filter coefficient of chrominance components within the group according to the filter coefficient index value, and calculating the corrected prediction sample according to the found filter coefficient and the prediction correction formula.

[0106] Specifically, at the coding end, first determine whether the current coding block can use the prediction correction technology of chrominance components.

[0107] If prediction correction of chrominance components is used, intra prediction is performed on the luminance component of the current coding block, and prediction sample correction is performed on the prediction samples after prediction ends. Then, intra prediction is performed on the chrominance components of the current coding block, and prediction correction is performed on the prediction samples after prediction ends.

[0108] The above prediction correction of the current coding block includes techniques that require transmitting a flag bit and those that do not require transmitting a flag bit to indicate whether prediction correction of chrominance components is used for the current coding block.

[0109] If the current prediction correction technique requires transmitting a flag bit, it is determined whether to use the prediction correction technique of intra prediction based on the rate-distortion cost calculated from the uncorrected prediction samples and the corrected prediction samples.

[0110] If the rate-distortion cost calculated for the uncorrected prediction samples is smaller, the current coding block does not use the prediction correction technique of intra prediction, and the flag bit is transmitted and represented as false.

[0111] If the rate-distortion cost calculated for the prediction samples after prediction correction is smaller, the current chrominance component coding block uses the prediction correction technique of intra prediction, and the flag bit is transmitted and represented as true.

[0112] If the current prediction correction technique does not require transmitting a flag bit, prediction correction is directly applied to the prediction samples of the current coding block to obtain the corrected prediction samples.

[0113] Specifically, at the decoding end, first, it is parsed and obtained whether the current bitstream can use the prediction correction technique of intra prediction for chrominance components.

[0114] If the prediction correction technique can be used, the bitstream is parsed to obtain the prediction mode of the current chrominance component of the current decoding block, and specific adjacent pixels are selected as reference pixels to perform prediction correction on the prediction samples of the current decoding block.

[0115] The above process of performing prediction correction on the prediction samples of the current decoding block includes cases where the current decoding block requires a flag bit to indicate whether to use the prediction correction technique and cases where it does not require a flag bit to indicate whether to use the prediction correction technique.

[0116] If the current decoding block requires a flag bit to indicate whether to use the prediction correction technique, the bitstream of the current decoding block is parsed to obtain the flag bit value and the prediction mode of the chrominance component.

[0117] If the value of the flag bit is true, the prediction samples are calculated according to the prediction mode of the current chrominance component.

[0118] If the upper adjacent pixel is selected as the reference pixel for calculating the prediction samples, the left adjacent pixel is taken as the reference pixel to perform prediction correction on the prediction samples.

[0119] If the left adjacent pixel is selected as the reference pixel for calculating the prediction sample, then the upper adjacent pixel is taken as the reference pixel to perform prediction correction on the prediction sample;

[0120] If the value of the flag bit is No, then the prediction sample is calculated according to the prediction mode of the current chrominance component, and the prediction sample is not filtered;

[0121] If the current decoding block does not require a flag bit to indicate whether to use the prediction correction technique, then the bitstream of the current decoding block is parsed to obtain the prediction mode of the chrominance component, and the prediction sample is calculated according to the prediction mode of the current chrominance component.

[0122] If the upper adjacent pixel is selected as the reference pixel for calculating the decoding block, then the left adjacent pixel is taken as the reference pixel to perform prediction correction on the prediction sample;

[0123] If the left adjacent pixel is selected as the reference pixel for calculating the decoding block, then the upper adjacent pixel is taken as the reference pixel to perform prediction correction on the prediction sample.

[0124] The embodiments of the present application utilize the spatial correlation between adjacent coding blocks and the current coding block to correct the prediction sample of the chrominance component of the current coding block, improving the prediction accuracy and coding efficiency.

[0125] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application.

[0126] Figure 9 It is a block diagram of a video decoding system 1 of an example described in the embodiments of the present application. As used herein, the term "video decoder" generally refers to both a video encoder and a video decoder. In the present application, the terms "video decoding" or "decoding" may generally refer to video encoding or video decoding. The video encoder 100 and the video decoder 200 of the video decoding system 1 are used to implement the cross-component prediction method proposed in the present application.

[0127] As Figure 9 shown, the video decoding system 1 includes a source device 10 and a destination device 20. The source device 10 generates encoded video data. Therefore, the source device 10 can be referred to as a video encoding device. The destination device 20 can decode the encoded video data generated by the source device 10. Therefore, the destination device 20 can be referred to as a video decoding device. Various embodiments of the source device 10, the destination device 20, or both may include one or more processors and a memory coupled to the one or more processors. The memory may include, but is not limited to, RAM, ROM, EEPROM, flash memory, or any other medium that can be used to store the desired program code in the form of computer-accessible instructions or data structures, as described herein.

[0128] The source device 10 and the destination device 20 may include various devices, including desktop computers, mobile computing devices, notebook (e.g., laptop) computers, tablet computers, set-top boxes, telephone handsets such as so-called "smart" phones, televisions, cameras, display devices, digital media players, video game consoles, in-vehicle computers, or the like.

[0129] The destination device 20 may receive the encoded video data from the source device 10 via the link 30. The link 30 may include one or more media or devices capable of moving the encoded video data from the source device 10 to the destination device 20. In one example, the link 30 may include one or more communication media that enable the source device 10 to directly transmit the encoded video data to the destination device 20 in real time. In this example, the source device 10 may modulate the encoded video data according to a communication standard (e.g., a wireless communication protocol) and may transmit the modulated video data to the destination device 20. The one or more communication media may include wireless and / or wired communication media, such as the radio frequency (RF) spectrum or one or more physical transmission lines. The one or more communication media may form part of a packet-based network, such as a local area network, a wide area network, or a global network (e.g., the Internet). The one or more communication media may include routers, switches, base stations, or other devices that facilitate communication from the source device 10 to the destination device 20. In another example, the encoded data may be output from the output interface 140 to the storage device 40.

[0130] The image codec technology of the present application can be applied to video coding and decoding to support a variety of multimedia applications, such as over-the-air television broadcasting, cable television transmission, satellite television transmission, streaming video transmission (e.g., via the Internet), encoding of video data stored on a data storage medium, decoding of video data stored on a data storage medium, or other applications. In some examples, the video decoding system 1 can be used to support one-way or two-way video transmission to support applications such as video streaming, video playback, video broadcasting, and / or video telephony.

[0131] Figure 9 The video decoding system 1 illustrated is only an example, and the technology of the present application can be applied to video decoding settings (e.g., video encoding or video decoding) that may not include any data communication between the encoding device and the decoding device. In other examples, data is retrieved from local memory, streamed over a network, etc. The video encoding device can encode the data and store the data in memory, and / or the video decoding device can retrieve the data from memory and decode the data. In many examples, encoding and decoding are performed by devices that do not communicate with each other but only encode data into memory and / or retrieve data from memory and decode the data.

[0132] InFigure 9 In an example, the source device 10 includes a video source 120, a video encoder 100, and an output interface 140. In some examples, the output interface 140 may include a regulator / demodulator (modem) and / or a transmitter. The video source 120 may include a video capture device (e.g., a camera), a video archive containing previously captured video data, a video feed interface for receiving video data from a video content provider, and / or a computer graphics system for generating video data, or a combination of these sources of video data.

[0133] The video encoder 100 may encode the video data from the video source 120. In some examples, the source device 10 directly transmits the encoded video data to the destination device 20 via the output interface 140. In other examples, the encoded video data may also be stored on the storage device 40 for later access by the destination device 20 for decoding and / or playback.

[0134] In Figure 9 an example, the destination device 20 includes an input interface 240, a video decoder 200, and a display device 220. In some examples, the input interface 240 includes a receiver and / or a modem. The input interface 240 may receive the encoded video data via the link 30 and / or from the storage device 40. The display device 220 may be integrated with the destination device 20 or may be external to the destination device 20. Generally, the display device 220 displays the decoded video data. The display device 220 may include various display devices, such as a liquid crystal display (LCD), a plasma display, an organic light emitting diode (OLED) display, or other types of display devices.

[0135] Although Figure 9 not shown in, in some aspects, the video encoder 100 and the video decoder 200 may each be integrated with an audio encoder and decoder, and may include appropriate multiplexer-demultiplexer units or other hardware and software to handle the encoding of both audio and video in a common data stream or separate data streams.

[0136] Video encoder 100 and video decoder 200 may each be implemented as any of a variety of circuits such as, for example, one or more microprocessors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), discrete logic, hardware, or any combination thereof. If the present application is implemented partially in software, the apparatus may store instructions for the software in a suitable non-transitory computer-readable storage medium and may execute the instructions in hardware using one or more processors to implement the techniques of the present application. Any of the foregoing (including hardware, software, combinations of hardware and software, etc.) may be considered one or more processors. Each of video encoder 100 and video decoder 200 may be included in one or more encoders or decoders, any of which may be integrated as part of a combined encoder / decoder (codec) in a corresponding apparatus.

[0137] Figure 10 FIG. is an example block diagram of a video encoder 100 described in an embodiment of the present application. Video encoder 100 is configured to output video to post-processing entity 41. Post-processing entity 41 represents an instance of a video entity that may process the encoded video data from video encoder 100, such as a media-aware network element (MANE) or a splicing / editing device. In some cases, post-processing entity 41 may be an instance of a network entity. In some video coding systems, post-processing entity 41 and video encoder 100 may be portions of separate devices, while in other cases, the functionality described with respect to post-processing entity 41 may be performed by the same device that includes video encoder 100. In one example, post-processing entity 41 is Figure 1 an instance of storage device 40.

[0138] In Figure 10 the example, video encoder 100 includes prediction processing unit 108, filter unit 106, memory 107, adder 112, transform unit 101, quantizer 102, and entropy encoder 103. Prediction processing unit 108 includes inter-frame predictor 110 and intra-frame predictor 109. For image block reconstruction, video encoder 100 also includes an inverse quantizer 104, an inverse transform unit 105, and adder 111. Filter unit 106 represents one or more loop filters, such as a deblocking filter, an adaptive loop filter (ALF), and a sample adaptive offset (SAO) filter. Although filter unit 106 is shown as an in-loop filter in Figure 10 FIG., in other implementations, filter unit 106 may be implemented as a post-loop filter. In one example, video encoder 100 may further include a video data memory, a segmentation unit (not shown in the figure).

[0139] Video encoder 100 receives video data and stores the video data in a video data memory. A splitting unit splits the video data into a number of image blocks, and these image blocks can be further split into smaller blocks, such as image block splitting based on a quadtree structure or a binary tree structure. Prediction processing unit 108 can select one of a plurality of possible decoding modes for the current image block, such as one of a plurality of intra-frame decoding modes or one of a plurality of inter-frame decoding modes. Prediction processing unit 108 can provide the resulting intra-frame, inter-frame decoded block to adder 112 to generate a residual block, and to adder 111 to reconstruct an encoded block used as a reference image. Intra-frame predictor 109 within prediction processing unit 108 can perform intra-frame predictive coding of the current image block relative to one or more adjacent blocks in the same frame or slice as the current block to be encoded to remove spatial redundancy. Inter-frame predictor 110 within prediction processing unit 108 can perform inter-frame predictive coding of the current image block relative to one or more prediction blocks in one or more reference images to remove temporal redundancy. Prediction processing unit 108 provides information indicating the selected intra-frame or inter-frame prediction mode of the current image block to entropy encoder 103 to facilitate entropy encoder 103 encoding the information indicating the selected inter-frame prediction mode.

[0140] After prediction processing unit 108 generates a prediction block of the current image block via inter-frame prediction / intra-frame prediction, video encoder 100 forms a residual image block by subtracting the prediction block from the current image block to be encoded. Adder 112 represents one or more components that perform this subtraction operation. The residual video data in the residual block can be included in one or more TUs and applied to transformer 101. Transformer 101 transforms the residual video data into residual transform coefficients using a transform such as a discrete cosine transform (DCT) or a conceptually similar transform. Transformer 101 can convert the residual video data from the pixel value domain to the transform domain, such as the frequency domain.

[0141] Transformer 101 can send the resulting transform coefficients to quantizer 102. Quantizer 102 quantizes the transform coefficients to further reduce the bit rate. In some instances, quantizer 102 can then perform a scan of the matrix containing the quantized transform coefficients. Alternatively, entropy encoder 103 can perform the scan.

[0142] After quantization, entropy encoder 103 performs entropy encoding on the quantized transform coefficients. For example, entropy encoder 103 may perform context - adaptive variable - length coding (CAVLC), context - adaptive binary arithmetic coding (CABAC), syntax - based context - adaptive binary arithmetic coding (SBAC), probability interval partitioning entropy (PIPE) coding, or another entropy coding method or technique. After being entropy - encoded by entropy encoder 103, the encoded bitstream may be transmitted to video decoder 200, or archived for later transmission or retrieval by video decoder 200. Entropy encoder 103 may also perform entropy encoding on the syntax elements of the current image block to be encoded.

[0143] Inverse quantizer 104 and inverse transformer 105 respectively apply inverse quantization and inverse transformation to reconstruct the residual block in the pixel domain, for example, for later use as a reference block of a reference image. Summing unit 111 adds the reconstructed residual block to the prediction block generated by inter - frame predictor 110 or intra - frame predictor 109 to generate a reconstructed image block. Filter unit 106 may be applied to the reconstructed image block to reduce distortions such as block artifacts. Then, the reconstructed image block is stored in memory 107 as a reference block and can be used by inter - frame predictor 110 as a reference block for inter - frame prediction of blocks in subsequent video frames or images.

[0144] Specifically, video encoder 100 specifically executes the image coding method provided by the embodiments of the present application. The input video is divided into a number of coding tree units, and each coding tree unit is further divided into a number of coding units that are either rectangular or square. When the current coding unit selects the intra - frame prediction mode for coding, several prediction modes of the luminance component of the current coding unit are calculated and traversed, and the optimal prediction mode is selected according to the rate - distortion cost. Several prediction modes of the chrominance component of the current coding unit are calculated and traversed, and the optimal prediction mode is selected according to the rate - distortion cost. After that, the residual between the original video block and the prediction block is calculated. This residual then passes through transformation and quantization, entropy encoding, etc. all the way to form an output bitstream, and passes through inverse transformation and inverse quantization, loop filtering, etc. on the other way to form reconstructed samples as reference information for subsequent video compression.

[0145] Intra - frame predictor 109 may also provide information indicating the intra - frame prediction mode selected for the current coding unit to entropy encoder 103 so that entropy encoder 103 encodes the information indicating the selected intra - frame prediction mode.

[0146] Figure 11 This is an example block diagram of a video decoder 200 described in the embodiments of the present application. In Figure 11In an example, the video decoder 200 includes an entropy decoder 203, a prediction processing unit 208, an inverse quantizer 204, an inverse transform unit 205, a summer 211, a filter unit 206, and a memory 207. The prediction processing unit 208 may include an inter-prediction unit 210 and an intra-prediction unit 209. In some examples, the video decoder 200 may perform a decoding process that is substantially inverse to the encoding process described with respect to the video encoder 100 from Figure 10 which the encoding process is described.

[0147] During the decoding process, the video decoder 200 receives an encoded video bitstream representing image blocks of an encoded video slice and associated syntax elements from the video encoder 100. The video decoder 200 may receive video data from a network entity 42 and, optionally, may also store the video data in a video data memory (not shown in the figure). The video data memory may store video data to be decoded by components of the video decoder 200, such as an encoded video bitstream. The video data stored in the video data memory may be obtained, for example, from a storage device 40, from a local video source such as a camera, via wired or wireless network communication of the video data, or by accessing a physical data storage medium. The video data memory may serve as a decoded picture buffer (CPB) for storing encoded video data from the encoded video bitstream.

[0148] The network entity 42 may be, for example, a server, a MANE, a video editor / splicer, or other such devices for implementing one or more of the techniques described above. The network entity 42 may or may not include a video encoder, such as the video encoder 100. Before the network entity 42 sends the encoded video bitstream to the video decoder 200, the network entity 42 may implement some of the techniques described in this application. In some video decoding systems, the network entity 42 and the video decoder 200 may be part of separate devices, while in other cases, the functionality described with respect to the network entity 42 may be performed by the same device that includes the video decoder 200.

[0149] The entropy decoder 203 of the video decoder 200 performs entropy decoding on the bitstream to generate quantized coefficients and some syntax elements. The entropy decoder 203 forwards the syntax elements to the prediction processing unit 208. The video decoder 200 may receive syntax elements at the video slice level and / or at the picture block level. When a video slice is decoded as an intra-coded (I) slice, the intra predictor 209 of the prediction processing unit 208 generates a predicted block of the picture blocks of the current video slice based on the signaled intra prediction mode and data from previously decoded blocks of the current frame or picture. When a video slice is decoded as an inter-coded (i.e., B or P) slice, the inter predictor 210 of the prediction processing unit 208 may determine an inter prediction mode for decoding the current picture block of the current video slice based on the syntax elements received from the entropy decoder 203, and decode the current picture block (e.g., perform inter prediction) based on the determined inter prediction mode.

[0150] The inverse quantizer 204 inverse quantizes, i.e., dequantizes, the quantized transform coefficients provided in the bitstream and decoded by the entropy decoder 203. The inverse quantization process may include: using the quantization parameter calculated by the video encoder 100 for each picture block in the video slice to determine the degree of quantization to be applied and similarly to determine the degree of inverse quantization to be applied. The inverse transform unit 205 applies an inverse transform to the transform coefficients, such as an inverse DCT, an inverse integer transform, or a conceptually similar inverse transform process, in order to generate a residual block in the pixel domain.

[0151] After the inter predictor 210 generates a predicted block for the current picture block or a sub-block of the current picture block, the video decoder 200 obtains a reconstructed block, i.e., a decoded picture block, by summing the residual block from the inverse transform unit 205 and the corresponding predicted block generated by the inter predictor 210. The summer 211 represents the component that performs this summing operation. When needed, a loop filter (either in the decoding loop or after the decoding loop) may also be used to smooth the pixel transitions or otherwise improve the video quality. The filter unit 206 may represent one or more loop filters, such as a deblocking filter, an adaptive loop filter (ALF), and a sample adaptive offset (SAO) filter. Although the filter unit 206 is shown as a in-loop filter in Figure 11 it may be implemented as a post-loop filter in other implementations.

[0152] The image decoding method specifically performed by the video decoder 200 includes obtaining a prediction mode index of the current coding unit after parsing, inverse transforming, and inverse quantizing the input bitstream.

[0153] If the prediction mode index of the chrominance component of the current coding unit is the enhanced two-step cross-component prediction mode, then only the reconstructed samples from the upper or left adjacent pixels of the current coding unit are selected for linear model calculation according to the index value, and the reference prediction block of the chrominance component of the current coding unit is obtained according to the linear model calculation, downsampled, and the prediction correction based on the correlation of the boundary adjacent pixels in the orthogonal direction is performed on the downsampled prediction block to obtain the final prediction block of the chrominance component.

[0154] The subsequent code stream is used as reference information for subsequent video decoding and is output as a video signal after post-filtering.

[0155] It should be understood that other structural changes of the video decoder 200 can be used to decode the encoded video code stream. For example, the video decoder 200 can generate an output video stream without being processed by the filter unit 206; or, for some image blocks or image frames, the entropy decoder 203 of the video decoder 200 does not decode the quantized coefficients, and accordingly does not need to be processed by the inverse quantizer 204 and the inverse transformer 205.

[0156] Specifically, the intra-frame predictor 209 may use the image decoding method described in the embodiment of the present application during the process of generating the prediction block.

[0157] Figure 12A A schematic diagram of a flow chart of an image encoding method in an embodiment of the present application, which can be applied to Figure 9 The source device 10 or Figure 10 A video encoder 100 is shown. Figure 12A The process shown is based on the execution subject Figure 10 The video encoder 100 shown is used as an example for explanation. Figure 12A As shown, the cross-component prediction method provided by the embodiment of the present application includes:

[0158] Step 110, divide the image and determine the intra-frame prediction mode of the chrominance component of the current coding block.

[0159] The color format of the video to which the image belongs includes but is not limited to 4:2:0, 4:2:2, etc.

[0160] For example, when the color format is 4:2:0, Figure 2 As shown in (c), the pixel ratio of the original pixel block of the luminance component of the current coding block to the original pixel block of the chrominance component is 4:1. Taking the 8*8 forward square pixel array as an example, the size of the corresponding original pixel block of the luminance component is 8*8, and the size of the corresponding original pixel block of the chrominance component is 4*4.

[0161] For example, when the color format is 4:2:2,Figure 2 As shown in (b) of , the pixel ratio of the original pixel block of the luminance component to the original pixel block of the chrominance component of the current coding block is 2:1. Taking an 8×8 forward pixel array as an example, the size of the original pixel block of the corresponding luminance component is 8×8, and the size of the original pixel block of the corresponding chrominance component is 8×4.

[0162] Among them, for the intra prediction mode of the chrominance component, at most 11 intra prediction modes of the chrominance component are calculated, including the calculation of 5 intra prediction modes of the chrominance component that refer to the single chrominance component information and the calculation of 6 intra prediction modes of the chrominance component that refer to the multi-component information. The above-mentioned intra chrominance prediction mode that refers to the single chrominance component information is the ordinary intra prediction mode of the chrominance component.

[0163] Step 120: Determine the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component.

[0164] In this possible example, the determining the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component includes: determining the reference pixels according to the available information of the reconstructed samples of the adjacent pixels of the current coding block and the intra prediction mode of the chrominance component; and determining the prediction block of the chrominance component of the current coding block according to the reference pixels.

[0165] In specific implementation, for the case where the ordinary intra prediction mode is adopted for the intra prediction mode of the chrominance component, the prediction block of the chrominance component can be determined by means of protocol agreement. For details, see the foregoing description of the ordinary intra prediction mode, which will not be elaborated here.

[0166] In this possible example, the determining the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component includes: determining the intra prediction mode of the luminance component of the current coding block; when the intra prediction mode of the chrominance component indicates that the luminance component of the current coding block is used to determine the predicted value of the chrominance component of the current coding block, determining the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component.

[0167] Among them, as Figure 5A shown, for the calculation of the intra-coded luminance component, at most 65 intra prediction modes are calculated. In specific implementation, the luminance component calculates at most 62 angular prediction modes and 3 non-angular prediction modes and selects an optimal intra prediction mode for transmission. The intra prediction mode of the luminance component of the current coding block is the prediction mode with the optimal rate-distortion cost among multiple intra prediction modes, and the multiple intra prediction modes are the intra prediction modes used for the intra prediction of the luminance component of the current coding block.

[0168] In this possible example, determining the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component includes: determining the reference prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component; filtering the reference prediction block of the chrominance component of the current coding block to obtain the prediction block of the chrominance component of the current coding block.

[0169] In a specific implementation, when the device determines that the intra prediction mode of the luminance component is a preset intra prediction mode, it can determine that the intra prediction mode of the chrominance component indicates using the luminance component of the current coding block to determine the predicted value of the chrominance component of the current coding block. The preset intra prediction mode is an intra prediction mode of the luminance component in a preset direction, and the preset direction includes but is not limited to the horizontal direction (for example: in the two-dimensional rectangular coordinate system XoY as Figure 1 shown, along the X-axis direction), the vertical direction (for example: in the two-dimensional rectangular coordinate system XoY as Figure 1 shown, along the negative Y-axis direction).

[0170] In this possible example, filtering the reference prediction block of the chrominance component of the current coding block includes: filtering the reference prediction block of the chrominance component of the current coding block using a third filter.

[0171] In this possible example, the third filter includes a filter for filtering the left boundary pixel region of the reference prediction block of the chrominance component and a filter for filtering the non-left boundary pixel region of the reference prediction block of the chrominance component.

[0172] In this possible example, the filter for filtering the left boundary pixel region of the reference prediction block of the chrominance component includes a third two-tap filter; the third two-tap filter includes:

[0173] P C (x, y) = (P′ C (2x, 2y) + P′ C (2x, 2y + 1) + 1) >> 1

[0174] where x and y are the coordinates of the pixel, and P′ c is the predicted sample of the pixel in the reference prediction block of the chrominance component, and P c is the predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0175] In this possible example, the filter for filtering the non-left boundary pixel region of the reference prediction block of the chrominance component includes a first six-tap filter; the first six-tap filter includes:

[0176]

[0177] Among them, x and y are the coordinates of the current pixel, and P' c is the predicted sample of the pixel in the reference prediction block of the chrominance component, and P c is the predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0178] In this possible example, determining the reference prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component includes: determining the reconstructed block of the luminance component of the current coding block according to the intra prediction mode of the luminance component; determining the reference prediction block of the chrominance component of the current coding block according to the reconstructed block of the luminance component of the current coding block.

[0179] Among them, the size of the reference prediction block of the chrominance component is the same as the size of the reconstructed block of the luminance component. For example, in the prediction process shown Figure 8 both the reconstructed block of the luminance component and the reference prediction block of the chrominance component are 8*8 pixel arrays.

[0180] In this possible example, determining the reference prediction block of the chrominance component of the current coding block according to the reconstructed block of the luminance component of the current coding block includes: determining a linear model for cross-component prediction using the reconstructed block of the luminance component of the current coding block; calculating the reconstructed block of the luminance component according to the linear model to obtain the reference prediction block of the chrominance component of the current coding block.

[0181] Among them, the linear model may be, for example, the linear model of the foregoing formula (1) or (2)(3).

[0182] In this possible example, determining the linear model for cross-component prediction using the reconstructed block of the luminance component of the current coding block includes: determining the reference pixels for calculating the linear model, and the reference pixels include at least one adjacent pixel of the current coding block; calculating the linear model according to the reference pixels.

[0183] Among them, the selection of the reference pixels for calculating the linear model can be extended to the adjacent pixels on the lower left side, left side, upper left side, upper side, and upper right side of the current coding block.

[0184] Optionally, if the current coding block is a partial image block in the current coding block, the device may select a linear model that adapts to the current coding block from multiple linear models. Specifically, a linear model that adapts to the current coding block may be selected according to the image characteristics. Since the coefficients of this linear model have not been determined yet, they still need to be calculated based on reference pixels. It can be seen that for the chrominance component prediction of the current coding block, the device can provide a more refined prediction mechanism relative to the coding block, achieving more refined image prediction.

[0185] In this possible example, determining the reference pixels for calculating the linear model includes: determining the reference pixels for calculating the linear model according to the available information of the reconstructed samples of the adjacent pixels of the current coding block and the intra prediction mode of the chrominance component.

[0186] Among them, the intra prediction mode of the chrominance component of the current coding block includes any one of TSCPM_T, TSCPM_L, MCPM_T, and MCPM_L. The available information specifically includes available on both sides and available on one side (for example: available on the left side and available on the right side). The following is a detailed description.

[0187] If the intra prediction mode of the chrominance component of the current coding block is TSCPM_T or MCPM_T, and the reconstructed samples of the upper adjacent pixels of the original pixel block corresponding to the current coding block and the reconstructed samples of the left adjacent pixels of the original pixel block corresponding to the current coding block are available, the reference adjacent pixels for calculating the coefficients of the linear model are 4 of the upper adjacent pixels of the original pixel block, as shown in (b) in Figure 6 shown.

[0188] If the intra prediction mode of the chrominance component of the current coding block is TSCPM_L or MCPM_L, and the reconstructed samples of the upper adjacent pixels of the original pixel block corresponding to the current coding block and the reconstructed samples of the left adjacent pixels of the original pixel block corresponding to the current coding block are available, the reference adjacent pixels for calculating the coefficients of the linear model are 4 of the left adjacent pixels of the original pixel block, as shown in (c) in Figure 6 shown.

[0189] It can be seen that in this example, the reference adjacent pixels for calculating the coefficients of the linear model can be flexibly set according to the availability of the reconstructed samples of the adjacent pixels and the intra prediction mode of the chrominance component.

[0190] In this possible example, determining the reference pixels for calculating the linear model includes: determining the reference pixels for calculating the linear model according to the rate-distortion cost-optimal intra prediction mode of the luminance component of the adjacent coding block of the current coding block.

[0191] Among them, the intra prediction mode with the optimal rate - distortion cost of the luminance component of the adjacent coding block may be the same as or different from the intra prediction mode with the optimal rate - distortion cost of the luminance component of the current coding block.

[0192] Step 130: Perform prediction correction on the prediction block of the chrominance component of the current coding block to obtain the corrected prediction block of the chrominance component of the current coding block.

[0193] In this possible example, the performing prediction correction on the prediction block of the chrominance component of the current coding block includes: determining a filter according to the chrominance component intra prediction mode; using the filter to perform prediction correction on the prediction block of the chrominance component of the current coding block.

[0194] In this possible example, the determining a filter according to the chrominance component intra prediction mode includes: when the chrominance component intra prediction mode is TSCPM_T or MCPM_T or the ordinary intra - vertical - type angular prediction mode, the filter is set to the first filter.

[0195] In this possible example, the first filter is used to filter the pixel region adjacent to the left boundary of the prediction block of the chrominance component of the current coding block and the pixel region of the prediction block of the chrominance component of the current coding block.

[0196] In this possible example, the first filter includes a first two - tap filter; the first two - tap filter includes:

[0197] P′(x, y) = f(x)·P(-1, y)+(1 - f(x))·P(x, y)

[0198] Where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P’(x, y) is the final predicted sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in the y - th row, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the pixel P(-1, y), and P(x, y) is the original predicted sample of the pixel (x, y).

[0199] For example, such as Figure 12BTaking the pixels in the prediction block of the chrominance component and the adjacent pixels on the left boundary in the shown 4×4 pixel array as an example, first, for pixel a and adjacent pixel 1 on the left boundary, a first two-tap filter is used for downsampling to form pixel A of the corrected prediction block of the chrominance component. Horizontally, for pixel b and adjacent pixel 1 on the left boundary, a first two-tap filter is used for downsampling to form pixel B of the corrected prediction block of the chrominance component. By analogy for other columns until pixel p and adjacent pixel 4 on the left boundary are used with the first two-tap filter for downsampling to form pixel P of the corrected prediction block of the chrominance component.

[0200] In this possible example, the horizontal filter coefficients are determined by a first parameter set, and the first parameter set includes the size of the prediction block of the chrominance component and the distance between pixel (x, y) and pixel P(−1, y).

[0201] Among them, the value of the above horizontal filter coefficients is related to the size of the chrominance component of the current coding block and the distance between the predicted pixel and the adjacent pixel on the left in the prediction block of the current chrominance component.

[0202] Specifically, the selection of the above filter coefficients is related to the size of the chrominance component. Different filter coefficient groups are divided according to the size of the prediction block of the chrominance component of the current coding block, and the corresponding filter coefficient group is selected according to the size of the prediction block of the current chrominance component. The selection of the above horizontal filter coefficients is related to the distance from the predicted pixel to the adjacent pixel on the left. The distance from the currently predicted pixel to the adjacent pixel on the left is used as the index value, and the corresponding filter coefficient is selected from the corresponding filter coefficient group. The intra-frame chrominance prediction filter coefficients are specifically shown in Table 1. It should be noted that all coefficients in the table can be amplified and shifted during the specific coding process to reduce the computational complexity.

[0203] Table 1 Intra-frame chrominance prediction filter coefficients

[0204]

[0205]

[0206] In addition, the filter coefficients of this technology can adopt the coefficient truncation method to reduce coefficient storage, that is, the filter coefficients of all pixels where the distance from the currently predicted pixel to the adjacent pixel on the left is greater than 10 are the same.

[0207] In this possible example, determining the filter according to the intra-frame prediction mode of the chrominance component includes: when the intra-frame prediction mode of the chrominance component is TSCPM_L or MCPM_L or the ordinary intra-frame horizontal angle prediction mode, the filter is set to the second filter.

[0208] In this possible example, the second filter is used to filter a pixel region adjacent to the upper side boundary of the prediction block of the chrominance component of the current coding block and the pixel region of the prediction block of the chrominance component of the current coding block.

[0209] In this possible example, the second filter includes a second two-tap filter; the second two-tap filter includes:

[0210] P′(x, y) = f(y)·P(x, -1) + (1 - f(y))·P(x, y)

[0211] where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P’(x, y) is the final predicted sample of the pixel (x, y) in the prediction block of the chrominance component of the current coding block, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper side boundary in column X, f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, -1), and P(x, y) is the original predicted sample of the pixel (x, y).

[0212] For example, as Figure 12C shown in the 4*4 pixel array, taking the pixels in the prediction block of the chrominance component and the pixels adjacent to the upper side boundary as an example. First, for pixel a and the adjacent pixel 1 to the upper side boundary, the second two-tap filter is used for downsampling to form pixel A in the corrected prediction block of the chrominance component. In the vertical direction, for pixel e and the adjacent pixel 1 to the upper side boundary, the second two-tap filter is used for downsampling to form pixel E in the corrected prediction block of the chrominance component. And so on for other columns until, for pixel p and the adjacent pixel 4 to the upper side boundary, the second two-tap filter is used for downsampling to form pixel P in the corrected prediction block of the chrominance component.

[0213] In this possible example, the vertical filtering coefficient is determined by a second parameter set, and the second parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(x, -1).

[0214] Among them, the value of the above vertical filtering coefficient is related to the size of the chrominance component of the current coding block and the distance between the predicted pixel and the left adjacent pixel in the prediction block of the current chrominance component.

[0215] Specifically, the selection of the above filtering coefficients is related to the size of the chrominance component. Different filter coefficient groups are divided according to the size of the prediction block of the chrominance component of the current coding block, and the corresponding filter coefficient group is selected according to the size of the prediction block of the current chrominance component. The selection of the above vertical filtering coefficients is related to the distance from the predicted pixel to the adjacent pixel above. The distance from the currently predicted pixel to the adjacent pixel above is used as the index value, and the corresponding filtering coefficient is selected from the corresponding filter coefficient group. The intra-frame chrominance prediction filtering coefficients are specifically shown in Table 1.

[0216] In this possible example, the determining the filter according to the intra-frame prediction mode of the chrominance component includes: when the intra-frame prediction mode of the chrominance component is the ordinary intra-frame non-angle prediction mode, the filter is set to the third filter.

[0217] In this possible example, the third filter is used to filter the pixel region adjacent to the left boundary of the prediction block of the chrominance component of the current coding block, the pixel region adjacent to the upper boundary of the prediction block of the chrominance component of the current coding block, and the pixel region of the prediction block of the chrominance component of the current coding block.

[0218] In this possible example, the third filter includes a first three-tap filter; the first three-tap filter includes:

[0219] P′(x, y) = f(x)·P(-1, y) + f(y)·P(x, -1) + (1 - f(x) - f(y))·P(x, y)

[0220] Where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P’(x, y) is the final predicted sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in row y, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary in column X, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the pixel P(-1, y), f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, -1), and P(x, y) is the original predicted sample of the pixel (x, y).

[0221] For example, such as Figure 12DTaking the pixels in the predicted block of the chrominance component, the adjacent pixels on the upper side boundary, and the adjacent pixels on the left side boundary in the 4×4 pixel array shown as an example. First, for pixel a, adjacent pixel 1 on the upper side boundary, and adjacent pixel 5 on the left side, a first three-tap filter is used for downsampling to form pixel A of the corrected predicted block of the chrominance component. In the vertical direction, for pixel e, adjacent pixel 1 on the upper side boundary, and adjacent pixel 6 on the left side, a first three-tap filter is used for downsampling to form pixel E of the corrected predicted block of the chrominance component. The same applies to other columns until, for pixel p, adjacent pixel 4 on the upper side boundary, and adjacent pixel 8 on the left side, a first three-tap filter is used for downsampling to form pixel P of the corrected predicted block of the chrominance component.

[0222] In this possible example, the horizontal filter coefficients are determined by a first parameter set, and the first parameter set includes the size of the predicted block of the chrominance component and the distance between pixel (x, y) and pixel P(−1, y);

[0223] The vertical filter coefficients are determined by a second parameter set, and the second parameter set includes the size of the predicted block of the chrominance component and the distance between pixel (x, y) and pixel P(x, −1).

[0224] Among them, the values of the above vertical filter coefficients and horizontal filter coefficients are related to the size of the chrominance component of the current coding block and the distance between the predicted pixel and the adjacent pixel on the left in the predicted block of the current chrominance component.

[0225] Specifically, the selection of the above filter coefficients is related to the size of the chrominance component. Different filter coefficient groups are divided according to the size of the predicted block of the chrominance component of the current coding block, and the corresponding filter coefficient group is selected according to the size of the predicted block of the current chrominance component. The selection of the above vertical filter coefficients is related to the distance from the predicted pixel to the adjacent pixel on the upper side. The distance from the currently predicted pixel to the adjacent pixel on the upper side is used as the index value, and the corresponding filter coefficient is selected from the corresponding filter coefficient group. The in-frame chrominance prediction filter coefficients are specifically shown in Table 1.

[0226] In addition, the filter coefficients of this technology can adopt a coefficient truncation method to reduce coefficient storage, that is, the filter coefficients of all pixels where the distance from the currently predicted pixel to the adjacent pixel on the upper side is greater than 10 are the same.

[0227] In specific implementation, after the corrected predicted block of the chrominance component of the current coding block is determined, the device can further calculate the reconstructed block of the chrominance component, and determine the reconstructed image block of the current coding block according to the reconstructed block of the chrominance component and the reconstructed block of the luminance component.

[0228] It can be seen that in the embodiments of the present application, compared with the prior art, the solution of the present application uses the spatial correlation between adjacent coding blocks and the current coding block to correct the prediction samples of the chrominance components of the current coding block, improving the prediction accuracy and coding efficiency.

[0229] In a possible example, the predicting and correcting the prediction block of the chrominance component of the current coding block includes: calculating a first rate-distortion cost of the current coding block without correction, and calculating a second rate-distortion cost of the current coding block with correction; determining that the first rate-distortion cost is greater than the second rate-distortion cost; and performing prediction correction on the prediction block of the chrominance component of the current coding block.

[0230] It can be seen that in this example, without increasing the number of rate-distortion cost calculations, there is no need to perform additional rate-distortion cost calculations, avoiding a large increase in computational complexity.

[0231] In a possible example, the predicting and correcting the prediction block of the chrominance component of the current coding block includes: calculating a first rate-distortion cost of the current coding block without correction, and calculating a second rate-distortion cost of the current coding block with correction; determining that the first rate-distortion cost is greater than the second rate-distortion cost, setting a chrominance correction flag bit to a first value, where the first value is used to indicate that the prediction correction needs to be performed; and performing prediction correction on the prediction block of the chrominance component of the current coding block.

[0232] In this possible example, the method further includes: determining that the first rate-distortion cost is less than or equal to the second rate-distortion cost, and setting the chrominance correction flag bit to a second value, where the second value is used to indicate that the prediction correction does not need to be performed.

[0233] In a specific implementation, the chrominance correction flag bit can be a single or multiple bits. For example, when it is a single bit, the first value can be 1 and the second value can be 0, which is not uniquely limited here.

[0234] In this possible example, the chrominance correction flag bit is shared with the luminance correction flag bit.

[0235] In this possible example, the chrominance correction flag bit is used independently.

[0236] In a possible example, the linear model applicable to the current coding block described above can be replaced with a linear model applicable row by row.

[0237] In a possible example, the flag bit representation in the existing protocol is increased to: each chrominance component uses a flag bit to indicate whether to use the prediction correction technique.

[0238] In a possible example, the prediction correction technique for the chrominance component of the present application may be used only for individual prediction modes in the chrominance component prediction mode.

[0239] In a possible example, it is possible to determine whether to cancel in advance or directly use the prediction correction technique according to the information of the prediction correction technique of the adjacent blocks of the current coding block.

[0240] And Figure 12A corresponding to Figure 13 is a schematic flowchart of an image coding method in an embodiment of the present application. This image coding method can be applied to Figure 9 the destination device 20 in the video decoding system 1 shown in Figure 11 or the video decoder 200 shown in Figure 13 The process shown takes the Figure 11 video encoder 200 shown as an example for illustration. As Figure 13 shown, the cross-component prediction method provided in the embodiment of the present application includes:

[0241] Step 210, parse the bitstream to determine the intra prediction mode of the chrominance component of the current decoded block.

[0242] Among them, the color format of the video of the bitstream includes but is not limited to 4:2:0, 4:2:2, etc.

[0243] In a specific implementation, the bitstream can obtain syntax elements through entropy decoding. These syntax elements are used to determine the intra prediction mode of the luminance component and the intra prediction mode of the chrominance component for predicting the current decoded block. Among them, the intra prediction mode of the luminance component is the optimal intra prediction mode among multiple intra prediction modes, and the multiple intra prediction modes are the intra prediction modes used for the intra prediction of the luminance component.

[0244] Step 220, determine the prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the chrominance component;

[0245] In this possible example, the determining the prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the chrominance component includes: determining reference pixels according to the available information of the reconstructed samples of the adjacent pixels of the current decoded block and the intra prediction mode of the chrominance component; and determining the prediction block of the chrominance component of the current decoded block according to the reference pixels.

[0246] In this possible example, determining a prediction block of a chrominance component of the current decoded block according to the intra prediction mode of the chrominance component includes: determining an intra prediction mode of a luminance component of the current decoded block; when the intra prediction mode of the chrominance component indicates that a reconstructed block of the luminance component of the current decoded block is used to determine a predicted value of the chrominance component of the current decoded block, determining a prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the luminance component.

[0247] In this possible example, determining a prediction block of a chrominance component of the current decoded block according to the intra prediction mode of the luminance component includes: determining a reference prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the luminance component; filtering the reference prediction block of the chrominance component of the current decoded block to obtain a prediction block of the chrominance component of the current decoded block.

[0248] In a specific implementation, when it is determined that the intra prediction mode of the luminance component is a preset intra prediction mode, the device may determine that the intra prediction mode of the chrominance component indicates using the luminance component of the current decoded block to determine the chrominance component of the current decoded block. The preset intra prediction mode is an intra prediction mode of a luminance component in a preset direction, and the preset direction includes but is not limited to a horizontal direction (for example: along the X-axis direction in the two-dimensional rectangular coordinate system XoY as Figure 1 described), a vertical direction (for example: along the negative Y-axis direction in the two-dimensional rectangular coordinate system XoY as Figure 1 shown).

[0249] In this possible example, filtering the reference prediction block of the chrominance component of the current decoded block includes: filtering the reference prediction block of the chrominance component of the current decoded block using a third filter.

[0250] In this possible example, the third filter includes a filter for filtering a left boundary pixel region of the reference prediction block of the chrominance component and a filter for filtering a non-left boundary pixel region of the reference prediction block of the chrominance component.

[0251] In this possible example, the filter for filtering the left boundary pixel region of the reference prediction block of the chrominance component includes a third two-tap filter; the third two-tap filter includes:

[0252] P C (x, y) = (P′ C (2x, 2y) + P′ C (2x, 2y + 1) + 1) >> 1

[0253] where x and y are coordinates of a pixel, and P′ cA predicted sample of a pixel in the reference prediction block of the chrominance component, P c Is a predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0254] In this possible example, the filter for filtering the non-left boundary pixel region of the reference prediction block of the chrominance component includes a first six-tap filter; the first six-tap filter includes:

[0255]

[0256] Where x and y are the coordinates of the current pixel, P′ c A predicted sample of a pixel in the reference prediction block of the chrominance component, P c Is a predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0257] In this possible example, determining the reference prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the luminance component includes: determining the reconstructed block of the luminance component of the current decoded block according to the intra prediction mode of the luminance component; determining the reference prediction block of the chrominance component of the current decoded block according to the reconstructed block of the luminance component of the current decoded block.

[0258] Wherein, the size of the reference prediction block of the chrominance component is the same as the size of the reconstructed block of the luminance component. For example, in the prediction process shown Figure 8 Both the reconstructed block of the luminance component and the reference prediction block of the chrominance component are 8*8 pixel arrays.

[0259] In this possible example, determining the reference prediction block of the chrominance component of the current decoded block according to the reconstructed block of the luminance component of the current decoded block includes: determining a linear model for cross-component prediction using the reconstructed block of the luminance component of the current decoded block; calculating the reconstructed block of the luminance component according to the linear model to obtain the reference prediction block of the chrominance component of the current decoded block.

[0260] Wherein, the linear model can be, for example, the linear model of the foregoing formula (1) or (2)(3).

[0261] In this possible example, determining the linear model for cross-component prediction using the reconstructed block of the luminance component of the current decoded block includes: determining reference pixels for calculating the linear model, the reference pixels including at least one adjacent pixel of the current decoded block; calculating the linear model according to the reference pixels.

[0262] Among them, the selection of the reference pixels for calculating the linear model can be extended to the adjacent pixels at the lower left side, left side, upper left side, upper side, and upper right side of the current decoding block.

[0263] In this possible example, determining the reference pixels for calculating the linear model includes: determining the reference pixels for calculating the linear model according to the available information of the reconstructed samples of the adjacent pixels of the current decoding block and the intra prediction mode of the chrominance component.

[0264] Among them, the intra prediction mode of the chrominance component of the current decoding block includes any one of TSCPM_T, TSCPM_L, MCPM_T, and MCPM_L. The available information specifically includes available on both sides and available on one side (for example: available on the left side and available on the right side). It can be seen that in this example, the reference adjacent pixels for calculating the coefficients of the linear model can be flexibly set according to the availability of the reconstructed samples of the adjacent pixels and the intra prediction mode of the chrominance component.

[0265] In this possible example, determining the reference pixels for calculating the linear model includes: determining the reference pixels for calculating the linear model according to the rate-distortion cost-optimal intra prediction mode of the luminance component of the adjacent decoding block of the current decoding block. Among them, the rate-distortion cost-optimal intra prediction mode of the luminance component of the adjacent decoding block may be the same as or different from the rate-distortion cost-optimal intra prediction mode of the luminance component of the current decoding block.

[0266] Step 230, perform prediction correction on the prediction block of the chrominance component of the current decoding block to obtain the corrected prediction block of the chrominance component of the current decoding block.

[0267] In this possible example, performing prediction correction on the prediction block of the chrominance component of the current decoding block includes: determining a filter according to the intra prediction mode of the chrominance component; using the filter to perform prediction correction on the prediction block of the chrominance component of the current decoding block.

[0268] Among them, the filtering direction of the filter is orthogonal to the direction of the adjacent pixels used to calculate the linear model by the intra prediction mode of the chrominance component relative to the current coding block, and can comprehensively predict the prediction samples of the chrominance component of each pixel based on the correlation of the boundary adjacent pixels in the orthogonal direction.

[0269] In this possible example, determining the filter according to the intra prediction mode of the chrominance component includes: when the intra prediction mode of the chrominance component is TSCPM_T or MCPM_T or the ordinary intra vertical class angle prediction mode, the filter is set to the first filter.

[0270] In this possible example, the first filter is used to filter a pixel region adjacent to the left boundary of the prediction block of the chrominance component of the current decoded block and the pixel region of the prediction block of the chrominance component of the current decoded block.

[0271] In this possible example, the first filter includes a first two-tap filter; the first two-tap filter includes:

[0272] P′(x, y) = f(x)·P(−1, y) + (1 − f(x))·P(x, y)

[0273] where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current decoded block, the value of y does not exceed the value range of the height of the current decoded block, P′(x, y) is the final predicted sample of the pixel (x, y) of the prediction block of the chrominance component of the current decoded block, P(−1, y) is the reconstructed sample of the pixel adjacent to the left boundary located in row y, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the pixel P(−1, y), and P(x, y) is the original predicted sample of the pixel (x, y).

[0274] In this possible example, the horizontal filtering coefficient is determined by a first parameter set, and the first parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(−1, y).

[0275] In this possible example, determining the filter according to the chrominance component intra prediction mode includes: when the chrominance component intra prediction mode is TSCPM_L or MCPM_L or the ordinary intra horizontal class angle prediction mode, the filter is set to a second filter.

[0276] In this possible example, the second filter is used to filter a pixel region adjacent to the upper boundary of the prediction block of the chrominance component of the current decoded block and the pixel region of the prediction block of the chrominance component of the current decoded block.

[0277] In this possible example, the second filter includes a second two-tap filter; the second two-tap filter includes:

[0278] P′(x, y) = f(y)·P(x, −1) + (1 − f(y))·P(x, y)

[0279] Among them, x and y are the coordinates of the current pixel. The value of x does not exceed the value range of the width of the current coding block, and the value of y does not exceed the value range of the height of the current coding block. P'(x, y) is the final predicted sample of the pixel (x, y) in the prediction block of the chrominance component of the current coding block. P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary in column X. f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, -1). P(x, y) is the original predicted sample of the pixel (x, y).

[0280] In this possible example, the vertical filtering coefficient is determined by a second parameter set, and the second parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(x, -1).

[0281] Among them, the value of the above vertical filtering coefficient is related to the size of the chrominance component of the current decoding block and the distance between the predicted pixel and the left adjacent pixel in the prediction block of the current chrominance component.

[0282] Specifically, the selection of the above filtering coefficient is related to the size of the chrominance component. It is divided into different filter coefficient groups according to the size of the prediction block of the chrominance component of the current decoding block, and the corresponding filter coefficient group is selected according to the size of the prediction block of the current chrominance component. The selection of the above vertical filtering coefficient is related to the distance from the currently predicted pixel to the upper adjacent pixel. The distance from the currently predicted pixel to the upper adjacent pixel is used as the index value, and the corresponding filtering coefficient is selected from the corresponding filter coefficient group. The intra-frame chrominance prediction filtering coefficients are specifically shown in Table 1.

[0283] In addition, the filter coefficients of this technology can adopt the coefficient truncation method to reduce coefficient storage, that is, the filtering coefficients of all pixels where the distance from the currently predicted pixel to the upper adjacent pixel is greater than 10 are the same.

[0284] In specific implementation, after the prediction block of the chrominance component of the current decoding block is determined, the device can further calculate the reconstructed block of the chrominance component, and determine the reconstructed image of the current decoding block according to the reconstructed block of the chrominance component and the reconstructed block of the luminance component.

[0285] In this possible example, the determining the filter according to the intra-frame prediction mode of the chrominance component includes: when the intra-frame prediction mode of the chrominance component is the ordinary intra-frame non-angle prediction mode, the filter is set as the third filter.

[0286] In this possible example, the third filter is used to filter the pixel region adjacent to the left boundary of the prediction block of the chrominance component of the current decoding block, the pixel region adjacent to the upper boundary of the prediction block of the chrominance component of the current decoding block, and the pixel region of the prediction block of the chrominance component of the current decoding block.

[0287] In this possible example, the third filter includes a first three-tap filter;

[0288] The first three-tap filter includes:

[0289] P′(x, y) = f(x)·P(−1, y) + f(y)·P(x, −1) + (1 − f(x) − f(y))·P(x, y)

[0290] where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P′(x, y) is the final predicted sample of the pixel (x, y) of the predicted block of the chrominance component of the current coding block, P(−1, y) is the reconstructed sample of the pixel adjacent to the left boundary in row y, P(x, −1) is the reconstructed sample of the pixel adjacent to the upper boundary in column x, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the pixel P(−1, y), f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, −1), and P(x, y) is the original predicted sample of the pixel (x, y).

[0291] In this possible example, the horizontal filtering coefficient is determined by a first parameter set, and the first parameter set includes the size of the predicted block of the chrominance component and the distance between the pixel (x, y) and the pixel P(−1, y);

[0292] The vertical filtering coefficient is determined by a second parameter set, and the second parameter set includes the size of the predicted block of the chrominance component and the distance between the pixel (x, y) and the pixel P(x, −1).

[0293] It can be seen that in the embodiments of the present application, compared with the prior art, in the intra prediction mode of the chrominance component, the present application scheme uses the spatial correlation between adjacent coding blocks and the current coding block to correct the predicted sample of the chrominance component of the current coding block, improving the prediction accuracy and decoding efficiency.

[0294] In a possible example, the predicting and correcting the predicted block of the chrominance component of the current decoded block includes: parsing the code stream to obtain a chrominance correction flag bit; determining that the value of the chrominance correction flag bit is a first value, where the first value is used to indicate that a filter is used for the predicting and correcting; and performing the predicting and correcting on the predicted block of the chrominance component of the current decoded block. It can be seen that in this example, the predicting and correcting is directly indicated by the flag bit.

[0295] In this possible example, the method further includes: determining that the value of the chrominance correction flag bit is a second value, where the second value is used to indicate that a filter is not used for the predicting and correcting.

[0296] In this possible example, the chroma correction flag bit is shared with the luminance correction identification bit, without adding extra identification bits, thus saving the transmission bitstream.

[0297] In this possible example, the chroma correction identification bit is used independently, which indicates more clearly and efficiently.

[0298] The proposed technology is implemented on the AVS reference software HPM6.0, and a 1-second sequence test is conducted on the all intra mode and random access mode under the general test conditions and video sequences. The specific performance is shown in Tables 2 and 3.

[0299] Table 2 All Intra Test Results

[0300]

[0301] Table 3 Random Access Test Results

[0302]

[0303] As can be seen from Tables 2 and 3, there are obvious performance gains on average for the UV components of the test sequences. Under the AI test conditions, the average coding performance of the U component is improved by 0.71%, and under the RA test conditions, the average coding performance of the V component is improved by 1.35%.

[0304] The embodiment of the present application provides an image coding device, which can be a video decoder or a video encoder. Specifically, the image coding device is used to execute the steps performed by the video decoder in the above decoding method. The image coding device provided by the embodiment of the present application may include modules corresponding to the respective steps.

[0305] The embodiment of the present application can divide the functional modules of the image coding device according to the above method examples. For example, each functional module can be divided corresponding to each function, or two or more functions can be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. The division of modules in the embodiment of the present application is illustrative, only a logical function division, and there may be other division methods in actual implementation.

[0306] In the case of dividing each functional module corresponding to each function, Figure 14 shows a possible structural schematic diagram of the image coding device involved in the above embodiment. As Figure 14 shown, the image coding device 14 includes a division unit 140, a determination unit 141, and a correction unit 142.

[0307] A dividing unit 140, configured to divide an image and determine an intra prediction mode of a chrominance component of a current coding block;

[0308] A determining unit 141, configured to determine a prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component;

[0309] A correcting unit 142, configured to perform prediction correction on the prediction block of the chrominance component of the current coding block to obtain a corrected prediction block of the chrominance component of the current coding block.

[0310] In a possible example, in terms of performing prediction correction on the prediction block of the chrominance component of the current coding block, the correcting unit 142 is specifically configured to determine a filter according to the intra prediction mode of the chrominance component; and use the filter to perform prediction correction on the prediction block of the chrominance component of the current coding block.

[0311] In a possible example, in terms of determining the filter according to the intra prediction mode of the chrominance component, the correcting unit 142 is specifically configured to set the filter to a first filter when the intra prediction mode of the chrominance component is a two-step cross-component prediction mode TSCPM_T or a multiple cross-component prediction mode MCPM_T or a normal intra vertical class angle prediction mode.

[0312] In a possible example, the first filter is configured to filter a pixel region adjacent to a left boundary of the prediction block of the chrominance component of the current coding block and a pixel region of the prediction block of the chrominance component of the current coding block.

[0313] In a possible example, the first filter includes a first two-tap filter;

[0314] The first two-tap filter includes:

[0315] P′(x, y) = f(x)·P(-1, y)+(1 - f(x))·P(x, y)

[0316] where x and y are coordinates of a current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P′(x, y) is a final prediction sample of a pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(-1, y) is a reconstructed sample of a pixel adjacent to the left boundary located in the y row, f(x) is a horizontal filtering coefficient of the pixel (x, y) with reference to the pixel P(-1, y), and P(x, y) is an original prediction sample of the pixel (x, y).

[0317] In this possible example, the horizontal filtering coefficient is determined by a first parameter set, and the first parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(-1, y).

[0318] In this possible example, in terms of determining the filter according to the intra prediction mode of the chrominance component, the correction unit 142 is specifically configured to, when the intra prediction mode of the chrominance component is TSCPM_L or MCPM_L or the ordinary intra horizontal angle prediction mode, set the filter to a second filter.

[0319] In this possible example, the second filter is used to filter the pixel region adjacent to the upper side boundary of the prediction block of the chrominance component of the current coding block and the pixel region of the prediction block of the chrominance component of the current coding block.

[0320] In this possible example, the second filter includes a second two-tap filter;

[0321] The second two-tap filter includes:

[0322] P′(x, y) = f(y)·P(x, -1) + (1 - f(y))·P(x, y)

[0323] Where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P’(x, y) is the final predicted sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper side boundary located in column X, f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, -1), and P(x, y) is the original predicted sample of the pixel (x, y).

[0324] In this possible example, the vertical filtering coefficient is determined by a second parameter set, and the second parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(x, -1).

[0325] In this possible example, in terms of determining the filter according to the intra prediction mode of the chrominance component, the correction unit 142 is specifically configured to, when the intra prediction mode of the chrominance component is the ordinary intra non-angle prediction mode, set the filter to a third filter.

[0326] In this possible example, the third filter is used to filter a pixel region adjacent to the left boundary of the prediction block of the chrominance component of the current coding block, a pixel region adjacent to the upper boundary of the prediction block of the chrominance component of the current coding block, and the pixel region of the prediction block of the chrominance component of the current coding block.

[0327] In this possible example, the third filter includes a first three-tap filter;

[0328] The first three-tap filter includes:

[0329] P′(x, y) = f(x)·P(-1, y) + f(y)·P(x, -1) + (1 - f(x) - f(y))·P(x, y)

[0330] where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P’(x, y) is the final predicted sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in row y, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary in column X, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the pixel P(-1, y), f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, -1), and P(x, y) is the original predicted sample of the pixel (x, y).

[0331] In this possible example, the horizontal filtering coefficient is determined by a first parameter set, and the first parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(-1, y);

[0332] The vertical filtering coefficient is determined by a second parameter set, and the second parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(x, -1).

[0333] In this possible example, in terms of predicting and correcting the prediction block of the chrominance component of the current coding block, the correction unit 142 is specifically configured to calculate a first rate-distortion cost of the current coding block without correction, and calculate a second rate-distortion cost of the current coding block with correction; and determine that the first rate-distortion cost is greater than the second rate-distortion cost; and perform prediction correction on the prediction block of the chrominance component of the current coding block.

[0334] In this possible example, in terms of predicting and correcting the prediction block of the chrominance component of the current coding block, the correction unit 142 is specifically configured to calculate a first rate-distortion cost of the current coding block without correction, and calculate a second rate-distortion cost of the current coding block with correction; and determine that the first rate-distortion cost is greater than the second rate-distortion cost, set a chrominance correction flag bit to a first value, where the first value is used to indicate that the prediction correction needs to be performed; and perform prediction correction on the prediction block of the chrominance component of the current coding block.

[0335] In this possible example, the determination unit 141 is further configured to determine that the first rate-distortion cost is less than or equal to the second rate-distortion cost, and set the chrominance correction flag bit to a second value, where the second value is used to indicate that the prediction correction does not need to be performed.

[0336] In this possible example, the chrominance correction flag bit is shared with the luminance correction flag bit.

[0337] In this possible example, the chrominance correction flag bit is used independently.

[0338] In this possible example, in terms of determining the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component, the determination unit 141 is specifically configured to determine the intra prediction mode of the luminance component of the current coding block; and when the intra prediction mode of the chrominance component indicates using the luminance component of the current coding block to determine the predicted value of the chrominance component of the current coding block, determine the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component.

[0339] In this possible example, in terms of determining the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component, the determination unit 141 is specifically configured to determine a reference prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component; and filter the reference prediction block of the chrominance component of the current coding block to obtain the prediction block of the chrominance component of the current coding block.

[0340] In this possible example, in terms of filtering the reference prediction block of the chrominance component of the current coding block, the determination unit 141 is specifically configured to filter the reference prediction block of the chrominance component of the current coding block using a third filter.

[0341] In this possible example, the third filter includes a filter for filtering the left boundary pixel region of the reference prediction block of the chrominance component and a filter for filtering the non-left boundary pixel region of the reference prediction block of the chrominance component.

[0342] In this possible example, the filter for filtering the left boundary pixel region of the reference prediction block of the chrominance component includes a third two-tap filter;

[0343] The third two-tap filter includes:

[0344] P C (x, y) = (P′ C (2x, 2y) + P′ C (2x, 2y + 1) + 1) >> 1

[0345] where x and y are the coordinates of the pixel, and P′ c is the predicted sample of the pixel in the reference prediction block of the chrominance component, and P c is the predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0346] In this possible example, the filter for filtering the non-left boundary pixel region of the reference prediction block of the chrominance component includes a first six-tap filter;

[0347] The first six-tap filter includes:

[0348]

[0349] where x and y are the coordinates of the current pixel, and P′ c is the predicted sample of the pixel in the reference prediction block of the chrominance component, and P c is the predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0350] In this possible example, in terms of determining the reference prediction block of the chrominance component of the current coding block according to the intra prediction mode of the luminance component, the determining unit 141 is specifically configured to determine the reconstructed block of the luminance component of the current coding block according to the intra prediction mode of the luminance component; and determine the reference prediction block of the chrominance component of the current coding block according to the reconstructed block of the luminance component of the current coding block.

[0351] In this possible example, in terms of determining the reference prediction block of the chrominance component of the current coding block according to the reconstructed block of the luminance component of the current coding block, the determining unit 141 is specifically configured to determine a linear model for cross-component prediction using the reconstructed block of the luminance component of the current coding block; and calculate the reconstructed block of the luminance component according to the linear model to obtain the reference prediction block of the chrominance component of the current coding block.

[0352] In this possible example, in terms of determining the linear model for cross-component prediction using the reconstructed block of the luminance component of the current coding block, the determining unit 141 is specifically configured to determine the reference pixels for calculating the linear model, where the reference pixels include at least one neighboring pixel of the current coding block; and calculate the linear model according to the reference pixels.

[0353] In this possible example, in terms of determining the reference pixels for calculating the linear model, the determining unit 141 is specifically configured to determine the reference pixels for calculating the linear model according to the available information of the reconstructed samples of the neighboring pixels of the current coding block and the intra prediction mode of the chrominance component.

[0354] In this possible example, in terms of determining the reference pixels for calculating the linear model, the determining unit 141 is specifically configured to determine the reference pixels for calculating the linear model according to the rate-distortion cost-optimal intra prediction mode of the luminance component of the neighboring coding blocks of the current coding block.

[0355] In this possible example, in terms of determining the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component, the determining unit 141 is specifically configured to determine the reference pixels according to the available information of the reconstructed samples of the neighboring pixels of the current coding block and the intra prediction mode of the chrominance component; and determine the prediction block of the chrominance component of the current coding block according to the reference pixels.

[0356] All relevant contents of each step involved in the above method embodiments can be cited in the function descriptions of the corresponding functional modules, and will not be repeated here. Of course, the image coding device provided in the embodiments of the present application includes but is not limited to the above modules. For example, the image coding device may further include a storage unit 143. The storage unit 143 may be used to store the program code and data of the image coding device.

[0357] In the case of adopting an integrated unit, the structural schematic diagram of the image coding device provided in the embodiments of the present application is as Figure 15 shown. In Figure 15 it, the image coding device 15 includes: a processing module 150 and a communication module 151. The processing module 150 is used to control and manage the actions of the image coding device. For example, it executes the steps performed by the partitioning unit 140, the determining unit 141, and the correcting unit 142, and / or is used to execute other processes of the technologies described herein. The communication module 151 is used to support the interaction between the image coding device and other devices. As Figure 15As shown in the figure, the image encoding device may further include a storage module 152, which is used to store the program code and data of the image encoding device, for example, to store the content saved by the above storage unit 143.

[0358] Among them, the processing module 150 may be a processor or a controller. For example, it may be a Central Processing Unit (CPU), a general-purpose processor, a Digital Signal Processor (DSP), an ASIC, an FPGA, or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It can implement or execute various exemplary logic blocks, modules, and circuits described in connection with the disclosure of the present application. The processor may also be a combination that implements a computing function, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, and so on. The communication module 151 may be a transceiver, an RF circuit, or a communication interface, etc. The storage module 152 may be a memory.

[0359] Among them, all the relevant content of each scenario involved in the above method embodiments can be cited in the function descriptions of the corresponding functional modules, and will not be repeated here. Both the above image encoding device 14 and the image encoding device 15 can execute the above Figure 12A shown image encoding method. The image encoding device 14 and the image encoding device 15 may specifically be a video image encoding device or other devices with video encoding functions.

[0360] The present application also provides a video encoder, including a non-volatile storage medium and a central processor. The non-volatile storage medium stores an executable program, and the central processor is connected to the non-volatile storage medium and executes the executable program to implement the image encoding method of the embodiments of the present application.

[0361] The embodiments of the present application provide an image decoding device, which may be a video decoder or a video decoder. Specifically, the image decoding device is used to execute the steps performed by the video decoder in the above decoding method. The image decoding device provided by the embodiments of the present application may include modules corresponding to the respective steps.

[0362] The embodiments of the present application may divide the functional modules of the image decoding device according to the above method examples. For example, each functional module may be divided corresponding to each function, or two or more functions may be integrated into one processing module. The above integrated module may be implemented in the form of hardware or in the form of a software functional module. The division of modules in the embodiments of the present application is illustrative, and is only a logical function division. There may be other division methods in actual implementation.

[0363] In the case of dividing each functional module corresponding to each function, Figure 16 Fig. Figure 16 shows a possible structural schematic diagram of the image decoding device involved in the above embodiment. As Figure 16 shown, the image decoding device 16 includes a parsing unit 160, a determination unit 161, and a correction unit 162.

[0364] The parsing unit 160 is configured to parse the bitstream and determine the intra prediction mode of the chrominance component of the current decoding block;

[0365] The determination unit 161 is configured to determine the prediction block of the chrominance component of the current decoding block according to the intra prediction mode of the chrominance component;

[0366] The correction unit 162 is configured to perform prediction correction on the prediction block of the chrominance component of the current decoding block to obtain the corrected prediction block of the chrominance component of the current decoding block.

[0367] In a possible example, in terms of performing prediction correction on the prediction block of the chrominance component of the current decoding block, the correction unit 162 is specifically configured to: determine a filter according to the intra prediction mode of the chrominance component; and use the filter to perform prediction correction on the prediction block of the chrominance component of the current decoding block.

[0368] In a possible example, in terms of determining the filter according to the intra prediction mode of the chrominance component, the correction unit 162 is specifically configured to: when the intra prediction mode of the chrominance component is TSCPM_T or MCPM_T or the ordinary intra vertical class angle prediction mode, the filter is set to the first filter.

[0369] In a possible example, the first filter is used to filter the pixel region adjacent to the left boundary of the prediction block of the chrominance component of the current decoding block and the pixel region of the prediction block of the chrominance component of the current decoding block.

[0370] In a possible example, the first filter includes a first two-tap filter;

[0371] The first two-tap filter includes:

[0372] P′(x, y) = f(x)·P(-1, y) + (1 - f(x))·P(x, y)

[0373] Among them, x and y are the coordinates of the current pixel. The value of x does not exceed the value range of the width of the current decoding block, and the value of v does not exceed the value range of the height of the current decoding block. P'(x, y) is the final predicted sample of the pixel (x, y) in the prediction block of the chrominance component of the current decoding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in row y, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the pixel P(-1, y), and P(x, y) is the original predicted sample of the pixel (x, y).

[0374] In a possible example, the horizontal filtering coefficient is determined by a first parameter set, and the first parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(-1, y).

[0375] In a possible example, the determining the filter according to the intra-frame prediction mode of the chrominance component includes:

[0376] When the intra-frame prediction mode of the chrominance component is TSCPM_L or MCPM_L or the ordinary intra-frame horizontal angle prediction mode, the filter is set to a second filter.

[0377] In a possible example, the second filter is used to filter the pixel region adjacent to the upper side boundary of the prediction block of the chrominance component of the current decoding block and the pixel region of the prediction block of the chrominance component of the current decoding block.

[0378] In a possible example, the second filter includes a second two-tap filter;

[0379] The second two-tap filter includes:

[0380] P′(x, y) = f(y)·P(x, -1) + (1 - f(y))·P(x, y)

[0381] Among them, x and y are the coordinates of the current pixel. The value of x does not exceed the value range of the width of the current coding block, and the value of y does not exceed the value range of the height of the current coding block. P'(x, y) is the final predicted sample of the pixel (x, y) in the prediction block of the chrominance component of the current coding block, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper side boundary in column X, f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, -1), and P(x, y) is the original predicted sample of the pixel (x, y).

[0382] In a possible example, the vertical filtering coefficient is determined by a second parameter set, and the second parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(x, -1).

[0383] In a possible example, in terms of determining the filter according to the intra prediction mode of the chrominance component frame, the correction unit 162 is specifically configured to: when the intra prediction mode of the chrominance component frame is the ordinary intra non-angle prediction mode, the filter is set to the third filter.

[0384] In a possible example, the third filter is used to filter a pixel region adjacent to the left boundary of the prediction block of the chrominance component of the current decoded block, a pixel region adjacent to the upper boundary of the prediction block of the chrominance component of the current decoded block, and the pixel region of the prediction block of the chrominance component of the current decoded block.

[0385] In a possible example, the third filter includes a first three-tap filter;

[0386] The first three-tap filter includes:

[0387] P′(x, y) = f(x)·P(-1, y) + f(y)·P(x, -1) + (1 - f(x) - f(y))·P(x, y)

[0388] where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of v does not exceed the value range of the height of the current coding block, P’(x, y) is the final predicted sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary located in row y, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary located in column X, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the pixel P(-1, y), f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the pixel P(x, -1), and P(x, y) is the original predicted sample of the pixel (x, y).

[0389] In a possible example, the horizontal filtering coefficient is determined by a first parameter set, and the first parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(-1, y);

[0390] The vertical filtering coefficient is determined by a second parameter set, and the second parameter set includes the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel P(x, -1).

[0391] In a possible example, in terms of predicting and correcting the prediction block of the chrominance component of the current decoded block, the correction unit 162 is specifically configured to: parse the bitstream to obtain a chrominance correction flag; and determine that the value of the chrominance correction flag is a first value, where the first value is used to indicate that a filter is used for the prediction correction; and perform prediction correction on the prediction block of the chrominance component of the current decoded block.

[0392] In a possible example, the determination unit 161 is further configured to determine that the value of the chrominance correction flag is a second value, where the second value is used to indicate that a filter is not used for the prediction correction.

[0393] In a possible example, the chrominance correction flag shares the same bit with the luminance correction flag.

[0394] In a possible example, the chrominance correction flag is used independently.

[0395] In a possible example, in terms of determining the prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the chrominance component, the determination unit 161 is specifically configured to determine the intra prediction mode of the luminance component of the current decoded block; and when the intra prediction mode of the chrominance component indicates that the luminance component of the current decoded block is used to determine the predicted value of the chrominance component of the current decoded block, determine the prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the luminance component.

[0396] In a possible example, in terms of determining the prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the luminance component, the determination unit 161 is specifically configured to: determine the reference prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the luminance component; and filter the reference prediction block of the chrominance component of the current decoded block to obtain the prediction block of the chrominance component of the current decoded block.

[0397] In a possible example, in terms of filtering the reference prediction block of the chrominance component of the current decoded block, the determination unit 161 is specifically configured to: filter the reference prediction block of the chrominance component of the current decoded block using a third filter.

[0398] In a possible example, the third filter includes a filter for filtering the left boundary pixel region of the reference prediction block of the chrominance component and a filter for filtering the non-left boundary pixel region of the reference prediction block of the chrominance component.

[0399] In a possible example, the filter for filtering the left boundary pixel region of the reference prediction block of the chrominance component includes a third two-tap filter;

[0400] The third two-tap filter includes:

[0401] P C (x, y) = (P′ C (2x, 2y) + P′ C (2x, 2y + 1) + 1) >> 1

[0402] where x and y are the coordinates of the pixel, and P′ c is the predicted sample of the pixel in the reference prediction block of the chrominance component, and P c is the predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0403] In a possible example, the filter for filtering the non-left boundary pixel region of the reference prediction block of the chrominance component includes a first six-tap filter;

[0404] The first six-tap filter includes:

[0405]

[0406] where x and y are the coordinates of the current pixel, and P′ c is the predicted sample of the pixel in the reference prediction block of the chrominance component, and P c is the predicted sample of the chrominance component of the current pixel in the prediction block of the chrominance component.

[0407] In a possible example, in terms of determining the reference prediction block of the chrominance component of the current decoding block according to the intra prediction mode of the luminance component, the determining unit 161 is specifically configured to: determine the reconstructed block of the luminance component of the current decoding block according to the intra prediction mode of the luminance component; and determine the reference prediction block of the chrominance component of the current decoding block according to the reconstructed block of the luminance component of the current decoding block.

[0408] In a possible example, in terms of determining the reference prediction block of the chrominance component of the current decoding block according to the reconstructed block of the luminance component of the current decoding block, the determining unit 161 is specifically configured to: determine the linear model for cross-component prediction using the reconstructed block of the luminance component of the current decoding block; and calculate the reconstructed block of the luminance component according to the linear model to obtain the reference prediction block of the chrominance component of the current decoding block.

[0409] In a possible example, in terms of determining a linear model for performing cross-component prediction using the reconstructed block of the luminance component of the current decoded block, the determining unit 161 is specifically configured to: determine reference pixels for calculating the linear model, where the reference pixels include at least one adjacent pixel of the current decoded block; and calculate the linear model based on the reference pixels.

[0410] In a possible example, in terms of determining the reference pixels for calculating the linear model, the determining unit 161 is specifically configured to: determine the reference pixels for calculating the linear model according to the available information of the reconstructed samples of the adjacent pixels of the current decoded block and the intra prediction mode of the chrominance component.

[0411] In a possible example, in terms of determining the reference pixels for calculating the linear model, the determining unit 161 is specifically configured to: determine the reference pixels for calculating the linear model according to the rate-distortion cost-optimal intra prediction mode of the luminance component of the adjacent decoded block of the current decoded block.

[0412] In a possible example, in terms of determining the prediction block of the chrominance component of the current decoded block according to the intra prediction mode of the chrominance component, the determining unit 161 is specifically configured to: determine reference pixels according to the available information of the reconstructed samples of the adjacent pixels of the current decoded block and the intra prediction mode of the chrominance component; and determine the prediction block of the chrominance component of the current decoded block based on the reference pixels.

[0413] Wherein, all relevant contents of each step involved in the above method embodiments can be cited in the function descriptions of the corresponding functional modules, and will not be elaborated here. Of course, the image decoding device provided in the embodiments of the present application includes but is not limited to the above modules. For example, the image decoding device may further include a storage unit 163. The storage unit 163 may be used to store the program code and data of the image decoding device.

[0414] In the case of adopting an integrated unit, the structural schematic diagram of the image decoding device provided in the embodiments of the present application is as Figure 17 shown. In Figure 17 it, the image decoding device 17 includes: a processing module 170 and a communication module 171. The processing module 170 is used to control and manage the actions of the image decoding device. For example, it executes the steps performed by the parsing unit 160, the determining unit 161, and the correcting unit 162, and / or is used to execute other processes of the technologies described herein. The communication module 171 is used to support the interaction between the image decoding device and other devices. As Figure 17As shown in the figure, the image decoding device may further include a storage module 172, which is used to store the program code and data of the image decoding device, for example, to store the content saved by the above storage unit 163.

[0415] Among them, the processing module 170 may be a processor or a controller. For example, it may be a Central Processing Unit (CPU), a general-purpose processor, a Digital Signal Processor (DSP), an ASIC, an FPGA or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. It can implement or execute various exemplary logic blocks, modules and circuits described in combination with the disclosure of the present application. The processor may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, and so on. The communication module 171 may be a transceiver, an RF circuit or a communication interface, etc. The storage module 172 may be a memory.

[0416] Among them, all the relevant contents of each scenario involved in the above method embodiment can be cited in the function description of the corresponding functional module, and will not be repeated here. Both the above image decoding device 16 and the image decoding device 17 can execute the above Figure 13 shown image decoding method. The image decoding device 16 and the image decoding device 17 may specifically be a video image decoding device or other devices with video decoding functions.

[0417] The present application also provides a video decoder, including a non-volatile storage medium and a central processor. The non-volatile storage medium stores an executable program, and the central processor is connected to the non-volatile storage medium and executes the executable program to implement the image decoding method of the embodiments of the present application.

[0418] The present application also provides a terminal, which includes: one or more processors, a memory, and a communication interface. The memory and the communication interface are coupled to one or more processors; the memory is used to store computer program code, and the computer program code includes instructions. When one or more processors execute the instructions, the terminal executes the image encoding and / or image decoding method of the embodiments of the present application. Here, the terminal may be a video display device, a smart phone, a portable computer, and other devices that can process or play videos.

[0419] Another embodiment of the present application also provides a computer-readable storage medium, which includes one or more program codes. The one or more programs include instructions. When a processor in a decoding device executes the program code, the decoding device executes the image encoding method and the image decoding method of the embodiments of the present application.

[0420] In another embodiment of the present application, a computer program product is further provided. The computer program product includes computer-executable instructions stored in a computer-readable storage medium. At least one processor of the decoding device can read the computer-executable instructions from the computer-readable storage medium, and the execution of the computer-executable instructions by at least one processor enables the terminal to implement the image encoding method and the image decoding method of the embodiments of the present application.

[0421] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented using a software program, it can appear in the form of a computer program product in whole or in part. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are generated in whole or in part.

[0422] The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from a website, a computer, a server, or a data center to another website, computer, server, or data center by wire (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wirelessly (such as infrared, wireless, microwave, etc.).

[0423] The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or a data center that integrates one or more available media. The available medium can be a magnetic medium (such as a floppy disk, a hard disk, a magnetic tape), an optical medium (such as a DVD), or a semiconductor medium (such as a solid-state drive (SSD)).

[0424] From the description of the above embodiments, those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the above division of each functional module is used as an example. In actual applications, the above functions can be allocated to different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.

[0425] In several embodiments provided by this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection between each other can be through some interfaces. The indirect coupling or communication connection of the devices or units can be in electrical, mechanical or other forms.

[0426] The units described as separate components may or may not be physically separated. The components displayed as units may be one physical unit or multiple physical units, that is, they can be located in one place, or they can be distributed to multiple different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0427] In addition, in each embodiment of this application, each functional unit can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

[0428] If the above-mentioned integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiments of this application, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to enable a device (which can be a single-chip microcomputer, a chip, etc.) or a processor to execute all or part of the steps of the methods described in each embodiment of this application. The foregoing storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROM), random access memories (RAM), magnetic disks or optical discs that can store program codes.

[0429] As described above, it is only the specific implementation manner of this application, but the protection scope of this application is not limited thereto. Any change or replacement within the technical scope disclosed in this application should be covered by the protection scope of this application. Therefore, the protection scope of this application should be subject to the protection scope of the claims.

Claims

1. An image encoding method, characterized in that, Including: Dividing an image to determine the intra prediction mode of the chrominance component of the current coding block; Determining a prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component; Correcting the prediction block of the chrominance component of the current coding block to obtain a corrected prediction block of the chrominance component of the current coding block; Wherein, the correcting the prediction block of the chrominance component of the current coding block includes: Determining a filter according to the intra prediction mode of the chrominance component; Filtering the prediction block of the chrominance component of the current coding block by using the filter; The determining a filter according to the intra prediction mode of the chrominance component includes: When the intra prediction mode of the chrominance component is the two-step cross-component prediction mode TSCPM_T or the intra vertical class angle prediction mode, the filter is a first filter; or When the intra prediction mode of the chrominance component is TSCPM_L or the intra horizontal class angle prediction mode, the filter is a second filter; Wherein, the first filter includes a first two-tap filter; The first two-tap filter includes: P′(x, y) = f(x)·P(-1,y) + (1 - f(x))·P(x,y) Wherein, x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P’(x, y) is the final prediction sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in the y row, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(-1, y), and P(x, y) is the original prediction sample of the pixel (x, y); Wherein, the second filter includes a second two-tap filter; The second two-tap filter includes: P′(x, y) = f(y)·P(x,-1) + (1 - f(y))·P(x,y) Wherein, x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P’(x, y) is the final prediction sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary in the X column, f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(x, -1), and P(x, y) is the original prediction sample of the pixel (x, y).

2. The method according to claim 1, wherein The first filter is used to filter the pixel region adjacent to the left boundary of the chrominance component of the current coding block and the prediction value of the prediction block of the chrominance component of the current coding block.

3. The method according to claim 2, wherein The pixel region adjacent to the left boundary of the chrominance component of the current coding block includes chrominance reconstruction pixels adjacent to the left of the current coding block.

4. The method according to claim 1, wherein The filtering coefficient of the first filter is determined by looking up a table, in the look-up table, the filtering coefficient is indexed by the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel (-1, y).

5. The method according to claim 1, wherein The second filter is used to filter a pixel region adjacent to an upper boundary of a chrominance component of the current coding block and a prediction value of a prediction block of the chrominance component of the current coding block.

6. The method according to claim 5, characterized in that, The pixel region adjacent to the upper boundary of the chrominance component of the current coding block includes chrominance reconstruction pixels adjacent to the current coding block above.

7. The method according to claim 1, wherein Filter coefficients of the second filter are determined by looking up a look-up table, in which the filter coefficients are indexed by a size of the prediction block of the chrominance component and a distance between a pixel (x, y) and a pixel (x, -1).

8. The method according to claim 1, wherein The correcting of the prediction block of the chrominance component of the current coding block further includes: calculating a first rate-distortion cost of the current coding block without correction and calculating a second rate-distortion cost of the current coding block with correction; determining that the first rate-distortion cost is greater than the second rate-distortion cost, and setting a chrominance correction flag bit to a first value, where the first value is used to indicate that the correction needs to be performed; correcting the prediction block of the chrominance component of the current coding block.

9. The method according to claim 1, wherein The correcting of the prediction block of the chrominance component of the current coding block further includes: calculating a first rate-distortion cost of the current coding block without correction and calculating a second rate-distortion cost of the current coding block with correction; determining that the first rate-distortion cost is less than or equal to the second rate-distortion cost, and setting a chrominance correction flag bit to a second value, where the second value is used to indicate that the correction does not need to be performed.

10. The method according to claim 8 or 9, characterized in that The chrominance correction flag bit is shared with a luminance correction flag bit.

11. An image decoding method, characterized in that, including: analyzing a bitstream to determine an intra prediction mode of a chrominance component of a current decoding block; determining a prediction block of the chrominance component of the current decoding block according to the intra prediction mode of the chrominance component; correcting the prediction block of the chrominance component of the current decoding block to obtain a corrected prediction block of the chrominance component of the current decoding block; wherein the correcting of the prediction block of the chrominance component of the current decoding block includes: determining a filter according to the intra prediction mode of the chrominance component; filtering the prediction block of the chrominance component of the current decoding block by using the filter; The determining a filter according to the intra prediction mode of the chrominance component includes: when the intra prediction mode of the chrominance component is TSCPM_T or an intra vertical class angle prediction mode, the filter is a first filter; or when the intra prediction mode of the chrominance component is TSCPM_L or an intra horizontal class angle prediction mode, the filter is a second filter; wherein the first filter includes a first two-tap filter; The first two-tap filter includes: P′(x, y) = f(x)·P(-1,y)+(1 - f(x))·P(x,y) Where x and y are the coordinates of the current pixel, the value of x does not exceed the range of the width of the current decoding block, the value of y does not exceed the range of the height of the current decoding block, P'(x, y) is the final predicted sample of the pixel (x, y) in the prediction block of the chrominance component of the current decoding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in row y, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(-1, y), and P(x, y) is the original predicted sample of the pixel (x, y). Wherein, the second filter includes a second two-tap filter; The second two-tap filter includes: P′(x, y) = f(y)·P(x, -1)+(1 - f(y))·P(x, y) Where x and y are the coordinates of the current pixel, the value of x does not exceed the range of the width of the current decoding block, the value of y does not exceed the range of the height of the current decoding block, P'(x, y) is the final predicted sample of the pixel (x, y) in the prediction block of the chrominance component of the current decoding block, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary in column X, f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(x, -1), and P(x, y) is the original predicted sample of the pixel (x, y).

12. The method according to claim 11, characterized in that The first filter is used to filter the pixel region adjacent to the left boundary of the chrominance component of the current decoding block and the predicted value of the prediction block of the chrominance component of the current decoding block.

13. The method according to claim 12, characterized in that, The pixel region adjacent to the left boundary of the chrominance component of the current decoding block includes chrominance reconstruction pixels adjacent to the left of the current decoding block.

14. The method according to claim 11, wherein The filtering coefficient of the first filter is determined by a look-up table. In the look-up table, the filtering coefficient is indexed by the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel (-1, y).

15. The method according to claim 11, wherein The second filter is used to filter the pixel region adjacent to the upper boundary of the chrominance component of the current decoding block and the predicted value of the prediction block of the chrominance component of the current decoding block.

16. The method according to claim 15, characterized in that, The pixel region adjacent to the upper boundary of the chrominance component of the current decoding block includes chrominance reconstruction pixels adjacent to the upper of the current decoding block.

17. The method according to claim 11, wherein The filtering coefficient of the second filter is determined by a look-up table. In the look-up table, the filtering coefficient is indexed by the size of the prediction block of the chrominance component and the distance between the pixel (x, y) and the pixel (x, -1).

18. The method according to claim 11, characterized in that, The correction of the prediction block of the chrominance component of the current decoding block further includes: Parsing the code stream to obtain a chrominance correction flag bit; Determining that the value of the chrominance correction flag bit is a first value, and the first value is used to indicate using a filter for the correction; Performing the correction on the prediction block of the chrominance component of the current decoding block.

19. The method according to claim 18, characterized in that The correction of the prediction block of the chrominance component of the current decoding block further includes: Parsing the code stream to obtain a chrominance correction flag bit; Determining that the value of the chrominance correction flag bit is a second value, and the second value is used to indicate not using a filter for the correction.

20. The method according to claim 18 or 19, characterized in that, The chrominance correction flag bit shares the same use with the luminance correction identification bit.

21. An image encoding device, characterized in that, It includes: A division unit, configured to divide an image and determine the intra prediction mode of the chrominance component of the current coding block; A determination unit, configured to determine the prediction block of the chrominance component of the current coding block according to the intra prediction mode of the chrominance component; A correction unit, configured to correct the prediction block of the chrominance component of the current coding block to obtain the corrected prediction block of the chrominance component of the current coding block; Wherein, the correction unit corrects the prediction block of the chrominance component of the current coding block, including: Determining a filter according to the intra prediction mode of the chrominance component; Filtering the prediction block of the chrominance component of the current coding block by using the filter; The correction unit determines the filter according to the intra prediction mode of the chrominance component, including: When the intra prediction mode of the chrominance component is the two-step cross-component prediction mode TSCPM_T or the intra vertical class angle prediction mode, the filter is a first filter; or When the intra prediction mode of the chrominance component is TSCPM_L or the intra horizontal class angle prediction mode, the filter is a second filter; Wherein, the first filter includes a first two-tap filter; The first two-tap filter includes: P′(x, y) = f(x)·P(-1, y) + (1 - f(x))·P(x, y) Wherein, x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P′(x, y) is the final prediction sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in the y row, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(-1, y), and P(x, y) is the original prediction sample of the pixel (x, y); Wherein, the second filter includes a second two-tap filter; The second two-tap filter includes: P′(x, y) = f(y)·P(x, -1) + (1 - f(y))·P(x, y) Wherein, x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current coding block, the value of y does not exceed the value range of the height of the current coding block, P′(x, y) is the final prediction sample of the pixel (x, y) of the prediction block of the chrominance component of the current coding block, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary in the X column, f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(x, -1), and P(x, y) is the original prediction sample of the pixel (x, y).

22. An image decoding apparatus, characterized in that, It includes: A parsing unit, configured to parse the bitstream and determine the intra prediction mode of the chrominance component of the current decoding block; A determination unit, configured to determine the prediction block of the chrominance component of the current decoding block according to the intra prediction mode of the chrominance component; A correction unit, configured to correct the prediction block of the chrominance component of the current decoding block to obtain the corrected prediction block of the chrominance component of the current decoding block; Among them, the correction unit corrects the prediction block of the chrominance component of the current decoded block, including: Determining a filter according to the intra-frame prediction mode of the chrominance component; Filtering the prediction block of the chrominance component of the current decoded block by using the filter; The correction unit determines a filter according to the intra-frame prediction mode of the chrominance component, including: When the intra-frame prediction mode of the chrominance component is TSCPM_T or an intra-frame vertical class angle prediction mode, the filter is a first filter; or When the intra-frame prediction mode of the chrominance component is TSCPM_L or an intra-frame horizontal class angle prediction mode, the filter is a second filter; Among them, the first filter includes a first two-tap filter; The first two-tap filter includes: P′(x, y) = f(x)·P(-1, y)+(1 - f(x))·P(x, y) Where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current decoded block, the value of y does not exceed the value range of the height of the current decoded block, P′(x, y) is the final prediction sample of the pixel (x, y) of the prediction block of the chrominance component of the current decoded block, P(-1, y) is the reconstructed sample of the pixel adjacent to the left boundary in row y, f(x) is the horizontal filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(-1, y), and P(x, y) is the original prediction sample of the pixel (x, y); Among them, the second filter includes a second two-tap filter; The second two-tap filter includes: P′(x, y) = f(y)·P(x, -1)+(1 - f(y))·P(x, y) Where x and y are the coordinates of the current pixel, the value of x does not exceed the value range of the width of the current decoded block, the value of y does not exceed the value range of the height of the current decoded block, P′(x, y) is the final prediction sample of the pixel (x, y) of the prediction block of the chrominance component of the current decoded block, P(x, -1) is the reconstructed sample of the pixel adjacent to the upper boundary in column X, f(y) is the vertical filtering coefficient of the pixel (x, y) referring to the reconstructed sample P(x, -1), and P(x, y) is the original prediction sample of the pixel (x, y).

23. An encoder, comprising a non-volatile storage medium and a central processing unit, characterized in that, The non-volatile storage medium stores an executable program, the central processing unit is connected to the non-volatile storage medium, and when the central processing unit executes the executable program, the encoder executes the method according to any one of claims 1-10.

24. A decoder, comprising a non-volatile storage medium and a central processing unit, characterized in that, The non-volatile storage medium stores an executable program, the central processing unit is connected to the non-volatile storage medium, and when the central processing unit executes the executable program, the decoder executes the method according to any one of claims 11-20.

25. A terminal, characterized in that, The terminal includes: one or more processors, a memory, and a communication interface; the memory and the communication interface are connected to the one or more processors; the terminal communicates with other devices through the communication interface, and the memory is used to store computer program code, and the computer program code includes instructions, When the one or more processors execute the instructions, the terminal executes the method according to any one of claims 1-20.

26. A computer program product comprising instructions, characterized in that, When the computer program product runs on the terminal, the terminal is caused to execute the method according to any one of claims 1-20.

27. A computer-readable storage medium includes instructions, characterized in that, When the instructions run on the terminal, the terminal is caused to execute the method according to any one of claims 1-20.

Citation Information

Patent Citations

  • Simplified cross-component prediction

    CN110839153A