History-Based Motion Vector Predictor Constraints for Merging Estimation Regions
The solution of adding block motion information to the HMVP table in specific conditions enables parallelization with MER, enhancing video encoding and decoding efficiency and reducing artifacts.
Patent Information
- Application Number
- JP2022539378
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2020-12-29
- Filing Date
- 2020-12-30
- Publication Date
- 2025-08-28
- Estimated Expiration
- 2040-12-30
AI Technical Summary
Existing implementations of history-based motion vector predictor (HMVP) prevent the parallelization of merge candidate list derivation when using a merge estimation region (MER), limiting its application in video encoding and decoding processes.
By adding block motion information to the HMVP table when a first block is located in the lower right corner of a motion estimation region, the HMVP can be used simultaneously with MER, enabling parallelization of merge candidate list derivation.
This approach allows for efficient parallel processing of merge candidate lists within MER, improving video encoding and decoding efficiency while maintaining video quality by reducing artifacts and distortions.
Smart Images

Figure 0007730820000001 
Figure 0007730820000002 
Figure 0007730820000003
Abstract
Description
[Technical Field]
[0001] This application claims priority to U.S. Application No. 17 / 136,983, filed December 29, 2020, which claims the benefit of U.S. Provisional Patent Application No. 62 / 955,977, filed December 31, 2019, the entire contents of each of which are incorporated herein by reference.
[0002] TECHNICAL FIELD This disclosure relates to video encoding and decoding. [Background technology]
[0003] Digital video capabilities may be incorporated into a wide range of devices, including digital televisions, digital direct broadcast systems, wireless broadcast systems, personal digital assistants (PDAs), laptop or desktop computers, tablet computers, e-book readers, digital cameras, digital recording devices, digital media players, video gaming devices, video game consoles, cellular or satellite radiotelephones, so-called "smartphones," video teleconferencing devices, video streaming devices, etc. Digital video devices implement video coding techniques, such as those described in standards defined by MPEG-2, MPEG-4, ITU-T H.263, ITU-T H.264 / MPEG-4, Part 10, Advanced Video Coding (AVC), ITU-T H.265 / High Efficiency Video Coding (HEVC), and extensions to such standards. By implementing such video coding techniques, video devices may more efficiently transmit, receive, encode, decode, and / or store digital video information.
[0004] Video coding techniques include spatial (intra-picture) prediction and / or temporal (inter-picture) prediction to reduce or remove redundancy inherent in video sequences. For block-based video coding, a video slice (e.g., a video picture or a portion of a video picture) may be partitioned into video blocks, which are also sometimes referred to as coding tree units (CTUs), coding units (CUs), and / or coding nodes. Video blocks in an intra-coded (I) slice of a picture are encoded using spatial prediction with respect to reference samples in neighboring blocks in the same picture. Video blocks in an inter-coded (P or B) slice of a picture may use spatial prediction with respect to reference samples in neighboring blocks in the same picture or temporal prediction with respect to reference samples in other reference pictures. A picture may be referred to as a frame, and a reference picture may be referred to as a reference frame. Summary of the Invention [Means for solving the problem]
[0005] A merge estimation region (MER) generally refers to a region of one or more blocks in which a video encoder and a video decoder may derive merge candidate lists for the blocks of the region in parallel. As described in more detail below, existing implementations of a history-based motion vector predictor (HMVP) may prevent the parallelization of merge candidate list derivation achieved using an MER. Thus, existing implementations of HMVP may not be able to be used with an MER. This disclosure describes techniques for maintaining an HMVP table in a manner that may enable HMVP to be used with an MER. More specifically, by adding block motion information to an HMVP table in response to determining that a first block is located in the lower right corner of the MER, a video encoder and a video decoder may be able to simultaneously implement HMVP while simultaneously achieving parallelization of the MER.
[0006] According to one example, a method for decoding video data includes steps of storing a history-based motion vector predictor (HMVP) table, determining motion information for a first block of the video data, adding the motion information of the first block to the HMVP table in response to determining that the first block is located in the lower right corner of a motion estimation region (MER), and using the HMVP table to decode a second block of the video data.
[0007] According to another example, a device for decoding video data includes a memory configured to store the video data and one or more processors implemented in a circuit, wherein the one or more processors are configured to store a history-based motion vector predictor (HMVP) table, determine motion information for a first block of the video data, and, in response to determining that the first block is located in a lower right corner of a motion estimation region (MER), add the motion information of the first block to the HMVP table, and use the HMVP table to decode a second block of the video data.
[0008] According to another example, a computer-readable storage medium storing instructions that, when executed by one or more processors, cause the one or more processors to store a history-based motion vector predictor (HMVP) table, determine motion information for a first block of video data, add the motion information of the first block to the HMVP table in response to determining that the first block is located in a lower right corner of a motion estimation region (MER), and use the HMVP table to decode a second block of video data.
[0009] According to another example, an apparatus for decoding video data includes means for storing a history-based motion vector predictor (HMVP) table, means for determining motion information for a first block of the video data, means for adding the motion information of the first block to the HMVP table in response to determining that the first block is located in a lower right corner of a motion estimation region (MER), and means for using the HMVP table to decode a second block of the video data.
[0010] The details of one or more examples are set forth in the accompanying drawings and the description below. Other features, objects, and advantages will become apparent from the description, drawings, and claims. [Brief explanation of the drawings]
[0011] [Figure 1] FIG. 1 is a block diagram illustrating an example video encoding and decoding system that may implement the techniques of this disclosure. [Figure 2A] FIG. 1 is a conceptual diagram illustrating an exemplary quad-tree binary tree (QTBT) structure and corresponding coding tree unit (CTU). [Figure 2B] FIG. 1 is a conceptual diagram illustrating an exemplary quad-tree binary tree (QTBT) structure and corresponding coding tree unit (CTU). [Figure 3] FIG. 1 is a conceptual diagram illustrating an exemplary merge estimation region. [Figure 4] FIG. 2 is a block diagram illustrating an example video encoder that may perform the techniques of this disclosure. [Figure 5] FIG. 2 is a block diagram illustrating an example video decoder that may perform the techniques of this disclosure. [Figure 6] 1 is a flowchart illustrating an exemplary video encoding process. [Figure 7] 1 is a flowchart illustrating an exemplary video decoding process. [Figure 8] 1 is a flowchart illustrating an exemplary video decoding process. DETAILED DESCRIPTION OF THE INVENTION
[0012] Video coding (e.g., video encoding and / or video decoding) typically involves predicting blocks of video data from either already coded blocks of video data in the same picture (e.g., intra prediction) or already coded blocks of video data in a different picture (e.g., inter prediction). In some instances, a video encoder also calculates residual data by comparing the predicted block with the original block. The residual data thus represents the difference between the predicted block and the original block. To reduce the number of bits required to signal the residual data, the video encoder transforms and quantizes the residual data and signals the transformed and quantized residual data in an encoded bitstream. The compression achieved by the transform and quantization processes may be lossy, meaning that the transform and quantization processes may introduce distortion into the decoded video data.
[0013] A video decoder decodes the residual data and adds it to the predictive block to generate a reconstructed video block that matches the original video block more closely than the predictive block alone. Due to losses introduced by transforming and quantizing the residual data, the initial reconstructed block may have distortions or artifacts. One common type of artifact or distortion is called blockiness, where the boundaries of the blocks used to code the video data are visible.
[0014] To further improve the quality of the decoded video, the video decoder may perform one or more filtering operations on the reconstructed video blocks. Examples of these filtering operations include deblocking filtering, sample adaptive offset (SAO) filtering, and adaptive loop filtering (ALF). Parameters for these filtering operations may either be determined by the video encoder and explicitly signaled in the encoded video bitstream, or may be implicitly determined by the video decoder without the parameters having to be explicitly signaled in the encoded video bitstream.
[0015] As described in more detail below, when coding a block of video data using inter prediction, the video encoder and video decoder may be configured to code the block in various modes. One such mode is merge mode. In merge mode, the video encoder and video decoder are configured to generate a list of merge candidates, where each merge candidate in the list includes motion information for predicting the block. The motion information may include, for example, one or more motion vectors and one or more reference picture identifiers.
[0016] By implementing the same list generation process and using only available information from already coded blocks, the video encoder and video decoder can be configured to generate the same list with the same merge candidates in the same order. Thus, for the video encoder to signal motion information in merge mode, the video encoder can include, in the encoded bitstream, an index that identifies one of the merge candidates. Because the video decoder has constructed the same list as the video encoder, the video decoder can determine the motion information associated with the merge candidate associated with the received index. In merge mode, the video decoder determines the predictive block based on the motion information associated with the merge candidate associated with the received index.
[0017] The video encoder and video decoder may generate a list of merge candidates for a block by adding, in a predefined order, motion information of spatially adjacent blocks in the same picture as the block, co-located blocks in different pictures, artificially generated candidates, default candidates, or other such candidates. In some instances, the video encoder and video decoder may also be configured to add history-based candidates including previously used motion information that may not correspond to spatially adjacent blocks or co-located blocks. To determine the history-based candidates, the video encoder and video decoder may each maintain, e.g., store and update, a history-based motion vector predictor (HMVP) table. The video encoder and video decoder may store a predefined number of motion vectors in the HMVP table. As new motion vectors are added to the HMVP table, older motion vectors may be deleted (e.g., on a first-in, first-out basis). In some situations, the video encoder and video decoder may be configured to add motion information of entries from the HMVP table to a list of merge candidates for the merge-coded video block.
[0018] The video encoder and video decoder may also be configured to code a block using a merge estimation region (MER) within a picture of the video data. The video encoder and / or video decoder may be configured to perform merge mode motion vector prediction processes (e.g., motion vector predictor list construction, such as merge candidate list construction) in parallel for multiple blocks (e.g., coding units) within the MER.
[0019] As described in more detail below, existing implementations of HMVP may prevent the parallelization of merge candidate list derivation achieved using MER. Thus, existing implementations of HMVP may not be able to be used with MER. This disclosure describes techniques for maintaining an HMVP table in a manner that may enable HMVP to be used with MER. More specifically, by adding block motion information to an HMVP table in response to determining that a first block is located in the lower-right corner of a motion estimation region, video encoders and video decoders may be able to implement both HMVP and MER simultaneously.
[0020] As used in this disclosure, the term video coding generally refers to either video encoding or video decoding. Similarly, the term video coder may generally refer to a video encoder or a video decoder. Furthermore, some techniques described in this disclosure with respect to video decoding may also apply to video encoding, and vice versa. For example, often, a video encoder and a video decoder are configured to perform the same process or an inverse process. For example, both a video encoder and a video decoder may be configured to use the same rules for generating an HMVP table, such that both the video encoder and the video decoder can maintain the same HMVP table without requiring any significant signaling overhead. Also, a video encoder typically performs video decoding (also called reconstruction) as part of the process of determining how to encode video data.
[0021] 1 is a block diagram illustrating an example video encoding and decoding system 100 that may perform the techniques of this disclosure. The techniques of this disclosure are generally directed to coding (encoding and / or decoding) video data. Generally, video data includes any data for processing video. Thus, video data may include raw uncoded video, coded video, decoded (e.g., reconstructed) video, and video metadata, such as signaling data.
[0022] 1, system 100 includes a source device 102 that, in this example, provides encoded video data to be decoded and displayed by a destination device 116. Specifically, source device 102 provides the video data to destination device 116 via a computer-readable medium 110. Source device 102 and destination device 116 may comprise any of a wide range of devices, including desktop computers, notebook (i.e., laptop) computers, mobile devices, tablet computers, set-top boxes, telephone handsets such as smartphones, televisions, cameras, display devices, digital media players, video gaming consoles, video streaming devices, broadcast receiver devices, etc. In some cases, source device 102 and destination device 116 may be equipped for wireless communication and therefore may be referred to as wireless communication devices.
[0023] In the example of FIG. 1, source device 102 includes a video source 104, memory 106, a video encoder 200, and an output interface 108. Destination device 116 includes an input interface 122, a video decoder 300, memory 120, and a display device 118. According to this disclosure, video encoder 200 of source device 102 and video decoder 300 of destination device 116 may be configured to apply techniques for updating an HMVP table disclosed herein. Thus, source device 102 represents an example of a video encoding device, while destination device 116 represents an example of a video decoding device. In other examples, the source device and destination device may include other components or configurations. For example, source device 102 may receive video data from an external video source, such as an external camera. Similarly, destination device 116 may interface with an external display device rather than including an integrated display device.
[0024] System 100 as shown in FIG. 1 is merely an example. In general, any digital video encoding and / or decoding device may perform the techniques for updating the HMVP table disclosed herein. Source device 102 and destination device 116 are merely examples of coding devices that generate coded video data for source device 102 to transmit to destination device 116. This disclosure refers to devices that perform coding (encoding and / or decoding) of data as “coding” devices. Accordingly, video encoder 200 and video decoder 300 represent examples of coding devices, specifically, video encoders and video decoders, respectively. In some examples, source device 102 and destination device 116 may operate in a substantially symmetric manner, such that each of source device 102 and destination device 116 includes video encoding and decoding components. Thus, system 100 may support unidirectional or bidirectional video transmission between source device 102 and destination device 116, for example, video streaming, video playback, video broadcasting, or video telephony.
[0025] Generally, video source 104 represents a source of video data (i.e., raw, unencoded video data) and provides a continuous series of pictures (also called “frames”) of the video data to video encoder 200, which encodes the data for the pictures. Video source 104 of source device 102 may include a video capture device, such as a video camera, a video archive containing previously captured live video, and / or a video feed interface for receiving video from a video content provider. As a further alternative, video source 104 may generate computer-graphics-based data as source video, or a combination of live, archived, and computer-generated video. In each case, video encoder 200 encodes the captured, pre-captured, or computer-generated video data. Video encoder 200 may reorder the pictures from the order in which they were received (sometimes referred to as “display order”) to a coding order for coding. Video encoder 200 may generate a bitstream including the encoded video data. Source device 102 may then output the encoded video data via output interface 108 onto computer-readable medium 110 for receipt and / or retrieval by input interface 122 of destination device 116, for example.
[0026] Memory 106 of source device 102 and memory 120 of destination device 116 represent general-purpose memory. In some examples, memory 106, 120 may store raw video data, e.g., raw video from video source 104 and raw decoded video data from video decoder 300. Additionally or alternatively, memory 106, 120 may store software instructions executable by video encoder 200 and video decoder 300, respectively, for example. While memory 106 and memory 120 are shown separate from video encoder 200 and video decoder 300 in this example, it should be understood that video encoder 200 and video decoder 300 may also include internal memory for functionally similar or equivalent purposes. Additionally, memory 106, 120 may store encoded video data, e.g., output from video encoder 200 and input to video decoder 300. In some examples, a portion of the memory 106, 120 may be allocated as one or more video buffers, for example, for storing raw decoded and / or encoded video data.
[0027] The computer-readable medium 110 may represent any type of medium or device capable of transporting encoded video data from the source device 102 to the destination device 116. In one example, the computer-readable medium 110 represents a communication medium that enables the source device 102 to transmit encoded video data directly to the destination device 116 in real time, for example, via a radio frequency network or a computer-based network. The output interface 108 may modulate a transmission signal containing the encoded video data, and the input interface 122 may demodulate a received transmission signal, in accordance with a communication standard such as a wireless communication protocol. The communication medium may comprise any wireless or wired communication medium, such as a 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, a wide area network, or a global network such as the Internet. The communication medium may include routers, switches, base stations, or any other equipment that may be useful for facilitating communication from the source device 102 to the destination device 116.
[0028] In some examples, source device 102 may output the encoded data from output interface 108 to storage device 112. Similarly, destination device 116 may access the encoded data from storage device 112 via input interface 122. Storage device 112 may include any of a variety of distributed or locally accessed data storage media, such as a hard drive, Blu-ray disc, DVD, CD-ROM, flash memory, volatile or non-volatile memory, or any other suitable digital storage medium for storing encoded video data.
[0029] In some examples, source device 102 may output the encoded video data to file server 114 or another intermediate storage device that may store the encoded video data generated by source device 102.
[0030] File server 114 may be any type of server device capable of storing encoded video data and transmitting the encoded video data to destination device 116. File server 114 may represent a web server (e.g., for a website), a server configured to provide file transfer protocol services (e.g., File Transfer Protocol (FTP) or File Delivery over Unidirectional Transport (FLUTE) protocol), a content delivery network (CDN) device, a Hypertext Transfer Protocol (HTTP) server, a Multimedia Broadcast Multicast Service (MBMS) or enhanced MBMS (eMBMS) server, and / or a network-attached storage (NAS) device. File server 114 may additionally or alternatively implement one or more HTTP streaming protocols, such as Dynamic Adaptive Streaming over HTTP (DASH), HTTP Live Streaming (HLS), Real Time Streaming Protocol (RTSP), HTTP Dynamic Streaming, etc.
[0031] Destination device 116 may access the encoded video data from file server 114 through any standard data connection, including an Internet connection. This may include a wireless channel (e.g., a Wi-Fi connection), a wired connection (e.g., a digital subscriber line (DSL), a cable modem, etc.), or a combination of both suitable for accessing encoded video data stored on file server 114. Input interface 122 may be configured to operate according to any one or more of the various protocols described above for retrieving or receiving media data from file server 114 or other such protocols for retrieving media data.
[0032] Output interface 108 and input interface 122 may represent a wireless transmitter / receiver, a modem, a wired networking component (e.g., an Ethernet card), a wireless communication component operating according to any of the various IEEE 802.11 standards, or other physical components. In examples in which output interface 108 and input interface 122 comprise wireless components, output interface 108 and input interface 122 may be configured to transfer data, such as encoded video data, according to a cellular communication standard such as 4G, 4G-LTE (Long Term Evolution), LTE-Advanced, 5G, etc. In some examples in which output interface 108 comprises a wireless transmitter, output interface 108 and input interface 122 may be configured to transfer data, such as encoded video data, according to other wireless standards such as the IEEE 802.11 specification, the IEEE 802.15 specification (e.g., ZigBee™), the Bluetooth™ standard, etc. In some examples, source device 102 and / or destination device 116 may include respective system-on-chip (SoC) devices. For example, the source device 102 may include an SoC device for performing functions attributed to the video encoder 200 and / or the output interface 108, and the destination device 116 may include an SoC device for performing functions attributed to the video decoder 300 and / or the input interface 122.
[0033] The techniques of this disclosure may be applied to video coding supporting any of a variety of multimedia applications, such as over-the-air television broadcast, cable television transmission, satellite television transmission, Internet streaming video transmission such as Dynamic Adaptive Streaming over HTTP (DASH), digital video encoded on a data storage medium, decoding of digital video stored on a data storage medium, or other applications.
[0034] The input interface 122 of the destination device 116 receives the encoded video bitstream from the computer-readable medium 110 (e.g., a communication medium, a storage device 112, a file server 114, etc.). The encoded video bitstream may include signaling information defined by the video encoder 200 and also used by the video decoder 300, such as syntax elements having values that describe the characteristics and / or processing of video blocks or other coded units (e.g., slices, pictures, groups of pictures, sequences, etc.). The display device 118 displays decoded pictures of the decoded video data to a user. The display device 118 may represent 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 another type of display device.
[0035] 1, in some examples, video encoder 200 and video decoder 300 may each be integrated with an audio encoder and / or decoder and may include an appropriate MUX-DEMUX unit or other hardware and / or software to process multiplexed streams containing both audio and video in a common data stream. Where applicable, the MUX-DEMUX unit may conform to the ITU H.223 multiplexer protocol or other protocols such as the User Datagram Protocol (UDP).
[0036] The video encoder 200 and the video decoder 300 may each be implemented as any of a variety of suitable encoder and / or decoder 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 the techniques are implemented partially in software, a device may store instructions for the software on a suitable non-transitory computer-readable medium and execute the instructions in hardware using one or more processors to perform the techniques of this disclosure. Each of the video encoder 200 and the video decoder 300 may be included in one or more encoders or decoders, any of which may be integrated as part of a combined encoder / decoder (codec) in the respective device. A device including the video encoder 200 and / or the video decoder 300 may comprise an integrated circuit, a microprocessor, and / or a wireless communication device such as a cellular phone.
[0037] Video encoder 200 and video decoder 300 may operate in accordance with a video coding standard such as ITU-T H.265, also known as High Efficiency Video Coding (HEVC), or extensions thereof, such as multiview and / or scalable video coding extensions. Video encoder 200 and video decoder 300 may additionally or alternatively operate in accordance with other proprietary or industry standards, such as Joint Search and Test Model (JEM), also known as Versatile Video Coding (VVC), or ITU-T H.266. A recent draft of the VVC standard is described in Bross et al., "Versatile Video Coding (Draft 7)," ITU-T SG 16 WP 3 and ISO / IEC JTC 1 / SC 29 / WG 11 Joint Video Experts Team (JVET), 16th Meeting: Geneva, Switzerland, October 1-11, 2019, JVET-P2001-v14 (hereafter "VVC Draft 7"). Another draft of the VVC standard is described in Bross et al., "Versatile Video Coding (Draft 10)," ITU-T SG 16 WP 3 and ISO / IEC JTC 1 / SC 29 / WG 11 Joint Video Experts Team (JVET), 18th Meeting: Teleconference, June 22-July 1, 2020, JVET-S2001-v17 (hereinafter "VVC Draft 10"). However, the techniques of this disclosure are not limited to any particular coding standard.
[0038] Generally, the video encoder 200 and the video decoder 300 may perform block-based coding of pictures. The term “block” generally refers to a structure containing data to be processed (e.g., encoded, decoded, or otherwise used in an encoding and / or decoding process). For example, a block may include a two-dimensional matrix of luminance and / or chrominance data samples. Generally, the video encoder 200 and the video decoder 300 may code video data represented in YUV (e.g., Y, Cb, Cr) format. That is, rather than coding red, green, and blue (RGB) data for the samples of a picture, the video encoder 200 and the video decoder 300 may code luminance and chrominance components, which may include chrominance components of both red and blue hues. In some examples, the video encoder 200 converts received RGB-formatted data to a YUV representation prior to encoding, and the video decoder 300 converts the YUV representation to an RGB format. Alternatively, pre-processing and post-processing units (not shown) may perform these conversions.
[0039] This disclosure may generally refer to coding (e.g., encoding and decoding) a picture to include the process of encoding or decoding data for a picture. Similarly, this disclosure may refer to coding of a block of a picture, e.g., predictive and / or residual coding, to include the process of encoding or decoding data for the block. A coded video bitstream generally includes a series of values for syntax elements that represent coding decisions (e.g., coding modes) and the partitioning of a picture into blocks. Thus, references to coding a picture or a block should generally be understood as coding values for the syntax elements that form the picture or block.
[0040] HEVC defines various blocks, including coding units (CUs), prediction units (PUs), and transform units (TUs). According to HEVC, a video coder (such as video encoder 200) partitions coding tree units (CTUs) into CUs according to a quadtree structure. That is, the video coder partitions CTUs and CUs into four equal, non-overlapping squares, and each node in the quadtree has either zero or four child nodes. A node with no child nodes may be called a "leaf node," and a CU of such a leaf node may include one or more PUs and / or one or more TUs. The video coder may further partition PUs and TUs. For example, in HEVC, a residual quadtree (RQT) represents the partitioning of TUs. In HEVC, a PU represents inter-predicted data, and a TU represents residual data. An intra-predicted CU includes intra-prediction information, such as an intra-mode indication.
[0041] As another example, video encoder 200 and video decoder 300 may be configured to operate according to VVC. According to VVC, a video coder (such as video encoder 200) partitions a picture into multiple coding tree units (CTUs). Video encoder 200 may partition the CTUs according to a tree structure, such as a quadtree-binary tree (QTBT) structure or a multi-type tree (MTT) structure. The QTBT structure eliminates the concept of multiple partition types, such as the distinction between CUs, PUs, and TUs in HEVC. The QTBT structure includes two levels: a first level partitioned according to quadtree partitioning and a second level partitioned according to binary tree partitioning. The root node of the QTBT structure corresponds to a CTU. The leaf nodes of the binary tree correspond to coding units (CUs).
[0042] In the MTT partitioning structure, blocks may be partitioned using quadtree (QT) partitioning, binary tree (BT) partitioning, and one or more types of triple tree (TT) (also called ternary tree (TT)) partitioning. Triple tree or ternary tree partitioning is a partition in which a block is divided into three sub-blocks. In some examples, triple tree or ternary tree partitioning divides a block into three sub-blocks without splitting the original block through the center. The partition types in MTT (e.g., QT, BT, and TT) can be symmetric or asymmetric.
[0043] In some examples, the video encoder 200 and the video decoder 300 may use a single QTBT or MTT structure to represent each of the luminance and chrominance components, while in other examples, the video encoder 200 and the video decoder 300 may use two or more QTBT or MTT structures, such as one QTBT / MTT structure for the luminance component and another QTBT / MTT structure for both chrominance components (or two QTBT / MTT structures for each chrominance component).
[0044] Video encoder 200 and video decoder 300 may be configured to use HEVC-specific quadtree partitioning, QTBT partitioning, MTT partitioning, or other partition structures. For illustrative purposes, the description of the techniques of this disclosure is presented with respect to QTBT partitioning. However, it should be understood that the techniques of this disclosure may also be applied to video coders configured to use quadtree partitioning or other types of partitioning.
[0045] In some examples, a CTU includes a coding tree block (CTB) of luma samples, two corresponding CTBs of chroma samples for a picture with three sample arrays, or a CTB of samples for a picture coded using three separate color planes and syntax structures used to code a monochrome picture or samples. The CTB can be an N×N block of samples for some value of N such that the division of the components into the CTB is partitioned. A component is a single sample from one array or one of three arrays (luma and two chroma) that create a picture in 4:2:0, 4:2:2, or 4:4:4 color format, or a single sample from an array or array that creates a picture in monochrome format. In some examples, a coding block is an M×N block of samples for some value of M and N such that the division of the CTB into coding blocks is partitioned.
[0046] Blocks (e.g., CTUs or CUs) may be grouped in various ways in a picture. As an example, a brick may refer to a rectangular region of a CTU row within a particular tile in a picture. A tile may be a rectangular region of a CTU within a particular tile column and a particular tile row in a picture. A tile column refers to a rectangular region of a CTU with a height equal to the height of the picture and a width specified by a syntax element (e.g., in a picture parameter set, etc.). A tile row refers to a rectangular region of a CTU with a height specified by a syntax element (e.g., in a picture parameter set, etc.) and a width equal to the width of the picture.
[0047] In some examples, a tile may be partitioned into multiple bricks, each of which may include one or more CTU rows within the tile. A tile that is not partitioned into multiple bricks may also be referred to as a brick. However, a brick that is a true subset of a tile may not be referred to as a tile.
[0048] Bricks in a picture may also be arranged in slices. A slice may be an integer number of bricks of a picture that may be contained exclusively in a single Network Abstraction Layer (NAL) unit. In some examples, a slice may contain either a certain number of complete tiles or only a continuous sequence of complete bricks of one tile.
[0049] This disclosure may use "N x N" and "N by N" interchangeably to refer to the sample dimensions of a block (such as a CU or other video block) in terms of the vertical and horizontal dimensions, e.g., 16 x 16 samples or 16 by 16 samples. Generally, a 16 x 16 CU has 16 samples in the vertical direction (y = 16) and 16 samples in the horizontal direction (x = 16). Similarly, an N x N CU generally has N samples in the vertical direction and N samples in the horizontal direction, where N represents a non-negative integer value. Samples in a CU may be arranged in rows and columns. Furthermore, a CU does not necessarily have to have the same number of samples horizontally as vertically. For example, a CU may comprise N x M samples, where M is not necessarily equal to N.
[0050] Video encoder 200 encodes video data for a CU that represents prediction and / or residual information, as well as other information. The prediction information indicates how the CU will be predicted to form a predictive block for the CU. The residual information generally represents sample-by-sample differences between the samples of the CU and the samples of the predictive block prior to encoding.
[0051] To predict a CU, the video encoder 200 may generally form a predictive block for the CU through inter prediction or intra prediction. Inter prediction generally refers to predicting a CU from data of a previously coded picture, while intra prediction generally refers to predicting a CU from previously coded data of the same picture. To perform inter prediction, the video encoder 200 may generate a predictive block using one or more motion vectors. The video encoder 200 may generally perform motion search to identify a reference block that closely matches the CU, for example, with respect to the difference between the CU and the reference block. The video encoder 200 may calculate a difference metric using a sum of absolute differences (SAD), a sum of squared differences (SSD), a mean absolute difference (MAD), a mean squared difference (MSD), or other such difference calculation to determine whether the reference block closely matches the current CU. In some examples, the video encoder 200 may predict the current CU using unidirectional prediction or bidirectional prediction.
[0052] The video encoder 200 may signal motion parameters of a block in various ways. Such motion parameters may include a motion vector, a reference index, a reference picture list indicator, and / or other data related to motion. In some examples, the video encoder 200 and the video decoder 300 may use motion prediction to reduce the amount of data used to signal motion parameters. Motion prediction may comprise determining motion parameters of a block (e.g., a PU, a CU, etc.) based on motion parameters of one or more other blocks. There are various types of motion prediction. For example, merge mode and advanced motion vector prediction (AMVP) mode are two types of motion prediction.
[0053] In merge mode, video encoder 200 generates a candidate list. The candidate list includes a set of candidates indicating motion parameters of one or more source blocks. The source blocks may be spatially or temporally adjacent to the current block. Furthermore, in merge mode, video encoder 200 may select a candidate from the candidate list and use the motion parameters indicated by the selected candidate as the motion parameters of the current block. Video encoder 200 may signal the position in the candidate list of the selected candidate. Video decoder 300 may determine an index into the candidate list based on information obtained from the bitstream. Additionally, video decoder 300 may generate the same candidate list and determine the selected candidate based on the index. Video decoder 300 may then use the motion parameters of the selected candidate to generate a predictor block for the current block.
[0054] Skip mode is similar to merge mode. In skip mode, video encoder 200 and video decoder 300 generate and use candidate lists in the same manner as they use candidate lists in merge mode. However, when video encoder 200 signals motion parameters of a current block using skip mode, video encoder 200 does not signal any residual data for the current block. Thus, video decoder 300 may determine a predictor block for the current block based on one or more reference blocks indicated by the motion parameters of a selected candidate in the candidate list. Video decoder 300 may then reconstruct samples in the coding block of the current block so that the reconstructed samples are equal to corresponding samples in the predictor block of the current block.
[0055] AMVP mode is similar to merge mode in that video encoder 200 may generate a candidate list for the current block and select a candidate from the candidate list. However, for each respective reference block used in determining a predictor block for the current block, video encoder 200 may signal a respective motion vector differential (MVD) for the current block, a respective reference index for the current block, and a respective candidate index indicating the selected candidate in the candidate list. The MVD for the block may indicate the difference between the motion vector of the block and the motion vector of the selected candidate. The reference index for the current block indicates the reference picture from which the reference block is determined.
[0056] Furthermore, when AMVP mode is used, for each respective reference block used in determining a predictor block for the current block, the video decoder 300 may determine an MVD for the current block, a reference index for the current block, a candidate index, and a motion vector prediction (MVP) flag. The video decoder 300 may generate a candidate list and determine a selected candidate in the candidate list based on the candidate index. As described above, this candidate list may include a temporal motion vector predictor derived based on the motion vectors of neighboring blocks associated with the same reference index and the motion parameters of neighboring blocks of the co-located block in the temporal reference picture. The video decoder 300 may reconstruct the motion vector of the current block by adding the MVD to the motion vector indicated by the selected AMVP candidate. That is, the video decoder 300 may determine the motion vector of the current block based on the motion vector and the MVD indicated by the selected AMVP candidate. The video decoder 300 may then use the reconstructed motion vector or the motion vector of the current block to generate a predictor block for the current block.
[0057] When a video coder (e.g., video encoder 200 or video decoder 300) generates an AMVP candidate list for a current block, the video coder may derive one or more AMVP candidates based on motion parameters of reference blocks (e.g., spatially neighboring blocks) that include locations spatially neighboring the current PU, and may derive one or more AMVP candidates based on motion parameters of PUs that are temporally neighboring the current PU. This candidate list may include a temporal motion vector predictor derived based on motion vectors of reference blocks associated with the same reference index as well as motion parameters (i.e., motion parameters) of neighboring blocks of co-located blocks in the temporal reference picture. Candidates in a merge candidate list or an AMVP candidate list based on motion parameters of reference blocks that are temporally neighboring the current block. This disclosure may use the term "temporal motion vector predictor" to refer to a block that is at a different time instance from the current block and is used for motion vector prediction.
[0058] Some examples of VVC also provide an affine motion compensation mode, which may be considered an inter-prediction mode. In the affine motion compensation mode, the video encoder 200 may determine two or more motion vectors that represent non-translational motion, such as zooming in or out, rotation, perspective motion, or other irregular motion types.
[0059] To perform intra prediction, the video encoder 200 may select an intra prediction mode to generate a predictive block. Some examples of VVC provide 67 intra prediction modes, including various directional modes, as well as a planar mode and a DC mode. Generally, the video encoder 200 selects an intra prediction mode that describes neighboring samples relative to a current block (e.g., a block of a CU) from which to predict samples of the current block. Such samples may generally be above, above and to the left, or to the left of the current block in the same picture as the current block, assuming that the video encoder 200 codes CTUs and CUs in raster scan order (left to right, top to bottom).
[0060] Video encoder 200 encodes data representing a prediction mode for the current block. For example, in the case of an inter prediction mode, video encoder 200 may encode data representing which of various available inter prediction modes is used, as well as motion information for the corresponding mode. In the case of unidirectional or bidirectional inter prediction, for example, video encoder 200 may encode motion vectors using AMVP or merge mode. Video encoder 200 may use a similar mode to encode motion vectors for an affine motion compensation mode.
[0061] Following prediction, such as intra-prediction or inter-prediction, of a block, the video encoder 200 may calculate residual data for the block. The residual data, such as a residual block, represents sample-by-sample differences between the block and a predictive block for that block formed using a corresponding prediction mode. The video encoder 200 may apply one or more transforms to the residual block to generate transform data in the transform domain rather than the sample domain. For example, the video encoder 200 may apply a discrete cosine transform (DCT), an integer transform, a wavelet transform, or a conceptually similar transform to the residual video data. In addition, the video encoder 200 may apply a secondary transform, such as a mode-dependent non-separable secondary transform (MDNSST), a signal-dependent transform, or a Karhunen-Loeve transform (KLT), following the first transform. The video encoder 200 generates transform coefficients following application of the one or more transforms.
[0062] As described above, following any transformation to generate transform coefficients, the video encoder 200 may perform quantization of the transform coefficients. Quantization generally refers to a process in which transform coefficients are quantized to possibly reduce the amount of data used to represent the transform coefficients, resulting in further compression. By performing the quantization process, the video encoder 200 may reduce the bit depth associated with some or all of the transform coefficients. For example, the video encoder 200 may round an n-bit value to an m-bit value during quantization, where n is greater than m. In some examples, to perform quantization, the video encoder 200 may perform a bitwise right shift of the value to be quantized.
[0063] Following quantization, the video encoder 200 may scan the transform coefficients and generate a one-dimensional vector from the two-dimensional matrix including the quantized transform coefficients. The scan may be designed to place higher energy (and therefore lower frequency) transform coefficients at the front of the vector and lower energy (and therefore higher frequency) transform coefficients at the back of the vector. In some examples, the video encoder 200 may utilize a predefined scan order for scanning the quantized transform coefficients to generate a serialized vector and then entropy encode the quantized transform coefficients of the vector. In other examples, the video encoder 200 may perform an adaptive scan. After scanning the quantized transform coefficients to form the one-dimensional vector, the video encoder 200 may entropy encode the one-dimensional vector, for example, according to context-adaptive binary arithmetic coding (CABAC). The video encoder 200 may also entropy encode values for syntax elements describing metadata associated with the encoded video data for use by the video decoder 300 in decoding the video data.
[0064] To perform CABAC, video encoder 200 may assign a context in a context model to a symbol to be transmitted. The context may relate, for example, to whether neighboring values of the symbol are zeroed. A probability determination may be based on the context assigned to the symbol.
[0065] Video encoder 200 may further generate syntax data, such as block-based syntax data, picture-based syntax data, and sequence-based syntax data, for example, in a picture header, a block header, a slice header, or other syntax data, such as a sequence parameter set (SPS), a picture parameter set (PPS), or a video parameter set (VPS), to video decoder 300. Video decoder 300 may similarly decode such syntax data to determine how to decode corresponding video data.
[0066] In this manner, video encoder 200 may generate a bitstream including syntax elements that describe encoded video data, e.g., partitions of a picture into blocks (e.g., CUs) and prediction and / or residual information for the blocks. Finally, video decoder 300 may receive the bitstream and decode the encoded video data.
[0067] In general, video decoder 300 performs a process that is the inverse of that performed by video encoder 200 to decode encoded video data of a bitstream. For example, video decoder 300 may decode values for syntax elements of a bitstream using CABAC in a manner that is the inverse of, but substantially similar to, the CABAC encoding process of video encoder 200. The syntax elements may define partition information for the partition of a picture into CTUs and the partition of each CTU according to a corresponding partition structure, such as a QTBT structure, to define the CUs of the CTU. The syntax elements may further define prediction and residual information for blocks of video data (e.g., CUs).
[0068] The residual information may be represented, for example, by quantized transform coefficients. The video decoder 300 may dequantize and inverse transform the quantized transform coefficients of the block to reconstruct a residual block for the block. The video decoder 300 uses the signaled prediction mode (intra-prediction or inter-prediction) and associated prediction information (e.g., motion information for inter-prediction) to form a predictive block for the block. The video decoder 300 may then combine (sample by sample) the predictive block and the residual block to reconstruct the original block. The video decoder 300 may perform additional processing, such as performing a deblocking process to reduce visual artifacts along block boundaries.
[0069] This disclosure generally refers to “signaling” certain information, such as syntax elements. The term “signaling” may generally refer to communication of values for syntax elements and / or other data used to decode encoded video data. That is, video encoder 200 may signal values for syntax elements in a bitstream. Generally, signaling refers to generating values in the bitstream. As mentioned above, source device 102 may transport the bitstream to destination device 116 substantially in real time or not in real time, such as may occur when storing syntax elements to storage device 112 for later retrieval by destination device 116.
[0070] 2A and 2B are conceptual diagrams illustrating an exemplary quadtree-binary tree (QTBT) structure 130 and corresponding coding tree unit (CTU) 132. Solid lines represent quadtree partitioning, and dotted lines represent binary tree partitioning. At each partition (i.e., non-leaf) node of the binary tree, one flag is signaled to indicate which partition type (i.e., horizontal or vertical) is used, where, in this example, 0 indicates horizontal partitioning and 1 indicates vertical partitioning. In the case of quadtree partitioning, there is no need to indicate the partition type because the quadtree node divides a block horizontally and vertically into four equal-sized sub-blocks. Thus, video encoder 200 may encode syntax elements (e.g., partition information) for the region tree level (i.e., solid lines) of QTBT structure 130 and syntax elements (e.g., partition information) for the prediction tree level (i.e., dashed lines) of QTBT structure 130, and video decoder 300 may decode those syntax elements. The video encoder 200 may encode video data, such as prediction data and transform data, for the CUs represented by the terminal leaf nodes of the QTBT structure 130, and the video decoder 300 may decode the video data.
[0071] 2B may be associated with parameters that define the sizes of blocks corresponding to nodes of the QTBT structure 130 at the first and second levels. These parameters may include a CTU size (representing the size of the CTU 132 in the sample), a minimum quadtree size (MinQTSize, representing the minimum allowed quadtree leaf node size), a maximum binary tree size (MaxBTSize, representing the maximum allowed binary tree root node size), a maximum binary tree depth (MaxBTDepth, representing the maximum allowed binary tree depth), and a minimum binary tree size (MinBTSize, representing the minimum allowed binary tree leaf node size).
[0072] The root node of a QTBT structure corresponding to a CTU may have four child nodes at the first level of the QTBT structure, and each child node may be partitioned according to a quadtree partition. That is, a first-level node is either a leaf node (with no child nodes) or has four child nodes. The example QTBT structure 130 represents nodes containing parent and child nodes with solid lines for branching. If first-level nodes are not larger than the maximum allowed binary tree root node size (MaxBTSize), these nodes may be further partitioned by their respective binary trees. The binary tree partitioning of a node may be repeated until the resulting node reaches the minimum allowed binary tree leaf node size (MinBTSize) or the maximum allowed binary tree depth (MaxBTDepth). The example QTBT structure 130 represents nodes with dashed lines for branching. The binary tree leaf nodes are called coding units (CUs), which are used for prediction (e.g., intra-picture or inter-picture prediction) and transformation without further distinction. As explained above, CUs are sometimes called "video blocks" or "blocks."
[0073] In one example of a QTBT partitioning structure, the CTU size is set as 128x128 (luma samples and two corresponding 64x64 chroma samples), MinQTSize is set as 16x16, MaxBTSize is set as 64x64, MinBTSize (for both width and height) is set as 4, and MaxBTDepth is set as 4. To generate quadtree leaf nodes, quadtree partitioning is first applied to the CTU. The quadtree leaf nodes may have sizes from 16x16 (i.e., MinQTSize) to 128x128 (i.e., CTU size). If the quadtree leaf node is 128x128, the quadtree leaf node is not further partitioned by a binary tree because the size exceeds MaxBTSize (i.e., 64x64 in this example). Otherwise, the quadtree leaf node is further partitioned by a binary tree. Therefore, a quadtree leaf node is also the root node of the binary tree and has the binary tree depth as 0. When the binary tree depth reaches MaxBTDepth (4 in this example), further splits are not allowed. A binary tree node with a width equal to MinBTSize (4 in this example) indicates that no further horizontal splits (i.e., dividing the width) are allowed for that binary tree node. Similarly, a binary tree node with a height equal to MinBTSize indicates that no further horizontal splits (i.e., dividing the height) are allowed for that binary tree node. As mentioned above, the leaf nodes of a binary tree are called CUs and are further processed according to the prediction and transformation without further partitioning.
[0074] As introduced above, the video encoder 200 and the video decoder 300 may be configured to code blocks of video data in a merge mode, which is a mode for signaling inter-prediction motion information. The merge candidate list construction process in some exemplary video codecs (e.g., HEVC and VVC) may result in dependencies between neighboring blocks due to the use of spatial merge candidates. In some exemplary video encoder implementations, the motion estimation stage for neighboring blocks (e.g., motion estimation performed by the motion estimation unit 222 of FIG. 3) is typically performed in parallel or at least pipelined to increase throughput. Due to the dependencies between neighboring blocks, the lists of merge candidates for neighboring blocks cannot be generated in parallel, which may represent a bottleneck in parallel encoder / decoder designs.
[0075] Therefore, a parallel merge estimation process was introduced in HEVC. The parallel merge estimation process in HEVC uses an indication of a region (e.g., an MER) in which the video encoder 200 and the video decoder 300 may simultaneously derive merge candidate lists for two or more blocks. The video encoder 200 and the video decoder 300 may derive merge candidate lists for all blocks in the MER in parallel. In some examples, the MER may include a single block. That is, the video encoder 200 (e.g., via the motion estimation unit 222 and the motion compensation unit 224) and the video decoder 300 (e.g., via the motion compensation unit 316) may perform the merge candidate list construction process for multiple blocks within the indicated region (e.g., an MER) in parallel.
[0076] Video encoder 200 and video decoder 300 may determine which blocks to perform the parallel merge candidate list construction process on by checking whether the candidate blocks are within the indicated MER. Candidate blocks within the same MER as the current block are not included in the merge candidate list. Therefore, motion data for such candidates does not need to be available during merge candidate list construction.
[0077] In an example where the size of the MER is 32x32 samples, the video encoder 200 and the video decoder 300 may be configured to construct merge candidate lists for all blocks (e.g., coding units or prediction units) within the 32x32 sample area in parallel, since not all merge candidates within the same 32x32 MER are added to the merge candidate list. Figure 3 shows an example partition of the CTU 150 into seven CUs and ten PUs. The first CU includes PU0 and PU1, the second CU includes PU2, the third CU includes PU3, the fourth CU includes PU4, the fifth CU includes PU5 and PU6, the sixth CU includes PU7, and the seventh CU includes PU8 and PU9. In Figure 3, the CTU 150 includes a 64x64 luma coding tree block. Motion estimation for PUs inside the 32x32 MER 152 (dashed block) is performed independently, allowing for parallel execution of motion estimation (e.g., including merge candidate list construction) for PUs within each MER 152. For illustrative purposes, Figure 3 shows possible spatial merge candidates for PU0, PU5, and PU9.
[0078] In the example of FIG. 3 , merge candidate 154 for PU0 is available for use in the merge candidate list because these merge candidates are outside the 32×32 MER that includes PU0. For the 32×32 MER that includes PU2-PU6, the merge candidate list for PU2-PU6 cannot include motion data from any of PU2-PU6 because merge estimation and merge candidate list construction inside that MER must be independent (e.g., performed in parallel). Thus, for PU5, merge candidate 156 is unavailable because it is within the same MER that includes PU5. Merge candidate 158 for PU5 is unavailable because its candidate location has not yet been coded. Thus, the merge list for PU5 may include only temporal candidates (if available) and zero-MV candidates. For PU9, merge candidate 154 is available because these merge candidates are outside the MER that includes PU9. Merge candidate 156 is unavailable because it is in the same MER as PU9, and merge candidate 158 is unavailable because their candidate locations have not yet been coded.
[0079] To allow an encoder (e.g., video encoder 200) to trade off parallelism and coding efficiency, the parallel merge estimation level (e.g., the size of the MER) may be adaptive and signaled using a syntax element. For example, video encoder 200 may signal a syntax element (e.g., log2_parallel_merge_level_minus2) indicating the size of the MER in a picture parameter set (PPS). In HEVC, the following MER sizes are allowed: 4x4 (parallel merge list construction is not possible), 8x8, 16x16, 32x32, and 64x64. The higher the degree of parallelism enabled by a larger MER, the more potential candidates are excluded from the merge candidate list. However, a larger MER may reduce coding efficiency.
[0080] HMVP in VVC Draft 7 prevents parallelization of merge candidate list derivation. HMVP merge candidates are added to the merge list after spatial MVP and TMVP. In HMVP implemented in VVC Draft 7, motion information of previously coded blocks is stored in a table and used as the MVP for the current CU. During the encoding / decoding process, a table with multiple HMVP candidates is maintained. When a new CTU row is encountered, the table is reset (emptied). Whenever there is a non-subblock inter-coded CU, the associated motion information is added to the final entry of the table as a new HMVP candidate. However, when blocks are coded in parallel within MER, the motion information of previously coded blocks may not be known, thus causing either the inability to use HMVP or a reduction in the parallelism achieved by MER.
[0081] This disclosure describes a process for constraining the addition of HMVP candidates to the HMVP table when using MERs so that both HMVPs and MERs can be used together. According to one technique of this disclosure, updating the HMVP table is constrained so that the associated motion information of the current block is added as a new HMVP candidate to the final entry of the HMVP table if and only if one of the following is true: (1) the size of the current block is greater than or equal to the MER size, or (2) the current block is located in the lower right corner of the current MER. Referring again to Figure 3, PU1, PU6, PU7, and PU9 are examples of blocks located in the lower right corner of the MER.
[0082] For example, when implementing the first condition, video encoder 200 and video decoder 300 may be configured to store an HMVP table, determine motion information for a first block of video data, and, in response to determining that the first block is greater than or equal to the size of the MER, add the motion information for the first block to the HMVP table and use the HMVP table to decode a second block of video data. When implementing the second condition, video encoder 200 and video decoder 300 may be configured to store an HMVP table, determine motion information for a first block of video data, and, in response to determining that the first block is located in the lower right corner of the MER, add the motion information for the first block to the HMVP table and use the HMVP table to decode the second block of video data.
[0083] In some examples, the relevant motion information of the current block is added to the last entry of the table as a new HMVP candidate if and only if one of the following is true: 1) cbWidth >= merSize and cbHeight >= merSize 2) floor(xCb / merSize) < floor (xCb + cbWidth) / merSize and floor(yCb / merSize) < floor(yCb + cbHeight) / merSize where xCb and yCb are the coordinates of the top-left sample within the current block, cbWidth and cbHeight are the width and height of the current block, and merSize is the size of the MER. floor(x) is an operator for obtaining the largest integer value less than or equal to x. For example, video encoder 200 and video decoder 300 may be configured to determine whether the value of the x-coordinate of the top-left sample of the first block plus the width of the first block divided by the size of the MER is greater than the value of the x-coordinate of the top-left sample divided by the size of the MER, and to determine whether the value of the y-coordinate of the top-left sample of the first block plus the height of the first block divided by the size of the MER is greater than the value of the y-coordinate of the top-left sample divided by the size of the MER. The video encoder 200 and the video decoder 300 may be configured to add the motion information of the first block to the HMVP table in response to determining that the value of the x-coordinate of the top-left sample of the first block plus the width of the first block divided by the size of the MER is greater than the value of the x-coordinate of the top-left sample divided by the size of the MER, and in response to determining that the value of the y-coordinate of the top-left sample of the first block plus the height of the first block divided by the size of the MER is greater than the value of the y-coordinate of the top-left sample divided by the size of the MER.
[0084] In another example, the relevant motion information of the current block is added to the last entry of the table as a new HMVP candidate if and only if one of the following is true: 1) cbWidth >= merSize and cbHeight >= merSize 2) floor(xCb / merSize) + 1 == floor (xCb + cbWidth) / merSize and floor(yCb / merSize) + 1 == floor(yCb + cbHeight) / merSize
[0085] In some examples of the present disclosure, a second HMVP table may be maintained. When coding a current block that is inside an MER, the second table is used instead of the original table. Also, the second HMVP table is not updated with the associated motion information of the current block. The original HMVP table is updated with the associated motion information of the current block. When coding a current block that consists of one or more MERs, the original table is used.
[0086] In some examples, a second HMVP table is maintained. When coding a current block inside the MER, the second table is used instead of the original table. Also, the second HMVP table is not updated with the associated motion information of the current block. The original HMVP table is updated with the associated motion information of a limited number of blocks located at several specific positions inside the MER. In some examples, the original HMVP table is updated with the associated motion information of the current block when the current block is located at the bottom right corner of the current MER. In some examples, the original HMVP table is updated with the associated motion information of the current block when the current block is located at the center of the current MER. In some examples, the original HMVP table is updated with the associated motion information of the current block when the current block is located at the top left corner of the current MER.
[0087] 4 is a block diagram illustrating an example video encoder 200 that may perform the techniques of this disclosure. FIG. 4 is provided for purposes of explanation and should not be considered a limitation of the techniques as broadly illustrated and described in this disclosure. For purposes of explanation, this disclosure describes video encoder 200 in accordance with JEM, VVC (ITU-T H.266 under development), and HEVC (ITU-T H.265) techniques. However, the techniques of this disclosure may be performed by video encoding devices configured according to other video coding standards.
[0088] 4, video encoder 200 includes video data memory 230, mode select unit 202, residual generation unit 204, transform processing unit 206, quantization unit 208, inverse quantization unit 210, inverse transform processing unit 212, reconstruction unit 214, filter unit 216, decoded picture buffer (DPB) 218, and entropy encoding unit 220. Any or all of video data memory 230, mode select unit 202, residual generation unit 204, transform processing unit 206, quantization unit 208, inverse quantization unit 210, inverse transform processing unit 212, reconstruction unit 214, filter unit 216, DPB 218, and entropy encoding unit 220 may be implemented in one or more processors or processing circuits. For example, the units of video encoder 200 may be implemented as one or more circuits or logic elements as part of a hardware circuit, or as part of a processor, ASIC, or FPGA. Furthermore, video encoder 200 may include additional or alternative processors or processing circuitry for performing these and other functions.
[0089] Video data memory 230 may store video data to be encoded by components of video encoder 200. Video encoder 200 may receive video data stored in video data memory 230, for example, from video source 104 (FIG. 1). DPB 218 may serve as a reference picture memory that stores reference video data for use in predicting subsequent video data by video encoder 200. Video data memory 230 and DPB 218 may be formed by 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. Video data memory 230 and DPB 218 may be provided by the same memory device or separate memory devices. In various examples, video data memory 230 may be on-chip with other components of video encoder 200, as shown, or may be off-chip relative to those components.
[0090] In this disclosure, references to video data memory 230 should not be construed as limited to memory internal to video encoder 200, unless specifically described as such, or to memory external to video encoder 200, unless specifically described as such. Rather, references to video data memory 230 should be understood as a reference memory that stores video data that video encoder 200 receives for encoding (e.g., video data for the current block to be encoded). Memory 106 of FIG. 1 may also provide temporary storage of outputs from various units of video encoder 200.
[0091] The various units in FIG. 4 are illustrated to aid in understanding the operations performed by video encoder 200. The units may be implemented as fixed-function circuits, programmable circuits, or a combination thereof. A fixed-function circuit refers to a circuit that provides a specific function and is preset for the operations that may be performed. A programmable circuit refers to a circuit that can be programmed to perform various tasks and provides flexibility in the operations that may be performed. For example, a programmable circuit may execute software or firmware that causes the programmable circuit to operate in a manner defined by the software or firmware instructions. A fixed-function circuit may execute software instructions (e.g., to receive or output parameters), but the types of operations that the fixed-function circuit performs are generally invariant. In some examples, one or more of the units may be separate circuit blocks (fixed function or programmable), and in some examples, one or more of the units may be integrated circuits.
[0092] Video encoder 200 may include an arithmetic logic unit (ALU), an elementary function unit (EFU), digital circuits, analog circuits, and / or a programmable core formed from programmable circuits. In examples in which the operations of video encoder 200 are performed using software executed by programmable circuits, memory 106 (FIG. 1) may store instructions (e.g., object code) of the software that video encoder 200 receives and executes, or another memory (not shown) within video encoder 200 may store such instructions.
[0093] The video data memory 230 is configured to store the received video data. The video encoder 200 may retrieve pictures of the video data from the video data memory 230 and provide the video data to the residual generation unit 204 and the mode selection unit 202. The video data in the video data memory 230 may be raw video data to be encoded.
[0094] The mode select unit 202 includes a motion estimation unit 222, a motion compensation unit 224, and an intra prediction unit 226. The mode select unit 202 may include additional functional units for performing video prediction according to other prediction modes. By way of example, the mode select unit 202 may include a palette unit, an intra block copy unit (which may be part of the motion estimation unit 222 and / or the motion compensation unit 224), an affine unit, a linear model (LM) unit, etc.
[0095] The mode selection unit 202 typically coordinates multiple coding passes to test combinations of coding parameters and the resulting rate-distortion values for such combinations. The coding parameters may include partitioning of the CTUs into CUs, prediction modes for the CUs, transform types for residual data of the CUs, quantization parameters for residual data of the CUs, etc. The mode selection unit 202 may ultimately select a combination of coding parameters that has a better rate-distortion value than the other tested combinations.
[0096] Video encoder 200 may partition a picture retrieved from video data memory 230 into a series of CTUs and encapsulate one or more CTUs within a slice. Mode select unit 202 may partition the CTUs of the picture according to a tree structure, such as the QTBT structure or quadtree structure of HEVC described above. As described above, video encoder 200 may form one or more CUs from partitioning the CTUs according to the tree structure. Such CUs may also be generally referred to as "video blocks" or "blocks."
[0097] Generally, mode select unit 202 also controls its components (e.g., motion estimation unit 222, motion compensation unit 224, and intra prediction unit 226) to generate a predictive block for a current block (e.g., a current CU, or in HEVC, an overlapping portion of a PU and TU). In the case of inter prediction of the current block, motion estimation unit 222 may perform motion search to identify one or more closely matching reference blocks in one or more reference pictures (e.g., one or more previously coded pictures stored in DPB 218). Specifically, motion estimation unit 222 may calculate a value representing how similar a potential reference block is to the current block according to, for example, a sum of absolute differences (SAD), a sum of squared differences (SSD), a mean absolute difference (MAD), a mean squared difference (MSD), etc. Motion estimation unit 222 may generally perform these calculations using sample-by-sample differences between the current block and the reference block under consideration. Motion estimation unit 222 may identify the reference block having the lowest value resulting from these calculations, which indicates the reference block that most closely matches the current block.
[0098] The motion estimation unit 222 may form one or more motion vectors (MVs) that define the position of a reference block in a reference picture relative to the position of the current block in the current picture. The motion estimation unit 222 may then provide the motion vectors to the motion compensation unit 224. For example, in the case of unidirectional inter prediction, the motion estimation unit 222 may provide a single motion vector, while in the case of bidirectional inter prediction, the motion estimation unit 222 may provide two motion vectors. The motion compensation unit 224 may then generate a predictive block using the motion vectors. For example, the motion compensation unit 224 may use the motion vectors to retrieve data of the reference block. As another example, if the motion vectors have fractional sample precision, the motion compensation unit 224 may interpolate values for the predictive block according to one or more interpolation filters. Furthermore, in the case of bidirectional inter prediction, the motion compensation unit 224 may retrieve data for the two reference blocks identified by the respective motion vectors and combine the retrieved data, for example, by sample-wise averaging or weighted averaging. The motion estimation unit 222 and the motion compensation unit 224 may be configured to code the blocks using MER, as described above.
[0099] As another example, for intra prediction or intra predictive coding, the intra prediction unit 226 may generate a predictive block from samples neighboring the current block. For example, for a directional mode, the intra prediction unit 226 may generally mathematically combine the values of neighboring samples and populate these calculated values in a defined direction across the current block to generate a predictive block. As another example, for a DC mode, the intra prediction unit 226 may calculate the average of neighboring samples for the current block and generate a predictive block to include this resulting average for each sample of the predictive block.
[0100] The mode select unit 202 provides the predictive block to the residual generation unit 204. The residual generation unit 204 receives a raw, uncoded version of the current block from the video data memory 230 and receives the predictive block from the mode select unit 202. The residual generation unit 204 calculates sample-by-sample differences between the current block and the predictive block. The resulting sample-by-sample differences define a residual block for the current block. In some examples, the residual generation unit 204 may also determine differences between sample values in the residual block to generate the residual block using residual differential pulse code modulation (RDPCM). In some examples, the residual generation unit 204 may be formed using one or more subtractor circuits that perform binary subtraction.
[0101] In examples in which mode select unit 202 partitions CUs into PUs, each PU may be associated with a luma prediction unit and a corresponding chroma prediction unit. Video encoder 200 and video decoder 300 may support PUs with various sizes. As indicated above, the size of a CU may refer to the size of the luma coding block of the CU, and the size of a PU may refer to the size of the luma prediction unit of the PU. Assuming that the size of a particular CU is 2N×2N, video encoder 200 may support a PU size of 2N×2N or N×N for intra prediction, and a symmetric PU size of 2N×2N, 2N×N, N×2N, N×N, or similar for inter prediction. Video encoder 200 and video decoder 300 may also support asymmetric partitioning for PU sizes of 2N×nU, 2N×nD, nL×2N, and nR×2N for inter prediction.
[0102] In examples where the mode select unit 202 does not further partition the CUs into PUs, each CU may be associated with a luma coding block and a corresponding chroma coding block. As described above, the size of a CU may refer to the size of the luma coding block of the CU. The video encoder 200 and the video decoder 300 may support CU sizes of 2N×2N, 2N×N, or N×2N.
[0103] For other video coding techniques, such as intra block copy mode coding, affine mode coding, and linear model (LM) mode coding, as a few examples, mode select unit 202 generates a predictive block for the current block being coded via a respective unit associated with the coding technique. In some examples, such as palette mode coding, mode select unit 202 may not generate a predictive block, but instead may generate syntax elements that indicate how to reconstruct the block based on a selected palette. In such modes, mode select unit 202 may provide these syntax elements to entropy coding unit 220 to be coded.
[0104] As described above, the residual generation unit 204 receives video data for a current block and a corresponding predictive block. The residual generation unit 204 then generates a residual block for the current block. To generate the residual block, the residual generation unit 204 calculates sample-by-sample differences between the predictive block and the current block.
[0105] Transform processing unit 206 applies one or more transforms to the residual block to generate a block of transform coefficients (referred to herein as a "transform coefficient block"). Transform processing unit 206 may apply various transforms to the residual block to form the transform coefficient block. For example, transform processing unit 206 may apply a discrete cosine transform (DCT), a directional transform, a Karhunen-Loeve transform (KLT), or a conceptually similar transform to the residual block. In some examples, transform processing unit 206 may perform multiple transforms, e.g., a primary transform and a secondary transform, such as a rotation transform, on the residual block. In some examples, transform processing unit 206 does not apply a transform to the residual block.
[0106] The quantization unit 208 may quantize the transform coefficients in the transform coefficient block to generate a quantized transform coefficient block. The quantization unit 208 may quantize the transform coefficients of the transform coefficient block according to a quantization parameter (QP) value associated with the current block. The video encoder 200 (e.g., via the mode select unit 202) may adjust the degree of quantization applied to the transform coefficient block associated with the current block by adjusting the QP value associated with the CU. Quantization may result in loss of information, and therefore, the quantized transform coefficients may have lower precision than the original transform coefficients generated by the transform processing unit 206.
[0107] Inverse quantization unit 210 and inverse transform processing unit 212 may apply inverse quantization and inverse transform, respectively, to the quantized transform coefficient block to reconstruct a residual block from the transform coefficient block. Reconstruction unit 214 may generate a reconstructed block that corresponds to the current block (potentially with some distortion) based on the reconstructed residual block and the predictive block generated by mode select unit 202. For example, reconstruction unit 214 may add samples of the reconstructed residual block to corresponding samples from the predictive block generated by mode select unit 202 to generate the reconstructed block.
[0108] Filter unit 216 may perform one or more filter operations on the reconstructed blocks. For example, filter unit 216 may perform a deblocking operation to reduce blockiness artifacts along the edges of a CU. The operations of filter unit 216 may be skipped in some examples.
[0109] Video encoder 200 stores the reconstructed blocks in DPB 218. For example, in examples where the operation of filter unit 216 is not required, reconstruction unit 214 may store the reconstructed blocks in DPB 218. In examples where the operation of filter unit 216 is required, filter unit 216 may store the filtered reconstructed blocks in DPB 218. Motion estimation unit 222 and motion compensation unit 224 may retrieve reference pictures formed from the reconstructed (and potentially filtered) blocks from DPB 218 to inter-predict blocks of a later-encoded picture. Additionally, intra-prediction unit 226 may use reconstructed blocks in DPB 218 of the current picture to intra-predict other blocks in the current picture.
[0110] In general, entropy encoding unit 220 may entropy encode syntax elements received from other functional components of video encoder 200. For example, entropy encoding unit 220 may entropy encode quantized transform coefficient blocks from quantization unit 208. As another example, entropy encoding unit 220 may entropy encode predictive syntax elements (e.g., motion information for inter-prediction or intra-mode information for intra-prediction) from mode select unit 202. Entropy encoding unit 220 may perform one or more entropy encoding operations on syntax elements, which are another example of video data, to generate entropy-encoded data. For example, entropy encoding unit 220 may perform a context-adaptive variable length coding (CAVLC) operation, a CABAC operation, a variable-to-variable (V2V) length coding operation, a syntax-based context-adaptive binary arithmetic coding (SBAC) operation, a probability interval partitioned entropy (PIPE) coding operation, an exponential-Golomb coding operation, or another type of entropy coding operation on the data. In some examples, entropy encoding unit 220 may operate in a bypass mode in which syntax elements are not entropy coded.
[0111] Video encoder 200 may output a bitstream that includes entropy-encoded syntax elements needed to reconstruct blocks of a slice or picture. Specifically, entropy encoding unit 220 may output the bitstream.
[0112] The operations described above are described with respect to blocks. Such descriptions should be understood as operations for luma coding blocks and / or chroma coding blocks. As described above, in some examples, the luma coding blocks and chroma coding blocks are luma and chroma components of a CU. In some examples, the luma coding blocks and chroma coding blocks are luma and chroma components of a PU.
[0113] In some examples, operations performed with respect to luma coding blocks need not be repeated for chroma coding blocks. As one example, operations for identifying motion vectors (MVs) and reference pictures for luma coding blocks need not be repeated to identify MVs and reference pictures for chroma coding blocks. Rather, MVs for luma coding blocks may be scaled to determine MVs for chroma coding blocks, and the reference pictures may be the same. As another example, the intra prediction process may be the same for luma coding blocks and chroma coding blocks.
[0114] Video encoder 200 represents an example of a device configured to encode video data, including a memory configured to store the video data and one or more processing units implemented in a circuit and configured to perform the techniques of this disclosure. For example, mode select unit 202 (e.g., motion estimation unit 222 and / or motion compensation unit 224) may store an HMVP table to be used when constructing a merge candidate list for a block coded in merge mode. Mode select unit 202 may determine motion information for a first block of video data and, in response to determining that the first block is located in the lower right corner of the MER, add the motion information of the first block to the HMVP table and use the HMVP table to decode a second block of video data. Mode select unit 202 may, for example, use entries from the HMVP table to generate a merge candidate list for the second block.
[0115] 5 is a block diagram illustrating an example video decoder 300 that may perform the techniques of this disclosure. Figure 5 is provided for purposes of explanation and does not limit the techniques as broadly illustrated and described in this disclosure. For purposes of explanation, this disclosure describes a video decoder 300 in accordance with JEM, VVC (ITU-T H.266 under development), and HEVC (ITU-T H.265) techniques. However, the techniques of this disclosure may be performed by video coding devices configured according to other video coding standards.
[0116] In the example of Figure 5, the video decoder 300 includes a coded picture buffer (CPB) memory 320, an entropy decoding unit 302, a prediction processing unit 304, an inverse quantization unit 306, an inverse transform processing unit 308, a reconstruction unit 310, a filter unit 312, and a decoded picture buffer (DPB) 314. Any or all of the CPB memory 320, the entropy decoding unit 302, the prediction processing unit 304, the inverse quantization unit 306, the inverse transform processing unit 308, the reconstruction unit 310, the filter unit 312, and the DPB 314 may be implemented in one or more processors or processing circuits. For example, the units of the video decoder 300 may be implemented as one or more circuits or logic elements as part of a hardware circuit, or as part of a processor, ASIC, or FPGA. Furthermore, the video decoder 300 may include additional or alternative processors or processing circuits for performing these and other functions.
[0117] Prediction processing unit 304 includes a motion compensation unit 316 and an intra prediction unit 318. Prediction processing unit 304 may include additional units for performing prediction according to other prediction modes. By way of example, prediction processing unit 304 may include a palette unit, an intra block copy unit (which may form part of motion compensation unit 316), an affine unit, a linear model (LM) unit, etc. In other examples, video decoder 300 may include more, fewer, or different functional components.
[0118] CPB memory 320 may store video data, such as an encoded video bitstream, to be decoded by components of video decoder 300. The video data stored in CPB memory 320 may be retrieved, for example, from computer-readable medium 110 (FIG. 1). CPB memory 320 may include a CPB that stores encoded video data (e.g., syntax elements) from the encoded video bitstream. CPB memory 320 may also store video data other than syntax elements of coded pictures, such as temporary data representing output from various units of video decoder 300. DPB 314 generally stores decoded pictures that video decoder 300 may output and / or use as reference video data when decoding subsequent data or pictures of the encoded video bitstream. CPB memory 320 and DPB 314 may be formed by any of a variety of memory devices, such as DRAM, including SDRAM, MRAM, RRAM, or other types of memory devices. The CPB memory 320 and the DPB 314 may be provided by the same memory device or separate memory devices. In various examples, the CPB memory 320 may be on-chip with other components of the video decoder 300 or off-chip relative to those components.
[0119] Additionally or alternatively, in some examples, video decoder 300 may retrieve coded video data from memory 120 (FIG. 1). That is, memory 120 may store data such as those described above with respect to CPB memory 320. Similarly, memory 120 may store instructions to be executed by video decoder 300 when some or all of the functionality of video decoder 300 is implemented in software to be executed by processing circuitry of video decoder 300.
[0120] The various units shown in FIG. 5 are illustrated to aid in understanding the operations performed by video decoder 300. The units may be implemented as fixed-function circuits, programmable circuits, or a combination thereof. As with FIG. 4, fixed-function circuits refer to circuits that provide specific functions and are preset for the operations that may be performed. Programmable circuits refer to circuits that may be programmed to perform various tasks and provide flexibility in the operations that may be performed. For example, a programmable circuit may execute software or firmware that causes the programmable circuit to operate in a manner defined by the software or firmware instructions. While a fixed-function circuit may execute software instructions (e.g., to receive or output parameters), the types of operations that the fixed-function circuit performs are generally invariant. In some examples, one or more of the units may be separate circuit blocks (fixed function or programmable), and in some examples, one or more of the units may be integrated circuits.
[0121] The video decoder 300 may include a programmable core formed from an ALU, an EFU, digital circuits, analog circuits, and / or programmable circuits. In examples in which the operations of the video decoder 300 are performed by software executing on programmable circuits, on-chip or off-chip memory may store instructions (e.g., object code) of the software that the video decoder 300 receives and executes.
[0122] The entropy decoding unit 302 may receive the encoded video data from the CPB and entropy decode the video data to recover the syntax elements. The prediction processing unit 304, the inverse quantization unit 306, the inverse transform processing unit 308, the reconstruction unit 310, and the filter unit 312 may generate decoded video data based on the syntax elements extracted from the bitstream.
[0123] In general, video decoder 300 reconstructs a picture on a block-by-block basis. Video decoder 300 may perform a reconstruction operation on each block individually (where the block currently being reconstructed, i.e., decoded, may be referred to as the “current block”).
[0124] The entropy decoding unit 302 may entropy decode the quantized transform coefficients of the quantized transform coefficient block as well as syntax elements defining transform information, such as a quantization parameter (QP) and / or a transform mode indication. The inverse quantization unit 306 may use the QP associated with the quantized transform coefficient block to determine the degree of quantization and, similarly, the degree of inverse quantization to apply. The inverse quantization unit 306 may, for example, perform a bitwise left-shift operation to inverse quantize the quantized transform coefficients. The inverse quantization unit 306 may thereby form a transform coefficient block including the transform coefficients.
[0125] After the inverse quantization unit 306 forms the transform coefficient block, the inverse transform processing unit 308 may apply one or more inverse transforms to the transform coefficient block to generate a residual block associated with the current block. For example, the inverse transform processing unit 308 may apply an inverse DCT, an inverse integer transform, an inverse Karhunen-Loeve transform (KLT), an inverse rotational transform, an inverse transform, or another inverse transform to the transform coefficient block.
[0126] Further, prediction processing unit 304 generates a predictive block according to the prediction information syntax element entropy decoded by entropy decoding unit 302. For example, if the prediction information syntax element indicates that the current block is inter-predicted, motion compensation unit 316 may generate a predictive block. In this case, the prediction information syntax element may indicate a reference picture in DPB 314 from which to retrieve a reference block, as well as a motion vector that identifies the location of the reference block in the reference picture relative to the location of the current block in the current picture. Motion compensation unit 316 may generally perform the inter-prediction process in a manner substantially similar to that described with respect to motion compensation unit 224 (FIG. 4). Motion compensation unit 316 may be configured to decode blocks using MER, as described above.
[0127] As another example, if the prediction information syntax element indicates that the current block is intra-predicted, intra prediction unit 318 may generate a predictive block according to the intra-prediction mode indicated by the prediction information syntax element. Again, intra prediction unit 318 may generally perform the intra-prediction process in a manner substantially similar to that described with respect to intra prediction unit 226 (FIG. 4). Intra prediction unit 318 may retrieve data of neighboring samples for the current block from DPB 314.
[0128] The reconstruction unit 310 may reconstruct the current block using the predictive block and the residual block. For example, the reconstruction unit 310 may add samples of the residual block to corresponding samples of the predictive block to reconstruct the current block.
[0129] Filter unit 312 may perform one or more filter operations on the reconstructed blocks. For example, filter unit 312 may perform a deblocking operation to reduce blockiness artifacts along the edges of the reconstructed blocks. The operations of filter unit 312 may not be performed in all instances.
[0130] The video decoder 300 may store the reconstructed block in the DPB 314. For example, in examples where the operations of the filter unit 312 are not performed, the reconstruction unit 310 may store the reconstructed block in the DPB 314. In examples where the operations of the filter unit 312 are performed, the filter unit 312 may store the filtered reconstructed block in the DPB 314. As described above, the DPB 314 may provide reference information to the prediction processing unit 304, such as samples of the current picture for intra prediction and previously decoded pictures for subsequent motion compensation. Additionally, the video decoder 300 may output the decoded picture (e.g., the decoded video) from the DPB 314 for later presentation on a display device, such as the display device 118 of FIG. 1 .
[0131] Video decoder 300 represents an example of a device configured to decode video data, including a memory configured to store video data and one or more processing units implemented in a circuit and configured to perform the techniques of this disclosure. For example, prediction processing unit 304 (e.g., motion compensation unit 316) may store an HMVP table to be used when constructing a merge candidate list for a block coded in merge mode. Prediction processing unit 304 may determine motion information for a first block of video data and, in response to determining that the first block is located in the lower right corner of the MER, add the motion information of the first block to the HMVP table and use the HMVP table to decode a second block of video data. Prediction processing unit 304 may, for example, use entries from the HMVP table to generate a merge candidate list for the second block.
[0132] 6 is a flowchart illustrating an example process for encoding a current block. The current block may comprise a current CU. Although described with respect to video encoder 200 (FIGS. 1 and 4), it should be understood that other devices may be configured to perform a process similar to that of FIG.
[0133] In this example, video encoder 200 first predicts the current block (350). As part of predicting the block, video encoder 200 may maintain one or more HMVP tables disclosed herein and may update those tables according to the techniques described herein. For example, video encoder 200 may form a predictive block for the current block. Video encoder 200 may then calculate a residual block for the current block (352). To calculate the residual block, video encoder 200 may calculate the difference between the original uncoded block and the predictive block for the current block. Video encoder 200 may then transform the residual block and quantize the transform coefficients of the residual block (354). Next, video encoder 200 may scan the quantized transform coefficients of the residual block (356). During or following the scan, video encoder 200 may entropy code the transform coefficients (358). For example, video encoder 200 may encode the transform coefficients using CAVLC or CABAC. Video encoder 200 may then output the entropy-coded data for the block (360).
[0134] 7 is a flowchart illustrating an example process for decoding a current block of video data. The current block may comprise a current CU. Although described with respect to video decoder 300 (FIGS. 1 and 5), it should be understood that other devices may be configured to perform a process similar to that of FIG.
[0135] The video decoder 300 may receive entropy-coded data for the current block, such as entropy-coded prediction information and entropy-coded data for the coefficients of the residual block corresponding to the current block (370). The video decoder 300 may entropy decode the entropy-coded data to determine prediction information for the current block and to reconstruct the coefficients of the residual block (372). The video decoder 300 may predict the current block, e.g., using an intra-prediction mode or an inter-prediction mode as indicated by the prediction information for the current block, to calculate a predictive block for the current block (374). As part of predicting the block, the video decoder 300 may maintain one or more HMVP tables disclosed herein and may update those tables according to the techniques described herein. The video decoder 300 may then inverse-scan the reconstructed coefficients to create a block of quantized transform coefficients (376). The video decoder 300 may then inverse-quantize and inverse-transform the transform coefficients to generate a residual block (378). Video decoder 300 may finally decode the current block by combining the predictive block and the residual block (380).
[0136] 8 is a flowchart illustrating an example process for decoding a current block of video data. The current block may comprise a current CU. The techniques of FIG. 8 are described with respect to a general-purpose video decoder, which may correspond, for example, to the video decoding loop of video decoder 300 (FIGS. 1 and 5), video encoder 200 (FIGS. 1 and 4), or any other such video decoder.
[0137] The video decoder stores an HMVP table (400). The video decoder may, for example, maintain the HMVP table, and as new blocks are decoded, the video decoder may add motion information used to decode the new blocks to the HMVP table. The decoder may also periodically remove entries from the HMVP table to limit the size of the table. The video decoder determines motion information for a first block of video data (402). The video decoder may, for example, use the determined motion information to inter-predict the first block.
[0138] The video decoder adds the motion information of the first block to the HMVP table in response to determining that the first block is located in the lower right corner of the MER (404). The MER may be the first MER, and the second block may belong to the second MER. To add the motion information of the first block to the HMVP table in response to determining that the first block is located in the lower right corner of the MER, the video decoder may, for example, determine whether the value of the x-coordinate of the top-left sample of the first block plus the width of the first block divided by the size of the MER is greater than the value of the x-coordinate of the top-left sample divided by the size of the MER, and determine whether the value of the y-coordinate of the top-left sample of the first block plus the height of the first block divided by the size of the MER is greater than the value of the y-coordinate of the top-left sample divided by the size of the MER. In response to determining that the value of the x-coordinate of the top-left sample of the first block plus the width of the first block divided by the size of the MER is greater than the value of the x-coordinate of the top-left sample divided by the size of the MER, and in response to determining that the value of the y-coordinate of the top-left sample of the first block plus the height of the first block divided by the size of the MER is greater than the value of the y-coordinate of the top-left sample divided by the size of the MER, the video decoder may add the motion information of the first block to the HMVP table.
[0139] The video decoder uses the HMVP table to decode the second block of video data (406). To use the HMVP table to decode the second block of video data, the video decoder may be configured to generate a candidate list of motion information for the second block, e.g., including candidates from the HMVP table, select a candidate from the motion information candidate list, and use the selected candidate to decode the second block of video data. The video decoder may, for example, output decoded video data including decoded versions of the first block and the second block. In an implementation in which the video decoder is operating to perform a video encoding process, the video decoder may store one or more decoded pictures including the decoded versions of the first block and the second block and use the one or more stored decoded pictures to encode other blocks of other pictures of the video data.
[0140] The following clauses represent exemplary implementations of the techniques and devices introduced above.
[0141] Clause 1: A method for coding video data includes storing a table of history-based motion vector predictors (HMVPs), determining motion information for a current block of the video data, and updating the table of history-based motion vector predictors based on the determined motion information for the current block, according to any technique or combination of techniques described in this disclosure.
[0142] Clause 2: The method of clause 1, wherein the step of updating the HMVP table based on the determined motion information of the current block comprises the step of adding the motion information of the current block to the HMVP table in response to determining that the current block is greater than or equal to the size of the motion estimation region.
[0143] Clause 3: The method of clause 1, wherein the step of updating the HMVP table based on the determined motion information of the current block comprises the step of adding the motion information of the current block to the HMVP table in response to determining that the current block is located in the lower right corner of the motion estimation region.
[0144] Clause 4: The method of any of clauses 1 to 3 further includes, for a second current block that is coded after the current block, generating a candidate list for the second current block by adding candidates from the HMVP table to the candidate list.
[0145] Clause 5: A method for coding video data includes storing a first table of a history-based motion vector predictor (HMVP), storing a second table of the HMVP, determining motion information for a current block of the video data, and updating the first table of the HMVP and / or the second table of the HMVP based on the determined motion information for the current block, according to any technique or combination of techniques described in this disclosure.
[0146] Clause 6: The method of clause 5 further includes, for a second current block coded after the current block, generating a candidate list for the second current block by adding candidates from the HMVP first table or the HMVP second table to the candidate list.
[0147] Clause 7: The method of any of clauses 1 to 6, wherein the coding step comprises a decoding step.
[0148] Clause 8: The method of any of clauses 1 to 6, wherein the coding step comprises the step of encoding.
[0149] Clause 9: A device for coding video data, comprising one or more means for performing the method of any of clauses 1 to 8.
[0150] Clause 10: The device of clause 9, wherein the one or more means comprise one or more processors implemented in circuitry.
[0151] Clause 11: The device of clause 9 or 10, further comprising a memory for storing video data.
[0152] Clause 12: The device of any of clauses 9 to 11, further comprising a display configured to display the decoded video data.
[0153] Clause 13: Any device of clauses 9 to 12, comprising one or more of a camera, a computer, a mobile device, a broadcast receiver device, or a set-top box.
[0154] Clause 14: A device according to any of clauses 9 to 13, comprising a video decoder.
[0155] Clause 15: A device according to any one of clauses 9 to 14, comprising a video encoder.
[0156] Clause 16: A computer-readable storage medium storing instructions that, when executed, cause one or more processors to perform the method of any of clauses 1 to 8.
[0157] It should be appreciated that, depending on the example, some acts or events of any of the techniques described herein may be performed in a different sequence, or may be added, combined, or omitted entirely (e.g., not all acts or events described may be necessary to practice the techniques). Furthermore, in some examples, acts or events may be performed simultaneously rather than sequentially, for example, through multithreaded processing, interrupt processing, or multiple processors.
[0158] In one or more examples, the functions described may be implemented in hardware, software, firmware, or any combination thereof. If implemented in software, the functions may be stored on or transmitted via a computer-readable medium as one or more instructions or code and executed by a hardware-based processing unit. Computer-readable media may include computer-readable storage media, which correspond to tangible media such as data storage media, or communication media, including any medium that facilitates transfer of a computer program from one place to another, for example, according to a communication protocol. As such, computer-readable media may generally correspond to (1) non-transitory tangible computer-readable storage media or (2) communication media such as a signal or carrier wave. Data storage media may be any available medium that can be accessed by one or more computers or one or more processors to retrieve instructions, code, and / or data structures for implementing the techniques described in this disclosure. A computer program product may include a computer-readable medium.
[0159] By way of example, and not limitation, such computer-readable storage media may comprise 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 desired program code in the form of instructions or data structures and that can be accessed by a computer. Also, any connection is properly termed a computer-readable medium. For example, if instructions are transmitted from a website, server, or other remote source using coaxial cable, fiber optic cable, twisted pair, digital subscriber line (DSL), or wireless technologies such as infrared, radio, and microwave, the coaxial cable, fiber optic cable, twisted pair, DSL, or wireless technologies such as infrared, radio, and microwave are included within the definition of medium. However, it should be understood that computer-readable storage media and data storage media do not include connections, carrier waves, signals, or other transitory media, but instead cover non-transitory tangible storage media. As used herein, disk and disc include compact discs (CDs), laser discs, optical discs, digital versatile discs (DVDs), floppy disks, and Blu-ray discs, where disks typically reproduce data magnetically and discs reproduce data optically using lasers. Combinations of the above should also be included within the scope of computer-readable media.
[0160] The instructions may be executed by one or more processors, such as one or more DSPs, general-purpose microprocessors, application-specific integrated circuits (ASICs), FPGAs, or other equivalent integrated or discrete logic circuitry. Accordingly, the terms "processor" and "processing circuitry," as used herein, may refer to any of the above structures or any other structure suitable for implementing the techniques described herein. Additionally, in some aspects, the functionality described herein may be provided within dedicated hardware and / or software modules configured for encoding and decoding, or may be incorporated into a combined codec. Also, the techniques may be implemented entirely in one or more circuits or logic elements.
[0161] The techniques of this disclosure may be implemented in a wide variety of devices or apparatuses, including wireless handsets, integrated circuits (ICs), or sets of ICs (e.g., chipsets). Various components, modules, or units are described in this disclosure to highlight functional aspects of devices configured to perform the disclosed techniques, but they do not necessarily require realization by different hardware units. Rather, as described above, the various units may be combined in a codec hardware unit or may be provided by a collection of interoperable hardware units, including one or more processors as described above, along with appropriate software and / or firmware.
[0162] Various examples have been described. These and other examples are within the scope of the following claims. [Explanation of symbols]
[0163] 100 Video encoding and decoding system, system 102 Source Devices 104 Video Sources 106 memory 108 Output Interface 110 Computer-Readable Medium 112 Storage Devices 114 File Server 116 Destination Device 118 Display Devices 120 memory 122 input interface 130 Quadruple Tree / Binary Tree (QTBT) Structure, QTBT Structure 132 Coding Tree Unit (CTU), CTU 150 CTU 152 32×32 MER, MER 154 Merge Candidates 156 Merge Candidates 158 Merge Candidates 200 Video Encoder 202 Mode Selection Unit 204 Residual Generation Unit 206 Conversion Processing Unit 208 quantization units 210 Inverse Quantization Unit 212 Inverse Transformation Processing Unit 214 Reconstruction Unit 216 Filter Unit 218 Decoded Picture Buffer (DPB), DPB 220 Entropy Coding Unit 222 Motion Estimation Unit 224 Motion Compensation Unit 226 intra prediction units 230 video data memory 300 Video Decoder 302 Entropy Decoding Unit 304 Prediction Processing Unit 306 Inverse Quantization Unit 308 Inverse Transformation Processing Unit 310 Reconstruction Unit 312 Filter Unit 314 Decoded Picture Buffer (DPB), DPB 316 Motion Compensation Unit 318 Intra Prediction Units 320 CPB memory
Claims
1. 1. A method for decoding video data, comprising: storing a table of history-based motion vector predictors (HMVPs); determining motion information for a first block of said video data; (i) determining that the first block is located in the bottom right corner of a merged estimation region (MER); (ii) determining whether the sum of the x-coordinate of the top-left sample of the first block and the width of the first block divided by the size of the MER is greater than the x-coordinate of the top-left sample divided by the size of the MER; adding the motion information of the first block to the HMVP table in response to both (i) and (ii) being true; using the HMVP table to decode a second block of the video data; A method for providing
2. 1. A method for decoding video data, comprising: storing a table of history-based motion vector predictors (HMVPs); determining motion information for a first block of said video data; (i) determining that the first block is located in the bottom right corner of a merged estimation region (MER); (ii) determining whether the sum of the y coordinate of the top-left sample of the first block and the height of the first block divided by the size of the MER is greater than the y coordinate of the top-left sample divided by the size of the MER; adding the motion information of the first block to the HMVP table in response to both (i) and (ii) being true; using the HMVP table to decode a second block of the video data; A method for providing
3. 1. A method for decoding video data, comprising: storing a table of history-based motion vector predictors (HMVPs); determining motion information for a first block of said video data; (i) determining that the first block is located in the bottom right corner of a merged estimation region (MER); (ii) determining whether the sum of the x-coordinate of the top-left sample of the first block and the width of the first block divided by the size of the MER is greater than the x-coordinate of the top-left sample divided by the size of the MER; (iii) determining whether the sum of the y coordinate of the top-left sample of the first block and the height of the first block divided by the size of the MER is greater than the y coordinate of the top-left sample divided by the size of the MER; In response to (i), (ii), and (iii) all being true, add the motion information of the first block to the HMVP table. Steps and using the HMVP table to decode a second block of the video data; A method for providing
4. determining that the sum of the x-coordinate of the top left sample of the first block and the width of the first block divided by the size of the MER is greater than the x-coordinate of the top left sample divided by the size of the MER; floor(xCb / merSize) < floor((xCb + cbWidth) / merSize) is expressed as determining that a value obtained by dividing the sum of a y coordinate of a top-left sample of the first block and a height of the first block by a size of the MER is greater than a value obtained by dividing the y coordinate of the top-left sample by a size of the MER; floor(yCb / merSize) < floor((yCb + cbHeight) / merSize) is expressed as where: xCb represents the x coordinate of the top-left sample of the first block; yCb represents the y coordinate of the top-left sample of the first block; cbWidth represents the width of the first block; cbHeight represents the height of the first block; merSize represents the size of the MER; < represents the less than operation, 4. The method of claim 3, wherein floor() represents a floor operation.
5. outputting decoded video data including decoded versions of the first block and the second block. The method of claim 3 further comprising:
6. The decoding method is performed as part of a video encoding process, the method comprising: storing one or more decoded pictures including decoded versions of the first block and the second block; using the one or more stored decoded pictures to encode other blocks of other pictures of the video data; The method of claim 3 further comprising:
7. 1. A device for decoding video data, comprising: a memory configured to store the video data; and one or more processors implemented in circuitry, the one or more processors comprising: storing a table of history-based motion vector predictors (HMVPs); determining motion information for a first block of the video data; (i) determining that the first block is located in the bottom right corner of a merged estimation region (MER); (ii) determining whether the sum of the x-coordinate of the top-left sample of the first block and the width of the first block divided by the size of the MER is greater than the x-coordinate of the top-left sample divided by the size of the MER; responsive to both (i) and (ii) being true, adding the motion information of the first block to the HMVP table; Using the HMVP table to decode the second block of video data. A device configured to:
8. 1. A device for decoding video data, comprising: a memory configured to store the video data; and one or more processors implemented in circuitry, the one or more processors comprising: storing a table of history-based motion vector predictors (HMVPs); determining motion information for a first block of the video data; (i) determining that the first block is located in the bottom right corner of a merged estimation region (MER); (ii) determining whether the sum of the y coordinate of the top-left sample of the first block and the height of the first block divided by the size of the MER is greater than the y coordinate of the top-left sample divided by the size of the MER; responsive to both (i) and (ii) being true, adding the motion information of the first block to the HMVP table; Using the HMVP table to decode the second block of video data. A device configured to:
9. 1. A device for decoding video data, comprising: a memory configured to store the video data; and one or more processors implemented in circuitry, the one or more processors comprising: storing a table of history-based motion vector predictors (HMVPs); determining motion information for a first block of the video data; (i) determining that the first block is located in the bottom right corner of a merged estimation region (MER); (ii) determining whether the sum of the x-coordinate of the top-left sample of the first block and the width of the first block divided by the size of the MER is greater than the x-coordinate of the top-left sample divided by the size of the MER; (iii) determining whether the sum of the y coordinate of the top-left sample of the first block and the height of the first block divided by the size of the MER is greater than the y coordinate of the top-left sample divided by the size of the MER; responsive to (i), (ii), and (iii) all being true, adding the motion information of the first block to the HMVP table; using the HMVP table to decode a second block of the video data; and A device configured to:
10. to use the HMVP table to decode the second block of video data, the one or more processors: generating a motion information candidate list for the second block, the candidate list including candidates from the HMVP table; selecting a candidate from the candidate list of motion information; using the selected candidate to decode the second block of video data; and The device of claim 9 , further configured to:
11. The device of claim 9 , wherein the MER is a first MER and the second block belongs to a second MER.
12. determining that the sum of the x-coordinate of the top left sample of the first block and the width of the first block divided by the size of the MER is greater than the x-coordinate of the top left sample divided by the size of the MER; floor(xCb / merSize) < floor((xCb + cbWidth) / merSize) is expressed as determining that a value obtained by dividing the sum of a y coordinate of a top-left sample of the first block and a height of the first block by a size of the MER is greater than a value obtained by dividing the y coordinate of the top-left sample by a size of the MER; floor(yCb / merSize) < floor((yCb + cbHeight) / merSize) is expressed as where: xCb represents the x coordinate of the top-left sample of the first block; yCb represents the y coordinate of the top-left sample of the first block; cbWidth represents the width of the first block; cbHeight represents the height of the first block; merSize represents the size of the MER; < represents the less than operation, The device of claim 9 , wherein floor() represents a floor operation.
13. the one or more processors: outputting decoded video data including decoded versions of the first block and the second block; 10. The device of claim 9, further configured to:
14. the device comprises a video encoder, and the one or more processors: storing one or more decoded pictures including decoded versions of the first block and the second block; using the one or more stored decoded pictures to encode other blocks of other pictures of the video data 10. The device of claim 9, further configured to:
15. the device comprises a wireless communication device further comprising a receiver configured to receive encoded video data, the wireless communication device comprising a telephone handset, the receiver configured to demodulate a signal comprising the encoded video data in accordance with a wireless communication standard; or the device further comprises a display configured to display the decoded video data; or the device comprises one or more of a camera, a computer, a mobile device, a broadcast receiver device, or a set-top box; or the device comprises a wireless communication device further comprising a transmitter configured to transmit encoded video data, the wireless communication device comprising a telephone handset, the transmitter configured to modulate a signal comprising the encoded video data in accordance with a wireless communication standard; or The device of claim 9 , wherein the device further comprises a camera configured to capture the video data.
16. 7. A computer-readable storage medium storing instructions that, when executed by one or more processors, cause the one or more processors to perform the method of any one of claims 1 to 6.
Citation Information
Patent Citations
Method, apparatus, and computer program therefor for history-based motion vector prediction by parallel processing
JP2021516514A
Video processing method, device, and computer program
JP2022515036A
Method and apparatus for history-based motion vector prediction with parallel processing
WO2020018241A1