Method and apparatus for chroma intra prediction in video coding

By acquiring and mapping the initial intra prediction mode of the chroma component in video decoding, the problem of low efficiency of chroma intra prediction in the existing technology is solved, more efficient video compression and decompression is achieved, and image quality is ensured.

CN118540474APending Publication Date: 2024-08-23HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410182430.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2019-03-24
Filing Date
2020-03-24
Publication Date
2024-08-23

AI Technical Summary

Technical Problem

It is difficult for existing video decoding technology to improve the compression ratio without compromising image quality during the compression and decompression process, especially when network resources are limited, especially for inefficient processing of chroma intra prediction modes. question.

Method used

By obtaining the initial intra prediction mode of the chroma component, and using the lookup table for mapping, wide-angle mapping is performed to obtain the modified prediction mode, and then the prediction samples of the chroma component are determined to ensure the consistency of the chroma and luma intra prediction modes. property, optimizing the chroma intra prediction direction.

Benefits of technology

The efficiency and accuracy of chroma intra-frame prediction are improved, the number of LUT items is reduced, the decoding delay is reduced, and the compression ratio is improved while maintaining image quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118540474A
    Figure CN118540474A
Patent Text Reader

Abstract

The invention provides an apparatus and method for directional intra prediction of chroma components of an image. The method comprises the following steps: acquiring an initial intra-frame prediction mode of the chrominance component; and obtaining a chroma intra prediction mode (intra prediction C) from a lookup table (lookup table, LUT), using the initial intra prediction mode of the chroma component, and obtaining a chroma intra prediction mode (intra prediction C) from the lookup table (LUT, LUT). The chrominance component has different sub-sampling ratios in the horizontal direction and the vertical direction. The method further comprises the following steps of: performing wide-angle mapping on the chroma intra prediction mode (intra prediction mode C) to obtain a modified intra prediction mode C (intra prediction mode C), and performing wide-angle mapping on the modified intra prediction mode C (intra prediction mode C) to obtain a modified intra prediction mode C (intra prediction mode C), according to the modified intraPredModeC, an intraPredAngle parameter of the chrominance component is obtained, and according to the modified intraPredModeC, the intraPredAngle parameter of the chrominance component is obtained; and according to the IntraPredAngle parameter, obtaining a prediction sample of the chrominance component, and according to the IntraPredAngle parameter, obtaining a prediction sample of the chrominance component. The LUT is used to determine a chroma intra prediction mode according to the initial chroma intra prediction mode, the method providing a minimum number of entries in the LUT.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application. The application number of the original application is 202080006360.6, and the original application date is March 24, 2020. The entire contents of the original application are incorporated into this application by reference.

[0002] Cross-application of related applications

[0003] This application claims priority to U.S. Provisional Application No. 62 / 822,981, filed on March 24, 2019, the contents of which are incorporated herein by reference. Technical Field

[0004] Embodiments of the present application (invention) generally relate to the field of image processing, and more specifically, to various chroma intra-frame prediction methods in video decoding. Background Art

[0005] Video coding (video encoding and decoding) is widely used in digital video applications such as broadcast digital television, video transmission over the Internet and mobile networks, real-time conversation applications such as video chat, video conferencing, DVD and Blu-ray discs, video content acquisition and editing systems, and camcorders for security applications.

[0006] Even if a video is relatively short, a large amount of video data is required to describe it, which can cause difficulties when the data is to be sent or otherwise transmitted across a communication network with limited bandwidth capacity. Therefore, video data is often compressed before being sent across modern telecommunications networks. Since memory resources may be limited, the size of the video may also be an issue when storing the video on a storage device. Video compression devices typically use software and / or hardware on the source side to encode the video data before transmission or storage, thereby reducing the amount of data required to represent the digital video image. A video decompression device that decodes the video data then receives the compressed data on the destination side. With limited network resources and a growing demand for higher video quality, there is a need for improved compression and decompression techniques that increase the compression ratio with little sacrifice in image quality. Summary of the invention

[0007] The embodiments of the present application provide a coding and decoding device and method as described in the independent claims.

[0008] The above and other objects are achieved by the subject matter claimed in the independent claims. Other implementations are apparent from the dependent claims, the detailed description and the drawings.

[0009] According to a first aspect, the present invention relates to a method for directional intra-frame prediction of a chroma component of an image. The method comprises: obtaining an initial intra-frame prediction mode of the chroma component (e.g., mode X in process map422); using the initial intra-frame prediction mode of the chroma component, obtaining a chroma intra-frame prediction mode (intraPredModeC) (e.g., mode Y in process map422) from a lookup table (look up table, LUT), wherein the chroma component has different subsampling ratios in the horizontal direction and the vertical direction. The method further comprises: performing wide-angle mapping on the chroma intra-frame prediction mode (intraPredModeC) to obtain a modified intraPredModeC; according to the modified intraPredModeC, obtaining an intraPredAngle parameter of the chroma component; according to the intraPredAngle parameter, obtaining a prediction sample of the chroma component.

[0010] In an implementation of the first aspect, the method further includes:

[0011] – Get the value of luma intra prediction mode (intraPredModeY) from the bitstream;

[0012] The obtaining of the initial intra prediction mode of the chrominance component comprises:

[0013] -According to the value of the luma intra prediction mode (intraPredModeY), obtaining the initial intra prediction mode of the chroma component.

[0014] In an implementation manner of the first aspect, performing wide-angle mapping on the chroma intra prediction mode (intraPredModeC) to obtain a modified intraPredModeC includes:

[0015] Wide-angle mapping is performed on an original intra prediction mode (predModeIntra) to obtain a modified predModeIntra, wherein a value of the original predModeIntra is equal to a value of the chroma intra prediction mode (intraPredModeC).

[0016] In an implementation manner of the first aspect, the LUT (eg, Table 8-4) has 67 entries, and the index of the LUT is 0-66.

[0017] The method according to the first aspect of the present invention can be performed by the device according to the second aspect of the present invention. The device for performing directional intra-frame prediction on the chrominance component of an image includes an acquisition unit, an acquisition unit and a mapping unit. The acquisition unit is used to acquire the initial intra-frame prediction mode of the chrominance component. The acquisition unit is used to obtain a chrominance intra-frame prediction mode (intraPredModeC) from a lookup table (look up table, LUT) using the initial intra-frame prediction mode of the chrominance component, wherein the chrominance component has different subsampling ratios in the horizontal direction and the vertical direction. The mapping unit is used to perform wide-angle mapping on the chrominance intra-frame prediction mode (intraPredModeC) to obtain a modified intraPredModeC.

[0018] The acquisition unit is further used to: acquire the intraPredAngle parameter of the chrominance component according to the modified intraPredModeC; and acquire the predicted sample of the chrominance component according to the intraPredAngle parameter.

[0019] Other features and implementations of the method according to the second aspect of the invention directly depend on the features and implementations of the apparatus according to the first aspect of the invention.

[0020] According to a third aspect, the present invention relates to an apparatus for decoding a video stream, comprising a processor and a memory, wherein the memory stores instructions, and the instructions enable the processor to execute the method according to the first aspect.

[0021] According to a fourth aspect, the present invention relates to a video stream encoding device, comprising a processor and a memory, wherein the memory stores instructions, and the instructions enable the processor to execute the method according to the first aspect.

[0022] According to a fifth aspect, a computer-readable storage medium storing instructions is provided, wherein when the instructions are executed, one or more processors are caused to decode video data. The instructions cause the one or more processors to perform the method according to the first aspect or any possible embodiment of the first aspect.

[0023] According to a sixth aspect, the present invention relates to a computer program comprising a program code for performing, when run on a computer, the method according to the first aspect or any possible embodiment of the first aspect.

[0024] According to a seventh aspect, the present invention further provides an encoder, comprising a processing circuit for executing the method described above.

[0025] According to an eighth aspect, the present invention further provides a decoder, comprising a processing circuit for executing the method described above.

[0026] The embodiment of the present invention provides a method for determining the minimum number of entries in the LUT of the chroma intra prediction mode according to the initial chroma intra prediction mode. The initial chroma intra prediction mode may be equal to the initial luma intra prediction mode. The above is achieved by executing the order, that is, by mapping the chroma intra prediction mode to the luma mode executed before the wide-angle mapping.

[0027] The details of one or more embodiments are set forth in the accompanying drawings and the description below. Other features, objects, and advantages will be apparent from the description, drawings, and claims. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] The embodiments of the present invention will be described in detail below with reference to the following drawings, in which:

[0029] Figure 1A is a block diagram of an exemplary video decoding system for implementing an embodiment of the present invention;

[0030] Figure 1B is a block diagram of another exemplary video decoding system for implementing an embodiment of the present invention;

[0031] Figure 2 is a block diagram of an exemplary video encoder for implementing an embodiment of the present invention;

[0032] Figure 3 is a block diagram of an exemplary video decoder structure for implementing an embodiment of the present invention;

[0033] Figure 4 is a block diagram of an exemplary encoding device or decoding device;

[0034] Figure 5 is a block diagram of another exemplary encoding device or decoding device;

[0035] Figure 6 A diagram of angular intra prediction directions and associated intra prediction modes in VTM-4.0 and VVC draft specification version 4;

[0036] Figure 7 is a diagram representing the luma and chroma color planes of the YUV 4:2:0 and YUV 4:2:2 chroma formats;

[0037] Figure 8 An example of a case where IntraPredModeC is obtained from IntraPredModeY is shown, wherein IntraPredModeY is a wide-angle intra-frame prediction mode, and IntraPredModeC is a non-wide-angle intra-frame prediction mode;

[0038] Fig. 9An example of a case where IntraPredModeC is obtained from IntraPredModeY is shown, wherein IntraPredModeY is a non-wide-angle intra prediction mode, and IntraPredModeC is a non-wide-angle intra prediction mode;

[0039] Fig.10 An example of a case where IntraPredModeC is obtained from IntraPredModeY is shown, wherein IntraPredModeY is a non-wide-angle intra-frame prediction mode and IntraPredModeC is a wide-angle intra-frame prediction mode;

[0040] Fig.11 An example of a case where IntraPredModeC is obtained from IntraPredModeY using a prediction mode modification operation is shown, wherein IntraPredModeY is a non-wide-angle intra prediction mode and IntraPredModeC is a non-wide-angle intra prediction mode;

[0041] Fig. 12A An embodiment of the intra-frame prediction step 1200 of the chrominance component implemented by the present invention is shown;

[0042] Fig. 12B An embodiment of the intra-frame prediction step 1210 of the chrominance component implemented by the present invention is shown;

[0043] Fig.13 An embodiment of a method 1300 for intra-frame prediction of a chrominance component implemented by the present invention is shown;

[0044] Fig.14 An embodiment of an intra-frame prediction device 1400 for chrominance components implemented by the present invention is shown;

[0045] Fig.15 A block diagram of an exemplary structure of a content providing system 3100 for implementing a content distribution service;

[0046] Fig.16 A block diagram of an exemplary structure of a terminal device.

[0047] In the following, unless explicitly stated otherwise, identical reference signs refer to identical or at least functionally equivalent features. DETAILED DESCRIPTION

[0048] In the following description, reference is made to the accompanying drawings which form a part of the present invention, which show by way of illustration specific aspects of embodiments of the present invention or specific aspects in which embodiments of the present invention may be used. It should be understood that embodiments of the present invention may be used in other aspects and include structural or logical changes not depicted in the accompanying drawings. Therefore, the following detailed description is not to be construed as limiting, and the scope of the present invention is defined by the appended claims.

[0049] It is understood that the disclosure related to the described method is also applicable to the device or system corresponding to the method for performing the method, and vice versa. For example, if one or more specific method steps are described, the corresponding device may include one or more units, such as functional units, for performing the described one or more method steps (e.g., a unit that performs the one or more steps, or multiple units that each perform one or more of the multiple steps), even if such one or more units are not explicitly described or illustrated in the figure. On the other hand, for example, if a specific device is described in terms of one or more units (e.g., functional units), the corresponding method may include a step to perform the function of one or more units (e.g., a step that performs the function of the one or more units, or multiple steps that each perform the function of one or more of the multiple units), even if such one or more steps are not explicitly described or illustrated in the figure. In addition, it should be understood that unless otherwise specifically indicated, the features of the various exemplary embodiments and / or aspects described herein may be combined with each other.

[0050] Video decoding generally refers to the processing of a sequence of images that constitute a video or video sequence. In the field of video decoding, the terms "frame" or "picture / image" can be used as synonyms. Video decoding (or commonly referred to as decoding) includes two parts: video encoding and video decoding. Video encoding is performed on the source side, typically including processing (for example, by compression) the original video image to reduce the amount of data required to represent the video image (for more efficient storage and / or transmission). Video decoding is performed on the destination side, typically including inverse processing relative to the encoder to reconstruct the video image. The "decoding" of the video image (or commonly referred to as the image) involved in the embodiment should be understood as involving the "encoding" or "decoding" of the video image or the corresponding video sequence. The combination of the encoding part and the decoding part is also called CODEC (encoding and decoding).

[0051] In the case of lossless video coding, the original video image can be reconstructed, i.e., the reconstructed video image has the same quality as the original video image (assuming no transmission losses or other data loss during storage or transmission). In the case of lossy video coding, compression is further performed (e.g., by quantization) to reduce the amount of data representing the video image that cannot be fully reconstructed in the decoder, i.e., the reconstructed video image has a lower or poorer quality than the original video image.

[0052] Several video coding standards belong to "lossy hybrid video codecs" (i.e., 2D transform coding that combines spatial prediction and temporal prediction in the sample domain and applies quantization in the transform domain). Each image of a video sequence is usually divided into a set of non-overlapping blocks, and decoding is usually performed in units of blocks. In other words, in the encoder, the video is usually processed (i.e., encoded) in units of blocks (video blocks), for example, a prediction block is generated by spatial (intra-frame) prediction and / or temporal (inter-frame) prediction; the prediction block is subtracted from the current block (currently processed / to be processed block) to obtain a residual block; the residual block is transformed in the transform domain and quantized to reduce the amount of data to be transmitted (compressed), and in the decoder, the inverse processing part relative to the encoder is applied to the coded or compressed block to reconstruct the current block for representation. In addition, the processing loop of the encoder is the same as that of the decoder, so that both will produce the same prediction (e.g., intra-frame prediction and inter-frame prediction) and / or reconstruction to process (i.e., decode) subsequent blocks.

[0053] In the following examples, according to Figures 1A to 3 Video coding system 10 , video encoder 20 , and video decoder 30 are described.

[0054] Figure 1A 1 is an exemplary decoding system 10 that can utilize the techniques of the present application, for example, a video decoding system 10 (or simply a decoding system 10). The video encoder 20 (or simply an encoder 20) and the video decoder 30 (or simply a decoder 30) of the video decoding system 10 represent examples of devices that can be used to perform various techniques according to various examples described in the present application.

[0055] like Figure 1A As shown, the decoding system 10 includes a source device 12 , for example, for providing encoded image data 21 to a destination device 14 for decoding the encoded image data 21 .

[0056] The source device 12 includes an encoder 20 and may additionally or optionally include an image source 16 , a preprocessor (or preprocessing unit) 18 such as an image preprocessor 18 , and a communication interface or communication unit 22 .

[0057] The image source 16 may include or may be any type of image capture device, such as a camera for capturing real-world images, and / or any type of image generation device, such as a computer graphics processor for generating computer-animated images, or any other device for acquiring and / or providing real-world images, computer-generated images (e.g., screen content, virtual reality (VR) images), and / or any combination thereof (e.g., augmented reality (AR) images). The image source may be any type of memory (memory / storage) that stores any of the above images.

[0058] In distinction from the processing performed by the preprocessor 18 and the preprocessing unit 18 , the image or image data 17 may also be referred to as a raw image or raw image data 17 .

