Method and apparatus for encoding and decoding video data
By introducing a predictive mode signaling system and method into video coding, the video coding process is optimized, solving the problem of large data volume in high-resolution video, achieving more efficient video coding and decoding, and maintaining image quality.
Patent Information
- Application Number
- CN202511886936.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2019-09-07
- Filing Date
- 2020-09-08
- Publication Date
- 2026-01-16
AI Technical Summary
As digital video quality progresses from high definition to 4K×2K and even 8K×4K, the amount of video data to be encoded/decoded grows exponentially. Maintaining the image quality of the decoded video data while encoding/decoding it more effectively remains a continuous challenge.
By introducing a predictive mode signaling system and method into the video coding process, including determining the semantic elements to be sent under different conditions, encoding non-skip mode coding blocks using a palette mode or intra-frame predictive mode, and sending these blocks via a bitstream, the video coding process is optimized.
It improves the efficiency and quality of video encoding, reduces the amount of data, and maintains the clarity and detail of the image, thus meeting the needs of high-resolution video data.
Smart Images

Figure CN121357321A_ABST
Abstract
Description
[0001] This application is a divisional of the Chinese Patent Application No. 202080059859.3 entitled “Prediction mode signaling in video coding” filed on September 8, 2020. TECHNICAL FIELD
[0002] Embodiments of the present application generally relate to video encoding and decoding, and more particularly, to methods and systems for prediction mode signaling in video coding. BACKGROUND
[0003] Various electronic devices support digital video, such as digital televisions, laptop or desktop computers, tablet computers, digital cameras, digital recording devices, digital media players, video gaming consoles, smartphones, video teleconferencing devices, video streaming devices, and the like. The electronic devices transmit, receive, encode, decode, and / or store digital video data by implementing video compression / decompression standards defined by MPEG-4, ITU-T H.263, ITU-T H.264 / MPEG-4, Part 10, Advanced Video Coding (AVC), High Efficiency Video Coding (HEVC), and Versatile Video Coding (VVC) standards. Video compression typically includes performing spatial (intra-frame) and / or temporal (inter-frame) prediction to reduce or remove redundancy inherent in video data. For block-based video coding, a video frame is partitioned into one or more slices, each having multiple video blocks, which can also be referred to as coding tree units (CTUs). Each CTU can contain one coding unit (CU) or recursively split into smaller CUs until a predefined minimum CU size is reached. Each CU, also referred to as a leaf CU, contains one or more transform units (TUs) and also one or more prediction units (PUs). Each CU can be coded in intra, inter, or IBC modes. Video blocks in intra coded (I) slices of a video frame are coded using spatial prediction relative to reference samples in neighboring blocks within the same video frame. Video blocks in inter coded (P or B) slices of a video frame can be coded by spatial prediction relative to reference samples in neighboring blocks within the same video frame or temporal prediction relative to reference samples in other reference video frames.
[0004] A prediction block for the current video block to be encoded is generated based on spatial or temporal predictions of previously encoded reference blocks (e.g., neighboring blocks). The process of finding reference blocks can be accomplished using a block-matching algorithm. Residual data representing the pixel differences between the current block to be encoded and the prediction block is called the residual block or prediction error. Inter-frame coded blocks are encoded based on the motion vectors pointing to the reference blocks in the reference frames that form the prediction blocks, and the residual blocks. The process of determining the motion vectors is often called motion estimation. Intra-frame coded blocks are encoded based on the intra-frame prediction mode and the residual blocks. For further compression, the residual blocks are transformed from the pixel domain to a transform domain, such as the frequency domain, producing residual transform coefficients, which can then be quantized. The quantized transform coefficients, initially arranged in a two-dimensional array, can be scanned to produce a one-dimensional vector of transform coefficients, which are then entropy-encoded into the video bitstream for even greater compression.
[0005] The encoded video bitstream is then stored in a computer-readable storage medium (e.g., flash memory) for access by another electronic device with digital video capabilities or directly transmitted to the electronic device via wired or wireless means. The electronic device then performs video decompression (the reverse of the video compression process described above) by, for example, parsing the encoded video bitstream to obtain semantic elements from the bitstream and reconstructing the digital video data from the encoded video bitstream to its original format based at least in part on the semantic elements obtained from the bitstream, and presents the reconstructed digital video data on the display of the electronic device.
[0006] As digital video quality progresses from high definition to 4K×2K and even 8K×4K, the amount of video data to be encoded / decoded grows exponentially. Maintaining image quality while encoding / decoding video data more efficiently remains a continuous challenge. Summary of the Invention
[0007] This application describes implementations related to video data encoding and decoding, and more specifically, describes systems and methods for predictive mode signaling in video encoding and decoding.
[0008] According to a first aspect of this application, a method for encoding video data is performed on a computing device having one or more processors and a memory storing multiple programs executed by the one or more processors, the method comprising: obtaining a parameter set associated with a non-skip mode coded block; determining, based on information including different conditions satisfied by the parameter set, to transmit a first semantic element, a second semantic element, or a third semantic element in a bitstream; wherein, if the first semantic element is transmitted and the first semantic element has a first value, the third semantic element is transmitted; under the condition that the non-skip mode coded block is encoded based on a palette mode, setting the first semantic element to have a first value and the third semantic element to have the first value; under the condition that the non-skip mode coded block is encoded based on an intra-frame prediction mode, setting the first semantic element to have the first value and the third semantic element to have a second value; and transmitting the non-skip mode coded block via the bitstream.
[0009] According to a second aspect of this application, a computing device includes one or more processors, a memory, and a plurality of programs stored in the memory. When executed by the one or more processors, these programs cause the computing device to perform the operations described above.
[0010] According to a third aspect of this application, a non-transitory computer-readable storage medium stores a plurality of programs for execution by a computing device having one or more processors. When executed by the one or more processors, these programs cause the computing device to perform the operations described above. Attached Figure Description
[0011] The accompanying drawings, included to provide a further understanding of the embodiments and incorporated herein and forming part of the specification, illustrate the described embodiments and, together with the specification, serve to explain the underlying principles. The same reference numerals denote corresponding parts.
[0012] Figure 1 This is a block diagram illustrating an exemplary video encoding and decoding system according to some embodiments of the present invention.
[0013] Figure 2 This is a block diagram illustrating an exemplary video encoder according to some embodiments of the present invention;
[0014] Figure 3 This is a block diagram illustrating an exemplary video decoder according to some embodiments of the present invention.
[0015] Figures 4A to 4E This is a block diagram illustrating how a frame, according to some embodiments of this application, is recursively segmented into multiple video blocks of different sizes by a quadtree.
[0016] Figure 5 This is a block diagram illustrating different prediction modes of coding units according to some implementations of this application.
[0017] Figure 6 This is a flowchart illustrating an exemplary process by which a video codec implements a technique for predicting patterns by signal transmission according to some embodiments of the present invention. Detailed Implementation
[0018] Reference will now be made in detail to the specific embodiments, examples of which are illustrated in the accompanying drawings. In the following detailed description, numerous non-limiting specific details are set forth to aid in understanding the subject matter presented herein. However, it will be apparent to those skilled in the art that various alternatives may be used without departing from the scope of the claims, and that the subject matter may be practiced without these specific details. For example, it will be apparent to those skilled in the art that the subject matter presented herein can be implemented on a wide variety of electronic devices with digital video capabilities.
[0019] Figure 1 This is a block diagram illustrating an exemplary system 10 for parallel encoding and decoding of video blocks according to some embodiments of the present invention. Figure 1 As shown, system 10 includes a source device 12 that generates and encodes video data which is then decoded by a target device 14. The source device 12 and target device 14 may include any of a variety of electronic devices, including desktop or laptop computers, tablets, smartphones, set-top boxes, digital televisions, cameras, display devices, digital media players, video game consoles, video streaming devices, and so on. In some embodiments, the source device 12 and target device 14 are equipped with wireless communication capabilities.
[0020] In some implementations, target device 14 may receive encoded video data to be decoded via link 16. Link 16 may include any type of communication medium or device capable of moving encoded video data from source device 12 to target device 14. In one example, link 16 may include a communication medium enabling source device 12 to transmit encoded video data directly to target device 14 in real time. The encoded video data may be modulated according to a communication standard such as a wireless communication protocol and transmitted to target device 14. The communication medium may include any wireless or wired communication medium, such as radio frequency (RF) spectrum or one or more physical transmission lines. The communication medium may form part of a packet-based network, such as a local area network, wide area network, or global network, such as the Internet. The communication medium may include a router, switch, base station, or any other device that may facilitate communication from source device 12 to target device 14.
[0021] In other embodiments, encoded video data can be transferred from output interface 22 to storage device 32. The target device 14 can then access the encoded video data in storage device 32 via input interface 28. Storage device 32 may include any of a variety of distributed or locally accessed data storage media, such as hard disk drives, Blu-ray discs, DVDs, CD-ROMs, flash memory, volatile or non-volatile memory, or any other suitable digital storage medium for storing encoded video data. In a further example, storage device 32 may correspond to a file server or another intermediate storage device capable of storing encoded video data generated by source device 12. The target device 14 can access the stored video data from storage device 32 via streaming or downloading. This file server can be any type of computer capable of storing and transferring encoded video data to the target device 14. Exemplary file servers include web servers (e.g., for websites), FTP servers, network attached storage (NAS) devices, or local disk drives. Target device 14 can access encoded video data via any standard data connection, including wireless channels (e.g., Wi-Fi connections), wired connections (e.g., DSL, cable modems, etc.), or combinations thereof, suitable for accessing encoded video data stored on a file server. Transmission of encoded video data from storage device 32 can be streaming, downloading, or a combination thereof.
[0022] like Figure 1 As shown, source device 12 includes a video source 18, a video encoder 20, and an output interface 22. Video source 18 may include sources such as video capture devices, such as cameras, video archives containing previously captured video, video feed interfaces for receiving video from video content providers, and / or computer graphics systems for generating computer graphics data as source video, or combinations of these sources. As an example, if video source 18 is a camera in a security monitoring system, source device 12 and target device 14 may form a camera phone or video phone. However, the embodiments described in this application are generally applicable to video encoding and decoding and are suitable for wireless and / or wired applications.
[0023] Captured, pre-captured, or computer-generated video can be encoded by video encoder 20. Encoded video data can be directly transmitted to target device 14 via output interface 22 of source device 12. Encoded video data can also (or alternatively) be stored on storage device 32 for subsequent access by target device 14 or other devices for decoding and / or playback. Output interface 22 may also include a modem and / or transmitter.
[0024] Target device 14 includes an input interface 28, a video decoder 30, and a display device 34. Input interface 28 may include a receiver and / or a modem, and receives encoded video data via link 16. The encoded video data transmitted via link 16 or provided on storage device 32 may include various semantic elements generated by video encoder 20 for use by video decoder 30 in decoding the video data. These semantic elements may be included within the encoded video data transmitted on a communication medium, stored on a storage medium, or stored on a file server.
[0025] In some embodiments, the target device 14 may include a display device 34, which may be an integrated display device or an external display device configured to communicate with the target device 14. The display device 34 displays decoded video data to a user and may include any of a variety of display devices, such as a liquid crystal display (LCD), a plasma display, an organic light-emitting diode (OLED) display, or other types of display devices.
[0026] The video encoder 20 and video decoder 30 may operate according to proprietary or industry standards such as VVC, HEVC, MPEG-4 Part 10, Advanced Video Coding (AVC), or extensions of such standards. It should be understood that this application is not limited to any particular video encoding / decoding standard and may be applicable to other video encoding / decoding standards. It is generally envisioned that the video encoder 20 of the source device 12 may be configured to encode video data according to any of these current or future standards. Similarly, it is generally envisioned that the video decoder 30 of the target device 14 may be configured to decode video data according to any of these current or future standards.
[0027] Both the video encoder 20 and the video decoder 30 can be implemented as any of a variety of suitable encoder circuits, such as one or more microprocessors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), discrete logic, software, hardware, firmware, or any combination thereof. When partially implemented in software, the electronic device may store instructions for software in a suitable non-transitory computer-readable medium and execute these instructions in hardware using one or more processors to perform the video encoding / decoding operations disclosed in this invention. Each of the video encoder 20 and the video decoder 30 may be included in one or more encoders or decoders, and either one may be integrated as part of a combined encoder / decoder (CODEC) in the respective device.
[0028] Figure 2This is a block diagram illustrating an exemplary video encoder 20 according to some embodiments described in this application. The video encoder 20 can perform intra-frame and inter-frame predictive coding of video blocks within a video frame. Intra-frame predictive coding relies on spatial prediction to reduce or remove spatial redundancy in video data within a given video frame or picture. Inter-frame predictive coding relies on temporal prediction to reduce or remove temporal redundancy in video data within adjacent video frames or pictures of a video sequence.
[0029] like Figure 2 As shown, the video encoder 20 includes a video data memory 40, a prediction processing unit 41, a decoded picture buffer (DPB) 64, an adder 50, a transform processing unit 52, a quantization unit 54, and an entropy coding unit 56. The prediction processing unit 41 further includes a motion estimation unit 42, a motion compensation unit 44, a segmentation unit 45, an intra-frame prediction processing unit 46, and an intra-frame block copy (BC) unit 48. In some embodiments, the video encoder 20 also includes an inverse quantization unit 58, an inverse transform processing unit 60, and an adder 62 for video block reconstruction. A deblocking filter (not shown) may be located between the adder 62 and the DPB 64 to filter block boundaries, thereby removing block artifacts from the reconstructed video. In addition to the deblocking filter, a loop filter (not shown) may be used to filter the output of the adder 62. The video encoder 20 may be in the form of fixed or programmable hardware units, or may be divided into one or more fixed or programmable hardware units as shown.
[0030] Video data memory 40 stores video data encoded by components of video encoder 20. The video data in video data memory 40 can be obtained, for example, from video source 18. DPB 64 is a buffer that stores reference video data used by video encoder 20 when encoding video data (e.g., in intra-frame or inter-frame predictive coding modes). Video data memory 40 and DPB 64 can be formed from any of a variety of memory devices. In various examples, video data memory 40 can be on-chip with other components of video encoder 20, or off-chip relative to these components.
[0031] like Figure 2As shown, after receiving video data, the segmentation unit 45 within the prediction processing unit 41 divides the video data into video blocks. This segmentation may also include dividing the video frame into slices, tiles, or other larger coding units (CUs) according to predefined segmentation structures, such as a quadtree structure associated with the video data. The video frame may be divided into multiple video blocks (or groups of video blocks referred to as tiles). The prediction processing unit 41 may select a prediction coding mode for the current video block from multiple possible prediction coding modes based on error results (such as coding rate and distortion level), such as one or more inter-frame prediction coding modes among multiple intra-frame prediction coding modes. The prediction processing unit 41 may provide the resulting intra-frame or inter-frame prediction coding block to adder 50 to generate a residual block, and to adder 62 to reconstruct the coding block for subsequent use as part of a reference frame. The prediction processing unit 41 also provides semantic elements, such as motion vectors, intra-frame mode indicators, segmentation information, and other such semantic information, to entropy coding unit 56.
[0032] To select an appropriate intra-predictive coding mode for the current video block, the intra-predictive processing unit 46 within the prediction processing unit 41 may perform intra-predictive coding of the current video block relative to one or more neighboring blocks in the same frame as the current block to be encoded, to provide spatial prediction. The motion estimation unit 42 and motion compensation unit 44 within the prediction processing unit 41 perform inter-predictive coding of the current video block relative to one or more prediction blocks in one or more reference frames, to provide temporal prediction. The video encoder 20 may perform multiple coding passes, for example, selecting an appropriate coding mode for each video data block.
[0033] In some implementations, motion estimation unit 42 determines an inter-frame prediction pattern for the current video frame by generating motion vectors based on a predetermined pattern within the video frame sequence. These motion vectors indicate the displacement of the prediction unit (PU) of a video block within the current video frame relative to a prediction block within a reference video frame. Motion estimation performed by motion estimation unit 42 is the process of generating motion vectors that estimate the motion of the video blocks. The motion vectors, for example, may indicate the displacement of the PU of a video block within the current video frame or picture relative to a prediction block within a reference frame (or other encoded unit), relative to the current block (or other encoded unit) encoded within the current frame. The predetermined pattern may designate the video frames in the sequence as P-frames or B-frames. Intra-frame BC unit 48 may determine vectors for intra-frame BC coding, such as block vectors, in a manner similar to how motion estimation unit 42 determines motion vectors for inter-frame prediction, or the block vectors may be determined using motion estimation unit 42.
[0034] A prediction block is a block of a reference frame that is considered to closely match the PU of the video block to be encoded in terms of pixel differences, which can be determined by the sum of absolute differences (SAD), sum of squared differences (SSD), or other difference metrics. In some implementations, the video encoder 20 can compute values for sub-integer pixel positions of the reference frame stored in the DPB 64. For example, the video encoder 20 can interpolate the quarter-pixel position, eighth-pixel position, or other fractional pixel position of the reference frame. Therefore, the motion estimation unit 42 can perform motion search relative to the full pixel position and fractional pixel position and output a motion vector with fractional pixel accuracy.
[0035] The motion estimation unit 42 calculates the motion vector of the PU in the inter-frame predictive coding frame by comparing the position of the PU with the position of the prediction block of a reference frame selected from the first reference frame list (list 0) or the second reference frame list (list 1). Each identifier in the first and second reference frame lists is stored in one or more reference frames in the DPB 64. The motion estimation unit 42 sends the calculated motion vector to the motion compensation unit 44, and then to the entropy coding unit 56.
[0036] Motion compensation performed by motion compensation unit 44 may involve acquiring or generating prediction blocks based on motion vectors determined by motion estimation unit 42. Upon receiving the motion vector of the PU for the current video block, motion compensation unit 44 may locate the prediction block pointed to by the motion vector in one of the reference frame lists, retrieve the prediction block from DPB 64, and forward the prediction block to adder 50. Adder 50 then forms a residual video block of pixel differences by subtracting the pixel values of the prediction block provided by motion compensation unit 44 from the pixel values of the current video block being encoded. These pixel differences forming the residual video block may include a luminance difference component or a chrominance difference component, or both. Motion compensation unit 44 may also generate semantic elements associated with video blocks of a video frame for use by video decoder 30 when decoding video blocks of a video frame. These semantic elements may include semantic elements defining motion vectors used to identify the prediction block, any identifiers indicating the prediction mode, or any other semantic information described herein. It should be noted that the motion estimation unit 42 and the motion compensation unit 44 can be highly integrated, but are illustrated separately for conceptual purposes.
[0037] In some implementations, the intra-BC unit 48 can generate vectors and acquire prediction blocks in a manner similar to that described above in conjunction with the motion estimation unit 42 and the motion compensation unit 44, but these prediction blocks are located within the same frame as the current block being encoded, and these vectors are referred to as block vectors rather than motion vectors. Specifically, the intra-BC unit 48 can determine the intra-prediction mode to be used for encoding the current block. In some examples, the intra-BC unit 48 can, for example, use various intra-prediction modes to encode the current block during individual encoding passes and test their performance through rate-distortion analysis. Next, the intra-BC unit 48 can select an appropriate intra-prediction mode from the various tested intra-prediction modes to use and generate an intra-prediction mode indicator accordingly. For example, the intra-BC unit 48 can use rate-distortion analysis for various tested intra-prediction modes to calculate rate-distortion values and select the intra-prediction mode with the best rate-distortion characteristics from the tested modes as the appropriate intra-prediction mode to use. Rate-distortion analysis typically determines the amount of distortion (or error) between a coded block and the original uncoded block that was encoded to produce that coded block, as well as the bit rate (i.e., number of bits) used to produce that coded block. Intra-frame BC unit 48 can calculate the ratio from the distortion and rate used for various coded blocks to determine which intra-frame prediction mode exhibits the optimal rate-distortion value for the block.
[0038] In other examples, the intra-frame BC unit 48 may use, in whole or in part, the motion estimation unit 42 and the motion compensation unit 44 to perform such functions for intra-frame BC prediction according to the embodiments described herein. In any case, for intra-frame block copying, the predicted block may be a block that is considered to closely match the block to be encoded, which, in terms of pixel differences, may be determined by the sum of absolute differences (SAD), the sum of squares (SSD), or other difference metrics, and the identification of the predicted block may include the calculation of values for sub-integer pixel positions.
[0039] Regardless of whether the prediction block originates from the same frame based on intra-frame prediction or from different frames based on inter-frame prediction, the video encoder 20 can form a residual video block by subtracting the pixel values of the prediction block from the pixel values of the current video block being encoded, thereby forming pixel differences. These pixel differences that form the residual video block may include luminance and chrominance component differences.
[0040] As described above, the intra-prediction processing unit 46 can perform intra-prediction on the current video block as an alternative to the inter-prediction performed by the motion estimation unit 42 and the motion compensation unit 44, or the intra-block copy prediction performed by the intra-BC unit 48. Specifically, the intra-prediction processing unit 46 can determine the intra-prediction mode to be used for encoding the current block. To this end, the intra-prediction processing unit 46 can encode the current block using various intra-prediction modes, for example, during individual encoding passes, and the intra-prediction processing unit 46 (or, in some examples, a mode selection unit) can select an appropriate intra-prediction mode from tested intra-prediction modes for use. The intra-prediction processing unit 46 can provide information indicating the selected intra-prediction mode for the block to the entropy coding unit 56. The entropy coding unit 56 can encode the information indicating the selected intra-prediction mode in the bitstream.
[0041] After prediction processing unit 41 determines the prediction block of the current video block through inter-frame prediction or intra-frame prediction, adder 50 forms a residual video block by subtracting the prediction block from the current video block. The residual video data in the residual block may be included in one or more transform units (TUs) and provided to transform processing unit 52. Transform processing unit 52 uses a transform such as discrete cosine transform (DCT) or a conceptually similar transform to transform the residual video data into residual transform coefficients.
[0042] Transform processing unit 52 can send the obtained transform coefficients to quantization unit 54. Quantization unit 54 quantizes these transform coefficients to further reduce the bit rate. This quantization process can also reduce the bit depth associated with some or all of the coefficients. The degree of quantization can be modified by adjusting the quantization parameters. In some examples, quantization unit 54 can then scan the matrix containing the quantized transform coefficients. Alternatively, entropy coding unit 56 can perform this scan.
[0043] After quantization, the entropy coding unit 56 entropy-encodes the quantized transform coefficients into a video bitstream using methods or techniques such as context-adaptive variable-length coding (CAVLC), context-adaptive binary arithmetic coding (CABAC), semantic-based context-adaptive binary arithmetic coding (SBAC), probability interval partitioning entropy (PIPE) coding, or other entropy coding methods or techniques. This encoded bitstream can then be transmitted to the video decoder 30, or archived in the storage device 32 for later transmission to or retrieval by the video decoder 30. The entropy coding unit 56 can also entropy-encode these motion vectors and other semantic elements used for the current video frame being encoded.
[0044] Inverse quantization unit 58 and inverse transform processing unit 60 apply inverse quantization and inverse transform, respectively, to reconstruct the residual video block in the pixel domain, thereby generating a reference block for predicting other video blocks. As described above, motion compensation unit 44 can generate a motion-compensated prediction block from one or more reference blocks of the frame stored in DPB 64. Motion compensation unit 44 can also apply one or more interpolation filters to the prediction block to calculate sub-integer pixel values for motion estimation.
[0045] Adder 62 adds the reconstructed residual block to the motion-compensated prediction block generated by motion compensation unit 44 to generate a reference block stored in DPB 64. This reference block can then be used by intra-frame BC unit 48, motion estimation unit 42, and motion compensation unit 44 as a prediction block for inter-frame prediction of another video block in a subsequent video frame.
[0046] Figure 3 This is a block diagram illustrating an exemplary video decoder 30 according to some embodiments of this application. The video decoder 30 includes a video data memory 79, an entropy decoding unit 80, a prediction processing unit 81, an inverse quantization unit 86, an inverse transform processing unit 88, an adder 90, and a DPB 92. The prediction processing unit 81 further includes a motion compensation unit 82, an intra-frame prediction processing unit 84, and an intra-frame prediction (BC) unit 85. The video decoder 30 performs a decoding process, which is typically combined with... Figure 2 The encoding processes described in relation to the video encoder 20 are reciprocal. For example, the motion compensation unit 82 may generate prediction data based on motion vectors received from the entropy decoding unit 80, while the intra-frame prediction unit 84 may generate prediction data based on intra-frame prediction mode indicators received from the entropy decoding unit 80.
[0047] In some examples, units of the video decoder 30 may be assigned to perform tasks that implement embodiments of the present invention. Furthermore, in some examples, embodiments of the present invention may be divided among one or more units of the video decoder 30. For example, the intra-frame BC unit 85 may perform embodiments of the present invention alone or in combination with other units of the video decoder 30 (such as the motion compensation unit 82, the intra-frame prediction processing unit 84, and the entropy decoding unit 80). In some examples, the video decoder 30 may not include the intra-frame BC unit 85, and the functionality of the intra-frame BC unit 85 may be performed by other components of the prediction processing unit 81 (such as the motion compensation unit 82).
[0048] Video data memory 79 can store video data, such as encoded video bitstreams, to be decoded by other components of video decoder 30. The video data stored in video data memory 79 can be obtained, for example, from storage device 32 via wired or wireless network communication of video data, from a local video source (such as a camera), or by accessing a physical data storage medium (such as a flash drive or hard disk). Video data memory 79 may include an encoded picture buffer (CPB) that stores encoded video data from the encoded video bitstream. Decoded picture buffer (DPB) 92 of video decoder 30 stores reference video data for use when video decoder 30 decodes video data (e.g., in intra-frame or inter-frame predictive coding modes). Video data memory 79 and DPB 92 can be formed of any of a variety of memory devices, such as dynamic random access memory (DRAM), including synchronous DRAM (SDRAM), magnetoresistive RAM (MRAM), resistive RAM (RRAM), or other types of memory devices. For illustrative purposes, in Figure 3 The video data memory 79 and DPB92 are shown as two distinct components of the video decoder 30. However, it will be apparent to those skilled in the art that the video data memory 79 and DPB92 may be provided by the same memory device or separate memory devices. In some examples, the video data memory 79 may be on-chip with other components of the video decoder 30, or off-chip relative to those components.
[0049] During this decoding process, the video decoder 30 receives an encoded video bitstream representing video blocks of encoded video frames and associated semantic elements. The video decoder 30 may receive these semantic elements at the video frame level and / or the video block level. The entropy decoding unit 80 of the video decoder 30 performs entropy decoding on the bitstream to generate quantization coefficients, motion vectors or intra-frame prediction mode indicators, and other semantic elements. The entropy decoding unit 80 then forwards these motion vectors and other semantic elements to the prediction processing unit 81.
[0050] When the video frame is encoded as an intra-predictive coded (I) frame or used for intra-coded prediction blocks in other types of frames, the intra-predictive processing unit 84 of the prediction processing unit 81 can generate prediction data for the video blocks of the current video frame based on the intra-predictive mode transmitted by signal and reference data from previously decoded blocks of the current frame.
[0051] When the video frame is encoded as an inter-frame predictive coded (i.e., B or P) frame, the motion compensation unit 82 of the prediction processing unit 81 generates one or more prediction blocks for the video blocks of the current video frame based on the motion vectors and other semantic elements received from the entropy decoding unit 80. Each of these prediction blocks can be generated from a reference frame in one of these reference frame lists. The video decoder 30 can construct the reference frame list, i.e., list 0 and list 1, based on the reference frames stored in the DPB 92 using the default construction technique.
[0052] In some examples, when encoding the video block according to the intra-BC mode described herein, the intra-BC unit 85 of the prediction processing unit 81 generates prediction blocks for the current video block based on the block vector and other semantic elements received from the entropy decoding unit 80. These prediction blocks can be located within the reconstructed region of the same image as the current video block defined by the video encoder 20.
[0053] Motion compensation unit 82 and / or intra-frame BC unit 85 determine prediction information for video blocks in the current video frame by parsing these motion vectors and other semantic elements, and then use this prediction information to generate a prediction frame for the current video block being decoded. For example, motion compensation unit 82 uses some of the received semantic elements to determine the prediction mode (e.g., intra-frame or inter-frame prediction), inter-frame prediction frame type (e.g., B or P), construction information for one or more reference frame lists for the frame, motion vectors of each inter-frame prediction coded video block in the frame, inter-frame prediction state of each inter-frame prediction coded video block in the frame, and other information for decoding these video blocks in the current video frame.
[0054] Similarly, the intra-frame BC unit 85 can use some of the received semantic elements (such as identifiers) to determine the construction information for predicting the current video block using the intra-frame BC mode, which video blocks of the frame are in the reconstruction region and should be stored in the DPB92, the block vector for each intra-frame BC predicted video block of the frame, the intra-frame BC prediction state for each intra-frame BC predicted video block of the frame, and other information for decoding these video blocks in the current video frame.
[0055] The motion compensation unit 82 can also use these interpolation filters during the encoding of these video blocks, just as the video encoder 20 does, to interpolate and calculate interpolated values for sub-integer pixels of the reference block. In this case, the motion compensation unit 82 can determine these interpolation filters used by the video encoder 20 from the received semantic elements and use these interpolation filters to generate prediction blocks.
[0056] The inverse quantization unit 86 uses the same quantization parameters calculated by the video encoder 20 for each video block in the video frame to inverse quantize the quantized transform coefficients provided in the bitstream and entropy decoded by the entropy decoding unit 80 to determine the degree of quantization. The inverse transform processing unit 88 applies an inverse transform (such as inverse DCT, inverse integer transform, or a conceptually similar inverse transform process) to these transform coefficients to reconstruct the residual block in the pixel domain.
[0057] After the motion compensation unit 82 or the intra-frame BC unit 85 generates a prediction block for the current video block based on these vectors and other semantic elements, the adder 90 reconstructs the encoded video block for the current video block by adding the residual block from the inverse transform processing unit 88 and the corresponding prediction block generated by the motion compensation unit 82 and the intra-frame BC unit 85. An in-loop filter (not shown) may be located between the adder 90 and the DPB 92 for further processing of the decoded video block. The decoded video block in a given frame is then stored in the DPB 92, which stores reference frames for subsequent motion compensation of later video blocks. The DPB 92 or a separate memory device may also store the decoded video for later display on a display device (such as a display device). Figure 1 It is displayed on the display device 34).
[0058] In a typical video coding process, a video sequence usually consists of a set of ordered frames or pictures. Each frame may include three sample arrays, denoted as SL, SCb, and SCr. SL is a two-dimensional array of luminance samples. SCb is a two-dimensional array of Cb chrominance samples. SCr is a two-dimensional array of Cr chrominance samples. In other cases, the frame may be monochrome, and therefore only includes a two-dimensional luminance sample array.
[0059] like Figure 4A As shown, the video encoder 20 (or more specifically, the segmentation unit 45) generates the coded representation of a frame by first dividing the frame into a set of coding tree units (CTUs). A video frame may include an integer number of CTUs sequentially ordered from left to right and from top to bottom in raster scan order. Each CTU is the largest logical coding unit, and its width and height are signaled by the video encoder 20 in the sequence parameter set so that all CTUs in the video sequence have the same size, namely one of 128×128, 64×64, 32×32, and 16×16. However, it should be noted that this application is not necessarily limited to a specific size. Figure 4BAs shown, each CTU may include a coding tree block (CTB) for luma samples, two corresponding coding tree blocks for chroma samples, and semantic elements for encoding samples of these coding tree blocks. These semantic elements describe the characteristics of different types of units in the encoded blocks of the coded pixel blocks and how the video sequence is reconstructed at the video decoder 30, including inter-frame or intra-frame prediction, intra-frame prediction modes, motion vectors, and other parameters. In monochrome images or images with three separate color planes, the CTU may include a single coding tree block and semantic elements for encoding samples of that coding tree block. A coding tree block may consist of N×N sample blocks.
[0060] To achieve better performance, the video encoder 20 can recursively perform tree splitting on these coding tree blocks of the CTU, such as binary tree splitting, ternary tree splitting, quadtree splitting, or combinations thereof, and divide the CTU into smaller coding units (CUs). Figure 4C As shown, the 64×64 CTU400 is first divided into four smaller CUs, each with a block size of 32×32. Among these four smaller CUs, CU410 and CU420 are each divided into four 16×16 CUs according to their block size. The two 16×16 CUs, 430 and 440, are further divided into four 8×8 CUs according to their block size. Figure 4D A quadtree data structure is shown in the figure, as illustrated below. Figure 4C The final result of the CTU 400 partitioning process shown in the figure is that each leaf node of the quadtree corresponds to a CU with a size ranging from 32×32 to 8×8. For example... Figure 4B Similar to the CTU shown, each CU may include a coded block (CB) of luminance samples and two corresponding coded blocks of chrominance samples of the same size frame, as well as semantic elements for encoding these samples of these coded blocks. In a monochrome image or an image with three separate color planes, the CU may include a single coded block and a semantic structure for encoding these samples of that coded block. It should be noted that in Figure 4C and 4D The quadtree segmentation shown is for illustrative purposes only, and a CTU can be split into CUs to accommodate different local features based on quadtree / ternary / binary tree segmentation. In multi-type tree structures, a CTU is segmented by a quadtree structure, and each quadtree leaf CU can be further segmented by binary and ternary tree structures. Figure 4E As shown, there are five types of partitioning: quadrilateral partitioning, horizontal binary partitioning, vertical binary partitioning, horizontal trilateral partitioning, and vertical trilateral partitioning.
[0061] In some implementations, the video encoder 20 may further segment the coded blocks of the CU into one or more M×N prediction blocks (PBs). A prediction block is a rectangular (square or non-square) sample block on which the same (inter-frame or intra-frame) prediction is applied. A prediction unit (PU) of the CU may include a prediction block for luma samples, two corresponding prediction blocks for chroma samples, and semantic elements for making predictions for these prediction blocks. In a monochrome image or an image with three separate color planes, a PU may include a single prediction block and a semantic structure for making predictions for that prediction block. The video encoder 20 can generate predicted luma, Cb, and Cr blocks for each PU of the CU.
[0062] Video encoder 20 can use intra-frame prediction or inter-frame prediction to generate prediction blocks for the PU. If video encoder 20 uses intra-frame prediction to generate prediction blocks for the PU, then video encoder 20 can generate prediction blocks for the PU based on decoded samples of the frame associated with the PU. If video encoder 20 uses inter-frame prediction to generate prediction blocks for the PU, then video encoder 20 can generate prediction blocks for the PU based on decoded samples of one or more frames other than the frame associated with the PU.
[0063] After the video encoder 20 generates predicted luminance, Cb, and Cr blocks for one or more PUs of the CU, the video encoder 20 can generate luminance residual blocks for the CU by subtracting the predicted luminance blocks of the CU from its original luminance coding blocks, such that each sample in the luminance residual block of the CU indicates the difference between a luminance sample in one of the predicted luminance blocks of the CU and a corresponding sample in the original luminance coding block of the CU. Similarly, the video encoder 20 can generate Cb residual blocks and Cr residual blocks for the CU respectively, such that each sample in the Cb residual block of the CU indicates the difference between a Cb sample in one of the predicted Cb blocks of the CU and a corresponding sample in the original Cb coding block of the CU, and each sample in the Cr residual block of the CU can indicate the difference between a Cr sample in one of the predicted Cr blocks of the CU and a corresponding sample in the original Cr coding block of the CU.
[0064] In addition, such as Figure 4CAs shown, the video encoder 20 can use quadtree partitioning to decompose the luminance, Cb, and Cr residual blocks of the CU into one or more luminance, Cb, and Cr transform blocks. A transform block is a rectangular (square or non-square) sample block to which the same transform is applied. A transform unit (TU) of the CU may include a transform block of luminance samples, two corresponding transform blocks of chrominance samples, and semantic elements for transforming these transform block samples. Therefore, each TU of the CU may be associated with a luminance transform block, a Cb transform block, and a Cr transform block. In some examples, the luminance transform block associated with the TU may be a sub-block of the luminance residual block of the CU. The Cb transform block may be a sub-block of the Cb residual block of the CU. The Cr transform block may be a sub-block of the Cr residual block of the CU. In a monochrome image or an image with three separate color planes, the TU may include a single transform block and a semantic structure for transforming the samples of that transform block.
[0065] The video encoder 20 can apply one or more transforms to the luminance transform block of the TU to generate a luminance coefficient block for the TU. The coefficient block can be a two-dimensional array of multiple transform coefficients. The transform coefficients can be scalars. The video encoder 20 can apply one or more transforms to the Cb transform block of the TU to generate a Cb coefficient block for the TU. The video encoder 20 can apply one or more transforms to the Cr transform block of the TU to generate a Cr coefficient block for the TU.
[0066] After generating coefficient blocks (such as luminance coefficient blocks, Cb coefficient blocks, or Cr coefficient blocks), video encoder 20 may quantize the coefficient blocks. Quantization typically refers to the process of quantizing transform coefficients to potentially reduce the amount of data used to represent the transform coefficients, thereby providing further compression. After quantizing the coefficient blocks, video encoder 20 may entropy encode the semantic elements indicating the quantized transform coefficients. For example, video encoder 20 may perform context-adaptive binary arithmetic coding (CABAC) on the semantic elements indicating the quantized transform coefficients. Finally, video encoder 20 may output a bitstream comprising a bit sequence that forms a representation of the encoded frames and associated data, which is stored in storage device 32 or transmitted to target device 14.
[0067] After receiving the bitstream generated by the video encoder 20, the video decoder 30 can parse the bitstream to obtain semantic elements. The video decoder 30 can reconstruct frames of the video data based at least in part on the semantic elements obtained from the bitstream. The process of reconstructing the video data is generally reciprocal to the encoding process performed by the video encoder 20. For example, the video decoder 30 can perform an inverse transform on the coefficient blocks associated with the TUs of the current CU to reconstruct the residual blocks associated with these TUs of the current CU. The video decoder 30 can also reconstruct the coded blocks of the current CU by adding these samples of the prediction blocks of the PUs used for the current CU to the samples of the transform blocks of these TUs of the current CU. After reconstructing the coded blocks for each CU of the frame, the video decoder 30 can reconstruct the frame.
[0068] As mentioned above, video encoding and decoding primarily use two modes to achieve video compression: intra-frame prediction and inter-frame prediction. Palette-based encoding and decoding is another encoding scheme adopted by many video coding standards. In palette-based encoding and decoding, which may be particularly suitable for encoding and decoding screen-generated content, the video codec (e.g., video encoder 20 or video decoder 30) forms a palette table representing the colors of a given block of video data. This palette table includes the most prominent (e.g., frequently used) pixel values in that given block. Pixel values that are not frequently represented in the video data of that given block are either not included in the palette table or are included as escape colors.
[0069] Each entry in the palette table includes an index to the corresponding pixel value in the palette table. The palette index for a sample in the block can be encoded to indicate which entry from the palette table will be used to predict or reconstruct which sample. The palette pattern begins with the process of generating a palette predictor for the first block of a group of images, slices, tiles, or other such video blocks. As described below, palette predictors for subsequent video blocks are typically generated by updating the previously used palette predictor. For illustrative purposes, it is assumed that the palette predictor is defined at the image level. In other words, an image may include multiple coded blocks, each with its own palette table, but only one palette predictor for the entire image.
[0070] To reduce the number of bits required to reconstruct palette entries in the video bitstream transmitted via signaling, the video decoder can utilize a palette predictor to determine new palette entries in the palette table for reconstructing video blocks. For example, the palette predictor may include palette entries from previously used palette tables, or even be initialized with the most recently used palette table by including all entries from the most recently used palette table. In some implementations, the palette predictor may include fewer than all entries from the most recently used palette table, and then merge some entries from other previously used palette tables. The palette predictor may have the same size as the palette table used to encode different blocks, or it may be larger or smaller than the palette table used to encode different blocks. In one example, the palette predictor is implemented as a first-in-first-out (FIFO) table comprising 64 palette entries.
[0071] To generate a palette table for blocks of video data from the palette predictor, the video decoder can receive a one-bit flag for each entry of the palette predictor from the encoded video bitstream. This one-bit flag can have a first value (e.g., binary 1) indicating that the associated entry of the palette predictor will be included in the palette table, or a second value (e.g., binary 0) indicating that the associated entry of the palette predictor is not included in the palette table. If the size of the palette predictor is larger than the palette table for blocks of video data, the video decoder can stop receiving more flags once the maximum size of the palette table is reached.
[0072] In some implementations, some entries in the palette table can be directly signaled within the encoded video bitstream, rather than being determined using a palette predictor. For these entries, the video decoder can receive three separate m-bit values from the encoded video bitstream, indicating the pixel values for the luminance and two chrominance components associated with the entry, where m represents the bit depth of the video data. Compared to the multiple m-bit values required for palette entries directly signaled, palette entries derived from the palette predictor require only one flag. Therefore, signaling some or all palette entries using a palette predictor can significantly reduce the number of bits required to signal new palette table entries, thereby improving the overall coding efficiency of palette pattern encoding.
[0073] In many cases, the palette predictor for a block is determined based on the palette table used to encode one or more previously encoded blocks. However, when encoding the first coding tree unit in a picture, slice, or tile, the palette table for previously encoded blocks may be unavailable. Therefore, the palette predictor cannot be generated using entries from the previously used palette table. In this case, a sequence of initial values for the palette predictor can be signaled in the Sequence Parameter Set (SPS) and / or Picture Parameter Set (PPS), values used to generate the palette predictor when the previously used palette table is unavailable. The SPS typically refers to the semantic structure of semantic elements applied to a series of consecutively encoded video pictures called a encoded video sequence (CVS), which is determined by the content of semantic elements found in the PPS, with semantic elements found in each slice header referencing semantic elements found in the PPS. The PPS typically refers to the semantic structure of semantic elements applied to one or more individual pictures within a CVS, which is determined by semantic elements found in each slice header. Therefore, SPS is generally considered to be a higher-level semantic structure than PPS, which means that the semantic elements included in SPS are usually less modified and applied to a larger portion of the video data compared to those included in PPS.
[0074] Figure 5 This is a block diagram illustrating different prediction modes of coding units according to some implementations of this application.
[0075] In VVC, each CU can be encoded in either a skip mode or a non-skip mode. For CUs encoded in skip mode, a semantic element is further signaled to indicate whether the current CU is in regular skip mode (similar to skip mode in HEVC) or IBC skip mode. For CUs encoded in non-skip mode, multiple semantic elements are further signaled to indicate whether the current CU is encoded in intra-frame mode, inter-frame mode, intra-block copy (IBC) mode, or palette (PLT) mode. These modes are referred to as "MODE_INTRA", "MODE_INTER", "MODE_IBC", and "MODE_PLT" in the VVC specification, respectively. For CUs encoded in intra-frame mode, only spatially adjacent reconstructed pixels within the same picture / slice can be used to generate the prediction signal for the current CU. For CUs encoded in inter-frame mode, the prediction signal can be generated from pixels from a reference picture that is not the current picture. Details of the IBC mode can be found in the document JVET-N1002 (http: / / phenix.int-evry.fr / jvet / ). At the 15th JVET meeting, the Palette (PLT) pattern was newly adopted in VVC, and its details are described in document JVET-O0119 at http: / / phenix.int-evry.fr / jvet / .
[0076] In the current VVC, the constraints and conditions for enabling each different mode are different, as summarized in Table 1 below. Furthermore, flags are sent via signaling in the Sequence Parameter Set (SPS) to indicate whether IBC and / or PLT modes are enabled or disabled in the relevant bitstream.
[0077]
[0078] Table 1: Constraints for Enabling / Signaling Non-Skip Related Modes
[0079] The semantics of mode signaling in the current VVC are shown in the table below.
[0080]
[0081] Table 2. Semantics of Predictive Mode Signaling in Current VVC
[0082] The semantics of mode signaling in the current VVC are explained below.
[0083] `cu_skip_flag[x0][y0]` equal to 1 means that for the current coding unit, when decoding P or B slices, semantic elements other than one or more of the following will not be parsed after `cu_skip_flag[x0][y0]`: the IBC mode flag `pred_mode_ibc_flag[x0][y0]`, and the `merge_data()` semantic structure; when decoding I slices, semantic elements other than `merge_idx[x0][y0]` will not be parsed after `cu_skip_flag[x0][y0]`. `cu_skip_flag[x0][y0]` equal to 0 means that the coding unit will not be skipped. The array indices `x0, y0` represent the position (x0, y0) of the top-left luminance sample of the considered coding block relative to the top-left luminance sample of the image. When `cu_skip_flag[x0][y0]` does not exist, it is inferred to be equal to 0.
[0084] A pred_mode_flag value of 0 indicates that the current coding unit is encoded using inter-frame prediction mode. A pred_mode_flag value of 1 indicates that the current coding unit is encoded using intra-frame prediction mode. When pred_mode_flag is absent, the following inference is made:
[0085] • If cbWidth equals 4 and cbHeight equals 4, then it is inferred that pred_mode_flag equals 1.
[0086] • Otherwise, if modeType equals MODE_TYPE_INTRA, then pred_mode_flag is inferred to be equal to 1.
[0087] • Otherwise, if modeType equals MODE_TYPE_INTER, then pred_mode_flag is inferred to be equal to 0.
[0088] • Otherwise, pred_mode_flag is inferred to be equal to 1 when decoding I slices, and to be equal to 0 when decoding P or B slices respectively.
[0089] • For x = x0..x0 + cbWidth-1 and y = y0..y0 + cbHeight-1, the derivation of the variable CuPredMode[chType][x][y] is as follows:
[0090] • If pred_mode_flag equals 0, then CuPredMode[chType][x][y] is set to equal MODE_INTER.
[0091] • Otherwise (pred_mode_flag equals 1), CuPredMode[chType][x][y] is set to equal MODE_INTRA.
[0092] A pred_mode_ibc_flag value of 1 indicates that the current coding unit is encoded using IBC prediction mode. A pred_mode_ibc_flag value of 0 indicates that the current coding unit is not encoded using IBC prediction mode. When pred_mode_ibc_flag does not exist, the following inference is made:
[0093] • If cu_skip_flag[x0][y0] equals 1, cbWidth equals 4, and cbHeight equals 4, then it is inferred that pred_mode_ibc_flag equals 1.
[0094] • Otherwise, if both cbWidth and cbHeight are equal to 128, then it is inferred that pred_mode_ibc_flag is equal to 0.
[0095] • Otherwise, if modeType equals MODE_TYPE_INTER, then pred_mode_ibc_flag is inferred to be equal to 0.
[0096] • Otherwise, if treeType equals DUAL_TREE_CHROMA, then pred_mode_ibc_flag is inferred to be equal to 0.
[0097] • Otherwise, when decoding I slices, pred_mode_ibc_flag is inferred to be equal to the value of sps_ibc_enabled_flag, and 0 when decoding P or B slices respectively.
[0098] • When pred_mode_ibc_flag equals 1, the variable CuPredMode[chType][x][y] is set to equal MODE_IBC, because x = x0..x0 + cbWidth-1 and y = y0..y0 + cbHeight-1.
[0099] `pred_mode_plt_flag` represents the use of palette mode in the current coding unit. `pred_mode_plt_flag` equal to 1 indicates that palette mode is applied in the current coding unit. `pred_mode_plt_flag` equal to 0 indicates that palette mode is not applied in the current coding unit. When `pred_mode_plt_flag` does not exist, it is inferred to be equal to 0. When `pred_mode_plt_flag` equals 1, the variable `CuPredMode[x][y]` is set to equal `MODE_PLT` for `x = x0..x0 + cbWidth - 1` and `y = y0..y0 + cbHeight - 1`.
[0100] In summary, in the current VVC, the semantics (i.e., associated flags) sent via signaling to indicate the corresponding non-skip mode are shown in Tables 4 through 10, each table corresponding to different conditions of the allowed prediction modes. It should be noted that in these tables, all 0s and 1s in the codeword can be reversed, and the resulting codewords have the same function. Furthermore, the names of the semantic elements can be changed without altering the function of the signaling mode.
[0101]
[0102] Table 3. Signaling for non-skipped CU prediction mode in the current VVC when all modes are allowed (inter-frame, intra-frame, IBC, and PLT modes)
[0103]
[0104] Table 4. Signaling in the current VVC for non-skipped CU modes when only intra-frame, IBC, and PLT modes are allowed.
[0105]
[0106] Table 5. Signaling in the current VVC that does not skip CU mode when only intra-frame, inter-frame, and PLT modes are allowed
[0107]
[0108] Table 6. Signaling in the current VVC for non-skipped CU modes when only intra-frame, inter-frame, and IBC modes are allowed.
[0109]
[0110] Table 7. Signaling in the current VVC for non-skipped CU modes when only intra-frame and IBC modes are allowed
[0111]
[0112] Table 8. Signaling in the current VVC for non-skipped CU modes when only intra-frame and PLT modes are allowed
[0113]
[0114] Table 9. Signaling in the current VVC for non-skipped CU mode when only intra-frame and inter-frame modes are allowed
[0115] Figure 6 This is a flowchart illustrating an exemplary process by which a video codec implements a technique for predicting patterns by signal transmission according to some embodiments of the present invention.
[0116] In the current VVC, IBC mode is considered more similar to inter-frame mode, while PLT mode is considered more similar to intra-frame mode. Therefore, in VVC, when `pred_mode_flag` is signaled as 0, the IBC mode flag (`pred_mode_ibc_flag`) is signaled, indicating that the current CU is in a similar inter-frame mode. When `pred_mode_flag` is signaled as 1, the PLT mode flag (`pred_mode_plt_flag`) is signaled, indicating that the current CU is in a similar intra-frame mode. However, there is an exception when only intra-frame, inter-frame, and PLT modes are allowed (i.e., IBC mode is not allowed). As shown in Table 5, when `pred_mode_flag` is signaled as 0, the PLT mode flag (`pred_mode_plt_flag`) is signaled. This exception not only disrupts the physical meaning of the pred_mode_flag flag, but also complicates the signaling conditions of pred_mode_plt_flag due to the different signaling conditions used depending on whether IBC mode is allowed.
[0117] Furthermore, in current VVC, the condition checks performed via signaling pred_mode_ibc_flag and pred_mode_plt_flag are complex, as shown in Table 2. Several methods are proposed to simplify the condition checks for these prediction modes via signaling.
[0118] According to a first embodiment of this application, the flag indicating the enable of the palette mode (such as pred_mode_plt_flag in the VVC specification) is signaled only in modes similar to intra-frame modes, without considering the conditions of allowed prediction modes. In one example, the palette mode flag pred_mode_plt_flag is signaled only when a semantic element indicating a mode similar to intra-frame or inter-frame (e.g., pred_mode_flag) is signaled or inferred to be similar to intra-frame (e.g., signaling pred_mode_flag as 1 in the current VVC). According to this embodiment, when only inter-frame, intra-frame, and PLT modes are allowed, the corresponding codewords are shown in Table 10, which differs from Table 5. Furthermore, the signaling conditions for pred_mode_plt_flag can be simplified, as highlighted in Table 11.
[0119]
[0120] Table 10. Signaling for non-skipped CU mode when only intra-frame, inter-frame, and PLT modes are allowed based on the first embodiment.
[0121]
[0122] Table 11. Semantics of the proposed mode signaling for VVC (modified parts are highlighted)
[0123] According to a second embodiment of this application, these modes are transmitted via signaling in a predefined order, with each mode indicated by a corresponding flag except for the last mode. The last mode does not require a corresponding flag because it can be inferred to be enabled when all previously transmitted modes (or flags) are not enabled. In one example, the inter-frame mode, IBC mode, and PLT mode are indicated by the flags pred_mode_inter_flag, pred_mode_ibc_flag, and pred_mode_plt_flag, respectively. In this case, the method is essentially the same as assigning truncated binary codewords to modes based on a predefined signaling order. The relevant codewords are shown in Tables 12 to 18. The signaling conditions for pred_mode_ibc_flag and pred_mode_plt_flag can also be simplified, as highlighted in Table 19.
[0124]
[0125] Table 12. Signaling for non-skipped CU mode when all modes (inter-frame, intra-frame, IBC, and PLT modes) are allowed based on the second embodiment.
[0126]
[0127] Table 13. Signaling for non-skipped CU mode when only intra-frame, IBC, and PLT modes are allowed based on the second embodiment.
[0128]
[0129] Table 14. Signaling for non-skipped CU mode when only intra-frame, inter-frame, and PLT modes are allowed based on the second embodiment.
[0130]
[0131] Table 15. Signaling for non-skipped CU mode when only intra-frame, inter-frame, and IBC modes are allowed based on the second embodiment.
[0132]
[0133] Table 16. Signaling for non-skipped CU mode when only intra-frame and IBC modes are allowed based on the second embodiment
[0134]
[0135] Table 17. Signaling for non-skipped CU mode when only intra-frame and PLT modes are allowed based on the second embodiment
[0136]
[0137] Table 18. Signaling for non-skipped CU mode when only intra-frame and inter-frame modes are allowed based on the second embodiment.
[0138]
[0139] Table 19. Semantics of the proposed mode signaling for VVC (modified parts are highlighted)
[0140] According to a third embodiment of the invention, these modes are signaled by first sending semantic elements to indicate whether the current block uses a conventional mode (such as inter-frame and intra-frame modes) or a new mode (such as IBC and PLT modes). Following the first semantic element, additional semantic elements are signaled to indicate which mode is used. The associated codewords are shown in Tables 20 to 26. It should be noted that, according to this embodiment, the naming of the codeword bins (or flags) is changed to reflect their physical meaning.
[0141]
[0142] Table 20. Signaling for non-skipped CU modes when all modes (inter-frame, intra-frame, IBC, and PLT modes) are allowed based on the third embodiment.
[0143]
[0144] Table 21. Signaling for non-skipped CU mode when only intra-frame, IBC, and PLT modes are allowed based on the third embodiment.
[0145]
[0146] Table 22. Signaling for non-skipped CU mode when only intra-frame, inter-frame, and PLT modes are allowed based on the third embodiment.
[0147]
[0148] Table 23. Signaling for non-skipped CU mode when only intra-frame, inter-frame, and IBC modes are allowed based on the third embodiment.
[0149]
[0150] Table 24. Signaling for non-skipped CU mode when only intra-frame and IBC modes are allowed based on the third embodiment.
[0151]
[0152] Table 25. Signaling for non-skipped CU mode when only intra-frame and PLT modes are allowed based on the third embodiment.
[0153]
[0154] Table 26. Signaling for non-skipped CU mode when only intra-frame and inter-frame modes are allowed based on the third embodiment.
[0155] In order to transmit the predicted mode via signaling, the video codec first receives video data (610) corresponding to a non-skip mode coded block from the bitstream and determines the parameter set (620) associated with the non-skip mode coded block. This parameter set (such as a sequence parameter set) includes information to include which modes (such as IBC, PLT, etc.) are allowed in the associated bitstream, as shown in Table 1.
[0156] Subsequently, the video codec selectively receives a first, second, or third semantic element from the bitstream. If the parameter set includes information satisfying a first condition, the video codec retrieves the first semantic element (such as `pred_mode_flag` in Table 2) from the bitstream (630). If the parameter set includes information satisfying a second condition, the video codec retrieves the second semantic element (such as `pred_mode_ibc_flag` in Table 2) from the bitstream (640). If the parameter set includes information satisfying a third condition, the video codec retrieves the third semantic element (such as `pred_mode_plt_flag` in Table 2) from the bitstream (650). Refer to Table 2 for the conditions associated with each corresponding semantic element. In some embodiments, if a corresponding condition is not met, the video codec does not receive the corresponding semantic element (e.g., the video codec may assign default values to these semantic elements or not use these semantic elements during decoding).
[0157] Next, the video codec decodes the video data corresponding to the non-skip mode coded block using the corresponding modes based on the values of the received first, second, and third semantic elements. Specifically:
[0158] When both the first semantic element (such as pred_mode_flag in Table 1) and the third semantic element (such as pred_mode_plt_flag in Table 1) have the first value (such as "1"), the video codec uses the palette mode to decode the video data and does not meet the second condition (e.g., the video codec does not receive pred_mode_ibc_flag) (660).
[0159] When the first semantic element (such as pred_mode_flag in Table 1) has a first value (such as "1") and the third semantic element has a second value (such as "0"), the video codec decodes the video data using intra-frame prediction mode. The second condition is not met (e.g., the video codec does not receive pred_mode_ibc_flag) (670).
[0160] When the first semantic element has a second value (such as "0") and the second and third conditions are not met (e.g., the video codec does not receive pred_mode_ibc_flag and pred_mode_plt_flag), the video codec uses the inter-frame prediction mode to decode the video data (680).
[0161] In one or more examples, the described functionality may be implemented in hardware, software, firmware, or any combination thereof. If implemented in software, these functions may be stored as one or more instructions or code on a computer-readable medium or transmitted through a computer-readable medium and executed by a hardware-based processing unit. A computer-readable medium may include a computer-readable storage medium, which corresponds to a tangible medium such as a data storage medium, or a communication medium that includes any medium facilitating the transfer of a computer program from one place to another, for example, according to a communication protocol. In this manner, a computer-readable medium may generally correspond to (1) a non-transitory tangible computer-readable storage medium or (2) a communication medium such as a signal or carrier wave. A data storage medium may be any available medium accessible by one or more computers or one or more processors to retrieve instructions, code, and / or data structures to implement the embodiments described in this application. Computer program products may include computer-readable media.
[0162] The terminology used in the description of the embodiments herein is for the purpose of describing particular embodiments only and is not intended to limit the scope of the claims. The singular forms “a” and “the” used in the description of the embodiments and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and covers any and all possible combinations of one or more of the associated listed items. It will be further understood that, when used in this specification, the term “comprising” specifies the presence of the stated features, elements, and / or components, but does not exclude the presence or addition of one or more other features, elements, components, and / or groups thereof.
[0163] It should also be understood that while the terms first, second, etc., may be used herein to describe various elements, these elements should not be limited to these terms. These terms are used only to distinguish one element from another. For example, without departing from the scope of the embodiments, a first electrode may be referred to as a second electrode, and similarly, a second electrode may be referred to as a first electrode. Both the first electrode and the second electrode are electrodes, but they are not the same electrode.
[0164] The description in this application is presented for illustrative and descriptive purposes and is not intended to be exhaustive or limiting of the invention in the disclosed form. Many modifications, variations, and alternative implementations will be apparent to those skilled in the art from the teachings presented in the foregoing description and the accompanying drawings. The embodiments were chosen and described in order to best explain the principles of the invention, its practical application, and to enable others skilled in the art to understand the various implementations of the invention and to best utilize the basic principles and various implementations with various modifications, as appropriate for the particular intended use. Therefore, it should be understood that the scope of the claims is not limited to the specific examples of the disclosed embodiments, and that modifications and other implementations are intended to be included within the scope of the appended claims.
Claims
1. A method of encoding video data, the method comprising: obtaining a parameter set associated with a non-skip mode coded block; determining to signal a first syntax element, a second syntax element or a third syntax element in a bitstream according to the parameter set including information satisfying different conditions; wherein the third syntax element is signaled in a case that the first syntax element is signaled and has a first value; setting the first syntax element has the first value and the third syntax element has the first value in a condition that the non-skip mode coded block is encoded based on a palette mode; setting the first syntax element has the first value and the third syntax element has a second value in a condition that the non-skip mode coded block is encoded based on an intra prediction mode; and signaling the non-skip mode coded block through the bitstream.
2. The method of claim 1, wherein, The method further comprises: setting the first syntax element has the second value in a condition that the non-skip mode coded block is encoded based on an inter prediction mode.
3. The method of claim 1, wherein, The second syntax element is not signaled in a case that the non-skip mode coded block is encoded based on the palette mode.
4. The method of claim 1, wherein, The second syntax element is not signaled in a case that the non-skip mode coded block is encoded based on the intra prediction mode.
5. The method of claim 1, wherein, The second syntax element and the third syntax element are not signaled in a case that the first syntax element is signaled and has a second value.
6. The method of claim 1, wherein, The first syntax element has a second value or the first syntax element is not signaled, the second syntax element has the first value and the third syntax element is not signaled when the non-skip mode coded block is encoded based on an intra block copy mode. 7.The method of any of claims 1 to 6, wherein, the first syntax element is pred_mode_flag, pred_mode_flag has a second value representing encoded in an inter prediction mode, pred_mode_flag has a first value representing encoded in an intra prediction mode or a palette mode; the second syntax element is pred_mode_ibc_flag, pred_mode_ibc_flag has a first value representing encoded in an intra block copy mode, pred_mode_ibc_flag has a second value representing not encoded in an intra block copy mode; the third syntax element is pred_mode_plt_flag, pred_mode_plt_flag has a second value representing not using a palette mode in a coding unit, pred_mode_plt_flag has a first value representing using a palette mode in a coding unit. 8.A method of decoding video data, the method comprising: obtaining a parameter set associated with a non-skip mode coded block; determining to retrieve a first semantic element, a second semantic element or a third semantic element from the bitstream according to the parameter set including information satisfying different conditions; wherein the third semantic element is received in a case that the first semantic element is received and the first semantic element has a first value; setting the first semantic element to have the first value and the third semantic element to have the first value in a case that the non-skip mode coded block is decoded based on the palette mode; setting the first semantic element to have the first value and the third semantic element to have a second value in a case that the non-skip mode coded block is decoded based on the intra prediction mode.
9. The method of claim 8, wherein, The method further comprises: setting the first semantic element to have the second value in a case that the non-skip mode coded block is decoded based on the inter prediction mode.
10. The method of claim 8, wherein, The second semantic element is not received when the non-skip mode coded block is decoded based on the palette mode.
11. The method of claim 8, wherein, The second semantic element is not received when the non-skip mode coded block is decoded based on the intra prediction mode.
12. The method of claim 8, wherein, The second semantic element and the third semantic element are not received when the first semantic element is received and the first semantic element has a second value.
13. The method of claim 8, wherein, The first semantic element has a second value or the first semantic element is not received, the second semantic element has the first value and the third semantic element is not received when the non-skip mode coded block is decoded based on the intra block copy mode.
14. The method of any of claims 8 to 13, wherein, the first semantic element is pred_mode_flag, pred_mode_flag having a second value representing encoded in inter prediction mode, pred_mode_flag having a first value representing encoded in intra prediction mode or palette mode; the second semantic element is pred_mode_ibc_flag, pred_mode_ibc_flag having a first value representing encoded in intra block copy mode, pred_mode_ibc_flag having a second value representing not encoded in intra block copy mode; the third semantic element is pred_mode_plt_flag, pred_mode_plt_flag having a second value representing palette mode not used in the coding unit, pred_mode_plt_flag having a first value representing palette mode used in the coding unit.
15. An apparatus for encoding video data, comprising: an obtaining unit configured to obtain a parameter set associated with a non-skip mode coded block; a determining unit configured to determine to send a first semantic element, a second semantic element or a third semantic element in a bitstream according to the parameter set including information satisfying different conditions; wherein the third semantic element is sent in a case that the first semantic element is sent and the first semantic element has a first value; a setting unit, which sets the first semantic element to have a first value and the third semantic element to have the first value, on a condition that the non-skip mode coding block is coded based on a palette mode; sets the first semantic element to have the first value and the third semantic element to have a second value, on a condition that the non-skip mode coding block is coded based on an intra prediction mode; and a sending unit, which sends the non-skip mode coding block through the bitstream.
16. A decoding apparatus of video data, comprising: an obtaining unit, which obtains a parameter set associated with a non-skip mode coding block; a determining unit, which determines to retrieve a first semantic element, a second semantic element or a third semantic element from a bitstream according to the parameter set including information satisfying different conditions; wherein the third semantic element is received in a case that the first semantic element is received and the first semantic element has a first value; a setting unit, which sets the first semantic element to have a first value and the third semantic element to have the first value, on a condition that the non-skip mode coding block is decoded based on a palette mode; sets the first semantic element to have the first value and the third semantic element to have a second value, on a condition that the non-skip mode coding block is decoded based on an intra prediction mode.
17. A computer readable storage medium, which stores computer programs / instructions and a bitstream, wherein the computer programs / instructions are executed by a processor to implement the encoding method of video data according to any one of claims 1 to 7 to generate the bitstream, or to implement the decoding method of video data according to any one of claims 8 to 14 to decode the bitstream.
18. A method of storing a bitstream, comprising: generating a bitstream according to the encoding method of video data according to any one of claims 1 to 7; and storing the bitstream, or storing a bitstream, which is decoded according to the decoding method of video data according to any one of claims 8 to 14.
19. A method of transmitting a bitstream, comprising: generating a bitstream according to the encoding method of video data according to any one of claims 1 to 7; and transmitting the bitstream, or transmitting a bitstream, which is decoded according to the decoding method of video data according to any one of claims 8 to 14.