[0059] The preprocessor 18 is used to receive (raw) image data 17 and preprocess the image data 17 to obtain a preprocessed image 19 or preprocessed image data 19. The preprocessing performed by the preprocessor 18 may include trimming, color format conversion (e.g., from RGB to YCbCr), color correction or denoising, etc. It should be understood that the preprocessing unit 18 may be an optional component.

[0060] The video encoder 20 is used to receive the pre-processed image data 19 and provide the encoded image data 21 (hereinafter referred to as Figure 2 etc. for further description).

[0061] Communication interface 22 in source device 12 may be used to receive encoded image data 21 and send the encoded image data 21 (or any other processed version thereof) to another device, such as destination device 14 or any other device, via communication channel 13 for storage or direct reconstruction.

[0062] Destination device 14 includes a decoder 30 (eg, video decoder 30 ) and, in addition or alternatively, may include a communication interface or communication unit 28 , a post-processor 32 (or post-processing unit 32 ), and a display device 34 .

[0063] The communication interface 28 in the destination device 14 is used to receive the encoded image data 21 (or any other processed version) directly from the source device 12 or from any other source device such as a storage device, for example, the storage device is an encoded image data storage device, and provide the encoded image data 21 to the decoder 30.

[0064] Communication interface 22 and communication interface 28 may be used to send or receive encoded image data 21 or encoded data 13 via a direct communication link (e.g., a direct wired or wireless connection) between source device 12 and destination device 14, or via any type of network (e.g., a wired or wireless network or any combination thereof, or any type of private and public networks), or any combination thereof.

[0065] For example, the communication interface 22 may be used to encapsulate the encoded image data 21 into a suitable format such as a message, and / or use any type of transmission coding or processing to process the encoded image data for transmission over a communication link or a communication network.

[0066] For example, the communication interface 28 corresponding to the communication interface 22 may be used to receive the transmitted data and process the transmitted data using any type of corresponding transport decoding or processing and / or decapsulation to obtain the encoded image data 21 .

[0067] Both the communication interface 22 and the communication interface 28 can be configured as follows Figure 1A The unidirectional communication interface indicated by the arrow pointing from the source device 12 to the corresponding communication channel 13 of the destination device 14, or configured as a bidirectional communication interface, and can be used to send and receive messages, etc. to establish a connection, confirm and exchange any other information related to the communication link and / or data transmission such as encoded image data transmission, etc.

[0068] The decoder 30 is used to receive the encoded image data 21 and provide decoded image data 31 or decoded image 31 (hereinafter referred to as Figure 3 or Figure 5 Detailed description).

[0069] The post-processor 32 of the destination device 14 is used to post-process the decoded image data 31 (also referred to as reconstructed image data) (e.g., decoded image 31) to obtain post-processed image data 33 (e.g., post-processed image 33). For example, the post-processing performed by the post-processing unit 32 may include color format conversion (e.g., conversion from YCbCr to RGB), color matching, cropping or resampling, or any other processing for generating decoded image data 31 for display by a display device 34 or the like.

[0070] The display device 34 in the destination device 14 is used to receive the post-processed image data 33 to display the image to a user or viewer, etc. The display device 34 can be or include any type of display for displaying the reconstructed image, such as an integrated or external display or monitor. For example, the display can include a liquid crystal display (LCD), an organic light emitting diode (OLED) display, a plasma display, a projector, a micro LED display, a liquid crystal on silicon (LCoS), a digital light processor (DLP), or any other type of display.

[0071] although Figure 1A The source device 12 and the destination device 14 are described as separate devices, but the device embodiments may also include two devices or two functions, namely the source device 12 or the corresponding function and the destination device 14 or the corresponding function. In these embodiments, the source device 12 or the corresponding function and the destination device 14 or the corresponding function may be implemented using the same hardware and / or software or by separate hardware and / or software or any combination thereof.

[0072] According to the description, Figure 1A It will be apparent to a skilled person that the different units or functions shown and (accurately) divided in the source device 12 and / or the destination device 14 may vary depending on the actual device and application.

[0073] The encoder 20 (eg, the video encoder 20) or the decoder 30 (eg, the video decoder 30) or both may be configured to generate a plurality of Figure 1B The processing circuitry shown may be implemented, for example, one or more microprocessors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), discrete logic, hardware, video decoding dedicated processors, or any combination thereof. The encoder 20 may be implemented by processing circuitry 46 to embody the Figure 2 The encoder 30 may be implemented by processing circuit 46 to embody the various modules discussed in connection with the encoder 20 and / or any other encoder system or subsystem described herein. Figure 3The processing circuits may be used to perform various operations discussed later. Figure 5 As shown in , when the techniques are partially implemented in software, the device may store instructions for the software in a suitable non-transitory computer-readable storage medium, and may use one or more processors to execute the instructions in hardware to perform the techniques of the present invention. One of the video encoder 20 and the video decoder 30 may be integrated into a single device as part of a combined encoder / decoder (codec), such as Figure 1B shown.

[0074] Source device 12 and destination device 14 may include any of a variety of devices, including any type of handheld or fixed device, such as a notebook or laptop computer, a mobile phone, a smart phone, a tablet / tabletcomputer, a camera, a desktop computer, a set-top box, a television, a display device, a digital media player, a video game console, a video streaming device (such as a content service server or a content distribution server), a broadcast receiver device, a broadcast transmitter device, etc., and may not use or use any type of operating system. In some cases, source device 12 and destination device 14 may be equipped with components for wireless communication. Therefore, source device 12 and destination device 14 may be wireless communication devices.

[0075] In some cases, Figure 1A The video decoding system 10 shown is merely exemplary, and the techniques provided herein may be applicable to video decoding settings (e.g., video encoding or video decoding) that do not necessarily include any data communication between an encoding device and a decoding device. In other examples, data is retrieved from a local memory, sent over a network, and so on. A video encoding device may encode data and store the data in a memory, and / or a video decoding device may retrieve data from a memory and decode the data. In some examples, encoding and decoding are performed by devices that do not communicate with each other but only encode data to a memory and / or retrieve data from a memory and decode the data.

[0076] For ease of description, this document describes embodiments of the present invention with reference to the High-Efficiency Video Coding (HEVC) or Versatile Video Coding (VVC) reference software or next-generation video coding standards developed by the Joint Collaboration Team on Video Coding (JCT-VC) of the ITU-T Video Coding Experts Group (VCEG) and the ISO / IEC Motion Picture Experts Group (MPEG). Those skilled in the art should understand that embodiments of the present invention are not limited to HEVC or VVC.

[0077] Encoders and encoding methods

[0078] Figure 2 FIG. 2 is a schematic block diagram of an exemplary video encoder 20 for implementing the technology of the present application. Figure 2 In the example of , the video encoder 20 includes an input terminal 201 (or an input interface 201), a residual calculation unit 204, a transform processing unit 206, a quantization unit 208, an inverse quantization unit 210 and an inverse transform processing unit 212, a reconstruction unit 214, a loop filter unit 220, a decoded picture buffer (DPB) 230, a mode selection unit 260, an entropy coding unit 270 and an output terminal 272 (or an output interface 272). The mode selection unit 260 may include an inter-frame prediction unit 244, an intra-frame prediction unit 254 and a segmentation unit 262. The inter-frame prediction unit 244 may include a motion estimation unit and a motion compensation unit (not shown). Figure 2 The illustrated video encoder 20 may also be referred to as a hybrid video encoder or a hybrid video codec-based video encoder.

[0079] The residual calculation unit 204, the transform processing unit 206, the quantization unit 208, and the mode selection unit 260 may constitute a forward signal path of the encoder 20, while the inverse quantization unit 210, the inverse transform processing unit 212, the reconstruction unit 214, the buffer 216, the loop filter 220, the decoded picture buffer (DPB) 230, the inter-frame prediction unit 244, and the intra-frame prediction unit 254 may constitute a reverse signal path of the video encoder 20. The reverse signal path of the video encoder 20 is similar to that of the decoder (see Figure 3The inverse quantization unit 210, the inverse transform processing unit 212, the reconstruction unit 214, the loop filter 220, the decoded picture buffer (DPB) 230, the inter-frame prediction unit 244 and the intra-frame prediction unit 254 also constitute a "built-in decoder" of the video encoder 20.

[0080] Images and Image Segmentation (Images and Blocks)

[0081] The encoder 20 may be used to receive, via an input 201 or the like, an image 17 (or image data 17), for example, an image in a sequence of images forming a video or a video sequence. The received image or image data may also be a pre-processed image 19 (or pre-processed image data 19). For simplicity, the following description uses image 17. Image 17 may also be referred to as a current image or an image to be decoded (particularly when the current image is distinguished from other images in video decoding, such as previously encoded images and / or decoded images in the same video sequence, i.e., a video sequence that also includes the current image).

[0082] A (digital) image is or may be a two-dimensional array or matrix of samples with intensity values. The samples in the array may also be referred to as pixels (a short form of picture elements). The number of samples in the horizontal and vertical directions (or axes) of the array or image defines the size and / or resolution of the image. To represent color, three color components are usually used, i.e., the image may be represented as or include three sample arrays. In the RBG format or color space, the image includes corresponding arrays of red, green and blue samples. However, in video decoding, each pixel is usually represented in a luminance and chrominance format or in a color space, for example, YCbCr, including a luminance component represented by Y (sometimes also represented by L) and two chrominance components represented by Cb and Cr. The luminance component Y represents the brightness or grayscale intensity (for example, as in a grayscale image), and the two chrominance components Cb and Cr represent the chrominance or color information components. Accordingly, an image in the YCbCr format includes a luminance sample array of luminance sample values ​​(Y) and two chrominance sample arrays of chrominance values ​​(Cb and Cr). An image in RGB format can be converted to YCbCr format and vice versa, a process also referred to as color conversion or conversion. If the image is monochrome, the image may include only a luma sample array. Accordingly, for example, the image may be a luma sample array in monochrome format or a luma sample array and two corresponding chroma sample arrays in 4:2:0, 4:2:2 and 4:4:4 color formats.

[0083] In one embodiment, the video encoder 20 may include an image segmentation unit ( Figure 2203) for partitioning the image 17 into a plurality of (usually non-overlapping) image blocks 203. These blocks may also be referred to as root blocks, macroblocks (H.264 / AVC) or coding tree blocks (CTB), or coding tree units (CTU) (H.265 / HEVC and VVC). The partitioning unit may be used to use the same block size for all images in a video sequence and a corresponding grid of defined block sizes, or to change the block size between images or subsets or groups of images, and to partition each image into corresponding blocks.

[0084] In another embodiment, the video encoder may be configured to directly receive a block 203 of the image 17, for example, one, several or all blocks constituting the image 17. The image block 203 may also be referred to as a current image block or an image block to be decoded.

[0085] Like the image 17, the image block 203 is also or can be considered as a two-dimensional array or matrix of samples with intensity values ​​(sample values), but the size of the image block 203 is smaller than that of the image 17. In other words, for example, the block 203 may include, for example, one sample array (e.g., a luminance array in the case of the black and white image 17, or a luminance or chrominance array in the case of a color image) or three sample arrays (e.g., a luminance array and two chrominance arrays in the case of the color image 17) or any other number and / or type of arrays depending on the color format applied. The number of samples in the horizontal and vertical directions (or axes) of the block 203 defines the size of the block 203. Therefore, the block may be an M×N (M columns×N rows) sample array, or an M×N transform coefficient array, etc.

[0086] In one embodiment, Figure 2 The video encoder 20 shown is used to encode the image 17 block by block, for example, encoding and prediction are performed on each block 203.

[0087] Figure 2 The illustrated embodiment of the video encoder 20 may also be used to partition and / or encode an image using slices (also referred to as video slices), wherein an image may be partitioned or encoded using one or more slices (typically non-overlapping), and each slice may include one or more blocks (e.g., CTUs).

[0088] Figure 2The illustrated embodiment of the video encoder 20 may also be used to segment and / or encode an image using block groups (also referred to as video block groups) and / or blocks (also referred to as video blocks), wherein one or more block groups (usually non-overlapping) may be used to segment or encode an image, each block group may include one or more blocks (e.g., CTU) or one or more blocks, etc., wherein each block may be a rectangular shape, etc., and may include one or more blocks (e.g., CTU), such as complete or partial blocks.

[0089] Residual calculation

[0090] The residual calculation unit 204 is used to calculate the residual block 205 (also referred to as residual 205) based on the image block 203 and the prediction block 265 (the prediction block 265 is described in detail later) in the following manner: for example, the sample value of the prediction block 265 is subtracted from the sample value of the image block 203 sample by sample (pixel by pixel) to obtain the residual block 205 in the sample domain.

[0091] Transform

[0092] The transform processing unit 206 is used to perform discrete cosine transform (DCT) or discrete sine transform (DST) on the sample values ​​of the residual block 205 to obtain transform coefficients 207 in the transform domain. The transform coefficients 207 may also be called transform residual coefficients, representing the residual block 205 in the transform domain.

[0093] The transform processing unit 206 can be used to apply integer approximations of DCT / DST, such as the transform specified for HEVC / H.265. Compared with the orthogonal DCT transform, this integer approximation is usually scaled by a certain factor. In order to maintain the norm of the residual block processed by the forward and inverse transforms, other scaling factors are applied during the transform process. The scaling factor is usually selected based on certain constraints, such as whether the scaling factor is a power of 2 for the shift operation, the bit depth of the transform coefficients, the trade-off between accuracy and implementation cost, etc. For example, a specific scaling factor is specified for the inverse transform by the inverse transform processing unit 212, etc. (and for the corresponding inverse transform at the video decoder 30 by the inverse transform processing unit 312, etc.), and accordingly, the corresponding scaling factor can be specified for the forward transform in the encoder 20 by the transform processing unit 206, etc.

[0094] An embodiment of the video encoder 20 (corresponding to the transform processing unit 206) can be used to directly output or output transform parameters (e.g., one or more types of transforms) after being encoded or compressed by the entropy coding unit 270, such that the video decoder 30 can receive and use the transform parameters for decoding.

[0095] Quantification

[0096] The quantization unit 208 is configured to quantize the transform coefficient 207 by, for example, scalar quantization or vector quantization to obtain a quantized transform coefficient 209 . The quantized coefficient 209 may also be referred to as a quantized transform coefficient 209 or a quantized residual coefficient 209 .

[0097] The quantization process can reduce the bit depth associated with some or all of the transform coefficients 207. For example, an n-bit transform coefficient can be rounded down to an m-bit transform coefficient during quantization, where n is greater than m. The degree of quantization can be modified by adjusting a quantization parameter (QP). For example, for scalar quantization, different scaling can be applied to achieve finer or coarser quantization. A smaller quantization step size corresponds to a finer quantization, while a larger quantization step size corresponds to a coarser quantization. The applicable quantization step size can be represented by a quantization parameter (QP). For example, a quantization parameter can be an index of a predefined set of applicable quantization steps. For example, a smaller quantization parameter can correspond to fine quantization (a smaller quantization step size), a larger quantization parameter can correspond to coarse quantization (a larger quantization step size), and vice versa. Quantization can include dividing by a quantization step size and corresponding quantization or inverse quantization, for example, performed by an inverse quantization unit 210, or can include multiplying by a quantization step size. Embodiments according to standards such as HEVC can be used to determine a quantization step size using a quantization parameter. Typically, the quantization step size can be calculated based on the quantization parameter using a fixed-point approximation of an equation that includes division. Quantization and dequantization can introduce other scaling factors to recover the norm of the residual block, which may be modified due to the scaling used in the fixed-point approximation of the equation for the quantization step size and the quantization parameter. In an exemplary implementation, the scaling of the inverse transform and dequantization can be combined. Alternatively, a custom quantization table can be used and indicated to the decoder by the encoder through a bitstream or the like. Quantization is a lossy operation, and the loss increases with the increase of the quantization step size.

[0098] In an embodiment, the video encoder 20 (corresponding to the quantization unit 208) may be configured to output a quantization parameter (QP), for example, directly output or output after being encoded by the entropy coding unit 270, such that the video decoder 30 may receive and use the quantization parameter for decoding.

[0099] Dequantization

[0100] The inverse quantization unit 210 is used to perform inverse quantization of the quantization unit 208 on the quantized coefficients to obtain dequantized coefficients 211, for example, performing an inverse quantization scheme of the quantization scheme performed by the quantization unit 208 according to or using the same quantization step size as the quantization unit 208. The dequantized coefficients 211 may also be referred to as dequantized residual coefficients 211, corresponding to the transform coefficients 207, but due to the loss caused by quantization, the dequantized coefficients 211 are usually not completely the same as the transform coefficients.

[0101] Inverse Transform

[0102] The inverse transform processing unit 212 is used to perform an inverse transform of the transform performed by the transform processing unit 206, for example, an inverse discrete cosine transform (DCT) or an inverse discrete sine transform (DST), to obtain a reconstructed residual block 213 (or a corresponding dequantized coefficient 213) in the pixel domain. The reconstructed residual block 213 may also be referred to as a transform block 213.

[0103] reconstruction

[0104] The reconstruction unit 214 (e.g., adder or summer 214) is used to add the transform block 213 (i.e., the reconstructed residual block 213) to the prediction block 265 to obtain the reconstructed block 215 in the sample domain, for example, by adding the sample values ​​of the reconstructed residual block 213 and the sample values ​​of the prediction block 265.

[0105] Filtering

[0106] The loop filter unit 220 (or simply "loop filter" 220) is used to filter the reconstructed block 215 to obtain a filter block 221, or generally to filter the reconstructed samples to obtain filtered samples. For example, the loop filter unit is used to smoothly perform pixel transitions or improve video quality. The loop filter unit 220 may include one or more loop filters, such as a deblocking filter, a sample-adaptive offset (SAO) filter, or one or more other filters, such as a bilateral filter, an adaptive loop filter (ALF), a sharpening or smoothing filter, or a collaborative filter, or any combination thereof. Although the loop filter unit 220 is in Figure 2 2 is shown as a loop filter, but in other configurations, the loop filter unit 220 can be implemented as a post-loop filter. The filter block 221 can also be referred to as a filtered reconstruction block 221.

[0107] Embodiments of the video encoder 20, and in particular the loop filter unit 220, may be used to encode output loop filter parameters (such as sample adaptive offset information) directly or via the entropy encoding unit 270, such that, for example, the decoder 30 may receive and apply the same loop filter parameters or a corresponding loop filter for decoding.

[0108] Decoded Image Buffer

[0109] The decoded picture buffer (DPB) 230 may be a memory for storing reference images or reference picture data for use by the video encoder 20. The DPB 230 may be formed by any of a variety of memory devices, such as a dynamic random access memory (DRAM), including synchronous DRAM (SDRAM), magnetoresistive RAM (MRAM), resistive RAM (RRAM), or other types of storage devices. The decoded picture buffer (DPB) 230 may be used to store one or more filter blocks 221. The decoded picture buffer 230 may also be used to store other previous filter blocks of different images such as the same current image or a previous reconstructed image, such as a previous reconstruction and filter block 221, and may provide a complete previous reconstruction, i.e., a decoded image (and corresponding reference blocks and samples) and / or a partially reconstructed current image (and corresponding reference blocks and samples), such as for inter-frame prediction. The decoded image buffer 230 may also be used to store one or more unfiltered reconstructed blocks 215, or generally unfiltered reconstructed samples, e.g., reconstructed blocks 215 that have not been filtered by the loop filter unit 220, or reconstructed blocks or reconstructed samples that have not undergone any other processing.

[0110] Mode selection (segmentation and prediction)

[0111] The mode selection unit 260 includes a segmentation unit 262, an inter-frame prediction unit 244, and an intra-frame prediction unit 254, which are used to receive or obtain original image data such as an original block 203 (current block 203 of the current image 17) from the decoded image buffer 230 or other buffers (e.g., a line buffer, not shown in the figure), and reconstructed image data, such as filtered and / or unfiltered reconstructed samples or reconstructed blocks of the same (current) image and / or one or more previously decoded images. The reconstructed image data is used as reference image data required for prediction such as inter-frame prediction or intra-frame prediction to obtain a prediction block 265 or a prediction value 265.

[0112] The mode selection unit 260 may be used to determine or select a partition type for a current block prediction mode (including non-partitioning) and a prediction mode (eg, intra-frame or inter-frame prediction mode), and to generate a corresponding prediction block 265 to calculate the residual block 205 and to reconstruct the reconstruction block 215.

[0113] In one embodiment, the mode selection unit 260 may be used to select a segmentation and prediction mode (e.g., from prediction modes supported or available by the mode selection unit 260), the prediction mode providing the best match or minimum residual (minimum residual means better compression in transmission or storage), or providing minimum indicated overhead (minimum indicated overhead means better compression in transmission or storage), or considering or balancing both of the above. The mode selection unit 260 may be used to determine the segmentation and prediction mode according to rate distortion optimization (RDO), i.e., selecting the prediction mode that provides minimum rate distortion optimization. In this context, terms such as "best", "minimum", "optimal", etc. do not necessarily mean "best", "minimum", "optimal", etc. in general, but may also refer to meeting termination or selection criteria, for example, a value exceeding or falling below a threshold or other constraint, which may result in a "suboptimal selection", but reduces complexity and processing time.

[0114] In other words, the partitioning unit 262 can be used to partition the block 203 into smaller partitions or sub-blocks (forming blocks again), for example, iteratively using quad-tree (QT) partitioning, binary-tree (BT) partitioning or triple-tree (TT) partitioning or any combination thereof, and for example, predict each partition or sub-block, wherein the mode selection includes selecting a tree structure of the partition 203 and applying a prediction mode to each partition or sub-block.

[0115] The segmentation (eg, performed by segmentation unit 260) and prediction processes (eg, performed by inter-prediction unit 244 and intra-prediction unit 254) performed by exemplary video encoder 20 are described in detail below.

[0116] segmentation

[0117] The segmentation unit 262 may segment (or divide) the current block 203 into smaller segments, such as smaller blocks of square or rectangular size. These smaller blocks (also referred to as sub-blocks) may be further segmented into even smaller segments. This method is also referred to as tree segmentation or hierarchical tree segmentation, wherein a root block, such as root tree level 0 (hierarchical level 0, depth 0), may be recursively segmented, such as into blocks of two or more next lower tree levels, such as nodes of tree level 1 (hierarchical level 1, depth 1). These blocks may be segmented again into blocks of two or more next lower levels, such as tree level 2 (hierarchical level 2, depth 2), and so on, until the segmentation terminates due to the satisfaction of the termination criteria, the maximum tree depth or the minimum block size is reached. Blocks that are not further segmented are also referred to as leaf blocks or leaf nodes of the tree. A tree segmented into two segments is referred to as a binary-tree (BT), a tree segmented into three segments is referred to as a ternary-tree (TT), and a tree segmented into four segments is referred to as a quad-tree (QT).

[0118] As mentioned above, the term "block" used in this document can be a part of an image, specifically a square or rectangular part. For example, in conjunction with HEVC and VVC, a block can be or correspond to a coding tree unit (CTU), a coding unit (CU), a prediction unit (PU) and a transform unit (TU), and / or correspond to a corresponding block, such as a coding tree block (CTB), a coding block (CB), a transform block (TB) or a prediction block (PB).

[0119] For example, a coding tree unit (CTU) may be or include a CTB of luma samples, two corresponding CTBs of chroma samples of an image with three sample arrays, or a CTB of samples of a monochrome image or a CTB of samples of an image decoded using three independent color planes and syntax structures for decoding the samples. Accordingly, a coding tree block (CTB) may be an N×N block of samples, where N may be set to a value such that the component is divided into CTBs, which is partitioning. A coding unit (CU) may be or include a coding block of luma samples, two corresponding coding blocks of chroma samples of an image with three sample arrays, or a coding block of samples of a monochrome image or a coding block of samples of an image decoded using three independent color planes and syntax structures for decoding the samples. Accordingly, a coding block (CB) may be an M×N block of samples, where M and N may be set to a value such that the CTB is divided into coding blocks, which is partitioning.

[0120] In an embodiment, for example, according to HEVC, a coding tree unit (CTU) can be divided into multiple CUs by a quadtree structure represented as a coding tree. Whether to use inter-frame (temporal) prediction or intra-frame (spatial) prediction to decode an image area is determined in units of CUs. Each CU can be further divided into one, two or four PUs according to the PU partition type. The same prediction process is applied within a PU, and relevant information is sent to the decoder in units of PUs. After applying the prediction process according to the PU partition type to obtain the residual block, the CU can be divided into transform units (TUs) according to another quadtree structure similar to the coding tree for the CU.

[0121] In an embodiment, for example, according to the latest video decoding standard currently under development called Versatile Video Coding (VVC), a combined quad-tree and binary tree (quad-tree and binary tree, QTBT) segmentation is used to segment the coding block. In the QTBT block structure, the CU can be square or rectangular. For example, the coding tree unit (CTU) is first segmented by a quadtree structure. The quadtree leaf nodes are further segmented by a binary tree or a ternary tree structure. The segmented leaf nodes are called coding units (CUs), and the fragments are used for prediction and transformation processing without further segmentation. That is, in the QTBT coding block structure, the block sizes of CU, PU, ​​and TU are the same. At the same time, multiple segmentations such as ternary tree segmentation can be used in combination with the QTBT block structure.

[0122] In one example, mode select unit 260 of video encoder 20 may be used to perform any combination of the segmentation techniques described herein.

[0123] As described above, the video encoder 20 is configured to determine or select the best or optimal prediction mode from a (eg, predetermined) prediction mode set. For example, the prediction mode set may include an intra-frame prediction mode and / or an inter-frame prediction mode.

[0124] Intra prediction

[0125] The intra-frame prediction mode set may include 35 different intra-frame prediction modes, for example, non-directional modes like DC (or mean) mode and planar mode, or directional modes as defined in HEVC, or may include 67 different intra-frame prediction modes, for example, non-directional modes like DC (or mean) mode and planar mode, or directional modes as defined in VVC.

[0126] The intra prediction unit 254 is configured to generate an intra prediction block 265 using reconstructed samples of neighboring blocks of the same current image according to an intra prediction mode in the intra prediction mode set.

[0127] The intra-frame prediction unit 254 (or generally the mode selection unit 260) is also used to output intra-frame prediction parameters (or generally information indicating the selected intra-frame prediction mode of the block) to the entropy coding unit 270 in the form of syntax elements 266 to be included in the encoded image data 21, for example so that the video decoder 30 can receive and use the prediction parameters for decoding.

[0128] Inter prediction

[0129] The set of (possible) inter-frame prediction modes is determined based on the available reference picture (i.e., a previously at least partially decoded picture stored in the DPB 230, for example) and other inter-frame prediction parameters, such as whether to use the entire reference picture or only a part of the reference picture (e.g., a search window area around the area of ​​the current block) to search for the best matching reference block, and / or whether to apply pixel interpolation (e.g., half-pixel and / or quarter-pixel interpolation), for example.

[0130] In addition to the above-mentioned prediction modes, skip mode and / or direct mode may also be applied.

[0131] The inter-frame prediction unit 244 may include a motion estimation (ME) unit and a motion compensation (MC) unit (both in Figure 2(not shown in the figure). The motion estimation unit may be used to receive or obtain the image block 203 (the current image block 203 of the current image 17) and the decoded image 231, or at least one or more previously reconstructed blocks, for example, reconstructed blocks of one or more other / different previously decoded images 231, for motion estimation. For example, a video sequence may include the current image and the previously decoded image 231, or in other words, the current image and the previously decoded image 231 may be part of an image sequence constituting the video sequence or an image sequence forming the video sequence.

[0132] For example, the encoder 20 may be used to select a reference block from a plurality of reference blocks of the same or different images in a plurality of other images, and provide the reference image (or reference image index) and / or the offset (spatial offset) between the position (x coordinate, y coordinate) of the reference block and the position of the current block as an inter-frame prediction parameter to the motion estimation unit. This offset is also referred to as a motion vector (MV).

[0133] The motion compensation unit is used to obtain (e.g., receive) inter-frame prediction parameters and perform inter-frame prediction based on or using the inter-frame prediction parameters to obtain an inter-frame prediction block 265. The motion compensation performed by the motion compensation unit may involve extracting or generating a prediction block based on a motion / block vector determined by motion estimation, and may also include interpolation to sub-pixel accuracy. Interpolation filtering can generate samples of other pixels from samples of known pixels, thereby potentially increasing the number of candidate prediction blocks that can be used to decode the image block. Once the motion vector of the PU of the current image block is received, the motion compensation unit can locate the prediction block pointed to by the motion vector in one of the reference image lists.

[0134] The motion compensation unit may also generate syntax elements associated with the blocks and video slices for use by the video decoder 30 in decoding the image blocks of the video slices. In addition to or as an alternative to slices and corresponding syntax elements, tile groups and / or tiles and corresponding syntax elements may also be received and / or used.

[0135] Entropy decoding

[0136] The entropy decoding unit 270 is used to apply an entropy coding algorithm or scheme (e.g., a variable length coding (VLC) scheme, a context adaptive VLC scheme (CAVLC), an arithmetic decoding scheme, a binarization algorithm, a context adaptive binary arithmetic coding (CABAC), a syntax-based context-adaptive binary arithmetic coding (SBAC), a probability interval partitioning entropy (PIPE) coding, or other entropy coding methods or techniques) or bypass (no compression) to the quantization coefficients 209, inter-frame prediction parameters, intra-frame prediction parameters, loop filter parameters and / or other syntax elements to obtain the encoded image data 21 that can be output through the output terminal 272 in the form of an encoded bitstream 21, etc., so that the video decoder 30, etc. can receive and use the parameters for decoding. The encoded bitstream 21 can be transmitted to the video decoder 30, or it can be stored in a memory for later transmission or retrieval by the video decoder 30.

[0137] Other structural variations of the video encoder 20 may be used to encode the video stream. For example, a non-transform based encoder 20 may directly quantize the residual signal of certain blocks or frames without the transform processing unit 206. In another embodiment, the encoder 20 may have the quantization unit 208 and the inverse quantization unit 210 combined into a single unit.

[0138] Decoder and decoding method

[0139] Figure 3 An example of a video decoder 30 for implementing the technology of the present application is shown. The video decoder 30 is used to receive the encoded image data 21 (e.g., the encoded code stream 21) encoded by the encoder 20, and obtain a decoded image 331. The encoded image data or code stream includes information for decoding the encoded image data, such as data representing image blocks of encoded video slices (and / or partition groups or partitions) and related syntax elements.

[0140] Figure 3In the example of , decoder 30 includes entropy decoding unit 304, inverse quantization unit 310, inverse transform processing unit 312, reconstruction unit 314 (e.g., summer 314), loop filter 320, decoded picture buffer (DPB) 330, mode application unit 360, inter prediction unit 344 and intra prediction unit 354. Inter prediction unit 344 may be or include a motion compensation unit. In some examples, video decoder 30 may perform operations generally related to Figure 2 The decoding process of the video encoder 100 is the reverse of the encoding process described above.

[0141] As explained with respect to the encoder 20, the inverse quantization unit 210, the inverse transform processing unit 212, the reconstruction unit 214, the loop filter 220, the decoded picture buffer (DPB) 230, the inter prediction unit 344, and the intra prediction unit 354 are also referred to as the “built-in decoder” constituting the video encoder 20. Accordingly, the inverse quantization unit 310 may be functionally identical to the inverse quantization unit 110, the inverse transform processing unit 312 may be functionally identical to the inverse transform processing unit 212, the reconstruction unit 314 may be functionally identical to the reconstruction unit 214, the loop filter 320 may be functionally identical to the loop filter 220, and the decoded picture buffer 330 may be functionally identical to the decoded picture buffer 230. Therefore, the explanation of the corresponding units and functions of the video encoder 20 applies accordingly to the corresponding units and functions of the video decoder 30.

[0142] Entropy decoding

[0143] The entropy decoding unit 304 is used to parse the bitstream 21 (or generally the encoded image data 21) and perform entropy decoding on the encoded image data 21 to obtain quantization coefficients 309 and / or decoded decoding parameters ( Figure 3 The entropy decoding unit 304 may be used to apply a decoding algorithm or scheme corresponding to the encoding scheme described for the entropy encoding unit 270 of the encoder 20. The entropy decoding unit 304 may also be used to provide the inter-frame prediction parameters, intra-frame prediction parameters and / or other syntax elements to the mode application unit 360, and to provide other parameters to other units of the decoder 30. The video decoder 30 may receive syntax elements at the video slice level and / or the video block level. In addition or as an alternative to slices and corresponding syntax elements, block groups and / or blocks and corresponding syntax elements may be received or used.

[0144] Dequantization

[0145] The inverse quantization unit 310 may be configured to receive a quantization parameter (QP) (or generally information related to inverse quantization) and a quantization coefficient from the encoded image data 21 (e.g., parsed and / or decoded by the entropy decoding unit 304), and inverse quantize the decoded quantization coefficient 309 according to the quantization parameter to obtain a dequantized coefficient 311, which may also be referred to as a transform coefficient 311. The inverse quantization process may include determining a degree of quantization using a quantization parameter determined by the video encoder 20 for each video block in a video slice (or partition or group of partitions), and also determining a degree of inverse quantization that needs to be applied.

[0146] Inverse Transform

[0147] The inverse transform processing unit 312 may be configured to receive the dequantized coefficients 311, also referred to as transform coefficients 311, and apply a transform to the dequantized coefficients 311 to obtain a reconstructed residual block 213 in the sample domain. The reconstructed residual block 213 may also be referred to as a transform block 313. The transform may be an inverse transform, such as an inverse DCT, an inverse DST, an inverse integer transform, or a conceptually similar inverse transform process. The inverse transform processing unit 312 may also be configured to receive transform parameters or corresponding information from the encoded image data 21 (e.g., parsed and / or decoded by the entropy decoding unit 304) to determine the transform applied to the dequantized coefficients 311.

[0148] reconstruction

[0149] The reconstruction unit 314 (eg, adder or summer 314 ) may be configured to add the reconstructed residual block 313 to the prediction block 365 to obtain the reconstructed block 315 in the sample domain, for example, by adding the sample values ​​of the reconstructed residual block 313 and the sample values ​​of the prediction block 365 .

[0150] Filtering

[0151] The loop filter unit 320 (in or after the decoding loop) is used to filter the reconstructed block 315 to obtain a filter block 321, so as to smoothly perform pixel conversion or improve video quality. The loop filter unit 320 may include one or more loop filters, such as a deblocking filter, a sample-adaptive offset (SAO) filter, or one or more other filters, such as a bilateral filter, an adaptive loop filter (ALF), a sharpening or smoothing filter, or a collaborative filter, or any combination thereof. Although the loop filter unit 320 is in Figure 3 3. Although shown as a loop filter in FIG. 3, in other configurations, the loop filter unit 320 may be implemented as a post-loop filter.

[0152] Decoded Image Buffer

[0153] The decoded video blocks 321 in one picture are then stored in a decoded picture buffer 330 which stores the decoded pictures 331 as reference pictures for subsequent motion compensation of other pictures and / or for respective output display.

[0154] The decoder 30 is used to output the decoded image 311 through an output terminal 312 or the like, for display to a user or for viewing by the user.

[0155] predict

[0156] The function of the inter-frame prediction unit 344 can be the same as that of the inter-frame prediction unit 244 (especially the motion compensation unit), and the function of the intra-frame prediction unit 354 can be the same as that of the inter-frame prediction unit 254, and decides to divide or partition and perform prediction according to the partition and / or prediction parameters or corresponding information received from the encoded image data 21 (for example, parsed and / or decoded by the entropy decoding unit 304, etc.). The mode application unit 360 can be used to perform prediction (intra-frame or inter-frame prediction) of each block according to the reconstructed image, block or corresponding sample (filtered or unfiltered), and obtain a prediction block 365.

[0157] When the video slice is decoded as an intra-coded (I) slice, the intra-prediction unit 354 of the mode application unit 360 is used to generate a prediction block 365 for the image block of the current video slice based on the intra-prediction mode and data of the previous decoded block of the current frame or picture. When the video picture is decoded as an inter-coded (e.g., B or P) slice, the inter-prediction unit 344 (e.g., motion compensation unit) of the mode application unit 360 is used to generate the prediction block 365 for the video block of the current video slice based on the motion vector and other syntax elements received from the entropy decoding unit 304. For inter-prediction, these prediction blocks can be generated from one of the reference pictures in one of the reference picture lists. The video decoder 30 can construct the reference frame lists: list 0 and list 1 using a default construction technique based on the reference pictures stored in the DPB 330. The same or similar processes may be applied to embodiments of partition groups (e.g., video partition groups) and / or partitions (e.g., video partitions) in addition to or as an alternative to slices (e.g., video slices), e.g., video may be coded using I, P, or B partition groups and / or partitions.

[0158] The mode application unit 360 is used to determine the prediction information of the video block in the current video slice by parsing the motion vector or related information and other syntax elements and generate a prediction block for the decoded current video block using the prediction information. For example, the mode application unit 360 uses some received syntax elements to determine the prediction mode (e.g., intra prediction or inter prediction) for decoding the video block of the video slice, the inter prediction slice type (e.g., B slice, P slice, or GPB slice), the construction information of one or more reference picture lists for the slice, the motion vector of each inter-coded video block of the slice, the inter-prediction state of each inter-coded video block of the slice, and other information to decode the video block in the current video slice. In addition to slices (e.g., video slices) or as an alternative to slices, the same or similar process can be applied to embodiments of block groups (e.g., video block groups) and / or blocks (e.g., video blocks), for example, video can be decoded using I, P, or B block groups and / or blocks.

[0159] Figure 3 An embodiment of the video decoder 30 shown in FIG. 1 may be used to partition and / or decode an image using slices (also referred to as video slices), wherein an image may be partitioned or decoded using one or more slices (typically non-overlapping) and each slice may include one or more blocks (e.g., CTUs).

[0160] Figure 3 An embodiment of the video decoder 30 shown may be used to segment and / or decode an image using block groups (also referred to as video block groups) and / or blocks (also referred to as video blocks), wherein an image may be segmented or decoded using one or more block groups (usually non-overlapping), each block group may include one or more blocks (e.g., CTUs) or one or more blocks, etc., wherein each block may be in a rectangular or other shape, and may include one or more blocks (e.g., CTUs), such as complete or partial blocks.

[0161] Other variations of the video decoder 30 may be used to decode the encoded image data 21. For example, the decoder 30 may generate an output video stream without the loop filter unit 320. For example, a non-transform based decoder 30 may directly inverse quantize the residual signal of certain blocks or frames without the inverse transform processing unit 312. In another implementation, in the video decoder 30, the inverse quantization unit 310 and the inverse transform processing unit 312 may be combined into one unit.

[0162] It should be understood that the processing result of the current step can be further processed in the encoder 20 and the decoder 30 and then output to the next step. For example, after interpolation filtering, motion vector derivation or loop filtering, the processing result of interpolation filtering, motion vector derivation or loop filtering can be further operated, such as correction (clip) or shift (shift) operation.

[0163] It should be noted that the derived motion vector of the current block (including but not limited to the control point motion vector of the affine mode, the sub-block motion vector of the affine mode, the planar mode and the ATMVP mode, the temporal motion vector, etc.) can be further operated. For example, the value of the motion vector is limited to a predefined range according to the representation bit of the motion vector. If the representation bit of the motion vector is bitDepth, the range is -2^(bitDepth-1) to 2^(bitDepth-1)-1, where "^" represents an exponent. For example, if bitDepth is set to 16, the range is -32768 to 32767; if bitDepth is set to 18, the range is -131072 to 131071. For example, the value of the derived motion vector (e.g., the MV of 4 4×4 sub-blocks in an 8×8 block) is limited so that the maximum difference between the integer parts of the 4 4×4 sub-block MVs does not exceed N pixels, for example, not more than 1 pixel. Two methods of limiting motion vectors according to bitDepth are provided here.

[0164] Method 1: Remove the most significant bit (MSB) of the overflow by performing the following operation:

[0165] ux= (mvx+2 bitDepth ) % 2 bitDepth (1)

[0166] mvx = (ux >= 2 bitDepth-1 ) ? (ux – 2 bitDepth ) : ux (2)

[0167] uy= (mvy+2 bitDepth ) % 2 bitDepth (3)

[0168] mvy = (uy >= 2 bitDepth-1 ) ? (uy – 2 bitDepth ) : uy (4)

[0169] Wherein, mvx is the horizontal component of the motion vector of the image block or sub-block, mvy is the vertical component of the motion vector of the image block or sub-block, and ux and uy represent intermediate values;

[0170] For example, if the value of mvx is –32769, the result after applying formulas (1) and (2) is 32767. In computer systems, decimal numbers are stored in two's complement form. The two's complement of –32769 is 1,0111,1111,1111,1111 (17 bits), and then the MSB is discarded, so the two's complement obtained is 0111,1111,1111,1111 (decimal 32767), which is the same as the output after applying formulas (1) and (2).

[0171] ux= (mvpx + mvdx +2 bitDepth ) % 2 bitDepth (5)

[0172] mvx = (ux >= 2 bitDepth-1 ) ? (ux – 2 bitDepth ) : ux (6)

[0173] uy= (mvpy + mvdy +2 bitDepth ) % 2 bitDepth (7)

[0174] mvy = (uy >= 2 bitDepth-1 ) ? (uy – 2 bitDepth ) : uy (8)

[0175] In the process of summing mvp and mvd, the above operations can be applied, as shown in equations (5) to (8).

[0176] Method 2: Trim the value to remove the overflowed MSB

[0177] vx=Clip3(-2 bitDepth-1 ,2 bitDepth-1 –1,vx)

[0178] vy=Clip3(-2 bitDepth-1 ,2 bitDepth-1 –1,vy)

[0179] Where vx is the horizontal component of the motion vector of the image block or sub-block, vy is the vertical component of the motion vector of the image block or sub-block; x, y and z correspond to the three input values ​​of the MV correction process respectively, and the function Clip3 is defined as follows:

[0180]

[0181] Figure 4Schematic diagram of a video decoding device 400 provided in an embodiment of the present invention. The video decoding device 400 is suitable for implementing the disclosed embodiments described herein. In one embodiment, the video decoding device 400 may be a decoder, such as Figure 1A The video decoder 30, or encoder, for example Figure 1A The video encoder 20 is configured to:

[0182] The video decoding device 400 includes an inlet port 410 (or input port 410) and a receiver unit (Rx) 420 for receiving data, a processor, a logic unit or a central processing unit (CPU) 430 for processing data, a transmitter unit (Tx) 440 and an outlet port 450 (or output port 450) for sending data, and a memory 460 for storing data. The video decoding device 400 may also include an optical-to-electrical (OE) component and an electrical-to-optical (EO) component coupled to the inlet port 410, the receiving unit 420, the transmitting unit 440 and the outlet port 450 for the outlet or inlet of an optical signal or an electrical signal.

[0183] The processor 430 is implemented by hardware and software. The processor 430 can be implemented as one or more CPU chips, cores (e.g., multi-core processors), FPGAs, ASICs, and DSPs. The processor 430 communicates with the input port 410, the receiver unit 420, the transmitter unit 440, the output port 450, and the memory 460. The processor 430 includes a decoding module 470. The decoding module 470 implements the embodiments disclosed above. For example, the decoding module 470 performs, processes, prepares, or provides various decoding operations. Therefore, the decoding module 470 provides substantial improvements to the functions of the video decoding device 400 and affects the switching of the video decoding device 400 to different states. Alternatively, the decoding module 470 is implemented with instructions stored in the memory 460 and executed by the processor 430.

[0184] The memory 460 may include one or more disks, tape drives, and solid-state hard disks, and may be used as an overflow data storage device for storing programs when they are selected for execution, and for storing instructions and data read during program execution. For example, the memory 460 may be volatile and / or non-volatile, and may be a read-only memory (ROM), a random access memory (RAM), a ternary content-addressable memory (TCAM), and / or a static random-access memory (SRAM).

[0185] Figure 5 A simplified block diagram of an apparatus 500 is provided for an exemplary embodiment, wherein the apparatus 500 may be used as Figure 1A Either or both of the source device 12 and the destination device 14 in .

[0186] The processor 502 in the device 500 may be a central processing unit. Alternatively, the processor 502 may be any other type of device or devices that are currently available or will be developed in the future and are capable of manipulating or processing information. Although a single processor such as the processor 502 shown in the figure may be used to implement the disclosed implementation, using more than one processor may improve speed and efficiency.

[0187] In one implementation, the memory 504 in the apparatus 500 may be a read only memory (ROM) device or a random access memory (RAM) device. Any other suitable type of storage device may be used as the memory 504. The memory 504 may include code and data 506 accessed by the processor 502 via a bus 512. The memory 504 may also include an operating system 508 and an application 510, wherein the application 510 includes at least one program that allows the processor 502 to perform the methods described herein. For example, the application 510 may include applications 1 to N, and also include a video decoding application that performs the methods described herein.

[0188] The apparatus 500 may also include one or more output devices, such as a display 518. In one example, the display 518 may be a touch-sensitive display that combines a display with a touch-sensitive element that may be used to sense touch input. The display 518 may be coupled to the processor 502 via the bus 512.

[0189] Although bus 512 in device 500 is described herein as a single bus, bus 512 may include multiple busses.

[0190] Furthermore, secondary storage 514 may be directly coupled to other components of device 500 or may be accessible via a network, and may include a single integrated unit such as a memory card or multiple units such as multiple memory cards. Thus, device 500 may have a wide variety of configurations.

[0191] Directional intra prediction is a well-known technique that consists in transferring the values ​​of neighboring samples into the prediction block specified by the prediction direction. Figure 6 93 prediction directions are shown, of which the dashed directions are associated with the wide-angle mode which is applied only to non-square blocks.

[0192] The direction can be specified by increasing the offset between the predicted sample position and the reference sample position. The larger the increase, the greater the inclination of the predicted direction. Table 1 is a mapping table between predModeIntra and the angle parameter intraPredAngle. This parameter is actually the increase in the offset of each row (or column) expressed in 1 / 32 sample resolution.

[0193] Table 1: Description of intraPredAngle

[0194] predModeIntra –14 –13 –12 –11 –10 –9 –8 –7 –6 –5 –4 –3 –2 –1 2 3 4 intraPredAngle 512 341 256 171 128 102 86 73 64 57 51 45 39 35 32 29 26 predModeIntra 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 intraPredAngle 23 20 18 16 14 12 10 8 6 4 3 2 1 0 –1 –2 –3 predModeIntra 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 intraPredAngle –4 –6 –8 –10 –12 –14 –16 –18 –20 –23 –26 –29 –32 –29 –26 –23 –20 predModeIntra 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 intraPredAngle –18 –16 –14 –12 –10 –8 –6 –4 –3 –2 –1 0 1 2 3 4 6 predModeIntra 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 intraPredAngle 8 10 12 14 16 18 20 23 26 29 32 35 39 45 51 57 64 predModeIntra 73 74 75 76 77 78 79 80 intraPredAngle 73 86 102 128 171 256 341 512

[0195] Wide-angle mode can be identified by an absolute value of intraPredAngle greater than 32 (1 sample), which corresponds to a predicted direction slope greater than 45 degrees.

[0196] Prediction samples (predSamples) can be obtained from neighboring samples (p) as follows:

[0197] The value of the predicted sample predSamples[x][y] is derived as follows, where x = 0..nTbW–1 and y = 0..nTbH–1:

[0198] – If predModeIntra is greater than or equal to 34, the following steps are performed in order:

[0199] 1. The reference sample array ref[x] is specified as follows:

[0200] – The following applies:

[0201] ref[x]=p[–1–refIdx+x][–1–refIdx], where x=0..nTbW+refIdx

[0202] – If intraPredAngle is less than 0, the primary reference sample array is extended as follows:

[0203] –When (nTbH*intraPredAngle)>>5 is less than –1,

[0204] ref[x]=p[–1–refIdx][–1–refIdx+((x*invAngle+128)>>8)], where x=–1..(nTbH*intraPredAngle)>>5

[0205] ref[((nTbH*intraPredAngle)>>5)–1]=ref[(nTbH*intraPredAngle)>>5]

[0206] ref[nTbW+1+refIdx]=ref[nTbW+refIdx]

[0207] -otherwise,

[0208] ref[x]=p[–1–refIdx+x][–1–refIdx], where x=nTbW+1+refIdx..refW+refIdx

[0209] ref[–1] = ref[0]

[0210] – The derivation of other samples ref[refW+refIdx+x] is as follows, where x=1..(Max(1,nTbW /

[0211] nTbH)*refIdx+1):

[0212] ref[refW+refIdx+x]=p[–1+refW][–1–refIdx]

[0213] 2. The value of the predicted sample predSamples[x][y] is derived as follows, where x = 0..nTbW–1 and y = 0..nTbH–1:

[0215] –The index variable iIdx and the multiplication factor iFact are derived as follows:

[0216] iIdx=((y+1+refIdx)*intraPredAngle)>>5+refIdx

[0217] iFact=((y+1+refIdx)*intraPredAngle)&31

[0218] – If cIdx is equal to 0, then:

[0219] – The interpolation filter coefficients fT[j] are derived as follows, where j = 0..3:

[0220] fT[j]=filterFlag? fG[iFact][j]:fC[iFact][j]

[0221] –The value of the predicted sample predSamples[x][y] is derived as follows:

[0222]

[0223] – Otherwise (cIdx is not equal to 0), depending on the value of iFact, the following applies:

[0224] – If iFact is not equal to 0, the value of the predicted sample predSamples[x][y] is derived as follows:

[0225] predSamples[x][y]=

[0226] ((32–iFact)*ref[x+iIdx+1]+iFact*ref[x+iIdx+2]+16)>>5

[0227] – Otherwise, the value of the predicted sample predSamples[x][y] is derived as follows:

[0228] predSamples[x][y]=ref[x+iIdx+1]

[0229] – Otherwise (predModeIntra is less than 34), perform the following steps in order:

[0230] 1. The reference sample array ref[x] is specified as follows:

[0231] – The following applies:

[0232] ref[x]=p[–1–refIdx][–1–refIdx+x], where x=0..nTbH+refIdx

[0233] – If intraPredAngle is less than 0, the primary reference sample array is extended as follows:

[0234] –When (nTbW*intraPredAngle)>>5 is less than –1,

[0235] ref[x]=p[–1–refIdx+((x*invAngle+128)>>8)][–1–refIdx], where x=-1..(nTbW*intraPredAngle)>>5

[0236] ref[((nTbW*intraPredAngle)>>5)–1]=ref[(nTbW*

[0237] intraPredAngle )>>5 ] (8-145)

[0238] ref[nTbG+1+refIdx]=ref[nTbH+refIdx]

[0239] -otherwise,

[0240] ref[x]=p[–1–refIdx][–1–refIdx+x], where x=nTbH1+refIdx..refH+refIdx

[0241] ref[–1] = ref[0]

[0242] – The derivation of other samples ref[refH+refIdx+x] is as follows, where x=1..(Max(1,nTbW / nTbH)

[0243] *refIdx+1):

[0244] ref[refH+refIdx+x]=p[–1+refH][–1–refIdx]

[0245] 2. The value of the predicted sample predSamples[x][y] is derived as follows, where x = 0..nTbW–1 and y = 0..nTbH–1:

[0247] –The index variable iIdx and the multiplication factor iFact are derived as follows:

[0248] iIdx=((x+1+refIdx)*intraPredAngle)>>5

[0249] iFact=((x+1+refIdx)*intraPredAngle)&31

[0250] – If cIdx is equal to 0, then:

[0251] – The interpolation filter coefficients fT[j] are derived as follows, where j = 0..3:

[0252] fT[j]=filterFlag? fG[iFact][j]:fC[iFact][j]

[0253] –The value of the predicted sample predSamples[x][y] is derived as follows:

[0254]

[0255] – Otherwise (cIdx is not equal to 0), depending on the value of iFact, the following applies:

[0256] – If iFact is not equal to 0, the value of the predicted sample predSamples[x][y] is derived as follows:

[0257] predSamples[x][y]=((32–iFact)*ref[y+iIdx+1]+iFact*ref[y+iIdx+2]+16)>>5

[0258] – Otherwise, the value of the predicted sample predSamples[x][y] is derived as follows: predSamples[x][y] = ref[y+iIdx+1]

[0259] The intra prediction modes may be indicated for the luma component and the chroma components such that the chroma intra prediction mode is obtained from the luma intra prediction mode:

[0260] The chroma intra prediction mode IntraPredModeC[xCb][yCb] is obtained using intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] shown in Tables 2 and 3.

[0261] Table 2: Description of IntraPredModeC[xCb][yCb] depending on intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] when sps_cclm_enabled_flag is equal to 0

[0262]

[0263] Table 3: Description of IntraPredModeC[xCb][yCb] depending on intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] when sps_cclm_enabled_flag is equal to 1

[0264]

[0265] The parameter "intra_chroma_pred_mode" is indicated in the codestream. It can be noted from Tables 2 and 3 that in some cases (indicated by "X"), the intra prediction mode (IntraPredModeC) of the chroma component is set equal to the intra prediction mode indicated for the collocated luma block.

[0266] The chroma format determines the priority and subsampling scheme of the chroma array, such as Figure 7 In a monochrome sampling scheme, there is only one sample array, nominally the brightness array.

[0267] In the 4:2:0 sampling scheme, the height and width of both chroma arrays are half of the luma array.

[0268] In the 4:2:2 sampling scheme, the height of both chroma arrays is the same as that of the luma array, and the width is half that of the luma array.

[0269] The technical solution provides the same intra prediction direction for predicting chroma samples as that specified for luma samples. However, when the chroma subsampling ratio in the horizontal direction is not equal to the chroma subsampling ratio in the vertical direction, the intra prediction direction of chroma is affected by subsampling, resulting in different mappings of intra prediction modes to intra prediction direction angles. In order to compensate for this effect, in the range extension of HM, it is proposed to perform a mode mapping step, that is, to extract the corresponding luma intra prediction mode (IntraPredModeY) from a dedicated lookup table (LUT), and use the extracted value for the chroma intra prediction mode (IntraPredModeC). Table 4 gives a set of LUTs used by modes specified in the HEVC standard.

[0270] Table 4: Description of the LUT used for intra prediction mode mapping in 4:2:2 chroma format

[0271] IntraPredModeY 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 IntraPredModeC 0 1 2 2 2 2 2 4 6 8 10 12 14 16 18 18 18 18 IntraPredModeY 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 IntraPredModeC 22 22 23 23 24 24 25 25 26 27 27 28 28 29 29 30 30

[0272] In VVC specification draft 4, during intra prediction, the intra prediction mode index (intraPredMode) is modified according to the aspect ratio as follows:

[0273] The variables nW and nH are derived as follows:

[0274] – If IntraSubPartitionsSplitType is equal to ISP_NO_SPLIT or cIdx is not equal to 0, then:

[0275] nW=nTbW,

[0276] nH=nTbH,

[0277] – Otherwise, (IntraSubPartitionsSplitType is not equal to ISP_NO_SPLIT, cIdx is equal to 0), then:

[0278] nW=nCbW,

[0279] nH=nCbH,

[0280] Set the variable whRatio to Abs(Log2(nW / nH)).

[0281] Set the variable wideAngle to 0.

[0282] For non-square blocks (nW is not equal to nH), the intra prediction mode predModeIntra is modified as follows:

[0283] – Set wideAngle to 1 and predModeIntra to (predModeIntra+65) when all of the following are true:

[0284] –nW is greater than nH,

[0285] –predModeIntra is greater than or equal to 2,

[0286] –predModeIntra is less than (whRatio>1)? (8+2*whRatio): 8,

[0287] – Otherwise, when all of the following conditions are true, set wideAngle to 1 and set predModeIntra to (predModeIntra

[0288] –67):

[0289] –nH is greater than nW,

[0290] –predModeIntra is less than or equal to 66,

[0291] –predModeIntra greater than (whRatio>1)? (60–2*whRatio):60.

[0292] The process of modifying the intra prediction mode (predModeIntra) according to the above aspect ratio (whRatio) may also be referred to as "wide-angle mapping".

[0293] If the prior art method is used, the intra prediction direction of chroma samples may be opposite to the direction specified for the collocated luma samples, because the conditions of luma and chroma blocks may be different due to the horizontal chroma subsampling specified for the YUV 4:2:2 chroma format.

[0294] The embodiment of the present invention proposes to consider both the aspect ratio of the block and the chroma subsampling format when using the luma intra prediction mode to perform chroma intra prediction.

[0295] The present invention provides several methods / embodiments to solve this problem. One method is to introduce a clipping operation to ensure that the luma and chroma directional predictions use the same side of the block.

[0296] Another approach consists in modifying the wide-angle mapping process to ensure that the resulting chroma prediction mode has the same angle as the mapping direction. According to the description above, these directions do not coincide. ("(predModeIntra-67)" and "(predModeIntra+65)").

[0297] The third method involves adjusting the input parameters of the wide-angle mapping process. Specifically, it is proposed to use the luma aspect ratio instead of the chroma aspect ratio. In addition, the intraPredAngle parameter is shifted left or right to compensate for the effect of chroma subsampling.

[0298] Alternatively, for the set of indicated luma intra prediction modes given in the VVC draft specification (in the range 0..66), the following lookup table can be used (Table 5)

[0299] Table 5: Description of the LUT used for intra prediction mode mapping for the 66 indicated intra prediction directions and 4:2:2 chroma format

[0300]

[0301] One possible technical solution includes applying the LUT shown in Table 5 to the value of the luma intra prediction mode (IntraPredModeY), and using the obtained mode as the input intra prediction mode (IntraPredModeC) of the directional intra prediction process of the chroma block, including:

[0302] – Perform wide-angle mapping for IntraPredModeC

[0303] – Derivation of reference sample array (“ref”) and intraPredAngle parameters

[0304] – Get the value of the predicted chroma sample using the reference sample (“ref”) determined above and the intraPredAngle parameter.

[0305] This method is very suitable when the luma intra prediction mode (IntraPredModeY) is not wide-angle mode. Fig. 9 As shown, predicted chrominance and luma samples located at the same spatial position "A" will use reference samples also located at the same spatial position.

[0306] This method also applies to Fig.11 The situation shown here is because the output chroma intra prediction direction is defined to be corrected to a 45 degree angle (mode 2). This correction is achieved by specifying the same value for a set of entries in the LUT (note that the entry IntraPredModeY = 2..8).

[0307] Another embodiment of the present invention includes modifying the wide-angle mapping process when performing the step "Perform wide-angle mapping on IntraPredModeC".

[0308] The following describes other dependencies between the wide-angle mapping process and whether the mapping direction is performed for chroma intra prediction in chroma mode specifying different subsampling ratios in the horizontal and vertical directions (denoted as "SubWidthC" and "SubHeightC", respectively):

[0309] The variables nW and nH are derived as follows:

[0310] – If IntraSubPartitionsSplitType is equal to ISP_NO_SPLIT or cIdx is not equal to 0, then:

[0311] nW=nTbW,

[0312] nH=nTbH,

[0313] – Otherwise, (IntraSubPartitionsSplitType is not equal to ISP_NO_SPLIT, cIdx is equal to 0), then:

[0314] nW=nCbW,

[0315] nH=nCbH,

[0316] If SubWidthC is not equal to SubHeightC, the value of the variable modeDelta is set to (cIdx == 0?0:1), otherwise

[0317] modeDelta is set to 0.

[0318] Set the variable whRatio to Abs(Log2(nW / nH)).

[0319] Set the variable wideAngle to 0.

[0320] For non-square blocks (nW is not equal to nH), the intra prediction mode predModeIntra is modified as follows:

[0321] – When all of the following conditions are true, set wideAngle to 1 and predModeIntra to (predModeIntra+65

[0322] +modeDelta):

[0323] –nW is greater than nH,

[0324] –predModeIntra is greater than or equal to 2,

[0325] –predModeIntra is less than (whRatio>1)? (8+2*whRatio): 8,

[0326] – Otherwise, when all of the following conditions are true, set wideAngle to 1 and set predModeIntra to (predModeIntra–

[0327] 67+modeDelta):

[0328] –nH is greater than nW,

[0329] –predModeIntra is less than or equal to 66,

[0330] –predModeIntra greater than (whRatio>1)? (60–2*whRatio):60.

[0331] However, the above method may cause the directions of the luma intra prediction mode (IntraPredModeY) and the chroma intra prediction mode to be opposite when the luma intra prediction mode (IntraPredModeY) corresponds to the wide-angle direction. Figure 8An example of a situation where IntraPredModeC is obtained according to IntraPredModeY is shown, where IntraPredModeY is a wide-angle intra prediction mode and IntraPredModeC is a non-wide-angle intra prediction mode. The example is an expected intra prediction mode (such as Figure 8 ) is not an example of a situation produced by the method disclosed above. Fig. 9 An example of obtaining IntraPredModeC according to IntraPredModeY is shown, where IntraPredModeY is a non-wide-angle intra prediction mode and IntraPredModeC is a non-wide-angle intra prediction mode. Fig.10 An example of a case where IntraPredModeC is obtained from IntraPredModeY is shown, where IntraPredModeY is a non-wide-angle intra prediction mode and IntraPredModeC is a wide-angle intra prediction mode. The example is an example of a case where a non-wide-angle input luminance intra prediction mode (IntraPredModeY) generates a wide-angle chromaticity intra prediction mode (IntraPredModeC) (e.g. Fig.10 shown). Fig.11 An example of the case where IntraPredModeC is obtained from IntraPredModeY using a prediction mode modification operation is shown, where IntraPredModeY is a non-wide-angle intra prediction mode and IntraPredModeC is a non-wide-angle intra prediction mode.

[0332] – When the chroma format is defined as YUV 4:2:2 and the input luma intra prediction mode (IntraPredModeY) is directional mode, the following steps can be used to publicly describe Figure 8 and Fig.10 An exemplary embodiment of the method shown ("Method 3") is as follows: performing wide-angle mapping on IntraPredModeY using the aspect ratio of the luminance block to obtain IntraPredModeFinalY;

[0333] – Using the input prediction mode IntraPredModeFinalY to derive the reference sample array (“ref”) and intraPredAngle parameters for the chroma block, the following steps are included:

[0334] – When IntraPredModeFinalY is not less than 34, the intraPredAngle parameter is redefined as follows:

[0335] intraPredAngle=intraPredAngle>>1

[0336] – Otherwise, the intraPredAngle parameter is redefined as follows:

[0337] intraPredAngle=intraPredAngle<<1

[0338] – Get the value of the predicted chroma sample using the reference sample (“ref”) determined above and the intraPredAngle parameter.

[0339] Alternatively, instead of performing the “intraPredAngle=intraPredAngle>>1” operation, other division by 2 may be used, for example: “intraPredAngle=sign(intraPredAngle)*((Abs(intraPredAngle)+1)>>1)” or “intraPredAngle=intraPredAngle / 2”.

[0340] The two methods can also be combined. One embodiment may include the following steps for an input luma intra prediction mode (IntraPredModeY) of directionality (i.e. not equal to DC mode and not equal to planar mode):

[0341] – If IntraPredModeY is not less than 18 and not greater than 50, perform the following steps.

[0342] o Use the key value of the luma intra prediction mode (IntraPredModeC) extracted from the LUT (e.g., as shown in Table 5) to obtain the chroma input intra prediction mode (IntraPredModeY)

[0343] oPerform wide-angle mapping for IntraPredModeC

[0344] o Derivation of reference sample array (“ref”) and intraPredAngle parameters

[0345] o Get the value of the predicted chroma sample using the reference sample ("ref") and the intraPredAngle parameter determined above.

[0346] – Otherwise, follow the steps in the “Method 3” description.

[0347] The embodiments of the present invention can also be expressed in the following forms:

[0348] 8.4.3 Process of Obtaining Chroma Intra Prediction Mode

[0349] The inputs to this process are:

[0350] – Luma position (xCb, yCb), which indicates the position of the top-left sample of the current chroma coding block relative to the top-left luma sample of the current image;

[0351] – The variable cbWidth indicates the width of the current coding block in units of luma samples;

[0352] – The variable cbHeight indicates the height of the current coding block in units of luma samples.

[0353] In this process, the chrominance intra prediction mode IntraPredModeC[xCb][yCb] is obtained.

[0354] The chroma intra prediction mode IntraPredModeC[xCb][yCb] is obtained using intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] shown in Table 8-2 and Table 8-3.

[0355] Use process map422 to obtain the chroma intra prediction mode IntraPredModeC[xCb][yCb].

[0356] Table 8-2: Description of IntraPredModeC[xCb][yCb] depending on intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] when sps_cclm_enabled_flag is equal to 0

[0357]

[0358] Table 8-3: Description of IntraPredModeC[xCb][yCb] depending on intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] when sps_cclm_enabled_flag is equal to 1

[0359] In the mapping process map422(), the way to obtain the output intra prediction mode Y from the input intra prediction mode X is as follows:

[0360] – Set output intra prediction mode Y to input intra prediction mode X if one of the following is true:

[0361] –SubWidthC is equal to SubHeightC,

[0362] –X is less than 2,

[0363] –X is greater than 66,

[0364] – Otherwise, the intra prediction mode Y is set to the value of the lookup table defined in Table 8-4.

[0365] Table 8-4: Description of the lookup table for the map422() mapping process

[0366]

[0367] Other embodiments of the present invention can also be expressed in the following forms:

[0368] 8.4.3 Process of Obtaining Chroma Intra Prediction Mode

[0369] The inputs to this process are:

[0370] – Luma position (xCb, yCb), which indicates the position of the top-left sample of the current chroma coding block relative to the top-left luma sample of the current image;

[0371] – The variable cbWidth indicates the width of the current coding block in units of luma samples;

[0372] – The variable cbHeight indicates the height of the current coding block in units of luma samples.

[0373] In this process, the chrominance intra prediction mode IntraPredModeC[xCb][yCb] is obtained.

[0374] Use intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] shown in Table 8-2 and Table 8-3 to obtain the chroma intra prediction mode IntraPredModeC[xCb][yCb].

[0375] Use process map422 to obtain the chroma intra prediction mode IntraPredModeC[xCb][yCb].

[0376] Table 8-2: Description of IntraPredModeC[xCb][yCb] depending on intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] when sps_cclm_enabled_flag is equal to 0

[0377]

[0378] Table 8-3: Description of IntraPredModeC[xCb][yCb] depending on intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] when sps_cclm_enabled_flag is equal to 1

[0379]

[0380] In the mapping process map422(), the way to obtain the output intra prediction mode Y from the input intra prediction mode X is as follows:

[0381] – Set output intra prediction mode Y to input intra prediction mode X if one of the following is true:

[0382] –SubWidthC is equal to SubHeightC,

[0383] –X is less than 2,

[0384] –X is greater than 66,

[0385] – Otherwise, the intra prediction mode Y is set to the value of the lookup table defined in Table 8-4.

[0386] Set the variable nW equal to cbWidth and the variable nH equal to cbHeight. Set the variable whRatio to Abs(Log2(nW / nH)).

[0387] For non-square blocks (nW is not equal to nH), the correction operation for output intra prediction mode Y is performed as follows:

[0388] – Set Y to ((whRatio>1)?(8+2*whRatio):8) if all of the following are true:

[0389] –nW is greater than nH,

[0390] –Y is greater than or equal to 2,

[0391] – Is Y less than (whRatio>1)? (8+2*whRatio): 8,

[0392] – Set Y to ((whRatio>1)?(60–2*whRatio):60) if all of the following are true:

[0393] –nH is greater than nW,

[0394] – Y is less than or equal to 66,

[0395] –Is Y greater than (whRatio>1)? (60–2*whRatio):60.

[0396] Table 8-4: Description of the lookup table for the map422() mapping process

[0397]

[0398] The intraPredAngle parameter adjustment method can also be implemented in the following form:

[0399] 8.4.4.2.7 Description of INTRA_ANGULAR2..INTRA_ANGULAR66 intra prediction modes

[0400] The inputs to this process are:

[0401] – Intra prediction mode predModeIntra;

[0402] – variable refIdx, indicating the intra prediction reference row index;

[0403] – variable nTbW, representing the transform block width;

[0404] – variable nTbH, indicating the transform block height;

[0405] – variable refW, indicating the reference sample width;

[0406] – variable refH, indicating the reference sample height;

[0407] – variable nCbW, indicating the coding block width;

[0408] – variable nCbH, indicating the coding block height;

[0409] – Variable cIdx, which represents the color component of the current block;

[0410] – Neighboring samples p[x][y], where x = –1 –refIdx, y = –1 –refIdx..refH–1, x = –refIdx..refW–1, y = –

[0411] 1–refIdx.

[0412] The output of this process is the modified intra prediction mode predModeIntra and prediction samples predSamples[x][y], where x=0..nTbW–1 and y=0..nTbH–1.

[0413] Set the variable nTbS to (Log2(nTbW)+Log2(nTbH))>>1.

[0414] The variables nW and nH are obtained as follows:

[0415] – If IntraSubPartitionsSplitType is equal to ISP_NO_SPLIT or cIdx is not equal to 0, then:

[0416] nW=nTbW

[0417] nH=nTbH

[0418] – Otherwise (IntraSubPartitionsSplitType is not equal to ISP_NO_SPLIT, cIdx is equal to 0):

[0419] nW=nCbW

[0420] nH=nCbH

[0421] Set the variable whRatio to Abs(Log2(nW / nH)).

[0422] If cIdx is not equal to 0 and subWidthC is greater than subHeightC, add 1 to whRatio.

[0423] Set the variable wideAngle to 0.

[0424] For non-square blocks (nW is not equal to nH), the intra prediction mode predModeIntra is obtained as follows:

[0425] – Set wideAngle to 1 and predModeIntra to (predModeIntra+65) if all of the following are true:

[0426] –nW is greater than nH,

[0427] –predModeIntra is greater than or equal to 2,

[0428] –predModeIntra is less than (whRatio>1)? (8+2*whRatio): 8,

[0429] – Otherwise, if all of the following are true, set wideAngle to 1 and predModeIntra to (predModeIntra–67):

[0430] –nH is greater than nW,

[0431] –predModeIntra is less than or equal to 66,

[0432] –predModeIntra greater than (whRatio>1)? (60–2*whRatio):60.

[0433] The variable filterFlag is obtained as follows:

[0434] – If one or more of the following conditions are true, filterFlag is set to 0.

[0435] –predModeIntra is equal to INTRA_ANGULAR2, INTRA_ANGULAR34, or INTRA_ANGULAR66

[0436] –refIdx is not equal to 0

[0437] –IntraSubPartitionsSplitType is not equal to ISP_NO_SPLIT and cIdx is equal to 0 and predModeIntra is greater than or equal to INTRA_ANGULAR34 and nW is greater than 8

[0438] –IntraSubPartitionsSplitType is not equal to ISP_NO_SPLIT and cIdx is equal to 0 and predModeIntra is less than INTRA_ANGULAR34 and nH is greater than 8.

[0439] -otherwise:

[0440] – Set the variable minDistVerHor to Min(Abs(predModeIntra–50),Abs(predModeIntra–18)).

[0441] –The variable intraHorVerDistThres[nTbS] is shown in Table 8-4A.

[0442] –The variable filterFlag is obtained as follows:

[0443] – If minDistVerHor is greater than intraHorVerDistThres[nTbS], or wideAngle is equal to 1, filterFlag is set to 1.

[0444] – Otherwise, filterFlag is set to 0.

[0445] Table 8-4A: Description of intraHorVerDistThres[nTbS] for various transform block sizes nTbS

[0446] nTbS=2 nTbS=3 nTbS=4 nTbS=5 nTbS=6 nTbS=7 intraHorVerDistThres[nTbS] 16 14 2 0 0 0

[0447] Figure 6 93 prediction directions are shown, of which the dashed directions are associated with the wide-angle mode which is applied only to non-square blocks.

[0448] Table 8-5 is a mapping table of predModeIntra and angle parameter intraPredAngle.

[0449] Table 8-5: Description of intraPredAngle

[0450]

[0451]

[0452] If cIdx is not equal to 0, and subWidthC is greater than subHeightC, then:

[0453] – If predModeIntra is greater than or equal to 34, then set intraPredAngle to intraPredAngle>>1,

[0454] – Otherwise, set intraPredAngle to intraPredAngle<<1.

[0455] The inverse angle parameter invAngle is derived from intraPredAngle as follows:

[0456]

[0457] The interpolation filter coefficients fC[phase][j] and fG[phase][j] are shown in Table 8-6, where phase = 0..31, j = 0..3.

[0458] Table 8-6: Description of interpolation filter coefficients fC and fG

[0459]

[0460]

[0461] The value of the predicted sample predSamples[x][y] is derived as follows, where x = 0..nTbW–1 and y = 0..nTbH–1:

[0462] – If predModeIntra is greater than or equal to 34, the following steps are performed in order:

[0463] 3. The reference sample array ref[x] is specified as follows:

[0464] – The following applies:

[0465] ref[x]=p[–1–refIdx+x][–1–refIdx], where x=0..nTbW+refIdx

[0466] – If intraPredAngle is less than 0, the primary reference sample array is extended as follows:

[0467] –When (nTbH*intraPredAngle)>>5 is less than –1,

[0468] ref[x]=p[–1–refIdx][–1–refIdx+((x*invAngle+128)>>8)], where x=–1..(nTbH*intraPredAngle)>>5

[0469] ref[((nTbH*intraPredAngle)>>5)–1]=ref[(nTbH*intraPredAngle)>> 5]

[0471] ref[nTbW+1+refIdx]=ref[nTbW+refIdx]

[0472] -otherwise,

[0473] ref[x]=p[–1–refIdx+x][–1–refIdx], where x=nTbW+1+refIdx..refW+

[0474] refIdx

[0475] ref[–1] = ref[0]

[0476] – The derivation of other samples ref[refW+refIdx+x] is as follows, where x=1..(Max(1,nTbW / nTbH)

[0477] *refIdx+1):

[0478] ref[refW+refIdx+x]=p[–1+refW][–1–refIdx]

[0479] 4. The value of the predicted sample predSamples[x][y] is derived as follows, where x = 0..nTbW–1 and y = 0..nTbH–1:

[0481] –The index variable iIdx and the multiplication factor iFact are derived as follows:

[0482] iIdx=((y+1+refIdx)*intraPredAngle)>>5+refIdx

[0483] iFact=((y+1+refIdx)*intraPredAngle)&31

[0484] – If cIdx is equal to 0, then:

[0485] – The interpolation filter coefficients fT[j] are derived as follows, where j = 0..3:

[0486] fT[j]=filterFlag? fG[iFact][j]:fC[iFact][j]

[0487] –The value of the predicted sample predSamples[x][y] is derived as follows:

[0488]

[0489] – Otherwise (cIdx is not equal to 0), depending on the value of iFact, the following applies:

[0490] – If iFact is not equal to 0, the value of the predicted sample predSamples[x][y] is derived as follows:

[0491] predSamples[x][y]=

[0492] ((32–iFact)*ref[x+iIdx+1]+iFact*ref[x+iIdx+2]+16)>>5

[0493] – Otherwise, the value of the predicted sample predSamples[x][y] is derived as follows:

[0494] predSamples[x][y]=ref[x+iIdx+1]

[0495] – Otherwise (predModeIntra is less than 34), perform the following steps in order:

[0496] 3. The reference sample array ref[x] is specified as follows:

[0497] – The following applies:

[0498] ref[x]=p[–1–refIdx][–1–refIdx+x], where x=0..nTbH+refIdx

[0499] – If intraPredAngle is less than 0, the primary reference sample array is extended as follows:

[0500] –When (nTbW*intraPredAngle)>>5 is less than –1,

[0501] ref[x]=p[–1–refIdx+((x*invAngle+128)>>8)][–1–refIdx], where x=-1..(nTbW*intraPredAngle)>>5

[0502] ref[((nTbW*intraPredAngle)>>5)–1]=ref[(nTbW*

[0503] intraPredAngle )>>5 ] (8-145)

[0504] ref[nTbG+1+refIdx]=ref[nTbH+refIdx]

[0505] -otherwise,

[0506] ref[x]=p[–1–refIdx][–1–refIdx+x], where x=nTbH1+refIdx..refH+refIdx

[0507] ref[–1] = ref[0]

[0508] – The derivation of other samples ref[refH+refIdx+x] is as follows, where x=1..(Max(1,nTbW /

[0509] nTbH)*refIdx+1):

[0510] ref[refH+refIdx+x]=p[–1+refH][–1–refIdx]

[0511] 4. The value of the predicted sample predSamples[x][y] is derived as follows, where x = 0..nTbW–1 and y = 0..nTbH–1:

[0513] –The index variable iIdx and the multiplication factor iFact are derived as follows:

[0514] iIdx=((x+1+refIdx)*intraPredAngle)>>5

[0515] iFact=((x+1+refIdx)*intraPredAngle)&31

[0516] – If cIdx is equal to 0, then:

[0517] – The interpolation filter coefficients fT[j] are derived as follows, where j = 0..3:

[0518] fT[j]=filterFlag? fG[iFact][j]:fC[iFact][j]

[0519] –The value of the predicted sample predSamples[x][y] is derived as follows:

[0520]

[0521] – Otherwise (cIdx is not equal to 0), depending on the value of iFact, the following applies:

[0522] – If iFact is not equal to 0, the value of the predicted sample predSamples[x][y] is derived as follows:

[0523] predSamples[x][y]=

[0524] ((32–iFact)*ref[y+iIdx+1]+iFact*ref[y+iIdx+2]+16)>>5

[0525] – Otherwise, the value of the predicted sample predSamples[x][y] is derived as follows:

[0526] predSamples[x][y]=ref[y+iIdx+1]

[0527] Specifically, a method and an embodiment of predictive decoding of a current block implemented by a decoding or encoding device are provided. The decoding device may be Figure 1A The video decoder 30 or Figure 3 The encoding device may be a decoder 30. Figure 1A Video encoder 20 or Figure 2 Encoder 20.

[0528] According to embodiment 1200 (see Fig. 12A ), when the value of idc_chrom_format indicates a 4:2:2 chroma format, the chroma intra prediction mode (intraPredModeC) 1203 is obtained from a lookup table (LUT) 1202 using the initial intra prediction mode of the chroma component. The value of the initial intra prediction mode of the chroma component may be equal to the value of the luma intra prediction mode intraPredModeY. Table 2, Table 3, Table 8-2, or Table 8-3 gives examples of the value of the initial intra prediction mode intra_chroma_pred_mode[xCb][yCb] of the chroma component and the value of the luma intra prediction mode intraPredModeYIntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2].

[0529] An example of the lookup table 1202 is Table 5 or Table 8-4. The lookup table includes 67 entries, indexed from 0 to 66.

[0530] After wide-angle mapping 1204 is performed on the chroma intra prediction mode 1203,

[0531] The modified chroma intra prediction mode is obtained. The parameter intraPredAngle 1205 is obtained according to the modified chroma intra prediction mode. For example, the modified chroma intra prediction mode is taken as predModeIntra, and intraPredAngle 1205 is obtained from Table 1. The prediction samples of the chroma component are obtained by performing chroma directional intra prediction 1206 according to the intraPredAngle parameter.

[0532] According to Example 1210 (see Fig. 12B ), perform wide-angle mapping 1212 on the luma intra prediction mode intraPredModeY 1211 to obtain a modified intraPredModeY. When the value of idc_chrom_format indicates a 4:2:2 chroma format,

[0533] The chroma intra prediction mode (intraPredModeC) 1214 is obtained from a lookup table (LUT) 1213 using the modified intraPredModeY. The lookup table 1213 may have 95 entries with indexes 0-94.

[0534] The parameter intraPredAngle 1215 is obtained according to the chroma intra prediction mode 1214. For example, the chroma intra prediction mode is taken as predModeIntra, and intraPredAngle 1215 is obtained from Table 1. The prediction samples of the chroma component are obtained by performing chroma directional intra prediction 1216 according to the intraPredAngle parameter.

[0535] Example 1300 (see Fig.13 ) includes the following steps: Step 1301, the device obtains the value of the luma intra-frame prediction mode (intraPredModeY). For example, the device obtains the value of intraPredModeY by parsing the bitstream. Step 1302: The device obtains the initial intra-frame prediction mode (IntraPredModeC) of the chroma component according to the value of the luma intra-frame prediction mode (intraPredModeY) (for example, according to Table 2, Table 3, Table 8-2 or Table 8-3). Step 1303: When the chroma format is 4:2:2, the device uses the initial intra-frame prediction mode (intraPredModeC) of the chroma component to obtain the chroma intra-frame prediction mode (intraPredModeC) from the lookup table (look up table, LUT). In the example of Table 8-4, the initial intra-frame prediction mode of the chroma component is mode X, and the chroma intra-frame prediction mode (intraPredModeC) is mode Y, that is, the initial intraPredModeC is adjusted to obtain intraPredModeC.

[0536] Step 1304: Perform wide-angle mapping on the chroma intra prediction mode (intraPredModeC) to obtain a modified intraPredModeC.

[0537] As disclosed above, for non-square blocks (nW is not equal to nH), the wide-angle mapping includes:

[0538] If all of the following conditions are true, set wideAngle to 1 and predModeIntra to (predModeIntra+65):

[0539] nW is greater than nH,

[0540] predModeIntra is greater than or equal to 2,

[0541] predModeIntra is less than (whRatio>1)? (8+2*whRatio): 8,

[0542] Otherwise, if all of the following are true, set wideAngle to 1 and set predModeIntra to (predModeIntra–67):

[0543] nH is greater than nW,

[0544] predModeIntra is less than or equal to 66,

[0545] predModeIntra greater than (whRatio>1)? (60–2*whRatio):60.

[0546] Step 1305: According to the modified intraPredModeC, obtain the intraPredAngle parameter of the chrominance component. For example, use the modified intraPredModeC as predModeIntra and obtain intraPredAngle1215 from Table 1. Step 1306: According to the intraPredAngle parameter, obtain the predicted sample of the chrominance component.

[0547] The detailed information of this embodiment 1300 is as shown in the above embodiment.

[0548] Fig.14 An embodiment of a device 1400 is shown. The device 1400 may be Figure 1A The video decoder 30, or Figure 3 The decoder 30 may be Figure 1A The video encoder 20, or Figure 2 The encoder 20. The device 1400 may be used to implement the above-mentioned embodiments 1200, 1210, 1300 and other embodiments.

[0549] The device for performing directional intra-frame prediction on the chrominance component of an image includes an acquisition unit 1401 , an obtaining unit 1402 , and a mapping unit 1403 .

[0550] The acquisition unit 1401 is used to acquire an initial intra prediction mode of a chroma component. The acquisition unit 1402 is used to obtain a chroma intra prediction mode (intraPredModeC) from a lookup table (LUT) using the initial intra prediction mode of the chroma component, wherein the chroma component has different subsampling ratios in the horizontal direction and the vertical direction. The acquisition unit 1402 can be used to obtain the chroma intra prediction mode IntraPredModeC[xCb][yCb] using intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] shown in Table 8-2 and Table 8-3.

[0551] The mapping unit 1403 is used to perform wide-angle mapping on the chroma intra prediction mode (intraPredModeC) to obtain a modified intraPredModeC. For example, the mapping unit 1403 performs wide-angle mapping on the original intra prediction mode (predModeIntra) to obtain a modified predModeIntra, wherein the value of the original predModeIntra is equal to the value of the chroma intra prediction mode (intraPredModeC).

[0552] The acquisition unit 1401 is further used for: acquiring, according to the modified intraPredModeC, for example, an intraPredAngle parameter of the chrominance component from a mapping table; and acquiring a prediction sample of the chrominance component according to the intraPredAngle parameter.

[0553] The acquisition unit 1401 may also be configured to acquire a value of a luma intra-frame prediction mode (intraPredModeY) from the bitstream, and then acquire an initial intra-frame prediction mode of a chroma component according to the value of the luma intra-frame prediction mode (intraPredModeY).

[0554] The present invention provides the following aspects:

[0555] Embodiment 1: A method for performing directional intra-frame prediction on a chrominance component of an image, wherein the chrominance component has different subsampling ratios in the horizontal direction and the vertical direction, the method comprising:

[0556] – obtain a reference sample array (“ref”) and an intraPredAngle parameter of the chroma component, wherein the intraPredAngle parameter derivation process is adjusted according to the difference in subsampling ratios of the chroma component in the horizontal direction and the vertical direction;

[0557] - Get the prediction samples of the chroma components using the reference sample array ("ref") of the chroma components and the intraPredAngle parameters.

[0558] Embodiment 2: The method according to embodiment 1, wherein the method further comprises:

[0559] –Get the value of luma intra prediction mode (intraPredModeY) from the bitstream.

[0560] Embodiment 3: The method according to embodiment 2, wherein the intraPredAngle parameter of the chroma component is obtained from the chroma intra-frame prediction mode (intraPredModeC), which is obtained from the value of the luma intra-frame prediction mode (intraPredModeY).

[0561] Embodiment 4: The method according to embodiment 3, wherein the process of obtaining the chroma intra prediction mode (intraPredModeC) is performed by extracting it from the LUT.

[0562] Embodiment 5: The method according to embodiment 3 or 4, wherein if the obtained chroma intra prediction mode (intraPredModeC) is wide angle, a clipping operation is performed.

[0563] Embodiment 6: The method according to embodiment 5, wherein, when intraPredModeC satisfies the mapping condition of the wide-angle mapping process, the chroma intra prediction mode is set to the closest non-wide-angle mode.

[0564] Embodiment 7: The method according to any one of embodiments 1 to 6, wherein wide-angle mapping is performed on the luma intra prediction mode (intraPredModeY), and the value of the intraPredAngle parameter is obtained using the resulting intra prediction mode.

[0565] Embodiment 8: The method according to embodiment 7, wherein the value of the intraPredAngle parameter is adjusted according to the chroma format and is used to obtain the predicted samples of the chroma component.

[0566] Embodiment 9: The method according to embodiment 7 or 8, wherein the chroma format is defined as YUV 4:2:2.

[0567] Embodiment 10: The method according to any one of embodiments 7 to 9, wherein the aspect ratio of the luminance block is used to perform wide-angle mapping on (IntraPredModeY) to generate IntraPredModeFinalY.

[0568] Embodiment 11: The method according to embodiment 10, wherein when IntraPredModeFinalY is not less than 34, the intraPredAngle parameter is defined as follows:

[0569] intraPredAngle=intraPredAngle>>1

[0570] Otherwise, the intraPredAngle parameter is redefined as follows:

[0571] intraPredAngle=intraPredAngle<<1.

[0572] Embodiment 12: A method according to any one of embodiments 1 to 11, wherein the intraPredAngle parameter is shifted left or right to compensate for the effect of chroma subsampling.

[0573] Embodiment 13: A method according to any one of Embodiments 1 to 12, wherein the chroma intra-frame prediction mode IntraPredModeC[xCb][yCb] is obtained using intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2] shown in Table 8-2 and Table 8-3.

[0574] Embodiment 14: A method according to any one of embodiments 1 to 12, wherein the chroma intra-frame prediction mode IntraPredModeC[xCb][yCb] is obtained using process map422.

[0575] Embodiment 15: A method according to any one of embodiments 1 to 14, wherein for a non-square block (nW is not equal to nH), the intra prediction mode predModeIntra is obtained as follows:

[0576] – Set wideAngle to 1 and predModeIntra to (predModeIntra+65) if all of the following are true:

[0577] –nW is greater than nH,

[0578] –predModeIntra is greater than or equal to 2,

[0579] –predModeIntra is less than (whRatio>1)? (8+2*whRatio): 8,

[0580] – Otherwise, if all of the following are true, set wideAngle to 1 and set predModeIntra to (predModeIntra

[0581] –67):

[0582] –nH is greater than nW,

[0583] –predModeIntra is less than or equal to 66,

[0584] –predModeIntra greater than (whRatio>1)? (60–2*whRatio):60.

[0585] Compared with the traditional method, the chrominance mode acquisition method using this method has better effect. The LUT is used to determine the chrominance intra-frame prediction mode based on the initial luminance intra-frame prediction mode. One of the characteristics of the embodiment of the present invention is to provide a minimum number of table entries in the LUT. The above content is achieved by executing the steps in sequence, that is, by mapping the chrominance intra-frame prediction mode to the luminance mode performed before the wide-angle mapping. When the chrominance to luminance LUT is applied without wide-angle mapping, it is necessary to specify the mapping only for the square block shape, thereby limiting the required LUT table entries to 67.

[0586] Furthermore, in the proposed embodiment of the present invention, the chrominance mode is obtained without obtaining the shape of the juxtaposed luminance blocks. In conventional methods, the mapping of the luminance intra prediction direction generated by the wide-angle mapping process also needs to consider the aspect ratio of the luminance block. The reason for this dependency is that the wide-angle mapping process requires information about the aspect ratio of the block to determine the value of the mapped intra prediction mode. In the embodiment of the present invention, the input luminance intra prediction mode is not subjected to wide-angle mapping, and therefore, the input luminance intra prediction mode can be obtained by code stream parsing. Since there is no need to process the segmentation structure of the luminance component, the decoding delay is improved if the proposed order of steps is adopted.

[0587] The encoding method and decoding method shown in the above-mentioned embodiments and applications of a system using these methods are explained below.

[0588] Fig.15 31 is a block diagram of a content providing system 3100 for implementing a content distribution service. The content providing system 3100 includes a capture device 3102, a terminal device 3106, and an (optional) display 3126. The capture device 3102 communicates with the terminal device 3106 via a communication link 3104. The communication link may include the communication channel 13 described above. The communication link 3104 includes, but is not limited to, WiFi, Ethernet, wired, wireless (3G / 4G / 5G), USB, or any combination thereof.

[0589] Capture device 3102 generates data, and can use the coding method shown in the above embodiment to encode data.Or, capture device 3102 can distribute data to streaming media server (not shown in the figure), and the server encodes data, and sends encoded data to terminal device 3106.Capture device 3102 includes but is not limited to video camera, smart phone or tablet computer, computer or notebook computer, video conferencing system, PDA, vehicle-mounted device or any combination thereof, etc.For example, capture device 3102 can include source device 12 described above.When data includes video, video encoder 20 in capture device 3102 can actually perform video encoding process.When data includes audio (i.e. sound), audio encoder in capture device 3102 can actually perform audio encoding process.In some actual scenes, capture device 3102 distributes encoded video data and encoded audio data by multiplexing encoded video data and encoded audio data together.In other actual scenes, for example, in video conferencing system, encoded audio data and encoded video data are not multiplexed. The capture device 3102 distributes the encoded audio data and the encoded video data to the terminal device 3106, respectively.

[0590] The terminal device 310 in the content providing system 3100 receives and regenerates the encoded data. The terminal device 3106 can be a device with data receiving and recovery capabilities, such as a smart phone or tablet computer 3108, a computer or laptop computer 3110, a network video recorder (NVR) / digital video recorder (DVR) 3112, a TV 3114, a set top box (STB) 3116, a video conferencing system 3118, a video surveillance system 3120, a personal digital assistant (PDA) 3122, a car device 3124 or any combination thereof, or such a device capable of decoding the above-mentioned encoded data. For example, the terminal device 3106 can include the destination device 14 described above. When the encoded data includes video, the video decoder 30 in the terminal device preferentially performs video decoding. When the encoded data includes audio, the audio decoder in the terminal device preferentially performs audio decoding processing.

[0591] For a terminal device with a display, such as a smartphone or tablet 3108, a computer or laptop 3110, a network video recorder (NVR) / digital video recorder (DVR) 3112, a TV 3114, a personal digital assistant (PDA) 3122, or a vehicle-mounted device 3124, the terminal device can send the decoded data to its display. For a terminal device without a display, such as an STB 3116, a video conferencing system 3118, or a video surveillance system 3120, an external display 3126 is connected to the terminal device to receive and display the decoded data.

[0592] When each device in this system performs encoding or decoding, the image encoding device or image decoding device shown in the above embodiments can be used.

[0593] Fig.16 3106. After the terminal device 3106 receives the code stream from the capture device 3102, the protocol processing unit 3202 analyzes the transmission protocol of the code stream. The protocol includes but is not limited to Real-Time Streaming Protocol (RTSP), Hyper Text Transfer Protocol (HTTP), HTTP Live streaming protocol (HLS), MPEG-DASH, Real-time Transport Protocol (RTP), Real-time Messaging Protocol (RTMP), or any combination thereof.

[0594] After the protocol processing unit 3202 processes the code stream, a stream file is generated. The file is output to the demultiplexing unit 3204. The demultiplexing unit 3204 can separate the multiplexed data into encoded audio data and encoded video data. As described above, for some actual scenarios, for example, in a video conferencing system, the encoded audio data and the encoded video data are not multiplexed. In this case, the encoded data is not sent to the video decoder 3206 and the audio decoder 3208 by the demultiplexing unit 3204.

[0595] Through the demultiplexing process, a video elementary stream (ES), an audio ES, and (optional) subtitles are generated. The video decoder 3206, including the video decoder 30 explained in the above embodiment, decodes the video ES to generate a video frame by the decoding method shown in the above embodiment, and sends the data to the synchronization unit 3212. The audio decoder 3208 decodes the audio ES to generate an audio frame, and sends the data to the synchronization unit 3212. Alternatively, the video frame can be stored in a buffer ( Fig.16 Similarly, the audio frame may be stored in a buffer before being sent to the synchronization unit 3212 ( Fig.16 not shown).

[0596] The synchronization unit 3212 synchronizes the video frames and the audio frames and provides the video / audio to the video / audio display 3214. For example, the synchronization unit 3212 synchronizes the presentation of the video information and the audio information. The information may be decoded in the syntax using timestamps associated with the presentation of the decoded audio and visual data and timestamps associated with the transmission of the data stream.

[0597] If subtitles are included in the bitstream, the subtitle decoder 3210 decodes the subtitles, synchronizes the subtitles with the video frames and the audio frames, and provides the video / audio / subtitles to the video / audio / subtitle display 3216 .

[0598] The present invention is not limited to the above-mentioned system, and the image encoding device or the image decoding device in the above-mentioned embodiments can be used in other systems such as automobile systems.

[0599] Mathematical operators

[0600] The mathematical operators used in this application are similar to those used in the C programming language. However, the results of integer division and arithmetic shift operations are more precisely defined, and other operations such as exponentiation and real-valued division are defined. Numbering and counting conventions generally start at 0, for example, "first" is equivalent to the 0th, "second" is equivalent to the 1st, and so on.

[0601] Arithmetic operators

[0602] The following arithmetic operators are defined as follows:

[0603] + Addition

[0604] – Subtraction (as a two-argument operator) or negation (as a unary prefix operator)

[0605] * Multiplication, including matrix multiplication

[0606]

[0607] ÷ is used to represent division in mathematical equations without truncation or rounding.

[0608] Used to represent division in mathematical equations without truncation or rounding.

[0609] The sum of f(i), where i takes all integer values ​​from x to y (inclusive).

[0610] x%y modulus operation. The remainder when x is divided by y, where both x and y must be integers and x≥0 and y>0.

[0611] Logical operators

[0612] The following logical operators are defined as follows:

[0613] x&&y Boolean logical "AND" of x and y

[0614] x||y Boolean logical OR of x and y

[0615] ! Boolean logic "not"

[0616] x? y:z If x is true or not equal to 0, find the value of y, otherwise find the value of z.

[0617] Relational operators

[0618] The following relational operators are defined as follows:

[0619] > Greater than

[0620] ≥ greater than or equal to

[0621] < less than

[0622] ≤ Less than or equal to

[0623] == is equal to

[0624] ! = Not equal to

[0625] When a relational operator is applied to a syntax element or variable that has been assigned the value "na" (not applicable), the value "na" is a distinct value for the syntax element or variable. The value "na" is not equal to any other value.

[0626] Bitwise Operators

[0627] The following bitwise operators are defined as follows:

[0628] & Bitwise AND. When operating on integer arguments, the operation is on the two's complement representation of the integer value. When operating on binary arguments, if the binary argument contains fewer bits than the other argument, the shorter argument is extended by adding more significant bits equal to 0.

[0629] | Bitwise OR. When operating on integer arguments, the operation is on the two's complement representation of the integer value. When operating on binary arguments, if the binary argument contains fewer bits than the other argument, the shorter argument is extended by adding more significant bits equal to 0.

[0630] ^ Bitwise XOR. When operating on integer arguments, the operation is on the two's complement representation of the integer value. When operating on binary arguments, if the binary argument contains fewer bits than the other argument, the shorter argument is extended by adding more significant bits equal to 0.

[0631] x >> y Arithmetic right shift of the two's complement integer representation of x by y binary digits. This function is defined only when y is a non - negative integer value. The result of the right shift is that the bit shifted into the most significant bit (MSB) is equal to the MSB of x before the shift operation.

[0632] x << y Arithmetic left shift of the two's complement integer representation of x by y binary digits. This function is defined only when y is a non - negative integer value. The result of the left shift is that the bit shifted into the least significant bit (LSB) is equal to 0.

[0633] Assignment operators

[0634] The following arithmetic operators are defined as follows:

[0635] = Assignment operator

[0636] ++ Increment, i.e., x++ is equal to x = x + 1; when used in an array index, it is equal to the value of the variable before the increment operation.

[0637] –– Decrement, i.e., x–– is equal to x = x - 1; when used in an array index, it is equal to the value of the variable before the decrement operation. += Increase by a specified amount, i.e., x += 3 is equal to x = x + 3, and x += (-3) is equal to x = x + (-3).

[0638] -= Decrease by a specified amount, i.e., x -= 3 is equal to x = x - 3, and x -= (-3) is equal to x = x - (-3).

[0639] Range notation

[0640] The following notation is used to indicate the range of values:

[0641] x=y..zx takes integer values ​​from y to z (including y and z), where x, y and z are all integers and z is greater than y.

[0642] Mathematical functions

[0643] The following mathematical functions are defined:

[0644]

[0645] Asin(x) trigonometric inverse sine function, operates on parameter x, x is between –1.0 and 1.0 (inclusive), and the output value is -

[0646] The range is between π÷2 and π÷2 (inclusive), and the unit is radians.

[0647] Atan(x) is a trigonometric inverse tangent function that operates on parameter x and has an output value in the range of –π÷2 to π÷2 (including the end value).

[0648] The unit is radians.

[0649]

[0650] Ceil(x) is the smallest integer greater than or equal to x.

[0651] Clip1 Y (x)=Clip3(0,(1< <BitDepth Y )–1,x)

[0652] Clip1 C (x)=Clip3(0,(1< <BitDepth C )–1,x)

[0653]

[0654] Cos(x) is the trigonometric cosine function, which operates on the parameter x in radians.

[0655] Floor(x) is the largest integer less than or equal to x.

[0656]

[0657] Ln(x) is the natural logarithm of x (base e logarithm, where e is the base constant of natural logarithms 2.718 281828…).

[0658] Log2(x) is the base 2 logarithm of x.

[0659] Log10(x) is the base 10 logarithm of x.

[0660]

[0661]

[0662] Round(x)=Sign(x)*Floor(Abs(x)+0.5)

[0663]

[0664] Sin(x) trigonometric sine function, operates on parameter x, in radians.

[0665]

[0666] Swap(x,y)=(y,x)

[0667] Tan(x) is the trigonometric tangent function, which operates on the parameter x in radians.

[0668] Operation priority order

[0669] When parentheses are not used to explicitly indicate precedence in an expression, the following rules apply:

[0670] – Operations with higher priority are evaluated before any operations with lower priority.

[0671] – Operations of the same priority are evaluated from left to right.

[0672] The following table describes the priority of operations from highest to lowest. The higher the position in the table, the higher the priority.

[0673] For operators that are also used in the C programming language, the operator precedence order in this specification is the same as the precedence order in the C programming language.

[0674] Table: Operation priority from highest (top of table) to lowest (bottom of table)

[0675]

[0676] Text description of the logical operation

[0677] In the text, statements for logical operations are described in mathematical form as follows:

[0678] if(condition 0)

[0679] statement 0

[0680] else if(condition 1)

[0681] statement 1 ...

[0683] else / *Remarks on remaining conditions* /

[0684] statement

[0685] It can be described as follows:

[0686] ...as follows / ...then:

[0687] – If condition 0 then statement 0

[0688] – Else if condition 1 then statement 1

[0689] –……

[0690] – Otherwise (information note for remaining conditions), then statement n

[0691] Each "if ... else, if ... else, ..." statement in the text is introduced by "if ..." followed by "... as follows:" or "... then:". The last condition of "if ... else, if ... else, ..." is always "otherwise, ...". Statements with "if ... else, if ... else, ..." in the middle are identified by matching "... as follows:" or "... then" with the ending statement "... else".

[0692] In the text, statements for logical operations are described in mathematical form as follows:

[0693]

[0694] It can be described as follows:

[0695] ...as follows / ...then:

[0696] – Statement 0 if all of the following are true:

[0697] –Condition 0a

[0698] – Condition 0b

[0699] – Otherwise, if one or more of the following conditions are true, then statement 1:

[0700] –Condition 1a

[0701] – Condition 1b

[0702] –……

[0703] – Otherwise, statement n

[0704] In the text, statements for logical operations are described in mathematical form as follows:

[0705] if(condition 0)

[0706] statement 0

[0707] if(condition 1)

[0708] statement 1

[0709] It can be described as follows:

[0710] When condition 0, then statement 0

[0711] When the condition is 1, then statement 1

[0712] Although the embodiments of the present invention are mainly described in terms of video decoding, it should be noted that the embodiments of the decoding system 10, the encoder 20 and the decoder 30 (respectively, the system 10) and other embodiments described herein can also be used for still image processing or decoding, that is, processing or decoding a single image in video decoding that is independent of any previous or consecutive images. In general, if the image processing decoding is limited to a single image 17, the inter-frame prediction unit 244 (encoder) and 344 (decoder) may not be available. All other functions (also called tools or techniques) of the video encoder 20 and the video decoder 30 can also be used for still image processing, such as residual calculation 204 / 304, transformation 206, quantization 208, inverse quantization 210 / 310, (inverse) transformation 212 / 312, segmentation 262 / 362, intra-frame prediction 254 / 354 and / or loop filtering 220 / 320, entropy coding 270 and entropy decoding 304.

[0713] Embodiments of encoders 20, decoders 30, etc., and the functions described herein related to encoders 20, decoders 30, etc. may be implemented using hardware, software, firmware, or any combination thereof. If implemented using software, the various functions may be stored or sent as one or more instructions or codes on a computer-readable medium and executed by a hardware-based processing unit. Computer-readable media may include computer-readable storage media, corresponding to tangible media such as data storage media, or communication media including any medium that facilitates the transfer of computer programs from one place to another (e.g., according to a communication protocol). In this manner, computer-readable media may generally correspond to (1) non-transitory tangible computer-readable storage media, or (2) communication media such as signals or carrier waves. Data storage media may be any available media that can be accessed by one or more computers or one or more processors to retrieve instructions, codes, and / or data structures for implementing the techniques described in the present invention. A computer program product may include a computer-readable medium.

[0714] As an example and not limitation, such computer-readable storage media may include RAM, ROM, EEPROM, CD-ROM or other optical disk storage, magnetic disk storage or other magnetic storage devices, flash memory or any other medium that can be used to store the required program code in the form of instructions or data structures and can be accessed by a computer. In addition, any connection can be appropriately defined as a computer-readable medium. For example, if the software is sent from a website site, server or other remote resource through a coaxial cable, optical cable, twisted pair, digital subscriber line (DSL) or wirelessly such as infrared, wireless and microwave, it is also included in the defined medium. However, it should be understood that the computer-readable storage medium and data storage medium do not include connections, carriers, signals or other transient media, but are actually directed to non-transient tangible storage media. Disks and discs used in this article include compact disks (CDs), laser discs, optical discs, digital versatile discs (DVDs), floppy disks and blue-ray discs. Disks usually copy data magnetically, while optical discs usually copy data optically with lasers. The above combinations can also be included in the scope of computer-readable media.

[0715] Instructions may be executed by one or more processors such as one or more digital signal processors (DSPs), general-purpose microprocessors, application specific integrated circuits (ASICs), field programmable logic arrays (FPGAs), or other equivalent integrated or discrete logic circuits. Therefore, the term "processor" as used herein may refer to any of the aforementioned structures or any other structures suitable for implementing the techniques described herein. In addition, in some aspects, the various functions described herein may be provided in dedicated hardware and / or software modules for encoding and decoding, or incorporated into a combined codec. Moreover, the techniques may be implemented entirely in one or more circuits or logic elements.

[0716] The techniques of the present invention may be implemented in a variety of devices or apparatuses, including wireless handsets, integrated circuits (ICs), or a set of ICs (e.g., chipsets). The various components, modules, or units described in the present invention are intended to emphasize the functional aspects of the apparatus for performing the disclosed techniques, but do not necessarily need to be implemented by different hardware units. In fact, as described above, the various units may be combined in a codec hardware unit in conjunction with appropriate software and / or firmware, or provided by a collection of interoperable hardware units (including one or more processors as described above).

Claims

1. A method for directional intra-frame prediction of the chrominance component of an image, characterized in that: include: According to the values ​​of intra_chroma_pred_mode and the luma intra prediction mode (intraPredModeY), obtaining a first chroma intra prediction mode (IntraPredModeC) of the chroma component through a first lookup table; When the width nW of the block corresponding to the chrominance component is not equal to the height nH of the block, performing wide-angle mapping on the first chrominance intra-frame prediction mode (intraPredModeC) to obtain a modified intraPredModeC; According to the modified intraPredModeC, obtaining the intraPredAngle parameter of the chrominance component; According to the intraPredAngle parameter, the predicted sample of the chrominance component is obtained.

2. The method according to claim 1, characterized in that The method further comprises: When the condition is met, obtaining a second chroma intra prediction mode (intraPredModeC) from a second lookup table (lookup table, LUT) using the first chroma intra prediction mode of the chroma component, Then, wide-angle mapping is performed on the second chroma intra prediction mode (intraPredModeC) to obtain the modified intraPredModeC.

3. The method according to claim 2, characterized in that The second LUT has 67 entries, and the index of the second LUT is 0-66.

4. The method according to claim 2, characterized in that: The second chroma intra prediction mode (intraPredModeC) is set to the first chroma intra prediction mode (intraPredModeC) if one of the following conditions is true: SubWidthC is equal to SubHeightC, The second chroma intra prediction mode is less than 2, The second chroma intra prediction mode is greater than 66, Otherwise, the second chroma intra prediction mode (intraPredModeC) is obtained from a second look up table (LUT) using the first chroma intra prediction mode of the chroma component.

5. The method according to any one of claims 1 to 4, characterized in that The acquiring of the intraPredAngle parameter according to the modified intraPredModeC includes: Using the modified predModeIntra, the intraPredAngle parameter of the chrominance component is obtained from a mapping table.

6. The method according to any one of claims 2 to 4, characterized in that The method further comprises: A clipping operation is performed on the obtained second chroma intra prediction mode (intraPredModeC).

7. The method according to claim 6, characterized in that The second chroma intra prediction mode is set to the closest non-wide-angle mode.

8. The method according to any one of claims 1 to 7, characterized in that The first chroma intra prediction mode is obtained using intra_chroma_pred_mode[xCb][yCb] and IntraPredModeY[xCb+cbWidth / 2][yCb+cbHeight / 2].

9. The method according to any one of claims 2 to 7, characterized in that The second LUT includes: Mode X represents the first chroma intra prediction mode of the chroma component, and mode Y represents the second chroma intra prediction mode (intraPredModeC) obtained from the second LUT.

10. The method according to claim 1, characterized in that Wide-angle mapping is performed on the original intra prediction mode (predModeIntra), and the modified predModeIntra includes: If all of the following conditions are true, the variable wideAngle is set to 1 and predModeIntra is set to (predModeIntra+65): nW is greater than nH, predModeIntra is greater than or equal to 2, predModeIntra is less than (whRatio>1)? (8+2*whRatio): 8, Otherwise, if all of the following are true, set wideAngle to 1 and set predModeIntra to (predModeIntra–67): nH is greater than nW, predModeIntra is less than or equal to 66, predModeIntra greater than (whRatio>1)? (60–2*whRatio): 60; Wherein the whRatio is set to Abs(Log2(nW / nH)); The first chroma intra prediction mode (intraPredModeC) is the original intra prediction mode (predModeIntra), and the modified predModeIntra is the modified intraPredModeC.

11. The method according to claim 1, characterized in that: The block corresponding to the chrominance component is a luminance block, and wide-angle mapping is performed on the first chrominance intra-frame prediction mode (intraPredModeC) based on the aspect ratio of the luminance block to obtain a modified intraPredModeC.

12. An encoder (20), characterized in that Comprising a processing circuit for performing a method according to any one of claims 1 to 11.

13. A decoder (30), characterized in that Comprising a processing circuit for performing a method according to any one of claims 1 to 11.

14. A computer-readable storage medium comprising a program code, characterized in that: The program code is used to execute the method according to any one of claims 1 to 11.

15. A decoder, characterized in that: include: one or more processors; A non-transitory computer-readable storage medium is coupled to the processor and stores a program executed by the processor, wherein when the processor executes the program, the decoder performs the method according to any one of claims 1 to 11.

16. An encoder, characterized in that: include: one or more processors; A non-transitory computer-readable storage medium is coupled to the processor and stores a program executed by the processor, wherein when the processor executes the program, the encoder performs the method according to any one of claims 1 to 11.